From 1f412341cf39655fe47318b20c23bf4de8dc8717 Mon Sep 17 00:00:00 2001
From: lu <123456>
Date: 星期五, 31 十月 2025 15:56:07 +0800
Subject: [PATCH] 完结功能
---
DevApp/Gs.DevApp/DevFrm/Ck/UcBlcl.cs | 97 +++++++++++++++++++++++++++---------------------
1 files changed, 54 insertions(+), 43 deletions(-)
diff --git a/DevApp/Gs.DevApp/DevFrm/Ck/UcBlcl.cs b/DevApp/Gs.DevApp/DevFrm/Ck/UcBlcl.cs
index 9e449e6..b3928b9 100644
--- a/DevApp/Gs.DevApp/DevFrm/Ck/UcBlcl.cs
+++ b/DevApp/Gs.DevApp/DevFrm/Ck/UcBlcl.cs
@@ -7,6 +7,7 @@
using System;
using System.Collections.Generic;
using System.Data;
+using System.Linq;
using System.Threading.Tasks;
using System.Windows.Forms;
@@ -39,6 +40,7 @@
toolBarMenu1.btnChkClick += ToolBarMenu1_btnChkClick;
toolBarMenu1.btnFChkClick += ToolBarMenu1_btnFChkClick;
toolBarMenu1.btnLogClick += ToolBarMenu1_btnLogClick;
+ toolBarMenu1.btnWjClick += ToolBarMenu1_btnWjClick;
this.toolBarMenu1.getXmlConfig();
Form parentForm = this.FindForm();
Gs.DevApp.ToolBox.UtilityHelper.SetGridViewParameterMx(gvMx1);
@@ -71,39 +73,16 @@
txt_bl014.Text = txt_aboutGuid.GetPrdName();
txt_bl015.Text = txt_aboutGuid.GetPrdModel();
txt_dptName.Text = txt_aboutGuid.GetWorkName();
- txt_bl012.Text = txt_aboutGuid.GetWorkXb();
+ txt_lineName.Text = txt_aboutGuid.GetWorkXb();
txt_bl013.Text = txt_aboutGuid.GetRwd();
txt_tldh.Text = txt_aboutGuid.GetTldh();
- var _obj = new
- {
- currentPage = 1,
- everyPageSize = 999999,
- sortName = "",
- keyWhere = "",
- daaGuid = strGdId
- };
- var json = JsonConvert.SerializeObject(_obj);
- try
- {
- var strReturn = UtilityHelper.HttpPost("",
- "WomdaaManager/GetListSelectDab", json);
- var rtn = UtilityHelper.ReturnToTablePage(strReturn);
- var dt = rtn.rtnData.list;
- this.repositoryItemSearchLookUpEdit1.DataSource = dt;
- this.repositoryItemSearchLookUpEdit1.BestFitMode = DevExpress.XtraEditors.Controls.BestFitMode.BestFitResizePopup;
- }
- catch (Exception ex)
- {
- MsgHelper.Warning("鎻愮ず锛�" + ex.Message);
- }
};
-
//閫夋嫨闇�瑕佸叆搴撶殑鏄庣粏
btnSelect.Click += (s, e) =>
{
if (string.IsNullOrEmpty(this.txt_orgId.GetId()))
{
- MsgHelper.Warning("璇烽�夋嫨鐢熶骇缁勭粐锛�");
+ MsgHelper.ShowError("璇烽�夋嫨鐢熶骇缁勭粐锛�");
txt_orgId.Focus();
return;
}
@@ -150,6 +129,9 @@
frm.ShowDialog();
};
}
+
+
+
private void GridView1_ColumnFilterChanged(object sender, EventArgs e)
{
_filterList = Gs.DevApp.ToolBox.UtilityHelper.GetDilter(gridView1.Columns, gridView1);
@@ -237,7 +219,7 @@
lbGuid, txt_blNo, gridView1, "blNo");
if (string.IsNullOrEmpty(rowGuid))
{
- MsgHelper.Warning("璇峰厛閫夋嫨浣犺鎿嶄綔鐨勮锛�");
+ MsgHelper.ShowError("璇峰厛閫夋嫨浣犺鎿嶄綔鐨勮锛�");
return;
}
if (!MsgHelper.AskQuestion("浣犻�夋嫨浜嗐��" + rowName + "銆戯紝纭畾鍒犻櫎鍚楋紵"))
@@ -261,13 +243,12 @@
Gs.DevApp.ToolBox.UtilityHelper.JumpTab(xtraTabControl1, 2);
getPageList(this.pageBar1.CurrentPage);
}
- MsgHelper.Warning("鎻愮ず锛�" + _rtn.rtnMsg);
+ MsgHelper.ShowError("鎻愮ず锛�" + _rtn.rtnMsg);
}
catch (Exception ex)
{
- MsgHelper.Warning("鎻愮ず锛�" + ex.Message);
+ MsgHelper.ShowError("鎻愮ず锛�" + ex.Message);
}
-
}
/// <summary>
@@ -317,6 +298,9 @@
gvList.Add(gvMx1);
UtilityHelper.ChangeEnableByControl(this.layoutMx1.Controls, true, gvList);
}
+ //2025/07/12鍔犱笂淇敼鐘舵�佷笅涓嶈兘淇敼
+ txt_orgId.IsReadly = true;
+ txt_aboutGuid.IsReadly = true;
}
/// <summary>
/// 鏂板浜嬩欢
@@ -331,6 +315,8 @@
gridViews.Add(gvMx1);
UtilityHelper.CleanValueByControl(this.layoutMx1.Controls, true, gridViews);
Gs.DevApp.ToolBox.UtilityHelper.SetDefaultTable(gcMx1, gvMx1);
+ //澧炲姞鏃讹紝榛樿缁勭粐
+ string deftOrg = UtilityHelper.GetFirstOrg(txt_orgId);
}
/// <summary>
@@ -345,19 +331,19 @@
string inGdId = txt_aboutGuid.GetId();//宸ュ崟鍙�
if (string.IsNullOrEmpty(inGdId))
{
- Gs.DevApp.ToolBox.MsgHelper.Warning("璇烽�夋嫨宸ュ崟锛�");
+ Gs.DevApp.ToolBox.MsgHelper.ShowError("璇烽�夋嫨宸ュ崟锛�");
txt_aboutGuid.Focus();
return;
}
if (string.IsNullOrEmpty(inGdId))
{
- Gs.DevApp.ToolBox.MsgHelper.Warning("璇烽�夋嫨宸ュ崟锛�");
+ Gs.DevApp.ToolBox.MsgHelper.ShowError("璇烽�夋嫨宸ュ崟锛�");
txt_aboutGuid.Focus();
return;
}
if (string.IsNullOrEmpty(txt_bl017.Text.Trim()))
{
- Gs.DevApp.ToolBox.MsgHelper.Warning("璇烽�夋嫨鍗曟嵁绫诲瀷锛�");
+ Gs.DevApp.ToolBox.MsgHelper.ShowError("璇烽�夋嫨鍗曟嵁绫诲瀷锛�");
txt_bl017.Focus();
return;
}
@@ -404,9 +390,10 @@
{
string strJson = UtilityHelper.HttpPost("", _webServiceName + "EditModel", JsonConvert.SerializeObject(_obj));
ReturnModel<dynamic> _rtn = ToolBox.UtilityHelper.ReturnToDynamic(strJson);
- ToolBox.MsgHelper.Warning("鎻愮ず锛�" + _rtn.rtnMsg);
+
if (_rtn.rtnCode > 0)
{
+ ToolBox.MsgHelper.ShowInformation("鎻愮ず锛�" + _rtn.rtnMsg);
lbGuid.Text = _rtn.rtnData.outGuid;
txt_blNo.Text = _rtn.rtnData.outNo;
toolBarMenu1.isSetBtn = true;
@@ -416,10 +403,12 @@
toolBarMenu1.currentAction = "";
Gs.DevApp.ToolBox.UtilityHelper.JumpTab(xtraTabControl1, 6);
}
+ else
+ ToolBox.MsgHelper.ShowError("鎻愮ず锛�" + _rtn.rtnMsg);
}
catch (Exception ex)
{
- ToolBox.MsgHelper.Warning("鎻愮ず锛�" + ex.Message);
+ ToolBox.MsgHelper.ShowError("鎻愮ず锛�" + ex.Message);
}
}
@@ -430,8 +419,12 @@
/// <param name="pageSize">姣忛〉鍑犳潯</param>
private void getPageList(int curPage)
{
- gcMain1.DataSource = null;var _sbSqlWhere = UtilityHelper.GetSearchWhere(_filterList);
- _sbSqlWhere += " and a.bl008='" + strType + "'";
+ gcMain1.DataSource = null;
+ System.Text.StringBuilder _sbSqlWhere = new System.Text.StringBuilder();
+ _sbSqlWhere.Append(" and a.bl008='" + strType + "'");
+ _sbSqlWhere.Append(" and a.org_id in");
+ _sbSqlWhere.Append(ToolBox.UtilityHelper.GetOrgWhere());
+ _sbSqlWhere.Append(UtilityHelper.GetSearchWhere(_filterList));
PageQueryModel pgq = new PageQueryModel(curPage, this.pageBar1.RowsCount, "create_date", "asc", "", _sbSqlWhere.ToString());
string json = JsonConvert.SerializeObject(pgq);
try
@@ -528,6 +521,15 @@
}
}
+ /// <summary>
+ /// 瀹岀粨
+ /// </summary>
+ /// <param name="sender"></param>
+ /// <param name="e"></param>
+ private void ToolBarMenu1_btnWjClick(object sender, EventArgs e)
+ {
+ _toolCk(2);
+ }
/// <summary>
/// 瀹℃牳浜嬩欢
@@ -565,13 +567,17 @@
case 0:
strMsg = "鍙嶅鏍�";
break;
- };
+ case 2:
+ strMsg = "瀹岀粨";
+ break;
+ }
+ ;
toolBarMenu1.guidKey = "";
string rowGuid, rowName;
(rowGuid, rowName) = UtilityHelper.GetCurrentRow(xtraTabControl1, lbGuid, txt_blNo, gridView1, "blNo");
if (string.IsNullOrEmpty(rowGuid))
{
- MsgHelper.Warning("璇峰厛閫夋嫨浣犺鎿嶄綔鐨勮锛�");
+ MsgHelper.ShowError("璇峰厛閫夋嫨浣犺鎿嶄綔鐨勮锛�");
return;
}
if (!MsgHelper.AskQuestion("浣犻�夋嫨浜嗐��" + rowName + "銆戯紝纭畾" + strMsg + "鍚楋紵"))
@@ -587,9 +593,10 @@
_webServiceName + "EditModelSubmit",
JsonConvert.SerializeObject(_obj));
var _rtn = UtilityHelper.ReturnToDynamic(strJson);
- MsgHelper.Warning(_rtn.rtnData.outMsg.ToString());
+
if (_rtn.rtnCode > 0 && _rtn.rtnData.outSum * 1 > 0)
{
+ MsgHelper.ShowInformation(_rtn.rtnData.outMsg.ToString());
if (xtraTabControl1.SelectedTabPageIndex == 1)
{
getModel(lbGuid.Text.Trim());
@@ -599,10 +606,12 @@
Form parentForm = this.FindForm();
UtilityHelper.SetCheckIco(gridView1, "bl018", "bl016", "bl006", picCheckBox, parentForm, _inFieldValue.ToString());
}
+ else
+ MsgHelper.ShowError(_rtn.rtnData.outMsg.ToString());
}
catch (Exception ex)
{
- MsgHelper.Warning("鎻愮ず锛�" + ex.Message);
+ MsgHelper.ShowError("鎻愮ず锛�" + ex.Message);
}
}
private void repositoryItemButtonEdit1_ButtonClick(object sender, DevExpress.XtraEditors.Controls.ButtonPressedEventArgs e)
@@ -634,13 +643,15 @@
var _rtn = UtilityHelper.ReturnToDynamic(strJson);
if (_rtn.rtnCode > 0)
{
- if (_rtn.rtnCode > 0) getModel(lbGuid.Text);
+ MsgHelper.ShowInformation("鎻愮ず锛�" + _rtn.rtnMsg);
+ getModel(lbGuid.Text);
}
- MsgHelper.Warning("鎻愮ず锛�" + _rtn.rtnMsg);
+ else
+ MsgHelper.ShowError("鎻愮ず锛�" + _rtn.rtnMsg);
}
catch (Exception ex)
{
- MsgHelper.Warning("鎻愮ず锛�" + ex.Message);
+ MsgHelper.ShowError("鎻愮ず锛�" + ex.Message);
}
}
}
--
Gitblit v1.9.3