From 4dc2dbda4150c7c74a26435a75308789dc359b99 Mon Sep 17 00:00:00 2001
From: cdk <2441919651@qq.com>
Date: 星期六, 01 十一月 2025 17:06:41 +0800
Subject: [PATCH] 增加批量打印功能,增加组织分开维护
---
DevApp/Gs.DevApp/DevFrm/User/Role.cs | 40 ++++++++++++++++++++++++++--------------
1 files changed, 26 insertions(+), 14 deletions(-)
diff --git a/DevApp/Gs.DevApp/DevFrm/User/Role.cs b/DevApp/Gs.DevApp/DevFrm/User/Role.cs
index 0fc2ba0..5569fec 100644
--- a/DevApp/Gs.DevApp/DevFrm/User/Role.cs
+++ b/DevApp/Gs.DevApp/DevFrm/User/Role.cs
@@ -106,7 +106,7 @@
lbGuid, txt_roleName, gridView1, "roleName");
if (string.IsNullOrEmpty(rowGuid))
{
- MsgHelper.Warning("璇峰厛閫夋嫨浣犺鎿嶄綔鐨勮锛�");
+ MsgHelper.ShowError("璇峰厛閫夋嫨浣犺鎿嶄綔鐨勮锛�");
return;
}
if (!MsgHelper.AskQuestion("浣犻�夋嫨浜嗐��" + rowName + "銆戯紝纭畾鍒犻櫎鍚楋紵\n璇ユ搷浣滃皢浼氭竻绌虹浉搴旂殑鐢ㄦ埛鏉冮檺"))
@@ -121,17 +121,19 @@
var _rtn = UtilityHelper.ReturnToDynamic(strJson);
if (_rtn.rtnCode > 0)
{
+ MsgHelper.ShowInformation("鎻愮ず锛�" + _rtn.rtnMsg);
if (xtraTabControl1.SelectedTabPageIndex == 0)
{ }
else
Gs.DevApp.ToolBox.UtilityHelper.JumpTab(xtraTabControl1, 2);
getPageList(this.pageBar1.CurrentPage);
}
- MsgHelper.Warning("鎻愮ず锛�" + _rtn.rtnMsg);
+ else
+ MsgHelper.ShowError("鎻愮ず锛�" + _rtn.rtnMsg);
}
catch (Exception ex)
{
- MsgHelper.Warning("鎻愮ず锛�" + ex.Message);
+ MsgHelper.ShowError("鎻愮ず锛�" + ex.Message);
}
}
@@ -169,7 +171,7 @@
(rowGuid, rowName) = UtilityHelper.GetCurrentRow(xtraTabControl1, lbGuid, txt_roleName, gridView1);
if (string.IsNullOrEmpty(rowGuid))
{
- ToolBox.MsgHelper.Warning("璇峰厛閫夋嫨浣犺鎿嶄綔鐨勮锛�");
+ ToolBox.MsgHelper.ShowError("璇峰厛閫夋嫨浣犺鎿嶄綔鐨勮锛�");
return;
}
Gs.DevApp.ToolBox.UtilityHelper.JumpTab(xtraTabControl1, 3);
@@ -205,14 +207,14 @@
toolBarMenu1.isSetBtn = false;
if (string.IsNullOrEmpty(txt_roleName.Text.Trim()))
{
- MsgHelper.Warning("瑙掕壊鍚嶇О涓嶈兘涓虹┖锛�");
+ MsgHelper.ShowError("瑙掕壊鍚嶇О涓嶈兘涓虹┖锛�");
txt_roleName.Focus();
return;
}
if (string.IsNullOrEmpty(txt_roleRemark.Text.Trim()))
{
- MsgHelper.Warning("瑙掕壊澶囨敞涓嶈兘涓虹┖锛�");
+ MsgHelper.ShowError("瑙掕壊澶囨敞涓嶈兘涓虹┖锛�");
txt_roleRemark.Focus();
return;
}
@@ -228,19 +230,21 @@
var strJson = UtilityHelper.HttpPost("", "Role/EditModel",
JsonConvert.SerializeObject(_obj));
var _rtn = UtilityHelper.ReturnToDynamic(strJson);
- MsgHelper.Warning("鎻愮ず锛�" + _rtn.rtnMsg);
if (_rtn.rtnCode > 0)
{
+ MsgHelper.ShowInformation("鎻愮ず锛�" + _rtn.rtnMsg);
lbGuid.Text = _rtn.rtnData;
toolBarMenu1.isSetBtn = true;
UtilityHelper.ChangeEnableByControl(this.layoutMx1.Controls, false);
toolBarMenu1.currentAction = "";
Gs.DevApp.ToolBox.UtilityHelper.JumpTab(xtraTabControl1, 6);
}
+ else
+ MsgHelper.ShowError("鎻愮ず锛�" + _rtn.rtnMsg);
}
catch (Exception ex)
{
- MsgHelper.Warning("鎻愮ず锛�" + ex.Message);
+ MsgHelper.ShowError("鎻愮ず锛�" + ex.Message);
}
}
@@ -283,10 +287,13 @@
}
catch (Exception ex)
{
- MsgHelper.Warning("鎻愮ず锛�" + ex.Message);
+ MsgHelper.ShowError("鎻愮ず锛�" + ex.Message);
}
}
-
+ /// <summary>
+ /// 璇诲彇瀹炰綋
+ /// </summary>
+ /// <param name="strGuid"></param>
private void getModel(string strGuid)
{
bool isEdit = false;
@@ -294,7 +301,7 @@
if (toolBarMenu1.currentAction == "edit") isEdit = true;
if (string.IsNullOrEmpty(strGuid))
{
- MsgHelper.Warning("璇峰厛閫夋嫨浣犺鎿嶄綔鐨勮锛�");
+ MsgHelper.ShowError("璇峰厛閫夋嫨浣犺鎿嶄綔鐨勮锛�");
return;
}
var _obj = new
@@ -315,12 +322,12 @@
}
else
{
- MsgHelper.Warning("鎻愮ず锛�" + _rtn.rtnMsg);
+ MsgHelper.ShowError("鎻愮ず锛�" + _rtn.rtnMsg);
}
}
catch (Exception ex)
{
- MsgHelper.Warning("鎻愮ず锛�" + ex.Message);
+ MsgHelper.ShowError("鎻愮ず锛�" + ex.Message);
}
}
// 閬嶅巻TreeView涓殑鎵�鏈夎妭鐐�
@@ -334,6 +341,11 @@
if (node.Nodes.Count > 0) TraverseTreeViewNodes(node.Nodes);
}
}
+ /// <summary>
+ /// 寮瑰嚭閰嶇疆鏉冮檺
+ /// </summary>
+ /// <param name="sender"></param>
+ /// <param name="e"></param>
private void repositoryItemButtonEdit1_ButtonClick(object sender, DevExpress.XtraEditors.Controls.ButtonPressedEventArgs e)
{
if (e.Button.Index == 0)
@@ -341,7 +353,7 @@
var rowhandle = gridView1.FocusedRowHandle;
var dr = gridView1.GetDataRow(rowhandle);
var roleGuid = dr["guid"].ToString();
- var frm = new RoleSelectAction(roleGuid);
+ var frm = new RoleSelectAction(roleGuid,"璁剧疆瑙掕壊鏉冮檺");
frm.ShowDialog();
}
}
--
Gitblit v1.9.3