Commit 34708a5f by Jianli Ou

调整厂商实名认证首次,变更,修改信息逻辑

对接修改手机号
parent 13cf1d96
......@@ -62,7 +62,22 @@ const tycpdmfirmReturnFile = (params = {}) => {
const redirectGLN = () => {
return POST(`${Prefix}/office/tycpdmfirm/authApi/redirectGLN`)
}
// 修改企业信息(不需审批)
const updateTycpdmFirmInfo = (params = {}) => {
return POST(`${Prefix}/office/tycpdmfirm/authApi/update`, params)
}
// 企业信息(不需审批)
const tycpdmFirmInfoNoAuth = (params = {}) => {
return POST(`${Prefix}/office/tycpdmfirm/authApi/findByUserName`, params)
}
// 获取验证码(修改手机号)
const getVerificationCode = (params = {}) => {
return POST(`${Prefix}/office/member/api/getVerificationCode`, params)
}
//
const updatePhone = (params = {}) => {
return POST(`${Prefix}/office/member/authApi/updatephone`, params)
}
export default {
memberInfo,
saveMemberInfo,
......@@ -77,5 +92,9 @@ export default {
tycpdmfirmChangeAuditList,
tycpdmfirmupdateSystem,
tycpdmfirmReturnFile,
redirectGLN
redirectGLN,
updateTycpdmFirmInfo,
tycpdmFirmInfoNoAuth,
getVerificationCode,
updatePhone
}
......@@ -618,7 +618,7 @@ const routes = [
},
component: () => import("@/views/News/NoticeArticle.vue"),
},
{
path: "/News/Health",
name: "Health",
......@@ -651,7 +651,7 @@ const routes = [
},
component: () => import("@/views/News/Retail.vue"),
},
{
path: "/News/Logistics",
name: "Logistics",
......@@ -1032,6 +1032,14 @@ const routes = [
},
component: () => import("@/views/MyManage/UnVerify/changePhone.vue"),
},
{
path: "/MyManage/UnVerify/vendorModify",
name: "vendorModify",
meta: {
name: "修改企业信息",
},
component: () => import("@/views/MyManage/UnVerify/vendorModify.vue"),
},
// 系统成员
{
path: "/MyManage/SystemMember/index",
......
<template>
<div class="container2">
<div class="content">
<div class="title">个人资料</div>
<div class="content-from">
<el-form ref='ruleForm'
label-position='right'
......@@ -41,16 +41,16 @@
</el-form-item>
</el-form>
</div>
<div class="btn-div">
<el-button type="primary" style="width: 110px">保 存</el-button>
<el-button type="primary" @click="savePhone" style="width: 110px">保 存</el-button>
</div>
</div>
</div>
......@@ -68,17 +68,37 @@ export default {
mobile:'',
validate:''
},
loginInfo: {},
memberInfo: {},
mobilePattern: /^((13[0-9])|(15[^4])|(18[0-9])|(17[0-8])|(147))\d{8}$/,
}
},
methods: {
async savePhone() {
const form = {
id: this.loginInfo.id,
phone: this.form.mobile,
verification: this.form.validate
}
const result = await this.$api.myManage.updatePhone(form)
if (result.success) {
this.$message.success('保存成功')
} else {
this.$message.error(result.returnMsg)
}
},
sendValidateCode() {
async sendValidateCode() {
if (this.form.mobile === '') {
this.$message({type: 'error', message: '请输入手机号码'});
} else {
const result = await this.$api.myManage.getVerificationCode({phone: this.form.mobile, userName: this.memberInfo.username})
if (result.success) {
this.$message.success('验证码已发送')
} else {
this.$message.error(result.returnMsg)
return
}
this.hasSent = true;
this.timer = setInterval(() => {
this.time -= 1;
......@@ -112,16 +132,21 @@ export default {
resolve(true);
});
},
async getMemberInfo() {
this.memberInfo = (await this.$api.myManage.memberInfo({id: this.loginInfo.id})).data
},
},
mounted() {
this.loginInfo = JSON.parse(localStorage.getItem('loginInfo'))
this.getMemberInfo()
}
}
</script>
<style lang="scss" scoped>
.container2{
.content{
@include module-box;
margin-top: 14px;
......@@ -138,26 +163,26 @@ export default {
color: #F26335;
}
}
.content-from{
padding:0 40px;
width: 70%;
.el-form {
margin-top: 36px;
.smallselect{
width: 100px!important;
}
.el-select{
width: 100%;
}
.el-input-group__append {
border-color: transparent;
border: none;
button.el-button--primary {
background-color: $theme-color1;
border-color: $theme-color1;
......@@ -183,7 +208,7 @@ export default {
font-size: 13px;
}
}
}
}
.btn-div{
......@@ -206,10 +231,10 @@ export default {
.container2 .content .content-from {
width: 100%;
margin: 0;
padding:0 10px;
}
}
</style>
\ No newline at end of file
</style>
......@@ -108,7 +108,7 @@
</div>
</li>
<!-- 校准已认证 -->
<li>
<li v-if="false">
<p class="content-title">
检测校准申请(办理“条码印制品检测”、“条码检测仪校准”等业务需先完成此申请)
</p>
......
......@@ -4,7 +4,11 @@
<p><i class="bi bi-exclamation-triangle-fill"></i>厂商实名认证(办理“进口商品信息通报、GLN”等业务需先完成此认证)</p>
</div>
<div class="content">
<div class="title">厂商实名认证——填写实名信息 <a href="/MyManage/UnVerify/index">返回我的首页</a></div>
<div class="title">
{{status === 2 ? '变更厂商实名认证信息' : '厂商实名认证——填写实名信息'}}
<a v-if="status !== 2" href="/MyManage/UnVerify/index">返回我的首页</a>
<a v-else href="/MyManage/UnVerify/vendorModify">修改企业信息</a>
</div>
<div class="content-list">
<p >
<span>1.填写实名信息</span>
......
......@@ -87,7 +87,66 @@ export default {
index: 2,
link: "/MyManage/UnVerify/changePhone",
},
],
},
],
isQYRouterList: [
{
id: uuid("gs_nav"),
name: "首页",
index: 0,
link: "/MyManage/UnVerify/index",
},
{
id: uuid("gs_nav"),
name: "业务管理",
index: 1,
link: "",
children: [
{
id: uuid("gs_nav"),
name: "商品条码在线注册",
index: 0,
link: "/Business",
},
{
id: uuid("gs_nav"),
name: "检测校准申请",
index: 2,
link: "/MyManage/UnVerify/calibration",
},
],
},
{
id: uuid("gs_nav"),
name: "用户信息管理",
index: 2,
link: "",
children: [
{
id: uuid("gs_nav"),
name: "个人资料",
index: 0,
link: "/MyManage/UnVerify/personalInfo",
},
{
id: uuid("gs_nav"),
name: "修改登录密码",
index: 1,
link: "/MyManage/UnVerify/changePass",
},
{
id: uuid("gs_nav"),
name: "修改手机号码",
index: 2,
link: "/MyManage/UnVerify/changePhone",
},
{
id: uuid("gs_nav"),
name: "变更企业信息",
index: 1,
link: "/MyManage/UnVerify/vendor",
},
],
},
],
......@@ -180,6 +239,10 @@ export default {
if (this.loginInfo.userType !== 3) { // 业务大厅用户不展示厂商实名认证菜单
this.routerList[1].children = this.routerList[1].children.filter(item => item.index !== 1)
}
if (this.loginInfo.userType === 3 && this.loginInfo.isQY === 1) {
this.$store.commit("system/SET_SUB_NAV", this.isQYRouterList);
return
}
this.$store.commit("system/SET_SUB_NAV", this.routerList);
} else if (this.userType === SYSTEM_MEMBER) {
if (this.loginInfo.userType !== 3) { // 业务大厅用户不展示厂商实名认证菜单
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment