zhupei 4 年之前
父節點
當前提交
b47ce580d3

+ 1 - 1
RMYY_CallCenter_Api.Bll/T_Sys_DictionaryBase.cs

@@ -9,7 +9,7 @@ namespace RMYY_CallCenter_Api.Bll
9 9
     /// </summary>
10 10
     public partial class T_Sys_DictionaryBase
11 11
     {
12
-        private readonly RMYY_CallCenter_Api.DAL.T_Sys_DictionaryBase dal = new RMYY_CallCenter_Api.DAL.T_Sys_DictionaryBase();
12
+        private readonly RMYY_CallCenter_Api.Dal.T_Sys_DictionaryBase dal = new RMYY_CallCenter_Api.Dal.T_Sys_DictionaryBase();
13 13
         public T_Sys_DictionaryBase()
14 14
         { }
15 15
         #region  BasicMethod

+ 1 - 1
RMYY_CallCenter_Api.Bll/T_Sys_DictionaryValue.cs

@@ -9,7 +9,7 @@ namespace RMYY_CallCenter_Api.Bll
9 9
     /// </summary>
10 10
     public partial  class T_Sys_DictionaryValue
11 11
     {
12
-        private readonly RMYY_CallCenter_Api.DAL.T_Sys_DictionaryValue dal = new RMYY_CallCenter_Api.DAL.T_Sys_DictionaryValue();
12
+        private readonly RMYY_CallCenter_Api.Dal.T_Sys_DictionaryValue dal = new RMYY_CallCenter_Api.Dal.T_Sys_DictionaryValue();
13 13
         public T_Sys_DictionaryValue()
14 14
         { }
15 15
         #region  BasicMethod

+ 1 - 1
RMYY_CallCenter_Api.Bll/T_Sys_GongDan.cs

@@ -9,7 +9,7 @@ namespace RMYY_CallCenter_Api.Bll
9 9
     /// </summary>
10 10
     public partial class T_Sys_GongDan
11 11
     {
12
-        private readonly RMYY_CallCenter_Api.DAL.T_Sys_GongDan dal = new RMYY_CallCenter_Api.DAL.T_Sys_GongDan();
12
+        private readonly RMYY_CallCenter_Api.Dal.T_Sys_GongDan dal = new RMYY_CallCenter_Api.Dal.T_Sys_GongDan();
13 13
         public T_Sys_GongDan()
14 14
         { }
15 15
         #region  BasicMethod

+ 1 - 1
RMYY_CallCenter_Api.Bll/T_Sys_GongDanType.cs

@@ -9,7 +9,7 @@ namespace RMYY_CallCenter_Api.Bll
9 9
     /// </summary>
10 10
     public partial class T_Sys_GongDanType
11 11
     {
12
-        private readonly RMYY_CallCenter_Api.DAL.T_Sys_GongDanType dal = new RMYY_CallCenter_Api.DAL.T_Sys_GongDanType();
12
+        private readonly RMYY_CallCenter_Api.Dal.T_Sys_GongDanType dal = new RMYY_CallCenter_Api.Dal.T_Sys_GongDanType();
13 13
         public T_Sys_GongDanType()
14 14
         { }
15 15
         #region  BasicMethod

+ 5 - 5
RMYY_CallCenter_Api.Dal/T_Sys_DictionaryBase.cs

@@ -4,7 +4,7 @@ using System.Text;
4 4
 using System.Data.SqlClient;
5 5
 using RMYY_CallCenter_Api.DB;
6 6
 
7
-namespace RMYY_CallCenter_Api.DAL
7
+namespace RMYY_CallCenter_Api.Dal
8 8
 {
9 9
     /// <summary>
10 10
     /// 数据访问类:T_Sys_DictionaryBase
@@ -148,7 +148,7 @@ namespace RMYY_CallCenter_Api.DAL
148 148
         {
149 149
 
150 150
             StringBuilder strSql = new StringBuilder();
151
-            strSql.Append("select  top 1 F_DictionaryFlag,F_DictionaryName,F_Sort,F_Describe,F_State from T_Sys_DictionaryBase ");
151
+            strSql.Append("select  top 1 F_DictionaryFlag,F_DictionaryName,F_Sort,F_Describe,F_State from T_Sys_DictionaryBase with(nolock)");
152 152
             strSql.Append(" where F_DictionaryFlag=@F_DictionaryFlag ");
153 153
             SqlParameter[] parameters = {
154 154
                     new SqlParameter("@F_DictionaryFlag", SqlDbType.VarChar,50)         };
@@ -213,7 +213,7 @@ namespace RMYY_CallCenter_Api.DAL
213 213
         {
214 214
             StringBuilder strSql = new StringBuilder();
215 215
             strSql.Append("select F_DictionaryFlag,F_DictionaryName,F_Sort,F_Describe,F_State ");
216
-            strSql.Append(" FROM T_Sys_DictionaryBase ");
216
+            strSql.Append(" FROM T_Sys_DictionaryBase (NOLOCK) ");
217 217
             if (strWhere.Trim() != "")
218 218
             {
219 219
                 strSql.Append(" where " + strWhere);
@@ -233,7 +233,7 @@ namespace RMYY_CallCenter_Api.DAL
233 233
                 strSql.Append(" top " + Top.ToString());
234 234
             }
235 235
             strSql.Append(" F_DictionaryFlag,F_DictionaryName,F_Sort,F_Describe,F_State ");
236
-            strSql.Append(" FROM T_Sys_DictionaryBase ");
236
+            strSql.Append(" FROM T_Sys_DictionaryBase (NOLOCK) ");
237 237
             if (strWhere.Trim() != "")
238 238
             {
239 239
                 strSql.Append(" where " + strWhere);
@@ -248,7 +248,7 @@ namespace RMYY_CallCenter_Api.DAL
248 248
         public int GetRecordCount(string strWhere)
249 249
         {
250 250
             StringBuilder strSql = new StringBuilder();
251
-            strSql.Append("select count(1) FROM T_Sys_DictionaryBase ");
251
+            strSql.Append("select count(1) FROM T_Sys_DictionaryBase (NOLOCK)");
252 252
             if (strWhere.Trim() != "")
253 253
             {
254 254
                 strSql.Append(" where " + strWhere);

+ 6 - 6
RMYY_CallCenter_Api.Dal/T_Sys_DictionaryValue.cs

@@ -4,7 +4,7 @@ using System.Text;
4 4
 using System.Data.SqlClient;
5 5
 using RMYY_CallCenter_Api.DB;
6 6
 
7
-namespace RMYY_CallCenter_Api.DAL
7
+namespace RMYY_CallCenter_Api.Dal
8 8
 {
9 9
     /// <summary>
10 10
     /// 数据访问类:T_Sys_DictionaryValue
@@ -20,7 +20,7 @@ namespace RMYY_CallCenter_Api.DAL
20 20
         public bool Exists(int F_DictionaryValueId)
21 21
         {
22 22
             StringBuilder strSql = new StringBuilder();
23
-            strSql.Append("select count(1) from T_Sys_DictionaryValue");
23
+            strSql.Append("select count(1) from T_Sys_DictionaryValue with(nolock)");
24 24
             strSql.Append(" where F_DictionaryValueId=@F_DictionaryValueId");
25 25
             SqlParameter[] parameters = {
26 26
                     new SqlParameter("@F_DictionaryValueId", SqlDbType.Int,4)
@@ -158,7 +158,7 @@ namespace RMYY_CallCenter_Api.DAL
158 158
         {
159 159
 
160 160
             StringBuilder strSql = new StringBuilder();
161
-            strSql.Append("select  top 1 F_DictionaryValueId,F_DictionaryFlag,F_ValueCode,F_Name,F_Sort,F_Describe,F_State from T_Sys_DictionaryValue ");
161
+            strSql.Append("select  top 1 F_DictionaryValueId,F_DictionaryFlag,F_ValueCode,F_Name,F_Sort,F_Describe,F_State from T_Sys_DictionaryValue with(nolock)");
162 162
             strSql.Append(" where F_DictionaryValueId=@F_DictionaryValueId");
163 163
             SqlParameter[] parameters = {
164 164
                     new SqlParameter("@F_DictionaryValueId", SqlDbType.Int,4)
@@ -231,7 +231,7 @@ namespace RMYY_CallCenter_Api.DAL
231 231
         public DataSet GetList(string strWhere)
232 232
         {
233 233
             StringBuilder strSql = new StringBuilder();
234
-            strSql.Append("select F_DictionaryValueId,F_DictionaryFlag,F_ValueCode,F_Name,F_Sort,F_Describe,F_State ");
234
+            strSql.Append("select F_DictionaryValueId,F_DictionaryFlag,F_ValueCode,F_Name,F_Sort,F_Describe,F_State with(nolock) ");
235 235
             strSql.Append(" FROM T_Sys_DictionaryValue ");
236 236
             if (strWhere.Trim() != "")
237 237
             {
@@ -252,7 +252,7 @@ namespace RMYY_CallCenter_Api.DAL
252 252
                 strSql.Append(" top " + Top.ToString());
253 253
             }
254 254
             strSql.Append(" F_DictionaryValueId,F_DictionaryFlag,F_ValueCode,F_Name,F_Sort,F_Describe,F_State ");
255
-            strSql.Append(" FROM T_Sys_DictionaryValue ");
255
+            strSql.Append(" FROM T_Sys_DictionaryValue with(nolock)");
256 256
             if (strWhere.Trim() != "")
257 257
             {
258 258
                 strSql.Append(" where " + strWhere);
@@ -267,7 +267,7 @@ namespace RMYY_CallCenter_Api.DAL
267 267
         public int GetRecordCount(string strWhere)
268 268
         {
269 269
             StringBuilder strSql = new StringBuilder();
270
-            strSql.Append("select count(1) FROM T_Sys_DictionaryValue ");
270
+            strSql.Append("select count(1) FROM T_Sys_DictionaryValue with(nolock) ");
271 271
             if (strWhere.Trim() != "")
272 272
             {
273 273
                 strSql.Append(" where " + strWhere);

+ 6 - 6
RMYY_CallCenter_Api.Dal/T_Sys_GongDan.cs

@@ -4,7 +4,7 @@ using System.Text;
4 4
 using System.Data.SqlClient;
5 5
 using RMYY_CallCenter_Api.DB;
6 6
 
7
-namespace RMYY_CallCenter_Api.DAL
7
+namespace RMYY_CallCenter_Api.Dal
8 8
 {
9 9
     /// <summary>
10 10
     /// 数据访问类:T_Sys_GongDan
@@ -20,7 +20,7 @@ namespace RMYY_CallCenter_Api.DAL
20 20
         public bool Exists(int F_GDId)
21 21
         {
22 22
             StringBuilder strSql = new StringBuilder();
23
-            strSql.Append("select count(1) from T_Sys_GongDan");
23
+            strSql.Append("select count(1) from T_Sys_GongDan with(nolock)");
24 24
             strSql.Append(" where F_GDId=@F_GDId");
25 25
             SqlParameter[] parameters = {
26 26
                     new SqlParameter("@F_GDId", SqlDbType.Int,4)
@@ -163,7 +163,7 @@ namespace RMYY_CallCenter_Api.DAL
163 163
         {
164 164
 
165 165
             StringBuilder strSql = new StringBuilder();
166
-            strSql.Append("select  top 1 F_GDId,F_ParentID,F_Name,F_Remark,F_Sort,F_CreateTime,F_TypeId,F_ImgUrl from T_Sys_GongDan ");
166
+            strSql.Append("select  top 1 F_GDId,F_ParentID,F_Name,F_Remark,F_Sort,F_CreateTime,F_TypeId,F_ImgUrl from T_Sys_GongDan with(nolock)");
167 167
             strSql.Append(" where F_GDId=@F_GDId");
168 168
             SqlParameter[] parameters = {
169 169
                     new SqlParameter("@F_GDId", SqlDbType.Int,4)
@@ -234,7 +234,7 @@ namespace RMYY_CallCenter_Api.DAL
234 234
         {
235 235
             StringBuilder strSql = new StringBuilder();
236 236
             strSql.Append("select F_GDId,F_ParentID,F_Name,F_Remark,F_Sort,F_CreateTime,F_TypeId,F_ImgUrl ");
237
-            strSql.Append(" FROM T_Sys_GongDan ");
237
+            strSql.Append(" FROM T_Sys_GongDan with(nolock)");
238 238
             if (strWhere.Trim() != "")
239 239
             {
240 240
                 strSql.Append(" where " + strWhere);
@@ -254,7 +254,7 @@ namespace RMYY_CallCenter_Api.DAL
254 254
                 strSql.Append(" top " + Top.ToString());
255 255
             }
256 256
             strSql.Append(" F_GDId,F_ParentID,F_Name,F_Remark,F_Sort,F_CreateTime,F_TypeId,F_ImgUrl ");
257
-            strSql.Append(" FROM T_Sys_GongDan ");
257
+            strSql.Append(" FROM T_Sys_GongDan with(nolock)");
258 258
             if (strWhere.Trim() != "")
259 259
             {
260 260
                 strSql.Append(" where " + strWhere);
@@ -269,7 +269,7 @@ namespace RMYY_CallCenter_Api.DAL
269 269
         public int GetRecordCount(string strWhere)
270 270
         {
271 271
             StringBuilder strSql = new StringBuilder();
272
-            strSql.Append("select count(1) FROM T_Sys_GongDan ");
272
+            strSql.Append("select count(1) FROM T_Sys_GongDan with(nolock)");
273 273
             if (strWhere.Trim() != "")
274 274
             {
275 275
                 strSql.Append(" where " + strWhere);

+ 6 - 6
RMYY_CallCenter_Api.Dal/T_Sys_GongDanType.cs

@@ -4,7 +4,7 @@ using System.Text;
4 4
 using System.Data.SqlClient;
5 5
 using RMYY_CallCenter_Api.DB;
6 6
 
7
-namespace RMYY_CallCenter_Api.DAL
7
+namespace RMYY_CallCenter_Api.Dal
8 8
 {
9 9
     /// <summary>
10 10
     /// 数据访问类:T_Sys_GongDanType
@@ -20,7 +20,7 @@ namespace RMYY_CallCenter_Api.DAL
20 20
         public bool Exists(int F_TypeId)
21 21
         {
22 22
             StringBuilder strSql = new StringBuilder();
23
-            strSql.Append("select count(1) from T_Sys_GongDanType");
23
+            strSql.Append("select count(1) from T_Sys_GongDanType with(nolock)");
24 24
             strSql.Append(" where F_TypeId=@F_TypeId");
25 25
             SqlParameter[] parameters = {
26 26
                     new SqlParameter("@F_TypeId", SqlDbType.Int,4)
@@ -148,7 +148,7 @@ namespace RMYY_CallCenter_Api.DAL
148 148
         {
149 149
 
150 150
             StringBuilder strSql = new StringBuilder();
151
-            strSql.Append("select  top 1 F_TypeId,F_TypeName,F_TypeCode,F_Remark,F_CreateTime from T_Sys_GongDanType ");
151
+            strSql.Append("select  top 1 F_TypeId,F_TypeName,F_TypeCode,F_Remark,F_CreateTime from T_Sys_GongDanType with(nolock)");
152 152
             strSql.Append(" where F_TypeId=@F_TypeId");
153 153
             SqlParameter[] parameters = {
154 154
                     new SqlParameter("@F_TypeId", SqlDbType.Int,4)
@@ -207,7 +207,7 @@ namespace RMYY_CallCenter_Api.DAL
207 207
         {
208 208
             StringBuilder strSql = new StringBuilder();
209 209
             strSql.Append("select F_TypeId,F_TypeName,F_TypeCode,F_Remark,F_CreateTime ");
210
-            strSql.Append(" FROM T_Sys_GongDanType ");
210
+            strSql.Append(" FROM T_Sys_GongDanType with(nolock)");
211 211
             if (strWhere.Trim() != "")
212 212
             {
213 213
                 strSql.Append(" where " + strWhere);
@@ -227,7 +227,7 @@ namespace RMYY_CallCenter_Api.DAL
227 227
                 strSql.Append(" top " + Top.ToString());
228 228
             }
229 229
             strSql.Append(" F_TypeId,F_TypeName,F_TypeCode,F_Remark,F_CreateTime ");
230
-            strSql.Append(" FROM T_Sys_GongDanType ");
230
+            strSql.Append(" FROM T_Sys_GongDanType with(nolock)");
231 231
             if (strWhere.Trim() != "")
232 232
             {
233 233
                 strSql.Append(" where " + strWhere);
@@ -242,7 +242,7 @@ namespace RMYY_CallCenter_Api.DAL
242 242
         public int GetRecordCount(string strWhere)
243 243
         {
244 244
             StringBuilder strSql = new StringBuilder();
245
-            strSql.Append("select count(1) FROM T_Sys_GongDanType ");
245
+            strSql.Append("select count(1) FROM T_Sys_GongDanType with(nolock)");
246 246
             if (strWhere.Trim() != "")
247 247
             {
248 248
                 strSql.Append(" where " + strWhere);

+ 25 - 78
RMYY_CallCenter_Api/Controllers/DictionaryController.cs

@@ -11,7 +11,7 @@ using System.Web.Mvc;
11 11
 using RMYY_CallCenter_Api.Model;
12 12
 using RMYY_CallCenter_Api.Models;
13 13
 
14
-namespace CallCenterApi.Interface.Controllers
14
+namespace RMYY_CallCenter_Api.Controllers
15 15
 {
16 16
     
17 17
     public class DictionaryController : BaseController
@@ -28,9 +28,6 @@ namespace CallCenterApi.Interface.Controllers
28 28
         /// <returns></returns>
29 29
         public ActionResult GetList(FilterDictionary filter)
30 30
         {
31
-            ActionResult res = NoToken("未知错误,请重新登录");
32
-            if (Request.IsAuthenticated)
33
-            {
34 31
                 var sql = " and F_State=1 ";
35 32
                 var recordCount = 0;
36 33
                 var dt = RMYY_CallCenter_Api.Bll.PagerBll.GetListPager(
@@ -54,9 +51,7 @@ namespace CallCenterApi.Interface.Controllers
54 51
                     }),
55 52
                     total = recordCount
56 53
                 };
57
-                res = Content(obj.ToJson());
58
-            }
59
-            return res;
54
+                return  Content(obj.ToJson());
60 55
         }
61 56
 
62 57
         /// <summary>
@@ -66,21 +61,16 @@ namespace CallCenterApi.Interface.Controllers
66 61
         /// <returns></returns>
67 62
         public ActionResult GetDic(string dicFlag)
68 63
         {
69
-            ActionResult res = NoToken("未知错误,请重新登录");
70
-            if (Request.IsAuthenticated)
71
-            {
72 64
                 T_Sys_DictionaryBase baseModel = dictionaryBaseBLL.GetModel(dicFlag);
73 65
                 if (baseModel != null)
74
-                    res = Success("加载字典成功", new
66
+                    return Success("加载字典成功", new
75 67
                     {
76 68
                         name = baseModel.F_DictionaryName,
77 69
                         flag = baseModel.F_DictionaryFlag,
78 70
                         sort = baseModel.F_Sort
79 71
                     });
80 72
                 else
81
-                    res = Error("加载字典失败");
82
-            }
83
-            return res;
73
+                    return Error("加载字典失败");
84 74
         }
85 75
         //[Authority]
86 76
         /// <summary>
@@ -90,9 +80,6 @@ namespace CallCenterApi.Interface.Controllers
90 80
         /// <returns></returns>
91 81
         public ActionResult AddDic(DictionaryBaseInput input)
92 82
         {
93
-            ActionResult res = NoToken("未知错误,请重新登录");
94
-            if (Request.IsAuthenticated)
95
-            {
96 83
                 T_Sys_DictionaryBase orderModel = new T_Sys_DictionaryBase();
97 84
                 var model = dictionaryBaseBLL.GetModel(input.DicFlag.Trim());
98 85
                 if (model != null)
@@ -104,11 +91,9 @@ namespace CallCenterApi.Interface.Controllers
104 91
                 orderModel.F_Sort = input.Sort;
105 92
 
106 93
                 if (dictionaryBaseBLL.Add(orderModel))
107
-                    res = Success("字典添加成功");
94
+                    return Success("字典添加成功");
108 95
                 else
109
-                    res = Error("字典添加失败");
110
-            }
111
-            return res;
96
+                    return Error("字典添加失败");
112 97
         }
113 98
 
114 99
         //[Authority]
@@ -119,9 +104,6 @@ namespace CallCenterApi.Interface.Controllers
119 104
         /// <returns></returns>
120 105
         public ActionResult EditDic(DictionaryBaseInput input)
121 106
         {
122
-            ActionResult res = NoToken("未知错误,请重新登录");
123
-            if (Request.IsAuthenticated)
124
-            {
125 107
                 T_Sys_DictionaryBase orderModel = dictionaryBaseBLL.GetModel(input.DicFlag.Trim());
126 108
                 if (orderModel == null)
127 109
                     return Error("字典对象不存在");
@@ -130,11 +112,9 @@ namespace CallCenterApi.Interface.Controllers
130 112
                 orderModel.F_Describe = input.Remark;
131 113
                 orderModel.F_Sort = input.Sort;
132 114
                 if (dictionaryBaseBLL.Update(orderModel))
133
-                    res = Success("字典添加成功");
115
+                    return Success("字典添加成功");
134 116
                 else
135
-                    res = Error("字典添加失败");
136
-            }
137
-            return res;
117
+                    return Error("字典添加失败");
138 118
         }
139 119
 
140 120
         //[Authority]
@@ -145,9 +125,6 @@ namespace CallCenterApi.Interface.Controllers
145 125
         /// <returns></returns>
146 126
         public ActionResult DelDic(string[] ids)
147 127
         {
148
-            ActionResult res = NoToken("未知错误,请重新登录");
149
-            if (Request.IsAuthenticated)
150
-            {
151 128
                 if (ids == null || ids.Length <= 0)
152 129
                     return Error("获取参数失败");
153 130
                 StringBuilder sb = new StringBuilder();
@@ -156,11 +133,9 @@ namespace CallCenterApi.Interface.Controllers
156 133
                     sb.Append("'" + item + "',");
157 134
                 }
158 135
                 if (dictionaryBaseBLL.DeleteList(sb.ToString().Trim(',')))
159
-                    res = Success("删除成功");
136
+                return Success("删除成功");
160 137
                 else
161
-                    res = Error("删除失败");
162
-            }
163
-            return res;
138
+                return Error("删除失败");
164 139
         }
165 140
         #endregion
166 141
 
@@ -169,9 +144,7 @@ namespace CallCenterApi.Interface.Controllers
169 144
         //获取字典值列表
170 145
         public ActionResult GetDicValueList(FilterDictionary filter)
171 146
         {
172
-             ActionResult res = NoToken("未知错误,请重新登录");
173
-            if (Request.IsAuthenticated)
174
-            {
147
+            
175 148
                 string sql = "";
176 149
                 DataTable dt = new DataTable();
177 150
 
@@ -210,38 +183,29 @@ namespace CallCenterApi.Interface.Controllers
210 183
                     total = recordCount
211 184
                 };
212 185
 
213
-                res = Content(obj.ToJson());
214
-            }
215
-            return res;
186
+            return Content(obj.ToJson());
187
+
216 188
         }
217 189
 
218 190
         //获取字典值列表
219 191
         public ActionResult GetDicValueListByFlag(string flag)
220 192
         {
221
-            ActionResult res = NoToken("未知错误,请重新登录");
222
-            if (Request.IsAuthenticated)
223
-            {
224
-
225
-                DataTable dt = new DataTable();
193
+    
226 194
 
227
-                dt = dictionaryValueBLL.GetList(" F_DictionaryFlag='" + flag + "' and F_State=1 ").Tables[0];
195
+             DataTable dt = new DataTable();
196
+             dt = dictionaryValueBLL.GetList(" F_DictionaryFlag='" + flag + "' and F_State=1 ").Tables[0];
197
+            return Success("列表加载成功", dt);
228 198
 
229
-                res = Success("列表加载成功", dt);
230
-            }
231
-            return res;
232 199
         }        
233 200
 
234 201
         //加载字典值
235 202
         public ActionResult GetDicValue(int dicValueId = 0)
236 203
         {
237
-            ActionResult res = NoToken("未知错误,请重新登录");
238
-            if (Request.IsAuthenticated)
239
-            {
240 204
                 if (dicValueId <= 0)
241 205
                     return Error("字典值标识传输失败");
242 206
                 T_Sys_DictionaryValue valueModel = dictionaryValueBLL.GetModel(dicValueId);
243 207
                 if (valueModel != null)
244
-                    res = Success("加载字典值成功", new
208
+                return Success("加载字典值成功", new
245 209
                     {
246 210
                         id = valueModel.F_DictionaryValueId,
247 211
                         dicflag = valueModel.F_DictionaryFlag,
@@ -250,18 +214,13 @@ namespace CallCenterApi.Interface.Controllers
250 214
                         sort = valueModel.F_Sort,
251 215
                     });
252 216
                 else
253
-                    res = Error("加载字典值失败");
254
-            }
255
-            return res;
217
+                return Error("加载字典值失败");
256 218
         }
257 219
 
258 220
         //[Authority]
259 221
         //添加字典值
260 222
         public ActionResult AddDicValue(DictionaryValueInput input)
261 223
         {
262
-            ActionResult res = NoToken("未知错误,请重新登录");
263
-            if (Request.IsAuthenticated)
264
-            {
265 224
                 T_Sys_DictionaryValue orderModel = new T_Sys_DictionaryValue();
266 225
                
267 226
                 orderModel.F_Name = input.DicvName;
@@ -273,19 +232,14 @@ namespace CallCenterApi.Interface.Controllers
273 232
 
274 233
 
275 234
                 if (dictionaryValueBLL.Add(orderModel) > 0)
276
-                    res = Success("字典值添加成功");
235
+                return Success("字典值添加成功");
277 236
                 else
278
-                    res = Error("字典值添加失败");
279
-            }
280
-            return res;
237
+                return Error("字典值添加失败");
281 238
         }
282 239
         ////[Authority]
283 240
         //编辑字典值
284 241
         public ActionResult EditDicValue(DictionaryValueInput input)
285 242
         {
286
-            ActionResult res = NoToken("未知错误,请重新登录");
287
-            if (Request.IsAuthenticated)
288
-            {
289 243
                 if (input.DicVid <= 0)
290 244
                     return Error("字典值id获取失败");
291 245
                 T_Sys_DictionaryValue orderModel = dictionaryValueBLL.GetModel(input.DicVid);
@@ -297,28 +251,21 @@ namespace CallCenterApi.Interface.Controllers
297 251
                 orderModel.F_DictionaryFlag = input.DicFlag;
298 252
                 orderModel.F_Sort = input.Sort;
299 253
                 if (dictionaryValueBLL.Update(orderModel))
300
-                    res = Success("字典值编辑成功");
254
+                return Success("字典值编辑成功");
301 255
                 else
302
-                    res = Error("字典值编辑失败");
303
-            }
304
-            return res;
256
+                return Error("字典值编辑失败");
305 257
         }
306 258
         //[Authority]
307 259
         //删除字典值
308 260
         public ActionResult DelDicValue(string[] ids)
309 261
         {
310
-            ActionResult res = NoToken("未知错误,请重新登录");
311
-            if (Request.IsAuthenticated)
312
-            {
313 262
                 if (ids == null || ids.Length <= 0)
314 263
                     return Error("获取参数失败");
315 264
                 var idStr = string.Join(",", ids);
316 265
                 if (dictionaryValueBLL.DeleteList(idStr))
317
-                    res = Success("删除成功");
266
+                return Success("删除成功");
318 267
                 else
319
-                    res = Error("删除失败");
320
-            }
321
-            return res;
268
+                return Error("删除失败");
322 269
         }
323 270
         #endregion
324 271
 

+ 3 - 30
RMYY_CallCenter_Api/Controllers/GongDanTypeController.cs

@@ -48,9 +48,6 @@ namespace RMYY_CallCenter_Api.Controllers
48 48
         /// <returns></returns>
49 49
         public ActionResult AddGongDan(T_Sys_GongDan input)
50 50
         {
51
-            //ActionResult res = NoToken("未知错误,请重新登录");
52
-            //if (Request.IsAuthenticated)
53
-            //{
54 51
             T_Sys_GongDan model = new T_Sys_GongDan();
55 52
             model.F_Name = input.F_Name;
56 53
             model.F_Remark = input.F_Remark;
@@ -66,8 +63,6 @@ namespace RMYY_CallCenter_Api.Controllers
66 63
             {
67 64
                 return Error("添加失败,请重试");
68 65
             }
69
-            //}
70
-            //return res;
71 66
 
72 67
         }
73 68
 
@@ -169,10 +164,7 @@ namespace RMYY_CallCenter_Api.Controllers
169 164
         /// </summary>
170 165
         /// <returns></returns>
171 166
         public ActionResult GetTypeList(FilterDictionary filter)
172
-        {
173
-            //ActionResult res = NoToken("未知错误,请重新登录");
174
-            //if (Request.IsAuthenticated)
175
-            //{
167
+        {  
176 168
                 var recordCount = 0;
177 169
                 var dt = RMYY_CallCenter_Api.Bll.PagerBll.GetListPager(
178 170
                   "T_Sys_GongDanType",
@@ -195,10 +187,7 @@ namespace RMYY_CallCenter_Api.Controllers
195 187
                     total = recordCount
196 188
                 };
197 189
               return  Content(obj.ToJson());
198
-            //}
199
-            //return res;
200 190
         }
201
-        //[Authority]
202 191
         /// <summary>
203 192
         /// 添加类型
204 193
         /// </summary>
@@ -206,9 +195,6 @@ namespace RMYY_CallCenter_Api.Controllers
206 195
         /// <returns></returns>
207 196
         public ActionResult AddType(T_Sys_GongDanType input)
208 197
         {
209
-            //ActionResult res = NoToken("未知错误,请重新登录");
210
-            //if (Request.IsAuthenticated)
211
-            //{
212 198
                 T_Sys_GongDanType orderModel = new T_Sys_GongDanType();
213 199
                 orderModel.F_TypeName = input.F_TypeName;
214 200
                 orderModel.F_Remark = input.F_Remark;
@@ -217,11 +203,8 @@ namespace RMYY_CallCenter_Api.Controllers
217 203
                    return  Success("添加成功");
218 204
                 else
219 205
                    return  Error("添加失败");
220
-            //}
221
-            //return res;
222
-        }
223 206
 
224
-        //[Authority]
207
+        }
225 208
         /// <summary>
226 209
         /// 编辑类型
227 210
         /// </summary>
@@ -229,9 +212,6 @@ namespace RMYY_CallCenter_Api.Controllers
229 212
         /// <returns></returns>
230 213
         public ActionResult EditType(T_Sys_GongDanType input)
231 214
         {
232
-            //ActionResult res = NoToken("未知错误,请重新登录");
233
-            //if (Request.IsAuthenticated)
234
-            //{
235 215
                 T_Sys_GongDanType orderModel = gongdanTypeBll.GetModel(input.F_TypeId);             
236 216
                 orderModel.F_TypeName = input.F_TypeName;
237 217
                 orderModel.F_Remark = input.F_Remark;
@@ -240,8 +220,6 @@ namespace RMYY_CallCenter_Api.Controllers
240 220
                     return Success("修改成功");
241 221
                 else
242 222
                     return Error("修改失败");
243
-            //}
244
-            //return res;
245 223
         }
246 224
 
247 225
         //[Authority]
@@ -251,10 +229,7 @@ namespace RMYY_CallCenter_Api.Controllers
251 229
         /// <param name="ids"></param>
252 230
         /// <returns></returns>
253 231
         public ActionResult DelType(string[] ids)
254
-        {
255
-            //ActionResult res = NoToken("未知错误,请重新登录");
256
-            //if (Request.IsAuthenticated)
257
-            //{
232
+        {        
258 233
                 if (ids == null || ids.Length <= 0)
259 234
                     return Error("获取参数失败");
260 235
                 StringBuilder sb = new StringBuilder();
@@ -266,8 +241,6 @@ namespace RMYY_CallCenter_Api.Controllers
266 241
                 return Success("删除成功");
267 242
                 else
268 243
                     return Error("删除失败");
269
-            //}
270
-            //return res;
271 244
         }
272 245
         #endregion
273 246
     }

+ 0 - 21
RMYY_CallCenter_Api/Models/Filter/FilterCallPlan.cs

@@ -1,21 +0,0 @@
1
-using CallCenterApi.Interface.Models.Common;
2
-using System;
3
-using System.Collections.Generic;
4
-using System.Linq;
5
-using System.Web;
6
-
7
-namespace CallCenterApi.Interface.Models.Filter
8
-{
9
-    public class FilterCallPlan : ListBase
10
-    {
11
-        /// <summary>
12
-        /// 任务类型, 1=点击外呼; 2=自动外呼; 默认为2
13
-        /// </summary>
14
-        public int TaskType { get; set; } = 2;
15
-        /// <summary>
16
-        /// 任务名称
17
-        /// </summary>
18
-        public string Name { get; set; }
19
-
20
-    }
21
-}

+ 1 - 1
RMYY_CallCenter_Api/Models/Filter/FilterCategory.cs

@@ -4,7 +4,7 @@ using System.Collections.Generic;
4 4
 using System.Linq;
5 5
 using System.Web;
6 6
 
7
-namespace CallCenterApi.Interface.Models.Filter
7
+namespace RMYY_CallCenter_Api.Models
8 8
 {
9 9
     public class FilterCategory : ListBase
10 10
     {

+ 1 - 1
RMYY_CallCenter_Api/Models/Filter/FilterDictionary.cs

@@ -4,7 +4,7 @@ using System.Collections.Generic;
4 4
 using System.Linq;
5 5
 using System.Web;
6 6
 
7
-namespace CallCenterApi.Interface.Models
7
+namespace RMYY_CallCenter_Api.Models
8 8
 {
9 9
     public class FilterDictionary : ListBase
10 10
     {

+ 0 - 14
RMYY_CallCenter_Api/Models/Filter/FilterExpress.cs

@@ -1,14 +0,0 @@
1
-using CallCenterApi.Interface.Models.Common;
2
-using System;
3
-using System.Collections.Generic;
4
-using System.Linq;
5
-using System.Web;
6
-
7
-namespace CallCenterApi.Interface.Models.Filter
8
-{
9
-    public class FilterExpress : ListBase
10
-    {
11
-        public string Name { get; set; }
12
-
13
-    }
14
-}

+ 1 - 1
RMYY_CallCenter_Api/Models/Filter/FilterLog.cs

@@ -4,7 +4,7 @@ using System.Collections.Generic;
4 4
 using System.Linq;
5 5
 using System.Web;
6 6
 
7
-namespace CallCenterApi.Interface.Models.Filter
7
+namespace RMYY_CallCenter_Api.Models
8 8
 {
9 9
     public class FilterLog : ListBase
10 10
     {

+ 0 - 13
RMYY_CallCenter_Api/Models/Filter/FilterModuleFunction.cs

@@ -1,13 +0,0 @@
1
-using CallCenterApi.Interface.Models.Common;
2
-using System;
3
-using System.Collections.Generic;
4
-using System.Linq;
5
-using System.Web;
6
-
7
-namespace CallCenterApi.Interface.Models.Filter
8
-{
9
-    public class FilterModuleFunction : ListBase
10
-    {
11
-        public int ModuleFunctionId { get; set; } = 0;
12
-    }
13
-}

+ 0 - 14
RMYY_CallCenter_Api/Models/Filter/FilterOrder.cs

@@ -1,14 +0,0 @@
1
-using CallCenterApi.Interface.Models.Common;
2
-using System;
3
-using System.Collections.Generic;
4
-using System.Linq;
5
-using System.Web;
6
-
7
-namespace CallCenterApi.Interface.Models.Filter
8
-{
9
-    public class FilterOrder : ListBase
10
-    {
11
-        
12
-
13
-    }
14
-}

+ 1 - 1
RMYY_CallCenter_Api/Models/Filter/FilterPagerInfo.cs

@@ -4,7 +4,7 @@ using System.Collections.Generic;
4 4
 using System.Linq;
5 5
 using System.Web;
6 6
 
7
-namespace CallCenterApi.Interface.Models.Filter
7
+namespace RMYY_CallCenter_Api.Models
8 8
 {
9 9
     public class FilterPagerInfo : ListBase
10 10
     {

+ 1 - 1
RMYY_CallCenter_Api/Models/Filter/FilterProduct.cs

@@ -4,7 +4,7 @@ using System.Collections.Generic;
4 4
 using System.Linq;
5 5
 using System.Web;
6 6
 
7
-namespace CallCenterApi.Interface.Models.Filter
7
+namespace RMYY_CallCenter_Api.Models
8 8
 {
9 9
     public class FilterProduct : ListBase
10 10
     {

+ 1 - 1
RMYY_CallCenter_Api/Models/Filter/FilterQuestion.cs

@@ -4,7 +4,7 @@ using System.Collections.Generic;
4 4
 using System.Linq;
5 5
 using System.Web;
6 6
 
7
-namespace CallCenterApi.Interface.Models.Filter
7
+namespace RMYY_CallCenter_Api.Models
8 8
 {
9 9
     public class FilterQuestion : ListBase
10 10
     {

+ 1 - 1
RMYY_CallCenter_Api/Models/Filter/FilterSysConfig.cs

@@ -4,7 +4,7 @@ using System.Collections.Generic;
4 4
 using System.Linq;
5 5
 using System.Web;
6 6
 
7
-namespace CallCenterApi.Interface.Models.Filter
7
+namespace RMYY_CallCenter_Api.Models
8 8
 {
9 9
     public class FilterSysConfig : ListBase
10 10
     {

+ 0 - 48
RMYY_CallCenter_Api/Models/Filter/FilterTalkRecord.cs

@@ -1,48 +0,0 @@
1
-using CallCenterApi.Interface.Models.Common;
2
-using System;
3
-using System.Collections.Generic;
4
-using System.Linq;
5
-using System.Web;
6
-
7
-namespace CallCenterApi.Interface.Models.Filter
8
-{
9
-    public class FilterTalkRecord : ListBase
10
-    {
11
-        /// <summary>
12
-        /// 通话号码
13
-        /// </summary>
14
-        public string Phone { get; set; }
15
-        /// <summary>
16
-        /// 通话类型   
17
-        /// 1=未转坐席;
18
-        /// 2=转坐席未接通;
19
-        /// 3=转坐席接通;
20
-        /// </summary>
21
-        public int CallType { get; set; } = 0;
22
-        /// <summary>
23
-        /// 坐席工号
24
-        /// </summary>
25
-        public string UserCode { get; set; }
26
-        /// <summary>
27
-        /// 页容量
28
-        /// </summary>
29
-        public new int PageSize { get; set; } = 100;
30
-        /// <summary>
31
-        /// 排序  排序字段,升降序
32
-        /// </summary>
33
-        public string SortField { get; set; }
34
-        /// <summary>
35
-        /// 开始时间
36
-        /// </summary>
37
-        public DateTime? StartTime { get; set; }
38
-        /// <summary>
39
-        /// 结束时间
40
-        /// </summary>
41
-        public DateTime? EndTime { get; set; }
42
-        /// <summary>
43
-        /// 通话时长
44
-        /// </summary>
45
-        public string TalkTime { get; set; }
46
-
47
-    }
48
-}

+ 1 - 1
RMYY_CallCenter_Api/Models/Filter/FilterUserAccount.cs

@@ -4,7 +4,7 @@ using System.Collections.Generic;
4 4
 using System.Linq;
5 5
 using System.Web;
6 6
 
7
-namespace CallCenterApi.Interface.Models.Filter
7
+namespace RMYY_CallCenter_Api.Models
8 8
 {
9 9
     public class FilterUserAccount : ListBase
10 10
     {

+ 0 - 5
RMYY_CallCenter_Api/RMYY_CallCenter_Api.csproj

@@ -135,18 +135,13 @@
135 135
     <Compile Include="Global.asax.cs">
136 136
       <DependentUpon>Global.asax</DependentUpon>
137 137
     </Compile>
138
-    <Compile Include="Models\Filter\FilterCallPlan.cs" />
139 138
     <Compile Include="Models\Filter\FilterCategory.cs" />
140 139
     <Compile Include="Models\Filter\FilterDictionary.cs" />
141
-    <Compile Include="Models\Filter\FilterExpress.cs" />
142 140
     <Compile Include="Models\Filter\FilterLog.cs" />
143
-    <Compile Include="Models\Filter\FilterModuleFunction.cs" />
144
-    <Compile Include="Models\Filter\FilterOrder.cs" />
145 141
     <Compile Include="Models\Filter\FilterPagerInfo.cs" />
146 142
     <Compile Include="Models\Filter\FilterProduct.cs" />
147 143
     <Compile Include="Models\Filter\FilterQuestion.cs" />
148 144
     <Compile Include="Models\Filter\FilterSysConfig.cs" />
149
-    <Compile Include="Models\Filter\FilterTalkRecord.cs" />
150 145
     <Compile Include="Models\Filter\FilterUserAccount.cs" />
151 146
     <Compile Include="Models\FormsPrincipal.cs" />
152 147
     <Compile Include="Models\Input\DictionaryInput.cs" />