mirror of
https://github.com/louislam/uptime-kuma.git
synced 2024-11-23 14:54:05 +00:00
remove duplicate code
This commit is contained in:
parent
0d2b380f44
commit
95a9e0a096
4 changed files with 0 additions and 46 deletions
|
@ -33,21 +33,12 @@
|
|||
import { Modal } from "bootstrap";
|
||||
|
||||
export default {
|
||||
beforeRouteLeave(to, from, next) {
|
||||
this.cleanupModal();
|
||||
next();
|
||||
},
|
||||
props: {},
|
||||
emits: [ "added" ],
|
||||
data: () => ({
|
||||
modal: null,
|
||||
groupName: null,
|
||||
}),
|
||||
watch: {
|
||||
$route(to, from) {
|
||||
this.cleanupModal();
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
this.modal = new Modal(this.$refs.modal);
|
||||
},
|
||||
|
@ -82,9 +73,6 @@ export default {
|
|||
console.warn("Modal hide failed:", e);
|
||||
}
|
||||
}
|
||||
document.body.classList.remove("modal-open");
|
||||
document.body.style.paddingRight = "";
|
||||
document.body.style.overflow = "";
|
||||
}
|
||||
},
|
||||
};
|
||||
|
|
|
@ -80,10 +80,6 @@ export default {
|
|||
components: {
|
||||
Confirm,
|
||||
},
|
||||
beforeRouteLeave(to, from, next) {
|
||||
this.cleanupModal();
|
||||
next();
|
||||
},
|
||||
props: {},
|
||||
emits: [ "added" ],
|
||||
data() {
|
||||
|
@ -230,9 +226,6 @@ export default {
|
|||
this.notification.name = this.getUniqueDefaultName(to);
|
||||
}
|
||||
},
|
||||
$route(to, from) {
|
||||
this.cleanupModal();
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
this.modal = new Modal(this.$refs.modal);
|
||||
|
@ -358,9 +351,6 @@ export default {
|
|||
console.warn("Modal hide failed:", e);
|
||||
}
|
||||
}
|
||||
document.body.classList.remove("modal-open");
|
||||
document.body.style.paddingRight = "";
|
||||
document.body.style.overflow = "";
|
||||
}
|
||||
},
|
||||
};
|
||||
|
|
|
@ -105,10 +105,6 @@ export default {
|
|||
components: {
|
||||
Confirm,
|
||||
},
|
||||
beforeRouteLeave(to, from, next) {
|
||||
this.cleanupModal();
|
||||
next();
|
||||
},
|
||||
props: {},
|
||||
emits: [ "added" ],
|
||||
data() {
|
||||
|
@ -129,11 +125,6 @@ export default {
|
|||
}
|
||||
};
|
||||
},
|
||||
watch: {
|
||||
$route(to, from) {
|
||||
this.cleanupModal();
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
this.modal = new Modal(this.$refs.modal);
|
||||
},
|
||||
|
@ -232,9 +223,6 @@ export default {
|
|||
console.warn("Modal hide failed:", e);
|
||||
}
|
||||
}
|
||||
document.body.classList.remove("modal-open");
|
||||
document.body.style.paddingRight = "";
|
||||
document.body.style.overflow = "";
|
||||
}
|
||||
},
|
||||
};
|
||||
|
|
|
@ -155,10 +155,6 @@ export default {
|
|||
Tag,
|
||||
VueMultiselect,
|
||||
},
|
||||
beforeRouteLeave(to, from, next) {
|
||||
this.cleanupModal();
|
||||
next();
|
||||
},
|
||||
props: {
|
||||
/**
|
||||
* Array of tags to be pre-selected
|
||||
|
@ -248,11 +244,6 @@ export default {
|
|||
};
|
||||
},
|
||||
},
|
||||
watch: {
|
||||
$route(to, from) {
|
||||
this.cleanupModal();
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
this.modal = new Modal(this.$refs.modal);
|
||||
this.getExistingTags();
|
||||
|
@ -484,9 +475,6 @@ export default {
|
|||
console.warn("Modal hide failed:", e);
|
||||
}
|
||||
}
|
||||
document.body.classList.remove("modal-open");
|
||||
document.body.style.paddingRight = "";
|
||||
document.body.style.overflow = "";
|
||||
}
|
||||
},
|
||||
};
|
||||
|
|
Loading…
Reference in a new issue