🔨 修改配置.
This commit is contained in:
@@ -287,14 +287,14 @@
|
||||
@click="setInstallSuccess(record.installLog)">
|
||||
<span class="more-doption normal">安装成功</span>
|
||||
</a-doption>
|
||||
<!-- 报警开关 -->
|
||||
<!-- 告警开关 -->
|
||||
<a-doption v-if="record.id"
|
||||
v-permission="['monitor:monitor-host:update', 'monitor:monitor-host:update-switch']"
|
||||
type="text"
|
||||
size="mini"
|
||||
@click="toggleAlarmSwitch(record)">
|
||||
<span class="more-doption normal">
|
||||
{{ toggleDictValue(AlarmSwitchKey, record.alarmSwitch, 'label') + '报警' }}
|
||||
{{ toggleDictValue(AlarmSwitchKey, record.alarmSwitch, 'label') + '告警' }}
|
||||
</span>
|
||||
</a-doption>
|
||||
</template>
|
||||
|
||||
@@ -317,14 +317,14 @@
|
||||
@click="setInstallSuccess(record.installLog)">
|
||||
<span class="more-doption normal">安装成功</span>
|
||||
</a-doption>
|
||||
<!-- 报警开关 -->
|
||||
<!-- 告警开关 -->
|
||||
<a-doption v-if="record.id"
|
||||
v-permission="['monitor:monitor-host:update', 'monitor:monitor-host:update-switch']"
|
||||
type="text"
|
||||
size="mini"
|
||||
@click="toggleAlarmSwitch(record)">
|
||||
<span class="more-doption normal">
|
||||
{{ toggleDictValue(AlarmSwitchKey, record.alarmSwitch, 'label') + '报警' }}
|
||||
{{ toggleDictValue(AlarmSwitchKey, record.alarmSwitch, 'label') + '告警' }}
|
||||
</span>
|
||||
</a-doption>
|
||||
</template>
|
||||
|
||||
@@ -107,13 +107,13 @@ export default function useMonitorHostList(options: UseMonitorHostListOptions) {
|
||||
});
|
||||
};
|
||||
|
||||
// 更新报警开关
|
||||
// 更新告警开关
|
||||
const toggleAlarmSwitch = async (record: MonitorHostQueryResponse) => {
|
||||
const dict = toggleDict(AlarmSwitchKey, record.alarmSwitch);
|
||||
Modal.confirm({
|
||||
title: `${dict.label}确认`,
|
||||
titleAlign: 'start',
|
||||
content: `确定要${dict.label}报警功能吗?`,
|
||||
content: `确定要${dict.label}告警功能吗?`,
|
||||
okText: '确定',
|
||||
onOk: async () => {
|
||||
try {
|
||||
|
||||
Reference in New Issue
Block a user