Commit 9e69707b authored by wanglianghe's avatar wanglianghe

产品类型统计产品数量,产品列表

parent 48d2dcdc
import request from '@/utils/request'
// 创建产品
export function createProduct(data) {
return request({
url: '/ecw/product/create',
method: 'post',
data: data
})
}
// 更新产品
export function updateProduct(data) {
return request({
url: '/ecw/product/update',
method: 'put',
data: data
})
}
// 删除产品
export function deleteProduct(id) {
return request({
url: '/ecw/product/delete?id=' + id,
method: 'delete'
})
}
// 获得产品
export function getProduct(id) {
return request({
url: '/ecw/product/get?id=' + id,
method: 'get'
})
}
// 获得产品分页
export function getProductPage(query) {
return request({
url: '/ecw/product/page',
method: 'get',
params: query
})
}
// 导出产品 Excel
export function exportProductExcel(query) {
return request({
url: '/ecw/product/export-excel',
method: 'get',
params: query,
responseType: 'blob'
})
}
......@@ -34,6 +34,15 @@ export function getProductAttr(id) {
})
}
// 获得所有产品属性
export function getProductAttrList(query) {
return request({
url: '/ecw/product-attr/list',
method: 'get',
params: query
})
}
// 获得产品属性分页
export function getProductAttrPage(query) {
return request({
......
......@@ -34,6 +34,15 @@ export function getProductType(id) {
})
}
// 获得产品类型
export function getProductTypeList(query) {
return request({
url: '/ecw/product-type/list',
method: 'get',
params: query
})
}
// 获得产品类型分页
export function getProductTypePage(query) {
return request({
......
......@@ -12,6 +12,11 @@ export const CommonStatusEnum = {
DISABLE: 1 // 禁用
}
export const AuditStatusEnum = {
PASS: 0,
NOT_PASS: 1
}
/**
* 菜单的类型枚举
*/
......
......@@ -8,6 +8,7 @@ import store from '@/store'
export const DICT_TYPE = {
USER_TYPE: 'user_type',
COMMON_STATUS: 'common_status',
AUDIT_STATUS: 'audit_status',
// ========== SYSTEM 模块 ==========
SYSTEM_USER_SEX: 'system_user_sex',
......
This diff is collapsed.
......@@ -85,7 +85,7 @@ import { getDictDatas, DICT_TYPE } from '@/utils/dict'
export default {
name: "ProductAttr",
components: {
Editor,
},
data() {
return {
......
......@@ -28,6 +28,11 @@
<el-table-column label="排序" align="center" prop="sort" />
<el-table-column label="中文标题" align="center" prop="titleZh" />
<el-table-column label="英文标题" align="center" prop="titleEn" />
<el-table-column label="产品统计" align="center" prop="productNum" width="100">
<template slot-scope="scope">
<span>{{scope.row.productNum }}</span>
</template>
</el-table-column>
<el-table-column label="发布时间" align="center" prop="createTime" width="180">
<template slot-scope="scope">
<span>{{ parseTime(scope.row.createTime) }}</span>
......
......@@ -362,7 +362,6 @@ export default {
}
}
}
},
},
......
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