From 318d349fc009011a135dbce5a25e392b492c0718 Mon Sep 17 00:00:00 2001 From: yzh <snbbt@21cn.com> Date: 星期五, 20 五月 2022 16:49:20 +0800 Subject: [PATCH] 客户分配个性产品 系统数据权限隔离 --- web/web/GwOrder.ashx | 20 +++++++++++++++++--- 1 files changed, 17 insertions(+), 3 deletions(-) diff --git a/web/web/GwOrder.ashx b/web/web/GwOrder.ashx index 99c1784..cdb1c66 100644 --- a/web/web/GwOrder.ashx +++ b/web/web/GwOrder.ashx @@ -23,10 +23,18 @@ private List<GwOpGroup> _GroupList; private List<GwProduct> _ProductList; //浜у搧鍙婁骇鍝佸垎绫� //private List<GwProduct> _ProductClassList; //浜у搧鍒嗙被 + + private int _userId = -1; + private int _userType = -1; + private string _account = ""; public override JsonPageResult ProcessRequestInternal(PageContext<SysUser> context) { string @string = context.GetString("action"); + _userId = context.SessionObject.UserID; + _userType = context.SessionObject.UserType; + _account = context.SessionObject.Account; + switch (@string) { case "delete": @@ -67,8 +75,10 @@ int recordCount = 0; int pageSize = context.GetInt("pageSize", 50); int pageIndex = context.GetInt("pageIndex", 1); + + string permissionsSQL = new GwClientDao().GetClientPermissions(_userId, _userType, "GWC"); - List<GwOrder> list = _Dao.LoadInfoList(spId, clientId, clientName, flag, startDate, endDate, pageSize, pageIndex, out recordCount); + List<GwOrder> list = _Dao.LoadInfoList(spId, clientId, clientName, flag, startDate, endDate, pageSize, pageIndex, permissionsSQL, out recordCount); string str1 = ""; if (list != null && list.Count > 0) @@ -125,8 +135,10 @@ int recordCount = 0; int pageSize = context.GetInt("pageSize", 50); int pageIndex = context.GetInt("pageIndex", 1); + + string permissionsSQL = new GwClientDao().GetClientPermissions(_userId, _userType, "GWC"); - List<GwOrder> list = _Dao.LoadInfoList(spId, clientId, clientName, flag, startDate, endDate, pageSize, pageIndex, out recordCount); + List<GwOrder> list = _Dao.LoadInfoList(spId, clientId, clientName, flag, startDate, endDate, pageSize, pageIndex, permissionsSQL, out recordCount); string str1 = ""; if (list != null && list.Count > 0) @@ -201,9 +213,11 @@ int recordCount = 0; int pageSize = context.GetInt("pageSize", 50); int pageIndex = context.GetInt("pageIndex", 1); + + string permissionsSQL = new GwClientDao().GetClientPermissions(_userId, _userType, "GWC"); //List<GwOrder> list = _Dao.LoadInfoList(spId, clientId, clientName, flag, Convert.ToDateTime(startDate), Convert.ToDateTime(endDate).AddDays(1.0), pageSize, pageIndex, out recordCount); - List<GwOrder> list = _Dao.LoadInfoList(spId, clientId, clientName, flag, startDate, endDate.AddDays(1.0), pageSize, pageIndex, out recordCount); + List<GwOrder> list = _Dao.LoadInfoList(spId, clientId, clientName, flag, startDate, endDate.AddDays(1.0), pageSize, pageIndex, permissionsSQL, out recordCount); string str1 = ""; if (list != null && list.Count > 0) -- Gitblit v1.9.1