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
6ec08a58
Commit
6ec08a58
authored
Sep 06, 2022
by
皮倩雯
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
事件工单全局排序
parent
3e3176b1
Pipeline
#59442
passed with stages
Changes
10
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
106 additions
and
60 deletions
+106
-60
SortModal.jsx
src/pages/bsmanager/workOrder/incident/SortModal.jsx
+29
-28
incident.jsx
src/pages/bsmanager/workOrder/incident/incident.jsx
+3
-0
flow.jsx
src/pages/bsmanager/workOrder/workFlow/flow.jsx
+1
-0
Order.jsx
...ges/bsmanager/workOrder/workFlow/flowComponents/Order.jsx
+32
-7
NewSelectUser.jsx
src/pages/userCenter/roleManage/SelectUser/NewSelectUser.jsx
+1
-0
SelectUser.jsx
src/pages/userCenter/roleManage/SelectUser/SelectUser.jsx
+1
-0
UserModal.jsx
src/pages/userCenter/roleManage/UserModal.jsx
+6
-4
SiteManage.jsx
src/pages/userCenter/siteManage/SiteManage.jsx
+26
-1
AddSubOrgModal.jsx
src/pages/userCenter/userManage/AddSubOrgModal.jsx
+4
-14
EditOrgModal.jsx
src/pages/userCenter/userManage/EditOrgModal.jsx
+3
-6
No files found.
src/pages/bsmanager/workOrder/incident/SortModal.jsx
View file @
6ec08a58
...
...
@@ -14,12 +14,11 @@ import Sortable from 'sortablejs';
import
styles
from
'./incident.less'
;
import
DragTable
from
'@/components/DragTable/DragTable'
;
const
SortModal
=
props
=>
{
const
{
callBackSubmit
=
()
=>
{},
title
,
visible
,
onCancel
,
sortData1
}
=
props
;
const
{
callBackSubmit
=
()
=>
{},
title
,
visible
,
onCancel
,
sortData1
,
keepIdValue
}
=
props
;
const
[
orderTable
,
setOrderTable
]
=
useState
([]);
const
[
flowIDs
,
setFlowIDs
]
=
useState
([]);
const
onSumbit
=
()
=>
{
console
.
log
(
flowIDs
);
callBackSubmit
({
str
:
flowIDs
});
};
...
...
@@ -29,25 +28,41 @@ const SortModal = props => {
orderTable
.
map
(
item
=>
{
ids
.
push
(
item
.
ID
);
});
console
.
log
(
ids
);
setFlowIDs
(
ids
);
},
[
orderTable
]);
useEffect
(()
=>
{
console
.
log
(
sortData1
);
if
(
visible
)
{
setOrderTable
(
sortData1
);
let
aa
=
[];
keepIdValue
.
map
(
i
=>
{
i
.
root
.
map
(
j
=>
{
aa
.
push
(
j
);
});
});
setOrderTable
(
aa
);
}
},
[
visible
]);
// 拖拽回调函数
const
dragCallBack
=
data
=>
{
console
.
log
(
data
);
if
(
data
)
{
setOrderTable
(
data
);
}
};
const
columns
=
[
{
title
:
'序号'
,
dataIndex
:
'order'
,
width
:
50
,
key
:
'order'
,
},
{
title
:
'业务类型'
,
dataIndex
:
'businessType'
,
width
:
150
,
key
:
'businessType'
,
},
{
title
:
'字段名'
,
dataIndex
:
'name'
,
...
...
@@ -55,47 +70,33 @@ const SortModal = props => {
key
:
'name'
,
},
];
return
(
<
Modal
title=
{
title
}
width=
"600px"
visible=
{
visible
}
onCancel=
{
onCancel
}
onOk=
{
onSumbit
}
okText=
"确认"
cancelText=
"取消"
>
<
div
className=
{
styles
.
cardContent
}
style=
{
{
width
:
'26rem'
,
marginLeft
:
'24px'
,
maxHeight
:
'400px'
,
overflow
:
'auto'
}
}
>
<
div
className=
{
styles
.
doctorTable
}
>
{
/* <table style={{ width: '104%', marginLeft: '-5px' }}>
<thead>
<tr>
<td>事件名称</td>
</tr>
</thead>
<tbody id="doctor-drag-items">
{sortData1.map((item, index) => (
<tr drag-id={item.ID} key={item.ID} style={{ cursor: 'move' }}>
<td>
<span title={item.name}>{item.name}</span>
</td>
</tr>
))}
</tbody>
</table> */
}
<
div
className=
{
styles
.
cardContent
}
style=
{
{
width
:
'90%'
,
marginLeft
:
'24px'
}
}
>
<
div
style=
{
{
minHeight
:
'200px'
}
}
>
<
DragTable
bordered
style=
{
{
marginBottom
:
'10px'
}
}
rowKey=
{
record
=>
record
.
extendID
}
columns=
{
columns
}
dataSource=
{
orderTable
}
showHeader=
{
false
}
//
showHeader={false}
pagination=
{
false
}
size=
"small"
dragCallBack=
{
dragCallBack
}
ItemTypes=
"flowOrder"
scroll=
{
{
y
:
500
,
}
}
/>
</
div
>
</
div
>
...
...
src/pages/bsmanager/workOrder/incident/incident.jsx
View file @
6ec08a58
...
...
@@ -70,6 +70,7 @@ const incident = () => {
const
[
maxLength
,
setMaxLength
]
=
useState
(
0
);
const
[
pickItem
,
setPickItem
]
=
useState
(
''
);
const
[
hoverItemIndex
,
setHoverItemIndex
]
=
useState
(
0
);
// hover流程索引
const
[
keepIdValue
,
setKeepIdValue
]
=
useState
([])
const
columns
=
[
{
...
...
@@ -252,6 +253,7 @@ const incident = () => {
setTreeLoading
(
false
);
if
(
res
.
code
===
0
)
{
console
.
log
(
res
.
data
);
setKeepIdValue
(
res
.
data
);
// setMaxLength(res.data.root.length + 1)
let
arr
=
formateArrDataA
(
res
.
data
,
'businessType'
);
console
.
log
(
arr
);
...
...
@@ -599,6 +601,7 @@ const incident = () => {
pickItem=
{
pickItem
}
onCancel=
{
()
=>
setSortVisible
(
false
)
}
callBackSubmit=
{
onOK
}
keepIdValue=
{
keepIdValue
}
/>
</
div
>
</
div
>
...
...
src/pages/bsmanager/workOrder/workFlow/flow.jsx
View file @
6ec08a58
...
...
@@ -324,6 +324,7 @@ const Flow = () => {
<
Order
visible=
{
visible
.
order
}
tableData=
{
tableData
}
processData=
{
processData
}
handleCancel=
{
()
=>
showModal
(
'order'
,
false
)
}
submitCallBack=
{
()
=>
{
showModal
(
'order'
,
false
);
...
...
src/pages/bsmanager/workOrder/workFlow/flowComponents/Order.jsx
View file @
6ec08a58
...
...
@@ -10,17 +10,26 @@ import { flowReOrder } from '@/services/flow/flow';
import
{
Modal
,
notification
}
from
'antd'
;
import
DragTable
from
'@/components/DragTable/DragTable'
;
const
Order
=
props
=>
{
const
{
visible
,
handleCancel
,
tableData
,
submitCallBack
}
=
props
;
const
{
visible
,
handleCancel
,
tableData
,
submitCallBack
,
processData
}
=
props
;
const
[
orderTable
,
setOrderTable
]
=
useState
([]);
const
[
flowIDs
,
setFlowIDs
]
=
useState
(
''
);
// 页面弹出的时候初始化拖拽数据
useEffect
(()
=>
{
if
(
visible
)
{
setOrderTable
(()
=>
{
let
table
;
table
=
tableData
.
filter
(
item
=>
item
.
extendID
!==
-
1
);
return
table
;
console
.
log
(
tableData
);
console
.
log
(
processData
);
let
aa
=
[];
processData
.
map
(
i
=>
{
i
.
root
.
map
(
j
=>
{
aa
.
push
(
j
);
});
});
setOrderTable
(
aa
);
// setOrderTable(() => {
// let table;
// table = tableData.filter(item => item.extendID !== -1);
// return table;
// });
}
},
[
visible
]);
// 根据orderTable值改变flowIDs
...
...
@@ -61,6 +70,18 @@ const Order = props => {
}
};
const
columns
=
[
{
title
:
'序号'
,
dataIndex
:
'order'
,
width
:
50
,
key
:
'order'
,
},
{
title
:
'分组名'
,
dataIndex
:
'group'
,
width
:
150
,
key
:
'group'
,
},
{
title
:
'字段名'
,
dataIndex
:
'name'
,
...
...
@@ -71,24 +92,28 @@ const Order = props => {
return
(
<
Modal
title=
"调整顺序"
width=
"600px"
visible=
{
visible
}
onOk=
{
onSubmit
}
onCancel=
{
handleCancel
}
maskClosable=
{
false
}
destroyOnClose
>
<
div
style=
{
{
m
axHeight
:
'400px'
,
overflow
:
'auto
'
}
}
>
<
div
style=
{
{
m
inHeight
:
'200px
'
}
}
>
<
DragTable
bordered
style=
{
{
marginBottom
:
'10px'
}
}
rowKey=
{
record
=>
record
.
extendID
}
columns=
{
columns
}
dataSource=
{
orderTable
}
showHeader=
{
false
}
//
showHeader={false}
pagination=
{
false
}
size=
"small"
dragCallBack=
{
dragCallBack
}
ItemTypes=
"flowOrder"
scroll=
{
{
y
:
500
,
}
}
/>
</
div
>
</
Modal
>
...
...
src/pages/userCenter/roleManage/SelectUser/NewSelectUser.jsx
View file @
6ec08a58
...
...
@@ -41,6 +41,7 @@ const NewSelectUser = props => {
};
// 获取初始数据
const
getInitialData
=
()
=>
{
console
.
log
(
itemObj
);
let
p1
=
getStationUsers
({
stationId
:
itemObj
.
roleID
});
let
p2
=
GetGroupUserTree
({
key
:
''
,
...
...
src/pages/userCenter/roleManage/SelectUser/SelectUser.jsx
View file @
6ec08a58
...
...
@@ -43,6 +43,7 @@ const SelectUser = props => {
};
// 获取初始数据
const
getInitialData
=
()
=>
{
console
.
log
(
itemObj
);
let
p1
=
getStationUsers
({
stationId
:
itemObj
.
roleID
});
let
p2
=
GetGroupUserTree
({
key
:
''
,
...
...
src/pages/userCenter/roleManage/UserModal.jsx
View file @
6ec08a58
...
...
@@ -2,7 +2,6 @@ import useModal from 'antd/lib/modal/useModal';
import
React
,
{
useEffect
,
useState
}
from
'react'
;
import
SiteModal
from
'@/components/Modal/SiteModa'
;
import
classnames
from
'classnames'
;
import
styles
from
'./UserModal.less'
;
import
lodash
,
{
clone
}
from
'lodash'
;
import
{
Card
,
Empty
,
Pagination
,
Checkbox
,
notification
,
Input
,
Row
,
Col
}
from
'antd'
;
import
{
...
...
@@ -18,6 +17,7 @@ import {
}
from
'@/services/siteManage/api'
;
import
{
UserOutlined
}
from
'@ant-design/icons'
;
import
qs
from
'qs'
;
import
styles
from
'./UserModal.less'
;
const
{
Search
}
=
Input
;
const
placeholder
=
'请输入机构名称'
;
const
UserModal
=
props
=>
{
...
...
@@ -44,9 +44,11 @@ const UserModal = props => {
},
[
visible
]);
// 切换站点,提交时触发已勾选列表更新
useEffect
(()
=>
{
if
(
!
itemObj
)
return
;
//
if (!itemObj) return;
// getAllcheckList();
getAllCheckListNew
();
if
(
itemObj
)
{
getAllCheckListNew
();
}
},
[
itemObj
,
updateCheck
]);
// 获取当前站点可编辑用户(已勾选和未勾选)分页展示
...
...
@@ -56,7 +58,7 @@ const UserModal = props => {
PageIndex
:
+
page
.
pageNum
,
PageSize
:
+
page
.
pageSize
,
};
console
.
log
(
123
)
console
.
log
(
123
)
;
if
(
name
)
params
=
{
...
params
,
name
};
groupUserPagingList
(
params
).
then
(
res
=>
{
if
(
res
.
code
===
0
&&
res
.
data
)
{
...
...
src/pages/userCenter/siteManage/SiteManage.jsx
View file @
6ec08a58
...
...
@@ -228,6 +228,7 @@ const SiteManageV2 = () => {
});
}
handleShowModal
(
'loading'
,
false
);
console
.
log
(
lodash
.
cloneDeep
(
list
));
setdataList
(
lodash
.
cloneDeep
(
list
));
setTotal
(
res
.
data
.
count
);
}
else
{
...
...
@@ -624,8 +625,30 @@ const SiteManageV2 = () => {
}
});
};
const
indeterminate
=
i
=>
{
let
aa
=
[];
i
.
users
.
map
(
i
=>
{
if
(
i
.
isChecked
)
{
aa
.
push
(
i
.
userName
);
}
});
if
(
i
.
isChecked
)
{
console
.
log
(
12
);
return
false
;
}
if
(
!
i
.
isChecked
&&
aa
.
length
<
i
.
users
.
length
&&
aa
.
length
!=
0
)
{
console
.
log
(
34
);
return
true
;
}
if
(
!
i
.
isChecked
&&
aa
.
length
==
0
)
{
console
.
log
(
56
);
return
false
;
}
};
const
Panels
=
React
.
memo
(
props
=>
{
let
{
index
,
groupId
,
groupName
,
users
,
isChecked
,
isShow
,
color
}
=
props
;
let
{
index
,
groupId
,
groupName
,
users
,
isChecked
,
isShow
,
color
,
item
}
=
props
;
return
(
<
div
className=
{
styles
.
sitePanel
}
key=
{
groupId
}
id=
{
`siteId${groupId}`
}
>
{
/* onClick={() => props.handleChangeCollpase(GroupId, isShow)} */
}
...
...
@@ -642,6 +665,7 @@ const SiteManageV2 = () => {
key=
"0"
className=
{
styles
.
siteListTitle
}
checked=
{
isChecked
}
indeterminate=
{
indeterminate
(
item
)
}
onClick=
{
e
=>
props
.
handleChangeAll
(
e
,
index
)
}
>
全选
...
...
@@ -856,6 +880,7 @@ const SiteManageV2 = () => {
handleChangeCollpase=
{
handleChangeCollpase
}
handleChangeAll=
{
handleChangeAll
}
handleChangeSignel=
{
handleChangeSignel
}
item=
{
item
}
/>
))
}
</
div
>
...
...
src/pages/userCenter/userManage/AddSubOrgModal.jsx
View file @
6ec08a58
...
...
@@ -16,14 +16,9 @@ const AddUserModal = props => {
const
submitAddOrg
=
()
=>
{
// 顶级机构
if
(
orgID
==
-
1
)
{
addOrg
(
orgID
,
addOrgForm
.
getFieldValue
(
'OUName'
),
addOrgForm
.
getFieldValue
(
'desrciption'
)
||
''
,
''
,
)
addOrg
(
orgID
,
addOrgForm
.
getFieldsValue
().
OUName
,
addOrgForm
.
getFieldsValue
().
description
)
.
then
(
res
=>
{
if
(
res
.
msg
===
'Ok'
)
{
if
(
res
.
code
===
0
)
{
onCancel
();
notification
.
success
({
message
:
'提交成功'
,
...
...
@@ -44,14 +39,9 @@ const AddUserModal = props => {
message
.
error
(
err
);
});
}
else
{
addOrg
(
orgID
.
id
,
addOrgForm
.
getFieldValue
(
'OUName'
),
addOrgForm
.
getFieldValue
(
'desrciption'
)
||
''
,
''
,
)
addOrg
(
orgID
.
id
,
addOrgForm
.
getFieldsValue
().
OUName
,
addOrgForm
.
getFieldsValue
().
description
)
.
then
(
res
=>
{
if
(
res
.
msg
===
'Ok'
)
{
if
(
res
.
code
===
0
)
{
onCancel
();
notification
.
success
({
message
:
'提交成功'
,
...
...
src/pages/userCenter/userManage/EditOrgModal.jsx
View file @
6ec08a58
...
...
@@ -18,9 +18,7 @@ const EditOrgModal = props => {
console
.
log
(
orgTitle1
);
console
.
log
(
orgID
);
if
(
visible
&&
orgID
)
{
console
.
log
(
orgID
.
text
);
editOrgForm
.
setFieldsValue
({
OUName
:
orgID
.
text
});
console
.
log
(
editOrgForm
.
getFieldValue
(
'OUName'
));
editOrgForm
.
setFieldsValue
({
OUName
:
orgID
.
text
,
description
:
orgID
.
describe
});
}
},
[
visible
]);
...
...
@@ -28,9 +26,8 @@ const EditOrgModal = props => {
const
submitEditOrg
=
()
=>
editOrgInfo
(
orgID
.
id
,
editOrgForm
.
getFieldValue
(
'OUName'
),
editOrgForm
.
getFieldValue
(
'description'
)
||
''
,
''
,
editOrgForm
.
getFieldsValue
().
OUName
,
editOrgForm
.
getFieldsValue
().
description
,
)
.
then
(
res
=>
{
if
(
res
.
code
===
0
)
{
...
...
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