Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
C
CivManage
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
ReactWeb5
CivManage
Commits
fa02667d
Commit
fa02667d
authored
Dec 21, 2023
by
皮倩雯
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix: '转办,暂存,中途关单,回退流程节点别名'
parent
d0cdaa00
Pipeline
#83384
failed with stages
Changes
5
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
173 additions
and
60 deletions
+173
-60
FlowChartRt.jsx
...workOrder/workflowEdit/workFlowComponents/FlowChartRt.jsx
+43
-37
AddView.jsx
...nents/flowChartComponents/nodeModalComponents/AddView.jsx
+11
-3
ConfigOperate.jsx
...flowChartComponents/nodeModalComponents/ConfigOperate.jsx
+60
-17
ConfigView.jsx
...ts/flowChartComponents/nodeModalComponents/ConfigView.jsx
+19
-1
index.jsx
src/pages/platformCenter/scheduledTasks/index.jsx
+40
-2
No files found.
src/pages/bsmanager/workOrder/workflowEdit/workFlowComponents/FlowChartRt.jsx
View file @
fa02667d
...
@@ -214,7 +214,6 @@ const FlowChart = props => {
...
@@ -214,7 +214,6 @@ const FlowChart = props => {
currentNode
.
current
=
nodeData
;
currentNode
.
current
=
nodeData
;
setNodeKey
(
nodeData
.
key
);
setNodeKey
(
nodeData
.
key
);
setEditMsg
(
nodeData
);
setEditMsg
(
nodeData
);
debugger
;
setModalType
(
'edit'
);
setModalType
(
'edit'
);
setVisible
(
true
);
setVisible
(
true
);
});
});
...
@@ -1037,31 +1036,13 @@ const FlowChart = props => {
...
@@ -1037,31 +1036,13 @@ const FlowChart = props => {
}),
}),
1.2
,
// 压缩比例
1.2
,
// 压缩比例
base64
=>
{
base64
=>
{
console
.
log
(
base64
);
SaveWorkFlowImage
({
SaveWorkFlowImage
({
flowName
:
flowData
.
flowName
,
flowName
:
flowData
.
flowName
,
base64Data
:
base64
,
base64Data
:
base64
,
}).
then
(
response
=>
{
}).
then
(
response
=>
{
if
(
response
.
code
===
0
)
{
if
(
response
.
code
===
0
)
{
console
.
log
(
currentNode
.
current
);
// let list = JSON.parse(JSON.stringify(currentNode.current));
// list.FlowNodeBackfillConfigs = jsonData(list.FlowNodeBackfillConfigs);
// currentNode.current = list;
let
flowNodeBackfillConfigs
=
currentNode
.
current
.
FlowNodeBackfillConfigs
;
let
flowNodeBackfillConfigs
=
currentNode
.
current
.
FlowNodeBackfillConfigs
;
currentNode
.
current
.
FlowNodeBackfillConfigs
=
jsonData
(
flowNodeBackfillConfigs
);
currentNode
.
current
.
FlowNodeBackfillConfigs
=
jsonData
(
flowNodeBackfillConfigs
);
let
data
=
isJSON
(
currentNode
.
current
.
BtnAliasNameConfig
);
// currentNode.current.BtnAliasNameConfig &&
// JSON.parse(currentNode.current.BtnAliasNameConfig.toString()).saveBtnAliasName;
if
(
currentNode
.
current
.
BtnAliasNameConfig
)
{
if
(
!
data
)
{
let
BtnAliasNameConfig
=
JSON
.
stringify
({
saveBtnAliasName
:
currentNode
.
current
.
BtnAliasNameConfig
,
});
currentNode
.
current
.
BtnAliasNameConfig
=
BtnAliasNameConfig
;
}
}
else
{
currentNode
.
current
.
BtnAliasNameConfig
=
''
;
}
FlowNodeSave
({
FlowNodeSave
({
PreviewImage
:
response
.
data
,
PreviewImage
:
response
.
data
,
CreateUser
:
sessionStorage
.
getItem
(
'userName'
),
CreateUser
:
sessionStorage
.
getItem
(
'userName'
),
...
@@ -1213,10 +1194,51 @@ const FlowChart = props => {
...
@@ -1213,10 +1194,51 @@ const FlowChart = props => {
const
nodeChage
=
(
key
,
value
)
=>
{
const
nodeChage
=
(
key
,
value
)
=>
{
setShowLeaveTip
(
true
);
setShowLeaveTip
(
true
);
let
obj
=
JSON
.
parse
(
JSON
.
stringify
(
currentNode
.
current
));
let
obj
=
JSON
.
parse
(
JSON
.
stringify
(
currentNode
.
current
));
if
(
key
===
'saveBtnAliasName'
)
{
let
data
=
obj
.
BtnAliasNameConfig
===
''
?
{}
:
JSON
.
parse
(
obj
.
BtnAliasNameConfig
);
data
.
saveBtnAliasName
=
value
;
obj
.
BtnAliasNameConfig
=
JSON
.
stringify
(
data
);
diagram
.
model
.
setDataProperty
(
currentNode
.
current
,
'BtnAliasNameConfig'
,
obj
.
BtnAliasNameConfig
,
);
}
else
if
(
key
===
'HalfwayCloseBtnAliasName'
)
{
let
data
=
obj
.
BtnAliasNameConfig
===
''
?
{}
:
JSON
.
parse
(
obj
.
BtnAliasNameConfig
);
data
.
HalfwayCloseBtnAliasName
=
value
;
obj
.
BtnAliasNameConfig
=
JSON
.
stringify
(
data
);
diagram
.
model
.
setDataProperty
(
currentNode
.
current
,
'BtnAliasNameConfig'
,
obj
.
BtnAliasNameConfig
,
);
// currentNode.current = obj;
}
else
if
(
key
===
'TransferableBtnAliasName'
)
{
let
data
=
obj
.
BtnAliasNameConfig
===
''
?
{}
:
JSON
.
parse
(
obj
.
BtnAliasNameConfig
);
data
.
TransferableBtnAliasName
=
value
;
obj
.
BtnAliasNameConfig
=
JSON
.
stringify
(
data
);
diagram
.
model
.
setDataProperty
(
currentNode
.
current
,
'BtnAliasNameConfig'
,
obj
.
BtnAliasNameConfig
,
);
// currentNode.current = obj;
}
else
if
(
key
===
'RollbackBtnAliasName'
)
{
let
data
=
obj
.
BtnAliasNameConfig
===
''
?
{}
:
JSON
.
parse
(
obj
.
BtnAliasNameConfig
);
data
.
RollbackBtnAliasName
=
value
;
obj
.
BtnAliasNameConfig
=
JSON
.
stringify
(
data
);
diagram
.
model
.
setDataProperty
(
currentNode
.
current
,
'BtnAliasNameConfig'
,
obj
.
BtnAliasNameConfig
,
);
// currentNode.current = obj;
}
else
{
diagram
.
model
.
setDataProperty
(
currentNode
.
current
,
key
,
value
);
}
obj
[
key
]
=
value
;
obj
[
key
]
=
value
;
const
nodeDetail
=
JSON
.
stringify
(
obj
);
const
nodeDetail
=
JSON
.
stringify
(
obj
);
diagram
.
model
.
setDataProperty
(
currentNode
.
current
,
key
,
value
);
if
(
key
===
'roleList'
)
{
if
(
key
===
'roleList'
)
{
diagram
.
model
.
setDataProperty
(
currentNode
.
current
,
'nodeDetail'
,
nodeDetail
);
diagram
.
model
.
setDataProperty
(
currentNode
.
current
,
'nodeDetail'
,
nodeDetail
);
}
}
...
@@ -1306,25 +1328,8 @@ const FlowChart = props => {
...
@@ -1306,25 +1328,8 @@ const FlowChart = props => {
base64Data
:
base64
,
base64Data
:
base64
,
}).
then
(
val
=>
{
}).
then
(
val
=>
{
if
(
val
.
code
===
0
)
{
if
(
val
.
code
===
0
)
{
console
.
log
(
diagramObj
.
nodeDataArray
);
diagramObj
.
nodeDataArray
.
map
(
i
=>
{
diagramObj
.
nodeDataArray
.
map
(
i
=>
{
i
.
FlowNodeBackfillConfigs
=
jsonData
(
i
.
FlowNodeBackfillConfigs
);
i
.
FlowNodeBackfillConfigs
=
jsonData
(
i
.
FlowNodeBackfillConfigs
);
let
data
=
isJSON
(
i
.
BtnAliasNameConfig
);
console
.
log
(
data
);
debugger
;
// let data =
// i.BtnAliasNameConfig &&
// JSON.parse(i.BtnAliasNameConfig.toString()).saveBtnAliasName;
if
(
i
.
BtnAliasNameConfig
)
{
if
(
!
data
)
{
let
BtnAliasNameConfig
=
JSON
.
stringify
({
saveBtnAliasName
:
i
.
BtnAliasNameConfig
,
});
i
.
BtnAliasNameConfig
=
BtnAliasNameConfig
;
}
}
else
{
i
.
BtnAliasNameConfig
=
''
;
}
});
});
SaveNodeChange
({
SaveNodeChange
({
FlowId
:
flowID
,
FlowId
:
flowID
,
...
@@ -1358,6 +1363,7 @@ const FlowChart = props => {
...
@@ -1358,6 +1363,7 @@ const FlowChart = props => {
},
},
);
);
};
};
const
treeChange
=
newValue
=>
{
const
treeChange
=
newValue
=>
{
setSelectValue
(
newValue
);
setSelectValue
(
newValue
);
};
};
...
...
src/pages/bsmanager/workOrder/workflowEdit/workFlowComponents/flowChartComponents/nodeModalComponents/AddView.jsx
View file @
fa02667d
...
@@ -24,15 +24,23 @@ const AddView = props => {
...
@@ -24,15 +24,23 @@ const AddView = props => {
},
[
visible
]);
},
[
visible
]);
// 获取表单回显
// 获取表单回显
const
getFormData
=
()
=>
{
const
getFormData
=
()
=>
{
if
(
msg
.
WebPage
===
'GisGatherProjectView'
&&
msg
.
WebParam
)
{
if
(
!
Array
.
isArray
(
msg
.
WebParam
))
{
msg
.
WebParam
=
msg
.
WebParam
?.
split
(
','
);
}
}
else
{
msg
.
WebParam
=
[];
}
form
.
setFieldsValue
(
msg
);
form
.
setFieldsValue
(
msg
);
};
};
// 提交表单
// 提交表单
const
onFinish
=
()
=>
{
const
onFinish
=
()
=>
{
form
.
validateFields
().
then
(
validate
=>
{
form
.
validateFields
().
then
(
validate
=>
{
if
(
validate
)
{
if
(
validate
)
{
if
(
validate
.
WebPage
===
'GisGatherProjectView'
&&
validate
.
WebParam
)
{
validate
.
WebParam
=
validate
.
WebParam
.
toString
();
}
let
obj
=
{};
let
obj
=
{};
console
.
log
(
modalType
);
if
(
modalType
===
'add'
)
{
if
(
modalType
===
'add'
)
{
obj
=
validate
;
obj
=
validate
;
}
else
{
}
else
{
...
@@ -118,7 +126,7 @@ const AddView = props => {
...
@@ -118,7 +126,7 @@ const AddView = props => {
display
:
form
.
getFieldValue
(
'WebPage'
)
===
'GisGatherProjectView'
?
'flex'
:
'none'
,
display
:
form
.
getFieldValue
(
'WebPage'
)
===
'GisGatherProjectView'
?
'flex'
:
'none'
,
}
}
}
}
>
>
<
Select
placeholder=
"选择视图参数"
showSearch
>
<
Select
placeholder=
"选择视图参数"
showSearch
mode=
"multiple"
>
{
[
'一键入库'
,
'edit'
].
map
((
item
,
index
)
=>
(
{
[
'一键入库'
,
'edit'
].
map
((
item
,
index
)
=>
(
<
Option
key=
{
index
}
value=
{
item
}
>
<
Option
key=
{
index
}
value=
{
item
}
>
{
item
}
{
item
}
...
...
src/pages/bsmanager/workOrder/workflowEdit/workFlowComponents/flowChartComponents/nodeModalComponents/ConfigOperate.jsx
View file @
fa02667d
...
@@ -21,14 +21,23 @@ const ConfigOperate = (props, ref) => {
...
@@ -21,14 +21,23 @@ const ConfigOperate = (props, ref) => {
HalfwayClose
,
HalfwayClose
,
}
=
editMsg
;
}
=
editMsg
;
let
newBtnAliasNameConfig
;
let
newBtnAliasNameConfig
;
let
newHalfwayCloseBtnAliasName
;
let
newTransferableBtnAliasName
;
let
newRollbackBtnAliasName
;
if
(
BtnAliasNameConfig
)
{
if
(
BtnAliasNameConfig
)
{
newBtnAliasNameConfig
=
JSON
.
parse
(
BtnAliasNameConfig
).
saveBtnAliasName
;
newBtnAliasNameConfig
=
JSON
.
parse
(
BtnAliasNameConfig
).
saveBtnAliasName
;
newHalfwayCloseBtnAliasName
=
JSON
.
parse
(
BtnAliasNameConfig
).
HalfwayCloseBtnAliasName
;
newTransferableBtnAliasName
=
JSON
.
parse
(
BtnAliasNameConfig
).
TransferableBtnAliasName
;
newRollbackBtnAliasName
=
JSON
.
parse
(
BtnAliasNameConfig
).
RollbackBtnAliasName
;
}
}
const
obj
=
{
const
obj
=
{
Transferable
:
Transferable
===
1
,
Transferable
:
Transferable
===
1
,
// EventsInformation: EventsInformation === 1,
// EventsInformation: EventsInformation === 1,
// IsSendMessage: IsSendMessage === 1,
// IsSendMessage: IsSendMessage === 1,
BtnAliasNameConfig
:
newBtnAliasNameConfig
,
saveBtnAliasName
:
newBtnAliasNameConfig
,
HalfwayCloseBtnAliasName
:
newHalfwayCloseBtnAliasName
,
TransferableBtnAliasName
:
newTransferableBtnAliasName
,
RollbackBtnAliasName
:
newRollbackBtnAliasName
,
IsSave
:
IsSave
===
1
,
IsSave
:
IsSave
===
1
,
AutoClose
:
AutoClose
===
'是'
,
AutoClose
:
AutoClose
===
'是'
,
HalfwayClose
:
HalfwayClose
===
1
,
HalfwayClose
:
HalfwayClose
===
1
,
...
@@ -84,10 +93,8 @@ const ConfigOperate = (props, ref) => {
...
@@ -84,10 +93,8 @@ const ConfigOperate = (props, ref) => {
case
'HalfwayClose'
:
case
'HalfwayClose'
:
value
=
changedFields
[
0
].
value
?
1
:
0
;
value
=
changedFields
[
0
].
value
?
1
:
0
;
break
;
break
;
default
:
default
:
value
=
changedFields
[
0
].
value
;
value
=
changedFields
[
0
].
value
;
break
;
}
}
nodeChage
(
changedFields
[
0
].
name
[
0
],
value
);
nodeChage
(
changedFields
[
0
].
name
[
0
],
value
);
};
};
...
@@ -123,7 +130,8 @@ const ConfigOperate = (props, ref) => {
...
@@ -123,7 +130,8 @@ const ConfigOperate = (props, ref) => {
功能按钮配置
功能按钮配置
</
div
>
</
div
>
<
Form
.
Item
<
Form
.
Item
valuePropName=
"checked"
labelCol=
{
{
span
:
5
}
}
wrapperCol=
{
{
span
:
19
}
}
style=
{
{
style=
{
{
marginBottom
:
'0'
,
marginBottom
:
'0'
,
padding
:
'2px'
,
padding
:
'2px'
,
...
@@ -138,9 +146,24 @@ const ConfigOperate = (props, ref) => {
...
@@ -138,9 +146,24 @@ const ConfigOperate = (props, ref) => {
<
span
>
转办
</
span
>
<
span
>
转办
</
span
>
</
div
>
</
div
>
}
}
name=
"Transferable"
>
>
<
Switch
disabled=
{
editMsg
.
NodeType
===
'1'
}
checkedChildren=
"是"
unCheckedChildren=
"否"
/>
<
Row
>
<
Col
span=
{
18
}
>
<
Form
.
Item
name=
"TransferableBtnAliasName"
style=
{
{
marginBottom
:
'0'
}
}
>
<
Input
placeholder=
"请输入转办按钮别名"
style=
{
{
width
:
'180px'
}
}
/>
</
Form
.
Item
>
</
Col
>
<
Col
span=
{
6
}
>
<
Form
.
Item
name=
"Transferable"
valuePropName=
"checked"
style=
{
{
marginBottom
:
'0'
}
}
>
<
Switch
disabled=
{
editMsg
.
NodeType
===
'1'
}
checkedChildren=
"是"
unCheckedChildren=
"否"
style=
{
{
marginLeft
:
'12px'
}
}
/>
</
Form
.
Item
>
</
Col
>
</
Row
>
</
Form
.
Item
>
</
Form
.
Item
>
{
/* <Form.Item
{
/* <Form.Item
valuePropName="checked"
valuePropName="checked"
...
@@ -151,14 +174,14 @@ const ConfigOperate = (props, ref) => {
...
@@ -151,14 +174,14 @@ const ConfigOperate = (props, ref) => {
<Switch checkedChildren="是" unCheckedChildren="否" />
<Switch checkedChildren="是" unCheckedChildren="否" />
</Form.Item> */
}
</Form.Item> */
}
<
Form
.
Item
<
Form
.
Item
labelCol=
{
{
span
:
4
}
}
labelCol=
{
{
span
:
5
}
}
wrapperCol=
{
{
span
:
20
}
}
wrapperCol=
{
{
span
:
19
}
}
style=
{
{
marginBottom
:
'0'
,
padding
:
'2px'
,
borderBottom
:
'1px solid #ccc'
}
}
style=
{
{
marginBottom
:
'0'
,
padding
:
'2px'
,
borderBottom
:
'1px solid #ccc'
}
}
label=
"暂存"
label=
"暂存"
>
>
<
Row
>
<
Row
>
<
Col
span=
{
18
}
>
<
Col
span=
{
18
}
>
<
Form
.
Item
name=
"
BtnAliasNameConfig
"
style=
{
{
marginBottom
:
'0'
}
}
>
<
Form
.
Item
name=
"
saveBtnAliasName
"
style=
{
{
marginBottom
:
'0'
}
}
>
<
Input
placeholder=
"请输入暂存按钮别名"
style=
{
{
width
:
'180px'
}
}
/>
<
Input
placeholder=
"请输入暂存按钮别名"
style=
{
{
width
:
'180px'
}
}
/>
</
Form
.
Item
>
</
Form
.
Item
>
</
Col
>
</
Col
>
...
@@ -174,13 +197,14 @@ const ConfigOperate = (props, ref) => {
...
@@ -174,13 +197,14 @@ const ConfigOperate = (props, ref) => {
</
Row
>
</
Row
>
</
Form
.
Item
>
</
Form
.
Item
>
<
Form
.
Item
<
Form
.
Item
labelCol=
{
{
span
:
5
}
}
wrapperCol=
{
{
span
:
19
}
}
style=
{
{
style=
{
{
marginBottom
:
'0'
,
marginBottom
:
'0'
,
padding
:
'2px'
,
padding
:
'2px'
,
borderBottom
:
'1px solid #ccc'
,
borderBottom
:
'1px solid #ccc'
,
display
:
editMsg
.
NodeType
===
'0'
?
'flex'
:
'none'
,
display
:
editMsg
.
NodeType
===
'0'
?
'flex'
:
'none'
,
}
}
}
}
valuePropName=
"checked"
label=
{
label=
{
<
div
style=
{
{
display
:
'flex'
,
alignItems
:
'center'
}
}
>
<
div
style=
{
{
display
:
'flex'
,
alignItems
:
'center'
}
}
>
{
/* <Tooltip title="开始节点和结束节点不可配置中途关单">
{
/* <Tooltip title="开始节点和结束节点不可配置中途关单">
...
@@ -189,13 +213,24 @@ const ConfigOperate = (props, ref) => {
...
@@ -189,13 +213,24 @@ const ConfigOperate = (props, ref) => {
<
span
>
中途关单
</
span
>
<
span
>
中途关单
</
span
>
</
div
>
</
div
>
}
}
name=
"HalfwayClose"
>
>
<
Switch
<
Row
>
disabled=
{
editMsg
.
NodeType
===
'1'
||
editMsg
.
NodeType
===
'2'
}
<
Col
span=
{
18
}
>
checkedChildren=
"是"
<
Form
.
Item
name=
"HalfwayCloseBtnAliasName"
style=
{
{
marginBottom
:
'0'
}
}
>
unCheckedChildren=
"否"
<
Input
placeholder=
"请输入中途关单按钮别名"
style=
{
{
width
:
'180px'
}
}
/>
/>
</
Form
.
Item
>
</
Col
>
<
Col
span=
{
6
}
>
<
Form
.
Item
name=
"HalfwayClose"
valuePropName=
"checked"
style=
{
{
marginBottom
:
'0'
}
}
>
<
Switch
disabled=
{
editMsg
.
NodeType
===
'1'
||
editMsg
.
NodeType
===
'2'
}
checkedChildren=
"是"
unCheckedChildren=
"否"
style=
{
{
marginLeft
:
'12px'
}
}
/>
</
Form
.
Item
>
</
Col
>
</
Row
>
</
Form
.
Item
>
</
Form
.
Item
>
<
Form
.
Item
<
Form
.
Item
style=
{
{
style=
{
{
...
@@ -231,7 +266,7 @@ const ConfigOperate = (props, ref) => {
...
@@ -231,7 +266,7 @@ const ConfigOperate = (props, ref) => {
<
Form
.
Item
<
Form
.
Item
name=
"RollbackNode"
name=
"RollbackNode"
wrapperCol=
{
{
span
:
24
}
}
wrapperCol=
{
{
span
:
24
}
}
style=
{
{
marginLeft
:
'5px'
,
width
:
'1
4
0px'
,
marginBottom
:
0
}
}
style=
{
{
marginLeft
:
'5px'
,
width
:
'1
0
0px'
,
marginBottom
:
0
}
}
>
>
<
Select
placeholder=
"请选择回退节点"
>
<
Select
placeholder=
"请选择回退节点"
>
{
backNodes
.
map
(
item
=>
(
{
backNodes
.
map
(
item
=>
(
...
@@ -241,6 +276,13 @@ const ConfigOperate = (props, ref) => {
...
@@ -241,6 +276,13 @@ const ConfigOperate = (props, ref) => {
))
}
))
}
</
Select
>
</
Select
>
</
Form
.
Item
>
</
Form
.
Item
>
<
Form
.
Item
name=
"RollbackBtnAliasName"
wrapperCol=
{
{
span
:
24
}
}
style=
{
{
marginLeft
:
'5px'
,
width
:
'80px'
,
marginBottom
:
0
}
}
>
<
Input
placeholder=
"按钮别名"
style=
{
{
width
:
'90px'
}
}
/>
</
Form
.
Item
>
</
div
>
</
div
>
<
Form
.
Item
<
Form
.
Item
...
@@ -252,6 +294,7 @@ const ConfigOperate = (props, ref) => {
...
@@ -252,6 +294,7 @@ const ConfigOperate = (props, ref) => {
checkedChildren=
"是"
checkedChildren=
"是"
unCheckedChildren=
"否"
unCheckedChildren=
"否"
disabled=
{
editMsg
.
NodeType
===
'1'
}
disabled=
{
editMsg
.
NodeType
===
'1'
}
style=
{
{
marginLeft
:
'4px'
}
}
/>
/>
</
Form
.
Item
>
</
Form
.
Item
>
</
div
>
</
div
>
...
...
src/pages/bsmanager/workOrder/workflowEdit/workFlowComponents/flowChartComponents/nodeModalComponents/ConfigView.jsx
View file @
fa02667d
...
@@ -39,6 +39,11 @@ const ConfigView = (props, ref) => {
...
@@ -39,6 +39,11 @@ const ConfigView = (props, ref) => {
list
[
edtiIndex
]
=
val
;
list
[
edtiIndex
]
=
val
;
}
}
list
.
map
(
i
=>
{
if
(
Array
.
isArray
(
i
.
WebParam
))
{
i
.
WebParam
=
i
.
WebParam
.
toString
();
}
});
tableData
.
current
=
list
;
tableData
.
current
=
list
;
nodeChage
(
'ExtendPageList'
,
tableData
.
current
);
nodeChage
(
'ExtendPageList'
,
tableData
.
current
);
setViewModal
(
false
);
setViewModal
(
false
);
...
@@ -89,6 +94,19 @@ const ConfigView = (props, ref) => {
...
@@ -89,6 +94,19 @@ const ConfigView = (props, ref) => {
),
),
},
},
];
];
const
onCancel
=
()
=>
{
setViewModal
(
false
);
let
list
=
JSON
.
parse
(
JSON
.
stringify
(
tableData
.
current
));
list
.
map
(
i
=>
{
if
(
Array
.
isArray
(
i
.
WebParam
))
{
i
.
WebParam
=
i
.
WebParam
.
toString
();
}
});
tableData
.
current
=
list
;
nodeChage
(
'ExtendPageList'
,
tableData
.
current
);
};
return
(
return
(
<
div
>
<
div
>
<
Divider
<
Divider
...
@@ -139,7 +157,7 @@ const ConfigView = (props, ref) => {
...
@@ -139,7 +157,7 @@ const ConfigView = (props, ref) => {
visible=
{
viewModal
}
visible=
{
viewModal
}
msg=
{
viewMsg
}
msg=
{
viewMsg
}
modalType=
{
modalType
}
modalType=
{
modalType
}
handleCancel=
{
()
=>
setViewModal
(
false
)
}
handleCancel=
{
onCancel
}
onSubumit=
{
saveView
}
onSubumit=
{
saveView
}
/>
/>
</
div
>
</
div
>
...
...
src/pages/platformCenter/scheduledTasks/index.jsx
View file @
fa02667d
...
@@ -35,6 +35,7 @@ import {
...
@@ -35,6 +35,7 @@ import {
import
AddModal
from
'./components/AddModal'
;
import
AddModal
from
'./components/AddModal'
;
import
LookModal
from
'./components/LookModal'
;
import
LookModal
from
'./components/LookModal'
;
import
PushTest
from
'./components/PushTest/PushTest'
;
import
PushTest
from
'./components/PushTest/PushTest'
;
import
logWorker
from
'./components/logWorker'
;
const
{
Option
}
=
Select
;
const
{
Option
}
=
Select
;
let
timer
=
null
;
let
timer
=
null
;
...
@@ -54,6 +55,7 @@ const ScheduledTasks = () => {
...
@@ -54,6 +55,7 @@ const ScheduledTasks = () => {
const
listRef
=
useRef
();
const
listRef
=
useRef
();
const
[
logList
,
setLogList
]
=
useState
([]);
const
[
logList
,
setLogList
]
=
useState
([]);
const
keepLength
=
useRef
(
0
);
const
keepLength
=
useRef
(
0
);
const
[
loadingLog
,
setLoadingLog
]
=
useState
(
false
);
const
columns
=
[
const
columns
=
[
{
{
...
@@ -125,9 +127,9 @@ const ScheduledTasks = () => {
...
@@ -125,9 +127,9 @@ const ScheduledTasks = () => {
width
:
150
,
width
:
150
,
render
:
(
text
,
record
)
=>
{
render
:
(
text
,
record
)
=>
{
if
(
text
===
true
)
{
if
(
text
===
true
)
{
return
<
Tag
color=
"green"
>
是
</
Tag
>;
}
else
if
(
text
===
false
)
{
return
<
Tag
color=
"blue"
>
否
</
Tag
>;
return
<
Tag
color=
"blue"
>
否
</
Tag
>;
}
else
if
(
text
===
false
)
{
return
<
Tag
color=
"green"
>
是
</
Tag
>;
}
}
// return (
// return (
// <Switch
// <Switch
...
@@ -183,14 +185,50 @@ const ScheduledTasks = () => {
...
@@ -183,14 +185,50 @@ const ScheduledTasks = () => {
getTableList
();
getTableList
();
setColumnsData
(
columns
);
setColumnsData
(
columns
);
getIISAgentLog
();
getIISAgentLog
();
// updateInfo();
return
()
=>
{
return
()
=>
{
clearInterval
(
timer
);
clearInterval
(
timer
);
timer
=
null
;
timer
=
null
;
};
};
},
[]);
},
[]);
// const updateInfo = () => {
// let worker = new Worker('logWorker');
// debugger;
// worker.onmessage = m => {
// debugger;
// console.log(m);
// };
// debugger;
// worker.postMessage('123');
// };
// updateInfo(payload={}){
// debugger
// this._updateInfo(payload);
// let worker = new Worker(worker, {name: 'myWorker'});
// const {pressions} = payload;
// worker.onmessage = (event) =>{
// debugger
// const { routeMap={}, codeMap = {}} = event.data;
// console.log(routeMap, "routeMap", event.data);
// this.updateRouteMap(routeMap);
// this.updateCodeMap(codeMap);
// worker.terminate();
// }
// if(pressions&&pressions.length>0){
// debugger
// worker.postMessage(pressions);
// }
// }
const
getIISAgentLog
=
()
=>
{
const
getIISAgentLog
=
()
=>
{
if
(
loadingLog
)
{
return
;
}
setLoadingLog
(
true
);
GetIISAgentLog
().
then
(
res
=>
{
GetIISAgentLog
().
then
(
res
=>
{
setLoadingLog
(
false
);
if
(
res
.
code
===
0
)
{
if
(
res
.
code
===
0
)
{
let
arr
=
[];
let
arr
=
[];
let
list
=
res
.
data
let
list
=
res
.
data
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment