FrmCouplingApplPro.cs 21 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527
  1. using com.steering.mes.mcp.entity;
  2. using Core.Mes.Client.Comm.Control;
  3. using Core.Mes.Client.Comm.Format;
  4. using Core.Mes.Client.Comm.Server;
  5. using Core.Mes.Client.Comm.Tool;
  6. using Core.StlMes.Client.Mcp.BaseMethod;
  7. using Core.StlMes.Client.Mcp.CollarMaterial;
  8. using Core.StlMes.Client.Mcp.Common;
  9. using Core.StlMes.Client.Mcp.Control;
  10. using Core.StlMes.Client.Mcp.Entity;
  11. using CoreFS.CA06;
  12. using Infragistics.Win;
  13. using Infragistics.Win.UltraWinGrid;
  14. using System;
  15. using System.Collections;
  16. using System.Collections.Generic;
  17. using System.ComponentModel;
  18. using System.Data;
  19. using System.Drawing;
  20. using System.Linq;
  21. using System.Text;
  22. using System.Windows.Forms;
  23. namespace Core.StlMes.Client.Mcp.Coupling
  24. {
  25. public partial class FrmCouplingApplPro : FrmBase
  26. {
  27. private string[] arr = null;
  28. private string[] starts = { };
  29. private string departm = "";//获取部门ID
  30. private string[] plineCode = null;//获取产线代码
  31. private string cutGx = "";//交库工序
  32. private string num = "";//支数
  33. private string pwt = "";//重量
  34. public FrmCouplingApplPro()
  35. {
  36. InitializeComponent();
  37. this.IsLoadUserView = true;
  38. }
  39. private void FrmCouplingApplPro_Load(object sender, EventArgs e)
  40. {
  41. DateTime now = DateTime.Now;
  42. DateTime dt1 = new DateTime(now.Year, now.Month, 1);//当月第一天
  43. DateTime dt2 = dt1.AddMonths(1).AddDays(-1);//当月最后一天
  44. this.StartTime.Value = DateTime.Parse(dt1.ToString("yyyy-MM-dd") + " 00:00:00");
  45. this.EndTime.Value = DateTime.Parse(dt2.ToString("yyyy-MM-dd") + " 23:59:59");
  46. EntityHelper.ShowGridCaption<CouplingMatMEntity>(ultraGrid1.DisplayLayout.Bands[0]);
  47. EntityHelper.ShowGridCaption<Core.StlMes.Client.Mcp.Entity.PlnGxJgPropSEntity>(ultraGrid2.DisplayLayout.Bands[0]);
  48. EntityHelper.ShowGridCaption<com.steering.mes.mcp.entity.QcmZgJugdeApplyEntity>(ultraGrid3.DisplayLayout.Bands[0]);
  49. this.IsLoadUserView = true;
  50. arr = this.ValidDataPurviewIds;
  51. //departm = UserInfo.GetDeptid();
  52. //plineCode = McpBaseHelper.GetPCodePline(departm, this.ob);
  53. ////获取交库工序
  54. //DataTable dt3 = ServerHelper.GetData("com.steering.mes.mcp.common.PlanService.getQueryGX", new object[] { "700313" }, this.ob);
  55. //if (dt3.Rows.Count > 0)
  56. //{
  57. // cutGx = dt3.Rows[0]["BASECODE"].ToString();
  58. //}
  59. //PipeManageClass.BindComBaseInfo(cmbStroage, this.ob);
  60. QuerySinglePlan();
  61. }
  62. public override void ToolBar_Click(object sender, string ToolbarKey)
  63. {
  64. switch (ToolbarKey)
  65. {
  66. case "DoQuery":
  67. if (ultraTabControl1.SelectedTab.Index == 0)
  68. {
  69. QuerySinglePlan();
  70. }
  71. else if (ultraTabControl1.SelectedTab.Index == 1)
  72. {
  73. QueryZgJugdeApply();
  74. }
  75. break;
  76. case "DoDecision":
  77. DoDecision();//转成品箍
  78. break;
  79. case "cancelDoDecision":
  80. cancelDoDecision();//撤销申请判定
  81. break;
  82. break;
  83. case "DoClose":
  84. this.Close();
  85. break;
  86. }
  87. }
  88. /// <summary>
  89. /// 查询送判数据
  90. /// </summary>
  91. private void QueryZgJugdeApply()
  92. {
  93. string Woid = "";
  94. string jugeNo = "";
  95. string startTim = "";
  96. string endTim = "";
  97. ArrayList list = new ArrayList();
  98. if (this.chkwoId.Checked && this.txtWoId.Text.Trim() != "")
  99. {
  100. Woid = this.txtWoId.Text.Trim();
  101. }
  102. if (this.chkJuNo.Checked && this.txtJudgeStoveNO.Text.Trim() != "")
  103. {
  104. jugeNo = this.txtJudgeStoveNO.Text.Trim();
  105. }
  106. if (chkTim2.Checked)
  107. {
  108. if (DateTime.Parse(this.StartTime.Value.ToString()) > DateTime.Parse(EndTime.Value.ToString()))
  109. {
  110. MessageUtil.ShowTips("选择的前面时间不能大于后面的时间!");
  111. return;
  112. }
  113. else
  114. {
  115. startTim = this.StartTime.Value.ToString("yyyy-MM-dd HH:mm:ss");
  116. endTim = this.EndTime.Value.ToString("yyyy-MM-dd HH:mm:ss");
  117. }
  118. }
  119. list.Add(startTim);
  120. list.Add(endTim);
  121. list.Add(jugeNo);
  122. list.Add(this.ultraOptionSet1.CheckedItem.DataValue.ToString());
  123. list.Add(Woid);
  124. QcmZgJudgebindingSource1.Clear();
  125. List<Core.StlMes.Client.Mcp.Entity.QcmZgJugdeApplyEntity> listSource = EntityHelper.GetData<Core.StlMes.Client.Mcp.Entity.QcmZgJugdeApplyEntity>(
  126. "com.steering.mes.mcp.coup.FrmCouplingApplPro.QueryZgJugdeApply", new object[] { list, arr }, this.ob);
  127. QcmZgbindingSource.DataSource = listSource;
  128. // WriteTextToGrid();
  129. }
  130. /// <summary>
  131. /// 撤销申请判定
  132. /// </summary>
  133. private void cancelDoDecision()
  134. {
  135. this.ultraGrid3.UpdateData();
  136. UltraGridRow uRow = this.ultraGrid3.ActiveRow;
  137. if (uRow == null) return;
  138. string plinCode = uRow.Cells["PlineCode"].Text.ToString();
  139. IQueryable<UltraGridRow> checkMags = this.ultraGrid3.Rows.AsQueryable().Where(" CHK = 'True'");
  140. if (checkMags.Count() == 0)
  141. {
  142. MessageUtil.ShowTips("请选择需要撤销的成品箍信息!");
  143. return;
  144. }
  145. ArrayList parmList = new ArrayList();
  146. foreach (UltraGridRow row in checkMags)
  147. {
  148. Entity.QcmZgJugdeApplyEntity matBcEntity = (Entity.QcmZgJugdeApplyEntity)row.ListObject;
  149. string matEntity = JSONFormat.Format(matBcEntity);
  150. parmList.Add(matEntity);
  151. }
  152. CoreClientParam ccp = new CoreClientParam();
  153. ccp.ServerName = "com.steering.mes.mcp.coup.FrmCouplingApplPro";
  154. ccp.MethodName = "cancelDoDecision";
  155. ccp.ServerParams = new object[] { parmList };
  156. ccp = ob.ExecuteNonQuery(ccp, CoreInvokeType.Internal);
  157. if (ccp.ReturnCode != -1)
  158. {
  159. if (ccp.ReturnInfo.Equals("撤销成功!"))
  160. {
  161. string applyCode = ccp.ReturnObject.ToString();
  162. QueryZgJugdeApply();
  163. //this.txtMemo.Text = "";
  164. MessageUtil.ShowTips(ccp.ReturnInfo);
  165. }
  166. else
  167. {
  168. MessageUtil.ShowTips(ccp.ReturnInfo);
  169. }
  170. }
  171. }
  172. private void QuerySinglePlan()
  173. {
  174. string Woid = "";
  175. string jugeNo = "";
  176. string startTim = "";
  177. string endTim = "";
  178. ArrayList list = new ArrayList();
  179. if (this.chkwoId.Checked && this.txtWoId.Text.Trim() != "")
  180. {
  181. Woid = this.txtWoId.Text.Trim();
  182. }
  183. if (this.chkJuNo.Checked && this.txtJudgeStoveNO.Text.Trim() != "")
  184. {
  185. jugeNo = this.txtJudgeStoveNO.Text.Trim();
  186. }
  187. if (chkTim2.Checked)
  188. {
  189. if (DateTime.Parse(this.StartTime.Value.ToString()) > DateTime.Parse(EndTime.Value.ToString()))
  190. {
  191. MessageUtil.ShowTips("选择的前面时间不能大于后面的时间!");
  192. return;
  193. }
  194. else
  195. {
  196. startTim = this.StartTime.Value.ToString("yyyy-MM-dd HH:mm:ss");
  197. endTim = this.EndTime.Value.ToString("yyyy-MM-dd HH:mm:ss");
  198. }
  199. }
  200. list.Add(startTim);
  201. list.Add(endTim);
  202. list.Add(jugeNo);
  203. list.Add(this.ultraOptionSet1.CheckedItem.DataValue.ToString());
  204. list.Add(Woid);
  205. CouplingMatMbindingSource.Clear();
  206. List<CouplingMatMEntity> listSource = EntityHelper.GetData<CouplingMatMEntity>(
  207. "com.steering.mes.mcp.coup.FrmCouplingApplPro.doQueryMat", new object[] { list, arr }, this.ob);
  208. CouplingMatMbindingSource.DataSource = listSource;
  209. //double mater = 0.0;
  210. //double proWt = 0.0;
  211. //double loadWt = 0.0;
  212. //foreach(UltraGridRow urg in ultraGrid1.Rows)
  213. //{
  214. // proWt += Convert.ToDouble(urg.Cells["ProWt"].Value.ToString());
  215. // loadWt += Convert.ToDouble(urg.Cells["RealBlWt"].Value.ToString());
  216. //}
  217. //mater = proWt / loadWt;
  218. //ultraGrid1.DisplayLayout.Bands[0].Summaries[9].DisplayFormat = Math.Round(mater*100, 2).ToString() + "%";
  219. }
  220. /// <summary>
  221. /// 编辑区Gird
  222. /// </summary>
  223. /// <param name="sender"></param>
  224. /// <param name="e"></param>
  225. private void ultraGrid1_CellChange(object sender, Infragistics.Win.UltraWinGrid.CellEventArgs e)
  226. {
  227. string woid = "";
  228. string judgeNo = "";
  229. UltraGridRow urg = ultraGrid1.ActiveRow;
  230. if (urg == null)
  231. {
  232. return;
  233. }
  234. else
  235. {
  236. woid = urg.Cells["WoId"].Value.ToString();
  237. judgeNo = urg.Cells["JudgeStoveNo"].Value.ToString();
  238. }
  239. ultraGrid1.UpdateData();
  240. if (e.Cell.Column.Key.Equals("ProNum") && urg.Cells["ProNum"].Text != "")
  241. {
  242. if (num != "")
  243. {
  244. urg.Cells["ProWt"].Value = (Convert.ToDouble(urg.Cells["ProNum"].Text) * (Convert.ToDouble(pwt) / Convert.ToDouble(num))).ToString("f3");
  245. }
  246. else
  247. {
  248. MessageUtil.ShowTips("接箍库存为零,请检查!");
  249. return;
  250. }
  251. }
  252. ArrayList list = new ArrayList();
  253. ArrayList array = new ArrayList();
  254. string spec = "";
  255. string codeJgBl = urg.Cells["CodeJgBl"].Value.ToString();
  256. IQueryable<UltraGridRow> checkMags = this.ultraGrid1.Rows.AsQueryable().Where(" CHK = 'True'");
  257. List<string> specs = new List<string>();
  258. foreach (UltraGridRow row in checkMags)
  259. {
  260. CouplingMatMEntity matBcEntity = (CouplingMatMEntity)row.ListObject;
  261. if (matBcEntity.SpecJgDesc == null || matBcEntity.SpecJgDesc.Equals(""))
  262. {
  263. MessageUtil.ShowTips("接箍规格为空请检查!");
  264. return;
  265. }
  266. specs.Add(matBcEntity.SpecJgDesc);
  267. }
  268. //spec = "('" + string.Join("','", specs) + "')";
  269. spec = string.Join("','", specs);
  270. List<PlnGxJgPropSEntity> listSource = EntityHelper.GetData<PlnGxJgPropSEntity>(
  271. "com.steering.mes.mcp.coup.FrmCouplingApplPro.doQueryMat", new object[] { spec, codeJgBl }, this.ob);
  272. bindingSource1.DataSource = listSource;
  273. }
  274. /// <summary>
  275. /// 转成品箍
  276. /// </summary>
  277. private void DoDecision()
  278. {
  279. this.ultraGrid1.UpdateData();
  280. this.ultraGrid2.UpdateData();
  281. UltraGridRow sRow = this.ultraGrid1.ActiveRow;
  282. if (sRow == null) return;
  283. string PlinCode = sRow.Cells["PlineCode"].Value.ToString();
  284. string judgeNo = sRow.Cells["JudgeStoveNo"].Value.ToString();
  285. string batchNo = sRow.Cells["BatchNo"].Value.ToString();
  286. IQueryable<UltraGridRow> checkMags = this.ultraGrid1.Rows.AsQueryable().Where(" CHK = 'True'");
  287. if (checkMags.Count() == 0)
  288. {
  289. MessageUtil.ShowTips("请选择半成品箍信息!");
  290. return;
  291. }
  292. ArrayList parmList = new ArrayList();
  293. foreach (UltraGridRow row in checkMags)
  294. {
  295. CouplingMatMEntity matBcEntity = (CouplingMatMEntity)row.ListObject;
  296. //if (!matBcEntity.DeterNo.Equals(""))
  297. //{
  298. // MessageUtil.ShowTips("炉批已进行送判,不允许重复送判!");
  299. // return;
  300. //}
  301. if(Convert.ToInt64(matBcEntity.ProNum)>Convert.ToInt64(num))
  302. {
  303. MessageUtil.ShowTips("转成品箍数量不能大于库存数量!");
  304. return;
  305. }
  306. string specJg = "";
  307. UltraGridRow urg = ultraGrid2.ActiveRow;
  308. if (urg != null)
  309. {
  310. specJg = urg.Cells["SpecJgDesc"].Text;
  311. }
  312. if (matBcEntity.SpecJgDesc != specJg)
  313. {
  314. MessageUtil.ShowTips("半成品规格与所选合同规格不匹配!");
  315. return;
  316. }
  317. string matEntity = JSONFormat.Format(matBcEntity);
  318. parmList.Add(matEntity);
  319. }
  320. ArrayList list = new ArrayList();
  321. UltraGridRow uug = ultraGrid2.ActiveRow;
  322. if(uug==null)
  323. {
  324. MessageUtil.ShowTips("请选择合同信息!");
  325. return;
  326. }
  327. else
  328. {
  329. PlnGxJgPropSEntity plnSaleEntity = (PlnGxJgPropSEntity)uug.ListObject;
  330. string plnEntity = JSONFormat.Format(plnSaleEntity);
  331. list.Add(plnEntity);
  332. }
  333. //IQueryable<UltraGridRow> checksMags = this.ultraGrid2.Rows.AsQueryable().Where(" CHK = 'True'");
  334. //if (checksMags.Count() == 0)
  335. //{
  336. // MessageUtil.ShowTips("请选择合同信息!");
  337. // return;
  338. //}
  339. //foreach (UltraGridRow row in checksMags)
  340. //{
  341. // PlnSaleordEntity plnSaleEntity = (PlnSaleordEntity)row.ListObject;
  342. // string plnEntity = JSONFormat.Format(plnSaleEntity);
  343. // list.Add(plnEntity);
  344. //}
  345. //if (!matBcEntity.DeterNo.Equals(""))
  346. //{
  347. // MessageUtil.ShowTips("炉批已进行送判,不允许重复送判!");
  348. // return;
  349. //}
  350. CoreClientParam ccp = new CoreClientParam();
  351. ccp.ServerName = "com.steering.mes.mcp.coup.FrmCouplingApplPro";
  352. ccp.MethodName = "doDecision";
  353. ccp.ServerParams = new object[] { parmList,UserInfo.GetUserName(),list,num };
  354. ccp = ob.ExecuteNonQuery(ccp, CoreInvokeType.Internal);
  355. if (ccp.ReturnCode != -1)
  356. {
  357. if (ccp.ReturnInfo.Equals("转成品箍成功!"))
  358. {
  359. QuerySinglePlan();
  360. MessageUtil.ShowTips("转成品箍成功!");
  361. }
  362. else
  363. {
  364. MessageUtil.ShowTips(ccp.ReturnInfo);
  365. }
  366. }
  367. }
  368. /// <summary>
  369. /// ultraGrid2 触发事件
  370. /// </summary>
  371. /// <param name="sender"></param>
  372. /// <param name="e"></param>
  373. private void ultraGrid2_AfterRowActivate(object sender, EventArgs e)
  374. {
  375. UltraGridRow row = ultraGrid1.ActiveRow;
  376. if (row == null)
  377. {
  378. //List<CouplingComInfoEntity> listSource = new List<Entity.CouplingComInfoEntity>();
  379. //CouplingComInfoEntity.DataSource = listSource;
  380. //GridHelper.RefreshAndAutoSize(ultraGrid3);
  381. }
  382. else
  383. {
  384. //List<CouplingComInfoEntity> listSource = EntityHelper.GetData<CouplingComInfoEntity>
  385. // ("com.steering.mes.mcp.coup.FrmInLibrary.doQueryInfoResult", new object[] { row.Cells["ZY_PLAN_ID"].Text.ToString(), row.Cells["WO_ID"].Text.ToString() }, this.ob);
  386. //CouplingComInfoEntity.DataSource = listSource;
  387. //GridHelper.RefreshAndAutoSize(ultraGrid3);
  388. }
  389. }
  390. private void chkStarts_CheckedChanged(object sender, EventArgs e)
  391. {
  392. if (chkJuNo.Checked) { txtJudgeStoveNO.Enabled = true; } else { txtJudgeStoveNO.Enabled = false; }
  393. // if (chkPlnNo.Checked) { txtPlnNo.Enabled = true; } else { txtPlnNo.Enabled = false; }
  394. if (chkwoId.Checked) { txtWoId.Enabled = true; } else { txtWoId.Enabled = false; }
  395. }
  396. private void ultraTabControl1_SelectedTabChanged(object sender, Infragistics.Win.UltraWinTabControl.SelectedTabChangedEventArgs e)
  397. {
  398. if (toolMenu == null) return;
  399. if (ultraTabControl1.SelectedTab.Index == 0)
  400. {
  401. chkTim2.Text = "入库日期";
  402. toolMenu.Toolbars[0].Tools["DoDecision"].InstanceProps.Visible = DefaultableBoolean.True;
  403. toolMenu.Toolbars[0].Tools["cancelDoDecision"].InstanceProps.Visible = DefaultableBoolean.False;
  404. }
  405. else if (ultraTabControl1.SelectedTab.Index == 1)
  406. {
  407. chkTim2.Text = "送判日期";
  408. toolMenu.Toolbars[0].Tools["DoDecision"].InstanceProps.Visible = DefaultableBoolean.False;
  409. toolMenu.Toolbars[0].Tools["cancelDoDecision"].InstanceProps.Visible = DefaultableBoolean.True;
  410. }
  411. }
  412. private void ultraGrid1_AfterRowActivate(object sender, EventArgs e)
  413. {
  414. QueryPlnOrd();
  415. }
  416. private void QueryPlnOrd()
  417. {
  418. UltraGridRow urg = ultraGrid1.ActiveRow;
  419. string spec = urg.Cells["SpecJgDesc"].Value.ToString();
  420. string codeJgBl = urg.Cells["CodeJgBl"].Value.ToString();
  421. List<PlnGxJgPropSEntity> listSource = EntityHelper.GetData<PlnGxJgPropSEntity>
  422. ("com.steering.mes.mcp.coup.FrmCouplingApplPro.doQueryplnSaleorder", new object[] { spec, codeJgBl }, this.ob);
  423. bindingSource1.DataSource = listSource;
  424. GridHelper.RefreshAndAutoSize(ultraGrid2);
  425. UltraGridRow row = ultraGrid1.ActiveRow;
  426. if(row==null)
  427. {
  428. return;
  429. }
  430. else
  431. {
  432. num = row.Cells["ProNum"].Text.ToString();
  433. pwt = row.Cells["ProWt"].Text.ToString();
  434. }
  435. }
  436. /// <summary>
  437. /// 查询炉批信息
  438. /// </summary>
  439. // private void doQueryJudgeBath(string woid, string judgeNo, string jugdeApplyCode)
  440. // {
  441. // UltraGridRow uRow = this.ultraGrid1.ActiveRow;
  442. // if (uRow == null)
  443. // {
  444. // return;
  445. // }
  446. // List<CouplingMatMEntity1> listSource = EntityHelper.GetData<CouplingMatMEntity1>(
  447. // "com.steering.mes.mcp.coup.FrmCouplingApplPro.doQueryJudgeBath", new object[] { woid, judgeNo, jugdeApplyCode, this.ultraOptionSet1.CheckedItem.DataValue.ToString() }, this.ob);
  448. // CouplingMatMbindingSource1.DataSource = listSource;
  449. // foreach (UltraGridRow row in this.ultraGrid2.Rows)
  450. // {
  451. // row.Cells["CHK"].Value = "True";
  452. // row.Update();
  453. // }
  454. // List<Core.StlMes.Client.Mcp.Entity.QcmZgJugdeApplyEntity> listSource1 = EntityHelper.GetData<Core.StlMes.Client.Mcp.Entity.QcmZgJugdeApplyEntity>(
  455. //"com.steering.mes.mcp.coup.FrmCouplingApplPro.doQueryQcmZgApplyData", new object[] { uRow.Cells["JudgeStoveNo"].Text }, this.ob);
  456. // if(listSource1.Count>0)
  457. // {
  458. // ultraGrid2.DisplayLayout.Bands[0].Columns["isFlag"].Header.Caption = "前工序是否紧急放行";
  459. // foreach (UltraGridRow row in this.ultraGrid2.Rows)
  460. // {
  461. // row.Cells["isFlag"].Value = "是";
  462. // }
  463. // }
  464. // else
  465. // {
  466. // ultraGrid2.DisplayLayout.Bands[0].Columns["isFlag"].Header.Caption = "前工序是否紧急放行";
  467. // foreach (UltraGridRow row in this.ultraGrid2.Rows)
  468. // {
  469. // row.Cells["isFlag"].Value = "否";
  470. // }
  471. // }
  472. // }
  473. private void ultraGrid3_ClickCellButton(object sender, CellEventArgs e)
  474. {
  475. this.ultraGrid3.UpdateData();
  476. if (e.Cell.Column.Key == "JugdeApplyCode")
  477. {
  478. string jugdeApplyCode = ultraGrid3.ActiveRow.Cells["JugdeApplyCode"].Value.ToString();
  479. string judgeStoveNo = ultraGrid3.ActiveRow.Cells["JudgeStoveNo"].Value.ToString();
  480. string ordenNo = ultraGrid3.ActiveRow.Cells["ProOrderNo"].Value.ToString();
  481. FrmQcmAddAsk orderZg = new FrmQcmAddAsk(jugdeApplyCode, judgeStoveNo, ordenNo, this.ob);
  482. orderZg.ShowDialog();
  483. }
  484. }
  485. private void FrmCouplingApplPro_Shown(object sender, EventArgs e)
  486. {
  487. if (toolMenu == null) return;
  488. if (toolMenu.Toolbars[0].Tools.Exists("cancelDoDecision"))
  489. {
  490. toolMenu.Toolbars[0].Tools["cancelDoDecision"].InstanceProps.Visible = DefaultableBoolean.False;
  491. }
  492. }
  493. }
  494. }