优化运营后台状态展示

master
lifenlong 2021-06-23 00:21:17 +08:00
parent 8e239a5bbf
commit 5b3c89886e
19 changed files with 101 additions and 305 deletions

View File

@ -147,21 +147,13 @@ export default {
sortable: false,
render: (h, params) => {
if (params.row.distributionStatus == "PASS") {
return h("Badge", {
props: { status: "success", text: "审核通过" },
});
return h("Tag", {props: {color: "green",},},"通过");
} else if (params.row.distributionStatus == "APPLY") {
return h("Badge", {
props: { status: "processing", text: "申请中" },
});
return h("Tag", {props: {color: "geekblue",},},"待审核");
} else if (params.row.distributionStatus == "RETREAT") {
return h("Badge", {
props: { status: "warning", text: "已清退" },
});
return h("Tag", {props: {color: "volcano",},},"清退");
} else if (params.row.distributionStatus == "REFUSE") {
return h("Badge", {
props: { status: "error", text: "审核拒绝" },
});
return h("Tag", {props: {color: "red",},},"拒绝");
}
},
},

View File

@ -186,11 +186,11 @@ export default {
width: 130,
render: (h, params) => {
if (params.row.goodsType === 'PHYSICAL_GOODS') {
return h("div", "实物商品");
return h("Tag", {props: {color: "green",},}, "实物商品");
} else if (params.row.goodsType === 'VIRTUAL_GOODS') {
return h("div", "虚拟商品");
return h("Tag", {props: {color: "volcano",},}, "虚拟商品");
} else {
return h("div", "电子卡券");
return h("Tag", {props: {color: "geekblue",},}, "电子卡券");
}
},
},
@ -200,23 +200,9 @@ export default {
width: 100,
render: (h, params) => {
if (params.row.marketEnable == "DOWN") {
return h("div", [
h("Badge", {
props: {
status: "error",
text: "下架",
},
}),
]);
return h("Tag", {props: {color: "green"},},"上架");
} else if (params.row.marketEnable == "UPPER") {
return h("div", [
h("Badge", {
props: {
status: "success",
text: "上架",
},
}),
]);
return h("Tag", {props: {color: "volcano",},},"下架");
}
},
},
@ -226,36 +212,14 @@ export default {
width: 130,
render: (h, params) => {
if (params.row.isAuth == "TOBEAUDITED") {
return h("div", [
h("Badge", {
props: {
status: "error",
text: "待审核",
},
}),
]);
return h("Tag", {props: {color: "volcano",},},"待审核");
} else if (params.row.isAuth == "PASS") {
return h("div", [
h("Badge", {
props: {
status: "success",
text: "审核通过",
},
}),
]);
return h("Tag", {props: {color: "green"},},"通过");
} else if (params.row.isAuth == "REFUSE") {
return h("div", [
h("Badge", {
props: {
status: "error",
text: "审核拒绝",
},
}),
]);
return h("Tag", {props: {color: "red",},},"拒绝");
}
},
},
{
title: "店铺名称",
key: "storeName",

View File

@ -113,23 +113,9 @@ export default {
align: "left",
render: (h, params) => {
if (params.row.deleteFlag == 0) {
return h("div", [
h("Badge", {
props: {
status: "success",
text: "启用",
},
}),
]);
return h("Tag", {props: {color: "green",},},"启用");
} else if (params.row.deleteFlag == 1) {
return h("div", [
h("Badge", {
props: {
status: "error",
text: "禁用",
},
}),
]);
return h("Tag", {props: {color: "volcano",},},"禁用");
}
},
filters: [

View File

@ -135,35 +135,11 @@ export default {
width: 90,
render: (h, params) => {
if (params.row.grade == "GOOD") {
return h(
"Tag",
{
props: {
color: "success",
},
},
"好评"
);
return h("Tag", {props: {color: "green",},}, "好评");
} else if (params.row.grade == "MODERATE") {
return h(
"Tag",
{
props: {
color: "warning",
},
},
"中评"
);
return h("Tag", {props: {color: "orange",},}, "中评");
} else {
return h(
"Tag",
{
props: {
color: "error",
},
},
"差评"
);
return h("Tag", {props: {color: "red",},}, "差评");
}
},
},

View File

@ -131,23 +131,9 @@
sortable: false,
render: (h, params) => {
if (params.row.payStatus == "PAID") {
return h("div", [
h("Badge", {
props: {
status: "success",
text: "已付款",
},
}),
]);
} else if (params.row.payStatus == "UNPAID") {
return h("div", [
h("Badge", {
props: {
status: "error",
text: "未付款",
},
}),
]);
return h("Tag", {props: {color: "green",},}, "已付款");
} else {
return h("Tag", {props: {color: "red",},}, "未付款");
}
},
},

View File

@ -216,11 +216,11 @@
width: 100,
render: (h, params) => {
if (params.row.serviceType == "RETURN_MONEY") {
return h('div', [h('span', {}, '退款'),]);
return h('div', [h('tag', {props: {color: "blue"}}, '退款'),]);
} else if (params.row.serviceType == "RETURN_GOODS") {
return h('div', [h('span', {}, '退货'),]);
return h('div', [h('tag', {props: {color: "volcano"}}, '退货'),]);
} else if (params.row.serviceType == "EXCHANGE_GOODS") {
return h('div', [h('span', {}, '换货'),]);
return h('div', [h('tag', {props: {color: "green"}}, '换货'),]);
}
}
},
@ -231,27 +231,23 @@
width: 110,
render: (h, params) => {
if (params.row.serviceStatus == "APPLY") {
return h('div', [h('span', {}, '申请中'),]);
return h('div', [h('tag', {props: {color: "blue"}}, '申请中'),]);
} else if (params.row.serviceStatus == "PASS") {
return h('div', [h('span', {}, '通过售后'),]);
return h('div', [h('tag', {props: {color: "cyan"}}, '通过售后'),]);
} else if (params.row.serviceStatus == "REFUSE") {
return h('div', [h('span', {}, '拒绝售后'),]);
return h('div', [h('tag', {props: {color: "volcano"}}, '拒绝售后'),]);
} else if (params.row.serviceStatus == "BUYER_RETURN") {
return h('div', [h('span', {}, '买家退货,待卖家收货'),]);
} else if (params.row.serviceStatus == "SELLER_RE_DELIVERY") {
return h('div', [h('span', {}, '商家换货/补发'),]);
return h('div', [h('tag', {props: {color: "orange"}}, '买家退货,待卖家收货'),]);
} else if (params.row.serviceStatus == "SELLER_CONFIRM") {
return h('div', [h('span', {}, '卖家确认收货'),]);
return h('div', [h('tag', {props: {color: "gold"}}, '卖家确认收货'),]);
} else if (params.row.serviceStatus == "SELLER_TERMINATION") {
return h('div', [h('span', {}, '卖家终止售后'),]);
} else if (params.row.serviceStatus == "BUYER_CONFIRM") {
return h('div', [h('span', {}, '买家确认收货'),]);
return h('div', [h('tag', {props: {color: "lime"}}, '卖家终止售后'),]);
} else if (params.row.serviceStatus == "BUYER_CANCEL") {
return h('div', [h('span', {}, '买家取消售后'),]);
return h('div', [h('tag', {props: {color: "purple"}}, '买家取消售后'),]);
} else if (params.row.serviceStatus == "COMPLETE") {
return h('div', [h('span', {}, '完成售后'),]);
return h('div', [h('tag', {props: {color: "green"}}, '完成售后'),]);
}else if (params.row.serviceStatus == "WAIT_REFUND") {
return h('div', [h('span', {}, '待平台退款'),]);
return h('div', [h('tag', {props: {color: "geekblue"}}, '待平台退款'),]);
}
}
},

View File

@ -191,17 +191,17 @@
width: 100,
render: (h, params) => {
if (params.row.complainStatus == "NEW") {
return h('div', [h('span', { }, '新投诉'),]);
return h('div', [h('tag',{props: {color: "purple"}}, '新投诉'),]);
} else if (params.row.complainStatus == "CANCEL") {
return h('div', [h('span', { }, '已撤销'),]);
return h('div', [h('tag', {props: {color: "cyan"}}, '已撤销'),]);
} else if (params.row.complainStatus == "WAIT_APPEAL") {
return h('div', [h('span', { }, '待申诉'),]);
return h('div', [h('tag', {props: {color: "volcano"}}, '待申诉'),]);
} else if (params.row.complainStatus == "COMMUNICATION") {
return h('div', [h('span', { }, '对话中'),]);
return h('div', [h('tag', {props: {color: "orange"}}, '对话中'),]);
}else if (params.row.complainStatus == "WAIT_ARBITRATION") {
return h('div', [h('span', { }, '等待仲裁'),]);
return h('div', [h('tag', {props: {color: "blue"}}, '等待仲裁'),]);
}else if (params.row.complainStatus == "COMPLETE") {
return h('div', [h('span', { }, '已完成'),]);
return h('div', [h('tag', {props: {color: "green"}}, '已完成'),]);
}
}
},

