From ebacb580490be3559fc4ddb1f234aeabbc70573a Mon Sep 17 00:00:00 2001 From: paulGao Date: Fri, 27 May 2022 16:07:54 +0800 Subject: [PATCH] =?UTF-8?q?=E5=95=86=E5=93=81=E6=90=9C=E7=B4=A2=E4=BC=98?= =?UTF-8?q?=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- manager/src/views/goods/goods-info/goods.vue | 56 ++++++++++++++++++-- 1 file changed, 52 insertions(+), 4 deletions(-) diff --git a/manager/src/views/goods/goods-info/goods.vue b/manager/src/views/goods/goods-info/goods.vue index da261ca8..73473a05 100644 --- a/manager/src/views/goods/goods-info/goods.vue +++ b/manager/src/views/goods/goods-info/goods.vue @@ -27,6 +27,15 @@ style="width: 200px" /> + + + + + + - @@ -112,7 +136,12 @@ > - +
@@ -120,7 +149,9 @@
- +
@@ -169,7 +200,24 @@ export default { key: "price", width: 130, render: (h, params) => { - return h("div", this.$options.filters.unitPrice(params.row.price, "¥")); + return h( + "div", + this.$options.filters.unitPrice(params.row.price, "¥") + ); + }, + }, + { + title: "销售模式", + key: "salesModel", + width: 100, + render: (h, params) => { + if (params.row.salesModel === "RETAIL") { + return h("Tag", { props: { color: "orange" } }, "零售"); + } else if (params.row.salesModel === "WHOLESALE") { + return h("Tag", { props: { color: "magenta" } }, "批发"); + } else { + return h("Tag", { props: { color: "volcano" } }, "其他类型"); + } }, }, {