product.js
6.17 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
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
exports.domain = require('../config/common.js').domain;
// exports.domain ="http://172.16.6.227:8088/platform";
//路由配置
exports.res = [
{
//商品管理【品类列表】页面渲染
route: '/erpproduct/sort/index',
method: 'GET',
view: 'pages/product/index',
src: '/product/index',
url: '/product/queryAllProductSortList',
},{
//商品管理【ajax查询所有品类】
route: '/product/class/queryAllProductSortList',
method: 'POST',
url: '/product/queryAllMaxSortList',
},{
//商品管理【根据ID ajax查询子品类列表】
route: '/product/class/queryProductSortList',
method: 'POST',
url: '/product/queryProductSortList',
params: [
{name: 'param', type: 'Number'}
]
},{
//商品管理>【添加品类】页面渲染
route: '/product/class/new',
method: 'GET',
view: 'pages/product/new-class',
src: '/product/add',
data: {
data: {
status: 1
},
pagetitle:"添加品类",
action:"/product/sort/addProductSort"
}
},{
//商品管理>【添加品类】ajax请求接口
route: '/product/sort/addProductSort',
method: 'POST',
url: '/product/addProductSort',
params: [
{name: 'sortName', type: 'String'},
{name: 'sortInitials', type: 'String'},
{name:'firstSortId', type: 'Number'},
{name:'secondSortId', type:'Number'},
{name:'threeSortId', type:'Number'},
{name: 'orderBy', type: 'Number'},
{name: 'status', type: 'Number'}
]
},{
//商品管理>【编辑品类】页面
route: '/product/class/edit/:param',
method: 'GET',
view: 'pages/product/new-class',
src: '/product/add',
data:{
pagetitle:"修改品类",
action:"/product/sort/update"
}
},{
route:'/product/class/getProductSort',
url:'/product/getProductSort',
method: 'POST',
params: [
{name: 'param', type: 'Number'}
]
},{
//商品管理>【品类列表ajax更新】
route: '/product/sort/update',
method: 'POST',
url: '/product/updateProductSort',
params: [
{name: 'id', type: 'Number'},
{name: 'sortName', type: 'String'},
{name: 'sortInitials', type: 'String'},
{name:'firstSortId', type: 'Number'},
{name:'secondSortId', type:'Number'},
{name:'threeSortId', type:'Number'},
{name: 'orderBy', type: 'Number'},
{name: 'status', type: 'Number'}
]
},{
route:"/erpproduct/sorter/open",
method: 'POST',
url: '/product/publishProductSort',
params: [
{name: 'param', type: 'Number'}
]
},{
route:"/erpproduct/sorter/close",
method: 'POST',
url: '/product/closeProductSort',
params: [
{name: 'param', type: 'Number'}
]
},
{
//商品管理>【产品属性】页面渲染
route: '/erpproduct/attribute/index',
method: 'GET',
view: 'pages/product/product-attr',
//url: '/product/queryAllProductSortList',
url:'/product/queryProductSortListByConf',
src: '/product/attr',
params:[
{name: 'status', type: 'String', def:1}
]
},
{
//商品管理>【产品属性ajax获取】
route: '/product/attr/get',
method: 'POST',
url: '/product/getAttr',
},{
//商品管理>【添加产品属性ajax】
route: '/product/attr/add',
method: 'POST',
url: '/product/addProductAttribute',
params: [
{name: 'attributeName', type: 'String'},
{name: 'saleType', type: 'Number'},
{name: 'inputType', type: 'String'},
{name: 'attributeType', type: 'String'},
{name: 'isMust', type: 'String'},
{name: 'isSearch', type: 'String'},
{name: 'maxValueLen', type: 'Number'},
{name: 'isAllowAlias', type: 'String'},
{name: 'orderBy', type: 'Number'},
{name: 'state', type: 'Number'},
{name: 'remark', type: 'String'},
{name: 'attributeValues', type: 'String'},
{name: 'displayPosition', type: 'Number'},
{name: 'categoryId', type: 'Number'}
]
},{
//商品管理>【更新产品属性ajax】
route: '/product/attr/update',
method: 'POST',
url: '/product/updateProductAttribute',
params: [
{name: 'attributeName', type: 'String'},
{name: 'saleType', type: 'Number'},
{name: 'inputType', type: 'String'},
{name: 'attributeType', type: 'String'},
{name: 'isMust', type: 'String'},
{name: 'isSearch', type: 'String'},
{name: 'maxValueLen', type: 'Number'},
{name: 'isAllowAlias', type: 'String'},
{name: 'orderBy', type: 'Number'},
{name: 'state', type: 'Number'},
{name: 'remark', type: 'String'},
{name: 'attributeValues', type: 'String'},
{name: 'displayPosition', type: 'Number'},
{name: 'attributeId', type: 'Number'},
{name: 'categoryId', type: 'Number'}
]
},{
//商品管理【根据类目ID ajax查询属性列表】
route: '/product/attr/queryProductAttributeList',
method: 'POST',
url: '/product/queryProductAttributeList',
params: [
{name: 'categoryId', type: 'Number'},
{name: 'page', type: 'Number'},
{name: 'size', type: 'Number'}
]
},{
//商品管理【根据类目ID ajax查询属性的详细信息】
route: '/product/attr/getProductAttribute',
method: 'POST',
url: '/product/getProductAttribute',
params: [
{name: 'attributeId', type: 'Number'}
]
}
];