From f121cd2803748763d7abb9509e049bd6e62e8844 Mon Sep 17 00:00:00 2001
From: lu <99954486@qq.com>
Date: 星期二, 01 四月 2025 15:00:24 +0800
Subject: [PATCH] 投入
---
DevApp/Gs.DevApp/DevFrm/Work/Frm_Work01.Designer.cs | 152 ++++++++++++++----------------
DevApp/Gs.DevApp/DevFrm/Work/Frm_WorkStart.Designer.cs | 41 ++++----
DevApp/Gs.DevApp/App.config | 4
DevApp/Gs.DevApp/DevFrm/Work/Frm_WorkStart.cs | 20 +++
DevApp/Gs.DevApp/DevFrm/Work/Frm_Work01.cs | 73 +++++++++-----
5 files changed, 158 insertions(+), 132 deletions(-)
diff --git a/DevApp/Gs.DevApp/App.config b/DevApp/Gs.DevApp/App.config
index 729ea9d..673f1fc 100644
--- a/DevApp/Gs.DevApp/App.config
+++ b/DevApp/Gs.DevApp/App.config
@@ -28,8 +28,8 @@
</assemblyBinding>
</runtime>
<appSettings>
- <!--<add key="WebApiUrl" value="http://localhost:5263/" />-->
- <add key="WebApiUrl" value="http://192.168.1.145:81/" />
+ <add key="WebApiUrl" value="http://localhost:5263/" />
+ <!--<add key="WebApiUrl" value="http://192.168.1.145:81/" />-->
<add key="LogPath" value="logs" />
<add key="ProductName" value="骞挎繁绉戞妧 G-MES V2.0" />
<add key="PageSize" value="50" />
diff --git a/DevApp/Gs.DevApp/DevFrm/Work/Frm_Work01.Designer.cs b/DevApp/Gs.DevApp/DevFrm/Work/Frm_Work01.Designer.cs
index 71f3813..24d7bf3 100644
--- a/DevApp/Gs.DevApp/DevFrm/Work/Frm_Work01.Designer.cs
+++ b/DevApp/Gs.DevApp/DevFrm/Work/Frm_Work01.Designer.cs
@@ -29,16 +29,16 @@
private void InitializeComponent()
{
this.components = new System.ComponentModel.Container();
- DevExpress.XtraLayout.ColumnDefinition columnDefinition9 = new DevExpress.XtraLayout.ColumnDefinition();
- DevExpress.XtraLayout.ColumnDefinition columnDefinition10 = new DevExpress.XtraLayout.ColumnDefinition();
- DevExpress.XtraLayout.ColumnDefinition columnDefinition11 = new DevExpress.XtraLayout.ColumnDefinition();
- DevExpress.XtraLayout.ColumnDefinition columnDefinition12 = new DevExpress.XtraLayout.ColumnDefinition();
- DevExpress.XtraLayout.RowDefinition rowDefinition13 = new DevExpress.XtraLayout.RowDefinition();
- DevExpress.XtraLayout.RowDefinition rowDefinition14 = new DevExpress.XtraLayout.RowDefinition();
- DevExpress.XtraLayout.RowDefinition rowDefinition15 = new DevExpress.XtraLayout.RowDefinition();
- DevExpress.XtraLayout.RowDefinition rowDefinition16 = new DevExpress.XtraLayout.RowDefinition();
- DevExpress.XtraLayout.RowDefinition rowDefinition17 = new DevExpress.XtraLayout.RowDefinition();
- DevExpress.XtraLayout.RowDefinition rowDefinition18 = new DevExpress.XtraLayout.RowDefinition();
+ DevExpress.XtraLayout.ColumnDefinition columnDefinition5 = new DevExpress.XtraLayout.ColumnDefinition();
+ DevExpress.XtraLayout.ColumnDefinition columnDefinition6 = new DevExpress.XtraLayout.ColumnDefinition();
+ DevExpress.XtraLayout.ColumnDefinition columnDefinition7 = new DevExpress.XtraLayout.ColumnDefinition();
+ DevExpress.XtraLayout.ColumnDefinition columnDefinition8 = new DevExpress.XtraLayout.ColumnDefinition();
+ DevExpress.XtraLayout.RowDefinition rowDefinition7 = new DevExpress.XtraLayout.RowDefinition();
+ DevExpress.XtraLayout.RowDefinition rowDefinition8 = new DevExpress.XtraLayout.RowDefinition();
+ DevExpress.XtraLayout.RowDefinition rowDefinition9 = new DevExpress.XtraLayout.RowDefinition();
+ DevExpress.XtraLayout.RowDefinition rowDefinition10 = new DevExpress.XtraLayout.RowDefinition();
+ DevExpress.XtraLayout.RowDefinition rowDefinition11 = new DevExpress.XtraLayout.RowDefinition();
+ DevExpress.XtraLayout.RowDefinition rowDefinition12 = new DevExpress.XtraLayout.RowDefinition();
this.splitMx1 = new DevExpress.XtraEditors.SplitContainerControl();
this.splitTop1 = new DevExpress.XtraEditors.SplitContainerControl();
this.layTop1 = new DevExpress.XtraLayout.LayoutControl();
@@ -100,10 +100,8 @@
this.gcMx1 = new DevExpress.XtraGrid.GridControl();
this.gvMx1 = new DevExpress.XtraGrid.Views.Grid.GridView();
this.gridColumn12 = new DevExpress.XtraGrid.Columns.GridColumn();
- this.gridColumn11 = new DevExpress.XtraGrid.Columns.GridColumn();
this.gvMx2status = new DevExpress.XtraGrid.Columns.GridColumn();
this.gvMx2pbillNo = new DevExpress.XtraGrid.Columns.GridColumn();
- this.gvMx2workLine = new DevExpress.XtraGrid.Columns.GridColumn();
this.gvMx2itemNo = new DevExpress.XtraGrid.Columns.GridColumn();
this.gridColumn5 = new DevExpress.XtraGrid.Columns.GridColumn();
this.gridColumn6 = new DevExpress.XtraGrid.Columns.GridColumn();
@@ -274,6 +272,7 @@
//
this.txt_gdbh.Location = new System.Drawing.Point(84, 12);
this.txt_gdbh.Name = "txt_gdbh";
+ this.txt_gdbh.Properties.ReadOnly = true;
this.txt_gdbh.Size = new System.Drawing.Size(126, 24);
this.txt_gdbh.StyleController = this.layTop1;
this.txt_gdbh.TabIndex = 4;
@@ -282,6 +281,7 @@
//
this.txt_gx.Location = new System.Drawing.Point(84, 40);
this.txt_gx.Name = "txt_gx";
+ this.txt_gx.Properties.ReadOnly = true;
this.txt_gx.Size = new System.Drawing.Size(126, 24);
this.txt_gx.StyleController = this.layTop1;
this.txt_gx.TabIndex = 5;
@@ -290,6 +290,7 @@
//
this.txt_czz.Location = new System.Drawing.Point(84, 68);
this.txt_czz.Name = "txt_czz";
+ this.txt_czz.Properties.ReadOnly = true;
this.txt_czz.Size = new System.Drawing.Size(126, 24);
this.txt_czz.StyleController = this.layTop1;
this.txt_czz.TabIndex = 6;
@@ -306,6 +307,7 @@
//
this.txt_currentBarCode.Location = new System.Drawing.Point(84, 124);
this.txt_currentBarCode.Name = "txt_currentBarCode";
+ this.txt_currentBarCode.Properties.ReadOnly = true;
this.txt_currentBarCode.Size = new System.Drawing.Size(328, 24);
this.txt_currentBarCode.StyleController = this.layTop1;
this.txt_currentBarCode.TabIndex = 8;
@@ -322,6 +324,7 @@
//
this.txt_itemNo.Location = new System.Drawing.Point(286, 12);
this.txt_itemNo.Name = "txt_itemNo";
+ this.txt_itemNo.Properties.ReadOnly = true;
this.txt_itemNo.Size = new System.Drawing.Size(126, 24);
this.txt_itemNo.StyleController = this.layTop1;
this.txt_itemNo.TabIndex = 10;
@@ -330,6 +333,7 @@
//
this.txt_bc.Location = new System.Drawing.Point(286, 40);
this.txt_bc.Name = "txt_bc";
+ this.txt_bc.Properties.ReadOnly = true;
this.txt_bc.Size = new System.Drawing.Size(126, 24);
this.txt_bc.StyleController = this.layTop1;
this.txt_bc.TabIndex = 11;
@@ -338,6 +342,7 @@
//
this.txt_gw.Location = new System.Drawing.Point(286, 68);
this.txt_gw.Name = "txt_gw";
+ this.txt_gw.Properties.ReadOnly = true;
this.txt_gw.Size = new System.Drawing.Size(126, 24);
this.txt_gw.StyleController = this.layTop1;
this.txt_gw.TabIndex = 12;
@@ -346,6 +351,7 @@
//
this.txt_itemName.Location = new System.Drawing.Point(488, 12);
this.txt_itemName.Name = "txt_itemName";
+ this.txt_itemName.Properties.ReadOnly = true;
this.txt_itemName.Size = new System.Drawing.Size(126, 24);
this.txt_itemName.StyleController = this.layTop1;
this.txt_itemName.TabIndex = 13;
@@ -354,6 +360,7 @@
//
this.txt_itemModel.Location = new System.Drawing.Point(690, 12);
this.txt_itemModel.Name = "txt_itemModel";
+ this.txt_itemModel.Properties.ReadOnly = true;
this.txt_itemModel.Size = new System.Drawing.Size(126, 24);
this.txt_itemModel.StyleController = this.layTop1;
this.txt_itemModel.TabIndex = 14;
@@ -362,6 +369,7 @@
//
this.txt_sbNo.Location = new System.Drawing.Point(488, 68);
this.txt_sbNo.Name = "txt_sbNo";
+ this.txt_sbNo.Properties.ReadOnly = true;
this.txt_sbNo.Size = new System.Drawing.Size(126, 24);
this.txt_sbNo.StyleController = this.layTop1;
this.txt_sbNo.TabIndex = 15;
@@ -370,6 +378,7 @@
//
this.txt_sjXt.Location = new System.Drawing.Point(488, 40);
this.txt_sjXt.Name = "txt_sjXt";
+ this.txt_sjXt.Properties.ReadOnly = true;
this.txt_sjXt.Size = new System.Drawing.Size(126, 24);
this.txt_sjXt.StyleController = this.layTop1;
this.txt_sjXt.TabIndex = 16;
@@ -378,6 +387,7 @@
//
this.txt_yjDate.Location = new System.Drawing.Point(690, 40);
this.txt_yjDate.Name = "txt_yjDate";
+ this.txt_yjDate.Properties.ReadOnly = true;
this.txt_yjDate.Size = new System.Drawing.Size(126, 24);
this.txt_yjDate.StyleController = this.layTop1;
this.txt_yjDate.TabIndex = 17;
@@ -386,6 +396,7 @@
//
this.txt_sjDate.Location = new System.Drawing.Point(690, 68);
this.txt_sjDate.Name = "txt_sjDate";
+ this.txt_sjDate.Properties.ReadOnly = true;
this.txt_sjDate.Size = new System.Drawing.Size(126, 24);
this.txt_sjDate.StyleController = this.layTop1;
this.txt_sjDate.TabIndex = 18;
@@ -436,38 +447,38 @@
this.layoutControlItem11});
this.Root.LayoutMode = DevExpress.XtraLayout.Utils.LayoutMode.Table;
this.Root.Name = "Root";
- columnDefinition9.SizeType = System.Windows.Forms.SizeType.Percent;
- columnDefinition9.Width = 100D;
- columnDefinition10.SizeType = System.Windows.Forms.SizeType.Percent;
- columnDefinition10.Width = 100D;
- columnDefinition11.SizeType = System.Windows.Forms.SizeType.Percent;
- columnDefinition11.Width = 100D;
- columnDefinition12.SizeType = System.Windows.Forms.SizeType.Percent;
- columnDefinition12.Width = 100D;
+ columnDefinition5.SizeType = System.Windows.Forms.SizeType.Percent;
+ columnDefinition5.Width = 100D;
+ columnDefinition6.SizeType = System.Windows.Forms.SizeType.Percent;
+ columnDefinition6.Width = 100D;
+ columnDefinition7.SizeType = System.Windows.Forms.SizeType.Percent;
+ columnDefinition7.Width = 100D;
+ columnDefinition8.SizeType = System.Windows.Forms.SizeType.Percent;
+ columnDefinition8.Width = 100D;
this.Root.OptionsTableLayoutGroup.ColumnDefinitions.AddRange(new DevExpress.XtraLayout.ColumnDefinition[] {
- columnDefinition9,
- columnDefinition10,
- columnDefinition11,
- columnDefinition12});
- rowDefinition13.Height = 100D;
- rowDefinition13.SizeType = System.Windows.Forms.SizeType.Percent;
- rowDefinition14.Height = 100D;
- rowDefinition14.SizeType = System.Windows.Forms.SizeType.Percent;
- rowDefinition15.Height = 100D;
- rowDefinition15.SizeType = System.Windows.Forms.SizeType.Percent;
- rowDefinition16.Height = 100D;
- rowDefinition16.SizeType = System.Windows.Forms.SizeType.Percent;
- rowDefinition17.Height = 100D;
- rowDefinition17.SizeType = System.Windows.Forms.SizeType.Percent;
- rowDefinition18.Height = 100D;
- rowDefinition18.SizeType = System.Windows.Forms.SizeType.Percent;
+ columnDefinition5,
+ columnDefinition6,
+ columnDefinition7,
+ columnDefinition8});
+ rowDefinition7.Height = 100D;
+ rowDefinition7.SizeType = System.Windows.Forms.SizeType.Percent;
+ rowDefinition8.Height = 100D;
+ rowDefinition8.SizeType = System.Windows.Forms.SizeType.Percent;
+ rowDefinition9.Height = 100D;
+ rowDefinition9.SizeType = System.Windows.Forms.SizeType.Percent;
+ rowDefinition10.Height = 100D;
+ rowDefinition10.SizeType = System.Windows.Forms.SizeType.Percent;
+ rowDefinition11.Height = 100D;
+ rowDefinition11.SizeType = System.Windows.Forms.SizeType.Percent;
+ rowDefinition12.Height = 100D;
+ rowDefinition12.SizeType = System.Windows.Forms.SizeType.Percent;
this.Root.OptionsTableLayoutGroup.RowDefinitions.AddRange(new DevExpress.XtraLayout.RowDefinition[] {
- rowDefinition13,
- rowDefinition14,
- rowDefinition15,
- rowDefinition16,
- rowDefinition17,
- rowDefinition18});
+ rowDefinition7,
+ rowDefinition8,
+ rowDefinition9,
+ rowDefinition10,
+ rowDefinition11,
+ rowDefinition12});
this.Root.Size = new System.Drawing.Size(828, 191);
this.Root.TextVisible = false;
//
@@ -508,7 +519,7 @@
this.layoutControlItem4.OptionsTableLayoutItem.ColumnSpan = 2;
this.layoutControlItem4.OptionsTableLayoutItem.RowIndex = 3;
this.layoutControlItem4.Size = new System.Drawing.Size(404, 28);
- this.layoutControlItem4.Text = "鎵撴潯鐮�";
+ this.layoutControlItem4.Text = "鎵潯鐮�";
this.layoutControlItem4.TextSize = new System.Drawing.Size(60, 18);
//
// layoutControlItem7
@@ -864,10 +875,8 @@
this.gvMx1.Appearance.Row.Options.UseFont = true;
this.gvMx1.Columns.AddRange(new DevExpress.XtraGrid.Columns.GridColumn[] {
this.gridColumn12,
- this.gridColumn11,
this.gvMx2status,
this.gvMx2pbillNo,
- this.gvMx2workLine,
this.gvMx2itemNo,
this.gridColumn5,
this.gridColumn6,
@@ -892,22 +901,12 @@
this.gridColumn12.OptionsColumn.ReadOnly = true;
this.gridColumn12.Width = 94;
//
- // gridColumn11
- //
- this.gridColumn11.Caption = "aboutGuid";
- this.gridColumn11.FieldName = "aboutGuid";
- this.gridColumn11.MinWidth = 25;
- this.gridColumn11.Name = "gridColumn11";
- this.gridColumn11.OptionsColumn.ReadOnly = true;
- this.gridColumn11.Width = 94;
- //
// gvMx2status
//
this.gvMx2status.AppearanceCell.Options.UseFont = true;
this.gvMx2status.Caption = "宸ュ崟缂栧彿";
- this.gvMx2status.FieldName = "status";
- this.gvMx2status.MaxWidth = 50;
- this.gvMx2status.MinWidth = 50;
+ this.gvMx2status.FieldName = "gdbh";
+ this.gvMx2status.MinWidth = 10;
this.gvMx2status.Name = "gvMx2status";
this.gvMx2status.OptionsColumn.ReadOnly = true;
this.gvMx2status.Tag = "query_a.status";
@@ -919,25 +918,13 @@
//
this.gvMx2pbillNo.AppearanceCell.Options.UseFont = true;
this.gvMx2pbillNo.Caption = "杩芥函鐮�";
- this.gvMx2pbillNo.FieldName = "pbillNo";
+ this.gvMx2pbillNo.FieldName = "barCode";
this.gvMx2pbillNo.Name = "gvMx2pbillNo";
this.gvMx2pbillNo.OptionsColumn.ReadOnly = true;
this.gvMx2pbillNo.Tag = "query_a.pbill_no";
this.gvMx2pbillNo.Visible = true;
this.gvMx2pbillNo.VisibleIndex = 1;
this.gvMx2pbillNo.Width = 94;
- //
- // gvMx2workLine
- //
- this.gvMx2workLine.AppearanceCell.Options.UseFont = true;
- this.gvMx2workLine.Caption = "鐗╂枡鏉$爜";
- this.gvMx2workLine.FieldName = "workLine";
- this.gvMx2workLine.Name = "gvMx2workLine";
- this.gvMx2workLine.OptionsColumn.ReadOnly = true;
- this.gvMx2workLine.Tag = "query_a.work_line";
- this.gvMx2workLine.Visible = true;
- this.gvMx2workLine.VisibleIndex = 2;
- this.gvMx2workLine.Width = 94;
//
// gvMx2itemNo
//
@@ -948,7 +935,7 @@
this.gvMx2itemNo.OptionsColumn.ReadOnly = true;
this.gvMx2itemNo.Tag = "query_a.item_no";
this.gvMx2itemNo.Visible = true;
- this.gvMx2itemNo.VisibleIndex = 3;
+ this.gvMx2itemNo.VisibleIndex = 2;
this.gvMx2itemNo.Width = 94;
//
// gridColumn5
@@ -958,7 +945,7 @@
this.gridColumn5.Name = "gridColumn5";
this.gridColumn5.OptionsColumn.ReadOnly = true;
this.gridColumn5.Visible = true;
- this.gridColumn5.VisibleIndex = 4;
+ this.gridColumn5.VisibleIndex = 3;
this.gridColumn5.Width = 94;
//
// gridColumn6
@@ -968,46 +955,49 @@
this.gridColumn6.Name = "gridColumn6";
this.gridColumn6.OptionsColumn.ReadOnly = true;
this.gridColumn6.Visible = true;
- this.gridColumn6.VisibleIndex = 5;
+ this.gridColumn6.VisibleIndex = 4;
this.gridColumn6.Width = 94;
//
// gridColumn3
//
this.gridColumn3.Caption = "鏁伴噺";
+ this.gridColumn3.FieldName = "quantity";
this.gridColumn3.MinWidth = 25;
this.gridColumn3.Name = "gridColumn3";
this.gridColumn3.Visible = true;
- this.gridColumn3.VisibleIndex = 7;
+ this.gridColumn3.VisibleIndex = 6;
this.gridColumn3.Width = 94;
//
// gvMx2tlQty
//
this.gvMx2tlQty.AppearanceCell.Options.UseFont = true;
this.gvMx2tlQty.Caption = "鍗曚綅";
- this.gvMx2tlQty.FieldName = "tlQty";
+ this.gvMx2tlQty.FieldName = "dwName";
this.gvMx2tlQty.Name = "gvMx2tlQty";
this.gvMx2tlQty.OptionsColumn.ReadOnly = true;
this.gvMx2tlQty.Tag = "query_a.tl_qty";
this.gvMx2tlQty.Visible = true;
- this.gvMx2tlQty.VisibleIndex = 6;
+ this.gvMx2tlQty.VisibleIndex = 5;
this.gvMx2tlQty.Width = 94;
//
// gridColumn2
//
this.gridColumn2.Caption = "宸ュ簭";
+ this.gridColumn2.FieldName = "processNo";
this.gridColumn2.MinWidth = 25;
this.gridColumn2.Name = "gridColumn2";
this.gridColumn2.Visible = true;
- this.gridColumn2.VisibleIndex = 8;
+ this.gridColumn2.VisibleIndex = 7;
this.gridColumn2.Width = 94;
//
// gridColumn1
//
this.gridColumn1.Caption = "澶囨敞";
+ this.gridColumn1.FieldName = "remark";
this.gridColumn1.MinWidth = 25;
this.gridColumn1.Name = "gridColumn1";
this.gridColumn1.Visible = true;
- this.gridColumn1.VisibleIndex = 9;
+ this.gridColumn1.VisibleIndex = 8;
this.gridColumn1.Width = 94;
//
// gridColumn14
@@ -1017,7 +1007,7 @@
this.gridColumn14.MinWidth = 25;
this.gridColumn14.Name = "gridColumn14";
this.gridColumn14.Visible = true;
- this.gridColumn14.VisibleIndex = 10;
+ this.gridColumn14.VisibleIndex = 9;
this.gridColumn14.Width = 94;
//
// gridColumn15
@@ -1027,7 +1017,7 @@
this.gridColumn15.MinWidth = 25;
this.gridColumn15.Name = "gridColumn15";
this.gridColumn15.Visible = true;
- this.gridColumn15.VisibleIndex = 11;
+ this.gridColumn15.VisibleIndex = 10;
this.gridColumn15.Width = 94;
//
// tabMxPage2
@@ -1296,10 +1286,8 @@
private DevExpress.XtraGrid.GridControl gcMx1;
private DevExpress.XtraGrid.Views.Grid.GridView gvMx1;
private DevExpress.XtraGrid.Columns.GridColumn gridColumn12;
- private DevExpress.XtraGrid.Columns.GridColumn gridColumn11;
private DevExpress.XtraGrid.Columns.GridColumn gvMx2status;
private DevExpress.XtraGrid.Columns.GridColumn gvMx2pbillNo;
- private DevExpress.XtraGrid.Columns.GridColumn gvMx2workLine;
private DevExpress.XtraGrid.Columns.GridColumn gvMx2itemNo;
private DevExpress.XtraGrid.Columns.GridColumn gridColumn5;
private DevExpress.XtraGrid.Columns.GridColumn gridColumn6;
diff --git a/DevApp/Gs.DevApp/DevFrm/Work/Frm_Work01.cs b/DevApp/Gs.DevApp/DevFrm/Work/Frm_Work01.cs
index 2b1f46d..9e75b37 100644
--- a/DevApp/Gs.DevApp/DevFrm/Work/Frm_Work01.cs
+++ b/DevApp/Gs.DevApp/DevFrm/Work/Frm_Work01.cs
@@ -1,18 +1,13 @@
-锘縰sing DevExpress.Utils.DirectXPaint;
-using DevExpress.XtraBars.Alerter;
+锘縰sing DevExpress.XtraBars.Alerter;
+using DevExpress.XtraBars.ToastNotifications;
using DevExpress.XtraEditors;
using Gs.DevApp.Entity;
using Gs.DevApp.ToolBox;
using Newtonsoft.Json;
using Newtonsoft.Json.Linq;
using System;
-using System.Collections.Generic;
-using System.ComponentModel;
using System.Data;
using System.Drawing;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
using System.Windows.Forms;
namespace Gs.DevApp.DevFrm.Work
@@ -20,22 +15,38 @@
public partial class Frm_Work01 : DevExpress.XtraEditors.XtraForm
{
string _webServiceName = "WorkCollect/";
- public Frm_Work01()
+
+ string fGx = "";
+ string fBc = "";
+ public Frm_Work01(string _fGx, string _fBc)
{
InitializeComponent();
+ this.fGx = _fGx;
+ this.fBc = _fBc;
+ txt_gx.Text = fGx;
+ txt_bc.Text = fBc;
txt_barCode.KeyDown += (s, e) =>
{
- if (e.KeyCode == Keys.Enter) { getModel(); };
+ if (e.KeyCode == Keys.Enter) { getModel("", ""); };
+ };
+ btnGood.Click += (s, e) =>
+ {
+ getModel("", "鈭�");
+ };
+ btnBad.Click += (s, e) => {
+ getModel("", "脳");
};
}
- private void getModel()
+ /// <summary>
+ ///
+ /// </summary>
+ /// <param name="_checkVal">妫�娴嬪��</param>
+ /// <param name="_checkResult">妫�娴嬬粨鏋�</param>
+ private void getModel(string _checkVal, string _checkResult)
{
- string _barCode =txt_barCode.Text.Trim();
- //string _guid = "";
+ string _barCode = txt_barCode.Text.Trim();
string _inBz = ""; ; //澶囨敞
- string _checkVal = ""; ; //妫�娴嬪��
- string _checkResult = ""; ; //妫�娴嬬粨鏋�
if (string.IsNullOrEmpty(_barCode))
{
ToolBox.MsgHelper.ShowError("璇峰厛鎵爜锛�");
@@ -43,11 +54,13 @@
}
var _obj = new
{
- // guid = _guid,
barCode = _barCode,
inBz = _inBz,
checkVal = _checkVal,
checkResult = _checkResult,
+ processNo = txt_gx.Text.Trim(),//宸ュ簭
+ banCi = txt_bc.Text.Trim(),//鐝
+ gongWei = txt_gw.Text.Trim(),//宸ヤ綅
};
try
{
@@ -56,6 +69,13 @@
if (_rtn.rtnCode > 0)
{
dynamic dy = _rtn.rtnData;
+ txt_gdbh.Text = dy.gdbh;
+ txt_itemNo.Text = dy.itemNo;
+ txt_itemName.Text = dy.itemName;
+ txt_itemModel.Text = dy.itemModel;
+ txt_sjXt.Text = dy.sjXt;
+ txt_sjDate.Text = dy.sjDate;
+ txt_yjDate.Text = dy.yjDate;
JObject _job = JObject.Parse(strJson);
JArray array = new JArray();
foreach (var a in _job["rtnData"]["list"])
@@ -94,22 +114,25 @@
Gs.DevApp.ToolBox.UtilityHelper.SetDefaultTable(gcMx2, gvMx2);
}
string _msg = _rtn.rtnMsg;
- //璁剧疆鍗曠獥鍙e嚭鐜板脊鍑虹殑閫熷害
- this.alertControl1.FormDisplaySpeed = DevExpress.XtraBars.Alerter.AlertFormDisplaySpeed.Fast;
- //璁剧疆鏄剧ず澶氬皯鏃堕棿绐楀彛浼氳嚜鍔ㄥ叧闂� 浠ユ绉掍负鍗曚綅
- this.alertControl1.AutoFormDelay = 3000;
- //璁剧疆鎻愬嚭绐楀彛鐨勬樉绀虹殑浣嶇疆
- this.alertControl1.FormLocation = DevExpress.XtraBars.Alerter.AlertFormLocation.BottomRight;
- this.alertControl1.Show(this, "鎻愮ず!", _msg);
-
+ if (!string.IsNullOrEmpty(_msg))
+ {
+ //璁剧疆鍗曠獥鍙e嚭鐜板脊鍑虹殑閫熷害
+ this.alertControl1.FormDisplaySpeed = DevExpress.XtraBars.Alerter.AlertFormDisplaySpeed.Fast;
+ //璁剧疆鏄剧ず澶氬皯鏃堕棿绐楀彛浼氳嚜鍔ㄥ叧闂� 浠ユ绉掍负鍗曚綅
+ this.alertControl1.AutoFormDelay = 3000;
+ //璁剧疆鎻愬嚭绐楀彛鐨勬樉绀虹殑浣嶇疆
+ this.alertControl1.FormLocation = DevExpress.XtraBars.Alerter.AlertFormLocation.BottomLeft;
+ this.alertControl1.Show(this, "鎻愮ず!", _msg);
+ };
}
else
- ToolBox.MsgHelper.Warning("鎻愮ず锛�" + _rtn.rtnMsg);
+ ToolBox.MsgHelper.ShowError("鎻愮ず锛�" + _rtn.rtnMsg);
}
catch (Exception ex)
{
- ToolBox.MsgHelper.Warning("鎻愮ず锛�" + ex.Message);
+ ToolBox.MsgHelper.ShowError("鎻愮ず锛�" + ex.Message);
}
}
}
+
}
\ No newline at end of file
diff --git a/DevApp/Gs.DevApp/DevFrm/Work/Frm_WorkStart.Designer.cs b/DevApp/Gs.DevApp/DevFrm/Work/Frm_WorkStart.Designer.cs
index 9b8e92b..4c0e27e 100644
--- a/DevApp/Gs.DevApp/DevFrm/Work/Frm_WorkStart.Designer.cs
+++ b/DevApp/Gs.DevApp/DevFrm/Work/Frm_WorkStart.Designer.cs
@@ -29,11 +29,11 @@
private void InitializeComponent()
{
this.panelControl1 = new DevExpress.XtraEditors.PanelControl();
- this.label2 = new System.Windows.Forms.Label();
- this.label1 = new System.Windows.Forms.Label();
this.btnLogin = new DevExpress.XtraEditors.SimpleButton();
this.txt_gx = new DevExpress.XtraEditors.ComboBoxEdit();
+ this.label2 = new System.Windows.Forms.Label();
this.txt_bc = new DevExpress.XtraEditors.ComboBoxEdit();
+ this.label1 = new System.Windows.Forms.Label();
((System.ComponentModel.ISupportInitialize)(this.panelControl1)).BeginInit();
this.panelControl1.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.txt_gx.Properties)).BeginInit();
@@ -54,24 +54,6 @@
this.panelControl1.Name = "panelControl1";
this.panelControl1.Size = new System.Drawing.Size(280, 249);
this.panelControl1.TabIndex = 0;
- //
- // label2
- //
- this.label2.AutoSize = true;
- this.label2.Location = new System.Drawing.Point(45, 99);
- this.label2.Name = "label2";
- this.label2.Size = new System.Drawing.Size(38, 18);
- this.label2.TabIndex = 2;
- this.label2.Text = "宸ュ簭";
- //
- // label1
- //
- this.label1.AutoSize = true;
- this.label1.Location = new System.Drawing.Point(45, 35);
- this.label1.Name = "label1";
- this.label1.Size = new System.Drawing.Size(38, 18);
- this.label1.TabIndex = 0;
- this.label1.Text = "鐝";
//
// btnLogin
//
@@ -96,6 +78,15 @@
this.txt_gx.Size = new System.Drawing.Size(125, 24);
this.txt_gx.TabIndex = 3;
//
+ // label2
+ //
+ this.label2.AutoSize = true;
+ this.label2.Location = new System.Drawing.Point(45, 99);
+ this.label2.Name = "label2";
+ this.label2.Size = new System.Drawing.Size(38, 18);
+ this.label2.TabIndex = 2;
+ this.label2.Text = "宸ュ簭";
+ //
// txt_bc
//
this.txt_bc.EditValue = "鐧界彮";
@@ -105,12 +96,22 @@
this.txt_bc.Properties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] {
new DevExpress.XtraEditors.Controls.EditorButton(DevExpress.XtraEditors.Controls.ButtonPredefines.Combo)});
this.txt_bc.Properties.Items.AddRange(new object[] {
+ "-璇烽�夋嫨-",
"鐧界彮",
"澶滅彮"});
this.txt_bc.Properties.TextEditStyle = DevExpress.XtraEditors.Controls.TextEditStyles.DisableTextEditor;
this.txt_bc.Size = new System.Drawing.Size(125, 24);
this.txt_bc.TabIndex = 1;
//
+ // label1
+ //
+ this.label1.AutoSize = true;
+ this.label1.Location = new System.Drawing.Point(45, 35);
+ this.label1.Name = "label1";
+ this.label1.Size = new System.Drawing.Size(38, 18);
+ this.label1.TabIndex = 0;
+ this.label1.Text = "鐝";
+ //
// Frm_WorkStart
//
this.AutoScaleDimensions = new System.Drawing.SizeF(8F, 18F);
diff --git a/DevApp/Gs.DevApp/DevFrm/Work/Frm_WorkStart.cs b/DevApp/Gs.DevApp/DevFrm/Work/Frm_WorkStart.cs
index 51ec7ea..bebbcb3 100644
--- a/DevApp/Gs.DevApp/DevFrm/Work/Frm_WorkStart.cs
+++ b/DevApp/Gs.DevApp/DevFrm/Work/Frm_WorkStart.cs
@@ -19,14 +19,28 @@
public Frm_WorkStart()
{
InitializeComponent();
-
+
_getListJyxm();
btnLogin.Click += BtnLogin_Click;
}
private void BtnLogin_Click(object sender, EventArgs e)
{
- Frm_Work01 frm = new Frm_Work01();
+ if (txt_bc.SelectedIndex <= 0)
+ {
+ txt_bc.Focus();
+ Gs.DevApp.ToolBox.MsgHelper.ShowInformation("璇烽�夋嫨鐝锛�");
+ return;
+ }
+ if (txt_gx.SelectedIndex <= 0)
+ {
+ txt_gx.Focus();
+ Gs.DevApp.ToolBox.MsgHelper.ShowInformation("璇烽�夋嫨宸ュ簭锛�");
+ return;
+ }
+ string fGx = txt_gx.Text.Trim();
+ string fBc = txt_bc.Text.Trim();
+ Frm_Work01 frm = new Frm_Work01(fGx, fBc);
frm.ShowDialog();
}
@@ -46,7 +60,7 @@
txt_gx.Properties.Items.Add("-璇烽�夋嫨-");
foreach (DataRow dr in dt.Rows)
{
- txt_gx.Properties.Items.Add(dr["processNo"].ToString()+":"+ dr["processName"].ToString());
+ txt_gx.Properties.Items.Add(dr["processNo"].ToString() + ":" + dr["processName"].ToString());
}
txt_gx.Focus();
txt_gx.SelectedIndex = 0;
--
Gitblit v1.9.3