Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
Y
yishuju-ui
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
何远江
yishuju-ui
Commits
6decb858
Commit
6decb858
authored
Mar 17, 2025
by
沈翠玲
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
法务专员和风控专员
parent
5c5357dd
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
13 changed files
with
810 additions
and
395 deletions
+810
-395
user.js
src/api/user.js
+11
-0
ChinaMapChart.vue
src/views/data-screen/components/ChinaMapChart.vue
+103
-357
index.scss
src/views/data-screen/index.scss
+12
-6
index.vue
src/views/data-screen/index.vue
+9
-16
index.vue
src/views/infoGather/constant/index.vue
+3
-2
Customer.vue
src/views/infoGather/customerGather/components/Customer.vue
+9
-11
index.vue
src/views/system/accountManage/index.vue
+3
-0
AccountFormModal.vue
.../system/legalMemberManage/components/AccountFormModal.vue
+130
-0
index.vue
src/views/system/legalMemberManage/index.vue
+198
-0
AccountFormModal.vue
...s/system/riskMemberManage/components/AccountFormModal.vue
+130
-0
index.vue
src/views/system/riskMemberManage/index.vue
+198
-0
index.vue
src/views/system/roleManage/index.vue
+1
-1
vite.config.js
vite.config.js
+3
-2
No files found.
src/api/user.js
View file @
6decb858
...
@@ -11,3 +11,14 @@ export const getUserPage = (params) => {
...
@@ -11,3 +11,14 @@ export const getUserPage = (params) => {
export
const
deleteUsers
=
(
ids
)
=>
{
export
const
deleteUsers
=
(
ids
)
=>
{
return
request
.
get
(
'/login/batchDeleteByIds'
,
{
ids
});
return
request
.
get
(
'/login/batchDeleteByIds'
,
{
ids
});
};
};
export
const
saveLeaderGroup
=
(
data
)
=>
{
return
request
.
post
(
`/leaderGroup/add?username=
${
data
.
username
}
&password=
${
data
.
password
}
&phone=
${
data
.
phone
}
&status=
${
data
.
status
}
&role=
${
data
.
role
}
`
);
};
export
const
getleaderGroupPage
=
(
params
)
=>
{
return
request
.
get
(
'/leaderGroup/page'
,
params
);
};
export
const
batchDeleteByIds
=
(
ids
)
=>
{
return
request
.
get
(
'/leaderGroup/batchDeleteByIds'
,
{
ids
});
};
\ No newline at end of file
src/views/data-screen/components/ChinaMapChart.vue
View file @
6decb858
This diff is collapsed.
Click to expand it.
src/views/data-screen/index.scss
View file @
6decb858
...
@@ -243,10 +243,20 @@
...
@@ -243,10 +243,20 @@
}
}
.dataScreen-main-title
{
.dataScreen-main-title
{
position
:
absolute
;
position
:
absolute
;
top
:
1px
;
top
:
1
0
px
;
left
:
0
;
left
:
0
;
z-index
:
99
;
box-sizing
:
border-box
;
display
:
flex
;
display
:
flex
;
flex-direction
:
column
;
align-items
:
center
;
width
:
270px
;
height
:
25px
;
padding-left
:
30px
;
font-size
:
14px
;
color
:
#ffffff
;
letter-spacing
:
5px
;
background
:
url("./images/map-title-bg.png")
no-repeat
;
background-size
:
100%
100%
;
span
{
span
{
margin-bottom
:
12px
;
margin-bottom
:
12px
;
font-family
:
YouSheBiaoTiHei
;
font-family
:
YouSheBiaoTiHei
;
...
@@ -255,10 +265,6 @@
...
@@ -255,10 +265,6 @@
color
:
#ffffff
;
color
:
#ffffff
;
letter-spacing
:
1px
;
letter-spacing
:
1px
;
}
}
img
{
width
:
68px
;
height
:
7px
;
}
}
}
.dataScreen-main-chart
{
.dataScreen-main-chart
{
width
:
100%
;
width
:
100%
;
...
...
src/views/data-screen/index.vue
View file @
6decb858
...
@@ -18,26 +18,23 @@
...
@@ -18,26 +18,23 @@
<div
class=
"dataScreen-lf"
>
<div
class=
"dataScreen-lf"
>
<div
class=
"dataScreen-top"
>
<div
class=
"dataScreen-top"
>
<div
class=
"dataScreen-main-title"
>
<div
class=
"dataScreen-main-title"
>
<span>
实时在案案人统计
</span>
实时在案案人统计
<img
src=
"./images/dataScreen-title.png"
alt=
""
/>
</div>
</div>
<div
class=
"dataScreen-main-chart"
>
<div
class=
"dataScreen-main-chart"
>
<
RealTimeAccessChart
/
>
<
!--
<RealTimeAccessChart
/>
--
>
</div>
</div>
</div>
</div>
<div
class=
"dataScreen-center"
>
<div
class=
"dataScreen-center"
>
<div
class=
"dataScreen-main-title"
>
<div
class=
"dataScreen-main-title"
>
<span>
案人性别比例
</span>
案人性别比例
<img
src=
"./images/dataScreen-title.png"
alt=
""
/>
</div>
</div>
<div
class=
"dataScreen-main-chart"
>
<div
class=
"dataScreen-main-chart"
>
<
MaleFemaleRatioChart
/
>
<
!--
<MaleFemaleRatioChart
/>
--
>
</div>
</div>
</div>
</div>
<div
class=
"dataScreen-bottom"
>
<div
class=
"dataScreen-bottom"
>
<div
class=
"dataScreen-main-title"
>
<div
class=
"dataScreen-main-title"
>
<span>
案人年龄比例
</span>
案人年龄比例
<img
src=
"./images/dataScreen-title.png"
alt=
""
/>
</div>
</div>
<div
class=
"dataScreen-main-chart"
>
<div
class=
"dataScreen-main-chart"
>
<AgeRatioChart
/>
<AgeRatioChart
/>
...
@@ -71,8 +68,7 @@
...
@@ -71,8 +68,7 @@
</div>
</div>
<div
class=
"dataScreen-cb"
>
<div
class=
"dataScreen-cb"
>
<div
class=
"dataScreen-main-title"
>
<div
class=
"dataScreen-main-title"
>
<span>
历史30天调解催记趋势
</span>
历史30天调解催记趋势
<img
src=
"./images/dataScreen-title.png"
alt=
""
/>
</div>
</div>
<div
class=
"dataScreen-main-chart"
>
<div
class=
"dataScreen-main-chart"
>
<OverNext30Chart
/>
<OverNext30Chart
/>
...
@@ -82,8 +78,7 @@
...
@@ -82,8 +78,7 @@
<div
class=
"dataScreen-rg"
>
<div
class=
"dataScreen-rg"
>
<div
class=
"dataScreen-top"
>
<div
class=
"dataScreen-top"
>
<div
class=
"dataScreen-main-title"
>
<div
class=
"dataScreen-main-title"
>
<span>
调解中心案件量排名
</span>
调解中心案件量排名
<img
src=
"./images/dataScreen-title.png"
alt=
""
/>
</div>
</div>
<div
class=
"dataScreen-main-chart"
>
<div
class=
"dataScreen-main-chart"
>
<HotPlateChart
/>
<HotPlateChart
/>
...
@@ -91,8 +86,7 @@
...
@@ -91,8 +86,7 @@
</div>
</div>
<div
class=
"dataScreen-center"
>
<div
class=
"dataScreen-center"
>
<div
class=
"dataScreen-main-title"
>
<div
class=
"dataScreen-main-title"
>
<span>
年度案件量对比
</span>
年度案件量对比
<img
src=
"./images/dataScreen-title.png"
alt=
""
/>
</div>
</div>
<div
class=
"dataScreen-main-chart"
>
<div
class=
"dataScreen-main-chart"
>
<AnnualUseChart
/>
<AnnualUseChart
/>
...
@@ -100,8 +94,7 @@
...
@@ -100,8 +94,7 @@
</div>
</div>
<div
class=
"dataScreen-bottom"
>
<div
class=
"dataScreen-bottom"
>
<div
class=
"dataScreen-main-title"
>
<div
class=
"dataScreen-main-title"
>
<span>
案源数据统计
</span>
案源数据统计
<img
src=
"./images/dataScreen-title.png"
alt=
""
/>
</div>
</div>
<div
class=
"dataScreen-main-chart"
>
<div
class=
"dataScreen-main-chart"
>
<PlatformSourceChart
/>
<PlatformSourceChart
/>
...
...
src/views/infoGather/constant/index.vue
View file @
6decb858
...
@@ -109,9 +109,10 @@
...
@@ -109,9 +109,10 @@
import
addModel
from
'./components/addModel.vue'
;
import
addModel
from
'./components/addModel.vue'
;
import
{
useDict
}
from
'@/hooks/useDict'
;
import
{
useDict
}
from
'@/hooks/useDict'
;
import
{
useAuthStore
}
from
'@/stores/modules/auth'
;
import
{
useAuthStore
}
from
'@/stores/modules/auth'
;
import
{
useUserStore
}
from
'@/stores/modules/user'
;
const
activeName
=
ref
(
'created'
);
const
activeName
=
ref
(
'created'
);
const
userStore
=
useUserStore
();
const
{
authButtonListGet
}
=
useAuthStore
();
// 获取用户权限列表
const
{
authButtonListGet
}
=
useAuthStore
();
// 获取用户权限列表
const
{
PaymentForm
,
ContractStatus
,
FlowStatus
}
=
useDict
(
"PaymentForm"
,
"ContractStatus"
,
"FlowStatus"
);
const
{
PaymentForm
,
ContractStatus
,
FlowStatus
}
=
useDict
(
"PaymentForm"
,
"ContractStatus"
,
"FlowStatus"
);
const
addModelRef
=
ref
()
const
addModelRef
=
ref
()
...
@@ -294,7 +295,7 @@
...
@@ -294,7 +295,7 @@
default
({
row
})
{
default
({
row
})
{
return
(
return
(
<>
<>
<
ElButton
type
=
"primary"
link
onClick
=
{()
=>
addConstant
(
row
,
true
)}
disabled
=
{
row
.
legalFlowStatus
===
'pass'
&&
row
.
financeFlowStatus
===
'pass'
}
>
<
ElButton
type
=
"primary"
link
onClick
=
{()
=>
addConstant
(
row
,
true
)}
v
-
show
=
{
row
.
createBy
===
userStore
.
userInfo
.
id
}
disabled
=
{
row
.
legalFlowStatus
===
'pass'
&&
row
.
financeFlowStatus
===
'pass'
}
>
修改
修改
<
/ElButton
>
<
/ElButton
>
<
ElButton
type
=
"primary"
link
onClick
=
{()
=>
apply
(
row
,
'finance'
)}
v
-
show
=
{
authButtonListGet
.
includes
(
'finance_apply'
)}
disabled
=
{
row
.
legalFlowStatus
||
row
.
financeFlowStatus
===
'pass'
}
>
<
ElButton
type
=
"primary"
link
onClick
=
{()
=>
apply
(
row
,
'finance'
)}
v
-
show
=
{
authButtonListGet
.
includes
(
'finance_apply'
)}
disabled
=
{
row
.
legalFlowStatus
||
row
.
financeFlowStatus
===
'pass'
}
>
...
...
src/views/infoGather/customerGather/components/Customer.vue
View file @
6decb858
...
@@ -128,17 +128,15 @@
...
@@ -128,17 +128,15 @@
</td>
</td>
</tr>
</tr>
<tr>
<tr>
<td
class=
"label"
rowspan=
"2"
>
个人及夫妻名下车辆
</td>
<td
class=
"label"
>
个人及夫妻名下车辆数量
</td>
<td
class=
"label"
>
数量
</td>
<td
colspan=
"2"
><el-input
class=
"line-input"
v-model=
"form.carNum"
placeholder=
""
/></td>
<td
><el-input
class=
"line-input"
v-model=
"form.carNum"
placeholder=
""
/></td>
<td
class=
"label"
>
个人及夫妻名下房产数量
</td>
<td
class=
"label"
rowspan=
"2"
>
个人及夫妻名下房产
</td>
<td
colspan=
"2"
><el-input
class=
"line-input"
v-model=
"form.houseNum"
placeholder=
""
/></td>
<td
class=
"label"
>
数量
</td>
<td
><el-input
class=
"line-input"
v-model=
"form.houseNum"
placeholder=
""
/></td>
</tr>
</tr>
<tr>
<tr>
<td
class=
"label"
>
总价值
</td>
<td
class=
"label"
>
个人及夫妻名下车辆
总价值
</td>
<td><el-input
class=
"line-input"
v-model=
"form.carPrice"
placeholder=
""
/></td>
<td
colspan=
"2"
><el-input
class=
"line-input"
v-model=
"form.carPrice"
placeholder=
""
/></td>
<td
class=
"label"
>
总价值
</td>
<td
class=
"label"
>
个人及夫妻名下房产
总价值
</td>
<td
colspan=
"2"
><el-input
class=
"line-input"
v-model=
"form.housePrice"
placeholder=
""
/></td>
<td
colspan=
"2"
><el-input
class=
"line-input"
v-model=
"form.housePrice"
placeholder=
""
/></td>
</tr>
</tr>
<tr>
<tr>
...
@@ -438,8 +436,8 @@ const handleQuery = () => {
...
@@ -438,8 +436,8 @@ const handleQuery = () => {
}
}
getDebtInfo
(
form
.
value
.
idCard
).
then
(
res
=>
{
getDebtInfo
(
form
.
value
.
idCard
).
then
(
res
=>
{
if
(
res
.
result
)
{
if
(
res
.
result
)
{
res
.
result
.
creditCard
=
res
.
result
.
creditCard
||
[]
res
.
result
.
creditCard
=
[]
res
.
result
.
lending
=
res
.
result
.
lending
||
[]
res
.
result
.
lending
=
[]
form
.
value
=
res
.
result
form
.
value
=
res
.
result
cardConfig
.
data
=
res
.
result
.
creditCard
cardConfig
.
data
=
res
.
result
.
creditCard
creditArr
.
value
=
res
.
result
.
lending
creditArr
.
value
=
res
.
result
.
lending
...
...
src/views/system/accountManage/index.vue
View file @
6decb858
...
@@ -26,9 +26,11 @@
...
@@ -26,9 +26,11 @@
import
{
reactive
,
ref
}
from
'vue'
;
import
{
reactive
,
ref
}
from
'vue'
;
import
{
ElButton
,
ElMessageBox
,
ElMessage
,
ElTag
}
from
'element-plus'
;
import
{
ElButton
,
ElMessageBox
,
ElMessage
,
ElTag
}
from
'element-plus'
;
import
{
getUserPage
,
saveUser
,
deleteUsers
}
from
'@/api/user'
;
import
{
getUserPage
,
saveUser
,
deleteUsers
}
from
'@/api/user'
;
import
{
useDict
}
from
'@/hooks/useDict'
;
import
{
onMounted
}
from
'vue'
;
import
{
onMounted
}
from
'vue'
;
import
{
getTenantPage
}
from
'@/api/tenant'
;
import
{
getTenantPage
}
from
'@/api/tenant'
;
import
{
getRolePage
}
from
'@/api/role'
;
import
{
getRolePage
}
from
'@/api/role'
;
const
{
Status
}
=
useDict
(
"Status"
);
const
proTable
=
ref
();
const
proTable
=
ref
();
const
accountFormModalRef
=
ref
();
const
accountFormModalRef
=
ref
();
...
@@ -78,6 +80,7 @@
...
@@ -78,6 +80,7 @@
field
:
'status'
,
field
:
'status'
,
title
:
'状态'
,
title
:
'状态'
,
width
:
100
,
width
:
100
,
enum
:
Status
,
search
:
{
el
:
'select'
,
props
:
{
clearable
:
true
},
labelWidth
:
85
},
search
:
{
el
:
'select'
,
props
:
{
clearable
:
true
},
labelWidth
:
85
},
slots
:
{
slots
:
{
default
:
({
row
})
=>
{
default
:
({
row
})
=>
{
...
...
src/views/system/legalMemberManage/components/AccountFormModal.vue
0 → 100644
View file @
6decb858
<
template
>
<vxe-modal
resize
v-model=
"showModal"
:title=
"modalTitle"
@
hide=
"onHide"
width=
"400px"
show-footer
esc-closable
>
<el-form
ref=
"formRef"
inline
:model=
"form"
:rules=
"rules"
label-width=
"80px"
>
<el-row
:gutter=
"10"
>
<el-col
:span=
"24"
>
<el-form-item
class=
"w-full"
label=
"手机号"
prop=
"phone"
>
<el-input
v-model=
"form.phone"
placeholder=
"请输入手机号"
/>
</el-form-item>
</el-col>
<el-col
:span=
"24"
>
<el-form-item
class=
"w-full"
label=
"密码"
prop=
"password"
>
<el-input
v-model=
"form.password"
placeholder=
"请输入密码"
/>
</el-form-item>
</el-col>
<el-col
:span=
"24"
>
<el-form-item
class=
"w-full"
label=
"用户名称"
prop=
"username"
>
<el-input
v-model=
"form.username"
placeholder=
"请输入用户名称"
/>
</el-form-item>
</el-col>
<el-col
:span=
"24"
>
<el-form-item
class=
"w-full"
label=
"状态"
prop=
"status"
>
<el-radio-group
v-model=
"form.status"
>
<el-radio
value=
"enable"
>
启用
</el-radio>
<el-radio
value=
"disable"
>
禁用
</el-radio>
</el-radio-group>
</el-form-item>
</el-col>
</el-row>
</el-form>
<template
#
footer
>
<el-button
type=
"default"
@
click=
"showModal = false"
>
取消
</el-button>
<el-button
type=
"primary"
@
click=
"submitForm"
>
提交
</el-button>
</
template
>
</vxe-modal>
</template>
<
script
setup
>
import
{
computed
}
from
'vue'
;
import
{
ref
}
from
'vue'
;
import
{
saveLeaderGroup
}
from
'@/api/user'
;
import
{
getDefualtRoles
}
from
'@/api/role'
;
import
{
ElMessage
}
from
'element-plus'
;
const
emits
=
defineEmits
([
'success'
]);
const
formRef
=
ref
();
const
showModal
=
ref
(
false
);
const
loading
=
ref
(
false
);
const
form
=
ref
({
username
:
''
,
password
:
''
,
phone
:
''
,
status
:
'enable'
,
});
const
options
=
ref
([]);
const
validatePhone
=
(
rule
,
value
,
callback
)
=>
{
const
reg
=
/^1
[
3-9
]\d{9}
$/
;
if
(
!
value
)
{
callback
(
new
Error
(
'请输入手机号'
));
}
else
if
(
!
reg
.
test
(
value
))
{
callback
(
new
Error
(
'请输入正确的手机号'
));
}
else
{
callback
();
}
};
const
rules
=
ref
({
username
:
{
required
:
true
,
message
:
'请输入用户名称'
,
trigger
:
'blur'
},
password
:
{
required
:
true
,
message
:
'请输入密码'
,
trigger
:
'blur'
},
phone
:
[
{
required
:
true
,
message
:
'请输入手机号'
,
trigger
:
'blur'
},
{
validator
:
validatePhone
,
trigger
:
'blur'
},
],
});
const
currentAccount
=
ref
(
null
);
const
isEdit
=
computed
(()
=>
!!
currentAccount
.
value
);
const
modalTitle
=
computed
(()
=>
(
isEdit
.
value
?
'编辑账号'
:
'新增账号'
));
const
submitForm
=
async
()
=>
{
try
{
await
formRef
.
value
.
validate
();
loading
.
value
=
true
;
await
saveLeaderGroup
({...
form
.
value
,
role
:
'legal_affairs_commissioner'
});
ElMessage
({
type
:
'success'
,
message
:
isEdit
.
value
?
'修改成功!'
:
'添加成功!'
,
plain
:
true
,
});
emits
(
'success'
);
showModal
.
value
=
false
;
}
catch
{}
loading
.
value
=
false
;
};
const
onHide
=
()
=>
{
form
.
value
=
{
username
:
''
,
roles
:
[],
password
:
''
,
phone
:
''
,
status
:
'enable'
,
};
formRef
.
value
.
clearValidate
();
currentAccount
.
value
=
null
;
showModal
.
value
=
false
;
};
const
openModal
=
(
account
)
=>
{
account
&&
(
form
.
value
=
account
);
getDefualtRoles
().
then
((
res
)
=>
{
options
.
value
=
res
.
result
;
});
currentAccount
.
value
=
account
;
showModal
.
value
=
true
;
};
defineExpose
({
openModal
,
});
</
script
>
<
style
lang=
"scss"
scoped
></
style
>
src/views/system/legalMemberManage/index.vue
0 → 100644
View file @
6decb858
<
template
>
<div
class=
"table-box"
>
<ProTable
ref=
"proTable"
:config=
"config"
:api=
"getleaderGroupPage"
:paramCallback=
"paramCallback"
>
<template
#
left_buttons
>
<el-button
v-permission=
"'legal_member_add'"
type=
"primary"
:icon=
"Plus"
@
click=
"accountFormModalRef?.openModal()"
>
新增
</el-button
>
<el-button
v-permission=
"'legal_member_del'"
type=
"danger"
:icon=
"Delete"
@
click=
"handleDelete"
>
删除
</el-button
>
</
template
>
</ProTable>
<AccountFormModal
ref=
"accountFormModalRef"
@
success=
"query"
/>
</div>
</template>
<
script
setup
lang=
"jsx"
name=
"accountManage"
>
import
ProTable
from
'@/components/ProTable/index.vue'
;
import
AccountFormModal
from
'./components/AccountFormModal.vue'
;
import
{
Delete
,
Edit
,
Plus
}
from
'@element-plus/icons-vue'
;
import
{
reactive
,
ref
}
from
'vue'
;
import
{
ElButton
,
ElMessageBox
,
ElMessage
,
ElTag
}
from
'element-plus'
;
import
{
getleaderGroupPage
,
saveLeaderGroup
,
batchDeleteByIds
}
from
'@/api/user'
;
import
{
useDict
}
from
'@/hooks/useDict'
;
import
{
onMounted
}
from
'vue'
;
import
{
getTenantPage
}
from
'@/api/tenant'
;
import
{
getRolePage
}
from
'@/api/role'
;
const
{
Status
}
=
useDict
(
"Status"
);
const
proTable
=
ref
();
const
accountFormModalRef
=
ref
();
const
Rolelist
=
ref
([]);
const
Tenantlist
=
ref
([]);
const
paramCallback
=
(
param
)
=>
{
const
obj
=
JSON
.
parse
(
JSON
.
stringify
(
param
));
obj
[
'staffRole'
]
=
'legal_affairs_commissioner'
return
obj
;
};
const
config
=
reactive
({
columns
:
[
{
type
:
'checkbox'
,
width
:
60
,
fixed
:
'left'
},
{
field
:
'leader.username'
,
width
:
110
,
title
:
'领导用户名称'
,
search
:
{
el
:
'input'
,
labelWidth
:
85
}
},
{
field
:
'staff.username'
,
width
:
110
,
title
:
'员工用户名称'
,
search
:
{
el
:
'input'
,
labelWidth
:
85
}
},
{
showOverflow
:
'tooltip'
,
slots
:
{
default
:
({
row
})
=>
{
return
(
<>
{
Array
.
from
(
new
Set
(
row
.
staff
.
tenantNames
)).
join
(
','
)}
<
/
>
);
},
},
field
:
'tenantNames'
,
enum
:
Tenantlist
,
search
:
{
el
:
'select'
,
props
:
{
filterable
:
true
},
key
:
'tenantId'
,
labelWidth
:
85
},
fieldNames
:
{
label
:
'name'
,
value
:
'id'
},
title
:
'员工调解中心'
},
{
showOverflow
:
'tooltip'
,
slots
:
{
default
:
({
row
})
=>
{
return
(
<>
{
Array
.
from
(
new
Set
(
row
.
staff
.
roleNames
)).
join
(
','
)}
<
/
>
);
},
},
field
:
'role'
,
enum
:
Rolelist
,
search
:
{
el
:
'select'
,
props
:
{
filterable
:
true
},
key
:
'roleCode'
,
labelWidth
:
85
},
fieldNames
:
{
label
:
'roleName'
,
value
:
'roleCode'
},
title
:
'员工角色'
},
{
field
:
'staff.phone'
,
title
:
'员工手机号'
,
width
:
160
,
search
:
{
el
:
'input'
,
props
:
{
clearable
:
true
},
labelWidth
:
85
},
},
{
field
:
'staff.status'
,
title
:
'员工状态'
,
width
:
100
,
enum
:
Status
,
search
:
{
el
:
'select'
,
props
:
{
clearable
:
true
},
labelWidth
:
85
},
slots
:
{
default
:
({
row
})
=>
{
return
(
<
ElTag
type
=
{
row
.
status
==
'enable'
?
'primary'
:
'danger'
}
>
{
row
.
status
==
'enable'
?
'启用'
:
'禁用'
}
<
/ElTag
>
);
},
},
},
{
field
:
'staff.createTime'
,
title
:
'员工创建时间'
,
width
:
170
,
},
{
field
:
'staff.updateTime'
,
title
:
'员工更新时间'
,
width
:
170
,
},
{
field
:
'action'
,
title
:
'操作'
,
width
:
200
,
fixed
:
'right'
,
slots
:
{
default
:
({
row
})
=>
{
return
(
<>
<
ElButton
link
type
=
"primary"
icon
=
{
Edit
}
onClick
=
{()
=>
editAccount
(
row
)}
>
编辑
<
/ElButton
>
<
ElButton
link
type
=
"primary"
icon
=
{
Edit
}
onClick
=
{()
=>
handleDisable
(
row
)}
>
{
row
.
status
==
'enable'
?
'禁用'
:
'启用'
}
<
/ElButton
>
<
/
>
);
},
},
},
],
});
const
handleDelete
=
async
()
=>
{
const
list
=
proTable
.
value
.
element
.
getCheckboxRecords
();
if
(
list
.
length
)
{
await
ElMessageBox
.
confirm
(
'是否确认删除选中账户?'
,
'提示'
,
{
confirmButtonText
:
'确认'
,
cancelButtonText
:
'取消'
,
type
:
'warning'
,
});
const
ids
=
list
.
map
((
v
)
=>
v
.
id
).
join
(
','
);
await
batchDeleteByIds
(
ids
);
ElMessage
({
type
:
'success'
,
message
:
'删除成功!'
,
plain
:
true
,
});
query
();
}
};
const
editAccount
=
(
row
)
=>
accountFormModalRef
.
value
.
openModal
(
JSON
.
parse
(
JSON
.
stringify
(
row
)));
const
handleDisable
=
async
(
row
)
=>
{
await
ElMessageBox
.
confirm
(
`是否确认
${
row
.
status
==
'enable'
?
'禁用'
:
'启用'
}
该用户?`
,
'提示'
,
{
confirmButtonText
:
'确认'
,
cancelButtonText
:
'取消'
,
type
:
'warning'
,
}
);
// 修改的状态
const
status
=
row
.
status
===
'enable'
?
'disable'
:
'enable'
;
await
saveLeaderGroup
({
...
row
,
status
,
});
row
.
status
=
status
;
ElMessage
({
type
:
'success'
,
message
:
`
${
status
==
'enable'
?
'启用'
:
'禁用'
}
成功!`
,
plain
:
true
,
});
};
const
query
=
()
=>
proTable
.
value
?.
search
();
onMounted
(()
=>
{
query
();
getRolePage
({
current
:
1
,
size
:
9999999
}).
then
(
res
=>
{
if
(
res
.
success
)
{
Rolelist
.
value
=
res
.
result
.
content
}
})
getTenantPage
({
current
:
1
,
size
:
9999999
,
status
:
'enable'
}).
then
(
res
=>
{
if
(
res
.
success
)
{
Tenantlist
.
value
=
res
.
result
.
content
console
.
log
(
'Tenantlist.value'
,
Tenantlist
.
value
)
}
})
});
</
script
>
<
style
lang=
"scss"
scoped
></
style
>
src/views/system/riskMemberManage/components/AccountFormModal.vue
0 → 100644
View file @
6decb858
<
template
>
<vxe-modal
resize
v-model=
"showModal"
:title=
"modalTitle"
@
hide=
"onHide"
width=
"400px"
show-footer
esc-closable
>
<el-form
ref=
"formRef"
inline
:model=
"form"
:rules=
"rules"
label-width=
"80px"
>
<el-row
:gutter=
"10"
>
<el-col
:span=
"24"
>
<el-form-item
class=
"w-full"
label=
"手机号"
prop=
"phone"
>
<el-input
v-model=
"form.phone"
placeholder=
"请输入手机号"
/>
</el-form-item>
</el-col>
<el-col
:span=
"24"
>
<el-form-item
class=
"w-full"
label=
"密码"
prop=
"password"
>
<el-input
v-model=
"form.password"
placeholder=
"请输入密码"
/>
</el-form-item>
</el-col>
<el-col
:span=
"24"
>
<el-form-item
class=
"w-full"
label=
"用户名称"
prop=
"username"
>
<el-input
v-model=
"form.username"
placeholder=
"请输入用户名称"
/>
</el-form-item>
</el-col>
<el-col
:span=
"24"
>
<el-form-item
class=
"w-full"
label=
"状态"
prop=
"status"
>
<el-radio-group
v-model=
"form.status"
>
<el-radio
value=
"enable"
>
启用
</el-radio>
<el-radio
value=
"disable"
>
禁用
</el-radio>
</el-radio-group>
</el-form-item>
</el-col>
</el-row>
</el-form>
<template
#
footer
>
<el-button
type=
"default"
@
click=
"showModal = false"
>
取消
</el-button>
<el-button
type=
"primary"
@
click=
"submitForm"
>
提交
</el-button>
</
template
>
</vxe-modal>
</template>
<
script
setup
>
import
{
computed
}
from
'vue'
;
import
{
ref
}
from
'vue'
;
import
{
saveLeaderGroup
}
from
'@/api/user'
;
import
{
getDefualtRoles
}
from
'@/api/role'
;
import
{
ElMessage
}
from
'element-plus'
;
const
emits
=
defineEmits
([
'success'
]);
const
formRef
=
ref
();
const
showModal
=
ref
(
false
);
const
loading
=
ref
(
false
);
const
form
=
ref
({
username
:
''
,
password
:
''
,
phone
:
''
,
status
:
'enable'
,
});
const
options
=
ref
([]);
const
validatePhone
=
(
rule
,
value
,
callback
)
=>
{
const
reg
=
/^1
[
3-9
]\d{9}
$/
;
if
(
!
value
)
{
callback
(
new
Error
(
'请输入手机号'
));
}
else
if
(
!
reg
.
test
(
value
))
{
callback
(
new
Error
(
'请输入正确的手机号'
));
}
else
{
callback
();
}
};
const
rules
=
ref
({
username
:
{
required
:
true
,
message
:
'请输入用户名称'
,
trigger
:
'blur'
},
password
:
{
required
:
true
,
message
:
'请输入密码'
,
trigger
:
'blur'
},
phone
:
[
{
required
:
true
,
message
:
'请输入手机号'
,
trigger
:
'blur'
},
{
validator
:
validatePhone
,
trigger
:
'blur'
},
],
});
const
currentAccount
=
ref
(
null
);
const
isEdit
=
computed
(()
=>
!!
currentAccount
.
value
);
const
modalTitle
=
computed
(()
=>
(
isEdit
.
value
?
'编辑账号'
:
'新增账号'
));
const
submitForm
=
async
()
=>
{
try
{
await
formRef
.
value
.
validate
();
loading
.
value
=
true
;
await
saveLeaderGroup
({...
form
.
value
,
role
:
'risk_control_commissioner'
});
ElMessage
({
type
:
'success'
,
message
:
isEdit
.
value
?
'修改成功!'
:
'添加成功!'
,
plain
:
true
,
});
emits
(
'success'
);
showModal
.
value
=
false
;
}
catch
{}
loading
.
value
=
false
;
};
const
onHide
=
()
=>
{
form
.
value
=
{
username
:
''
,
roles
:
[],
password
:
''
,
phone
:
''
,
status
:
'enable'
,
};
formRef
.
value
.
clearValidate
();
currentAccount
.
value
=
null
;
showModal
.
value
=
false
;
};
const
openModal
=
(
account
)
=>
{
account
&&
(
form
.
value
=
account
);
getDefualtRoles
().
then
((
res
)
=>
{
options
.
value
=
res
.
result
;
});
currentAccount
.
value
=
account
;
showModal
.
value
=
true
;
};
defineExpose
({
openModal
,
});
</
script
>
<
style
lang=
"scss"
scoped
></
style
>
src/views/system/riskMemberManage/index.vue
0 → 100644
View file @
6decb858
<
template
>
<div
class=
"table-box"
>
<ProTable
ref=
"proTable"
:config=
"config"
:api=
"getleaderGroupPage"
:paramCallback=
"paramCallback"
>
<template
#
left_buttons
>
<el-button
v-permission=
"'risk_member_add'"
type=
"primary"
:icon=
"Plus"
@
click=
"accountFormModalRef?.openModal()"
>
新增
</el-button
>
<el-button
v-permission=
"'risk_member_del'"
type=
"danger"
:icon=
"Delete"
@
click=
"handleDelete"
>
删除
</el-button
>
</
template
>
</ProTable>
<AccountFormModal
ref=
"accountFormModalRef"
@
success=
"query"
/>
</div>
</template>
<
script
setup
lang=
"jsx"
name=
"accountManage"
>
import
ProTable
from
'@/components/ProTable/index.vue'
;
import
AccountFormModal
from
'./components/AccountFormModal.vue'
;
import
{
Delete
,
Edit
,
Plus
}
from
'@element-plus/icons-vue'
;
import
{
reactive
,
ref
}
from
'vue'
;
import
{
ElButton
,
ElMessageBox
,
ElMessage
,
ElTag
}
from
'element-plus'
;
import
{
getleaderGroupPage
,
saveLeaderGroup
,
batchDeleteByIds
}
from
'@/api/user'
;
import
{
useDict
}
from
'@/hooks/useDict'
;
import
{
onMounted
}
from
'vue'
;
import
{
getTenantPage
}
from
'@/api/tenant'
;
import
{
getRolePage
}
from
'@/api/role'
;
const
{
Status
}
=
useDict
(
"Status"
);
const
proTable
=
ref
();
const
accountFormModalRef
=
ref
();
const
Rolelist
=
ref
([]);
const
Tenantlist
=
ref
([]);
const
paramCallback
=
(
param
)
=>
{
const
obj
=
JSON
.
parse
(
JSON
.
stringify
(
param
));
obj
[
'staffRole'
]
=
'risk_control_commissioner'
return
obj
;
};
const
config
=
reactive
({
columns
:
[
{
type
:
'checkbox'
,
width
:
60
,
fixed
:
'left'
},
{
field
:
'leader.username'
,
width
:
110
,
title
:
'领导用户名称'
,
search
:
{
el
:
'input'
,
labelWidth
:
85
}
},
{
field
:
'staff.username'
,
width
:
110
,
title
:
'员工用户名称'
,
search
:
{
el
:
'input'
,
labelWidth
:
85
}
},
{
showOverflow
:
'tooltip'
,
slots
:
{
default
:
({
row
})
=>
{
return
(
<>
{
Array
.
from
(
new
Set
(
row
.
staff
.
tenantNames
)).
join
(
','
)}
<
/
>
);
},
},
field
:
'tenantNames'
,
enum
:
Tenantlist
,
search
:
{
el
:
'select'
,
props
:
{
filterable
:
true
},
key
:
'tenantId'
,
labelWidth
:
85
},
fieldNames
:
{
label
:
'name'
,
value
:
'id'
},
title
:
'员工调解中心'
},
{
showOverflow
:
'tooltip'
,
slots
:
{
default
:
({
row
})
=>
{
return
(
<>
{
Array
.
from
(
new
Set
(
row
.
staff
.
roleNames
)).
join
(
','
)}
<
/
>
);
},
},
field
:
'role'
,
enum
:
Rolelist
,
search
:
{
el
:
'select'
,
props
:
{
filterable
:
true
},
key
:
'roleCode'
,
labelWidth
:
85
},
fieldNames
:
{
label
:
'roleName'
,
value
:
'roleCode'
},
title
:
'员工角色'
},
{
field
:
'staff.phone'
,
title
:
'员工手机号'
,
width
:
160
,
search
:
{
el
:
'input'
,
props
:
{
clearable
:
true
},
labelWidth
:
85
},
},
{
field
:
'staff.status'
,
title
:
'员工状态'
,
width
:
100
,
enum
:
Status
,
search
:
{
el
:
'select'
,
props
:
{
clearable
:
true
},
labelWidth
:
85
},
slots
:
{
default
:
({
row
})
=>
{
return
(
<
ElTag
type
=
{
row
.
status
==
'enable'
?
'primary'
:
'danger'
}
>
{
row
.
status
==
'enable'
?
'启用'
:
'禁用'
}
<
/ElTag
>
);
},
},
},
{
field
:
'staff.createTime'
,
title
:
'员工创建时间'
,
width
:
170
,
},
{
field
:
'staff.updateTime'
,
title
:
'员工更新时间'
,
width
:
170
,
},
{
field
:
'action'
,
title
:
'操作'
,
width
:
200
,
fixed
:
'right'
,
slots
:
{
default
:
({
row
})
=>
{
return
(
<>
<
ElButton
link
type
=
"primary"
icon
=
{
Edit
}
onClick
=
{()
=>
editAccount
(
row
)}
>
编辑
<
/ElButton
>
<
ElButton
link
type
=
"primary"
icon
=
{
Edit
}
onClick
=
{()
=>
handleDisable
(
row
)}
>
{
row
.
status
==
'enable'
?
'禁用'
:
'启用'
}
<
/ElButton
>
<
/
>
);
},
},
},
],
});
const
handleDelete
=
async
()
=>
{
const
list
=
proTable
.
value
.
element
.
getCheckboxRecords
();
if
(
list
.
length
)
{
await
ElMessageBox
.
confirm
(
'是否确认删除选中账户?'
,
'提示'
,
{
confirmButtonText
:
'确认'
,
cancelButtonText
:
'取消'
,
type
:
'warning'
,
});
const
ids
=
list
.
map
((
v
)
=>
v
.
id
).
join
(
','
);
await
batchDeleteByIds
(
ids
);
ElMessage
({
type
:
'success'
,
message
:
'删除成功!'
,
plain
:
true
,
});
query
();
}
};
const
editAccount
=
(
row
)
=>
accountFormModalRef
.
value
.
openModal
(
JSON
.
parse
(
JSON
.
stringify
(
row
)));
const
handleDisable
=
async
(
row
)
=>
{
await
ElMessageBox
.
confirm
(
`是否确认
${
row
.
status
==
'enable'
?
'禁用'
:
'启用'
}
该用户?`
,
'提示'
,
{
confirmButtonText
:
'确认'
,
cancelButtonText
:
'取消'
,
type
:
'warning'
,
}
);
// 修改的状态
const
status
=
row
.
status
===
'enable'
?
'disable'
:
'enable'
;
await
saveLeaderGroup
({
...
row
,
status
,
});
row
.
status
=
status
;
ElMessage
({
type
:
'success'
,
message
:
`
${
status
==
'enable'
?
'启用'
:
'禁用'
}
成功!`
,
plain
:
true
,
});
};
const
query
=
()
=>
proTable
.
value
?.
search
();
onMounted
(()
=>
{
query
();
getRolePage
({
current
:
1
,
size
:
9999999
}).
then
(
res
=>
{
if
(
res
.
success
)
{
Rolelist
.
value
=
res
.
result
.
content
}
})
getTenantPage
({
current
:
1
,
size
:
9999999
,
status
:
'enable'
}).
then
(
res
=>
{
if
(
res
.
success
)
{
Tenantlist
.
value
=
res
.
result
.
content
console
.
log
(
'Tenantlist.value'
,
Tenantlist
.
value
)
}
})
});
</
script
>
<
style
lang=
"scss"
scoped
></
style
>
src/views/system/roleManage/index.vue
View file @
6decb858
...
@@ -9,7 +9,7 @@
...
@@ -9,7 +9,7 @@
<RoleFormModal
ref=
"roleModalRef"
@
success=
"query"
/>
<RoleFormModal
ref=
"roleModalRef"
@
success=
"query"
/>
<AllocationMenuModal
ref=
"allocationMenuModalRef"
@
success=
"query"
/>
<AllocationMenuModal
ref=
"allocationMenuModalRef"
@
success=
"query"
/>
<AllocationUserModal
ref=
"allocationUserModalRef"
/>
<AllocationUserModal
ref=
"allocationUserModalRef"
@
success=
"query"
/>
</div>
</div>
</template>
</template>
...
...
vite.config.js
View file @
6decb858
...
@@ -55,8 +55,9 @@ export default defineConfig(({ command, mode }) => {
...
@@ -55,8 +55,9 @@ export default defineConfig(({ command, mode }) => {
port
:
VITE_PORT
,
port
:
VITE_PORT
,
proxy
:
{
proxy
:
{
'/api'
:
{
'/api'
:
{
// target: 'http://192.168.31.128:8080',
// target: 'http://192.168.31.189:8080',
target
:
'http://8.152.205.9:8080'
,
target
:
'http://192.168.31.128:8080'
,
// target: 'http://8.152.205.9:8080',
changeOrigin
:
true
,
changeOrigin
:
true
,
rewrite
:
(
path
)
=>
path
.
replace
(
/^
\/
api/
,
''
),
rewrite
:
(
path
)
=>
path
.
replace
(
/^
\/
api/
,
''
),
},
},
...
...
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