diff --git a/src/assets/images/abnormalAlarm/title_right.png b/src/assets/images/abnormalAlarm/title_right.png
new file mode 100644
index 0000000..88b1e84
Binary files /dev/null and b/src/assets/images/abnormalAlarm/title_right.png differ
diff --git a/src/style.less b/src/style.less
index ae83659..4aa1cd5 100644
--- a/src/style.less
+++ b/src/style.less
@@ -139,7 +139,7 @@ body {
width: 100%;
}
&-required::before {
- display: none !important;
+ // display: none !important;
}
}
&-horizontal {
@@ -173,7 +173,7 @@ body {
}
&-input {
- background-color: transparent;
+ background-color: red;
&-wrap {
border-color: @formInputBorderColor;
height: 32px;
diff --git a/src/views/abnormalAlarm/alarmCenter/alarmContactGroup/index.vue b/src/views/abnormalAlarm/alarmCenter/alarmContactGroup/index.vue
index 7b2a477..fb10f3c 100644
--- a/src/views/abnormalAlarm/alarmCenter/alarmContactGroup/index.vue
+++ b/src/views/abnormalAlarm/alarmCenter/alarmContactGroup/index.vue
@@ -18,7 +18,7 @@
-
+
@@ -50,15 +50,21 @@
show-size-changer
show-quick-jumper
:total="page.total"
- :show-total="(total, range) => `Total ${total} items Page ${currentPage} / ${Math.ceil(total / page.pageSize)}`"
+ :show-total="(total, range) => `Total ${total} items Page ${page.currentPage} / ${Math.ceil(total / page.pageSize)}`"
show-less-items
@change="handlePageChange"
@showSizeChange="handleSizeChange"
/>
-
-
+
+
-
-
+
+
+
+
+
+
+
-
-
+
+
+
+
+ Save
+ Cancel
+
+
+
@@ -136,7 +157,8 @@ export default {
'background: #02282b;;margin-bottom: 20px;border: solid 1px #416f7f;overflow: hidden',
targetKeys: [],
groupName: "",
- currGroupId:""
+ currGroupId: "",
+ form: this.$form.createForm(this)
}
},
mounted() {
@@ -173,7 +195,12 @@ export default {
if (res.success) {
this.visible = true
this.isAdd = false
- this.groupName = res.result.name
+ // this.groupName = res.result.name
+ this.$nextTick(() => {
+ this.form.setFieldsValue({
+ name: res.result.name,
+ });
+ })
this.targetKeys = res.result.userIds
this.currGroupId = res.result.id
} else {
@@ -195,29 +222,41 @@ export default {
}
})
},
- setGroupName(e) {
- this.groupName = e.target.value
- },
+ // setGroupName(e) {
+ // this.groupName = e.target.value
+ // },
handleChange(targetKeys, direction, moveKeys) {
console.log(targetKeys, direction, moveKeys);
this.targetKeys= targetKeys;
},
handleOk() {
- if (this.isAdd) {
- this.createContactGroup()
- } else {
- this.updateContactGroup()
- }
+ this.form.validateFields((err, values) => {
+ if (!err) {
+ if (this.targetKeys.length>0) {
+ if (this.isAdd) {
+ this.createContactGroup(values.name)
+ } else {
+ this.updateContactGroup(values.name)
+ }
+ } else {
+ this.$message.warning("Please select User")
+ }
+ }
+ });
},
- updateContactGroup() {
+ onCancel() {
+ this.visible = false
+ },
+ updateContactGroup(name) {
let params = {
- name: this.groupName,
+ name,
description: "",
userIds: this.targetKeys,
id:this.currGroupId
}
httpAction("/alarmContactGroup/update", params, "put").then(res => {
if (res.success) {
+ this.visible = false
this.$message.success("success")
this.getAlarmGroup()
} else {
@@ -225,14 +264,15 @@ export default {
}
})
},
- createContactGroup() {
+ createContactGroup(name) {
let params = {
- name: this.groupName,
+ name,
description: "",
userIds:this.targetKeys,
}
postAction("/alarmContactGroup/create", params).then(res => {
if (res.success) {
+ this.visible = false
this.$message.success("success")
this.getAlarmGroup()
} else {
@@ -283,6 +323,11 @@ export default {
console.log('search:', dir, value);
},
showModal() {
+ this.targetKeys = []
+ this.groupName = ""
+ this.form.setFieldsValue({
+ name: "",
+ });
this.visible = true;
},
},
@@ -290,6 +335,13 @@ export default {
\ No newline at end of file
diff --git a/src/views/abnormalAlarm/components/searchBar.vue b/src/views/abnormalAlarm/components/searchBar.vue
index ac8b67f..ca83215 100644
--- a/src/views/abnormalAlarm/components/searchBar.vue
+++ b/src/views/abnormalAlarm/components/searchBar.vue
@@ -41,7 +41,8 @@
@@ -159,28 +160,33 @@ export default {
margin-right: 9px;
}
}
-::v-deep .ant-form-item {
- display: flex;
- margin-bottom: 0;
- .ant-form-item-label,.ant-form-item-control {
- line-height: 32px;
- height: 32px;
- }
- .ant-form-item-label {
- flex-shrink: 0;
- margin-right: 10px;
- label {
- font-size: 16px;
- font-family: ArialMT;
- color: #ade6ee;
- &::after {
- display: none;
+::v-deep {
+ .ant-form-item {
+ display: flex;
+ margin-bottom: 0;
+ .ant-form-item-label,.ant-form-item-control {
+ line-height: 32px;
+ height: 32px;
+ }
+ .ant-form-item-label {
+ flex-shrink: 0;
+ margin-right: 10px;
+ label {
+ font-size: 16px;
+ font-family: ArialMT;
+ color: #ade6ee;
+ &::after {
+ display: none;
+ }
}
}
- }
- .ant-form-item-control-wrapper {
- width: 100%;
- overflow: hidden;
+ .ant-calendar-range-picker-separator{
+ color: white;
+ }
+ .ant-form-item-control-wrapper {
+ width: 100%;
+ overflow: hidden;
+ }
}
}
.ant-select {
@@ -197,4 +203,13 @@ export default {
position: relative;
background: #03353f;
}
+:global{
+ .asd{
+ .ant-calendar-range .ant-calendar-input ,
+ .ant-calendar-range .ant-calendar-time-picker-input{
+ color: red !important;
+ background: none !important;
+ }
+ }
+}
\ No newline at end of file