You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
94 lines
2.2 KiB
94 lines
2.2 KiB
import request from '@/utils/request'
|
|
|
|
export default {
|
|
|
|
// 查询分页列表
|
|
listPage: function(params) {
|
|
return request({
|
|
url: '/wms/apiadmin/base/basegoodsspu/listPage',
|
|
// url: '/wms/apiadmin/base/basegoodsspu/goodsListPage',
|
|
method: 'post',
|
|
data: params,
|
|
headers: {
|
|
'Content-Type': 'application/json'
|
|
}
|
|
})
|
|
},
|
|
|
|
// 修改是否可用状态
|
|
updateIsEnable: function(sid, isEnable) {
|
|
return request({
|
|
url: '/wms/apiadmin/base/basegoodsspu/updateIsEnable/' + sid + "/" + isEnable
|
|
});
|
|
},
|
|
|
|
// 新增、保存
|
|
saveGoods: function(data) {
|
|
return request({
|
|
url: '/wms/apiadmin/base/basegoodsspu/saveOrUpdate',
|
|
// url: '/wms/apiadmin/base/basegoodsspu/saveOrUpdateGoods',
|
|
method: 'post',
|
|
data: data,
|
|
headers: {
|
|
'Content-Type': 'application/json'
|
|
}
|
|
});
|
|
},
|
|
|
|
// 初始化
|
|
initGoods: function(data) {
|
|
return request({
|
|
url: '/wms/apiadmin/base/basegoodsspu/initialization/' + data,
|
|
// url: '/wms/apiadmin/base/basegoodsspu/goodsDetails/' + data,
|
|
method: 'get'
|
|
});
|
|
},
|
|
|
|
// 商品规格 修改是否可用状态
|
|
updateIsEnable2: function(sid, isEnable) {
|
|
return request({
|
|
url: '/wms/apiadmin/base/basegoodsspu/updateIsEnablebySku/' + sid + "/" + isEnable
|
|
});
|
|
},
|
|
|
|
|
|
|
|
// 商品-- 删除
|
|
deleteBySids: function(data) {
|
|
return request({
|
|
url: '/wms/apiadmin/base/basegoodsspu/delBySids',
|
|
// url: '/wms/apiadmin/base/basegoodsspu/delGoodsBySids',
|
|
method: 'DELETE',
|
|
data: data,
|
|
headers: {
|
|
'Content-Type': 'application/json'
|
|
}
|
|
})
|
|
},
|
|
|
|
// 下载模板
|
|
downloadExcel: function() {
|
|
return request({
|
|
url: '/wms/apiadmin/base/basegoodsspu/download',
|
|
method: 'post',
|
|
responseType: 'blob', // 表明返回服务器返回的数据类型
|
|
headers: {
|
|
'Content-Type': 'application/json'
|
|
}
|
|
})
|
|
},
|
|
|
|
// 查询商品分页列表
|
|
getGoodsListAllByOrg: function(params) {
|
|
return request({
|
|
url: '/wms/apiadmin/basegoodssku/listAllByOrg',
|
|
// url: '/wms/apiadmin/base/basegoodsspu/goodsListPage',
|
|
method: 'post',
|
|
data: params,
|
|
headers: {
|
|
'Content-Type': 'application/json'
|
|
}
|
|
})
|
|
},
|
|
|
|
}
|
|
|