From 8fe5fc7c9e254d8b5c846bd2da8d8fd0f22f1e63 Mon Sep 17 00:00:00 2001
From: lu <99954486@qq.com>
Date: 星期四, 19 十二月 2024 17:45:06 +0800
Subject: [PATCH] 工单之前的细节
---
DevApp/Gs.DevApp/DevFrm/WOM/Frm_Womcaa.Designer.cs | 40 +++++++---
DevApp/Gs.DevApp/DevFrm/WOM/Frm_Womcaa.cs | 158 +++++++++++++++++++--------------------
DevApp/GsDevSolution.sln | 6 -
DevApp/Gs.DevApp/DevFrm/WOM/Frm_Womdaa.cs | 1
DevApp/Gs.DevApp/DevFrm/WOM/Frm_Womdaa.Designer.cs | 18 ++++
5 files changed, 122 insertions(+), 101 deletions(-)
diff --git a/DevApp/Gs.DevApp/DevFrm/WOM/Frm_Womcaa.Designer.cs b/DevApp/Gs.DevApp/DevFrm/WOM/Frm_Womcaa.Designer.cs
index 552958f..b4dc033 100644
--- a/DevApp/Gs.DevApp/DevFrm/WOM/Frm_Womcaa.Designer.cs
+++ b/DevApp/Gs.DevApp/DevFrm/WOM/Frm_Womcaa.Designer.cs
@@ -49,6 +49,7 @@
this.tabMxPage1 = new DevExpress.XtraTab.XtraTabPage();
this.gcMx1 = new DevExpress.XtraGrid.GridControl();
this.gvMx1 = new DevExpress.XtraGrid.Views.Grid.GridView();
+ this.gridColumn6 = new DevExpress.XtraGrid.Columns.GridColumn();
this.gridColumn14 = new DevExpress.XtraGrid.Columns.GridColumn();
this.gridColumn15 = new DevExpress.XtraGrid.Columns.GridColumn();
this.gridColumn16 = new DevExpress.XtraGrid.Columns.GridColumn();
@@ -127,7 +128,7 @@
this.txt_caa021 = new Gs.DevApp.UserControl.UcLookWorkshop();
this.labelControl11 = new DevExpress.XtraEditors.LabelControl();
this.lbGuid = new System.Windows.Forms.Label();
- this.gridColumn6 = new DevExpress.XtraGrid.Columns.GridColumn();
+ this.picCheckBox = new System.Windows.Forms.PictureBox();
this.tabMxPage1.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.gcMx1)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.gvMx1)).BeginInit();
@@ -154,6 +155,7 @@
((System.ComponentModel.ISupportInitialize)(this.tabMx)).BeginInit();
this.tabMx.SuspendLayout();
this.panel1.SuspendLayout();
+ ((System.ComponentModel.ISupportInitialize)(this.picCheckBox)).BeginInit();
this.SuspendLayout();
//
// gvMx1scraprate
@@ -420,10 +422,20 @@
this.gridColumn17});
this.gvMx1.GridControl = this.gcMx1;
this.gvMx1.Name = "gvMx1";
- this.gvMx1.OptionsBehavior.AllowAddRows = DevExpress.Utils.DefaultBoolean.True;
+ this.gvMx1.OptionsBehavior.AllowAddRows = DevExpress.Utils.DefaultBoolean.False;
this.gvMx1.OptionsFind.ShowSearchNavButtons = false;
- this.gvMx1.OptionsView.NewItemRowPosition = DevExpress.XtraGrid.Views.Grid.NewItemRowPosition.Bottom;
+ this.gvMx1.OptionsLayout.Columns.AddNewColumns = false;
this.gvMx1.OptionsView.ShowGroupPanel = false;
+ //
+ // gridColumn6
+ //
+ this.gridColumn6.Caption = "gridColumn6";
+ this.gridColumn6.FieldName = "cab001";
+ this.gridColumn6.MinWidth = 80;
+ this.gridColumn6.Name = "gridColumn6";
+ this.gridColumn6.Visible = true;
+ this.gridColumn6.VisibleIndex = 1;
+ this.gridColumn6.Width = 94;
//
// gridColumn14
//
@@ -1118,6 +1130,7 @@
// toolBarMenu1
//
this.toolBarMenu1.chkParameter = null;
+ this.toolBarMenu1.currentAction = null;
this.toolBarMenu1.Dock = System.Windows.Forms.DockStyle.Top;
this.toolBarMenu1.guidKey = null;
this.toolBarMenu1.isSetBtn = false;
@@ -1288,7 +1301,6 @@
this.xtraTabPage2.Controls.Add(this.tabMx);
this.xtraTabPage2.Controls.Add(this.panel1);
this.xtraTabPage2.Name = "xtraTabPage2";
-
this.xtraTabPage2.Size = new System.Drawing.Size(1126, 570);
this.xtraTabPage2.Text = "鏁版嵁璇︾粏";
//
@@ -1372,21 +1384,23 @@
this.lbGuid.TabIndex = 1;
this.lbGuid.Visible = false;
//
- // gridColumn6
+ // picCheckBox
//
- this.gridColumn6.Caption = "gridColumn6";
- this.gridColumn6.FieldName = "cab001";
- this.gridColumn6.MinWidth = 80;
- this.gridColumn6.Name = "gridColumn6";
- this.gridColumn6.Visible = true;
- this.gridColumn6.VisibleIndex = 1;
- this.gridColumn6.Width = 94;
+ this.picCheckBox.Image = global::Gs.DevApp.Properties.Resources.ico_noCheck;
+ this.picCheckBox.Location = new System.Drawing.Point(1001, 55);
+ this.picCheckBox.Name = "picCheckBox";
+ this.picCheckBox.Size = new System.Drawing.Size(100, 50);
+ this.picCheckBox.SizeMode = System.Windows.Forms.PictureBoxSizeMode.StretchImage;
+ this.picCheckBox.TabIndex = 6;
+ this.picCheckBox.TabStop = false;
+ this.picCheckBox.Visible = false;
//
// Frm_Womcaa
//
this.AutoScaleDimensions = new System.Drawing.SizeF(8F, 18F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(1128, 682);
+ this.Controls.Add(this.picCheckBox);
this.Controls.Add(this.xtraTabControl1);
this.Controls.Add(this.toolBarMenu1);
this.Name = "Frm_Womcaa";
@@ -1417,6 +1431,7 @@
this.tabMx.ResumeLayout(false);
this.panel1.ResumeLayout(false);
this.panel1.PerformLayout();
+ ((System.ComponentModel.ISupportInitialize)(this.picCheckBox)).EndInit();
this.ResumeLayout(false);
}
@@ -1535,5 +1550,6 @@
private DevExpress.XtraGrid.Columns.GridColumn gridColumn4;
private DevExpress.XtraGrid.Columns.GridColumn gridColumn5;
private DevExpress.XtraGrid.Columns.GridColumn gridColumn6;
+ private System.Windows.Forms.PictureBox picCheckBox;
}
}
\ No newline at end of file
diff --git a/DevApp/Gs.DevApp/DevFrm/WOM/Frm_Womcaa.cs b/DevApp/Gs.DevApp/DevFrm/WOM/Frm_Womcaa.cs
index 0065543..07d1103 100644
--- a/DevApp/Gs.DevApp/DevFrm/WOM/Frm_Womcaa.cs
+++ b/DevApp/Gs.DevApp/DevFrm/WOM/Frm_Womcaa.cs
@@ -6,7 +6,6 @@
using System;
using System.Collections.Generic;
using System.Data;
-using System.Drawing;
using System.Threading.Tasks;
using System.Windows.Forms;
@@ -19,35 +18,32 @@
public Frm_Womcaa()
{
InitializeComponent();
- toolBarMenu1.btnEdtClick += ToolBarMenu1_btnEdtClick;
this.toolBarMenu1.btnLoadClick += ToolBarMenu1_btnLoadClick;
this.toolBarMenu1.btnQueryClick += ToolBarMenu1_btnQueryClick;
this.toolBarMenu1.btnJieAnClick += ToolBarMenu1_btnJieAnClick;
this.toolBarMenu1.btnFjieAnClick += ToolBarMenu1_btnFjieAnClick;
-
- Gs.DevApp.ToolBox.UtilityHelper.SetGridViewParameter(gridView1);
Gs.DevApp.ToolBox.UtilityHelper.SetGridViewParameterMx(gvMx1);
+ Gs.DevApp.ToolBox.UtilityHelper.SetGridViewParameter(gridView1, picCheckBox, this, "fstatus", "", (value) =>
+ {
+ Gs.DevApp.ToolBox.UtilityHelper.JumpTab(xtraTabControl1, 0);
+ });
+ Gs.DevApp.ToolBox.UtilityHelper.SetTabParameter(gridView1, xtraTabControl1, pageBar1, (value) =>
+ {
+ getModel(value);
+ }, (value) =>
+ {
+ getPageList(this.pageBar1.CurrentPage);
+ });
getPageList(1);
pageBar1.PagerEvent += PageBar1_PagerEvent;
}
- private void GridView1_ColumnFilterChanged(object sender, EventArgs e)
+ private void GridView1_ColumnFilterChanged(object sender, EventArgs e)
{
_filterList = Gs.DevApp.ToolBox.UtilityHelper.GetDilter(gridView1.Columns);
- Task.Delay(100);
+ Task.Delay(100);
getPageList(1);
}
- /// <summary>
- /// 鍙屽嚮浜嬩欢
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- private void GcMain_MouseDoubleClick(object sender, MouseEventArgs e)
- {
- string rowGuid = Gs.DevApp.ToolBox.UtilityHelper.GetCurrentDoubleRow(gridView1, e, "guid");
- if (!string.IsNullOrEmpty(rowGuid))
- getModel(rowGuid, false, 999);
- }
/// <summary>
/// 鍒嗛〉浜嬩欢
/// </summary>
@@ -91,7 +87,7 @@
private void ToolBarMenu1_btnLoadClick(object sender, EventArgs e)
{
if (xtraTabControl1.SelectedTabPageIndex == 1)
- getModel(lbGuid.Text.Trim(), false, 999);
+ getModel(lbGuid.Text.Trim());
else
{
_filterList.Clear();
@@ -105,21 +101,14 @@
}
}
/// <summary>
- /// 淇敼浜嬩欢
+ /// 缁撴
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
- private void ToolBarMenu1_btnEdtClick(object sender, EventArgs e)
+ /// <exception cref="NotImplementedException"></exception>
+ private void ToolBarMenu1_btnJieAnClick(object sender, EventArgs e)
{
- string rowGuid = "", rowName = "";
- (rowGuid, rowName) = UtilityHelper.GetCurrentRow(xtraTabControl1,
- lbGuid, txt_caa001, gridView1);
- if (string.IsNullOrEmpty(rowGuid))
- {
- MsgHelper.Warning("璇峰厛閫夋嫨浣犺鎿嶄綔鐨勮锛�");
- return;
- }
- getModel(rowGuid, true, 1);
+ _toolCk(1);
}
/// <summary>
/// 鍙嶇粨妗�
@@ -127,62 +116,16 @@
/// <param name="sender"></param>
/// <param name="e"></param>
/// <exception cref="NotImplementedException"></exception>
- private void ToolBarMenu1_btnFjieAnClick(object sender, EventArgs e)
+ private void ToolBarMenu1_btnFjieAnClick(object sender, EventArgs e)
{
-
- }
- /// <summary>
- /// 缁撴
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- /// <exception cref="NotImplementedException"></exception>
- private void ToolBarMenu1_btnJieAnClick(object sender, EventArgs e)
- {
- toolBarMenu1.guidKey = "";
- string rowGuid, rowName;
- (rowGuid, rowName) = UtilityHelper.GetCurrentRow(xtraTabControl1,
- lbGuid, txt_caa001, gridView1);
- toolBarMenu1.guidKey = rowGuid;
- if (string.IsNullOrEmpty(rowGuid))
- {
- MsgHelper.Warning("璇峰厛閫夋嫨浣犺鎿嶄綔鐨勮锛�");
- return;
- }
- if (!MsgHelper.AskQuestion("浣犻�夋嫨浜嗐��" + rowName + "銆戯紝纭畾鎻愪氦妫�楠屽悧锛�"))
- return;
-
- var _obj = new
- {
- guid = rowGuid,
- };
- try
- {
- var strJson = UtilityHelper.HttpPost("",
- _webServiceName + "EditModelSubmit",
- JsonConvert.SerializeObject(_obj));
- var _rtn = UtilityHelper.ReturnToDynamic(strJson);
- MsgHelper.Warning("鎻愮ず锛�" + _rtn.rtnData.outMsg);
- if (_rtn.rtnCode > 0)
- {
- if (xtraTabControl1.SelectedTabPageIndex == 1)
- getModel(lbGuid.Text.Trim(), false, 999);
- else
- getPageList(1);
- }
- }
- catch (Exception ex)
- {
- MsgHelper.Warning("鎻愮ず锛�" + ex.Message);
- }
-
+ _toolCk(0);
}
/// <summary>
///
/// </summary>
/// <param name="curPage">绗嚑椤�</param>
/// <param name="pageSize">姣忛〉鍑犳潯</param>
- private void getPageList(int curPage)
+ private void getPageList(int curPage)
{
var _sbSqlWhere = UtilityHelper.GetSearchWhere(_filterList);
PageQueryModel pgq = new PageQueryModel(curPage, this.pageBar1.RowsCount, "create_date", "asc", "", _sbSqlWhere.ToString());
@@ -218,16 +161,18 @@
{
ToolBox.MsgHelper.Warning("鎻愮ず锛�" + ex.Message);
}
-
+
}
- private void getModel(string strGuid, bool isEdit, int tabIdx)
+ private void getModel(string strGuid)
{
+ bool isEdit = false;
+ if (toolBarMenu1.currentAction == "add") return;
+ if (toolBarMenu1.currentAction == "edit") isEdit = true;
if (string.IsNullOrEmpty(strGuid))
{
ToolBox.MsgHelper.Warning("璇峰厛閫夋嫨浣犺鎿嶄綔鐨勮锛�");
return;
}
- UtilityHelper.JumpToTab(xtraTabControl1, tabIdx);
var _obj = new
{
guid = strGuid,//涓诲缓
@@ -270,5 +215,56 @@
}
}
+ /// <summary>
+ /// 宸ュ叿鏉′簨浠�
+ /// </summary>
+ /// <param name="inFieldValue"></param>
+ private void _toolCk(int _inFieldValue)
+ {
+ string strMsg = "";
+ switch (_inFieldValue)
+ {
+ case 1:
+ strMsg = "缁撴";
+ break;
+ case 0:
+ strMsg = "鍙嶇粨妗�";
+ break;
+ };
+ toolBarMenu1.guidKey = "";
+ string rowGuid, rowName;
+ (rowGuid, rowName) = UtilityHelper.GetCurrentRow(xtraTabControl1, lbGuid, txt_caa001, gridView1, "caa001");
+ if (string.IsNullOrEmpty(rowGuid))
+ {
+ MsgHelper.Warning("璇峰厛閫夋嫨浣犺鎿嶄綔鐨勮锛�");
+ return;
+ }
+ if (!MsgHelper.AskQuestion("浣犻�夋嫨浜嗐��" + rowName + "銆戯紝纭畾" + strMsg + "鍚楋紵"))
+ return;
+ var _obj = new
+ {
+ guid = rowGuid,
+ inFieldValue = _inFieldValue,
+ };
+ try
+ {
+ var strJson = UtilityHelper.HttpPost("",
+ _webServiceName + "EditModelSubmit",
+ JsonConvert.SerializeObject(_obj));
+ var _rtn = UtilityHelper.ReturnToDynamic(strJson);
+ MsgHelper.Warning(_rtn.rtnData.outMsg.ToString());
+ if (_rtn.rtnCode > 0)
+ {
+ if (xtraTabControl1.SelectedTabPageIndex == 1)
+ getModel(lbGuid.Text.Trim());
+ else
+ getPageList(this.pageBar1.CurrentPage);
+ }
+ }
+ catch (Exception ex)
+ {
+ MsgHelper.Warning("鎻愮ず锛�" + ex.Message);
+ }
+ }
}
}
\ No newline at end of file
diff --git a/DevApp/Gs.DevApp/DevFrm/WOM/Frm_Womdaa.Designer.cs b/DevApp/Gs.DevApp/DevFrm/WOM/Frm_Womdaa.Designer.cs
index a753c9f..278be78 100644
--- a/DevApp/Gs.DevApp/DevFrm/WOM/Frm_Womdaa.Designer.cs
+++ b/DevApp/Gs.DevApp/DevFrm/WOM/Frm_Womdaa.Designer.cs
@@ -217,6 +217,7 @@
this.labelControl12 = new DevExpress.XtraEditors.LabelControl();
this.labelControl11 = new DevExpress.XtraEditors.LabelControl();
this.lbGuid = new System.Windows.Forms.Label();
+ this.picCheckBox = new System.Windows.Forms.PictureBox();
this.tabMxPage2.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.gcMx2)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.gvMx2)).BeginInit();
@@ -249,6 +250,7 @@
((System.ComponentModel.ISupportInitialize)(this.textEdit1.Properties)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.txt_iCount_1.Properties)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.txt_psnQty_1.Properties)).BeginInit();
+ ((System.ComponentModel.ISupportInitialize)(this.picCheckBox)).BeginInit();
this.SuspendLayout();
//
// gvMx2suppId
@@ -2426,6 +2428,7 @@
// toolBarMenu1
//
this.toolBarMenu1.chkParameter = null;
+ this.toolBarMenu1.currentAction = null;
this.toolBarMenu1.Dock = System.Windows.Forms.DockStyle.Top;
this.toolBarMenu1.guidKey = null;
this.toolBarMenu1.isSetBtn = false;
@@ -2568,7 +2571,6 @@
this.xtraTabPage2.Controls.Add(this.tabMx);
this.xtraTabPage2.Controls.Add(this.panel1);
this.xtraTabPage2.Name = "xtraTabPage2";
-
this.xtraTabPage2.Size = new System.Drawing.Size(1126, 708);
this.xtraTabPage2.Text = "鏁版嵁璇︾粏";
//
@@ -2709,11 +2711,23 @@
this.lbGuid.TabIndex = 1;
this.lbGuid.Visible = false;
//
+ // picCheckBox
+ //
+ this.picCheckBox.Image = global::Gs.DevApp.Properties.Resources.ico_noCheck;
+ this.picCheckBox.Location = new System.Drawing.Point(999, 55);
+ this.picCheckBox.Name = "picCheckBox";
+ this.picCheckBox.Size = new System.Drawing.Size(100, 50);
+ this.picCheckBox.SizeMode = System.Windows.Forms.PictureBoxSizeMode.StretchImage;
+ this.picCheckBox.TabIndex = 6;
+ this.picCheckBox.TabStop = false;
+ this.picCheckBox.Visible = false;
+ //
// Frm_Womdaa
//
this.AutoScaleDimensions = new System.Drawing.SizeF(8F, 18F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(1128, 820);
+ this.Controls.Add(this.picCheckBox);
this.Controls.Add(this.xtraTabControl1);
this.Controls.Add(this.toolBarMenu1);
this.Name = "Frm_Womdaa";
@@ -2750,6 +2764,7 @@
((System.ComponentModel.ISupportInitialize)(this.textEdit1.Properties)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.txt_iCount_1.Properties)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.txt_psnQty_1.Properties)).EndInit();
+ ((System.ComponentModel.ISupportInitialize)(this.picCheckBox)).EndInit();
this.ResumeLayout(false);
}
@@ -2958,5 +2973,6 @@
private DevExpress.XtraEditors.TextEdit textEdit1;
private DevExpress.XtraTab.XtraTabPage xtraTabPage4;
private DevExpress.XtraGrid.Columns.GridColumn gvMx1Guid;
+ private System.Windows.Forms.PictureBox picCheckBox;
}
}
\ No newline at end of file
diff --git a/DevApp/Gs.DevApp/DevFrm/WOM/Frm_Womdaa.cs b/DevApp/Gs.DevApp/DevFrm/WOM/Frm_Womdaa.cs
index 30c336e..b3ae679 100644
--- a/DevApp/Gs.DevApp/DevFrm/WOM/Frm_Womdaa.cs
+++ b/DevApp/Gs.DevApp/DevFrm/WOM/Frm_Womdaa.cs
@@ -29,7 +29,6 @@
this.toolBarMenu1.btnTzblClick += ToolBarMenu1_btnTzblClick;
this.toolBarMenu1.btnKgClick += ToolBarMenu1_btnKgClick;
this.toolBarMenu1.btnWgClick += ToolBarMenu1_btnWgClick;
-
Gs.DevApp.ToolBox.UtilityHelper.SetGridViewParameter(gridView1);
getPageList(1);
pageBar1.PagerEvent += PageBar1_PagerEvent;
diff --git a/DevApp/GsDevSolution.sln b/DevApp/GsDevSolution.sln
index d6c3cd7..d90da1b 100644
--- a/DevApp/GsDevSolution.sln
+++ b/DevApp/GsDevSolution.sln
@@ -5,8 +5,6 @@
MinimumVisualStudioVersion = 10.0.40219.1
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Gs.DevApp", "Gs.DevApp\Gs.DevApp.csproj", "{A7EB5F78-699E-4514-8905-30842765E673}"
EndProject
-Project("{54435603-DBB4-11D2-8724-00A0C9A8B90C}") = "Gs.Setup", "Gs.Setup\Gs.Setup.vdproj", "{877CD8AF-E72F-46EC-98C9-1AFA7D37CF52}"
-EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
@@ -17,10 +15,6 @@
{A7EB5F78-699E-4514-8905-30842765E673}.Debug|Any CPU.Build.0 = Debug|Any CPU
{A7EB5F78-699E-4514-8905-30842765E673}.Release|Any CPU.ActiveCfg = Release|Any CPU
{A7EB5F78-699E-4514-8905-30842765E673}.Release|Any CPU.Build.0 = Release|Any CPU
- {877CD8AF-E72F-46EC-98C9-1AFA7D37CF52}.Debug|Any CPU.ActiveCfg = Debug
- {877CD8AF-E72F-46EC-98C9-1AFA7D37CF52}.Debug|Any CPU.Build.0 = Debug
- {877CD8AF-E72F-46EC-98C9-1AFA7D37CF52}.Release|Any CPU.ActiveCfg = Release
- {877CD8AF-E72F-46EC-98C9-1AFA7D37CF52}.Release|Any CPU.Build.0 = Release
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
--
Gitblit v1.9.3