F_PC_0102_1.cs 5.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204
  1. /*******************************************************************************
  2. * Copyright(c) 2014 DongkeSoft All rights reserved. / Confidential
  3. * 类的信息:
  4. * 1.程序名称:F_PC_0102.cs
  5. * 2.功能描述:成型线管理
  6. * 编辑履历:
  7. * 作者 日期 版本 修改内容
  8. * 陈晓野 2015/04/22 1.00 新建
  9. *******************************************************************************/
  10. using System;
  11. using System.Collections.Generic;
  12. using System.Data;
  13. using System.Reflection;
  14. using System.Windows.Forms;
  15. using Dongke.IBOSS.PRD.Basics.BaseControls;
  16. using Dongke.IBOSS.PRD.Basics.BaseResources;
  17. using Dongke.IBOSS.PRD.Client.CommonModule;
  18. using Dongke.IBOSS.PRD.Client.Controls;
  19. using Dongke.IBOSS.PRD.WCF.DataModels;
  20. using Dongke.IBOSS.PRD.WCF.Proxys;
  21. using Dongke.IBOSS.PRD.WCF.Proxys.PCModuleService;
  22. namespace Dongke.IBOSS.PRD.Client.PCModule
  23. {
  24. /// <summary>
  25. /// 成型线管理
  26. /// </summary>
  27. public partial class F_PC_0102_1 : DKFormBase
  28. {
  29. #region 成员变量
  30. // 成型线ID
  31. private int _lineID = 0;
  32. // 窗体模式
  33. private Constant.FormMode _formMode = Constant.FormMode.Add;
  34. #endregion
  35. #region 构造函数
  36. /// <summary>
  37. /// 成型线管理
  38. /// </summary>
  39. public F_PC_0102_1()
  40. :this(0)
  41. {
  42. }
  43. /// <summary>
  44. /// 成型线管理
  45. /// </summary>
  46. /// <param name="id">成型线ID</param>
  47. public F_PC_0102_1(int id)
  48. {
  49. this._lineID = id;
  50. this.InitializeComponent();
  51. this.InitializeControls();
  52. }
  53. #endregion
  54. #region 事件
  55. /// <summary>
  56. /// 窗体加载事件
  57. /// </summary>
  58. /// <param name="sender"></param>
  59. /// <param name="e"></param>
  60. private void F_PC_0102_Load(object sender, EventArgs e)
  61. {
  62. try
  63. {
  64. // 取得成型线信息
  65. //ServiceResultEntity sre = this.DoAsync<ServiceResultEntity>(() =>
  66. // {
  67. // return PCModuleProxyNew.Service.GetFPC0102Data();
  68. // }
  69. //);
  70. }
  71. catch (Exception ex)
  72. {
  73. // 对异常进行共通处理
  74. ExceptionManager.HandleEventException(this.ToString(),
  75. MethodBase.GetCurrentMethod().Name, this.Text, ex);
  76. }
  77. }
  78. /// <summary>
  79. /// 添加成型线明细
  80. /// </summary>
  81. private void btnAddMould_Click(object sender, EventArgs e)
  82. {
  83. try
  84. {
  85. }
  86. catch (Exception ex)
  87. {
  88. // 对异常进行共通处理
  89. ExceptionManager.HandleEventException(this.ToString(),
  90. MethodBase.GetCurrentMethod().Name, this.Text, ex);
  91. }
  92. }
  93. /// <summary>
  94. /// 关闭窗体
  95. /// </summary>
  96. private void btnCancel_Click(object sender, EventArgs e)
  97. {
  98. this.Close();
  99. }
  100. /// <summary>
  101. /// 删除明细
  102. /// </summary>
  103. private void btnDeleteSelected_Click(object sender, EventArgs e)
  104. {
  105. try
  106. {
  107. }
  108. catch (Exception ex)
  109. {
  110. // 对异常进行共通处理
  111. ExceptionManager.HandleEventException(this.ToString(),
  112. MethodBase.GetCurrentMethod().Name, this.Text, ex);
  113. }
  114. }
  115. /// <summary>
  116. /// 提交新建
  117. /// </summary>
  118. private void btnSave_Click(object sender, EventArgs e)
  119. {
  120. try
  121. {
  122. }
  123. catch (Exception ex)
  124. {
  125. // 对异常进行共通处理
  126. ExceptionManager.HandleEventException(this.ToString(),
  127. MethodBase.GetCurrentMethod().Name, this.Text, ex);
  128. }
  129. }
  130. /// <summary>
  131. /// 编号变更
  132. /// </summary>
  133. private void txtBuildingNo_TextChanged(object sender, EventArgs e)
  134. {
  135. this.txtGroutingLineCode.Text = this.txtBuildingNo.Text + this.txtFloorNo.Text.PadLeft(2, '0')
  136. + this.txtGroutingLineNo.Text.Trim();
  137. this.txtGroutingLineName.Text = this.txtBuildingNo.Text + this.txtFloorNo.Text.PadLeft(2, '0')
  138. + this.txtGroutingLineNo.Text.Trim();
  139. }
  140. /// <summary>
  141. /// 编号变更
  142. /// </summary>
  143. private void txtFloorNo_TextChanged(object sender, EventArgs e)
  144. {
  145. this.txtGroutingLineCode.Text = this.txtBuildingNo.Text + this.txtFloorNo.Text.PadLeft(2, '0')
  146. + this.txtGroutingLineNo.Text.Trim();
  147. this.txtGroutingLineName.Text = this.txtBuildingNo.Text + this.txtFloorNo.Text.PadLeft(2, '0')
  148. + this.txtGroutingLineNo.Text.Trim();
  149. }
  150. /// <summary>
  151. /// 编号变更
  152. /// </summary>
  153. private void txtGroutingLineNo_TextChanged(object sender, EventArgs e)
  154. {
  155. this.txtGroutingLineCode.Text = this.txtBuildingNo.Text + this.txtFloorNo.Text.PadLeft(2, '0')
  156. + this.txtGroutingLineNo.Text.Trim();
  157. this.txtGroutingLineName.Text = this.txtBuildingNo.Text + this.txtFloorNo.Text.PadLeft(2, '0')
  158. + this.txtGroutingLineNo.Text.Trim();
  159. }
  160. /// <summary>
  161. /// 成型线文本改变事件
  162. /// </summary>
  163. /// <param name="sender"></param>
  164. /// <param name="e"></param>
  165. private void txtGroutingLineCode_TextChanged(object sender, EventArgs e)
  166. {
  167. }
  168. #endregion
  169. #region 私有方法
  170. /// <summary>
  171. /// 初始化控件
  172. /// </summary>
  173. private void InitializeControls()
  174. {
  175. this.Text = FormTitles.F_PC_0102;
  176. this.btnSave.Text = ButtonText.BTN_SAVE;
  177. this.btnClose.Text = ButtonText.BTN_CLOSE;
  178. this.dkUser.IsWorker = true;
  179. }
  180. #endregion
  181. }
  182. }