diff --git a/frontend/src/components/NumericKeyboard.vue b/frontend/src/components/NumericKeyboard.vue index a3f7293..89136a4 100644 --- a/frontend/src/components/NumericKeyboard.vue +++ b/frontend/src/components/NumericKeyboard.vue @@ -24,19 +24,8 @@ const keys = ['1', '2', '3', '4', '5', '6', '7', '8', '9', '.', '0', 'del'] const handleKeyPress = (key: string) => { if (key === 'del') { displayValue.value = displayValue.value.slice(0, -1) - } else if (key === '.') { - const parts = displayValue.value.split('.') - // 最多3个点(4段),且前一段不能为空且不能超过255 - if (parts.length < 4 && parts[parts.length - 1] !== '' && parseInt(parts[parts.length - 1]) <= 255) { - displayValue.value += key - } } else { - const parts = displayValue.value.split('.') - const currentPart = parts[parts.length - 1] - // 每段最多3位,且值不能超过255 - if (currentPart.length < 3 && parseInt(currentPart + key) <= 255) { - displayValue.value += key - } + displayValue.value += key } } diff --git a/frontend/src/components/passwordValie.vue b/frontend/src/components/passwordValie.vue new file mode 100644 index 0000000..30bcef8 --- /dev/null +++ b/frontend/src/components/passwordValie.vue @@ -0,0 +1,232 @@ + + + + + + + \ No newline at end of file diff --git a/frontend/src/views/aiAlarmSetting/index.vue b/frontend/src/views/aiAlarmSetting/index.vue index 1751471..f09aad3 100644 --- a/frontend/src/views/aiAlarmSetting/index.vue +++ b/frontend/src/views/aiAlarmSetting/index.vue @@ -1,7 +1,8 @@ @@ -433,6 +425,7 @@ const handleSave = () => { +