fix: 新增字段
Some checks failed
构建并部署前端到测试环境 / build-and-deploy (push) Failing after 37m49s

This commit is contained in:
luo
2026-10-12 14:53:27 +08:00
parent e009c1cb0b
commit 9a636a953b
8 changed files with 1266 additions and 76 deletions

View File

@@ -68,6 +68,19 @@ export function useAssetFormatters() {
return map[status] || 'info'
}
// 获取网络状态名称和标签类型,缺失状态不能误报为停机。
const getNetworkStatusName = (status?: number) => {
if (status === 1) return '正常'
if (status === 0) return '停机'
return '未知'
}
const getNetworkStatusType = (status?: number): TagType => {
if (status === 1) return 'success'
if (status === 0) return 'danger'
return 'info'
}
// 获取实名认证策略名称
const getRealnamePolicyName = (policy?: string) => {
if (!policy || policy === '') return '未知'
@@ -261,6 +274,8 @@ export function useAssetFormatters() {
formatIccidWithDashes,
getRealNameStatusName,
getRealNameStatusType,
getNetworkStatusName,
getNetworkStatusType,
getRealnamePolicyName,
getCarrierTypeName,
getAssetStatusName,