Showing
1 changed file
with
277 additions
and
0 deletions
inferface-document/size.md
0 → 100644
1 | +# 产品管理接口服务定义 | ||
2 | +--------------------- | ||
3 | + | ||
4 | +# 添加(更新)品类接口 | ||
5 | + | ||
6 | +> 接口名: `/product/update` | ||
7 | + | ||
8 | +### 入参 | ||
9 | + | ||
10 | +------------------------- | ||
11 | +|属性名称|类型|例子|说明|是否必填| | ||
12 | +|--------|----|----|----|--------| | ||
13 | +|categoryName|string|nike|品类名称|是| | ||
14 | +|categoryAbbr|string|n|品类缩写|是| | ||
15 | +|firstCategory|string|根目录|一级分类|否| | ||
16 | +|secondCategory|string|根目录|二级分类|否| | ||
17 | +|thirdCategory|string|根目录|三级分类|否| | ||
18 | +|categorySort|number|0|排序|否| | ||
19 | +|categoryStatus|boolean|true|状态|否| | ||
20 | +|id|int|1|品类ID| | ||
21 | +--------------------- | ||
22 | + | ||
23 | +### 返回 | ||
24 | + | ||
25 | +``` json | ||
26 | +{ | ||
27 | + "code":200, | ||
28 | + "message":"添加成功!" | ||
29 | +} | ||
30 | + | ||
31 | +``` | ||
32 | + | ||
33 | +# 获取品类列表 | ||
34 | + | ||
35 | +> 接口名: `/product/getClassList` | ||
36 | + | ||
37 | +### 入参 | ||
38 | + | ||
39 | +------------------------- | ||
40 | +|属性名称|类型|例子|说明|是否必填| | ||
41 | +|-------|----|----|----|-------| | ||
42 | +-------------------------------- | ||
43 | + | ||
44 | +### 返回 | ||
45 | + | ||
46 | +``` json | ||
47 | +{ | ||
48 | + code:200, | ||
49 | + message:"", | ||
50 | + data: { | ||
51 | + list: [{ | ||
52 | + categoryName: '', //品类名称 | ||
53 | + categoryAbbr: '', //品类缩写 | ||
54 | + firstCategory: '', //一级分类 | ||
55 | + secondCategory: '', //二级分类 | ||
56 | + thirdCategory: '', //三级分类 | ||
57 | + categorySort: '', //排序 | ||
58 | + categoryStatus: '',//状态, | ||
59 | + id: '', //品类ID | ||
60 | + }] | ||
61 | + page: '', //当前第几页 | ||
62 | + size: '', //每页多少条 | ||
63 | + } | ||
64 | +} | ||
65 | + | ||
66 | +``` | ||
67 | + | ||
68 | + | ||
69 | +# 添加产品属性接口 | ||
70 | + | ||
71 | +> 接口名: `/product/addProductAttribute` | ||
72 | + | ||
73 | +### 入参 | ||
74 | + | ||
75 | +------------------------- | ||
76 | +|属性名称|类型|例子|说明|是否必填| | ||
77 | +|--------|----|----|----|--------| | ||
78 | +|attributeName|string|衣长|属性名称|是| | ||
79 | +|categoryId|number|6|目录ID|是| | ||
80 | +|saleType|number|1|销售类型|是| | ||
81 | +|inputType|string|checkbox|输入类型|是| | ||
82 | +|attributeType|number|2|属性类型|否| | ||
83 | +|isMust|String|N|是否必选|否| | ||
84 | +|isSearch|String|Y|是否启动搜索|否| | ||
85 | +|maxValueLen|number|50|最大输入值|否| | ||
86 | +|isAllowAlias|String|N|是否允许别名|否| | ||
87 | +|orderBy|number|0|排序|否| | ||
88 | +|state|number|1|状态|否| | ||
89 | +|remark|string|abc|备注|否| | ||
90 | +|attributeValues|string|反光,毛呢,网布,皮革,麻,帆布|属性值|是| | ||
91 | +|displayPosition|int|1|展示位置|是 | ||
92 | +--------------------- | ||
93 | + | ||
94 | +### 返回 | ||
95 | + | ||
96 | +``` json | ||
97 | +{ | ||
98 | + "code": 200, | ||
99 | + "data": [], | ||
100 | + "md5": "d751713988987e9331980363e24189ce", | ||
101 | + "message": "Product Attribute Add success." | ||
102 | +} | ||
103 | + | ||
104 | +``` | ||
105 | + | ||
106 | +# 更新产品属性接口 | ||
107 | + | ||
108 | +> 接口名: `/product/updateProductAttribute` | ||
109 | + | ||
110 | +### 入参 | ||
111 | + | ||
112 | +------------------------- | ||
113 | +|属性名称|类型|例子|说明|是否必填| | ||
114 | +|--------|----|----|----|--------| | ||
115 | +|attributId|int|15|属性ID|是| | ||
116 | +|attributeName|string|衣长|属性名称|是| | ||
117 | +|categoryId|number|6|目录ID|是| | ||
118 | +|saleType|number|1|销售类型|是| | ||
119 | +|inputType|string|checkbox|输入类型|是| | ||
120 | +|attributeType|number|2|属性类型|否| | ||
121 | +|isMust|String|N|是否必选|否| | ||
122 | +|isSearch|String|Y|是否启动搜索|否| | ||
123 | +|maxValueLen|number|50|最大输入值|否| | ||
124 | +|isAllowAlias|String|N|是否允许别名|否| | ||
125 | +|orderBy|number|0|排序|否| | ||
126 | +|state|number|1|状态|否| | ||
127 | +|remark|string|abc|备注|否| | ||
128 | +|attributeValues|string|反光,毛呢,网布,皮革,麻,帆布|属性值|是| | ||
129 | +|displayPosition|int|1|展示位置|是 | ||
130 | +--------------------- | ||
131 | + | ||
132 | +### 返回 | ||
133 | + | ||
134 | +``` json | ||
135 | +{ | ||
136 | + "code": 200, | ||
137 | + "data": [], | ||
138 | + "md5": "d751713988987e9331980363e24189ce", | ||
139 | + "message": "Product Attribute update success." | ||
140 | +} | ||
141 | + | ||
142 | +``` | ||
143 | + | ||
144 | +# 获取产品属性列表接口 | ||
145 | + | ||
146 | +> 接口名: `/product/queryProductAttributeList` | ||
147 | + | ||
148 | +### 入参 | ||
149 | + | ||
150 | +------------------------- | ||
151 | +|属性名称|类型|例子|说明|是否必填| | ||
152 | +|--------|----|----|----|--------| | ||
153 | +|categoryId|int|1|目录ID|是 | ||
154 | +--------------------- | ||
155 | + | ||
156 | +### 返回 | ||
157 | + | ||
158 | +``` json | ||
159 | +{ | ||
160 | + "code": 200, | ||
161 | + "data": [ | ||
162 | + { | ||
163 | + "attributeId": 15, | ||
164 | + "attributeName": "防风外套属性", | ||
165 | + "attributeType": 2, | ||
166 | + "attributeValues": "11", | ||
167 | + "belong": 1, | ||
168 | + "categoryId": 454, | ||
169 | + "createTime": 1453951139, | ||
170 | + "displayPosition": 1, | ||
171 | + "inputType": "checkbox", | ||
172 | + "isAllowAlias": "Y", | ||
173 | + "isColor": "N", | ||
174 | + "isMust": "Y", | ||
175 | + "isSearch": "Y", | ||
176 | + "maxValueLen": 50, | ||
177 | + "orderBy": 0, | ||
178 | + "remark": "备注", | ||
179 | + "saleType": 0, | ||
180 | + "state": 0 | ||
181 | + }, | ||
182 | + { | ||
183 | + "attributeId": 16, | ||
184 | + "attributeName": "纹理", | ||
185 | + "attributeType": 2, | ||
186 | + "attributeValues": "条纹,豹纹", | ||
187 | + "belong": 1, | ||
188 | + "categoryId": 454, | ||
189 | + "createTime": 1453966719, | ||
190 | + "displayPosition": 2, | ||
191 | + "inputType": "checkbox", | ||
192 | + "isAllowAlias": "N", | ||
193 | + "isColor": "N", | ||
194 | + "isMust": "N", | ||
195 | + "isSearch": "N", | ||
196 | + "maxValueLen": 50, | ||
197 | + "orderBy": 0, | ||
198 | + "remark": "备注", | ||
199 | + "saleType": 0, | ||
200 | + "state": 1 | ||
201 | + } | ||
202 | + ], | ||
203 | + "md5": "b4a7dec9fb1b236e4aec02ba40411e42", | ||
204 | + "message": "Product Attribute List." | ||
205 | +} | ||
206 | + | ||
207 | +``` | ||
208 | + | ||
209 | +# 获取产品单个属性列表接口 | ||
210 | + | ||
211 | +> 接口名: `/product/getProductAttribute` | ||
212 | + | ||
213 | +### 入参 | ||
214 | + | ||
215 | +------------------------- | ||
216 | +|属性名称|类型|例子|说明|是否必填| | ||
217 | +|--------|----|----|----|--------| | ||
218 | +|attributeId|int|1|属性ID|是 | ||
219 | +--------------------- | ||
220 | + | ||
221 | +### 返回 | ||
222 | + | ||
223 | +``` json | ||
224 | +{ | ||
225 | + "code": 200, | ||
226 | + "data": { | ||
227 | + "attributeId": 22, | ||
228 | + "attributeName": "材质", | ||
229 | + "attributeType": 2, | ||
230 | + "attributeValues": "反光,毛呢,网布,皮革,麻,帆布", | ||
231 | + "belong": 1, | ||
232 | + "categoryId": 6, | ||
233 | + "createTime": 1453970276, | ||
234 | + "displayPosition": 1, | ||
235 | + "inputType": "checkbox", | ||
236 | + "isAllowAlias": "N", | ||
237 | + "isColor": "N", | ||
238 | + "isMust": "N", | ||
239 | + "isSearch": "N", | ||
240 | + "maxValueLen": 50, | ||
241 | + "orderBy": 0, | ||
242 | + "remark": "备注", | ||
243 | + "saleType": 1, | ||
244 | + "state": 1 | ||
245 | + }, | ||
246 | + "md5": "dfc645ecb0c66c8d4771dd2a749047e8", | ||
247 | + "message": "Product Attribute get success." | ||
248 | +} | ||
249 | + | ||
250 | +``` | ||
251 | + | ||
252 | +# 获取产品列表 | ||
253 | + | ||
254 | +> 接口名: `/product/getList` | ||
255 | + | ||
256 | +------------------------- | ||
257 | +|属性名称|类型|例子|说明|是否必填| | ||
258 | +|--------|----|----|----|--------| | ||
259 | +| | | | | | | ||
260 | +--------------------- | ||
261 | + | ||
262 | +### 返回 | ||
263 | + | ||
264 | +``` json | ||
265 | +{ | ||
266 | + code:200, | ||
267 | + message:"", | ||
268 | + data: { | ||
269 | + list: [{ | ||
270 | + //... | ||
271 | + }] | ||
272 | + page: '', //当前第几页 | ||
273 | + size: '', //每页多少条 | ||
274 | + } | ||
275 | +} | ||
276 | + | ||
277 | +``` |
-
Please register or login to post a comment