diff --git a/src/api/productAttr.js b/src/api/productAttr.js new file mode 100644 index 0000000..474ab02 --- /dev/null +++ b/src/api/productAttr.js @@ -0,0 +1,16 @@ +import request from '@/utils/request' +export function fetchList(cid,params) { + return request({ + url:'/productAttribute/list/'+cid, + method:'get', + params:params + }) +} + +export function deleteProductAttr(data) { + return request({ + url:'/productAttribute/delete', + method:'post', + data:data + }) +} diff --git a/src/router/index.js b/src/router/index.js index 7927511..74084c1 100644 --- a/src/router/index.js +++ b/src/router/index.js @@ -74,6 +74,13 @@ export const constantRouterMap = [ component: () => import('@/views/pms/productAttr/index'), meta: {title: '商品类型', icon: 'product-attr'} }, + { + path: 'productAttrList', + name: 'productAttrList', + component: () => import('@/views/pms/productAttr/productAttrList'), + meta: {title: '商品属性列表'}, + hidden:true + }, { path: 'addProductAttr', name: 'addProductAttr', diff --git a/src/views/pms/productAttr/index.vue b/src/views/pms/productAttr/index.vue index c400419..c86bf7c 100644 --- a/src/views/pms/productAttr/index.vue +++ b/src/views/pms/productAttr/index.vue @@ -157,10 +157,10 @@ this.productAttrCate.id = row.id; }, getAttrList(index, row) { - console.log('addProductAttrCate') + this.$router.push({path: '/pms/productAttrList',query:{cid:row.id,cname:row.name,type:0}}) }, getParamList(index, row) { - console.log('addProductAttrCate') + this.$router.push({path: '/pms/productAttrList',query:{cid:row.id,cname:row.name,type:1}}) }, handleConfirm(formName){ this.$refs[formName].validate((valid) => { diff --git a/src/views/pms/productAttr/productAttrList.vue b/src/views/pms/productAttr/productAttrList.vue new file mode 100644 index 0000000..5211f47 --- /dev/null +++ b/src/views/pms/productAttr/productAttrList.vue @@ -0,0 +1,239 @@ + + + + + +