Commit a39fef88 authored by zhanglw's avatar zhanglw

产品保存

parent ba532b9d
import request from '@/utils/request' import request from '@/utils/request'
import qs from 'qs'
export const HttpReq = { export const HttpReq = {
// 后台管理接口列表 // 后台管理接口列表
...@@ -6,7 +7,7 @@ export const HttpReq = { ...@@ -6,7 +7,7 @@ export const HttpReq = {
// 上传营业执照图片 // 上传营业执照图片
uploadBusinessLicense: function(data) { uploadBusinessLicense: function(data) {
return request({ return request({
url: '/api/bsw/users/updateBusinessLicense', url: '/api/bsw/users/uploadBusinessLicense',
method: 'post', method: 'post',
data: data data: data
}).then((res) => { }).then((res) => {
...@@ -23,23 +24,103 @@ export const HttpReq = { ...@@ -23,23 +24,103 @@ export const HttpReq = {
}) })
}, },
// 获取行政区划 // 获取行政区划
findAreaByCodeAndType: function(param) { findAreaByCodeAndType: function(params) {
return request({ return request({
url: '/api/bsw/users/findAreaByCodeAndType', url: '/api/bsw/users/findAreaByCodeAndType?' + qs.stringify(params, { indices: false }),
method: 'get', method: 'get'
params: param
}) })
}, },
// 获取行政区划 // 添加客户信息
addCustomer: function(data) { addCustomer: function(data) {
return request({ return request({
url: '/api/bsw/users/addCustomer', url: '/api/bsw/users/addCustomer',
method: 'POST', method: 'post',
data: data data: data
}).then((res) => { }).then((res) => {
return res return res
}) })
} },
// 修改客户信息
updateCustomerDetail: function(data) {
return request({
url: '/api/bsw/users/updateCustomerDetail',
method: 'put',
data: data
}).then((res) => {
return res
})
},
// 获取客户列表
queryCustomer: function(params) {
return request({
url: '/api/bsw/users/queryCustomer?' + qs.stringify(params, { indices: false }),
method: 'get'
})
},
// 客户信息详情
queryCustomerDetail: function(params) {
return request({
url: '/api/bsw/users/queryCustomerDetail?' + qs.stringify(params, { indices: false }),
method: 'get'
})
},
// 批量禁用启用客户
userEnableDisable: function(data) {
return request({
url: '/api/bsw/users/enableDisable',
method: 'put',
data: data
}).then((res) => {
return res
})
},
// 客户信息审核
reviewCustomer: function(data) {
return request({
url: '/api/bsw/users/reviewCustomer',
method: 'put',
data: data
}).then((res) => {
return res
})
},
// 上传产品图片
uploadProductPic: function(data) {
return request({
url: '/api/bsw/product/uploadProductPic',
method: 'post',
data: data
}).then((res) => {
return res
})
},
deleteProductPic: function(data) {
return request({
url: '/api/bsw/product/deleteProductPic',
method: 'delete',
data: data
}).then((res) => {
return res
})
},
// 联想查询供应商名称
associateQueryEnterpriseName: function(params) {
return request({
url: '/api/bsw/product/associateQueryEnterpriseName?' + qs.stringify(params, { indices: false }),
method: 'get'
})
},
// 添加产品详情
addProduct: function(data) {
return request({
url: '/api/bsw/product/addProduct',
method: 'post',
data: data
}).then((res) => {
return res
})
},
xxx: null
} }
} }
...@@ -127,7 +127,7 @@ export default { ...@@ -127,7 +127,7 @@ export default {
}) })
}, },
toAdd() { toAdd() {
this.$refs.addView.showView() this.$refs.addView.loadData()
}, },
toEdit(item) { toEdit(item) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment