Commit 2151c5de by wangzhihui

bug修复

1 parent 0dc8b187
......@@ -174,17 +174,20 @@ export default {
let merchantNos = []
this.conditionData.metricRuleList.forEach((item) => {
if (item.active) {
if (item.merchantNos && item.merchantNos.length) {
merchantNos.push(...item.merchantNos)
console.log(item)
if (!item.merchantNos || item.merchantNos.length == 0) {
item.merchantNos = [-1]
}
merchantNos.push(item.merchantNos.join(","))
}
})
console.log(merchantNos)
if (merchantNos.length > 0) {
this.$refs.editFormRef.$refs[this.handleFormRef].clearValidate(
`merchantNos`
)
}
this.coustomForm.merchantNos = merchantNos.join(",")
this.coustomForm.merchantNos = merchantNos
},
handleData(val) {
this.coustomForm.brandId = val.id
......
......@@ -109,7 +109,7 @@ ${this.title}:${
: rate.indexOf("-") > -1
? "#2CCA74"
: "#EB4E4E"
}">${rate == "null" ? "-" : rate ? rate : 0}${
}">${rate == "null" ? "-" : rate ? rate + "%" : 0 + "%"}${
rate == "null" || rate == 0
? ""
: rate.indexOf("-") > -1
......
......@@ -120,7 +120,7 @@ ${this.title}:${
: rate.indexOf("-") > -1
? "#2CCA74"
: "#EB4E4E"
}">${rate == "null" ? "-" : rate ? rate : 0}${
}">${rate == "null" ? "-" : rate ? rate + "%" : 0 + "%"}${
rate == "null" || rate == 0
? ""
: rate.indexOf("-") > -1
......
......@@ -26,7 +26,7 @@
></div>
<template
v-if="
item.key == 'merchantNames' || item.key == 'superiors'
item.key == 'merchantName' || item.key == 'superiors'
"
>
<template
......@@ -99,8 +99,15 @@
>
<div slot="OutputValue" slot-scope="scope">
<div>
¥{{ scope.scope.lastOutputValue || "-" }} → ¥{{
scope.scope.currentOutputValue || "-"
¥{{
scope.scope.lastOutputValue === 0
? 0
: scope.scope.lastOutputValue || "-"
}}
→ ¥{{
scope.scope.currentOutputValue === 0
? 0
: scope.scope.currentOutputValue || "-"
}}
</div>
<div
......@@ -113,14 +120,24 @@
: ''
]"
>
环 {{ scope.scope.outputValueRate }}
环 {{ scope.scope.outputValueRate }}%
</div>
<div v-else class="normal">
环 {{ scope.scope.outputValueRate === 0 ? 0 + "%" : "-" }}
</div>
<div v-else class="normal">环 -</div>
</div>
<div slot="Conversion" slot-scope="scope">
<div>
{{ scope.scope.lastConversion || "-" }}% →
{{ scope.scope.currentConversion || "-" }}%
{{
scope.scope.lastConversion === 0
? 0
: scope.scope.lastConversion || "-"
}}% →
{{
scope.scope.currentConversion === 0
? 0
: scope.scope.currentConversion || "-"
}}%
</div>
<div
v-if="scope.scope.conversionRate"
......@@ -132,14 +149,23 @@
: ''
]"
>
环 {{ scope.scope.conversionRate }}
环 {{ scope.scope.conversionRate }}%
</div>
<div v-else class="normal">
环 {{ scope.scope.conversionRate === 0 ? 0 + "%" : "-" }}
</div>
<div v-else class="normal">环 -</div>
</div>
<div slot="CustomerUnitPrice" slot-scope="scope">
<div>
¥{{ scope.scope.lastCustomerUnitPrice || "-" }} → ¥{{
scope.scope.currentCustomerUnitPrice || "-"
¥{{
scope.scope.lastCustomerUnitPrice === 0
? 0
: scope.scope.lastCustomerUnitPrice || "-"
}}
→ ¥{{
scope.scope.currentCustomerUnitPrice === 0
? 0
: scope.scope.currentCustomerUnitPrice || "-"
}}
</div>
<div
......@@ -153,9 +179,11 @@
: ''
]"
>
环 {{ scope.scope.customerUnitPriceRate }}
环 {{ scope.scope.customerUnitPriceRate }}%
</div>
<div v-else class="normal">
环 {{ scope.scope.customerUnitPriceRate === 0 ? 0 + "%" : "-" }}
</div>
<div v-else class="normal">环 -</div>
</div>
</d2-table>
</div>
......@@ -203,7 +231,7 @@ export default {
},
{
title: "门店:",
key: "merchantNames"
key: "merchantName"
},
{
title: "上级:",
......@@ -354,8 +382,8 @@ export default {
},
{
staffName: this.paramsObj.staffPhone,
merchantNames: this.paramsObj.merchantName,
staffName: this.paramsObj.staffName
merchantName: this.paramsObj.merchantName,
staffPhone: this.paramsObj.staffPhone
}
)
}
......
......@@ -25,7 +25,7 @@
></div>
<template
v-if="
item.key == 'merchantNames' || item.key == 'superiors'
item.key == 'merchantName' || item.key == 'superiors'
"
>
<template
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!