Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
丽
丽人贷管理后台
Project
Project
Details
Activity
Releases
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
百灵美选
丽人贷管理后台
Commits
8a771fea
Commit
8a771fea
authored
Oct 11, 2022
by
caimeng
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
新增编辑
parent
5281cb65
Changes
14
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
14 changed files
with
1986 additions
and
74 deletions
+1986
-74
package.json
package.json
+1
-0
approval.vue
src/components/approval.vue
+15
-7
blockHeader.vue
src/components/blockHeader.vue
+13
-1
index.js
src/router/index.js
+37
-1
api.js
src/server/api.js
+80
-11
common.js
src/store/modules/common.js
+10
-9
routes.js
src/store/modules/routes.js
+0
-45
a.js
src/views/merchant/a.js
+165
-0
account.vue
src/views/merchant/com/account.vue
+281
-0
base.vue
src/views/merchant/com/base.vue
+693
-0
product.vue
src/views/merchant/com/product.vue
+374
-0
detail.vue
src/views/merchant/detail.vue
+52
-0
index.scss
src/views/merchant/index.scss
+42
-0
list.vue
src/views/merchant/list.vue
+223
-0
No files found.
package.json
View file @
8a771fea
...
...
@@ -51,6 +51,7 @@
"
js-cookie
"
:
"^2.2.1"
,
"
jsencrypt
"
:
"^3.0.0-rc.1"
,
"
jsplumb
"
:
"^2.14.6"
,
"
local-storage
"
:
"^2.0.0"
,
"
lodash
"
:
"^4.17.20"
,
"
mockjs
"
:
"^1.1.0"
,
"
moment
"
:
"^2.29.3"
,
...
...
src/components/approval.vue
View file @
8a771fea
...
...
@@ -25,7 +25,7 @@
<el-form-item
prop=
'loanIntentionNum'
label=
'申请期数(期)'
>
<el-row>
<el-col
:span=
'14'
>
<span>
{{
loanIntention
Num
}}
月
</span>
<span>
{{
manual
Num
}}
月
</span>
</el-col>
</el-row>
</el-form-item>
...
...
@@ -220,6 +220,7 @@
hasRisk
:
false
,
riskResult
:
null
,
manualAmount
:
''
,
manualNum
:
''
,
creditNo
:
''
,
opinionEnum
:
[],
...
...
@@ -247,14 +248,15 @@
if
(
this
.
item
!==
null
)
{
const
{
clientDetail
,
projectInfoResponse
}
=
this
.
item
const
{
creditNo
,
creditType
}
=
clientDetail
const
{
manualAmount
,
loanIntention
Num
}
=
projectInfoResponse
const
{
manualAmount
,
manual
Num
}
=
projectInfoResponse
this
.
creditNo
=
creditNo
this
.
manualAmount
=
manualAmount
this
.
loanIntentionNum
=
loanIntention
Num
this
.
manualNum
=
manual
Num
this
.
form
.
perAllotAmount
=
manualAmount
this
.
form
.
loanIntentionNum
=
loanIntentionNum
this
.
form
.
loanIntentionNum
=
manualNum
this
.
form
.
creditNo
=
creditNo
this
.
form
.
creditType
=
creditType
...
...
@@ -292,7 +294,7 @@
this
.
$refs
[
'dForm'
].
clearValidate
(
'loanIntentionNum'
)
if
(
this
.
hasRisk
)
{
this
.
form
.
perAllotAmount
=
this
.
manualAmount
this
.
form
.
loanIntentionNum
=
this
.
loanIntention
Num
this
.
form
.
loanIntentionNum
=
this
.
manual
Num
}
}
this
.
form
.
capitalCode
=
capitalCode
...
...
@@ -356,9 +358,15 @@
const
form
=
this
.
form
if
(
this
.
handleRisk
&&
form
.
capitalCode
===
'FENGSHENGBUSINESS'
)
{
form
.
perAllotAmount
=
this
.
manualAmount
form
.
perAllotAmount
=
this
.
manualAmount
;
form
.
loanIntentionNum
=
this
.
loanIntentionNum
;
}
form
.
userId
=
this
.
user
.
userId
form
.
userId
=
this
.
user
.
userId
;
console
.
log
(
form
,
'提交内容'
);
//return;
const
result
=
await
API
.
approveSubmit
({
...
form
})
...
...
src/components/blockHeader.vue
View file @
8a771fea
...
...
@@ -4,6 +4,10 @@
<div
class=
"b-header-inner"
>
<h3>
{{
title
}}
</h3>
</div>
<div
class=
"b-header-extra"
>
<slot></slot>
</div>
</div>
</
template
>
...
...
@@ -28,10 +32,10 @@ export default {
}
.b-header-inner
{
flex
:
1
;
display
:
flex
;
align-items
:
center
;
}
.
b-header-inner
:
:
before
{
content
:
""
;
background-color
:
#155bd4
;
...
...
@@ -48,4 +52,12 @@ export default {
margin
:
0
;
padding
:
0
;
}
.b-header-extra
{
flex
:
1
;
display
:
flex
;
align-items
:
center
;
justify-content
:
flex-end
;
}
</
style
>
src/router/index.js
View file @
8a771fea
...
...
@@ -61,7 +61,9 @@ export const constantRoutes = [
name
:
'404'
,
component
:
()
=>
import
(
'@/views/404'
),
hidden
:
true
}
},
]
export
const
asyncRoutes
=
[
...
...
@@ -252,6 +254,40 @@ export const asyncRoutes = [
}
]
},
{
path
:
'/merchant'
,
name
:
'merchant'
,
component
:
Layout
,
redirect
:
'/merchant/list'
,
alwaysShow
:
true
,
meta
:
{
noKeepAlive
:
true
,
title
:
'商户管理'
,
remixIcon
:
'home-4-line'
},
children
:
[
{
path
:
'list'
,
name
:
'merchantList'
,
component
:
()
=>
import
(
'@/views/merchant/list'
),
meta
:
{
noKeepAlive
:
true
,
title
:
'商户列表'
}
},
{
path
:
'detail'
,
name
:
'merchantDetail'
,
component
:
()
=>
import
(
'@/views/merchant/detail'
),
hidden
:
true
,
meta
:
{
noKeepAlive
:
true
,
title
:
'商户信息'
,
tagHidden
:
true
}
}
]
},
{
path
:
'/admin'
,
name
:
'admin'
,
...
...
src/server/api.js
View file @
8a771fea
...
...
@@ -270,7 +270,7 @@ export default {
// 用户管理
// 用户列表
userList
(
data
){
userList
(
data
)
{
return
request
({
url
:
'/user/searchAll'
,
method
:
'post'
,
...
...
@@ -278,7 +278,7 @@ export default {
})
},
// 用户详情
userDetail
(
params
){
userDetail
(
params
)
{
return
request
({
url
:
'/user/searchAll'
,
method
:
'get'
,
...
...
@@ -286,7 +286,7 @@ export default {
})
},
// 用户新增
userNew
(
data
){
userNew
(
data
)
{
return
request
({
url
:
'/user/insert'
,
method
:
'post'
,
...
...
@@ -294,7 +294,7 @@ export default {
})
},
// 用户编辑
userUpdate
(
data
){
userUpdate
(
data
)
{
return
request
({
url
:
'/user/update'
,
method
:
'post'
,
...
...
@@ -302,7 +302,7 @@ export default {
})
},
// 用户重置密码
userResetPwd
(
data
){
userResetPwd
(
data
)
{
return
request
({
url
:
'/user/resetPassword'
,
method
:
'post'
,
...
...
@@ -310,7 +310,7 @@ export default {
})
},
// 用户修改密码
userUpdatePwd
(
data
){
userUpdatePwd
(
data
)
{
return
request
({
url
:
'/user/updatePassword'
,
method
:
'post'
,
...
...
@@ -319,7 +319,7 @@ export default {
},
// 初始化用户角色
GetAllUserRole
(
params
){
GetAllUserRole
(
params
)
{
return
request
({
url
:
'/role/select'
,
method
:
'get'
,
...
...
@@ -327,7 +327,7 @@ export default {
})
},
// 查询用户角色
GetUserRole
(
params
){
GetUserRole
(
params
)
{
return
request
({
url
:
'/user/selectUserRole'
,
method
:
'get'
,
...
...
@@ -336,7 +336,7 @@ export default {
},
// 设置用户角色
SetUserRole
(
data
){
SetUserRole
(
data
)
{
return
request
({
url
:
'/user/userRole'
,
method
:
'post'
,
...
...
@@ -346,7 +346,7 @@ export default {
// 获取OSS验签
initOssSign
(
params
){
initOssSign
(
params
)
{
return
request
({
url
:
'/common/oss'
,
method
:
'get'
,
...
...
@@ -355,11 +355,80 @@ export default {
},
// 获取OSS验签
saveExtraImg
(
data
){
saveExtraImg
(
data
)
{
return
request
({
url
:
'/credit/uploadExtraAnnex'
,
method
:
'post'
,
data
})
},
/*商户管理*/
// 商户列表
merchantList
(
data
)
{
return
request
({
url
:
'/partner/selectPartnerList'
,
method
:
'post'
,
data
})
},
// 商户新增编辑
merchantUpdate
(
data
)
{
return
request
({
url
:
'/partner/addOrUpdateBasic'
,
method
:
'post'
,
data
})
},
// 商户详情
merchantDetail
(
data
)
{
return
request
({
url
:
'/partner/selectPartnerDetail'
,
method
:
'get'
,
params
:
data
})
},
// 上下架(修改状态)
merchantChangeStatus
(
data
)
{
return
request
({
url
:
'/partner/updatePartnerShelves'
,
method
:
'post'
,
data
})
},
// 商户银行卡列表
merchantBankList
(
data
)
{
return
request
({
url
:
'/partner/selectAccountByPartnerNo'
,
method
:
'get'
,
params
:
data
})
},
// 商户银行卡更新
merchantBankUpdate
(
data
)
{
return
request
({
url
:
'/partner/addOrUpdateAccount'
,
method
:
'post'
,
data
})
},
// 商户产品配置列表
merchantProductList
(
data
)
{
return
request
({
url
:
'/partner/getLrdConfigList'
,
method
:
'get'
,
params
:
data
})
},
// 商户产品配置更新
merchantProductUpdate
(
data
)
{
return
request
({
url
:
'/partner/addOrUpdateLrdConfig'
,
method
:
'post'
,
data
})
},
}
src/store/modules/common.js
View file @
8a771fea
import
ls
from
'local-storage'
import
API
from
'@/server/api'
const
common
=
{
state
:
{
searchData
:
null
,
searchData
:
ls
.
get
(
'SearchData'
)
?
JSON
.
parse
(
ls
.
get
(
'SearchData'
))
:
null
},
actions
:
{
GetSearchData
({
commit
})
{
GetSearchData
({
commit
})
{
return
new
Promise
(
resolve
=>
{
API
.
initSearchData
().
then
((
res
)
=>
{
const
data
=
res
.
result
;
commit
(
"SET_SEARCH_DATA"
,
data
);
resolve
(
data
);
});
});
API
.
initSearchData
().
then
(
async
(
res
)
=>
{
const
data
=
res
.
result
commit
(
'SET_SEARCH_DATA'
,
data
)
await
ls
.
set
(
'SearchData'
,
JSON
.
stringify
(
data
))
resolve
(
data
)
})
})
}
},
mutations
:
{
...
...
src/store/modules/routes.js
View file @
8a771fea
...
...
@@ -25,53 +25,8 @@ const actions = {
let
routes
=
asyncRoutes
console
.
log
(
mode
,
'路由模式'
)
if
(
mode
===
'all'
&&
process
.
env
.
NODE_ENV
!==
'development'
)
{
//let data = [
// {
// path: '/',
// component: 'Layout',
// name: 'Home',
// meta: {
// title: '首页',
// remixIcon: 'home-4-line',
// },
// children: [
// {
// path: 'index',
// name: 'Index',
// component: '@/views/index',
// meta: {
// title: '首页',
// affix: true
// }
// }
// ],
// },
// {
// path: '/user',
// name: 'User',
// component: 'Layout',
// redirect: '/user/list',
// alwaysShow: true,
// meta: {
// title: '用户管理',
// remixIcon: 'apps-line',
// },
// children: [
// {
// path: 'list',
// name: '用户列表',
// component: '@/views/user/list',
// meta: {
// title: '用户列表'
// }
// }
// ]
// }
//];
let
{
result
}
=
await
API
.
userInfo
()
const
data
=
result
.
menuList
if
(
data
[
data
.
length
-
1
].
path
!==
'*'
)
{
data
.
push
({
path
:
'*'
,
redirect
:
'/404'
,
hidden
:
true
})
}
...
...
src/views/merchant/a.js
0 → 100644
View file @
8a771fea
const
a
=
{
'code'
:
'200'
,
'success'
:
true
,
'message'
:
'操作成功!'
,
'result'
:
{
'partnerBasicResponse'
:
{
'partnerNo'
:
'830136976731013003264'
,
'regName'
:
'贵州悦美熹亚医疗服务有限公司'
,
'realName'
:
'贵州悦美熹亚医疗服务有限公司'
,
'establishDate'
:
'2021-05-13T00:00:00'
,
'regAmt'
:
'100'
,
'companyIndustry'
:
6
,
'companyIndustryStr'
:
'医疗防疫'
,
'qualificationType'
:
2
,
'qualificationTypeStr'
:
'医学美容'
,
'branchStatus'
:
0
,
'branchStatusStr'
:
'诊所及个体户'
,
'bizProperty'
:
1
,
'bizPropertyStr'
:
'私营'
,
'isShelves'
:
0
,
'isShelvesStr'
:
'已上架'
,
'addressNature'
:
1
,
'addressNatureStr'
:
'租用'
,
'addressSize'
:
'677.21'
,
'employeesNumber'
:
40
,
'customerSource'
:
1
,
'monthSales'
:
'300'
,
'bizScope'
:
'法律、法规、国务院决定规定禁止的不得经营;法律、法规、国务院决定规定应当许可(审批)的,经审批机关批准后凭许可(审批)文件经营;法律、法规、国务院决定规定无需许可(审批)的,市场主体自主选择经营。(其他未列明商务服务业;医疗美容服务(依法须经批准的项目,经相关部门批准后方可开展经营活动))'
,
'registerAddress'
:
'金华园街道办事处中渝·第一城B2地块第B2-14栋3层1、2号;4层2号'
,
'actualAddress'
:
'金华园街道办事处中渝·第一城B2地块第B2-14栋3层1、2号;4层2号'
,
'lng'
:
'106.639644'
,
'lat'
:
' 26.656524'
,
'regionCode'
:
'100123'
,
'regionName'
:
'贵阳(南宁)'
,
'grade'
:
'0'
,
'coopAgreementExpire'
:
'2023-06-13'
,
'leaseExpire'
:
'2026-03-03'
,
'instLicenceLongTime'
:
null
,
'instLicenceExpire'
:
'长期'
,
'stagingOrdersPercent'
:
null
,
'residentDoctorsNumber'
:
null
,
'operatingRoomsNumber'
:
0
,
'mainProject'
:
''
,
'managementMode'
:
'渠道医院,无返利平台合作'
,
'unifiedCode'
:
'91520115MAAL1JGH2B'
,
'bankLicenseNo'
:
'J7010041421801'
,
'creditCode'
:
'91520115MAAL1JGH2B'
,
'medicalLicenseName'
:
''
,
'medicalLicenseLegal'
:
null
,
'medicalLicensePrincipal'
:
null
,
'medicalLicenseExpire'
:
'2027-06-08'
,
'medicalLicenseAddress'
:
''
,
'hospitalCategory'
:
null
,
'hospitalCategoryStr'
:
null
,
'medicalSubjects'
:
null
}
,
'contactsResponse'
:
{
'partnerNo'
:
'830136976731013003264'
,
'reprName'
:
'李晶晶'
,
'reprIdNo'
:
'511324199701257546'
,
'reprTel'
:
'13310404169'
,
'linkerPosition'
:
'法人'
,
'linker'
:
'李晶晶'
,
'linkerTel'
:
'13310404169'
,
'linkerEmail'
:
''
,
'isDelete'
:
0
,
'gmtCreated'
:
'2022-06-21T05:57:14.000+00:00'
,
'gmtModified'
:
'2022-06-21T05:57:14.000+00:00'
,
'memo'
:
null
}
,
'annexResponseList'
:
[{
'type'
:
'yiyaunzhaopian'
,
'typeStr'
:
'医院照片'
,
'imgData'
:
[
'https://wxres.jqtianxia.com/LRD-FILE/20220822/4f94709217074796ac7d6ee92f24075f.jpg'
]
},
{
'type'
:
'zufanghetong'
,
'typeStr'
:
'租房合同'
,
'imgData'
:
[
'https://wxres.jqtianxia.com/LRD-FILE/20220822/4f94709217074796ac7d6ee92f24075f.jpg'
]
},
{
'type'
:
'yingyezhizhao'
,
'typeStr'
:
'营业执照'
,
'imgData'
:
[
'https://wxres.jqtianxia.com/LRD-FILE/20220822/4f94709217074796ac7d6ee92f24075f.jpg'
]
},
{
'type'
:
'yiliaoxukezheng'
,
'typeStr'
:
'医疗许可证'
,
'imgData'
:
[
'https://wxres.jqtianxia.com/LRD-FILE/20220822/4f94709217074796ac7d6ee92f24075f.jpg'
]
},
{
'type'
:
'shoushudan'
,
'typeStr'
:
'手术单'
,
'imgData'
:
[
'https://wxres.jqtianxia.com/LRD-FILE/20220822/4f94709217074796ac7d6ee92f24075f.jpg'
]
},
{
'type'
:
'shenfenzheng'
,
'typeStr'
:
'法人身份证'
,
'imgData'
:
[
'https://wxres.jqtianxia.com/LRD-FILE/20220822/4f94709217074796ac7d6ee92f24075f.jpg'
]
},
{
'type'
:
'duisishenfenzheng'
,
'typeStr'
:
'对私账户身份证'
,
'imgData'
:
[
'https://wxres.jqtianxia.com/LRD-FILE/20220822/4f94709217074796ac7d6ee92f24075f.jpg'
]
},
{
'type'
:
'yinhangka'
,
'typeStr'
:
'银行卡'
,
'imgData'
:
[
'https://wxres.jqtianxia.com/LRD-FILE/20220822/4f94709217074796ac7d6ee92f24075f.jpg'
]
},
{
'type'
:
'hezuoxieyi'
,
'typeStr'
:
'合作协议'
,
'imgData'
:
[
'https://wxres.jqtianxia.com/LRD-FILE/20220822/4f94709217074796ac7d6ee92f24075f.jpg'
]
}]
}
}
src/views/merchant/com/account.vue
0 → 100644
View file @
8a771fea
<
template
>
<div
class=
'merchant-account'
>
<div>
账户管理
</div>
</div>
</
template
>
<
script
>
import
API
from
'@/server/api'
import
{
mapGetters
}
from
'vuex'
import
Axios
from
'axios'
export
default
{
name
:
'MerchantAccount'
,
data
()
{
return
{
}
},
computed
:
{
...
mapGetters
([
'searchData'
,
'user'
])
},
async
created
()
{
const
{
query
}
=
this
.
$route
if
(
query
&&
query
.
orderNo
)
{
this
.
orderNo
=
query
.
orderNo
await
this
.
init
()
}
},
methods
:
{
// 上传
async
handleUpload
(
obj
)
{
const
{
clientDetail
,
addAttachInfo
}
=
this
.
detail
const
{
file
}
=
obj
let
fileName
=
'jpg'
let
fileType
=
'LRD-ADMIN/audit'
const
resOssSign
=
await
API
.
initOssSign
({
fileName
,
fileType
})
console
.
log
(
resOssSign
,
'oss返回信息'
)
if
(
resOssSign
.
success
)
{
const
{
accessId
,
dir
,
expire
,
host
,
policy
,
signature
}
=
resOssSign
.
result
const
data
=
new
FormData
()
data
.
append
(
'key'
,
dir
)
data
.
append
(
'OSSAccessKeyId'
,
accessId
)
data
.
append
(
'policy'
,
policy
)
data
.
append
(
'Signature'
,
signature
)
data
.
append
(
'success_action_status'
,
'200'
)
data
.
append
(
'file'
,
file
)
try
{
Axios
({
url
:
host
,
method
:
'post'
,
data
:
data
,
headers
:
{
'Content-Type'
:
'multipart/form-data'
}
}).
then
(
async
(
res
)
=>
{
console
.
log
(
res
,
'w'
)
const
uploadFileUrl
=
host
+
dir
const
annexList
=
[
uploadFileUrl
]
const
result
=
await
API
.
saveExtraImg
({
annexList
,
creditNo
:
clientDetail
.
creditNo
})
if
(
result
.
success
)
{
this
.
$message
.
success
(
'上传成功'
)
addAttachInfo
.
push
(
uploadFileUrl
)
this
.
detail
.
addAttachInfo
=
addAttachInfo
}
}).
catch
(
e
=>
{
throw
new
Error
(
e
)
})
}
catch
(
e
)
{
this
.
$message
.
error
(
'上传报错'
)
}
}
},
// 初始化详情
async
init
()
{
const
orderNo
=
this
.
orderNo
const
result
=
await
API
.
loanDetail
({
orderNo
})
const
data
=
result
.
result
const
{
bdInfoResponse
,
clientDetail
,
capitalName
,
clientIdCardInfoResponse
,
collectionAccountResponse
,
creditAttachInfo
,
faceInfoResponse
,
approvalResultResponse
,
projectInfoResponse
,
repayAccountResponse
,
reportResponse
,
supplAttachInfo
,
thirdPartyReport
,
xcxSupplAttachInfo
,
addAttachInfo
}
=
data
this
.
project
=
projectInfoResponse
this
.
client
=
clientDetail
this
.
capitalName
=
capitalName
// 资金方
this
.
collectionAccountResponse
=
collectionAccountResponse
// 收款方信息
this
.
repayAccountResponse
=
repayAccountResponse
// 还款方信息
this
.
bdInfoResponse
=
bdInfoResponse
// 还款方信息
this
.
approvalResultResponse
=
approvalResultResponse
this
.
clientIdCardInfoResponse
=
Object
.
entries
(
clientIdCardInfoResponse
)
this
.
faceInfoResponse
=
Object
.
entries
(
faceInfoResponse
)
this
.
creditAttachInfo
=
creditAttachInfo
// 授信图片信息
this
.
reportResponse
=
reportResponse
this
.
thirdPartyReport
=
JSON
.
parse
(
thirdPartyReport
)
this
.
supplAttachInfo
=
supplAttachInfo
// 附件信息
this
.
addAttachInfo
=
addAttachInfo
if
(
xcxSupplAttachInfo
&&
xcxSupplAttachInfo
.
length
>
0
)
{
this
.
xcxSupplAttachInfo
=
xcxSupplAttachInfo
}
this
.
detail
=
data
if
(
this
.
$route
.
query
&&
this
.
$route
.
query
.
type
)
{
this
.
visible
=
true
this
.
dForm
.
orderNo
=
this
.
orderNo
this
.
dForm
.
stepsNo
=
projectInfoResponse
.
stepsNo
this
.
dForm
.
currentAction
=
projectInfoResponse
.
currentAction
}
},
// 手风琴折叠那啥
handleChange
(
val
)
{
this
.
activeNames
=
val
},
// 稽核审批提交
onSubmit
(
formName
)
{
this
.
$refs
[
formName
].
validate
(
async
(
valid
)
=>
{
if
(
valid
)
{
this
.
$confirm
(
'是否确认提交?'
,
'提示'
,
{
confirmButtonText
:
'确定'
,
cancelButtonText
:
'取消'
,
type
:
'warning'
}).
then
(
async
(
res
)
=>
{
console
.
log
(
res
,
'是啥'
)
const
form
=
this
.
dForm
base
.
userId
=
this
.
user
.
userId
console
.
log
(
base
,
'表单数据'
)
const
result
=
await
API
.
loanAuditSubmit
({
...
base
})
if
(
result
.
success
)
{
this
.
$message
({
type
:
'success'
,
message
:
'操作成功!'
})
}
this
.
onBack
()
}).
catch
((
e
)
=>
{
console
.
log
(
e
,
'取消申述了'
)
})
}
else
{
console
.
log
(
'哈哈错误了'
)
}
})
},
// 返回
onBack
()
{
this
.
$router
.
back
()
},
// 图片上传
arraySplice
(
obj
,
result
)
{
if
(
Array
.
isArray
(
obj
))
{
obj
.
forEach
(
item
=>
{
result
=
result
.
concat
(
item
.
screenList
)
})
}
else
{
const
{
values
}
=
Object
for
(
let
val
of
values
(
obj
))
{
if
(
val
)
result
.
push
(
val
)
}
}
return
result
},
showImgViewer
(
firstImg
)
{
const
{
clientIdCardInfoResponse
,
creditAttachInfo
,
faceInfoResponse
,
supplAttachInfo
,
xcxSupplAttachInfo
,
addAttachInfo
}
=
this
.
detail
let
imgArray
=
[]
// 客户身份证
if
(
clientIdCardInfoResponse
)
{
imgArray
=
this
.
arraySplice
(
clientIdCardInfoResponse
,
imgArray
)
}
// 补充图片
if
(
xcxSupplAttachInfo
&&
xcxSupplAttachInfo
.
length
)
{
imgArray
=
this
.
arraySplice
(
xcxSupplAttachInfo
,
imgArray
)
}
// 活体
if
(
faceInfoResponse
)
{
imgArray
=
this
.
arraySplice
(
faceInfoResponse
,
imgArray
)
}
// 授信图片
if
(
creditAttachInfo
&&
creditAttachInfo
.
length
)
{
imgArray
=
this
.
arraySplice
(
creditAttachInfo
,
imgArray
)
}
// 附件图片
if
(
supplAttachInfo
&&
supplAttachInfo
.
length
)
{
imgArray
=
this
.
arraySplice
(
supplAttachInfo
,
imgArray
)
}
// 额外的图片
if
(
addAttachInfo
&&
addAttachInfo
.
length
)
{
addAttachInfo
.
forEach
(
item
=>
{
imgArray
.
push
(
item
)
})
}
// 获取当前点击图片的索引
const
curIndex
=
imgArray
.
findIndex
((
item
)
=>
item
===
firstImg
)
// 把索引之前的内容copy一份
const
ArrayHeader
=
imgArray
.
slice
(
0
,
curIndex
)
// 删除索引之前的内容
imgArray
.
splice
(
0
,
curIndex
)
console
.
log
(
ArrayHeader
,
imgArray
)
imgArray
=
imgArray
.
concat
(
ArrayHeader
)
console
.
log
(
imgArray
)
this
.
imgList
=
imgArray
this
.
imgList
=
imgArray
this
.
imgViewerVisible
=
true
const
m
=
(
e
)
=>
{
e
.
preventDefault
()
}
document
.
body
.
style
.
overflow
=
'hidden'
document
.
addEventListener
(
'touchmove'
,
m
,
false
)
// 禁止页面滑动
},
closeImgViewer
()
{
this
.
imgViewerVisible
=
false
const
m
=
(
e
)
=>
{
e
.
preventDefault
()
}
document
.
body
.
style
.
overflow
=
'auto'
document
.
removeEventListener
(
'touchmove'
,
m
,
true
)
},
// 上下架
handleChangeStatus
()
{
}
}
}
</
script
>
<
style
lang=
'scss'
src=
'../index.scss'
></
style
>
src/views/merchant/com/base.vue
0 → 100644
View file @
8a771fea
This diff is collapsed.
Click to expand it.
src/views/merchant/com/product.vue
0 → 100644
View file @
8a771fea
This diff is collapsed.
Click to expand it.
src/views/merchant/detail.vue
0 → 100644
View file @
8a771fea
<
template
>
<div
class=
'page merchant-form'
>
<!--判断是否有商户编号-->
<template
v-if=
'partnerNo'
>
<el-tabs
v-model=
'activeName'
@
tab-click=
'handleTabClick'
>
<el-tab-pane
label=
'基础信息'
name=
'Base'
/>
<el-tab-pane
label=
'产品信息'
name=
'Product'
/>
<el-tab-pane
label=
'收款信息'
name=
'Account'
/>
</el-tabs>
</
template
>
<!-- 这里加载组件 -->
<component
:is=
'currentTabComponent'
:merchant-no=
'partnerNo'
></component>
</div>
</template>
<
script
>
import
Base
from
'./com/base'
import
Product
from
'./com/product'
import
Account
from
'./com/account'
export
default
{
name
:
'MerchantDetail'
,
components
:
{
Base
,
Product
,
Account
},
data
()
{
return
{
partnerNo
:
''
,
activeName
:
'Base'
,
currentTabComponent
:
'Base'
}
},
async
created
()
{
const
{
query
}
=
this
.
$route
if
(
query
&&
query
.
partnerNo
)
{
this
.
partnerNo
=
query
.
partnerNo
}
},
methods
:
{
// 选项卡切换
handleTabClick
(
tab
)
{
this
.
currentTabComponent
=
tab
.
name
}
}
}
</
script
>
<
style
lang=
'scss'
src=
'./index.scss'
></
style
>
src/views/merchant/index.scss
0 → 100644
View file @
8a771fea
/* 商户表单 */
.merchant-form
{
box-sizing
:
border-box
;
padding
:
20px
;
background
:
#fff
;
.m-select
{
width
:
100%
;
}
}
.merchant-base
{
.fixed
{
position
:
fixed
;
bottom
:
80px
;
left
:
0
;
display
:
flex
;
align-items
:
center
;
justify-content
:
center
;
width
:
100%
;
}
.auditUpload
{
.el-icon-close-tip
{
display
:
none
!
important
;
}
.el-upload-list__item-actions
{
display
:
inherit
!
important
;
}
}
.is-error
.el-upload--picture-card
{
border-color
:
#ff4d4f
;
}
}
.merchant-product
{
.el-table-input
{
margin-bottom
:
0
;
}
}
src/views/merchant/list.vue
0 → 100644
View file @
8a771fea
<
template
>
<div
class=
'page-fence'
>
<!--搜索-->
<block-header
title=
'搜索'
/>
<div
class=
'search'
>
<el-form
ref=
'form'
label-suffix=
':'
:inline=
'true'
:model=
'queryForm'
class=
'form-inline'
>
<el-form-item
prop=
'partnerName'
label=
'商户注册名称'
>
<el-input
v-model=
'queryForm.partnerName'
clearable
placeholder=
'请输入商户注册名称'
/>
</el-form-item>
<template
v-if=
'searchData!==null'
>
<el-form-item
prop=
'isShelves'
label=
'商户状态'
>
<el-select
v-model=
'queryForm.isShelves'
:popper-append-to-body=
'false'
style=
'width: 100%;'
clearable
>
<el-option
v-for=
'(item,index) in searchData.partnerStatusResponseList'
:key=
'index'
:value=
'item.partnerStatus'
:label=
'item.partnerStatusStr'
>
</el-option>
</el-select>
</el-form-item>
</
template
>
<el-form-item>
<el-button
icon=
'el-icon-search'
type=
'primary'
@
click=
'onSearch'
>
搜 索
</el-button>
<el-button
icon=
'el-icon-delete'
type=
'default'
@
click=
"onReset('form')"
>
重 置
</el-button>
</el-form-item>
</el-form>
</div>
<!--表格-->
<block-header
title=
'商户列表'
>
<el-button
type=
'primary'
size=
'mini'
@
click=
'JumpForm'
>
新增商户
</el-button>
</block-header>
<el-table
ref=
'tableSort'
v-loading=
'listLoading'
border
:data=
'list'
style=
'width: 100%'
>
<el-table-column
v-for=
'(item, index) in finallyColumns'
:key=
'index'
align=
'center'
:label=
'item.label'
:sortable=
'item.sortable'
:width=
'item.width'
:fixed=
'!!item.fixed'
:show-overflow-tooltip=
'!!item.overflow'
>
<
template
#
default=
'{ row }'
>
<div
v-if=
'item.label==="商户状态"'
>
<el-tag
v-if=
'row.isShelves!==0'
type=
'danger'
>
{{
row
.
isShelvesStr
}}
</el-tag>
<el-tag
v-else
type=
'success'
>
{{
row
.
isShelvesStr
}}
</el-tag>
</div>
<span
v-else
>
{{
row
[
item
.
prop
]
}}
</span>
</
template
>
</el-table-column>
<el-table-column
fixed=
'right'
align=
'center'
label=
'操作'
>
<
template
#
default=
'{ row }'
>
<el-button
type=
'text'
@
click=
'handleClick(row)'
>
查看详情
</el-button>
<el-button
type=
'text'
@
click=
'handleClick(row)'
>
编辑
</el-button>
<el-button
v-if=
'row.isShelves'
type=
'text'
@
click=
'handleChangeStatus(row,"down")'
>
下架
</el-button>
<el-button
v-else
type=
'text'
@
click=
'handleChangeStatus(row,"up")'
>
上架
</el-button>
</
template
>
</el-table-column>
</el-table>
<el-pagination
:current-page=
'queryForm.current'
layout=
'total,sizes, prev, pager, next'
:page-sizes=
'[10,20,30,40,50,100]'
:page-size=
'queryForm.size'
:total=
'total'
background
@
size-change=
'handleSizeChange'
@
current-change=
'handleCurrentChange'
/>
</div>
</template>
<
script
>
import
_
from
'lodash'
import
API
from
'@/server/api'
import
{
mapGetters
}
from
'vuex'
export
default
{
name
:
'MerchantList'
,
data
()
{
return
{
checkList
:
[
'商户注册名称'
,
'实际经营名称'
,
'联系人姓名'
,
'联系人电话'
,
'商户状态'
],
columns
:
[
{
order
:
1
,
label
:
'商户注册名称'
,
prop
:
'regName'
},
{
order
:
2
,
label
:
'实际经营名称'
,
prop
:
'realName'
},
{
order
:
3
,
label
:
'联系人姓名'
,
prop
:
'linker'
},
{
order
:
3
,
label
:
'联系人电话'
,
prop
:
'linkerTel'
},
{
order
:
5
,
label
:
'商户状态'
,
prop
:
'isShelvesStr'
}
],
list
:
[],
listLoading
:
true
,
total
:
1
,
queryForm
:
{
current
:
1
,
size
:
10
,
partnerName
:
''
,
isShelves
:
''
,
regionCode
:
''
,
partnerNo
:
''
}
}
},
computed
:
{
finallyColumns
()
{
let
finallyArray
=
[]
this
.
checkList
.
forEach
((
checkItem
)
=>
{
finallyArray
.
push
(
this
.
columns
.
filter
((
item
)
=>
item
.
label
===
checkItem
)[
0
]
)
})
return
_
.
sortBy
(
finallyArray
,
(
item
)
=>
item
.
order
)
},
...
mapGetters
([
'searchData'
,
'user'
])
},
mounted
()
{
this
.
fetchData
()
},
methods
:
{
onSearch
()
{
this
.
queryForm
.
current
=
1
this
.
fetchData
()
},
// 页码变更
handleCurrentChange
(
val
)
{
this
.
queryForm
.
current
=
val
this
.
fetchData
()
},
// 页码变更
handleSizeChange
(
val
)
{
this
.
queryForm
.
current
=
1
this
.
queryForm
.
size
=
val
this
.
fetchData
()
},
async
fetchData
()
{
this
.
listLoading
=
true
const
form
=
this
.
queryForm
const
params
=
Object
.
assign
({},
form
)
delete
params
.
time
const
result
=
await
API
.
merchantList
({
...
params
})
const
{
data
,
total
}
=
result
.
result
this
.
list
=
data
this
.
total
=
total
this
.
listLoading
=
false
},
JumpForm
(
partnerNo
)
{
const
route
=
{
path
:
'/merchant/detail'
}
if
(
partnerNo
)
route
.
query
=
{
partnerNo
}
this
.
$router
.
push
(
route
)
},
handleClick
(
row
)
{
const
{
partnerNo
}
=
row
this
.
JumpForm
(
partnerNo
)
}
}
}
</
script
>
<
style
lang=
'scss'
scoped
>
.page-fence
{
::v-deep
{
i
{
cursor
:
pointer
;
}
}
box-sizing
:
border-box
;
padding
:
20px
;
}
</
style
>
<
style
lang=
'scss'
>
.custom-table-checkbox
{
.el-checkbox
{
display
:
block
!
important
;
margin
:
0
0
$base-padding
/
4
0
;
}
}
.action-bar
{
margin-bottom
:
15px
;
}
</
style
>
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