| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384 |
- 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 System.Collections;
- using Core.Mes.Client.Comm.Control;
- using Pur.require_plan;
- namespace Pur.ck
- {
- public partial class frmReportJl : FrmBase
- {
- public frmReportJl()
- {
- InitializeComponent();
- }
- public override void ToolBar_Click(object sender, string ToolbarKey)
- {
- switch (ToolbarKey)
- {
- case "Query":
- {
- dataTable3.Rows.Clear();
- getJLData();
- }
- break;
- }
- }
- /// <summary>
- /// 获取计量数据
- /// </summary>
- private void getJLData()
- {
- this.Cursor = Cursors.WaitCursor;//等待
- Hashtable ht = new Hashtable();
- //ht.Add("orderno", "SH16090604001");//ugr.Cells["DELIVERYSUBLINESQE"].Value.ToString());
- //ht.Add("ordernos", new ArrayList());//ugr.Cells["DELIVERYSUBLINESQE"].Value.ToString());
- //ht.Add("carno", "津AG7061");
- //ht.Add("icno", "2E2568AE");
- if (chkMat.Checked)
- {
- ht.Add("materialcode", txtItemCode.Text);
- }
- if (chkSupp.Checked)
- {
- ht.Add("sourcecode", txtSuppcode.Text);
- }
- if (chkMatName.Checked)
- {
- ht.Add("materialname", txtItemName.Text);
- }
- if (chkSuppName.Checked)
- {
- ht.Add("sourcename", txtSuppName.Text);
- }
- if (chkOrderId.Checked)
- {
- ht.Add("orderno", txtOrderId.Text);
- }
- //ht.Add("sourcename", "葛洲坝兴业包头再生资源有限公司");
- //ht.Add("matchid", "42816062700050");
- ht.Add("suttletime", ((DateTime)txt_CreateTimeStart.Value));//净重时间开始
- ht.Add("taretime", ((DateTime)txt_CreateTimeEnd.Value));//净重时间结束
- DataTable dt = null;
- try
- {
- dt = this.GetJsonService().execute<DataTable>("com.hnshituo.pur.utils.service.UtilsService", "readData", new object[] { ht });
- }
- catch (System.Exception e)
- {
- MessageBox.Show(e.Message);
- }
- GridHelper.CopyDataToDatatable(dt, dataTable3, true);
- comm.RefreshAndAutoSizeExceptColumns(ultraGrid4);
- this.Cursor = Cursors.Default;//鼠标状态恢复正常
- }
- }
- }
|