|
|
@@ -12,6 +12,8 @@ namespace CallCenterApi.Interface.Controllers.knowledge
|
|
12
|
12
|
[Authority]
|
|
13
|
13
|
public class KnowledgeClassController : BaseController
|
|
14
|
14
|
{
|
|
|
15
|
+ private BLL.T_Sys_UserAccount userbll = new BLL.T_Sys_UserAccount();
|
|
|
16
|
+ private BLL.T_Sys_RoleInfo rolebll = new BLL.T_Sys_RoleInfo();
|
|
15
|
17
|
// 获取知识库分类列表
|
|
16
|
18
|
public ActionResult GetAllList()
|
|
17
|
19
|
{
|
|
|
@@ -23,6 +25,27 @@ namespace CallCenterApi.Interface.Controllers.knowledge
|
|
23
|
25
|
|
|
24
|
26
|
return Success("加载成功", dt);
|
|
25
|
27
|
}
|
|
|
28
|
+
|
|
|
29
|
+ // 二级网络单位知识库索要录添加知识库 获取知识库分类列表
|
|
|
30
|
+ public ActionResult GetAllListEJ()
|
|
|
31
|
+ {
|
|
|
32
|
+ DataTable dt = new DataTable();
|
|
|
33
|
+
|
|
|
34
|
+
|
|
|
35
|
+
|
|
|
36
|
+ dt = new BLL.T_RepositoryCategory().GetList("").Tables[0];
|
|
|
37
|
+
|
|
|
38
|
+ List<Model.TreeModel> modelList = BindTree(dt, "0");
|
|
|
39
|
+
|
|
|
40
|
+ if (modelList.Count > 0)
|
|
|
41
|
+ {
|
|
|
42
|
+ return Success("加载成功", modelList);
|
|
|
43
|
+ }
|
|
|
44
|
+ else
|
|
|
45
|
+ return Error("加载失败");
|
|
|
46
|
+ }
|
|
|
47
|
+
|
|
|
48
|
+
|
|
26
|
49
|
// 获取知识库分类列表
|
|
27
|
50
|
public ActionResult GetList()
|
|
28
|
51
|
{
|
|
|
@@ -36,6 +59,14 @@ namespace CallCenterApi.Interface.Controllers.knowledge
|
|
36
|
59
|
else
|
|
37
|
60
|
sql += " and F_ParentId=0";
|
|
38
|
61
|
|
|
|
62
|
+ Model.T_Sys_RoleInfo role = rolebll.GetModel("WLDW");
|
|
|
63
|
+ if (User.F_RoleId == role.F_RoleId)
|
|
|
64
|
+ {
|
|
|
65
|
+ sql = " and F_ParentId=0 and F_CategoryId in ( select F_CategoryId from T_RepositoryCategory where F_CategoryName ='知识信息分类')";
|
|
|
66
|
+
|
|
|
67
|
+ }
|
|
|
68
|
+
|
|
|
69
|
+
|
|
39
|
70
|
dt = new BLL.T_RepositoryCategory().GetList(" 1=1 " + sql).Tables[0];
|
|
40
|
71
|
List<Model.TreeModel> modelList = BindTree(dt, "0");
|
|
41
|
72
|
|