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
c68a4871
Commit
c68a4871
authored
Nov 01, 2022
by
张俊
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'dev' of
https://cloud.wodcloud.com/git/apaas/apaas-system-ui
into dev
parents
4139b7f0
8ff082a3
Changes
12
Show whitespace changes
Inline
Side-by-side
Showing
12 changed files
with
90 additions
and
33 deletions
+90
-33
src/bg-ui/bg-info.vue
src/bg-ui/bg-info.vue
+13
-2
src/page/main/develop/account/add/contact-form.vue
src/page/main/develop/account/add/contact-form.vue
+32
-2
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
+12
-1
src/page/main/develop/account/detail/index.vue
src/page/main/develop/account/detail/index.vue
+2
-2
src/page/main/develop/account/index.vue
src/page/main/develop/account/index.vue
+3
-1
src/page/main/system/organization/directory-form.vue
src/page/main/system/organization/directory-form.vue
+6
-11
src/page/main/system/organization/index.vue
src/page/main/system/organization/index.vue
+3
-2
src/page/main/system/organization/org-form.vue
src/page/main/system/organization/org-form.vue
+9
-7
src/page/main/system/organization/org-user/org-person-form.vue
...age/main/system/organization/org-user/org-person-form.vue
+3
-0
src/page/main/system/organization/tree.vue
src/page/main/system/organization/tree.vue
+5
-4
src/page/main/system/organization/user-detail/index.vue
src/page/main/system/organization/user-detail/index.vue
+1
-0
No files found.
src/bg-ui/bg-info.vue
View file @
c68a4871
...
...
@@ -21,6 +21,7 @@
>
<span
v-if=
"item.state"
:style=
"
{color: stateColor[item.state]}">
<span
class=
"state-dot"
:style=
"
{backgroundColor: stateColor[item.state]}">
</span>
{{
item
.
value
}}
</span>
<span
v-else-if=
"item.secret"
>
{{
secret
(
item
.
value
)
}}
</span>
<span
v-else-if=
"item.idCard"
>
{{
idCardShow
?
item
.
value
:
idcard
(
item
.
value
)
}}
</span>
<span
v-else-if=
"item.callback"
@
click.stop=
"item.callback && item.callback()"
class=
"can_click_text"
>
{{
item
.
value
}}
</span>
<span
v-else
>
{{
item
.
value
}}
</span>
</span>
...
...
@@ -32,6 +33,7 @@
复制
</a>
<bg-icon
v-if=
"item.copy_icon"
@
click=
"copyIcon(item.value)"
class=
"copy-btn"
style=
"font-size: 14px; color: #a9b1c7;cursor: pointer;"
icon=
"#bg-ic-copy"
></bg-icon>
<bg-icon
v-if=
"item.idCard"
@
click=
"idCardShow = !idCardShow"
class=
"copy-btn"
style=
"font-size: 14px; color: #a9b1c7;cursor: pointer;"
icon=
"#bg-ic-eye"
></bg-icon>
<bg-icon
class=
"copy-btn"
style=
"font-size: 14px; color: #a9b1c7;cursor: pointer;"
...
...
@@ -74,6 +76,7 @@ export default {
data
()
{
return
{
show
:
false
,
idCardShow
:
false
,
stateColor
:
{
success
:
'
#48ad97
'
,
danger
:
'
#d75138
'
,
...
...
@@ -146,9 +149,17 @@ export default {
const
str1
=
value
.
substring
(
0
,
3
);
const
str2
=
value
.
substring
(
value
.
length
-
6
,
value
.
length
);
const
passwordStr
=
value
.
substring
(
3
,
value
.
length
-
6
).
split
(
''
).
map
(
item
=>
'
*
'
).
join
(
''
);
console
.
log
(
8888888
)
console
.
log
(
passwordStr
)
return
str1
+
passwordStr
+
str2
},
idcard
(
value
)
{
const
len
=
value
.
length
;
const
str1
=
value
.
substring
(
0
,
3
);
const
str2
=
value
.
substring
(
value
.
length
-
4
,
value
.
length
);
const
passwordStr
=
value
.
substring
(
3
,
value
.
length
-
4
).
split
(
''
).
map
(
item
=>
'
*
'
).
join
(
''
);
return
str1
+
passwordStr
+
str2
},
viewIdCard
()
{
}
},
};
...
...
src/page/main/develop/account/add/contact-form.vue
View file @
c68a4871
...
...
@@ -23,14 +23,25 @@
</
template
>
<
script
setup
>
import
{
reactive
,
ref
,
onMounted
}
from
'
vue
'
import
{
reactive
,
ref
,
onMounted
,
getCurrentInstance
}
from
'
vue
'
const
{
proxy
}
=
getCurrentInstance
()
const
{
$axios
,
$message
}
=
proxy
const
contactForm
=
reactive
({
contact_name
:
''
,
contact_phone
:
''
,
contact_email
:
''
,
remark
:
''
,
})
const
props
=
defineProps
({
formType
:
{
type
:
Boolean
,
default
:
false
,
//false 新建 true 编辑
},
id
:
{
type
:
String
,
default
:
''
,
}
});
const
checkPhone
=
(
rule
,
value
,
callback
)
=>
{
var
phone_ruler
=
/^
(?:(?:\+
|00
)
86
)?
1
[
3-9
]\d{9}
$/
;
...
...
@@ -43,6 +54,24 @@ const checkPhone = (rule, value, callback) => {
});
};
const
checkPhoneRepet
=
(
rule
,
value
,
callback
)
=>
{
let
params
=
null
;
if
(
props
.
id
){
params
=
{
id
:
parseInt
(
props
.
id
),
contact_phone
:
value
,}
}
else
{
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
))
}
})
}
const
contactFormRules
=
reactive
({
contact_name
:
[
{
required
:
true
,
message
:
'
请输入联系人姓名
'
,
trigger
:
'
blur
'
},
...
...
@@ -50,6 +79,7 @@ const contactFormRules = reactive({
contact_phone
:
[
{
required
:
true
,
message
:
'
请输入联系人手机号
'
,
trigger
:
'
blur
'
},
{
validator
:
checkPhone
,
trigger
:
'
blur
'
},
{
validator
:
checkPhoneRepet
,
trigger
:
'
blur
'
}
],
contact_email
:
[
{
type
:
'
email
'
,
message
:
'
请输入正确的邮箱
'
,
trigger
:
'
blur
'
},
...
...
src/page/main/develop/account/add/index.vue
View file @
c68a4871
...
...
@@ -45,7 +45,7 @@
</div>
<div
class=
"content_main"
>
<systemForm
v-show=
"step === 1"
ref=
"systemFormRef"
:form-type=
"route.query.id ? true : false"
:id=
"route.query.id"
@
action=
"getSystemFormData"
></systemForm>
<contactForm
v-show=
"step === 2"
ref=
"contactFormRef"
@
action=
"getContactFormData"
></contactForm>
<contactForm
v-show=
"step === 2"
ref=
"contactFormRef"
:id=
"route.query.id"
@
action=
"getContactFormData"
></contactForm>
<div
class=
"process_end"
v-show=
"step === 3"
>
<div>
<div>
...
...
src/page/main/develop/account/add/system-form.vue
View file @
c68a4871
...
...
@@ -23,7 +23,7 @@
<el-form-item
label=
"AppSecret"
prop=
"appsecret"
v-if=
"formType"
>
<el-input
v-model=
"systemForm.appsecret"
:disabled=
"formType"
style=
"width: 80%;"
/>
<span
class=
"pl-1"
><el-button
type=
"primary"
@
click=
"copyText(systemForm.appsecret)"
>
复制
</el-button></span>
<span
class=
"pl-1"
><el-button
type=
"primary"
>
重置
</el-button></span>
<span
class=
"pl-1"
><el-button
type=
"primary"
@
click=
"resetSecret"
>
重置
</el-button></span>
</el-form-item>
<el-form-item
label=
"系统LOGO"
prop=
"logo"
>
<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>
...
...
@@ -233,6 +233,17 @@ const copyText = (data) => {
}
);
}
const
resetSecret
=
()
=>
{
$axios
.
get
(
`/apaas/system/v5/user/reset/secret/
${
props
.
id
}
`
)
.
then
((
res
)
=>
{
if
(
res
.
data
.
code
==
200
)
{
systemForm
.
appsecret
=
res
.
data
.
data
;
$message
.
success
(
"
重置成功!
"
)
}
else
{
$message
.
error
(
res
.
data
.
data
)
}
})
}
const
getRoleList
=
()
=>
{
$axios
.
get
(
`/apaas/system/v5/org/select/role?is_admin=1`
)
.
then
((
res
)
=>
{
...
...
src/page/main/develop/account/detail/index.vue
View file @
c68a4871
...
...
@@ -155,11 +155,11 @@ const baseInfo = reactive(
baseInfo
[
3
].
value
=
detail
.
system_account
;
baseInfo
[
4
].
value
=
detail
.
app_id
;
baseInfo
[
5
].
value
=
detail
.
app_secret
;
baseInfo
[
6
].
value
=
detail
.
created_by
;
baseInfo
[
6
].
value
=
detail
.
created_by
+
"
(
"
+
(
detail
.
created_user_role
?
detail
.
created_user_role
.
join
(
'
、
'
)
:
''
)
+
"
)
"
;
baseInfo
[
7
].
value
=
detail
.
created_time
;
baseInfo
[
8
].
value
=
detail
.
state
===
1
?
'
是
'
:
'
否
'
;
baseInfo
[
8
].
state
=
detail
.
state
===
1
?
'
success
'
:
'
default
'
;
baseInfo
[
9
].
value
=
detail
.
develop_
id
;
baseInfo
[
9
].
value
=
detail
.
develop_
name
;
baseInfo
[
10
].
value
=
detail
.
access_address
;
baseInfo
[
11
].
value
=
detail
.
business_desc
;
...
...
src/page/main/develop/account/index.vue
View file @
c68a4871
...
...
@@ -237,7 +237,7 @@ import CryptoJS from "crypto-js";
{
label
:
"
创建时间
"
,
prop
:
"
created_time
"
,
width
:
1
5
0
width
:
1
6
0
},
{
label
:
"
是否启用
"
,
...
...
@@ -524,6 +524,8 @@ import CryptoJS from "crypto-js";
if
(
!
passwordRef
)
return
passwordRef
.
value
.
resetFields
()
editFlag
.
value
=
false
;
password_eye
.
value
=
false
;
confirm_eye
.
value
=
false
;
}
const
editConfirm
=
()
=>
{
if
(
!
passwordRef
)
return
...
...
src/page/main/system/organization/directory-form.vue
View file @
c68a4871
...
...
@@ -8,14 +8,13 @@
style=
"max-width: 80%"
>
<el-form-item
label=
"上级目录"
prop=
"p_organization_id"
v-if=
"formType === 'create'"
>
<!--
<el-input
v-model=
"directoryForm.p_organization_id"
style=
"width: 80%;"
/>
-->
<el-tree-select
v-model=
"directoryForm.p_organization_id"
:data=
"orgData"
:props=
"treeProps"
:render-aftertreeProps-expand=
"false"
:filter-node-method=
"filterNode"
:render-after-expand=
"false"
:check-strictly=
"true"
:disabled=
"directoryForm.level"
style=
"width: 80%;"
/>
<el-form-item
label=
""
style=
"padding-left: 16px"
>
<el-checkbox
v-model=
"directoryForm.level"
@
change=
"isTop"
label=
"顶级"
/>
...
...
@@ -72,7 +71,7 @@ import { reactive, ref, onMounted, onBeforeMount, getCurrentInstance, nextTick }
}
const
setForm
=
(
data
)
=>
{
directoryForm
.
value
=
Object
.
assign
(
directoryForm
,
data
);
Object
.
assign
(
directoryForm
,
data
);
}
const
orgData
=
ref
([])
...
...
@@ -80,7 +79,7 @@ import { reactive, ref, onMounted, onBeforeMount, getCurrentInstance, nextTick }
label
:
'
name
'
,
children
:
'
Child
'
,
value
:
'
organization_id
'
,
disabled
:
'
disabled
'
//
disabled: 'disabled'
}
const
getOrgTree
=
()
=>
{
$axios
.
get
(
`/apaas/system/v5/org/tree`
)
...
...
@@ -89,6 +88,7 @@ import { reactive, ref, onMounted, onBeforeMount, getCurrentInstance, nextTick }
const
orgDataTemp
=
res
.
data
.
data
||
[]
orgDataTemp
.
shift
()
orgData
.
value
=
filterOrg
(
orgDataTemp
);
}
else
{
$message
.
error
(
res
.
data
.
data
)
}
...
...
@@ -99,7 +99,6 @@ import { reactive, ref, onMounted, onBeforeMount, getCurrentInstance, nextTick }
if
(
data
.
length
>
0
)
{
data
.
forEach
(
item
=>
{
item
.
disabled
=
item
.
data_type
===
0
?
false
:
true
;
if
(
item
.
Child
){
filterOrg
(
item
.
Child
)
}
else
{
...
...
@@ -110,10 +109,6 @@ import { reactive, ref, onMounted, onBeforeMount, getCurrentInstance, nextTick }
return
data
;
}
const
filterNode
=
(
value
,
data
)
=>
{
return
data
.
data_type
===
0
}
const
isTop
=
(
data
)
=>
{
directoryForm
.
p_organization_id
=
data
?
'
'
:
''
;
//空格绕过表单非空校验
}
...
...
src/page/main/system/organization/index.vue
View file @
c68a4871
...
...
@@ -114,7 +114,7 @@
v-model=
"dialogDirectory"
:title=
"action === 'create' ? '新增目录' : '编辑目录' "
width=
"758px"
:before-close=
"handleCloseDirectory
Directory
"
:before-close=
"handleCloseDirectory"
destroy-on-close
>
<div
class=
"dialog_form"
>
...
...
@@ -412,6 +412,7 @@ import { downloadFileFormatNew } from '@/services/helper'
password
:
''
,
confirm_password
:
''
,
})
const
search
=
ref
(
''
)
const
validatePass
=
(
rule
,
value
,
callback
)
=>
{
if
(
value
!==
passwordForm
.
password
)
{
callback
(
new
Error
(
"
密码输入不一致
"
))
...
...
@@ -796,7 +797,7 @@ import { downloadFileFormatNew } from '@/services/helper'
}
const
editAccount
=
(
data
)
=>
{
if
(
selectTreeDataType
===
1
)
{
if
(
selectTreeDataType
.
value
===
1
)
{
router
.
push
({
path
:
"
/system/organization/org-user
"
,
query
:
{
...
...
src/page/main/system/organization/org-form.vue
View file @
c68a4871
...
...
@@ -8,7 +8,14 @@
style=
"max-width: 80%"
>
<el-form-item
label=
"上级目录"
prop=
"p_organization_id"
v-if=
"formType === 'create'"
>
<el-tree-select
v-model=
"orgForm.p_organization_id"
:data=
"orgData"
:props=
"treeProps"
:render-after-expand=
"false"
:filter-node-method=
"filterNode"
:disabled=
"orgForm.level"
:check-strictly=
"true"
style=
"width: 80%;"
/>
<el-tree-select
v-model=
"orgForm.p_organization_id"
:data=
"orgData"
:props=
"treeProps"
:render-after-expand=
"false"
:check-strictly=
"true"
:disabled=
"orgForm.level"
style=
"width: 80%;"
/>
<el-form-item
label=
""
style=
"padding-left: 16px"
>
<el-checkbox
v-model=
"orgForm.level"
@
change=
"isTop"
label=
"顶级"
/>
</el-form-item>
...
...
@@ -83,7 +90,7 @@ import { reactive, ref, onMounted, onBeforeMount, getCurrentInstance } from 'vue
}
const
setForm
=
(
data
)
=>
{
orgForm
.
value
=
Object
.
assign
(
orgForm
,
data
);
Object
.
assign
(
orgForm
,
data
);
}
const
orgData
=
ref
([])
...
...
@@ -122,11 +129,6 @@ import { reactive, ref, onMounted, onBeforeMount, getCurrentInstance } from 'vue
return
data
;
}
const
filterNode
=
(
value
,
data
)
=>
{
return
data
.
data_type
===
0
}
const
isTop
=
(
data
)
=>
{
orgForm
.
p_organization_id
=
data
?
'
'
:
''
;
//空格绕过表单非空校验
}
...
...
src/page/main/system/organization/org-user/org-person-form.vue
View file @
c68a4871
...
...
@@ -53,6 +53,9 @@ const orgPersonFormRules = reactive({
// { required: true, message: '请输入手机号', trigger: 'blur' },
{
type
:
'
email
'
,
message
:
'
请输入正确的邮箱
'
,
trigger
:
'
blur
'
}
],
document_number
:
[
{
pattern
:
/
(
^
[
1-9
]\d{5}(
18|19|
([
23
]\d))\d{2}((
0
[
1-9
])
|
(
10|11|12
))(([
0-2
][
1-9
])
|10|20|30|31
)\d{3}[
0-9Xx
]
$
)
|
(
^
[
1-9
]\d{5}\d{2}((
0
[
1-9
])
|
(
10|11|12
))(([
0-2
][
1-9
])
|10|20|30|31
)\d{2}[
0-9Xx
]
$
)
/
,
message
:
'
请输入正确的身份证号
'
,
trigger
:
'
blur
'
}
]
})
const
orgPersonFormRef
=
ref
(
null
)
const
emit
=
defineEmits
([
'
action
'
])
...
...
src/page/main/system/organization/tree.vue
View file @
c68a4871
...
...
@@ -38,18 +38,19 @@
v-show=
"actionFlag"
:style=
"{ top: acTop, left: acLeft }"
>
<!-- 平台用户组织 -->
<div
v-if=
"selectData && selectData.data_type === 2"
class=
"action"
@
click=
"treeAction({type: 'directory',action: 'create',target: null})"
>
新建目录
</div>
<div
v-if=
"selectData && selectData.data_type === 2"
class=
"action"
@
click=
"treeAction({type: 'org',action: 'create',target: null})"
>
新建组织
</div>
<!-- 目录 -->
<div
v-if=
"selectData && selectData.data_type === 0"
class=
"action"
@
click=
"treeAction({type: 'directory',action: 'create',target: 'local'})"
>
新建本级目录
</div>
<div
v-if=
"selectData && selectData.data_type === 0"
class=
"action"
@
click=
"treeAction({type: 'directory',action: 'create',target: 'child'})"
>
新建下级目录
</div>
<div
v-if=
"selectData && selectData.data_type === 0"
class=
"action"
@
click=
"treeAction({type: 'org',action: 'create',target: 'local'})"
>
新建本级组织
</div>
<div
v-if=
"selectData && selectData.data_type === 0
&& selectData.level !== 1
"
class=
"action"
@
click=
"treeAction({type: 'org',action: 'create',target: 'local'})"
>
新建本级组织
</div>
<div
v-if=
"selectData && selectData.data_type === 0"
class=
"action"
@
click=
"treeAction({type: 'org',action: 'create',target: 'child'})"
>
新建下级组织
</div>
<div
v-if=
"selectData && selectData.data_type === 0"
class=
"action"
@
click=
"treeAction({type: 'directory',action: 'edit',target: 'local'})"
>
编辑目录
</div>
<div
v-if=
"selectData && selectData.data_type === 0"
class=
"action"
@
click=
"treeAction({type: 'directory',action: 'delete',target: 'local'})"
>
删除
</div>
<div
v-if=
"selectData && selectData.data_type === 0"
class=
"action"
@
click=
"treeAction({type: 'directory',action: 'mvup',target: 'local'})"
>
上移
</div>
<div
v-if=
"selectData && selectData.data_type === 0"
class=
"action"
@
click=
"treeAction({type: 'directory',action: 'mvdown',target: 'local'})"
>
下移
</div>
<!-- 组织 -->
<div
v-if=
"selectData && selectData.data_type === 1"
class=
"action"
@
click=
"treeAction({type: 'org',action: 'create',target: 'local'})"
>
新建本级组织
</div>
<div
v-if=
"selectData && selectData.data_type === 1"
class=
"action"
@
click=
"treeAction({type: 'org',action: 'edit',target: 'local'})"
>
编辑组织
</div>
<div
v-if=
"selectData && selectData.data_type === 1"
class=
"action"
@
click=
"treeAction({type: 'org',action: 'delete',target: 'local'})"
>
删除
</div>
...
...
@@ -132,7 +133,7 @@ import { useRouter } from 'vue-router';
}
const
emit
=
defineEmits
([
'
action
'
])
const
emit
=
defineEmits
([
'
action
'
,
'
select
'
])
const
handleNodeClick
=
(
node
,
nodeAttr
,
treeNode
,
event
)
=>
{
selectData
.
value
=
node
;
emit
(
'
select
'
,
selectData
);
...
...
src/page/main/system/organization/user-detail/index.vue
View file @
c68a4871
...
...
@@ -116,6 +116,7 @@ const accountInfo = reactive(
{
name
:
"
身份证号
"
,
value
:
""
,
idCard
:
true
,
nameWidth
:
130
},
{
...
...
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