Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
S
so-manage-ui
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
smart-operation
so-manage-ui
Commits
50365532
Commit
50365532
authored
Nov 11, 2022
by
赵伟庚
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix some bugs
parent
3feed9b4
Changes
10
Hide whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
383 additions
and
334 deletions
+383
-334
src/bg-ui/bg-upload.vue
src/bg-ui/bg-upload.vue
+4
-0
src/page/main/config/dict/index.vue
src/page/main/config/dict/index.vue
+11
-2
src/page/main/develop/account/add/contact-form.vue
src/page/main/develop/account/add/contact-form.vue
+35
-24
src/page/main/develop/account/add/index.vue
src/page/main/develop/account/add/index.vue
+1
-1
src/page/main/develop/account/add/system-form.vue
src/page/main/develop/account/add/system-form.vue
+53
-35
src/page/main/system/organization/org-form.vue
src/page/main/system/organization/org-form.vue
+101
-87
src/page/main/system/organization/org-user/index.vue
src/page/main/system/organization/org-user/index.vue
+2
-2
src/page/main/system/organization/platform-user/index.vue
src/page/main/system/organization/platform-user/index.vue
+2
-2
src/page/main/system/organization/user-detail/index.vue
src/page/main/system/organization/user-detail/index.vue
+173
-180
src/page/main/system/role/index.vue
src/page/main/system/role/index.vue
+1
-1
No files found.
src/bg-ui/bg-upload.vue
View file @
50365532
...
@@ -176,6 +176,10 @@ export default {
...
@@ -176,6 +176,10 @@ export default {
},
},
handleExceed
(
file
,
fileList
)
{
handleExceed
(
file
,
fileList
)
{
console
.
log
(
file
,
fileList
);
console
.
log
(
file
,
fileList
);
if
(
fileList
&&
fileList
.
length
==
this
.
limit
)
{
this
.
$message
.
error
(
`最多只允许上传
${
this
.
limit
}
个文件`
)
return
false
}
},
},
handlePreview
(
val
)
{
handlePreview
(
val
)
{
let
a
=
document
.
createElement
(
"
a
"
);
// 生成一个a元素
let
a
=
document
.
createElement
(
"
a
"
);
// 生成一个a元素
...
...
src/page/main/config/dict/index.vue
View file @
50365532
...
@@ -103,6 +103,16 @@
...
@@ -103,6 +103,16 @@
<el-form-item
label=
"名称"
prop=
"name"
>
<el-form-item
label=
"名称"
prop=
"name"
>
<el-input
<el-input
v-model=
"formData.name"
v-model=
"formData.name"
show-word-limit
:maxlength=
"
nodeClassifyId == 'eb9c7d70-c123-42b7-8e61-dde1b022b669'
? 6
: nodeClassifyId == 'efd9ec3b-7f18-49e2-9d88-bcca022243bb'
? 4
: nodeClassifyId == '949a1138-4995-464e-97a9-424d097eb271'
? 2
: 20
"
placeholder=
"请输入名称"
placeholder=
"请输入名称"
></el-input>
></el-input>
</el-form-item>
</el-form-item>
...
@@ -232,8 +242,7 @@ const state = reactive({
...
@@ -232,8 +242,7 @@ const state = reactive({
},
},
rules
:
{
rules
:
{
name
:
[
name
:
[
{
required
:
true
,
message
:
"
请输入名称
"
,
trigger
:
"
blur
"
},
{
required
:
true
,
message
:
"
请输入名称
"
,
trigger
:
"
blur
"
}
{
max
:
20
,
message
:
"
名称最大为20字
"
,
trigger
:
"
blur
"
}
],
],
describe
:
[
describe
:
[
{
required
:
true
,
message
:
"
请输入描述
"
,
trigger
:
"
blur
"
},
{
required
:
true
,
message
:
"
请输入描述
"
,
trigger
:
"
blur
"
},
...
...
src/page/main/develop/account/add/contact-form.vue
View file @
50365532
...
@@ -17,7 +17,7 @@
...
@@ -17,7 +17,7 @@
<el-input
v-model=
"contactForm.contact_email"
/>
<el-input
v-model=
"contactForm.contact_email"
/>
</el-form-item>
</el-form-item>
<el-form-item
label=
"备注"
prop=
"remark"
>
<el-form-item
label=
"备注"
prop=
"remark"
>
<el-input
type=
"textarea"
:rows=
"3"
v-model=
"contactForm.remark"
/>
<el-input
type=
"textarea"
:rows=
"3"
v-model=
"contactForm.remark"
show-word-limit
maxlength=
"300"
/>
</el-form-item>
</el-form-item>
</el-form>
</el-form>
</
template
>
</
template
>
...
@@ -44,37 +44,47 @@ const props = defineProps({
...
@@ -44,37 +44,47 @@ const props = defineProps({
});
});
const
checkPhone
=
(
rule
,
value
,
callback
)
=>
{
const
checkPhone
=
(
rule
,
value
,
callback
)
=>
{
var
phone_ruler
=
/^
(?:(?:\+
|00
)
86
)?
1
[
3-9
]\d{9}
$/
;
var
phone_ruler
=
/^
(?:(?:\+
|00
)
86
)?
1
[
3-9
]\d{9}
$/
;
setTimeout
(()
=>
{
setTimeout
(()
=>
{
if
(
!
phone_ruler
.
test
(
value
)
&&
value
.
length
!==
0
)
{
if
(
!
phone_ruler
.
test
(
value
)
&&
value
.
length
!==
0
)
{
callback
(
new
Error
(
"
请输入正确的手机号码
"
));
callback
(
new
Error
(
"
请输入正确的手机号码
"
));
}
else
{
}
else
{
callback
();
callback
();
}
}
});
});
};
};
const
checkPhoneRepet
=
(
rule
,
value
,
callback
)
=>
{
const
checkPhoneRepet
=
(
rule
,
value
,
callback
)
=>
{
let
params
=
null
;
let
params
=
null
;
if
(
props
.
id
){
if
(
props
.
id
){
params
=
{
id
:
parseInt
(
props
.
id
),
contact_phone
:
value
,}
params
=
{
id
:
parseInt
(
props
.
id
),
contact_phone
:
value
,}
}
else
{
}
else
{
params
=
{
id
:
0
,
contact_phone
:
value
}
params
=
{
id
:
0
,
contact_phone
:
value
}
}
}
$axios
.
post
(
`/apaas/system/v5/org/check`
,
params
)
.
then
((
res
)
=>
{
if
(
res
.
data
.
code
==
200
)
{
callback
()
}
else
{
callback
(
new
Error
(
res
.
data
.
data
))
}
})
}
$axios
.
post
(
`/apaas/system/v5/org/check`
,
params
)
const
checkName
=
(
rule
,
value
,
callback
)
=>
{
.
then
((
res
)
=>
{
var
reg
=
/^
[
a-zA-Z0-9
\u
4e00-
\u
9fa5
]
+$/
if
(
res
.
data
.
code
==
200
)
{
if
(
!
reg
.
test
(
value
))
{
callback
()
callback
(
new
Error
(
"
只能输入字母、数字和汉字
"
))
}
else
{
}
else
{
callback
(
new
Error
(
res
.
data
.
data
))
callback
()
}
}
})
}
}
const
contactFormRules
=
reactive
({
const
contactFormRules
=
reactive
({
contact_name
:
[
contact_name
:
[
{
required
:
true
,
message
:
'
请输入联系人姓名
'
,
trigger
:
'
blur
'
},
{
required
:
true
,
message
:
'
请输入联系人姓名
'
,
trigger
:
'
blur
'
},
{
max
:
50
,
message
:
"
联系人姓名最大长度为50个字符
"
,
trigger
:
"
blur
"
},
{
validator
:
checkName
,
trigger
:
'
blur
'
},
],
],
contact_phone
:
[
contact_phone
:
[
{
required
:
true
,
message
:
'
请输入联系人手机号
'
,
trigger
:
'
blur
'
},
{
required
:
true
,
message
:
'
请输入联系人手机号
'
,
trigger
:
'
blur
'
},
...
@@ -83,6 +93,7 @@ const contactFormRules = reactive({
...
@@ -83,6 +93,7 @@ const contactFormRules = reactive({
],
],
contact_email
:
[
contact_email
:
[
{
type
:
'
email
'
,
message
:
'
请输入正确的邮箱
'
,
trigger
:
'
blur
'
},
{
type
:
'
email
'
,
message
:
'
请输入正确的邮箱
'
,
trigger
:
'
blur
'
},
{
max
:
100
,
message
:
"
邮箱最大长度为100个字符
"
,
trigger
:
"
blur
"
},
]
]
})
})
const
contactRef
=
ref
(
null
)
const
contactRef
=
ref
(
null
)
...
...
src/page/main/develop/account/add/index.vue
View file @
50365532
...
@@ -191,7 +191,7 @@ const getDetail = () => {
...
@@ -191,7 +191,7 @@ const getDetail = () => {
systemFormRef
.
value
.
setForm
({
systemFormRef
.
value
.
setForm
({
organization_id
:
form
.
organization_id
,
organization_id
:
form
.
organization_id
,
system_role_id
:
form
.
system_role_id
,
system_role_id
:
form
.
system_role_id
,
logo
:
[{
url
:
form
.
logo
}
],
logo
:
form
.
logo
?
[{
url
:
form
.
logo
}]
:
[
],
business_code
:
form
.
business_code
,
business_code
:
form
.
business_code
,
business_name
:
form
.
business_name
,
business_name
:
form
.
business_name
,
business_desc
:
form
.
business_desc
,
business_desc
:
form
.
business_desc
,
...
...
src/page/main/develop/account/add/system-form.vue
View file @
50365532
...
@@ -29,7 +29,7 @@
...
@@ -29,7 +29,7 @@
<bg-upload-image
v-model=
"systemForm.logo"
:showTips=
"true"
:limit=
"1"
:fileSize=
"500"
:fileSizeUnit=
"'KB'"
listType=
"picture-card"
:accept=
"['.jpg','.jpeg','.png']"
customTips=
"请选择图片上传:大小120 * 120像素支持jpg、png等格式,图片需小于500KB"
></bg-upload-image>
<bg-upload-image
v-model=
"systemForm.logo"
:showTips=
"true"
:limit=
"1"
:fileSize=
"500"
:fileSizeUnit=
"'KB'"
listType=
"picture-card"
:accept=
"['.jpg','.jpeg','.png']"
customTips=
"请选择图片上传:大小120 * 120像素支持jpg、png等格式,图片需小于500KB"
></bg-upload-image>
</el-form-item>
</el-form-item>
<el-form-item
label=
"业务系统概述"
prop=
"business_desc"
>
<el-form-item
label=
"业务系统概述"
prop=
"business_desc"
>
<el-input
type=
"textarea"
:rows=
"3"
v-model=
"systemForm.business_desc"
/>
<el-input
type=
"textarea"
:rows=
"3"
v-model=
"systemForm.business_desc"
show-word-limit
maxlength=
"300"
/>
</el-form-item>
</el-form-item>
<el-form-item
label=
"角色"
prop=
"system_role_id"
v-if=
"!formType"
>
<el-form-item
label=
"角色"
prop=
"system_role_id"
v-if=
"!formType"
>
<el-select
v-model=
"systemForm.system_role_id"
placeholder=
"请选择角色"
:disabled=
"true"
style=
"width: 100%"
>
<el-select
v-model=
"systemForm.system_role_id"
placeholder=
"请选择角色"
:disabled=
"true"
style=
"width: 100%"
>
...
@@ -118,39 +118,49 @@ const validatePass = (rule, value, callback) => {
...
@@ -118,39 +118,49 @@ const validatePass = (rule, value, callback) => {
}
}
}
}
const
validateBusinessName
=
(
rule
,
value
,
callback
)
=>
{
const
validateBusinessName
=
(
rule
,
value
,
callback
)
=>
{
let
params
=
null
;
let
reg
=
/^
[
a-zA-Z0-9
\u
4e00-
\u
9fa5
]
+$/
if
(
props
.
id
){
if
(
!
reg
.
test
(
value
))
{
params
=
{
id
:
parseInt
(
props
.
id
),
business_name
:
value
,
organization_id
:
systemForm
.
organization_id
}
callback
(
new
Error
(
"
只能输入字母、数字和汉字
"
))
}
else
{
}
else
{
params
=
{
business_name
:
value
,
organization_id
:
systemForm
.
organization_id
}
let
params
=
null
;
}
if
(
props
.
id
){
params
=
{
id
:
parseInt
(
props
.
id
),
business_name
:
value
,
organization_id
:
systemForm
.
organization_id
}
$axios
.
post
(
`/apaas/system/v5/user/check/business`
,
params
)
}
else
{
.
then
((
res
)
=>
{
params
=
{
business_name
:
value
,
organization_id
:
systemForm
.
organization_id
}
if
(
res
.
data
.
code
==
200
)
{
}
callback
()
}
else
{
$axios
.
post
(
`/apaas/system/v5/user/check/business`
,
params
)
.
then
((
res
)
=>
{
if
(
res
.
data
.
code
==
200
)
{
callback
()
}
else
{
callback
(
new
Error
(
res
.
data
.
data
))
callback
(
new
Error
(
res
.
data
.
data
))
}
}
})
})
}
}
}
const
validateSystemAccount
=
(
rule
,
value
,
callback
)
=>
{
const
validateSystemAccount
=
(
rule
,
value
,
callback
)
=>
{
let
params
=
null
;
let
reg
=
/^
[
a-zA-Z0-9
]
+$/
if
(
props
.
id
){
if
(
!
reg
.
test
(
value
))
{
params
=
{
id
:
parseInt
(
props
.
id
),
system_account
:
value
,}
callback
(
new
Error
(
"
只能输入字母和数字
"
))
}
else
{
}
else
{
params
=
{
system_account
:
value
}
let
params
=
null
;
}
if
(
props
.
id
){
params
=
{
id
:
parseInt
(
props
.
id
),
system_account
:
value
,}
$axios
.
post
(
`/apaas/system/v5/user/check/account`
,
params
)
}
else
{
.
then
((
res
)
=>
{
params
=
{
system_account
:
value
}
if
(
res
.
data
.
code
==
200
)
{
}
callback
()
}
else
{
$axios
.
post
(
`/apaas/system/v5/user/check/account`
,
params
)
.
then
((
res
)
=>
{
if
(
res
.
data
.
code
==
200
)
{
callback
()
}
else
{
callback
(
new
Error
(
res
.
data
.
data
))
callback
(
new
Error
(
res
.
data
.
data
))
}
}
})
})
}
}
}
const
formRules
=
reactive
({
const
formRules
=
reactive
({
...
@@ -159,6 +169,7 @@ const formRules = reactive({
...
@@ -159,6 +169,7 @@ const formRules = reactive({
],
],
business_name
:
[
business_name
:
[
{
required
:
true
,
message
:
'
请输入业务系统名称
'
,
trigger
:
'
blur
'
},
{
required
:
true
,
message
:
'
请输入业务系统名称
'
,
trigger
:
'
blur
'
},
{
max
:
50
,
message
:
'
业务系统名称最大长度为50个字符
'
,
trigger
:
'
blur
'
},
{
validator
:
validateBusinessName
,
trigger
:
'
blur
'
},
{
validator
:
validateBusinessName
,
trigger
:
'
blur
'
},
],
],
system_role_id
:
[
system_role_id
:
[
...
@@ -166,16 +177,24 @@ const formRules = reactive({
...
@@ -166,16 +177,24 @@ const formRules = reactive({
],
],
system_account
:
[
system_account
:
[
{
required
:
true
,
message
:
'
请输入账号
'
,
trigger
:
'
blur
'
},
{
required
:
true
,
message
:
'
请输入账号
'
,
trigger
:
'
blur
'
},
{
min
:
4
,
message
:
'
帐号长度不得低于4个字符
'
,
trigger
:
'
blur
'
},
{
max
:
20
,
message
:
'
帐号最大长度为20个字符
'
,
trigger
:
'
blur
'
},
{
validator
:
validateSystemAccount
,
trigger
:
'
blur
'
},
{
validator
:
validateSystemAccount
,
trigger
:
'
blur
'
},
],
],
password
:
[
password
:
[
{
required
:
true
,
message
:
'
请输入密码
'
,
trigger
:
'
blur
'
},
{
required
:
true
,
message
:
'
请输入密码
'
,
trigger
:
'
blur
'
},
{
min
:
8
,
message
:
'
密码长度不得低于8位
'
,
trigger
:
'
blur
'
}
{
min
:
8
,
message
:
'
密码长度不得低于8位
'
,
trigger
:
'
blur
'
}
],
],
confirm_password
:
[
confirm_password
:
[
{
required
:
true
,
message
:
'
请确认密码
'
,
trigger
:
'
blur
'
},
{
required
:
true
,
message
:
'
请确认密码
'
,
trigger
:
'
blur
'
},
{
validator
:
validatePass
,
trigger
:
'
blur
'
}
{
validator
:
validatePass
,
trigger
:
'
blur
'
}
],
],
access_address
:
[
{
max
:
500
,
message
:
'
访问地址最大长度为500个字符
'
,
trigger
:
'
blur
'
},
],
develop_id
:
[
{
required
:
true
,
message
:
"
请选择开发厂商
"
,
trigger
:
"
change
"
}
]
})
})
const
systemRef
=
ref
(
null
)
const
systemRef
=
ref
(
null
)
...
@@ -258,14 +277,13 @@ const getRoleList = () => {
...
@@ -258,14 +277,13 @@ const getRoleList = () => {
const
getFirmList
=
()
=>
{
const
getFirmList
=
()
=>
{
$axios
.
get
(
`/apaas/system/v5/dictionary/developer/list`
)
$axios
.
get
(
`/apaas/system/v5/dictionary/developer/list`
)
.
then
((
res
)
=>
{
.
then
((
res
)
=>
{
if
(
res
.
data
.
code
==
200
)
{
if
(
res
.
data
.
code
==
200
)
{
firmList
.
value
=
res
.
data
.
data
;
firmList
.
value
=
res
.
data
.
data
||
[];
}
else
{
}
else
{
$message
.
error
(
res
.
data
.
data
)
}
}
})
})
}
}
onBeforeMount
(()
=>
{
onBeforeMount
(()
=>
{
...
...
src/page/main/system/organization/org-form.vue
View file @
50365532
...
@@ -26,13 +26,13 @@
...
@@ -26,13 +26,13 @@
<el-input
v-model=
"orgForm.organization_code"
/>
<el-input
v-model=
"orgForm.organization_code"
/>
</el-form-item>
</el-form-item>
<el-form-item
label=
"组织介绍"
prop=
"description"
>
<el-form-item
label=
"组织介绍"
prop=
"description"
>
<el-input
type=
"textarea"
:rows=
"3"
v-model=
"orgForm.description"
/>
<el-input
type=
"textarea"
:rows=
"3"
v-model=
"orgForm.description"
maxlength=
"300"
show-word-limit
/>
</el-form-item>
</el-form-item>
<el-form-item
label=
"组织附件"
prop=
"logo"
>
<el-form-item
label=
"组织附件"
prop=
"logo"
>
<bg-upload
<bg-upload
v-model=
"orgForm.attachment"
v-model=
"orgForm.attachment"
customTips
customTips
:limit=
"3"
:limit=
"3"
:fileTypes=
"['doc','docx','xls','xlsx','pdf','jpg','jpeg','png','zip','rar']"
:fileTypes=
"['doc','docx','xls','xlsx','pdf','jpg','jpeg','png','zip','rar']"
:otherInfo=
"'最多可上传三个附件,可上传zip,rar,doc,docx,xlsx,xls,png,jpg,可上传营业执照和相关协议文件等'"
:otherInfo=
"'最多可上传三个附件,可上传zip,rar,doc,docx,xlsx,xls,png,jpg,可上传营业执照和相关协议文件等'"
>
>
...
@@ -44,105 +44,119 @@
...
@@ -44,105 +44,119 @@
<
script
setup
>
<
script
setup
>
import
{
reactive
,
ref
,
onMounted
,
onBeforeMount
,
getCurrentInstance
}
from
'
vue
'
import
{
reactive
,
ref
,
onMounted
,
onBeforeMount
,
getCurrentInstance
}
from
'
vue
'
const
props
=
defineProps
({
const
props
=
defineProps
({
formType
:
{
formType
:
{
type
:
String
,
type
:
String
,
default
:
'
create
'
,
//false 新建 true 编辑
default
:
'
create
'
,
//false 新建 true 编辑
},
},
});
});
const
{
proxy
}
=
getCurrentInstance
()
const
{
proxy
}
=
getCurrentInstance
()
const
{
$axios
,
$message
}
=
proxy
const
{
$axios
,
$message
}
=
proxy
const
orgForm
=
reactive
({
const
orgForm
=
reactive
({
p_organization_id
:
''
,
p_organization_id
:
''
,
level
:
false
,
level
:
false
,
name
:
''
,
name
:
''
,
organization_code
:
''
,
organization_code
:
''
,
description
:
''
,
description
:
''
,
attachment
:
[]
attachment
:
[]
})
})
const
formRules
=
reactive
({
p_organization_id
:
[
{
required
:
true
,
message
:
'
输入上级目录
'
,
trigger
:
'
blur
'
},
],
name
:
[
{
required
:
true
,
message
:
'
请输入机构名称
'
,
trigger
:
'
blur
'
},
],
organization_code
:
[
{
required
:
true
,
message
:
'
请输入组织机构代码
'
,
trigger
:
'
blur
'
},
],
})
const
orgRef
=
ref
(
null
)
const
checkCode
=
(
rule
,
value
,
callback
)
=>
{
const
emit
=
defineEmits
([
'
action
'
])
var
reg
=
/^
[
a-zA-Z0-9
]
+$/
if
(
!
reg
.
test
(
value
))
{
callback
(
new
Error
(
"
只能输入字母和数字
"
))
}
else
{
callback
()
}
}
const
submitForm
=
async
()
=>
{
const
checkName
=
(
rule
,
value
,
callback
)
=>
{
if
(
!
orgRef
)
return
var
reg
=
/^
[
a-zA-Z
\u
4e00-
\u
9fa5
]
+$/
await
orgRef
.
value
.
validate
((
valid
,
fields
)
=>
{
if
(
!
reg
.
test
(
value
))
{
if
(
valid
)
{
callback
(
new
Error
(
"
只能输入字母和汉字
"
))
emit
(
'
action
'
,
orgForm
)
}
else
{
}
else
{
callback
()
emit
(
'
action
'
,
null
)
}
})
}
}
}
const
clearForm
=
()
=>
{
const
formRules
=
reactive
({
if
(
!
orgRef
)
return
p_organization_id
:
[
orgRef
.
value
.
resetFields
()
{
required
:
true
,
message
:
'
输入上级目录
'
,
trigger
:
'
blur
'
},
}
],
name
:
[
{
required
:
true
,
message
:
'
请输入机构名称
'
,
trigger
:
'
blur
'
},
{
max
:
50
,
message
:
'
机构名称最大长度为50位
'
,
trigger
:
'
blur
'
},
{
validator
:
checkName
,
trigger
:
'
blur
'
}
],
organization_code
:
[
{
required
:
true
,
message
:
'
请输入组织机构代码
'
,
trigger
:
'
blur
'
},
{
max
:
18
,
message
:
'
组织机构代码最大长度为18位
'
,
trigger
:
'
blur
'
},
{
validator
:
checkCode
,
trigger
:
'
blur
'
}
],
})
const
setForm
=
(
data
)
=>
{
const
orgRef
=
ref
(
null
)
Object
.
assign
(
orgForm
,
data
);
const
emit
=
defineEmits
([
'
action
'
])
}
const
orgData
=
ref
([])
const
submitForm
=
async
()
=>
{
const
treeProps
=
{
if
(
!
orgRef
)
return
label
:
'
name
'
,
await
orgRef
.
value
.
validate
((
valid
,
fields
)
=>
{
children
:
'
Child
'
,
if
(
valid
)
{
value
:
'
organization_id
'
,
emit
(
'
action
'
,
orgForm
)
disabled
:
'
disabled
'
}
else
{
}
emit
(
'
action
'
,
null
)
const
getOrgTree
=
()
=>
{
}
$axios
.
get
(
`/apaas/system/v5/org/tree`
)
})
.
then
((
res
)
=>
{
}
const
clearForm
=
()
=>
{
if
(
!
orgRef
)
return
orgRef
.
value
.
resetFields
()
}
const
setForm
=
(
data
)
=>
{
Object
.
assign
(
orgForm
,
data
);
}
const
orgData
=
ref
([])
const
treeProps
=
{
label
:
'
name
'
,
children
:
'
Child
'
,
value
:
'
organization_id
'
,
disabled
:
'
disabled
'
}
const
getOrgTree
=
()
=>
{
$axios
.
get
(
`/apaas/system/v5/org/tree`
)
.
then
((
res
)
=>
{
if
(
res
.
data
.
code
==
200
)
{
if
(
res
.
data
.
code
==
200
)
{
const
orgDataTemp
=
res
.
data
.
data
||
[]
const
orgDataTemp
=
res
.
data
.
data
||
[]
orgDataTemp
.
shift
()
orgDataTemp
.
shift
()
orgData
.
value
=
filterOrg
(
orgDataTemp
);
orgData
.
value
=
filterOrg
(
orgDataTemp
);
}
else
{
}
else
{
$message
.
error
(
res
.
data
.
data
)
$message
.
error
(
res
.
data
.
data
)
}
}
})
})
}
}
const
filterOrg
=
(
data
)
=>
{
if
(
data
.
length
>
0
)
{
data
.
forEach
(
item
=>
{
item
.
disabled
=
item
.
data_type
===
0
?
false
:
true
;
if
(
item
.
Child
){
const
filterOrg
=
(
data
)
=>
{
filterOrg
(
item
.
Child
)
if
(
data
.
length
>
0
)
{
}
else
{
data
.
forEach
(
item
=>
{
return
item
.
disabled
=
item
.
data_type
===
0
?
false
:
true
;
}
if
(
item
.
Child
){
})
filterOrg
(
item
.
Child
)
}
else
{
return
}
}
return
data
;
})
}
const
isTop
=
(
data
)
=>
{
orgForm
.
p_organization_id
=
data
?
'
'
:
''
;
//空格绕过表单非空校验
}
}
return
data
;
}
onBeforeMount
((
)
=>
{
const
isTop
=
(
data
)
=>
{
getOrgTree
()
orgForm
.
p_organization_id
=
data
?
'
'
:
''
;
//空格绕过表单非空校验
})
}
onBeforeMount
(()
=>
{
onMounted
(()
=>
{
getOrgTree
()
})
})
onMounted
(()
=>
{
})
defineExpose
({
submitForm
,
clearForm
,
setForm
})
defineExpose
({
submitForm
,
clearForm
,
setForm
})
</
script
>
</
script
>
\ No newline at end of file
src/page/main/system/organization/org-user/index.vue
View file @
50365532
...
@@ -4,7 +4,7 @@
...
@@ -4,7 +4,7 @@
<el-breadcrumb
separator=
"/"
>
<el-breadcrumb
separator=
"/"
>
<el-breadcrumb-item>
组织管理
</el-breadcrumb-item>
<el-breadcrumb-item>
组织管理
</el-breadcrumb-item>
<el-breadcrumb-item
:to=
"
{ path: '/system/organization' }"> 组织管理
</el-breadcrumb-item>
<el-breadcrumb-item
:to=
"
{ path: '/system/organization' }"> 组织管理
</el-breadcrumb-item>
<el-breadcrumb-item>
新增组织管理员
</el-breadcrumb-item>
<el-breadcrumb-item>
{{
route
.
query
.
id
?
'
编辑组织用户
'
:
'
新增组织管理员
'
}}
</el-breadcrumb-item>
</el-breadcrumb>
</el-breadcrumb>
</div>
</div>
<div
class=
"page_content flex_cloumn"
>
<div
class=
"page_content flex_cloumn"
>
...
@@ -192,7 +192,7 @@ const getDetail = () => {
...
@@ -192,7 +192,7 @@ const getDetail = () => {
orgAccountRef
.
value
.
setForm
({
orgAccountRef
.
value
.
setForm
({
organization_id
:
form
.
organization_id
,
organization_id
:
form
.
organization_id
,
select_role
:
form
.
select_role
,
select_role
:
form
.
select_role
,
logo
:
[{
url
:
form
.
logo
}
],
logo
:
form
.
logo
?
[{
url
:
form
.
logo
}]
:
[
],
system_account
:
form
.
system_account
,
system_account
:
form
.
system_account
,
contact_phone
:
form
.
contact_phone
,
contact_phone
:
form
.
contact_phone
,
state
:
form
.
state
,
state
:
form
.
state
,
...
...
src/page/main/system/organization/platform-user/index.vue
View file @
50365532
...
@@ -4,7 +4,7 @@
...
@@ -4,7 +4,7 @@
<el-breadcrumb
separator=
"/"
>
<el-breadcrumb
separator=
"/"
>
<el-breadcrumb-item>
组织管理
</el-breadcrumb-item>
<el-breadcrumb-item>
组织管理
</el-breadcrumb-item>
<el-breadcrumb-item
:to=
"
{ path: '/system/organization' }"> 组织管理
</el-breadcrumb-item>
<el-breadcrumb-item
:to=
"
{ path: '/system/organization' }"> 组织管理
</el-breadcrumb-item>
<el-breadcrumb-item>
新增平台用户
</el-breadcrumb-item>
<el-breadcrumb-item>
{{
route
.
query
.
id
?
'
编辑平台用户
'
:
'
新增平台用户
'
}}
</el-breadcrumb-item>
</el-breadcrumb>
</el-breadcrumb>
</div>
</div>
<div
class=
"page_content flex_cloumn"
>
<div
class=
"page_content flex_cloumn"
>
...
@@ -217,7 +217,7 @@ const getDetail = () => {
...
@@ -217,7 +217,7 @@ const getDetail = () => {
if
(
res
.
data
.
code
==
200
)
{
if
(
res
.
data
.
code
==
200
)
{
const
form
=
res
.
data
.
data
;
const
form
=
res
.
data
.
data
;
platformAccountFormRef
.
value
.
setForm
({
platformAccountFormRef
.
value
.
setForm
({
logo
:
[{
url
:
form
.
logo
}
],
logo
:
form
.
logo
?
[{
url
:
form
.
logo
}]
:
[
],
system_account
:
form
.
system_account
,
system_account
:
form
.
system_account
,
contact_phone
:
form
.
contact_phone
,
contact_phone
:
form
.
contact_phone
,
state
:
form
.
state
,
state
:
form
.
state
,
...
...
src/page/main/system/organization/user-detail/index.vue
View file @
50365532
<
template
>
<
template
>
<div
class=
"page_container"
>
<div
class=
"page_container"
>
<div
class=
"bg-breadcrumb"
>
<div
class=
"bg-breadcrumb"
>
<el-breadcrumb
separator=
"/"
>
<el-breadcrumb
separator=
"/"
>
<el-breadcrumb-item>
组织管理
</el-breadcrumb-item>
<el-breadcrumb-item>
组织管理
</el-breadcrumb-item>
<el-breadcrumb-item
:to=
"
{ path: '/system/organization' }"> 组织管理
</el-breadcrumb-item>
<el-breadcrumb-item
:to=
"
{ path: '/system/organization' }"> 组织管理
</el-breadcrumb-item>
<el-breadcrumb-item>
用户详情
</el-breadcrumb-item>
<el-breadcrumb-item>
用户详情
</el-breadcrumb-item>
</el-breadcrumb>
</el-breadcrumb>
</div>
<div
class=
"page_content apaas_scroll"
>
<div
class=
"info_row"
>
<div
class=
"title"
>
<div><span
class=
"icon_box"
></span>
账号信息
</div>
<div
class=
"dashed_line"
>
</div>
</div>
</div>
<div
class=
"page_content apaas_scroll"
>
<div
class=
"info_content"
>
<div
class=
"info_row"
>
<div
class=
"img_box"
>
<div
class=
"title"
>
<img
v-if=
"logo"
:src=
"logo"
style=
"height: 96px;width: 96px;border-radius: 99px"
alt=
""
>
<div><span
class=
"icon_box"
></span>
账号信息
</div>
<img
v-else
src=
"/src/assets/imgs/home_ic_user.png"
style=
"height: 96px;width: 96px;border-radius: 99px"
alt=
""
>
<div
class=
"dashed_line"
>
</div>
</div>
<div
class=
"info_content"
>
<div
class=
"img_box"
>
<img
v-if=
"logo"
:src=
"logo"
style=
"height: 96px;width: 96px;border-radius: 99px"
alt=
""
>
<img
v-else
src=
"/src/assets/imgs/home_ic_user.png"
style=
"height: 96px;width: 96px;border-radius: 99px"
alt=
""
>
</div>
<div
class=
"info_box"
>
<bg-info
:data=
"accountInfo"
></bg-info>
</div>
</div>
</div>
</div>
<div>
<div
class=
"info_box"
>
<div
class=
"title"
>
<bg-info
:data=
"accountInfo"
></bg-info>
<div><span
class=
"icon_box"
></span>
个人信息
</div>
<div
class=
"dashed_line"
>
</div>
</div>
<div
class=
"info_content"
>
<div
class=
"img_box"
></div>
<div
class=
"info_box"
>
<bg-info
v-if=
"accountType === 2"
:data=
"personInfo"
></bg-info>
<bg-info
v-if=
"accountType === 3"
:data=
"personInfo2"
></bg-info>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<div>
<div
class=
"title"
>
<div><span
class=
"icon_box"
></span>
个人信息
</div>
<div
class=
"dashed_line"
>
</div>
</div>
<div
class=
"info_content"
>
<div
class=
"img_box"
></div>
<div
class=
"info_box"
>
<bg-info
v-if=
"accountType === 2"
:data=
"personInfo"
></bg-info>
<bg-info
v-if=
"accountType === 3"
:data=
"personInfo2"
></bg-info>
</div>
</div>
</div>
</div>
</div>
</div>
</
template
>
</
template
>
<
script
setup
>
<
script
setup
>
...
@@ -52,159 +52,152 @@ const { proxy } = getCurrentInstance()
...
@@ -52,159 +52,152 @@ const { proxy } = getCurrentInstance()
const
{
$axios
,
$message
}
=
proxy
const
{
$axios
,
$message
}
=
proxy
const
route
=
useRoute
();
const
route
=
useRoute
();
const
accountInfo
=
reactive
(
const
accountInfo
=
reactive
([
[
{
{
name
:
"
手机号
"
,
name
:
"
手机号
"
,
value
:
""
,
value
:
""
,
nameWidth
:
130
nameWidth
:
130
},
},
{
{
name
:
"
账号
"
,
name
:
"
账号
"
,
value
:
""
,
value
:
""
,
nameWidth
:
130
nameWidth
:
130
},
},
{
{
name
:
"
角色
"
,
name
:
"
角色
"
,
value
:
""
,
value
:
""
,
nameWidth
:
130
nameWidth
:
130
},
},
{
{
name
:
"
所属组织
"
,
name
:
"
所属组织
"
,
value
:
""
,
value
:
""
,
nameWidth
:
130
nameWidth
:
130
},
},
{
{
name
:
"
创建人
"
,
name
:
"
创建人
"
,
value
:
""
,
value
:
""
,
nameWidth
:
130
nameWidth
:
130
},
},
{
{
name
:
"
创建账号
"
,
name
:
"
创建账号
"
,
value
:
""
,
value
:
""
,
nameWidth
:
130
nameWidth
:
130
},
},
{
{
name
:
"
最后编辑时间
"
,
name
:
"
最后编辑时间
"
,
value
:
""
,
value
:
""
,
nameWidth
:
130
nameWidth
:
130
},
},
{
{
name
:
"
创建时间
"
,
name
:
"
创建时间
"
,
value
:
""
,
value
:
""
,
nameWidth
:
130
nameWidth
:
130
},
},
])
]
)
const
personInfo
=
reactive
([
{
const
personInfo
=
reactive
(
name
:
"
姓名
"
,
[{
value
:
""
,
name
:
"
姓名
"
,
nameWidth
:
130
value
:
""
,
},
nameWidth
:
130
{
},
name
:
"
邮箱
"
,
{
value
:
""
,
name
:
"
邮箱
"
,
nameWidth
:
130
value
:
""
,
},
nameWidth
:
130
{
},
name
:
"
证据类型
"
,
{
value
:
""
,
name
:
"
证据类型
"
,
nameWidth
:
130
value
:
""
,
},
nameWidth
:
130
{
},
name
:
"
身份证号
"
,
{
value
:
""
,
name
:
"
身份证号
"
,
idCard
:
true
,
value
:
""
,
nameWidth
:
130
idCard
:
true
,
},
nameWidth
:
130
{
},
name
:
"
备注
"
,
{
value
:
""
,
name
:
"
备注
"
,
full
:
true
,
value
:
""
,
nameWidth
:
130
full
:
true
,
},
nameWidth
:
130
])
},
])
const
personInfo2
=
reactive
([
{
const
personInfo2
=
reactive
(
name
:
"
姓名
"
,
[{
value
:
""
,
name
:
"
姓名
"
,
nameWidth
:
130
value
:
""
,
},
nameWidth
:
130
{
},
name
:
"
邮箱
"
,
{
value
:
""
,
name
:
"
邮箱
"
,
nameWidth
:
130
value
:
""
,
},
nameWidth
:
130
{
},
name
:
"
备注
"
,
{
value
:
""
,
name
:
"
备注
"
,
full
:
true
,
value
:
""
,
nameWidth
:
130
full
:
true
,
},
nameWidth
:
130
])
},
])
const
logo
=
ref
(
''
)
const
accountType
=
ref
(
2
);
//1.业务系统账号 2.组织管理员账号 3.平台用户账号
const
logo
=
ref
(
''
)
const
getDetail
=
()
=>
{
const
accountType
=
ref
(
2
);
//1.业务系统账号 2.组织管理员账号 3.平台用户账号
$axios
.
get
(
`/apaas/system/v5/org/user/
${
route
.
query
.
id
}
`
)
.
then
((
res
)
=>
{
const
getDetail
=
()
=>
{
if
(
res
.
data
.
code
==
200
)
{
$axios
.
get
(
`/apaas/system/v5/org/user/
${
route
.
query
.
id
}
`
)
const
detail
=
res
.
data
.
data
;
.
then
((
res
)
=>
{
accountInfo
[
0
].
value
=
detail
.
contact_phone
;
if
(
res
.
data
.
code
==
200
)
{
accountInfo
[
1
].
value
=
detail
.
system_account
;
const
detail
=
res
.
data
.
data
;
accountInfo
[
2
].
value
=
detail
.
system_role
&&
detail
.
system_role
.
length
>
0
?
detail
.
system_role
.
join
(
'
、
'
)
:
''
;
accountInfo
[
0
].
value
=
detail
.
contact_phone
;
accountInfo
[
3
].
value
=
detail
.
organization
;
accountInfo
[
1
].
value
=
detail
.
system_account
;
accountInfo
[
4
].
value
=
detail
.
created_by
;
accountInfo
[
2
].
value
=
detail
.
system_role
&&
detail
.
system_role
.
length
>
0
?
detail
.
system_role
.
join
(
'
、
'
)
:
''
;
accountInfo
[
5
].
value
=
detail
.
created_by_account
;
accountInfo
[
3
].
value
=
detail
.
organization
;
accountInfo
[
6
].
value
=
detail
.
updated_time
;
accountInfo
[
4
].
value
=
detail
.
created_by
;
accountInfo
[
7
].
value
=
detail
.
created_t
accountInfo
[
5
].
value
=
detail
.
created_by_account
;
personInfo
[
0
].
value
=
detail
.
contact_name
;
accountInfo
[
6
].
value
=
detail
.
updated_time
;
personInfo
[
1
].
value
=
detail
.
contact_email
;
accountInfo
[
7
].
value
=
detail
.
created_time
;
personInfo
[
2
].
value
=
detail
.
document_type
===
1
?
'
身份证
'
:
''
;
personInfo
[
3
].
value
=
detail
.
document_number
;
personInfo
[
0
].
value
=
detail
.
contact_name
;
personInfo
[
4
].
value
=
detail
.
rem
personInfo
[
1
].
value
=
detail
.
contact_email
;
personInfo2
[
0
].
value
=
detail
.
contact_name
;
personInfo
[
2
].
value
=
detail
.
document_type
===
1
?
'
身份证
'
:
''
;
personInfo2
[
1
].
value
=
detail
.
contact_email
;
personInfo
[
3
].
value
=
detail
.
document_number
;
personInfo2
[
2
].
value
=
detail
.
rem
personInfo
[
4
].
value
=
detail
.
remark
;
logo
.
value
=
detail
.
logo
;
accountType
.
value
=
detail
.
is_ad
personInfo2
[
0
].
value
=
detail
.
contact_name
;
}
else
{
personInfo2
[
1
].
value
=
detail
.
contact_email
;
$message
.
error
(
res
.
data
.
data
)
personInfo2
[
2
].
value
=
detail
.
remark
;
}
})
logo
.
value
=
detail
.
logo
;
}
accountType
.
value
=
detail
.
is_admin
;
}
else
{
onBeforeMount
(()
=>
{
$message
.
error
(
res
.
data
.
data
)
if
(
route
.
query
.
id
)
{
}
getDetail
()
})
}
}
})
onBeforeMount
(()
=>
{
if
(
route
.
query
.
id
)
{
getDetail
()
}
})
</
script
>
</
script
>
<
style
scoped
>
<
style
scoped
>
.page_content
{
.page_content
{
padding
:
15px
;
padding
:
15px
;
overflow
:
auto
;
overflow
:
auto
;
}
}
.info_content
{
.info_content
{
display
:
flex
;
display
:
flex
;
}
}
.info_row
{
.info_row
{
margin-bottom
:
40px
;
margin-bottom
:
40px
;
}
}
.img_box
{
.img_box
{
width
:
120px
;
width
:
120px
;
}
}
.info_box
{
.info_box
{
width
:
60%
;
width
:
60%
;
}
}
.title
{
.title
{
...
@@ -216,19 +209,19 @@ const accountInfo = reactive(
...
@@ -216,19 +209,19 @@ const accountInfo = reactive(
align-items
:
center
;
align-items
:
center
;
}
}
.dashed_line
{
.dashed_line
{
flex
:
1
;
flex
:
1
;
height
:
1px
;
height
:
1px
;
margin
:
0
10px
;
margin
:
0
10px
;
border-bottom
:
dashed
1px
#dadee7
;
border-bottom
:
dashed
1px
#dadee7
;
}
}
.icon_box
{
.icon_box
{
display
:
inline-block
;
display
:
inline-block
;
width
:
4px
;
width
:
4px
;
height
:
14px
;
height
:
14px
;
background-color
:
#3759be
;
background-color
:
#3759be
;
border-radius
:
2px
;
border-radius
:
2px
;
margin-right
:
5px
;
margin-right
:
5px
;
}
}
</
style
>
</
style
>
\ No newline at end of file
src/page/main/system/role/index.vue
View file @
50365532
...
@@ -146,7 +146,7 @@
...
@@ -146,7 +146,7 @@
</
template
>
</
template
>
</el-cascader>
</el-cascader>
<el-input
<el-input
v-model=
"userFilter.search"
v-model
.trim
=
"userFilter.search"
placeholder=
"请输入内容"
placeholder=
"请输入内容"
style=
"width: 200px"
style=
"width: 200px"
:prefix-icon=
"Search"
:prefix-icon=
"Search"
...
...
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