fix: 账户状态统一修改。

This commit is contained in:
tianyongbao
2025-12-24 18:18:58 +08:00
parent 106f1cf117
commit 5c40cc4189
17 changed files with 114 additions and 162 deletions

View File

@@ -67,20 +67,12 @@ const data = reactive({
const {detailInfo} = toRefs(data)
function getStatusClass(status, statusText) {
// 优先根据状态文字判断
if (statusText && statusText.includes('正常')) {
return 'status-normal'
}
if (statusText && (statusText.includes('销卡') || statusText.includes('销户'))) {
return 'status-error'
}
// 备用:根据状态值判断
// 根据状态判断
const statusStr = String(status)
if (statusStr === '2') {
if (statusStr === '1') {
return 'status-normal'
}
if (statusStr === '0' || statusStr === '3' || statusStr === '4') {
if (statusStr === '5') {
return 'status-error'
}

View File

@@ -166,24 +166,16 @@ function settingCancel() {
settingPickShow.value = false
}
function getStatusClass(status, statusText) {
// 根据状态文字判断(更可靠)
if (statusText && statusText.includes('正常')) {
return 'status-normal'
}
if (statusText && (statusText.includes('销卡') || statusText.includes('销户'))) {
return 'status-error'
}
// 备用:根据状态值判断
const statusStr = String(status)
if (statusStr === '2') {
return 'status-normal'
}
if (statusStr === '0' || statusStr === '3' || statusStr === '4') {
return 'status-error'
}
return 'status-default'
// 根据状态值判断
const statusStr = String(status)
if (statusStr === '1') {
return 'status-normal'
}
if (statusStr === '5') {
return 'status-error'
}
return 'status-default'
}
function dictStr(val, arr) {