Commit 03089311 authored by 皮倩雯's avatar 皮倩雯

fix: '工单流程配置新增暂存按钮别名'

parent bed21541
Pipeline #77313 canceled with stages
......@@ -214,6 +214,7 @@ const FlowChart = props => {
currentNode.current = nodeData;
setNodeKey(nodeData.key);
setEditMsg(nodeData);
debugger;
setModalType('edit');
setVisible(true);
});
......@@ -1048,7 +1049,19 @@ const FlowChart = props => {
// currentNode.current = list;
let flowNodeBackfillConfigs = currentNode.current.FlowNodeBackfillConfigs;
currentNode.current.FlowNodeBackfillConfigs = jsonData(flowNodeBackfillConfigs);
console.log(currentNode.current);
let data =
currentNode.current.ButAliasNameConfig &&
JSON.parse(currentNode.current.ButAliasNameConfig).saveButAliasName;
if (currentNode.current.ButAliasNameConfig) {
if (!data) {
let butAliasNameConfig = JSON.stringify({
saveButAliasName: currentNode.current.ButAliasNameConfig,
});
currentNode.current.ButAliasNameConfig = butAliasNameConfig;
}
} else {
currentNode.current.ButAliasNameConfig = '';
}
FlowNodeSave({
PreviewImage: response.data,
CreateUser: sessionStorage.getItem('userName'),
......@@ -1191,7 +1204,6 @@ const FlowChart = props => {
};
// 节点数据改边
const nodeChage = (key, value) => {
console.log(key, value);
setShowLeaveTip(true);
let obj = JSON.parse(JSON.stringify(currentNode.current));
obj[key] = value;
......@@ -1290,8 +1302,18 @@ const FlowChart = props => {
console.log(diagramObj.nodeDataArray);
diagramObj.nodeDataArray.map(i => {
i.FlowNodeBackfillConfigs = jsonData(i.FlowNodeBackfillConfigs);
let data = i.ButAliasNameConfig && JSON.parse(i.ButAliasNameConfig).saveButAliasName;
if (i.ButAliasNameConfig) {
if (!data) {
let butAliasNameConfig = JSON.stringify({
saveButAliasName: i.ButAliasNameConfig,
});
i.ButAliasNameConfig = butAliasNameConfig;
}
} else {
i.ButAliasNameConfig = '';
}
});
console.log(diagramObj.nodeDataArray);
SaveNodeChange({
FlowId: flowID,
// DeleteNodes,
......
......@@ -15,14 +15,20 @@ const ConfigOperate = (props, ref) => {
Transferable,
// EventsInformation,
// IsSendMessage,
ButAliasNameConfig,
IsSave,
AutoClose,
HalfwayClose,
} = editMsg;
let newButAliasNameConfig;
if (ButAliasNameConfig) {
newButAliasNameConfig = JSON.parse(ButAliasNameConfig).saveButAliasName;
}
const obj = {
Transferable: Transferable === 1,
// EventsInformation: EventsInformation === 1,
// IsSendMessage: IsSendMessage === 1,
ButAliasNameConfig: newButAliasNameConfig,
IsSave: IsSave === 1,
AutoClose: AutoClose === '是',
HalfwayClose: HalfwayClose === 1,
......@@ -136,13 +142,36 @@ const ConfigOperate = (props, ref) => {
>
<Switch disabled={editMsg.NodeType === '1'} checkedChildren="是" unCheckedChildren="否" />
</Form.Item>
<Form.Item
{/* <Form.Item
valuePropName="checked"
style={{ marginBottom: '0', padding: '2px', borderBottom: '1px solid #ccc' }}
label="暂存"
name="IsSave"
>
<Switch checkedChildren="是" unCheckedChildren="否" />
</Form.Item> */}
<Form.Item
labelCol={{ span: 4 }}
wrapperCol={{ span: 20 }}
style={{ marginBottom: '0', padding: '2px', borderBottom: '1px solid #ccc' }}
label="暂存"
>
<Row>
<Col span={18}>
<Form.Item name="ButAliasNameConfig" style={{ marginBottom: '0' }}>
<Input placeholder="请输入暂存按钮别名" style={{ width: '180px' }} />
</Form.Item>
</Col>
<Col span={6}>
<Form.Item name="IsSave" valuePropName="checked" style={{ marginBottom: '0' }}>
<Switch
checkedChildren="是"
unCheckedChildren="否"
style={{ marginLeft: '12px' }}
/>
</Form.Item>
</Col>
</Row>
</Form.Item>
<Form.Item
style={{
......
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