|
@@ -1,6 +1,7 @@
|
|
|
<template>
|
|
|
- <view class="container register">
|
|
|
- <view class="register-error clearfix">
|
|
|
+ <view class="container register" :style="{paddingTop:CustomBar+'px'}">
|
|
|
+ <cu-custom :navbar-data='nvabarData' @navigateBack="hanldNavigateBack"></cu-custom>
|
|
|
+ <view class="register-error clearfix" :style="{top:CustomBar+'px'}">
|
|
|
<view class="error-top animation" @click="showOpenError" :class="{'error-top--none': isOpenError}" >
|
|
|
<view class="name">审核未通过原因</view>
|
|
|
<view class="icon">{{ isOpenError ? '' : '查看详情'}}<text class="iconfont icon-xiangxiajiantou" :class="{'icon-xiangxiajiantou-active':isOpenError}"></text></view>
|
|
@@ -31,34 +32,6 @@
|
|
|
<input class="row-input" type="text" v-model="clubContact" placeholder="请输入联系姓名" maxlength="6"/>
|
|
|
</view>
|
|
|
</view>
|
|
|
- <view class="register-row clearfix">
|
|
|
- <view class="register-from">
|
|
|
- <view class="label">手机号:</view>
|
|
|
- <input class="row-input" type="number" v-model="mobile" placeholder="请输入手机号" maxlength="11"/>
|
|
|
- <view class="row-btn" @click="showCheckPhone">{{ isShowCheckPhone ? '取消修改' : '修改手机号' }}</view>
|
|
|
- </view>
|
|
|
- </view>
|
|
|
- <view class="register-row clearfix" v-show="isShowCheckPhone">
|
|
|
- <view class="register-from code">
|
|
|
- <input class="row-input" type="number" v-model="mobileCode" placeholder="请输入上述手机号的验证码" maxlength="6"/>
|
|
|
- </view>
|
|
|
- <view class="register-from btn" :class="[isMobileDisabled ? 'disabled' : '']">
|
|
|
- <button class="row-input" type="button" @click.stop="getMobileCodeFn" :disabled="isMobileDisabled">{{ mobileCodeText }}</button>
|
|
|
- </view>
|
|
|
- </view>
|
|
|
- <view class="register-row clearfix" v-show="isShowCheckPhone">
|
|
|
- <view class="register-from">
|
|
|
- <input class="row-input" type="number" v-model="newMobile" placeholder="请输入新手机号" maxlength="11"/>
|
|
|
- </view>
|
|
|
- </view>
|
|
|
- <view class="register-row clearfix" v-show="isShowCheckPhone">
|
|
|
- <view class="register-from code">
|
|
|
- <input class="row-input" type="number" v-model="newMobileCode" placeholder="请输入新手机号的验证码" maxlength="6"/>
|
|
|
- </view>
|
|
|
- <view class="register-from btn" :class="[isNewMobileDisabled ? 'disabled' : '']" >
|
|
|
- <button class="row-input" type="button" @click.stop="getNewMobileCodeFn" :disabled="isNewMobileDisabled">{{ newMobileCodeText }}</button>
|
|
|
- </view>
|
|
|
- </view>
|
|
|
</view>
|
|
|
<view class="register-main clearfix" >
|
|
|
<view class="register-row">
|
|
@@ -69,7 +42,7 @@
|
|
|
<view class="register-row clearfix">
|
|
|
<view class="register-from">
|
|
|
<view class="label">机构简称:</view>
|
|
|
- <input class="row-input" type="text" v-model="clubContact" placeholder="请输入您的机构简称" maxlength="10"/>
|
|
|
+ <input class="row-input" type="text" v-model="abbreviation" placeholder="请输入您的机构简称" maxlength="10"/>
|
|
|
</view>
|
|
|
</view>
|
|
|
<view class="register-row clearfix">
|
|
@@ -133,10 +106,6 @@
|
|
|
<view class="label">机构类型:</view>
|
|
|
<view class="row-input picker" @click="bindPickerChange">{{ organizationTypeText }}</view>
|
|
|
<text class="iconfont icon-xiayibu"></text>
|
|
|
-<!-- <picker @change="bindPickerChange" :value="index" :range="organizationTypeList" range-key="name">
|
|
|
- <view class="row-input" :class="[isOrganizationType == 0 ? 'none' : '']">{{organizationTypeList[typtIndex].name}}</view>
|
|
|
- </picker>
|
|
|
- -->
|
|
|
</view>
|
|
|
</view>
|
|
|
<view class="register-row clearfix" v-if="isOrganizationType == 1">
|
|
@@ -254,8 +223,9 @@
|
|
|
<script>
|
|
|
import { mapMutations } from 'vuex';
|
|
|
import mpvueCityPicker from '@/components/mpvue-citypicker/mpvueCityPicker.vue'
|
|
|
- import { organizationUpdateModifyInfo , organizationModifyUpdate } from "@/api/use.js"
|
|
|
- import { getClubMobileCode,getClubNewMobileCode,uploadFileImage } from "@/api/utils.js"
|
|
|
+ import { organizationUpdateModifyInfo } from "@/api/use.js"
|
|
|
+ import { uploadFileImage } from "@/api/utils.js"
|
|
|
+ import { sellerClubUpdate } from "@/api/seller.js"
|
|
|
var self;
|
|
|
export default{
|
|
|
components:{
|
|
@@ -263,28 +233,20 @@ import { mapMutations } from 'vuex';
|
|
|
},
|
|
|
data() {
|
|
|
return{
|
|
|
+ nvabarData: { //顶部自定义导航
|
|
|
+ showCapsule: 1, // 是否显示左上角图标 1表示显示 0表示不显示,
|
|
|
+ showSearch: 0,
|
|
|
+ title: '修改申请信息', // 导航栏 中间的标题
|
|
|
+ },
|
|
|
+ CustomBar:this.CustomBar,// 顶部导航栏高度
|
|
|
isOpenError:false,
|
|
|
errorList:[],
|
|
|
- isShowCheckPhone:false, //是否显示修改手机
|
|
|
- tabCurrentIndex:3,
|
|
|
- isPreviewImage:false, //预览图片开关
|
|
|
- isMobileDisabled: false, //手机验证码按钮控制
|
|
|
- isNewMobileDisabled: false, //手机验证码按钮控制
|
|
|
- userID:'', //用户ID
|
|
|
- clubID:'', //会所ID
|
|
|
- count: '', //倒计时
|
|
|
- newCount: '', //倒计时
|
|
|
- codeTime: null,
|
|
|
- codeTimeNew: null,
|
|
|
- clubName:'', //机构名称
|
|
|
- abbreviation:'', //机构简称
|
|
|
- clubContact:'', //联系人
|
|
|
- mobile:'', //联系人手机号
|
|
|
- newMobile:'', //新联系人手机号
|
|
|
- mobileCode:'', //手机号验证码
|
|
|
- newMobileCode:'', //新手机号手机验证码
|
|
|
- mobileCodeText: '获取验证码',
|
|
|
- newMobileCodeText: '获取验证码',
|
|
|
+ isPreviewImage:false, //预览图片开关
|
|
|
+ userID:'', //用户ID
|
|
|
+ clubID:'', //会所ID
|
|
|
+ clubName:'', //机构名称
|
|
|
+ abbreviation:'', //机构简称
|
|
|
+ clubContact:'', //联系人
|
|
|
socialCreditCode:'', //统一社会信用代码
|
|
|
isAgreed:0, //是否勾选协议
|
|
|
isDisabled:true,
|
|
@@ -323,6 +285,7 @@ import { mapMutations } from 'vuex';
|
|
|
},
|
|
|
onLoad(option) {
|
|
|
console.log(option)
|
|
|
+ this.userID = option.userID
|
|
|
this.organizationInfo()
|
|
|
},
|
|
|
methods:{
|
|
@@ -334,74 +297,71 @@ import { mapMutations } from 'vuex';
|
|
|
})
|
|
|
},
|
|
|
organizationInfo(){
|
|
|
- this.$api.getStorage().then((resolve) =>{
|
|
|
- this.userID = resolve.userID
|
|
|
- organizationUpdateModifyInfo({userID:10283}).then(response =>{
|
|
|
- let organizationClub = response.data.club
|
|
|
- let organizationUser = response.data.user
|
|
|
- this.errorList =organizationUser.auditNoteList
|
|
|
- this.email = organizationUser.email
|
|
|
- this.clubID = organizationUser.clubID
|
|
|
- this.clubName = organizationClub.name
|
|
|
- this.clubContact = organizationClub.linkMan
|
|
|
- this.mobile = organizationUser.bindMobile
|
|
|
- this.abbreviation = organizationClub.sname
|
|
|
- if( organizationClub.provinceID == null ){
|
|
|
- this.addressData.provinceID = ''
|
|
|
- }else{
|
|
|
- this.addressData.provinceID = organizationClub.provinceID
|
|
|
- }
|
|
|
- if( organizationClub.cityID == null ){
|
|
|
- this.addressData.cityID = ''
|
|
|
- }else{
|
|
|
- this.addressData.cityID = organizationClub.cityID
|
|
|
- }
|
|
|
- if( organizationClub.townID == null ){
|
|
|
- this.addressData.townID = ''
|
|
|
+ organizationUpdateModifyInfo({userID:this.userID}).then(response =>{
|
|
|
+ let organizationClub = response.data.club
|
|
|
+ let organizationUser = response.data.user
|
|
|
+ this.errorList =organizationUser.auditNoteList
|
|
|
+ this.email = organizationUser.email
|
|
|
+ this.clubID = organizationUser.clubID
|
|
|
+ this.clubName = organizationClub.name
|
|
|
+ this.clubContact = organizationClub.linkMan1
|
|
|
+ this.mobile = organizationUser.bindMobile
|
|
|
+ this.abbreviation = organizationClub.sname
|
|
|
+ if( organizationClub.provinceID == null ){
|
|
|
+ this.addressData.provinceID = ''
|
|
|
+ }else{
|
|
|
+ this.addressData.provinceID = organizationClub.provinceID
|
|
|
+ }
|
|
|
+ if( organizationClub.cityID == null ){
|
|
|
+ this.addressData.cityID = ''
|
|
|
+ }else{
|
|
|
+ this.addressData.cityID = organizationClub.cityID
|
|
|
+ }
|
|
|
+ if( organizationClub.townID == null ){
|
|
|
+ this.addressData.townID = ''
|
|
|
+ }else{
|
|
|
+ this.addressData.townID = organizationClub.townID
|
|
|
+ }
|
|
|
+ this.addressData.address = organizationClub.provincialAddress
|
|
|
+ this.addressData.addressDetail = organizationClub.address
|
|
|
+ this.socialCreditCode = organizationClub.socialCreditCode
|
|
|
+ this.firstClubType = organizationClub.firstClubType
|
|
|
+ this.secondClubType = organizationClub.secondClubType
|
|
|
+ this.uploadBusinessImage = organizationClub.businessLicenseImage
|
|
|
+ this.uploadMentuzImage = organizationClub.headpic
|
|
|
+ this.uploadMedicalImage = organizationClub.medicalPracticeLicenseImg
|
|
|
+ this.department = organizationClub.department
|
|
|
+ this.clubTelePhone = organizationClub. contractPhone
|
|
|
+ this.clubFax = organizationClub.fax
|
|
|
+ this.companyPprofile = organizationClub.info
|
|
|
+ //机构类型&&主营项目
|
|
|
+ switch(this.firstClubType){
|
|
|
+ case '1':
|
|
|
+ this.organizationTypeText = '医美'
|
|
|
+ this.isOrganizationType = 1
|
|
|
+ break;
|
|
|
+ case '2':
|
|
|
+ this.organizationTypeText = '生美'
|
|
|
+ this.isOrganizationType = 2
|
|
|
+ break;
|
|
|
+ case null:
|
|
|
+ this.organizationTypeText = '请选择机构类型'
|
|
|
+ this.isOrganizationType = 0
|
|
|
+ break;
|
|
|
+ }
|
|
|
+ if(organizationClub.mainpro!=null){
|
|
|
+ if(this.firstClubType == '1'){
|
|
|
+ this.mentuzCampList = this.setNewMainpro(organizationClub.mainpro)
|
|
|
}else{
|
|
|
- this.addressData.townID = organizationClub.townID
|
|
|
- }
|
|
|
- this.addressData.address = organizationClub.provincialAddress
|
|
|
- this.addressData.addressDetail = organizationClub.address
|
|
|
- this.socialCreditCode = organizationClub.socialCreditCode
|
|
|
- this.firstClubType = organizationClub.firstClubType
|
|
|
- this.secondClubType = organizationClub.secondClubType
|
|
|
- this.uploadBusinessImage = organizationClub.businessLicenseImage
|
|
|
- this.uploadMentuzImage = organizationClub.headpic
|
|
|
- this.uploadMedicalImage = organizationClub.medicalPracticeLicenseImg
|
|
|
- this.department = organizationClub.department
|
|
|
- this.clubTelePhone = organizationClub. contractPhone
|
|
|
- this.clubFax = organizationClub.fax
|
|
|
- this.companyPprofile = organizationClub.info
|
|
|
- //机构类型&&主营项目
|
|
|
- switch(this.firstClubType){
|
|
|
- case '1':
|
|
|
- this.organizationTypeText = '医美'
|
|
|
- this.isOrganizationType = 1
|
|
|
- break;
|
|
|
- case '2':
|
|
|
- this.organizationTypeText = '生美'
|
|
|
- this.isOrganizationType = 2
|
|
|
- break;
|
|
|
- case null:
|
|
|
- this.organizationTypeText = '请选择机构类型'
|
|
|
- this.isOrganizationType = 0
|
|
|
- break;
|
|
|
- }
|
|
|
- if(organizationClub.mainpro!=null){
|
|
|
- if(this.firstClubType == '1'){
|
|
|
- this.mentuzCampList = this.setNewMainpro(organizationClub.mainpro)
|
|
|
- }else{
|
|
|
- this.medicaCampList = this.setNewMainpro(organizationClub.mainpro)
|
|
|
- }
|
|
|
- }
|
|
|
- //机构类型
|
|
|
- switch(this.secondClubType){
|
|
|
- case '1':this.current = 0;break;
|
|
|
- case '2':this.current = 1;this.isDepartment=true;break;
|
|
|
- case '3':this.current = 2;this.isDepartment=true;break;
|
|
|
+ this.medicaCampList = this.setNewMainpro(organizationClub.mainpro)
|
|
|
}
|
|
|
- })
|
|
|
+ }
|
|
|
+ //机构类型
|
|
|
+ switch(this.secondClubType){
|
|
|
+ case '1':this.current = 0;break;
|
|
|
+ case '2':this.current = 1;this.isDepartment=true;break;
|
|
|
+ case '3':this.current = 2;this.isDepartment=true;break;
|
|
|
+ }
|
|
|
}).catch(response =>{
|
|
|
this.$util.msg(response.msg,2000)
|
|
|
})
|
|
@@ -428,11 +388,7 @@ import { mapMutations } from 'vuex';
|
|
|
userID:this.userID,
|
|
|
clubID:this.clubID, //会所ID
|
|
|
name:this.clubName,
|
|
|
- linkMan:this.clubContact,
|
|
|
- contractMobile2:this.mobile,
|
|
|
- contractMobile:this.newMobile,
|
|
|
- mobileCode:this.mobileCode,
|
|
|
- newMobileCode:this.newMobileCode,
|
|
|
+ linkMan1:this.clubContact,
|
|
|
sname:this.abbreviation,
|
|
|
provinceID:this.addressData.provinceID,
|
|
|
cityID:this.addressData.cityID,
|
|
@@ -452,83 +408,17 @@ import { mapMutations } from 'vuex';
|
|
|
info : this.companyPprofile
|
|
|
}
|
|
|
console.log(params)
|
|
|
- organizationModifyUpdate(params).then(response =>{
|
|
|
- this.$util.msg(response.msg,2000);
|
|
|
+ sellerClubUpdate(params).then(response =>{
|
|
|
+ this.$util.msg('修改成功',2000);
|
|
|
setTimeout(()=>{
|
|
|
- this.$api.switchTabTo('/pages/tabBar/home/home')
|
|
|
+ uni.navigateBack({
|
|
|
+ delta: 1
|
|
|
+ });
|
|
|
},2000)
|
|
|
}).catch(response =>{
|
|
|
this.$util.msg(response.msg,2000);
|
|
|
})
|
|
|
},
|
|
|
- getMobileCodeFn(){
|
|
|
- if( this.mobile == ''){
|
|
|
- this.$util.msg('请输入手机号',2000);
|
|
|
- return
|
|
|
- }
|
|
|
- if(!this.$reg.isMobile(this.mobile)){
|
|
|
- this.$util.msg('请输入正确的手机号',2000);
|
|
|
- return
|
|
|
- }
|
|
|
- let params = { mobile : this.mobile }
|
|
|
- this.isMobileDisabled = true;
|
|
|
- getClubMobileCode(params).then(response =>{
|
|
|
- this.$util.msg('验证短信已发送',2000);
|
|
|
- const TIME_COUNT = 60;
|
|
|
- if (!this.codeTime) {
|
|
|
- this.count = TIME_COUNT;
|
|
|
- this.isMobileDisabled = true;
|
|
|
- this.codeTime = setInterval(() => {
|
|
|
- if (this.count > 1 && this.count <= TIME_COUNT) {
|
|
|
- this.count--
|
|
|
- this.mobileCodeText = this.count +'s重新发送'
|
|
|
- } else {
|
|
|
- this.isMobileDisabled = false;
|
|
|
- clearInterval(this.codeTime)
|
|
|
- this.codeTime = null
|
|
|
- this.mobileCodeText = '获取验证码'
|
|
|
- }
|
|
|
- },1000)
|
|
|
- }
|
|
|
- }).catch( response =>{
|
|
|
- this.$util.msg(response.msg,2000);
|
|
|
- this.isMobileDisabled = false;
|
|
|
- })
|
|
|
- },
|
|
|
- getNewMobileCodeFn(){
|
|
|
- if( this.newMobile == ''){
|
|
|
- this.$util.msg('请输入手机号',2000);
|
|
|
- return
|
|
|
- }
|
|
|
- if(!this.$reg.isMobile(this.newMobile)){
|
|
|
- this.$util.msg('请输入正确的手机号',2000);
|
|
|
- return
|
|
|
- }
|
|
|
- let params = { newMobile : this.newMobile }
|
|
|
- this.isNewMobileDisabled = true;
|
|
|
- getClubNewMobileCode(params).then(response =>{
|
|
|
- this.$util.msg('验证短信已发送',2000);
|
|
|
- const TIME_COUNT = 60;
|
|
|
- if (!this.codeTimeNew) {
|
|
|
- this.newCount = TIME_COUNT;
|
|
|
- this.isNewMobileDisabled = true;
|
|
|
- this.codeTimeNew = setInterval(() => {
|
|
|
- if (this.newCount > 1 && this.newCount <= TIME_COUNT) {
|
|
|
- this.newCount
|
|
|
- this.newMobileCodeText = this.newCount +'s重新发送'
|
|
|
- } else {
|
|
|
- this.isNewMobileDisabled = false;
|
|
|
- clearInterval(this.codeTimeNew)
|
|
|
- this.codeTimeNew = null
|
|
|
- this.newMobileCodeText = '获取验证码'
|
|
|
- }
|
|
|
- },1000)
|
|
|
- }
|
|
|
- }).catch( res =>{
|
|
|
- this.$util.msg(response.msg,2000);
|
|
|
- this.isNewMobileDisabled = false;
|
|
|
- })
|
|
|
- },
|
|
|
// 三级联动选择
|
|
|
showMulLinkageThreePicker() {
|
|
|
this.isShowInput = true
|
|
@@ -659,6 +549,8 @@ import { mapMutations } from 'vuex';
|
|
|
this.isCheck = !this.isCheck
|
|
|
if(this.isCheck){
|
|
|
this.isAgreed = 1
|
|
|
+ }else{
|
|
|
+ this.isAgreed = 0
|
|
|
}
|
|
|
},
|
|
|
onBlurInput(e){//
|
|
@@ -691,13 +583,6 @@ import { mapMutations } from 'vuex';
|
|
|
showOpenError(){//顶部审核信息详情
|
|
|
this.isOpenError = !this.isOpenError
|
|
|
},
|
|
|
- showCheckPhone(){//控制修改手机显隐
|
|
|
- this.isShowCheckPhone = !this.isShowCheckPhone
|
|
|
- },
|
|
|
- steps(index) {//$attrstab切换
|
|
|
- console.log(index)
|
|
|
- this.tabCurrentIndex = index;
|
|
|
- }
|
|
|
},
|
|
|
onShow() {
|
|
|
if(this.isPreviewImage){
|