attrVal.js
875 Bytes
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
import request from '@/utils/request'
export default{
getAttrVals: function (idAttrKey) {
return request({
url: '/shop/attr/val/getAttrVals',
method: 'get',
params: {
idAttrKey: idAttrKey
}
})
},
save: function (params) {
return request({
url: '/shop/attr/val',
method: 'post',
params
})
},
remove: function (id) {
return request({
url: '/shop/attr/val',
method: 'delete',
params: {
id: id
}
})
},
updateAttrVal:function(id,attrVal){
return request({
url: '/shop/attr/val/updateAttrVal',
method: 'POST',
params: {
id: id,
attrVal:attrVal
}
})
},
getAttrBy: function(idCategory) {
return request({
url: '/shop/attr/val/getAttrByCategoryAndGoods/'+idCategory,
method: 'get'
})
}
}