diff --git a/src/utils/tools.js b/src/utils/tools.js index cc8d97bb..aad75a0a 100644 --- a/src/utils/tools.js +++ b/src/utils/tools.js @@ -1306,12 +1306,13 @@ export function numberWithCommas (num) { * @returns {string} */ export function switchStatus (status) { - switch (status) { + switch (status + '') { case '0': return 'detection.create.disabled' case '1': return 'detection.create.enabled' } + return null } /** diff --git a/src/views/detectionsNew/Index.vue b/src/views/detectionsNew/Index.vue index 40658277..4febd749 100644 --- a/src/views/detectionsNew/Index.vue +++ b/src/views/detectionsNew/Index.vue @@ -3,7 +3,7 @@