FrmStandardG.cs 23 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571
  1. using Core.Mes.Client.Comm.Control;
  2. using Core.Mes.Client.Comm.Server;
  3. using CoreFS.CA06;
  4. using Infragistics.Win.UltraWinEditors;
  5. using Infragistics.Win.UltraWinGrid;
  6. using System;
  7. using System.Collections;
  8. using System.Collections.Generic;
  9. using System.Data;
  10. using System.Drawing;
  11. using System.Windows.Forms;
  12. namespace Core.StlMes.Client.Qcm
  13. {
  14. public partial class FrmStandardG : FrmBase
  15. {
  16. //提示信息
  17. private string errMessage = "";
  18. private Dictionary<string, UltraComboEditor> _ultCmbDic_Unit = null;
  19. //定位标准基础
  20. private string _std = "";
  21. //判断是否勾选
  22. private int isSelectData = -1;
  23. UltraComboEditor[] ucbs = new UltraComboEditor[3];
  24. public FrmStandardG()
  25. {
  26. InitializeComponent();
  27. }
  28. /// <summary>
  29. /// 重写基类方法
  30. /// </summary>
  31. /// <param name="sender"></param>
  32. /// <param name="ToolbarKey"></param>
  33. public override void ToolBar_Click(object sender, string ToolbarKey)
  34. {
  35. switch (ToolbarKey)
  36. {
  37. case "doQuery":
  38. DoQuery();
  39. break;
  40. case "doSave":
  41. DoSave();
  42. break;
  43. case "doDelete":
  44. this.DoDeleteOrResume(true);
  45. break;
  46. case "doResume":
  47. this.DoDeleteOrResume(false);
  48. break;
  49. case "Refresh":
  50. InitComBoEditor();
  51. break;
  52. case "Export":
  53. Export();
  54. break;
  55. case "Close":
  56. this.Close();
  57. break;
  58. }
  59. }
  60. private void Export()
  61. {
  62. GridHelper.ulGridToExcel(ultraGrid1, "其他标准");
  63. }
  64. /// <summary>
  65. /// 查询
  66. /// </summary>
  67. private void DoQuery()
  68. {
  69. //查询条件
  70. string valid = "1";
  71. if (ChcValid.Checked)
  72. valid = "0";
  73. string std = "";
  74. if (ChcStd.Checked)
  75. std = TextStd.Text.Trim();
  76. //CoreStandard标准基础表
  77. DataTable dt = ServerHelper.GetData("com.steering.pss.qcm.CoreStandard1.getComBaseStd", new Object[] { valid, std }, this.ob);
  78. if (CustomInfo == "1")
  79. {
  80. DataRow[] rows = dt.Select("STDSTYLE<>'订货标准' AND STDSTYLE<>'协议标准'");
  81. foreach (DataRow dr in rows)
  82. {
  83. dt.Rows.Remove(dr);
  84. }
  85. }
  86. if (CustomInfo == "2")
  87. {
  88. DataRow[] rows = dt.Select("STDSTYLE<>'内控'");
  89. foreach (DataRow dr in rows)
  90. {
  91. dt.Rows.Remove(dr);
  92. }
  93. }
  94. if (CustomInfo == "3")
  95. {
  96. DataRow[] rows = dt.Select("STDSTYLE<>'Alpha'");
  97. foreach (DataRow dr in rows)
  98. {
  99. dt.Rows.Remove(dr);
  100. }
  101. }
  102. if (CustomInfo == "4")
  103. {
  104. DataRow[] rows = dt.Select("STDSTYLE='协议标准' or STDSTYLE='订货标准' or STDSTYLE='Alpha' or STDSTYLE='内控'");
  105. foreach (DataRow dr in rows)
  106. {
  107. dt.Rows.Remove(dr);
  108. }
  109. }
  110. GridHelper.CopyDataToDatatable(ref dt, ref this.dataTable1, true);
  111. //定位
  112. UltraGridRow[] rows1 = GridHelper.GetRowsWithKey(ultraGrid1, new string[] { "STD_NAME" }, new string[] { _std });
  113. if (rows1.Length > 0)
  114. rows1[0].Activate();
  115. UltraGridColumn[] col = new UltraGridColumn[] { this.ultraGrid1.DisplayLayout.Bands[0].Columns["STD_NAME"], this.ultraGrid1.DisplayLayout.Bands[0].Columns["MEMO"] };
  116. GridHelper.RefreshAndAutoSizeExceptRows(ultraGrid1, col);
  117. QcmBaseCommon.SetUltraGridNoEdit(ultraGrid1);
  118. isSelectData = -1;
  119. }
  120. /// <summary>
  121. /// 保存
  122. /// </summary>
  123. private void DoSave()
  124. {
  125. ultraGrid1.UpdateData();
  126. if (isSelectData == -1)
  127. {
  128. MessageBox.Show("请选择记录!", "提示", MessageBoxButtons.OK, MessageBoxIcon.Information);
  129. return;
  130. }
  131. //标准基础
  132. UltraGridRow[] rows = GridHelper.GetRowsWithKey(ultraGrid1, new string[] { "CHC" }, new string[] { "True" });
  133. ArrayList stdAdd = new ArrayList();
  134. ArrayList stdUpdate = new ArrayList();
  135. if (rows.Length > 0)
  136. {
  137. foreach (UltraGridRow row in rows)
  138. {
  139. ArrayList stdList = GetStdData(row);
  140. if (stdList == null)
  141. {
  142. MessageBox.Show(errMessage, "提示", MessageBoxButtons.OK, MessageBoxIcon.Information);
  143. return;
  144. }
  145. //标准名称
  146. string stdName = row.Cells["STD_NAME"].Value.ToString().Trim();
  147. string stdType = row.Cells["STDSTYLE"].Value.ToString();
  148. string stdCodeU = row.Cells["STD_CODE"].Value.ToString().Trim();
  149. if (!row.Cells["VALIDFLAG"].Value.ToString().Equals("") && row.Cells["STD_NAME_OLD"].Value.ToString() != stdName)
  150. {
  151. DataTable dt1 = ServerHelper.GetData("com.steering.pss.qcm.CoreStandard.getPsc", new Object[] { stdCodeU }, this.ob);
  152. if (dt1 != null && dt1.Rows.Count > 0 && Int32.Parse(dt1.Rows[0][0].ToString()) > 0)
  153. {
  154. MessageBox.Show("标准代码:" + stdCodeU + " 已经被产品规范码引用,不能修改!", "提示",
  155. MessageBoxButtons.OK, MessageBoxIcon.Information);
  156. return;
  157. }
  158. }
  159. _std = stdName;
  160. //标准代码
  161. string stdCode = row.Cells["STD_CODE"].Value.ToString().Trim();
  162. //如果创建人为空,则新增,否则修改
  163. if (row.Cells["VALIDFLAG"].Value.ToString().Equals(""))
  164. {
  165. UltraGridRow[] rows1 = GridHelper.GetRowsWithKey(ultraGrid1, new string[] { "STD_NAME", "STDSTYLE" }, new string[] { stdName, stdType });
  166. if (rows1.Length > 1)
  167. {
  168. MessageBox.Show("标准名称:" + stdName + " 已经存在,请重新输入!", "提示",
  169. MessageBoxButtons.OK, MessageBoxIcon.Information);
  170. return;
  171. }
  172. //验证标准名称是否重复
  173. DataTable dt = ServerHelper.GetData("com.steering.pss.qcm.CoreStandard1.checkStdName", new Object[] { stdName, stdType }, this.ob);
  174. if (dt != null && dt.Rows.Count > 0)
  175. {
  176. MessageBox.Show("标准名称:" + stdName + " 已经存在,请重新输入!", "提示",
  177. MessageBoxButtons.OK, MessageBoxIcon.Information);
  178. return;
  179. }
  180. stdAdd.Add(stdList);
  181. }
  182. else
  183. {
  184. //验证标准名称是否重复
  185. DataTable dt = ServerHelper.GetData("com.steering.pss.qcm.CoreStandard1.checkStdName",
  186. new Object[] { stdName, stdCode, stdType }, this.ob);
  187. if (dt != null && dt.Rows.Count > 0)
  188. {
  189. MessageBox.Show("标准名称:" + stdName + " 已经存在,请重新输入!", "提示",
  190. MessageBoxButtons.OK, MessageBoxIcon.Information);
  191. return;
  192. }
  193. stdList.Add(stdCode);
  194. stdUpdate.Add(stdList);
  195. }
  196. }
  197. }
  198. if (MessageBox.Show("是否保存选择记录?", "提示", MessageBoxButtons.YesNo, MessageBoxIcon.Question) == DialogResult.No)
  199. {
  200. return;
  201. }
  202. //产品规范
  203. ArrayList pscAdd = new ArrayList();
  204. ArrayList pscUpdate = new ArrayList();
  205. //客户
  206. ArrayList custerAdd = new ArrayList();
  207. ArrayList custerUpdate = new ArrayList();
  208. if (stdAdd.Count > 0 || pscAdd.Count > 0 || custerAdd.Count > 0 || stdUpdate.Count > 0 || pscUpdate.Count > 0 || custerUpdate.Count > 0)
  209. {
  210. int count = ServerHelper.SetData("com.steering.pss.qcm.CoreStandard1.saveCoreStandard1",
  211. new Object[] { stdAdd, stdUpdate, pscAdd, pscUpdate, custerAdd, custerUpdate }, this.ob);
  212. if (count > 0)
  213. {
  214. MessageBox.Show("保存成功!", "提示", MessageBoxButtons.OK, MessageBoxIcon.Information);
  215. DoQuery();
  216. }
  217. }
  218. }
  219. /// <summary>
  220. /// 作废与恢复
  221. /// </summary>
  222. /// <param name="flag"></param>
  223. private void DoDeleteOrResume(Boolean flag)
  224. {
  225. if (isSelectData == -1)
  226. {
  227. MessageBox.Show("请选择记录!", "提示", MessageBoxButtons.OK, MessageBoxIcon.Information);
  228. return;
  229. }
  230. if (flag)
  231. {
  232. if (MessageBox.Show("是否作废选择记录", "提示", MessageBoxButtons.YesNo, MessageBoxIcon.Question) == DialogResult.No)
  233. {
  234. return;
  235. }
  236. }
  237. else
  238. {
  239. if (MessageBox.Show("是否恢复选择记录?", "提示", MessageBoxButtons.YesNo, MessageBoxIcon.Question) == DialogResult.No)
  240. {
  241. return;
  242. }
  243. }
  244. //标准基础
  245. UltraGridRow[] rows = GridHelper.GetRowsWithKey(ultraGrid1, new string[] { "CHC" }, new string[] { "True" });
  246. ArrayList stdList = new ArrayList();
  247. ArrayList pscList = new ArrayList();
  248. ArrayList custList = new ArrayList();
  249. if (rows.Length > 0)
  250. {
  251. foreach (UltraGridRow row in rows)
  252. {
  253. ArrayList std = new ArrayList();
  254. if (flag)
  255. {
  256. std.Add(UserInfo.GetUserName());
  257. }
  258. else
  259. std.Add("");
  260. std.Add(row.Cells["STD_CODE"].Value.ToString());
  261. stdList.Add(std);
  262. //用于定位
  263. _std = row.Cells["STD_NAME"].Value.ToString();
  264. //DataTable dt1 = ServerHelper.GetData("com.steering.pss.qcm.ComBaseQuery.getCount", new Object[] { row.Cells["STD_NAME"].Value.ToString() }, this.ob);
  265. //if (dt1 != null && dt1.Rows.Count > 0 && Int32.Parse(dt1.Rows[0][0].ToString()) > 0)
  266. //{
  267. // MessageBox.Show("标准名称:" + row.Cells["STD_NAME"].Value.ToString() + " 已经被引用,不能作废!", "提示",
  268. // MessageBoxButtons.OK, MessageBoxIcon.Information);
  269. // return;
  270. //}
  271. }
  272. }
  273. if (stdList.Count > 0 || pscList.Count > 0 || custList.Count > 0)
  274. {
  275. int count = ServerHelper.SetData("com.steering.pss.qcm.CoreStandard1.deleteOrResume",
  276. new Object[] { stdList, pscList, custList, flag }, this.ob);
  277. if (count > 0)
  278. {
  279. if (flag)
  280. MessageBox.Show("作废成功!", "提示", MessageBoxButtons.OK, MessageBoxIcon.Information);
  281. else
  282. MessageBox.Show("恢复成功!", "提示", MessageBoxButtons.OK, MessageBoxIcon.Information);
  283. DoQuery();
  284. }
  285. }
  286. }
  287. /// <summary>
  288. /// 初始化下拉框
  289. /// </summary>
  290. private void InitComBoEditor()
  291. {
  292. for (int i = 0; i < ucbs.Length; i++)
  293. {
  294. ucbs[i] = new UltraComboEditor();
  295. Controls.Add(ucbs[i]);
  296. ucbs[i].Visible = false;
  297. }
  298. UltraGridBand ugb = ultraGrid1.DisplayLayout.Bands[0];
  299. //初始化标准类型
  300. ClsBaseInfo.FillStdType(ucbs[0], this.ob, false);
  301. if (CustomInfo == "1")
  302. {
  303. ((DataTable)ucbs[0].DataSource).DefaultView.RowFilter = "CODE IN ('G', 'X')";
  304. }
  305. if (CustomInfo == "2")
  306. {
  307. ((DataTable)ucbs[0].DataSource).DefaultView.RowFilter = "CODE IN ('N')";
  308. }
  309. if (CustomInfo == "3")
  310. {
  311. ((DataTable)ucbs[0].DataSource).DefaultView.RowFilter = "CODE IN ('K')";
  312. }
  313. if (CustomInfo == "4")
  314. {
  315. ((DataTable)ucbs[0].DataSource).DefaultView.RowFilter = "CODE IN ('P','S')";
  316. }
  317. ugb.Columns["STDSTYLE"].EditorComponent = ucbs[0];
  318. ugb.Columns["STDSTYLE"].Style = Infragistics.Win.UltraWinGrid.ColumnStyle.DropDownList;
  319. //初始化标准协会
  320. QcmBaseCommon.InitDropUltraComEditor(ucbs[1], "com.steering.pss.qcm.CoreStandard1.bandCmbMaxStdXh", "BASENAME", this.ob, true);
  321. ugb.Columns["STD_STYLE_NAME"].EditorComponent = ucbs[1];
  322. ugb.Columns["STD_STYLE_NAME"].Style = Infragistics.Win.UltraWinGrid.ColumnStyle.DropDownList;
  323. //初始化管理部门
  324. QcmBaseCommon.InitDropUltraComEditor(ucbs[2], "com.steering.comm.data.ComBaseInfo.getDepartment", "DEPARTNAME", this.ob, false);
  325. ugb.Columns["DEPARTMENT_DESC"].EditorComponent = ucbs[2];
  326. ugb.Columns["DEPARTMENT_DESC"].Style = Infragistics.Win.UltraWinGrid.ColumnStyle.DropDownList;
  327. CreateGrid1Combo(ucbs[2]);
  328. }
  329. /// <summary>
  330. /// 集合 生成Comboeditor集合 用于科室管理
  331. /// </summary>
  332. private void CreateGrid1Combo(UltraComboEditor ultraComboDepart)
  333. {
  334. int cout = ultraComboDepart.Items.Count;
  335. _ultCmbDic_Unit = new Dictionary<string, UltraComboEditor>(cout + 1);
  336. _ultCmbDic_Unit.Add("NoValue", new UltraComboEditor());
  337. for (int i = 0; i < ultraComboDepart.Items.Count; i++)
  338. {
  339. string pid = ultraComboDepart.Items[i].DataValue.ToString().Split('@')[0];
  340. DataTable dt = ServerHelper.GetData("com.steering.comm.data.ComBaseInfo.getSection",
  341. new object[] { }, this.ob);
  342. dt.DefaultView.RowFilter = "PID = '" + pid + "'";
  343. UltraComboEditor cmb = new UltraComboEditor();
  344. cmb.DataSource = dt;
  345. cmb.DisplayMember = "DEPARTNAME";
  346. cmb.ValueMember = "DEPARTID";
  347. cmb.Visible = false;
  348. _ultCmbDic_Unit.Add(pid, cmb);
  349. this.Controls.Add(cmb);
  350. }
  351. }
  352. /// <summary>
  353. /// 动态绑定数据源 管理科室
  354. /// </summary>
  355. private void BandComboToGrid(InitializeRowEventArgs e)
  356. {
  357. string pid = e.Row.Cells["DEPARTMENT_CODE"].Value.ToString();
  358. if (_ultCmbDic_Unit.ContainsKey(pid))
  359. {
  360. e.Row.Cells["UNIT_DESC"].EditorComponent = _ultCmbDic_Unit[pid];
  361. }
  362. else
  363. {
  364. e.Row.Cells["UNIT_DESC"].EditorComponent = _ultCmbDic_Unit["NoValue"];
  365. }
  366. }
  367. private void ChcStd_CheckedChanged(object sender, EventArgs e)
  368. {
  369. if (ChcStd.Checked)
  370. TextStd.Enabled = true;
  371. else
  372. TextStd.Enabled = false;
  373. }
  374. private void ultraGrid1_AfterRowInsert(object sender, RowEventArgs e)
  375. {
  376. //增加一行,自动获取最大的标准代码,然后加1
  377. UltraGridRow ugr = ultraGrid1.DisplayLayout.ActiveRow;
  378. int stdCode = 0;
  379. DataRow[] rows = dataTable1.Select("", "STD_CODE DESC");
  380. if (rows.Length > 0)
  381. stdCode = Convert.ToInt32(rows[0]["STD_CODE"].ToString().Substring(3, 7));
  382. ugr.Cells["STD_CODE"].Value = "STD" + string.Format("{0:0000000}", (stdCode + 1));
  383. //增加行如果没有勾选则不可编辑
  384. if (!Convert.ToBoolean(ugr.Cells["CHC"].Value))
  385. {
  386. for (int i = 0; i < ugr.Cells.Count; i++)
  387. {
  388. if (!ugr.Cells[i].Column.Key.Equals("CHC"))
  389. ugr.Cells[i].Activation = Activation.ActivateOnly;
  390. }
  391. }
  392. }
  393. private void ultraGrid1_CellChange(object sender, CellEventArgs e)
  394. {
  395. ultraGrid1.UpdateData();
  396. UltraGridRow ugr = ultraGrid1.DisplayLayout.ActiveRow;
  397. if (e.Cell.Column.Key.Equals("STD_STYLE_NAME")) //标准协会
  398. {
  399. ugr.Cells["STD_STYLE"].Value = ugr.Cells["STD_STYLE_NAME"].Value.ToString();
  400. }
  401. //if (e.Cell.Column.Key.Equals("STDSTYLE")) //标准类型
  402. //{
  403. // if (e.Cell.Value.ToString().Equals("K"))
  404. // {
  405. // ugr.Cells["DEPARTMENT_DESC"].Appearance.BackColor = Color.Empty;
  406. // ugr.Cells["UNIT_DESC"].Appearance.BackColor = Color.Empty;
  407. // }
  408. // else
  409. // {
  410. // ugr.Cells["DEPARTMENT_DESC"].Appearance.BackColor = Color.Yellow;
  411. // ugr.Cells["UNIT_DESC"].Appearance.BackColor = Color.Yellow;
  412. // }
  413. //}
  414. if (e.Cell.Column.Key.Equals("DEPARTMENT_DESC")) //部门管理
  415. {
  416. string departMentCode = ugr.Cells["DEPARTMENT_DESC"].Value.ToString();
  417. string[] str = departMentCode.Split('@');
  418. ugr.Cells["DEPARTMENT_CODE"].Value = str[0];
  419. //根据部门号查询管理科室
  420. ugr.Cells["UNIT_CODE"].Value = "";
  421. ugr.Cells["UNIT_DESC"].Value = "";
  422. }
  423. if (e.Cell.Column.Key.Equals("UNIT_DESC")) //科室管理
  424. {
  425. ugr.Cells["UNIT_CODE"].Value = ugr.Cells["UNIT_DESC"].Value.ToString();
  426. }
  427. if (e.Cell.Column.Key.Equals("CHC"))//选择
  428. {
  429. Activation activation = Activation.ActivateOnly;
  430. if (Convert.ToBoolean(e.Cell.Value))
  431. {
  432. activation = Activation.AllowEdit;
  433. isSelectData += 1;
  434. }
  435. else
  436. isSelectData -= 1;
  437. CellsCollection cells = e.Cell.Row.Cells;
  438. for (int i = 0; i < cells.Count; i++)
  439. {
  440. if (!cells[i].Column.Key.Equals("CHC"))
  441. {
  442. e.Cell.Row.Cells[i].Activation = activation;
  443. }
  444. }
  445. }
  446. }
  447. private void ultraGrid1_InitializeRow(object sender, InitializeRowEventArgs e)
  448. {
  449. BandComboToGrid(e);
  450. if (e.Row.Cells["VALIDFLAG"].Value.ToString().Equals("无效"))
  451. {
  452. e.Row.Appearance.ForeColor = Color.Red;
  453. }
  454. else
  455. {
  456. e.Row.Appearance.ForeColor = Color.Black;
  457. }
  458. }
  459. /// <summary>
  460. /// 获取标准类型数据
  461. /// </summary>
  462. /// <param name="ugr"></param>
  463. /// <returns></returns>
  464. private ArrayList GetStdData(UltraGridRow ugr)
  465. {
  466. ArrayList list = new ArrayList();
  467. string std_code = ugr.Cells["std_code"].Value.ToString();
  468. string std_name = ugr.Cells["std_name"].Value.ToString().Trim();
  469. if (std_name.Equals(""))
  470. {
  471. errMessage = "请输入标准名称";
  472. return null;
  473. }
  474. string stdstyle = ugr.Cells["stdstyle"].Text.ToString();
  475. if (stdstyle.Equals(""))
  476. {
  477. errMessage = "请选择标准类型";
  478. return null;
  479. }
  480. if (stdstyle.Equals("订货标准"))
  481. stdstyle = "G";
  482. else if (stdstyle.Equals("Alpha"))
  483. stdstyle = "K";
  484. else if (stdstyle.Equals("内控"))
  485. stdstyle = "N";
  486. else if (stdstyle.Equals("协议标准"))
  487. stdstyle = "X";
  488. else if (stdstyle.Equals("试验标准"))
  489. stdstyle = "S";
  490. else
  491. stdstyle = "P";
  492. string std_note = ugr.Cells["std_note"].Value.ToString();
  493. string std_style = ugr.Cells["std_style"].Value.ToString();
  494. string std_style_name = ugr.Cells["std_style_name"].Text.ToString();
  495. string std_version = ugr.Cells["std_version"].Value.ToString();
  496. string department_code = ugr.Cells["department_code"].Value.ToString();
  497. string department_desc = ugr.Cells["department_desc"].Text.ToString();
  498. if (CustomInfo != "3" && department_desc.Equals(""))
  499. {
  500. errMessage = "请选择管理部门描述";
  501. return null;
  502. }
  503. string unit_code = ugr.Cells["unit_code"].Value.ToString();
  504. string unit_desc = ugr.Cells["unit_desc"].Text.ToString();
  505. if (CustomInfo != "3" && unit_desc.Equals(""))
  506. {
  507. errMessage = "请选择管理科室描述";
  508. return null;
  509. }
  510. string userName = UserInfo.GetUserName();
  511. string validflag = ugr.Cells["validflag"].Value.ToString();
  512. if (validflag.Equals("无效"))
  513. {
  514. errMessage = "无效记录不能保存";
  515. return null;
  516. }
  517. string memo = ugr.Cells["memo"].Value.ToString();
  518. list.Add(std_code);
  519. list.Add(std_name);
  520. list.Add(stdstyle);
  521. list.Add(std_note);
  522. list.Add(std_style);
  523. list.Add(std_style_name);
  524. list.Add(std_version);
  525. list.Add(department_code);
  526. list.Add(department_desc);
  527. list.Add(unit_code);
  528. list.Add(unit_desc);
  529. list.Add(userName);
  530. list.Add(memo);
  531. return list;
  532. }
  533. private void FrmStandardG_Load(object sender, EventArgs e)
  534. {
  535. InitComBoEditor();
  536. if (this.CustomInfo == "3")
  537. {
  538. this.ultraGrid1.DisplayLayout.Bands[0].Columns["DEPARTMENT_DESC"].CellAppearance.BackColor = Color.Empty;
  539. this.ultraGrid1.DisplayLayout.Bands[0].Columns["UNIT_DESC"].CellAppearance.BackColor = Color.Empty;
  540. }
  541. }
  542. }
  543. }