guang.info.js
2.93 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
/**
* Created by ty on 2016/6/20.
* 资讯管理
*/
module.exports=function(app) {
/*首页*/
app.get("/guang/article/index","guang.info.Index", function () {
this.$extend = {
iscreate: true,
moduleName: "资讯管理",
pageName: "资讯列表管理"
};
});
/*添加*/
app.get("/guang/article/contentAdd","guang.info.Edit", ["common_aggStyle"],function (style,req,res) {
this.$extend = {
action:"/guang/article/addArticle",
moduleName: "文章管理",
pageName: "添加文章"
};
var style=(JSON.parse(style)).data;
style=style.map(function(item){
return {stylename:item.style_name};
});
return {style:style};
});
/*编辑*/
app.get("/guang/article/contentEdit/:id","guang.info.Edit","common_aggStyle", function (style) {
this.$extend = {
action:"/guang/article/updateArticle",
moduleName: "文章管理",
pageName: "修改文章"
};
var style=(JSON.parse(style)).data;
style=style.map(function(item){
return {stylename:item.style_name};
});
return {style:style};
});
/*资讯管理列表数据*/
app.post("/guang/article/list","infoManager_getList");
/*资讯管理-列表操作(修改、发布、关闭、推荐、取消推荐)*/
app.post("/guang/article/operation","infoManager_operation");
/*资讯管理-定时*/
app.post("/guang/article/timmer","infoManager_timePublish");
/*资讯管理-删除*/
app.post("/guang/article/del","infoManager_delArticle");
//================================= [下拉框调用的接口]
/*作者列表*/
app.post("/guang/article/getAuthorList","infoManager_getAuthorList");
/*可用的作者列表*/
app.post("/guang/article/getUsedAuthorList","infoManager_getUsedAuthorList");
/*所有分类*/
// app.post("/guang/article/getSortList","infoManager_getSortList");
/*根据是否启用获取标签分类列表*/
app.post("/guang/tagSort/getTagItems","infoManager_getTagItems");
/*plus star 频道*/
app.post("/guang/plustarcategory/getCategoryNames","infoManager_getCategoryNames");
/*添加文章*/
app.post("/guang/article/addArticle","infoManager_addArticle");
/*更新文章*/
app.post("/guang/article/updateArticle","infoManager_updateArticle");
/*获取文章详情*/
app.post("/guang/article/getDetail","infoManager_getDetail");
/*获取标签列表*/
app.post("/guang/tags/getTags","infoManager_getTags");
/*获取文章详情*/
app.post("/guang/queryAllGoodsSort","infoManager_queryAllGoodsSort");
app.get("/guang/updateArticlePic/background/:page", "guang.info.Update");
app.post("/guang/updateArticlePic", "infoManager_updateArticlePic");
app.post("/guang/article/syncArticleToGrass", "infoManager_syncArticleToGrass");
}