diff --git a/README.md b/README.md index 96d6fd2b..cb458f4a 100644 --- a/README.md +++ b/README.md @@ -115,5 +115,6 @@ this.tableHeader = ['门店名称', '地址', '经度', '纬度', '管理员id', - 新建价格变更单页面完成 2019/03/06 16:00 - 价格变更单列表页面完成 2019/03/06 17:09 - 短信模板设置页面完成 2019/03/06 19:12 - +- 计量单位设置页面完成 2019/03/06 20:00 +晚安世界 ``` \ No newline at end of file diff --git a/src/api/BasicSettings.js b/src/api/BasicSettings.js index 4d0c9922..2e863a4b 100644 --- a/src/api/BasicSettings.js +++ b/src/api/BasicSettings.js @@ -161,3 +161,78 @@ export function deletemodel(query) { data: params }) } + +// 查询计量单位列表 +export function searchMea(query) { + var params = new URLSearchParams() + if (query.iseffective !== '' && query.iseffective !== null && query.iseffective !== undefined) { + params.append('iseffective', query.iseffective) // 你要传给后台的参数值 key/value + } + if (query.categoryname !== '' && query.categoryname !== null && query.categoryname !== undefined) { + params.append('categoryname', query.categoryname) // 你要传给后台的参数值 key/value + } + if (query.type !== '' && query.type !== null && query.type !== undefined) { + params.append('type', query.type) // 你要传给后台的参数值 key/value + } + params.append('pagenum', query.pagenum) // 你要传给后台的参数值 key/value + params.append('pagesize', query.pagesize) // 你要传给后台的参数值 key/value + return request({ + url: 'http://192.168.1.45:8080/erp/measurement/search', + method: 'post', + data: params + }) +} + +// 新增计量单位 +export function createmea(query) { + var params = new URLSearchParams() + if (query.category !== '' && query.category !== null && query.category !== undefined) { + params.append('category', query.category) // 你要传给后台的参数值 key/value + } + if (query.type !== '' && query.type !== null && query.type !== undefined) { + params.append('type', query.type) // 你要传给后台的参数值 key/value + } + if (query.iseffective !== '' && query.iseffective !== null && query.iseffective !== undefined) { + params.append('iseffective', query.iseffective) // 你要传给后台的参数值 key/value + } + if (query.categoryname !== '' && query.categoryname !== null && query.categoryname !== undefined) { + params.append('categoryname', query.categoryname) // 你要传给后台的参数值 key/value + } + return request({ + url: 'http://192.168.1.45:8080/erp/measurement/create', + method: 'post', + data: params + }) +} + +// 修改计量单位 +export function updatemea(query) { + var params = new URLSearchParams() + if (query.id !== '' && query.id !== null && query.id !== undefined) { + params.append('id', query.id) // 你要传给后台的参数值 key/value + } + if (query.isEffective !== '' && query.isEffective !== null && query.isEffective !== undefined) { + params.append('iseffective', query.isEffective) // 你要传给后台的参数值 key/value + } + if (query.categoryName !== '' && query.categoryName !== null && query.categoryName !== undefined) { + params.append('categoryname', query.categoryName) // 你要传给后台的参数值 key/value + } + return request({ + url: 'http://192.168.1.45:8080/erp/measurement/update', + method: 'post', + data: params + }) +} + +// 批量删除计量单位 +export function deletemea(query) { + var params = new URLSearchParams() + if (query !== '' && query !== null && query !== undefined) { + params.append('modelids', query) // 你要传给后台的参数值 key/value + } + return request({ + url: 'http://192.168.1.45:8080/erp/measurement/delete', + method: 'post', + data: params + }) +} diff --git a/src/lang/zh.js b/src/lang/zh.js index 37d2cdb8..62b575e6 100644 --- a/src/lang/zh.js +++ b/src/lang/zh.js @@ -38,8 +38,9 @@ export default { NumberingRules: '单据编号设置', Newadjustprice: '新建价格变更单', AdjustpriceList: '价格变更单列表', - addSMS: '新增短信模板', - SMSModelList: '短信设置' + SMSModelList: '短信设置', + Measurement: '计量单位设置', + Commission: '提成设置' }, navbar: { logOut: '退出登录', @@ -295,7 +296,14 @@ export default { createTime: '创建日期', modelname: '短信模板名称', content: '内容', - iseffective2: '是否启用' + iseffective2: '是否启用', + categoryname: '计量单位名称', + type2: '计量单位类别', + iseffective3: '状态', + roleId: '员工职位', + productCategoryId: '商品类别', + commissionType: '提成类型', + commissionValue: '提成' }, public: { uploadimage: '上传', diff --git a/src/router/index.js b/src/router/index.js index d36fecef..a5c10017 100644 --- a/src/router/index.js +++ b/src/router/index.js @@ -333,10 +333,16 @@ export const asyncRouterMap = [ meta: { title: 'SMSModelList', noCache: true } }, { - path: 'addSMS', - component: () => import('@/views/BasicSettings/addSMS'), - name: 'addSMS', - meta: { title: 'addSMS', noCache: false } + path: 'Measurement', + component: () => import('@/views/BasicSettings/Measurement'), + name: 'Measurement', + meta: { title: 'Measurement', noCache: true } + }, + { + path: 'Commission', + component: () => import('@/views/BasicSettings/Commission'), + name: 'Commission', + meta: { title: 'Commission', noCache: true } } ] }, diff --git a/src/views/BasicSettings/Commission.vue b/src/views/BasicSettings/Commission.vue new file mode 100644 index 00000000..6342b4b3 --- /dev/null +++ b/src/views/BasicSettings/Commission.vue @@ -0,0 +1,408 @@ + + + + + diff --git a/src/views/BasicSettings/Measurement.vue b/src/views/BasicSettings/Measurement.vue new file mode 100644 index 00000000..f8fa1ca2 --- /dev/null +++ b/src/views/BasicSettings/Measurement.vue @@ -0,0 +1,427 @@ + + + + + diff --git a/src/views/BasicSettings/addSMS.vue b/src/views/BasicSettings/addSMS.vue deleted file mode 100644 index 6c6183ef..00000000 --- a/src/views/BasicSettings/addSMS.vue +++ /dev/null @@ -1,210 +0,0 @@ - - - - -