| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156 |
- using System;
- using System.Collections.Generic;
- using System.ComponentModel;
- using System.Data;
- using System.Drawing;
- using System.Linq;
- using System.Text;
- using System.Windows.Forms;
- using CoreFS.CA06;
- using Infragistics.Win.UltraWinGrid;
- using System.Collections;
- using System.Diagnostics;
- namespace Core.LZMes.Client.UIB
- {
- public partial class UIB030230 : FrmBase
- {
- public UIB030230()
- {
- InitializeComponent();
- }
- public override void ToolBar_Click(object sender, string ToolbarKey)
- {
- switch (ToolbarKey)
- {
- case "Query":
- this.DoQuery();
- break;
- case "Save":
- this.DoSave();
- break;
- }
- }
- public void DoQuery()
- {
- try
- {
- ArrayList al = new ArrayList();
- al.Add("UIB030230_01.SELECT");
- al.Add(this.textBox3_COILNO.Text.Trim());
- this.dataSet1.Tables[0].Clear();
- CoreClientParam ccp = new CoreClientParam();
- ccp.ServerName = "UIB.COM.ComDBQuery";
- ccp.MethodName = "doSimpleQuery";
- ccp.ServerParams = new object[] { al };
- ccp.SourceDataTable = this.dataSet1.Tables[0];
- this.ExecuteQueryToDataTable(ccp, CoreInvokeType.Internal);
- }
- catch (Exception ex)
- {
- }
- }
- public void DoSave()
- {
- try
- {
- if (MessageBox.Show("确定改判?", "提示", MessageBoxButtons.OKCancel) == DialogResult.Cancel)
- return;
- //改判
- CoreClientParam ccp = new CoreClientParam();
- Hashtable ht = new Hashtable();
- ht.Add("i1", this.ultraGrid1.ActiveRow.Cells["COIL_NO"].Text);
- ht.Add("i2", this.ultraGrid2.ActiveRow.Cells["PRDNM_CD"].Text);
- ht.Add("i3", this.ultraGrid2.ActiveRow.Cells["SPEC_ABBSYM"].Text);
- ht.Add("i4", this.ultraGrid2.ActiveRow.Cells["SPEC_STL_GRD"].Text);
- ht.Add("i5", this.ultraGrid2.ActiveRow.Cells["ORD_USE_TP"].Text);
- ht.Add("i6", this.UserInfo.GetUserName().ToString());
- ht.Add("o7", "");
- ccp.ServerName = "UIB.COM.ComDBProcedure";
- ccp.MethodName = "doXmlProcedure";
- ccp.ServerParams = new object[] { "UIB030230_01.CALL", ht };
- this.ExecuteNonQuery(ccp, CoreInvokeType.Internal);
- this.DoQuery();
- ////材质判定
- //CoreClientParam ccp = new CoreClientParam();
- //Hashtable ht = new Hashtable();
- //ht.Add("i1", this.UserInfo.GetUserName());
- //ht.Add("o2", "");
- //ccp.ServerName = "UIB.COM.ComDBProcedure";
- //ccp.MethodName = "doXmlProcedure";
- //ccp.ServerParams = new object[] { "UIB030140_01.CALL", ht };
- //this.ExecuteNonQuery(ccp, CoreInvokeType.Internal);
- //this.DoQuery();
- }
- catch (Exception ex)
- {
- }
- }
- private void ultraGrid1_AfterRowActivate(object sender, EventArgs e)
- {
- try
- {
- if (this.ultraGrid1.ActiveRow == null) return;
- ArrayList al = new ArrayList();
- al.Add("UIB030230_02.SELECT");
- al.Add(this.ultraGrid1.ActiveRow.Cells["COIL_THK"].Text);
- al.Add(this.ultraGrid1.ActiveRow.Cells["COIL_THK"].Text);
- this.dataSet3.Tables[0].Clear();
- this.dataSet2.Tables[0].Clear();
- CoreClientParam ccp = new CoreClientParam();
- ccp.ServerName = "UIB.COM.ComDBQuery";
- ccp.MethodName = "doSimpleQuery";
- ccp.ServerParams = new object[] { al };
- ccp.SourceDataTable = this.dataSet2.Tables[0];
- this.ExecuteQueryToDataTable(ccp, CoreInvokeType.Internal);
- }
- catch (Exception ex)
- {
- }
- }
- private void ultraGrid2_DoubleClick(object sender, EventArgs e)
- {
- }
- //获取标准对应的材质信息
- private void ultraGrid2_AfterRowActivate(object sender, EventArgs e)
- {
- try
- {
- if (this.ultraGrid1.ActiveRow == null) return;
- if (this.ultraGrid2.ActiveRow == null) return;
- ArrayList al = new ArrayList();
- al.Add("UIB030230_03.SELECT");
- al.Add(this.ultraGrid2.ActiveRow.Cells["PRDNM_CD"].Text);
- al.Add(this.ultraGrid2.ActiveRow.Cells["SPEC_ABBSYM"].Text);
- al.Add(this.ultraGrid2.ActiveRow.Cells["SPEC_STL_GRD"].Text);
- al.Add(this.ultraGrid2.ActiveRow.Cells["ORD_USE_TP"].Text);
- al.Add(this.ultraGrid1.ActiveRow.Cells["COIL_THK"].Text);
- al.Add(this.ultraGrid1.ActiveRow.Cells["COIL_THK"].Text);
- this.dataSet3.Tables[0].Clear();
- CoreClientParam ccp = new CoreClientParam();
- ccp.ServerName = "UIB.COM.ComDBQuery";
- ccp.MethodName = "doSimpleQuery";
- ccp.ServerParams = new object[] { al };
- ccp.SourceDataTable = this.dataSet3.Tables[0];
- this.ExecuteQueryToDataTable(ccp, CoreInvokeType.Internal);
- }
- catch (Exception ex)
- {
- }
- }
- }
- }
|