cleanup an old view

This commit is contained in:
wh1te909
2021-01-29 02:15:27 +00:00
parent fc064c0ea3
commit e1f7e50164

View File

@@ -644,14 +644,14 @@ export default {
this.$store.dispatch("loadNotes", pk);
},
overdueAlert(category, pk, alert_action) {
const db_field = category === "email" ? "overdue_email_alert" : "overdue_text_alert";
const action = alert_action ? "enabled" : "disabled";
const data = {
pk: pk,
alertType: category,
action: action,
[db_field]: alert_action,
};
const alertColor = alert_action ? "positive" : "warning";
axios
this.$axios
.post("/agents/overdueaction/", data)
.then(r => {
this.$q.notify({
@@ -660,7 +660,7 @@ export default {
message: `Overdue ${category} alerts ${action} on ${r.data}`,
});
})
.catch(e => this.notifyError(e.response.data.error));
.catch(() => this.notifyError("Something went wrong"));
},
agentClass(status) {
if (status === "offline") {