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
168c023b
Commit
168c023b
authored
3 years ago
by
皮倩雯
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
消息平台添加企业微信
parent
6d6071a0
Pipeline
#38745
skipped with stages
Changes
6
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
85 additions
and
26 deletions
+85
-26
ProjectManage.jsx
...tformCenter/messageManage/projectManage/ProjectManage.jsx
+1
-0
TemplateManage.jsx
...ormCenter/messageManage/templateManage/TemplateManage.jsx
+1
-0
EditModal.jsx
...ter/messageManage/templateManage/components/EditModal.jsx
+0
-15
schemeDetail.jsx
src/pages/platformCenter/schemeDetail/schemeDetail.jsx
+71
-7
AddUserModal.jsx
src/pages/userCenter/userManage/AddUserModal.jsx
+1
-1
UserManage.js
src/pages/userCenter/userManage/UserManage.js
+11
-3
No files found.
src/pages/platformCenter/messageManage/projectManage/ProjectManage.jsx
View file @
168c023b
...
...
@@ -212,6 +212,7 @@ const ProjectManage = () => {
setCurrentName
(
"全部"
)
GetMessageList
({
pageSize
:
10
,
pageIndex
:
0
})
setShowSearchStyle
(
false
);
setValue
(
''
)
}
// 弹出模态框
const
handleShowModal
=
(
key
,
value
)
=>
{
...
...
This diff is collapsed.
Click to expand it.
src/pages/platformCenter/messageManage/templateManage/TemplateManage.jsx
View file @
168c023b
...
...
@@ -381,6 +381,7 @@ const TemplateManage = () => {
<
Option
value=
"短信"
>
短信
</
Option
>
<
Option
value=
"APP"
>
APP
</
Option
>
<
Option
value=
"WEB"
>
WEB
</
Option
>
<
Option
value=
"企业微信"
>
企业微信
</
Option
>
</
Select
>
</
div
>
<
div
className=
{
styles
.
fast_search
}
>
...
...
This diff is collapsed.
Click to expand it.
src/pages/platformCenter/messageManage/templateManage/components/EditModal.jsx
View file @
168c023b
...
...
@@ -11,7 +11,6 @@ const EditModal = props => {
const
[
form
]
=
Form
.
useForm
();
const
[
templateName
,
setTemplateName
]
=
useState
([]);
const
[
loading
,
setLoading
]
=
useState
(
false
);
const
[
flag
,
setFlag
]
=
useState
(
0
)
const
onSubmit
=
()
=>
{
form
.
submit
()
...
...
@@ -22,20 +21,6 @@ const EditModal = props => {
}
useEffect
(()
=>
{
// console.log(props)
// if(props.template.type=='企业微信'){
// form.setFieldsValue({type:'企业微信'})
// }
// let aa
// if(props.template.third_id==null){
// aa=props.template.weixin
// }
// if(props.template.weixin==null){
// aa=props.template.third_id
// }
form
.
setFieldsValue
({
name
:
props
.
template
.
name
,
type
:
props
.
template
.
type
,
...
...
This diff is collapsed.
Click to expand it.
src/pages/platformCenter/schemeDetail/schemeDetail.jsx
View file @
168c023b
...
...
@@ -31,12 +31,14 @@ const EditModal = props => {
isMessageShow
:
false
,
isAPPShow
:
false
,
isWEBShow
:
false
,
isWXShow
:
false
isWXShow
:
false
,
isEnterpriseWXShow
:
false
,
})
const
[
APP_ITEMS
,
setAPP_ITEMS
]
=
useState
([])
const
[
WEB_ITEMS
,
setWEB_ITEMS
]
=
useState
([])
const
[
WX_ITEMS
,
setWX_ITEMS
]
=
useState
([])
const
[
MES_ITEMS
,
setMES_ITEMS
]
=
useState
([])
const
[
EN_ITEMS
,
setEN_ITEMS
]
=
useState
([])
const
[
listType
,
setListType
]
=
useState
([{
title
:
'定时推送'
,
desc
:
'用于周期性简报的定时推送,如智能巡检、运行周报。'
},
{
title
:
'监控报警'
,
desc
:
'设备硬件故障,阈值超限,状态突变,采集超时等异常情况报警。'
},
{
title
:
'工单办理'
,
desc
:
'在工单系统中,针对特定人员的通知,包括工作办理、审核、会签、回退等操作。'
},
{
title
:
'平台公告'
,
desc
:
'由运维人员向所有用户或特定用户发送的事务公告,如系统升级、维护。'
}])
useEffect
(()
=>
{
...
...
@@ -47,6 +49,7 @@ const EditModal = props => {
let
arr2
=
[]
let
arr3
=
[]
let
arr4
=
[]
let
arr5
=
[]
res
.
data
.
map
((
item
,
index
)
=>
{
if
(
item
.
Type
===
"公众号"
)
{
arr1
.
push
(
item
)
...
...
@@ -60,18 +63,29 @@ const EditModal = props => {
if
(
item
.
Type
===
"WEB"
)
{
arr4
.
push
(
item
)
}
if
(
item
.
Type
===
"企业微信"
)
{
arr5
.
push
(
item
)
}
})
setAPP_ITEMS
(
arr3
)
setMES_ITEMS
(
arr2
)
setWX_ITEMS
(
arr1
)
setWEB_ITEMS
(
arr4
)
setEN_ITEMS
(
arr5
)
}
}
)
},
[])
useEffect
(()
=>
{
console
.
log
(
'template'
,
template
);
console
.
log
(
template
.
WorkWeiXinTemplateId
)
let
aa
if
(
template
.
WorkWeiXinTemplateId
==
null
||
template
.
WorkWeiXinTemplateId
==
''
)
{
aa
=
''
}
else
{
aa
=
parseInt
(
template
.
WorkWeiXinTemplateId
)
}
if
(
template
.
ThemeName
)
{
console
.
log
(
'template'
,
template
);
form
.
setFieldsValue
({
name
:
template
.
MsgType
,
isStart
:
template
.
IsStarted
===
"0"
?
"关闭"
:
"开启"
,
...
...
@@ -86,6 +100,7 @@ const EditModal = props => {
web_template
:
template
.
WebTemplateID
,
web_path
:
template
.
WebFunctionPath
,
message_template
:
template
.
MsgTemplateID
,
enterprise_template
:
aa
,
})
setPlan
(
template
.
MsgType
)
setBtnType
(
template
.
type
)
...
...
@@ -95,9 +110,11 @@ const EditModal = props => {
isWXShow
:
template
.
PushMode
&&
template
.
PushMode
.
split
(
","
).
indexOf
(
"公众号推送"
)
>
-
1
?
true
:
false
,
isWEBShow
:
template
.
PushMode
&&
template
.
PushMode
.
split
(
","
).
indexOf
(
"平台弹框"
)
>
-
1
?
true
:
false
,
isMessageShow
:
template
.
PushMode
&&
template
.
PushMode
.
split
(
","
).
indexOf
(
"短信推送"
)
>
-
1
?
true
:
false
,
isEnterpriseWXShow
:
template
.
PushMode
&&
template
.
PushMode
.
split
(
","
).
indexOf
(
"企业微信推送"
)
>
-
1
?
true
:
false
,
})
}
else
{
console
.
log
(
111
)
setBtnType
(
'定时推送'
)
}
},
[
props
])
...
...
@@ -106,8 +123,17 @@ const EditModal = props => {
}
const
onSubmit
=
()
=>
{
let
fv
=
form
.
getFieldValue
()
let
push_mode
=
((
currentTrench
.
isAPPShow
||
currentTrench
.
isWEBShow
)
?
'平台弹框'
:
''
)
+
(
currentTrench
.
isWXShow
?
',公众号推送'
:
''
)
+
(
currentTrench
.
isMessageShow
?
',短信推送'
:
''
)
console
.
log
(
fv
.
enterprise_template
)
let
aa
if
(
fv
.
enterprise_template
==
undefined
)
{
aa
=
''
}
else
{
aa
=
fv
.
enterprise_template
.
toString
()
}
console
.
log
(
fv
)
let
push_mode
=
((
currentTrench
.
isAPPShow
||
currentTrench
.
isWEBShow
)
?
'平台弹框'
:
''
)
+
(
currentTrench
.
isWXShow
?
',公众号推送'
:
''
)
+
(
currentTrench
.
isMessageShow
?
',短信推送'
:
''
)
+
(
currentTrench
.
isEnterpriseWXShow
?
',企业微信推送'
:
''
)
if
(
template
.
ThemeName
)
{
let
a
=
{
ID
:
template
.
ID
,
...
...
@@ -133,7 +159,8 @@ const EditModal = props => {
MsgTemplateID
:
fv
.
message_template
,
AppTemplateID
:
fv
.
app_template
,
WebTemplateID
:
fv
.
web_template
,
PushGroup
:
fv
.
to_person
?
fv
.
to_person
.
toString
()
:
''
PushGroup
:
fv
.
to_person
?
fv
.
to_person
.
toString
()
:
''
,
WorkWeiXinTemplateId
:
aa
,
}
UpdateMessageConfig
(
a
).
then
(
...
...
@@ -170,6 +197,13 @@ const EditModal = props => {
)
}
else
{
let
bb
if
(
fv
.
enterprise_template
==
undefined
)
{
bb
=
''
}
else
{
bb
=
fv
.
enterprise_template
.
toString
()
}
console
.
log
(
fv
.
enterprise_template
)
let
b
=
{
ThemeName
:
"定时推送"
,
MsgType
:
fv
.
name
,
...
...
@@ -193,7 +227,8 @@ const EditModal = props => {
MsgTemplateID
:
fv
.
message_template
,
AppTemplateID
:
fv
.
app_template
,
WebTemplateID
:
fv
.
web_template
,
PushGroup
:
fv
.
to_person
?
fv
.
to_person
.
toString
()
:
''
PushGroup
:
fv
.
to_person
?
fv
.
to_person
.
toString
()
:
''
,
WorkWeiXinTemplateId
:
bb
,
}
InsertMessageConfig
(
b
).
then
(
res
=>
{
...
...
@@ -233,7 +268,7 @@ const EditModal = props => {
const
onIISAgentSubmit
=
(
value
)
=>
{
console
.
log
(
'value'
,
value
);
console
.
log
(
'value'
,
value
);
setIISConfig
(
value
)
}
...
...
@@ -360,7 +395,7 @@ const EditModal = props => {
<
div
className=
{
styles
.
trench_card
}
>
<
div
className=
{
styles
.
card_title
}
>
<
div
className=
{
styles
.
lable
}
>
微信
</
div
>
<
div
className=
{
styles
.
lable
}
>
公众号
</
div
>
<
Switchs
onChange=
{
e
=>
onTypeChange
(
e
,
'isWXShow'
)
}
checked=
{
currentTrench
.
isWXShow
}
/>
</
div
>
<
div
className=
{
styles
.
card_body
}
>
...
...
@@ -465,6 +500,35 @@ const EditModal = props => {
</
div
>
}
{
<
div
className=
{
styles
.
trench_card
}
>
<
div
className=
{
styles
.
card_title
}
>
<
div
className=
{
styles
.
lable
}
>
企业微信
</
div
>
<
Switchs
onChange=
{
e
=>
onTypeChange
(
e
,
'isEnterpriseWXShow'
)
}
checked=
{
currentTrench
.
isEnterpriseWXShow
}
/>
</
div
>
<
div
className=
{
styles
.
card_body
}
>
<
Item
label=
"模板"
labelAlign=
'left'
name=
"enterprise_template"
labelCol=
{
{
span
:
2
}
}
>
<
Select
style=
{
{
width
:
'97%'
}
}
disabled=
{
!
currentTrench
.
isEnterpriseWXShow
}
>
{
EN_ITEMS
.
map
((
item
,
idx
)
=>
{
return
(
<
Select
.
Option
value=
{
item
.
Id
}
key=
{
idx
}
>
{
item
.
LikeName
}
</
Select
.
Option
>
)
})
}
</
Select
>
</
Item
>
</
div
>
</
div
>
}
</
div
>
</
div
>
...
...
This diff is collapsed.
Click to expand it.
src/pages/userCenter/userManage/AddUserModal.jsx
View file @
168c023b
...
...
@@ -72,7 +72,7 @@ const AddUserModal = props => {
)
{
addUser
({
OUID
:
orgID
.
id
,
loginName
,
userName
,
password
,
phone
,
email
})
.
then
(
res
=>
{
if
(
res
.
msg
===
''
)
{
if
(
res
.
code
===
0
)
{
addUserForm
.
resetFields
();
onCancel
();
// 设置Modal不可见
notification
.
success
({
...
...
This diff is collapsed.
Click to expand it.
src/pages/userCenter/userManage/UserManage.js
View file @
168c023b
...
...
@@ -533,6 +533,11 @@ const UserManage = () => {
const
onSelect
=
(
props
,
e
)
=>
{
console
.
log
(
e
);
console
.
log
(
props
);
console
.
log
(
props
[
0
])
console
.
log
(
props
[
0
].
id
)
if
(
props
[
0
].
id
!=
undefined
){
props
[
0
]
=
props
[
0
].
id
}
setKeep1
(
props
);
console
.
log
(
keep1
);
setTableLoading
(
true
);
...
...
@@ -558,8 +563,11 @@ const UserManage = () => {
}).
then
(
res
=>
{
if
(
res
.
code
===
0
)
{
console
.
log
(
res
);
setCurrentOrgArea
(
res
.
data
.
MapRange
);
setCurrentOrgDistinct
(
res
.
data
.
AreeName
);
if
(
res
.
code
.
MapRange
!=
null
){
setCurrentOrgArea
(
res
.
data
.
MapRange
);
setCurrentOrgDistinct
(
res
.
data
.
AreeName
);
}
}
});
setOrgID
(
props
[
0
]
||
currentSelectOrg
);
...
...
@@ -1459,7 +1467,7 @@ const UserManage = () => {
visible
=
{
userVisible
}
orgID
=
{
orgID
}
onCancel
=
{
kee
}
// onSelect={() =>
onSelect([orgID])}
onSelect
=
{()
=>
onSelect
([
orgID
])}
/
>
{
/* 添加下级机构 */
}
<
AddSubOrgModal
...
...
This diff is collapsed.
Click to expand it.
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