View File

@ -72,51 +72,13 @@ export default {
align: "center",
render: (h, params) => {
if (params.row.paymentMethod === "WECHAT") {
return h("div", [
h(
"Tag",
{
props: {
color: "green",
},
},
"微信"
),
]);
return h("div", [h("Tag", {props: {color: "green",},}, "微信"),]);
} else if (params.row.paymentMethod === "ALIPAY") {
return h("div", [
h(
"Tag",
{
props: {
color: "blue",
},
},
"支付宝"
),
]);
return h("div", [h("Tag", {props: {color: "blue",},}, "支付宝"),]);
} else if (params.row.paymentMethod === "WALLET") {
return h("div", [
h(
"Tag",
{
props: {},
},
"余额支付"
),
]);
return h("div", [h("Tag", {props: {color: "geekblue",},}, "余额支付"),]);
} else if (params.row.paymentMethod === "BANK_TRANSFER") {
return h("div", [
h(
"Tag",
{
props: {
color: "orange",
},
},
"银行转帐"
),
]);
return h("div", [h("Tag", {props: {color: "orange",},}, "银行转帐"),]);
} else {
return h("div", [h("Tag", {}, "暂未付款")]);
}

View File

@ -100,9 +100,9 @@ export default {
width: 95,
render: (h, params) => {
if (params.row.isRefund == "1") {
return h("div", [h("span", {}, "已退款")]);
return h("div", [h("Tag", {props: {color: "green",},}, "已退款")]);
} else {
return h("div", [h("span", {}, "未退款")]);
return h("div", [h("Tag", {props: {color: "orange",},}, "未退款")]);
}
},
},

View File

@ -150,19 +150,15 @@
width:95,
render: (h, params) => {
if (params.row.orderStatus == "UNPAID") {
return h('div', [h('span', { }, '未付款'),]);
return h("div", [h("tag", {props: {color: "magenta"}}, "未付款")]);
} else if (params.row.orderStatus == "PAID") {
return h('div', [h('span', { }, '已付款'),]);
} else if (params.row.orderStatus == "UNDELIVERED") {
return h('div', [h('span', { }, '待发货'),]);
} else if (params.row.orderStatus == "DELIVERED") {
return h('div', [h('span', { }, '已发货'),]);
}else if (params.row.orderStatus == "COMPLETED") {
return h('div', [h('span', { }, '已完成'),]);
}else if (params.row.orderStatus == "TAKE") {
return h('div', [h('span', { }, '待核验'),]);
}else if (params.row.orderStatus == "CANCELLED") {
return h('div', [h('span', { }, '已取消'),]);
return h("div", [h("tag", {props: {color: "blue"}}, "已付款")]);
} else if (params.row.orderStatus == "COMPLETED") {
return h("div", [h("tag", {props: {color: "green"}}, "已完成")]);
} else if (params.row.orderStatus == "TAKE") {
return h("div", [h("tag", {props: {color: "volcano"}}, "待核验")]);
} else if (params.row.orderStatus == "CANCELLED") {
return h("div", [h("tag", {props: {color: "red"}}, "已取消")]);
}
}
},

View File

@ -166,13 +166,13 @@ export default {
width: 120,
render: (h, params) => {
if (params.row.orderType == "NORMAL") {
return h("div", [h("span", {}, "普通订单")]);
return h("div", [h("tag", {props: {color: "blue"}}, "普通订单")]);
} else if (params.row.orderType == "PINTUAN") {
return h("div", [h("span", {}, "拼团订单")]);
return h("div", [h("tag", {props: {color: "volcano"}}, "拼团订单")]);
} else if (params.row.orderType == "GIFT") {
return h("div", [h("span", {}, "赠品订单")]);
return h("div", [h("tag", {props: {color: "green"}}, "赠品订单")]);
} else if (params.row.orderType == "VIRTUAL") {
return h("div", [h("tag", {}, "核验订单")]);
return h("div", [h("tag", {props: {color: "geekblue"}}, "核验订单")]);
}
},
},
@ -202,19 +202,19 @@ export default {
minWidth: 100,
render: (h, params) => {
if (params.row.orderStatus == "UNPAID") {
return h("div", [h("span", {}, "未付款")]);
return h("div", [h("tag", {props: {color: "magenta"}}, "未付款")]);
} else if (params.row.orderStatus == "PAID") {
return h("div", [h("span", {}, "已付款")]);
return h("div", [h("tag", {props: {color: "blue"}}, "已付款")]);
} else if (params.row.orderStatus == "UNDELIVERED") {
return h("div", [h("span", {}, "待发货")]);
return h("div", [h("tag", {props: {color: "geekblue"}}, "待发货")]);
} else if (params.row.orderStatus == "DELIVERED") {
return h("div", [h("span", {}, "已发货")]);
return h("div", [h("tag", {props: {color: "cyan"}}, "已发货")]);
} else if (params.row.orderStatus == "COMPLETED") {
return h("div", [h("span", {}, "已完成")]);
return h("div", [h("tag", {props: {color: "green"}}, "已完成")]);
} else if (params.row.orderStatus == "TAKE") {
return h("div", [h("span", {}, "待核验")]);
return h("div", [h("tag", {props: {color: "volcano"}}, "待核验")]);
} else if (params.row.orderStatus == "CANCELLED") {
return h("div", [h("span", {}, "已取消")]);
return h("div", [h("tag", {props: {color: "red"}}, "已取消")]);
}
},
},

View File

@ -131,13 +131,14 @@ export default {
key: "couponType",
width: 120,
render: (h, params) => {
let text = "未知";
let text = "";
if (params.row.couponType === "DISCOUNT") {
text = "打折";
return h("Tag", {props: {color: "blue",},}, "打折");
} else if (params.row.couponType === "PRICE") {
text = "减免现金";
return h("Tag", {props: {color: "geekblue",},}, "减免现金");
}else {
return h("Tag", {props: {color: "purple",},}, "未知");
}
return h("div", [text]);
},
},
{
@ -184,7 +185,7 @@ export default {
color = "red";
if (params.row.promotionStatus == "NEW") {
text = "未开始";
color = "default";
color = "geekblue";
} else if (params.row.promotionStatus == "START") {
text = "已开始";
color = "green";

View File

@ -132,19 +132,19 @@ export default {
minWidth: 60,
render: (h, params) => {
let text = "未知",
color = "default";
color = "purple";
if (params.row.promotionStatus == "NEW") {
text = "未开始";
color = "default";
color = "geekblue";
} else if (params.row.promotionStatus == "START") {
text = "已开始";
color = "green";
color = "blue";
} else if (params.row.promotionStatus == "END") {
text = "已结束";
color = "blue";
color = "green";
} else if (params.row.promotionStatus == "CLOSE") {
text = "已关闭";
color = "red";
color = "volcano";
}
return h("div", [
h(

View File

@ -122,16 +122,16 @@ export default {
color = "";
if (params.row.promotionStatus == "NEW") {
text = "未开始";
color = "default";
color = "geekblue";
} else if (params.row.promotionStatus == "START") {
text = "已开始";
color = "green";
color = "blue";
} else if (params.row.promotionStatus == "END") {
text = "已结束";
color = "blue";
color = "green";
} else if (params.row.promotionStatus == "CLOSE") {
text = "已关闭";
color = "red";
color = "volcano";
}
return h("div", [
h(

View File

@ -92,7 +92,7 @@
<div>{{ row.startTime }}</div>
<div>{{ row.endTime }}</div>
</template>
<template slot-scope="{ row }" slot="action">
<Button
v-if="row.promotionStatus == 'NEW'"
@ -213,16 +213,16 @@ export default {
color = "";
if (params.row.promotionStatus == "NEW") {
text = "未开始";
color = "default";
color = "geekblue";
} else if (params.row.promotionStatus == "START") {
text = "已开始";
color = "green";
color = "blue";
} else if (params.row.promotionStatus == "END") {
text = "已结束";
color = "blue";
color = "green";
} else if (params.row.promotionStatus == "CLOSE") {
text = "已关闭";
color = "red";
color = "volcano";
}
return h("div", [h("Tag", { props: { color: color } }, text)]);
},

View File

@ -145,41 +145,13 @@ export default {
width: 100,
render: (h, params) => {
if (params.row.promotionStatus == "NEW") {
return h("div", [
h("Badge", {
props: {
status: "error",
text: "新建",
},
}),
]);
return h("Tag", {props: {color: "volcano",},},"新建");
} else if (params.row.promotionStatus == "START") {
return h("div", [
h("Badge", {
props: {
status: "success",
text: "开始",
},
}),
]);
return h("Tag", {props: {color: "blue",},},"开始");
} else if (params.row.promotionStatus == "END") {
return h("div", [
h("Badge", {
props: {
status: "error",
text: "结束",
},
}),
]);
return h("Tag", {props: {color: "green",},},"结束");
} else if (params.row.promotionStatus == "CLOSE") {
return h("div", [
h("Badge", {
props: {
status: "error",
text: "废弃",
},
}),
]);
return h("Tag", {props: {color: "volcano",},},"结束");
}
},
},

View File

@ -95,13 +95,13 @@ export default {
width: 100,
render: (h, params) => {
if (params.row.billStatus == "OUT") {
return h("div", "已出账");
return h("Tag", {props: {color: "blue",},},"已出账");
} else if (params.row.billStatus == "CHECK") {
return h("div", "已对账");
return h("Tag", {props: {color: "geekblue",},},"已对账");
} else if (params.row.billStatus == "EXAMINE") {
return h("div", "已审核");
return h("Tag", {props: {color: "purple",},},"已审核");
} else {
return h("div", "已付款");
return h("Tag", {props: {color: "green",},},"已付款");
}
},
},

View File

@ -106,13 +106,13 @@ export default {
width: 100,
render: (h, params) => {
if (params.row.billStatus == "OUT") {
return h("div", "已出账");
return h("Tag", {props: {color: "blue",},},"已出账");
} else if (params.row.billStatus == "CHECK") {
return h("div", "已对账");
return h("Tag", {props: {color: "geekblue",},},"已对账");
} else if (params.row.billStatus == "EXAMINE") {
return h("div", "已审核");
return h("Tag", {props: {color: "purple",},},"已审核");
} else {
return h("div", "已付款");
return h("Tag", {props: {color: "green",},},"已付款");
}
},
},

View File

@ -126,7 +126,7 @@ export default {
"Tag",
{
props: {
color: params.row.selfOperated ? "error" : "success",
color: params.row.selfOperated ? "volcano" : "green",
},
},
params.row.selfOperated ? "自营" : "非自营"
@ -141,50 +141,15 @@ export default {
width: 130,
render: (h, params) => {
if (params.row.storeDisable == "OPEN") {
return h("div", [
h("Badge", {
props: {
status: "success",
text: "开启中",
},
}),
]);
return h("Tag", {props: {color: "green",},},"开启中");
} else if (params.row.storeDisable == "CLOSED") {
return h("div", [
h("Badge", {
props: {
status: "error",
text: "已关闭",
},
}),
]);
return h("Tag", {props: {color: "volcano",},},"已关闭");
} else if (params.row.storeDisable == "APPLY") {
return h("div", [
h("Badge", {
props: {
status: "error",
text: "申请中",
},
}),
]);
return h("Tag", {props: {color: "geekblue",},},"申请中");
} else if (params.row.storeDisable == "APPLYING") {
return h("div", [
h("Badge", {
props: {
status: "error",
text: "审核中",
},
}),
]);
return h("Tag", {props: {color: "purple",},},"审核中");
} else if (params.row.storeDisable == "REFUSED") {
return h("div", [
h("Badge", {
props: {
status: "error",
text: "审核拒绝",
},
}),
]);
return h("Tag", {props: {color: "red",},},"审核拒绝");
}
},
},