From 2b99047683332624832c1dfcae596e957a710b7d Mon Sep 17 00:00:00 2001
From: ZZJ <10913410+zzj2100@user.noreply.gitee.com>
Date: 星期四, 28 七月 2022 10:20:49 +0800
Subject: [PATCH] bug修复
---
src/views/hashrate/CameraManage/CameraRules/components/TimeSlider.vue | 35 ++++++++++++++++++++++++-----------
1 files changed, 24 insertions(+), 11 deletions(-)
diff --git a/src/views/hashrate/CameraManage/CameraRules/components/TimeSlider.vue b/src/views/hashrate/CameraManage/CameraRules/components/TimeSlider.vue
index 5877a6b..c000dc0 100644
--- a/src/views/hashrate/CameraManage/CameraRules/components/TimeSlider.vue
+++ b/src/views/hashrate/CameraManage/CameraRules/components/TimeSlider.vue
@@ -182,11 +182,27 @@
});
},
chooseEdit(data) {
- this.$prompt("璇疯緭鍏ユ柊鐨勫満鏅悕绉�", "鎻愮ず", {
+ this.$prompt("璇疯緭鍏ユ柊鐨勬椂闂存鍚嶇О", "鎻愮ず", {
confirmButtonText: "纭畾",
cancelButtonText: "鍙栨秷",
})
.then(({ value }) => {
+ let repeat = false;
+ this.VideoManageData.TimeRules.forEach((item) => {
+ if (item.name === value) {
+ repeat = true;
+ }
+ });
+ console.log("aaa");
+ console.log(repeat);
+ if (repeat) {
+ this.$notify({
+ message: "鍚嶇О涓嶈兘閲嶅",
+ type: "warning",
+ });
+ return;
+ }
+
this.activeTabObj.name = value;
this.save();
})
@@ -251,14 +267,11 @@
return;
}
- this.$confirm(
- "姝ゆ搷浣滃皢姘镐箙鍒犻櫎璇ヨ鍒�, 鎵�鍏宠仈鐨勪换鍔″皢浼氬け鏁堬紝鏄惁缁х画?",
- {
- center: true,
- confirmButtonText: "纭畾",
- cancelButtonText: "鍙栨秷",
- }
- )
+ this.$confirm("姝ゆ搷浣滃皢鍒犻櫎璇ヨ鍒�, 鎵�鍏宠仈鐨勪换鍔″皢浼氬け鏁堬紝鏄惁缁х画?", {
+ center: true,
+ confirmButtonText: "纭畾",
+ cancelButtonText: "鍙栨秷",
+ })
.then(() => {
deleteTimeRule({ id: tabId }).then((rsp) => {
if (rsp && rsp.success) {
@@ -382,7 +395,7 @@
padding: 0 20px;
margin-top: 20px;
display: flex;
- justify-content: end;
+ justify-content: flex-end;
text-align: center;
line-height: 32px;
font-size: 14px;
@@ -479,7 +492,7 @@
.btns {
position: absolute;
display: flex;
- justify-content: end;
+ justify-content: flex-end;
align-items: center;
left: 0;
right: 0;
--
Gitblit v1.8.0