Commit 023c8a80 authored by 皮倩雯's avatar 皮倩雯

fix: '设备维保开关交互优化'

parent b30e8088
Pipeline #63131 passed with stages
......@@ -86,6 +86,7 @@ const AddModal = props => {
let data = res.data[0];
setVisibleChecked(data.isSubmit == '是');
setVisibleChecked1(data.autoAssign == '是');
console.log(data);
data && form.setFieldsValue({ ...data });
setType1(data.businessType);
setType2(data.accountName);
......@@ -353,6 +354,9 @@ const AddModal = props => {
};
const change = e => {
if (e == true) {
setVisibleChecked1(false);
}
console.log(e);
setVisibleChecked(e);
setAutoFlag(e);
......
......@@ -88,11 +88,27 @@ const NodeEdit = props => {
if (res.data.Extend != null) {
obj.NodeAliasName = obj.NodeAliasName || res.data.Name;
obj.Transferable = obj.Transferable == 1;
obj.EventsInformation = obj.EventsInformation == 1;
obj.IsSendMessage = obj.IsSendMessage == 1;
setVisibleChecked(obj.Transferable == 1);
setVisibleChecked1(obj.EventsInformation == 1);
setVisibleChecked2(obj.IsSendMessage == 1);
if (obj.EventsInformation) {
obj.EventsInformation = obj.EventsInformation == 1;
setVisibleChecked1(obj.EventsInformation == 1);
} else {
obj.EventsInformation = true;
setVisibleChecked1(true);
}
if (obj.IsSendMessage) {
obj.IsSendMessage = obj.IsSendMessage == 1;
setVisibleChecked2(obj.IsSendMessage == 1);
} else {
obj.IsSendMessage = true;
setVisibleChecked2(true);
}
if (!obj.Handover) {
obj.Handover = '移交选择人';
}
form.setFieldsValue(obj);
} else {
obj.AutoClose = obj.AutoClose == '是';
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment