Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
O
op-web-service
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
bp
op-web-service
Commits
4849f7a2
Commit
4849f7a2
authored
Jun 15, 2021
by
mengwenhao
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix:部分显示补全修改,编辑提交功能增加
parent
ffcd9670
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
107 additions
and
38 deletions
+107
-38
enterprise.js
server/controllers/enterprise.js
+11
-0
router.js
server/router.js
+1
-0
index.vue
src/pages/Enterprise/Audit/index.vue
+14
-10
index.vue
src/pages/Enterprise/Certification/index.vue
+29
-12
enterpriseForm.vue
src/pages/Enterprise/components/enterpriseForm.vue
+44
-15
enterprise.js
src/service/enterprise.js
+8
-1
No files found.
server/controllers/enterprise.js
View file @
4849f7a2
...
@@ -93,6 +93,17 @@ exports.postAudit = async ctx => {
...
@@ -93,6 +93,17 @@ exports.postAudit = async ctx => {
};
};
ctx
.
body
=
await
req
(
ctx
,
opts
);
ctx
.
body
=
await
req
(
ctx
,
opts
);
};
};
// 企业资料修改
exports
.
opBusinessUpdate
=
async
ctx
=>
{
const
url
=
`
${
API_INTERNAL_URI
}
/merchant/inner/op_business_update`
;
const
opts
=
{
url
,
method
:
"POST"
,
json
:
true
,
body
:
ctx
.
request
.
body
};
ctx
.
body
=
await
req
(
ctx
,
opts
);
}
// 商户上传营业执照信息
// 商户上传营业执照信息
exports
.
postBusiness
=
async
ctx
=>
{
exports
.
postBusiness
=
async
ctx
=>
{
...
...
server/router.js
View file @
4849f7a2
...
@@ -34,6 +34,7 @@ router.post(`${API_VERSION}/get_log`, enterprise.getLog);
...
@@ -34,6 +34,7 @@ router.post(`${API_VERSION}/get_log`, enterprise.getLog);
router
.
post
(
`
${
API_VERSION
}
/audit`
,
enterprise
.
postAudit
);
router
.
post
(
`
${
API_VERSION
}
/audit`
,
enterprise
.
postAudit
);
router
.
post
(
`
${
API_VERSION
}
/business`
,
enterprise
.
postBusiness
)
router
.
post
(
`
${
API_VERSION
}
/business`
,
enterprise
.
postBusiness
)
router
.
post
(
`
${
API_VERSION
}
/op_commit`
,
enterprise
.
opCommit
);
router
.
post
(
`
${
API_VERSION
}
/op_commit`
,
enterprise
.
opCommit
);
router
.
post
(
`
${
API_VERSION
}
/op_business_update`
,
enterprise
.
opBusinessUpdate
);
//生活号
//生活号
router
.
post
(
`
${
API_VERSION
}
/merchant/lifeinner/life_info`
,
life
.
get_life_info
)
router
.
post
(
`
${
API_VERSION
}
/merchant/lifeinner/life_info`
,
life
.
get_life_info
)
...
...
src/pages/Enterprise/Audit/index.vue
View file @
4849f7a2
...
@@ -13,7 +13,7 @@
...
@@ -13,7 +13,7 @@
<!-- 审核/查看详情页 -->
<!-- 审核/查看详情页 -->
<el-table
<el-table
v-if=
"pageStatus !== 'EDIT'"
v-if=
"pageStatus !== 'EDIT'
&& pageStatus !== 'COMPILE'
"
border
border
:data=
"messageList"
:data=
"messageList"
>
>
...
@@ -23,10 +23,10 @@
...
@@ -23,10 +23,10 @@
label=
"审核状态"
label=
"审核状态"
>
>
<template
#
default=
"scope"
>
<template
#
default=
"scope"
>
<span
v-if=
"scope.row.audit_status ==
=
5"
>
编辑中
</span>
<span
v-if=
"scope.row.audit_status == 5"
>
编辑中
</span>
<span
v-if=
"scope.row.audit_status ==
=
10"
>
待审核
</span>
<span
v-if=
"scope.row.audit_status == 10"
>
待审核
</span>
<span
v-if=
"scope.row.audit_status ==
=
20"
>
审核成功
</span>
<span
v-if=
"scope.row.audit_status == 20"
>
审核成功
</span>
<span
v-if=
"scope.row.audit_status ==
=
30"
>
审核失败
</span>
<span
v-if=
"scope.row.audit_status == 30"
>
审核失败
</span>
</
template
>
</
template
>
</el-table-column>
</el-table-column>
<!-- 企业ID -->
<!-- 企业ID -->
...
@@ -126,7 +126,7 @@
...
@@ -126,7 +126,7 @@
<enterprise-form
<enterprise-form
:dataForm=
"messageForm"
:dataForm=
"messageForm"
:enterpriseId=
"auditId"
:enterpriseId=
"auditId"
v-if=
"pageStatus === 'EDIT'"
v-if=
"pageStatus === 'EDIT'
|| pageStatus === 'COMPILE'
"
></enterprise-form>
></enterprise-form>
</el-card>
</el-card>
...
@@ -192,15 +192,19 @@
...
@@ -192,15 +192,19 @@
label=
"审核状态"
label=
"审核状态"
>
>
<
template
#
default=
"scope"
>
<
template
#
default=
"scope"
>
<span
v-if=
"scope.row.audit_status ==
=
20"
>
通过
</span>
<span
v-if=
"scope.row.audit_status == 20"
>
通过
</span>
<span
v-if=
"scope.row.audit_status ==
=
30"
>
审核不通过
</span>
<span
v-if=
"scope.row.audit_status == 30"
>
审核不通过
</span>
</
template
>
</
template
>
</el-table-column>
</el-table-column>
<el-table-column
<el-table-column
align=
"center"
align=
"center"
label=
"审核意见"
label=
"审核意见"
prop=
"audit_opinion"
>
></el-table-column>
<
template
#
default=
"scope"
>
<span
v-if=
"scope.row.audit_opinion.length !== 0"
>
{{
scope
.
row
.
audit_opinion
}}
</span>
<span
v-else
>
无
</span>
</
template
>
</el-table-column>
</el-table>
</el-table>
</el-card>
</el-card>
...
...
src/pages/Enterprise/Certification/index.vue
View file @
4849f7a2
...
@@ -155,7 +155,7 @@
...
@@ -155,7 +155,7 @@
>
>
<
template
#
default=
"scope"
>
<
template
#
default=
"scope"
>
<el-button
<el-button
v-if=
"
scope.row.audit_status === 10"
v-if=
"scope.row.audit_status === 10"
size=
"mini"
size=
"mini"
type=
"primary"
type=
"primary"
:disabled=
"!permission.get('audit')"
:disabled=
"!permission.get('audit')"
...
@@ -163,14 +163,28 @@
...
@@ -163,14 +163,28 @@
>
审核
</el-button>
>
审核
</el-button>
<el-button
<el-button
v-if=
" scope.row.audit_status === 30"
v-if=
"
:disabled=
"!permission.get('edit') || scope.row.audit_status !== 30 ? true : false"
scope.row.audit_status === 30 || scope.row.audit_status === 5
"
:disabled=
"
!permission.get('edit') &&
scope.row.audit_status !== 30 &&
scope.row.audit_status !== 5
"
size=
"mini"
size=
"mini"
type=
"success"
type=
"success"
@
click=
"goAuditPage('EDIT', scope.row.enterprise_auth_record_id)"
@
click=
"goAuditPage(scope.row.audit_status=== 5 ? 'COMPILE' : 'EDIT',
>
修改提交
</el-button>
scope.row.enterprise_auth_record_id)"
>
{{
scope
.
row
.
audit_status
===
5
?
"编辑"
:
"修改"
}}
提交
</el-button>
<el-button
<el-button
v-if=
" scope.row.audit_status === 10 || scope.row.audit_status === 20 || scope.row.audit_status === 30 || scope.row.audit_status === 5"
v-if=
"
scope.row.audit_status === 10 ||
scope.row.audit_status === 20 ||
scope.row.audit_status === 30 ||
scope.row.audit_status === 5
"
size=
"mini"
size=
"mini"
type=
"warning"
type=
"warning"
@
click=
"
@
click=
"
...
@@ -195,7 +209,7 @@
...
@@ -195,7 +209,7 @@
v-model=
"detailDialogVisible"
v-model=
"detailDialogVisible"
>
>
<el-input
<el-input
style=
"width:
5
0%"
style=
"width:
4
0%"
placeholder=
"请输入您收到的验证码"
placeholder=
"请输入您收到的验证码"
v-model=
"checkIsCode"
v-model=
"checkIsCode"
></el-input>
></el-input>
...
@@ -266,9 +280,10 @@ export default {
...
@@ -266,9 +280,10 @@ export default {
computed
:
{
computed
:
{
// 使用示例: permission.get("audit") 获取是否有审核权限
// 使用示例: permission.get("audit") 获取是否有审核权限
permission
()
{
permission
()
{
const
modulePermissions
=
this
.
$store
.
getters
.
moduleSubPermissions
(
'enterprise'
)
||
[];
const
modulePermissions
=
console
.
log
(
'Current page func-permissions:'
,
modulePermissions
);
this
.
$store
.
getters
.
moduleSubPermissions
(
"enterprise"
)
||
[];
return
new
Map
(
modulePermissions
.
map
(
ele
=>
[
ele
.
name
,
true
]))
console
.
log
(
"Current page func-permissions:"
,
modulePermissions
);
return
new
Map
(
modulePermissions
.
map
(
ele
=>
[
ele
.
name
,
true
]));
}
}
},
},
...
@@ -321,10 +336,12 @@ export default {
...
@@ -321,10 +336,12 @@ export default {
// 跳转到审核页面
// 跳转到审核页面
goAuditPage
(
pageStatus
,
auditId
)
{
goAuditPage
(
pageStatus
,
auditId
)
{
if
(
pageStatus
===
"EDIT"
)
{
if
(
pageStatus
===
"EDIT"
)
{
console
.
log
(
auditId
);
this
.
auditId
=
auditId
;
this
.
auditId
=
auditId
;
return
(
this
.
detailDialogVisible
=
true
);
return
(
this
.
detailDialogVisible
=
true
);
}
else
{
}
else
if
(
pageStatus
===
"COMPILE"
)
{
this
.
$router
.
push
({
name
:
"Audit"
,
params
:
{
pageStatus
,
auditId
}
});
}
else
{
this
.
$router
.
push
({
name
:
"Audit"
,
params
:
{
pageStatus
,
auditId
}
});
this
.
$router
.
push
({
name
:
"Audit"
,
params
:
{
pageStatus
,
auditId
}
});
}
}
},
},
...
...
src/pages/Enterprise/components/enterpriseForm.vue
View file @
4849f7a2
...
@@ -172,7 +172,7 @@
...
@@ -172,7 +172,7 @@
</
style
>
</
style
>
<
script
>
<
script
>
import
{
postBusiness
,
opCommit
}
from
"@/service/enterprise"
;
import
{
postBusiness
,
opCommit
,
opBusinessUpdate
}
from
"@/service/enterprise"
;
import
{
API_INTERNAL_URI
}
from
"../../../../server/config"
;
import
{
API_INTERNAL_URI
}
from
"../../../../server/config"
;
export
default
{
export
default
{
props
:
{
props
:
{
...
@@ -326,8 +326,12 @@ export default {
...
@@ -326,8 +326,12 @@ export default {
this
.
establishForm
.
userName
=
val
.
legal_person
;
this
.
establishForm
.
userName
=
val
.
legal_person
;
this
.
establishForm
.
legal_mobile
=
val
.
legal_mobile
;
this
.
establishForm
.
legal_mobile
=
val
.
legal_mobile
;
this
.
establishForm
.
mobile
=
val
.
mobile
;
this
.
establishForm
.
mobile
=
val
.
mobile
;
this
.
establishForm
.
legal_mobile
=
val
.
legal_mobile
;
this
.
establishForm
.
user_id
=
val
.
user_id
;
this
.
establishForm
.
user_id
=
val
.
user_id
;
this
.
establishForm
.
sensitiveWord
=
val
.
sensitiveWord
;
this
.
establishForm
.
sensitiveWord
=
val
.
sensitiveWord
;
this
.
establishForm
.
entterpriseImage
=
val
.
entterprise_image
;
this
.
establishForm
.
frontImg
=
val
.
legal_front_id_card
;
this
.
establishForm
.
bakImg
=
val
.
legal_back_id_card
;
}
}
},
},
...
@@ -378,21 +382,47 @@ export default {
...
@@ -378,21 +382,47 @@ export default {
user_id
user_id
}
=
this
.
establishForm
;
}
=
this
.
establishForm
;
/**
/**
* 第一步 企业信息提交
* 第一步 企业信息提交
(修改)
* @param enterpriseQuery
* @param enterpriseQuery
*/
*/
// 1.设置提交参数
console
.
log
(
"是否为修改的ID"
,
this
.
enterpriseId
);
const
enterpriseQuery
=
{
// 提交
code
,
if
(
!
this
.
enterpriseId
)
{
name
,
const
enterpriseQuery
=
{
entterprise_image
,
code
,
data_from
:
3
,
name
,
data_type
,
entterprise_image
,
mobile
data_from
:
3
,
};
data_type
,
const
res
=
await
postBusiness
(
enterpriseQuery
);
mobile
,
if
(
res
.
code
!==
0
)
return
this
.
$message
.
error
(
res
.
reason
);
proxy_user_name
:
this
.
$store
.
state
.
userInfo
.
email
this
.
establishForm
.
enterprise_id
=
res
.
result
.
enterprise_auth_record_id
;
};
const
res
=
await
postBusiness
(
enterpriseQuery
);
if
(
res
.
code
!==
0
)
return
this
.
$message
.
error
(
res
.
reason
);
this
.
establishForm
.
enterprise_id
=
res
.
result
.
enterprise_auth_record_id
;
}
// 修改
else
{
const
{
code
,
name
,
entterprise_image
,
data_type
,
mobile
}
=
this
.
establishForm
;
const
editQuery
=
{
record_id
:
this
.
enterpriseId
,
code
,
name
,
entterprise_image
,
data_type
,
data_from
:
3
,
mobile
};
const
res
=
await
opBusinessUpdate
(
editQuery
);
console
.
log
(
res
);
if
(
res
.
code
!==
0
)
return
this
.
$message
.
error
(
res
.
reason
);
}
/**
/**
* 第二步 法人(经营者信息提交)
* 第二步 法人(经营者信息提交)
*/
*/
...
@@ -408,7 +438,6 @@ export default {
...
@@ -408,7 +438,6 @@ export default {
idcard_number
,
idcard_number
,
name
:
userName
,
name
:
userName
,
legal_mobile
,
legal_mobile
,
mobile
,
data_type
,
data_type
,
user_id
:
user_id
?
parseInt
(
user_id
)
:
""
user_id
:
user_id
?
parseInt
(
user_id
)
:
""
};
};
...
...
src/service/enterprise.js
View file @
4849f7a2
...
@@ -74,4 +74,11 @@ export async function opCommit (params) {
...
@@ -74,4 +74,11 @@ export async function opCommit (params) {
const
res
=
await
axios
.
post
(
`/api/v1/op_commit`
,
params
);
const
res
=
await
axios
.
post
(
`/api/v1/op_commit`
,
params
);
return
res
;
return
res
;
}
}
/**
* 414-3商户后台营业执照更新(op后台)
* @param params 修改企业信息
*/
export
async
function
opBusinessUpdate
(
params
)
{
const
res
=
await
axios
.
post
(
`/api/v1/op_business_update`
,
params
);
return
res
;
}
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