|
@@ -28,29 +28,29 @@
|
|
<view class="register-row clearfix">
|
|
<view class="register-row clearfix">
|
|
<view class="register-from">
|
|
<view class="register-from">
|
|
<view class="label">手机号:</view>
|
|
<view class="label">手机号:</view>
|
|
- <input class="row-input" type="number" v-model="registerEmail" placeholder="请输入手机号" maxlength="11"/>
|
|
|
|
- <view class="row-btn" @click="showCheckPhone">{{isShowCheckPhone?'取消修改':'修改手机号'}}</view>
|
|
|
|
|
|
+ <input class="row-input" type="number" v-model="mobile" placeholder="请输入手机号" maxlength="11"/>
|
|
|
|
+ <view class="row-btn" @click="showCheckPhone">{{ isShowCheckPhone ? '取消修改' : '修改手机号' }}</view>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
<view class="register-row clearfix" v-show="isShowCheckPhone">
|
|
<view class="register-row clearfix" v-show="isShowCheckPhone">
|
|
<view class="register-from code">
|
|
<view class="register-from code">
|
|
- <input class="row-input" type="text" v-model="regEmailCode" placeholder="请输入上述手机号的验证码" maxlength="6"/>
|
|
|
|
|
|
+ <input class="row-input" type="text" v-model="mobileCode" placeholder="请输入上述手机号的验证码" maxlength="6"/>
|
|
</view>
|
|
</view>
|
|
- <view class="register-from btn" :class="[isDisabled ? 'disabled' : 'none']">
|
|
|
|
- <button class="row-input" type="button" @click.stop="getEmailCode" :disabled="isDisabled">获取验证码</button>
|
|
|
|
|
|
+ <view class="register-from btn" :class="[isMobileDisabled ? 'disabled' : '']" @click.stop="getMobileCodeFn">
|
|
|
|
+ <button class="row-input" type="button" :disabled="isMobileDisabled">{{ mobileCodeText }}</button>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
<view class="register-row clearfix" v-show="isShowCheckPhone">
|
|
<view class="register-row clearfix" v-show="isShowCheckPhone">
|
|
<view class="register-from">
|
|
<view class="register-from">
|
|
- <input class="row-input" type="number" v-model="registerEmail" placeholder="请输入新手机号" maxlength="11"/>
|
|
|
|
|
|
+ <input class="row-input" type="number" v-model="newMobile" placeholder="请输入新手机号" maxlength="11"/>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
<view class="register-row clearfix" v-show="isShowCheckPhone">
|
|
<view class="register-row clearfix" v-show="isShowCheckPhone">
|
|
<view class="register-from code">
|
|
<view class="register-from code">
|
|
- <input class="row-input" type="text" v-model="regEmailCode" placeholder="请输入新手机号的验证码" maxlength="6"/>
|
|
|
|
|
|
+ <input class="row-input" type="text" v-model="newMobileCode" placeholder="请输入新手机号的验证码" maxlength="6"/>
|
|
</view>
|
|
</view>
|
|
- <view class="register-from btn" :class="[isDisabled ? 'disabled' : 'none']">
|
|
|
|
- <button class="row-input" type="button" @click.stop="getEmailCode" :disabled="isDisabled">获取验证码</button>
|
|
|
|
|
|
+ <view class="register-from btn" :class="[isMobileDisabled ? 'disabled' : '']" @click.stop="getNewMobileCodeFn">
|
|
|
|
+ <button class="row-input" type="button" :disabled="isNewMobileDisabled">{{ newMobileCodeText }}</button>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
@@ -125,13 +125,15 @@
|
|
<view class="register-row clearfix">
|
|
<view class="register-row clearfix">
|
|
<view class="register-from picker">
|
|
<view class="register-from picker">
|
|
<view class="label">机构类型:</view>
|
|
<view class="label">机构类型:</view>
|
|
- <picker @change="bindPickerChange" :value="index" :range="organizationTypeList" range-key="name">
|
|
|
|
|
|
+ <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>
|
|
<view class="row-input" :class="[isOrganizationType == 0 ? 'none' : '']">{{organizationTypeList[typtIndex].name}}</view>
|
|
</picker>
|
|
</picker>
|
|
- <text class="iconfont icon-xiayibu"></text>
|
|
|
|
|
|
+ -->
|
|
</view>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
- <view class="register-row clearfix" v-if="isOrganizationType == 1">
|
|
|
|
|
|
+ <view class="register-row clearfix" v-if="isOrganizationType == 0">
|
|
<view class="register-from radio">
|
|
<view class="register-from radio">
|
|
<radio-group @change="radioChange">
|
|
<radio-group @change="radioChange">
|
|
<label class="row-input" v-for="(item, index) in beautyList" :key="item.value">
|
|
<label class="row-input" v-for="(item, index) in beautyList" :key="item.value">
|
|
@@ -147,7 +149,7 @@
|
|
<input class="row-input keshi" type="text" v-model="clubContact" placeholder="请填写经营的科室,至少三个,用逗号隔开" maxlength="16"/>
|
|
<input class="row-input keshi" type="text" v-model="clubContact" placeholder="请填写经营的科室,至少三个,用逗号隔开" maxlength="16"/>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
- <view class="register-row clearfix" v-if="isOrganizationType == 1">
|
|
|
|
|
|
+ <view class="register-row clearfix" v-if="isOrganizationType == 0">
|
|
<view class="register-picture">
|
|
<view class="register-picture">
|
|
<view class="label zz">医疗执业许可证:</view>
|
|
<view class="label zz">医疗执业许可证:</view>
|
|
<view class="upload-picture">
|
|
<view class="upload-picture">
|
|
@@ -161,7 +163,7 @@
|
|
</view>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
- <view class="register-row clearfix" v-if="isOrganizationType == 1">
|
|
|
|
|
|
+ <view class="register-row clearfix" v-if="isOrganizationType == 0">
|
|
<view class="register-from group">
|
|
<view class="register-from group">
|
|
<view class="label">主营内容:</view>
|
|
<view class="label">主营内容:</view>
|
|
<checkbox-group class="content-class" @change="chooseMaleLike" >
|
|
<checkbox-group class="content-class" @change="chooseMaleLike" >
|
|
@@ -180,7 +182,7 @@
|
|
</view>
|
|
</view>
|
|
<view class="register-from group btn" v-show="isShowAustomItem">
|
|
<view class="register-from group btn" v-show="isShowAustomItem">
|
|
<view class="content-class btn">
|
|
<view class="content-class btn">
|
|
- <input class="row-input" type="text" v-model="customItemValue" placeholder="请输入自定义项目" @blur="onBlurInput" maxlength="5"/>
|
|
|
|
|
|
+ <input class="row-input other" type="text" v-model="customItemValue" placeholder="请输入自定义项目" @blur="onBlurInput" maxlength="5"/>
|
|
<button type="default"
|
|
<button type="default"
|
|
class="confirm-btn"
|
|
class="confirm-btn"
|
|
:class="[isDisabled ? 'disabled' : 'none']"
|
|
:class="[isDisabled ? 'disabled' : 'none']"
|
|
@@ -190,7 +192,7 @@
|
|
</view>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
- <view class="register-row clearfix" v-if="isOrganizationType == 2">
|
|
|
|
|
|
+ <view class="register-row clearfix" v-if="isOrganizationType == 1">
|
|
<view class="register-from group">
|
|
<view class="register-from group">
|
|
<view class="label">主营内容:</view>
|
|
<view class="label">主营内容:</view>
|
|
<checkbox-group class="content-class" @change="chooseMaleLikes">
|
|
<checkbox-group class="content-class" @change="chooseMaleLikes">
|
|
@@ -209,7 +211,7 @@
|
|
</view>
|
|
</view>
|
|
<view class="register-from group btn" v-show="isShowAustomItem">
|
|
<view class="register-from group btn" v-show="isShowAustomItem">
|
|
<view class="content-class btn">
|
|
<view class="content-class btn">
|
|
- <input class="row-input" type="text" v-model="customItemValue" placeholder="请输入自定义项目" @blur="onBlurInput" maxlength="5"/>
|
|
|
|
|
|
+ <input class="row-input other" type="text" v-model="customItemValue" placeholder="请输入自定义项目" @blur="onBlurInput" maxlength="5"/>
|
|
<button type="default"
|
|
<button type="default"
|
|
class="confirm-btn"
|
|
class="confirm-btn"
|
|
:class="[isDisabled ? 'disabled' : 'none']"
|
|
:class="[isDisabled ? 'disabled' : 'none']"
|
|
@@ -222,13 +224,13 @@
|
|
<view class="register-row clearfix">
|
|
<view class="register-row clearfix">
|
|
<view class="register-from">
|
|
<view class="register-from">
|
|
<view class="label">固定电话:</view>
|
|
<view class="label">固定电话:</view>
|
|
- <input class="row-input" type="text" v-model="clubName" placeholder="请填写机构的固定电话" maxlength="15"/>
|
|
|
|
|
|
+ <input class="row-input" type="text" v-model="clubTelePhone" placeholder="请填写机构的固定电话" maxlength="15"/>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
<view class="register-row clearfix">
|
|
<view class="register-row clearfix">
|
|
<view class="register-from">
|
|
<view class="register-from">
|
|
<view class="label">传真:</view>
|
|
<view class="label">传真:</view>
|
|
- <input class="row-input" type="text" v-model="clubName" placeholder="请填写机构的传真" maxlength="15"/>
|
|
|
|
|
|
+ <input class="row-input" type="text" v-model="clubFax" placeholder="请填写机构的传真" maxlength="15"/>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
<view class="register-row text-textarea clearfix">
|
|
<view class="register-row text-textarea clearfix">
|
|
@@ -247,8 +249,11 @@
|
|
<view class="register-fiexd clearfix">
|
|
<view class="register-fiexd clearfix">
|
|
<view class="register-agree">
|
|
<view class="register-agree">
|
|
<view class="agree-text" @tap.stop="agreeCheck()">
|
|
<view class="agree-text" @tap.stop="agreeCheck()">
|
|
- <button class="checkbox iconfont" :class="[isCheck?'icon-gouxuan':'icon-weigouxuan']"></button>
|
|
|
|
- 我已阅读并同意<text>《机构协议》</text><text>《用户协议》</text>及<text>《隐私权政策》</text>
|
|
|
|
|
|
+ <button class="checkbox iconfont" :class="[isCheck ?'icon-gouxuan':'icon-weigouxuan']"></button>
|
|
|
|
+ 我已阅读并同意
|
|
|
|
+ <text @click.stop="this.$api.navigateTo('/pages/service/organagree')">《机构协议》</text>
|
|
|
|
+ <text @click.stop="this.$api.navigateTo('/pages/service/useragree')">《用户协议》</text>及
|
|
|
|
+ <text @click.stop="this.$api.navigateTo('/pages/service/privacyagree')">《隐私权政策》</text>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
<view class="register-row ">
|
|
<view class="register-row ">
|
|
@@ -268,35 +273,48 @@
|
|
<script>
|
|
<script>
|
|
import { mapMutations } from 'vuex';
|
|
import { mapMutations } from 'vuex';
|
|
import mpvueCityPicker from '@/components/mpvue-citypicker/mpvueCityPicker.vue'
|
|
import mpvueCityPicker from '@/components/mpvue-citypicker/mpvueCityPicker.vue'
|
|
- import uniTag from '@/components/uni-tag/uni-tag.vue';
|
|
|
|
- import authorize from '@/common/config/authorize.js'
|
|
|
|
- import configUrl from '@/common/config/config.js'
|
|
|
|
|
|
+ import { organizationRegister , organizationVerifyRegisterFirst ,organizationVerifyRegisterTwo } from "@/api/use.js"
|
|
|
|
+ import { getImageCode, getMobileCode, uploadFileImage } from "@/api/utils.js"
|
|
var self;
|
|
var self;
|
|
export default{
|
|
export default{
|
|
components:{
|
|
components:{
|
|
- uniTag,
|
|
|
|
mpvueCityPicker
|
|
mpvueCityPicker
|
|
},
|
|
},
|
|
data() {
|
|
data() {
|
|
return{
|
|
return{
|
|
- isOpenError:false,
|
|
|
|
- errorList:[
|
|
|
|
- {text:'图片模糊'},
|
|
|
|
- {text:'营业执照错误'},
|
|
|
|
- {text:'手机号码错误图片模糊图片模糊图片模糊图片模糊图片模糊图片模糊图片模糊图片模糊图片模糊图片模糊图片模糊'}
|
|
|
|
- ],
|
|
|
|
|
|
+ isShowCheckPhone:false, //是否显示修改手机
|
|
|
|
+ tabCurrentIndex:3,
|
|
|
|
+ isPreviewImage:false, //预览图片开关
|
|
|
|
+ isMobileDisabled: false, //手机验证码按钮控制
|
|
|
|
+ isNewMobileDisabled: false, //手机验证码按钮控制
|
|
|
|
+ count: '', //倒计时
|
|
|
|
+ codeTime: null,
|
|
|
|
+ clubName:'', //机构名称
|
|
|
|
+ abbreviation:'', //机构简称
|
|
|
|
+ clubContact:'', //联系人
|
|
|
|
+ mobile:'', //联系人手机号
|
|
|
|
+ newMobile:'', //新联系人手机号
|
|
|
|
+ mobileCode:'', //手机号验证码
|
|
|
|
+ newMobileCode:'', //新手机号手机验证码
|
|
|
|
+ mobileCodeText: '获取验证码',
|
|
|
|
+ newMobileCodeText: '获取验证码',
|
|
|
|
+ socialCreditCode:'', //统一社会信用代码
|
|
|
|
+ isAgreed:0, //是否勾选协议
|
|
isDisabled:true,
|
|
isDisabled:true,
|
|
isShowInput:false,
|
|
isShowInput:false,
|
|
- isCheck:true, //勾选协议
|
|
|
|
- uploadBusinessImage:'',
|
|
|
|
- uploadMentuzImage:'https://ss0.bdstatic.com/70cFuHSh_Q1YnxGkpoWK1HF6hhy/it/u=1431188283,1203112303&fm=26&gp=0.jpg',
|
|
|
|
- uploadMedicalImage:'https://ss0.bdstatic.com/70cFuHSh_Q1YnxGkpoWK1HF6hhy/it/u=1431188283,1203112303&fm=26&gp=0.jpg',
|
|
|
|
- isOrganizationType:0,
|
|
|
|
- organizationTypeList:[
|
|
|
|
- {name:'请选择机构类型',value:0},
|
|
|
|
- {name:'医美',value:1},
|
|
|
|
- {name:'生美',value:2}
|
|
|
|
- ],
|
|
|
|
|
|
+ isCheck:true, //是否勾选协议
|
|
|
|
+ uploadBusinessImage:'', //营业执照图片
|
|
|
|
+ uploadMentuzImage:'', //门头照图片
|
|
|
|
+ uploadMedicalImage:'', //资质照图片
|
|
|
|
+ department:'', //科室
|
|
|
|
+ isDepartment:false, //是否显示科室
|
|
|
|
+ secondClubType:'', //机构类型二级分类
|
|
|
|
+ mainpro:'', //主营内容
|
|
|
|
+ clubTelePhone:'', //固定电话
|
|
|
|
+ clubFax:'', //传真
|
|
|
|
+ companyPprofile:'', //公司简介
|
|
|
|
+ isOrganizationType:3,
|
|
|
|
+ organizationTypeText:'请选择机构类型',
|
|
beautyList:[{value:'1',name:'诊所'},{value:'2',name:'门诊'},{value:'3',name:'医院'}],
|
|
beautyList:[{value:'1',name:'诊所'},{value:'2',name:'门诊'},{value:'3',name:'医院'}],
|
|
mentuzCampList:[{value:'1',name:'整形'},{value:'2',name:'轻医美'},{value:'3',name:'皮肤科'}],
|
|
mentuzCampList:[{value:'1',name:'整形'},{value:'2',name:'轻医美'},{value:'3',name:'皮肤科'}],
|
|
medicaCampList:[
|
|
medicaCampList:[
|
|
@@ -312,85 +330,130 @@
|
|
typtIndex:0,
|
|
typtIndex:0,
|
|
organizationType:0,
|
|
organizationType:0,
|
|
current:0,
|
|
current:0,
|
|
- isShowCheckPhone:false,
|
|
|
|
- isDepartment:false, //是否显示科室
|
|
|
|
isShowAustomItem:false, //是否显示其他添加
|
|
isShowAustomItem:false, //是否显示其他添加
|
|
- customItemValue:'', //自定义项目
|
|
|
|
- isCompanyPprofile:true,
|
|
|
|
- invitationCode:'', //获取用户登录的邀请码
|
|
|
|
- isToast:false, //控制显示未输入邀请码提示
|
|
|
|
- isUserInfo:false, //控制显示授权弹窗
|
|
|
|
- nickName:'', //存储用户名
|
|
|
|
- userInfo:'', //存储微信用户授权信息
|
|
|
|
- isSuccess:false,
|
|
|
|
- toestText:'',
|
|
|
|
- telPhone:'',
|
|
|
|
- registerType:'', //跳转类型
|
|
|
|
- alertText:'',
|
|
|
|
- listType: '',
|
|
|
|
- listVal: '',
|
|
|
|
- detilType:'',
|
|
|
|
- id:'',//商品ID
|
|
|
|
|
|
+ customItemValue:'', //自定义项目
|
|
addressData:{
|
|
addressData:{
|
|
- addressID:'',
|
|
|
|
address:'请选择机构所在地区',
|
|
address:'请选择机构所在地区',
|
|
- userID: '', //用户id ,只在新增收货地址时传
|
|
|
|
- shouHuoRen: '', //收货人
|
|
|
|
- mobile:'', //收货人手机
|
|
|
|
townID:'', //区ID
|
|
townID:'', //区ID
|
|
|
|
+ cityID:'', //区ID
|
|
|
|
+ provinceID:'', //区ID
|
|
addressDetail: '', //地址
|
|
addressDetail: '', //地址
|
|
- defaultFlag:0, //是否默认收货地址(0 不是默认,1 默认)
|
|
|
|
},
|
|
},
|
|
- }
|
|
|
|
|
|
+ }
|
|
},
|
|
},
|
|
onLoad(option) {
|
|
onLoad(option) {
|
|
console.log(option)
|
|
console.log(option)
|
|
- self = this;
|
|
|
|
- self.registerType = option.type;
|
|
|
|
- self.id = option.id
|
|
|
|
- if(option.listType) {
|
|
|
|
- self.listType = option.listType;
|
|
|
|
- self.listVal = option.listVal;
|
|
|
|
- }
|
|
|
|
},
|
|
},
|
|
methods:{
|
|
methods:{
|
|
- ...mapMutations(['register']),
|
|
|
|
- goregister() {
|
|
|
|
- self.$api.get('/register/isEnabled',{userOrganizeID:self.userOrganizeID,invitationCode:self.invitationCode}, res => {
|
|
|
|
- if (res.code == "1") {
|
|
|
|
- //查看此微信用户是否已经授权过
|
|
|
|
- authorize.getSetting().then(res =>{
|
|
|
|
- // console.log('是否已授权',res);//0:为取消授权 1:为已授权 2:为未操作
|
|
|
|
- if(res == 2){
|
|
|
|
- self.isUserInfo = true
|
|
|
|
- }else{
|
|
|
|
- self.isUserInfo = false
|
|
|
|
- self.wxGetUserInfo()
|
|
|
|
- }
|
|
|
|
- })
|
|
|
|
- }else if(res.code =='0'){
|
|
|
|
- self.toestText ='请输入邀请码';
|
|
|
|
- self.alertText ='邀请码';
|
|
|
|
- self.telPhone = res.msg;
|
|
|
|
- self.isToast = true;
|
|
|
|
- }else if(res.code =='-2'){
|
|
|
|
- self.toestText ='邀请码已失效';
|
|
|
|
- self.alertText ='新邀请码';
|
|
|
|
- self.telPhone = res.msg;
|
|
|
|
- self.isToast = true;
|
|
|
|
- }else if(res.code =='-3'){
|
|
|
|
- self.toestText ='邀请码已被使用';
|
|
|
|
- self.alertText ='新邀请码';
|
|
|
|
- self.telPhone = res.msg;
|
|
|
|
- self.isToast = true;
|
|
|
|
- }else{
|
|
|
|
- uni.showToast({icon:'none', title: res.msg, duration: 3000});
|
|
|
|
- self.isUserInfo = false
|
|
|
|
- }
|
|
|
|
|
|
+ registerStepsTwo(){
|
|
|
|
+ let params ={
|
|
|
|
+ name:this.clubName,
|
|
|
|
+ linkMan:this.clubContact,
|
|
|
|
+ bindMobile:this.registerMobile,
|
|
|
|
+ activationCode:this.mobileCode,
|
|
|
|
+ whichStep:2,
|
|
|
|
+ }
|
|
|
|
+ organizationVerifyRegisterTwo(params).then(res =>{
|
|
|
|
+ console.log(res)
|
|
|
|
+ this.tabCurrentIndex = 3
|
|
|
|
+ }).catch(res =>{
|
|
|
|
+ this.$util.msg(res.msg,2000);
|
|
|
|
+ })
|
|
|
|
+ },
|
|
|
|
+ registerStepsSub(){
|
|
|
|
+ let params ={
|
|
|
|
+ name:this.clubName,
|
|
|
|
+ linkMan:this.clubContact,
|
|
|
|
+ bindMobile:this.registerMobile,
|
|
|
|
+ activationCode:this.mobileCode,
|
|
|
|
+ sname:this.abbreviation,
|
|
|
|
+ provinceID:this.addressData.provinceID,
|
|
|
|
+ cityID:this.addressData.cityID,
|
|
|
|
+ townID:this.addressData.townID,
|
|
|
|
+ address:this.addressData.addressDetail,
|
|
|
|
+ socialCreditCode:this.socialCreditCode,
|
|
|
|
+ businessLicenseImage:this.uploadBusinessImage,
|
|
|
|
+ headpic:this.uploadMentuzImage,
|
|
|
|
+ firstClubType:this.isOrganizationType, //机构类型分类 医美:0和生美:1
|
|
|
|
+ secondClubType:this.secondClubType, //机构类型二级分类 诊所:1,门诊:2,医院:3
|
|
|
|
+ department:this.department, //科室
|
|
|
|
+ medicalPracticeLicenseImg:this.uploadMedicalImage,//资质图片
|
|
|
|
+ isAgreed:this.isAgreed, //是否勾选协议
|
|
|
|
+ mainpro:this.mainpro,
|
|
|
|
+ whichStep:3
|
|
|
|
+ }
|
|
|
|
+ organizationRegister(params).then(res =>{
|
|
|
|
+ this.$util.msg('您的机构账号已提交审核',2000);
|
|
|
|
+ this.$api.switchTabTo('/pages/tabBar/home/home')
|
|
|
|
+ }).catch(res =>{
|
|
|
|
+ this.$util.msg(res.msg,2000);
|
|
})
|
|
})
|
|
},
|
|
},
|
|
- showOpenError(){
|
|
|
|
- this.isOpenError = !this.isOpenError
|
|
|
|
|
|
+ getMobileCodeFn(){
|
|
|
|
+ let params = {
|
|
|
|
+ mobile:this.registerMobile,
|
|
|
|
+ activateCodeType:2,
|
|
|
|
+ platformType:2,
|
|
|
|
+ imgCode:this.imageCode,
|
|
|
|
+ token:this.imageCodetoken,
|
|
|
|
+ }
|
|
|
|
+ getMobileCode(params).then(res =>{
|
|
|
|
+ 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( res =>{
|
|
|
|
+ this.$util.msg(res.msg,2000);
|
|
|
|
+ })
|
|
|
|
+ },
|
|
|
|
+ getNewMobileCodeFn(){
|
|
|
|
+ let params = {
|
|
|
|
+ mobile:this.registerMobile,
|
|
|
|
+ activateCodeType:2,
|
|
|
|
+ platformType:2,
|
|
|
|
+ imgCode:this.imageCode,
|
|
|
|
+ token:this.imageCodetoken,
|
|
|
|
+ }
|
|
|
|
+ getMobileCode(params).then(res =>{
|
|
|
|
+ this.$util.msg('验证短信已发送',2000);
|
|
|
|
+ const TIME_COUNT = 60;
|
|
|
|
+ if (!this.codeTime) {
|
|
|
|
+ this.count = TIME_COUNT;
|
|
|
|
+ this.isNewMobileDisabled = true;
|
|
|
|
+ this.codeTime = setInterval(() => {
|
|
|
|
+ if (this.count > 1 && this.count <= TIME_COUNT) {
|
|
|
|
+ this.count--
|
|
|
|
+ this.newMobileCodeText = this.count +'s重新发送'
|
|
|
|
+ } else {
|
|
|
|
+ this.isNewMobileDisabled = false;
|
|
|
|
+ clearInterval(this.codeTime)
|
|
|
|
+ this.codeTime = null
|
|
|
|
+ this.newMobileCodeText = '获取验证码'
|
|
|
|
+ }
|
|
|
|
+ },1000)
|
|
|
|
+ }
|
|
|
|
+ }).catch( res =>{
|
|
|
|
+ this.$util.msg(res.msg,2000);
|
|
|
|
+ })
|
|
|
|
+ },
|
|
|
|
+ getVerificationCode(){//图形验证
|
|
|
|
+ getImageCode().then(res => {
|
|
|
|
+ this.imageCodeUrl = res.data.baseImage
|
|
|
|
+ this.imageCodetoken = res.data.token
|
|
|
|
+ })
|
|
},
|
|
},
|
|
// 三级联动选择
|
|
// 三级联动选择
|
|
showMulLinkageThreePicker() {
|
|
showMulLinkageThreePicker() {
|
|
@@ -398,182 +461,129 @@
|
|
this.$refs.mpvueCityPicker.show()
|
|
this.$refs.mpvueCityPicker.show()
|
|
},
|
|
},
|
|
onConfirm(e) {
|
|
onConfirm(e) {
|
|
- // console.log('地址',e);
|
|
|
|
|
|
+ console.log('地址',e);
|
|
this.addressData.address = e.name;
|
|
this.addressData.address = e.name;
|
|
- this.addressData.townID = e.cityCode;
|
|
|
|
|
|
+ this.addressData.townID = e.townCode;
|
|
|
|
+ this.addressData.cityID = e.cityCode;
|
|
|
|
+ this.addressData.provinceID = e.provinceCode;
|
|
},
|
|
},
|
|
- bindPickerChange(e) {
|
|
|
|
- console.log('picker发送选择改变,携带值为:' + e.target.value)
|
|
|
|
- this.current=0
|
|
|
|
- this.isDepartment = false
|
|
|
|
- this.typtIndex = e.target.value
|
|
|
|
- this.isOrganizationType = e.target.value
|
|
|
|
- },
|
|
|
|
- radioChange(e) {
|
|
|
|
- let _value = e.target.value
|
|
|
|
- if( _value == '2' || _value == '3'){
|
|
|
|
- this.isDepartment = true
|
|
|
|
- }else{
|
|
|
|
- this.isDepartment = false
|
|
|
|
- }
|
|
|
|
- for (let i = 0; i < this.beautyList.length; i++) {
|
|
|
|
- if (this.beautyList[i].value === _value) {
|
|
|
|
- this.current = i;
|
|
|
|
- break;
|
|
|
|
- }
|
|
|
|
- }
|
|
|
|
- },
|
|
|
|
- chooseMaleLike(e){
|
|
|
|
- let items = this.mentuzCampList
|
|
|
|
- let values = e.detail.value
|
|
|
|
- for (var i = 0, lenI = items.length; i < lenI; ++i) {
|
|
|
|
- const item = items[i]
|
|
|
|
- if(values.indexOf(item.value) >= 0){
|
|
|
|
- this.$set(item,'checked',true)
|
|
|
|
- }else{
|
|
|
|
- this.$set(item,'checked',false)
|
|
|
|
- }
|
|
|
|
- }
|
|
|
|
- },
|
|
|
|
- chooseMaleLikes(e){
|
|
|
|
- let items = this.medicaCampList
|
|
|
|
- let values = e.detail.value
|
|
|
|
- for (var i = 0, lenI = items.length; i < lenI; ++i) {
|
|
|
|
- const item = items[i]
|
|
|
|
- if(values.indexOf(item.value) >= 0){
|
|
|
|
- this.$set(item,'checked',true)
|
|
|
|
- }else{
|
|
|
|
- this.$set(item,'checked',false)
|
|
|
|
- }
|
|
|
|
- }
|
|
|
|
- },
|
|
|
|
onTextareaInput(e){
|
|
onTextareaInput(e){
|
|
this.addressData.addressDetail = e.detail.value;
|
|
this.addressData.addressDetail = e.detail.value;
|
|
- // console.log(this.addressData.addressDetail)
|
|
|
|
},
|
|
},
|
|
- chooseBusinessImage() {
|
|
|
|
- let self = this;
|
|
|
|
- uni.chooseImage({
|
|
|
|
- count: 1, //默认1
|
|
|
|
- sizeType: ['compressed'], //可以指定是原图还是压缩图,默认二者都有
|
|
|
|
- sourceType: ['album','camera'], //从相册选择
|
|
|
|
- success: (res) => {
|
|
|
|
- const tempFilePaths = res.tempFilePaths;
|
|
|
|
- const uploadTask = uni.uploadFile({
|
|
|
|
- url : 'https://mall-b.caimei365.com/formData/MultiPictareaddData',
|
|
|
|
- filePath: tempFilePaths[0],
|
|
|
|
- name: 'file',
|
|
|
|
- formData: {
|
|
|
|
- 'user': 'test'
|
|
|
|
- },
|
|
|
|
- success: function (data) {
|
|
|
|
- console.log(data.data);
|
|
|
|
- self.uploadBusinessImage = res.tempFilePaths
|
|
|
|
- },
|
|
|
|
- error : function(e){
|
|
|
|
- console.log(e);
|
|
|
|
- }
|
|
|
|
- })
|
|
|
|
- },
|
|
|
|
-
|
|
|
|
|
|
+ chooseBusinessImage() {//营业执照图片上传
|
|
|
|
+ uploadFileImage().then(res =>{
|
|
|
|
+ this.uploadBusinessImage = JSON.parse(res.data).data
|
|
})
|
|
})
|
|
},
|
|
},
|
|
- chooseMentuzImage() {
|
|
|
|
- let self = this;
|
|
|
|
- uni.chooseImage({
|
|
|
|
- count: 1, //默认1
|
|
|
|
- sizeType: ['compressed'], //可以指定是原图还是压缩图,默认二者都有
|
|
|
|
- sourceType: ['album','camera'], //从相册选择
|
|
|
|
- success: (res) => {
|
|
|
|
- const tempFilePaths = res.tempFilePaths;
|
|
|
|
- const uploadTask = uni.uploadFile({
|
|
|
|
- url : 'https://mall-b.caimei365.com/formData/MultiPictareaddData',
|
|
|
|
- filePath: tempFilePaths[0],
|
|
|
|
- name: 'file',
|
|
|
|
- formData: {
|
|
|
|
- 'user': 'test'
|
|
|
|
- },
|
|
|
|
- success: function (res) {
|
|
|
|
- console.log(res.data);
|
|
|
|
- self.uploadMentuzImage = res.data
|
|
|
|
- },
|
|
|
|
- error : function(e){
|
|
|
|
- console.log(e);
|
|
|
|
- }
|
|
|
|
- })
|
|
|
|
- }
|
|
|
|
- });
|
|
|
|
- },
|
|
|
|
- chooseMedicalImage() {
|
|
|
|
- let self = this;
|
|
|
|
- uni.chooseImage({
|
|
|
|
- count: 1, //默认1
|
|
|
|
- sizeType: ['compressed'], //可以指定是原图还是压缩图,默认二者都有
|
|
|
|
- sourceType: ['album','camera'], //从相册选择
|
|
|
|
- success: (res) => {
|
|
|
|
- const tempFilePaths = res.tempFilePaths;
|
|
|
|
- const uploadTask = uni.uploadFile({
|
|
|
|
- url : 'https://mall-b.caimei365.com/formData/MultiPictareaddData',
|
|
|
|
- filePath: tempFilePaths[0],
|
|
|
|
- name: 'file',
|
|
|
|
- formData: {
|
|
|
|
- 'user': 'test'
|
|
|
|
- },
|
|
|
|
- success: function (res) {
|
|
|
|
- console.log(res.data);
|
|
|
|
- self.uploadMedicalImage = res.data
|
|
|
|
- },
|
|
|
|
- error : function(e){
|
|
|
|
- console.log(e);
|
|
|
|
- }
|
|
|
|
- })
|
|
|
|
- }
|
|
|
|
- });
|
|
|
|
|
|
+ chooseMentuzImage() {//门头照图片上传
|
|
|
|
+ uploadFileImage().then(res =>{
|
|
|
|
+ this.uploadMentuzImage = JSON.parse(res.data).data
|
|
|
|
+ })
|
|
},
|
|
},
|
|
- viewMentuzImage(e) {
|
|
|
|
- let self = this
|
|
|
|
- let mentuzArray = []
|
|
|
|
- mentuzArray.push(self.uploadMentuzImage)
|
|
|
|
- uni.previewImage({
|
|
|
|
- urls: mentuzArray,
|
|
|
|
- current: 0
|
|
|
|
- });
|
|
|
|
|
|
+ chooseMedicalImage() {//资质照图片上传
|
|
|
|
+ uploadFileImage().then(res =>{
|
|
|
|
+ this.uploadMedicalImage = JSON.parse(res.data).data
|
|
|
|
+ })
|
|
},
|
|
},
|
|
viewBusinessImage(e) {
|
|
viewBusinessImage(e) {
|
|
- let self = this
|
|
|
|
- let businessArray = []
|
|
|
|
- businessArray.push(self.uploadBusinessImage)
|
|
|
|
- uni.previewImage({
|
|
|
|
- urls: businessArray,
|
|
|
|
- current: 0
|
|
|
|
- });
|
|
|
|
|
|
+ this.myPreviewImageFn(this.uploadBusinessImage)
|
|
|
|
+ },
|
|
|
|
+ viewMentuzImage(e) {
|
|
|
|
+ this.myPreviewImageFn(this.uploadMentuzImage)
|
|
},
|
|
},
|
|
viewMedicalImage(e) {
|
|
viewMedicalImage(e) {
|
|
- let self = this
|
|
|
|
- let medicalArray = []
|
|
|
|
- medicalArray.push(self.uploadMedicalImage)
|
|
|
|
|
|
+ this.myPreviewImageFn(this.uploadMedicalImage)
|
|
|
|
+ },
|
|
|
|
+ myPreviewImageFn(url){
|
|
|
|
+ this.isPreviewImage = true
|
|
|
|
+ let mentuzArray = []
|
|
|
|
+ mentuzArray.push(url)
|
|
uni.previewImage({
|
|
uni.previewImage({
|
|
- urls: self.medicalArray,
|
|
|
|
|
|
+ urls: mentuzArray,
|
|
current: 0
|
|
current: 0
|
|
});
|
|
});
|
|
},
|
|
},
|
|
delBusinessImage(){
|
|
delBusinessImage(){
|
|
- this.$util.modal('提示','确定删除营业执照图片吗?',true,() =>{
|
|
|
|
|
|
+ this.$util.modal('','确定删除营业执照图片吗?','确定','取消',true,() =>{
|
|
this.uploadBusinessImage = ''
|
|
this.uploadBusinessImage = ''
|
|
})
|
|
})
|
|
},
|
|
},
|
|
delMentuzImage(){
|
|
delMentuzImage(){
|
|
- this.$util.modal('提示','确定删除门头照图片吗?',true,() =>{
|
|
|
|
|
|
+ this.$util.modal('','确定删除门头照图片吗?','确定','取消',true,() =>{
|
|
this.uploadMentuzImage = ''
|
|
this.uploadMentuzImage = ''
|
|
})
|
|
})
|
|
},
|
|
},
|
|
delMedicalImage(){
|
|
delMedicalImage(){
|
|
- this.$util.modal('提示','确定删除资质图片吗?',true,() =>{
|
|
|
|
|
|
+ this.$util.modal('','确定删除资质图片吗?','确定','取消',true,() =>{
|
|
this.uploadMedicalImage = ''
|
|
this.uploadMedicalImage = ''
|
|
})
|
|
})
|
|
},
|
|
},
|
|
|
|
+ bindPickerChange() {
|
|
|
|
+ let self = this
|
|
|
|
+ uni.showActionSheet({
|
|
|
|
+ title:'标题',
|
|
|
|
+ itemList: ['医美', '生美'],
|
|
|
|
+ success: (e) => {
|
|
|
|
+ self.isOrganizationType = e.tapIndex
|
|
|
|
+ switch(e.tapIndex){
|
|
|
|
+ case 0:
|
|
|
|
+ this.organizationTypeText = '医美'
|
|
|
|
+ break;
|
|
|
|
+ case 1:
|
|
|
|
+ this.organizationTypeText = '生美'
|
|
|
|
+ break;
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ })
|
|
|
|
+
|
|
|
|
+ },
|
|
|
|
+ bindPickerChange2(e) {
|
|
|
|
+ console.log('picker携带值为:' + e.target.value)
|
|
|
|
+ this.typtIndex = e.target.value
|
|
|
|
+ this.isOrganizationType = e.target.value
|
|
|
|
+ },
|
|
|
|
+ radioChange(e) {
|
|
|
|
+ this.secondClubType = e.target.value;
|
|
|
|
+ if( this.secondClubType == '2' || this.secondClubType == '3'){
|
|
|
|
+ this.isDepartment = true
|
|
|
|
+ }else{
|
|
|
|
+ this.isDepartment = false
|
|
|
|
+ }
|
|
|
|
+ for (let i = 0; i < this.beautyList.length; i++) {
|
|
|
|
+ if (this.beautyList[i].value === this.secondClubType) {
|
|
|
|
+ this.current = i;
|
|
|
|
+ break;
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ },
|
|
|
|
+ chooseMaleLike(e){
|
|
|
|
+ this.mainpro = this.checkLikes(e,this.mentuzCampList)
|
|
|
|
+ console.log(this.mainpro)
|
|
|
|
+ },
|
|
|
|
+ chooseMaleLikes(e){
|
|
|
|
+ this.mainpro = this.checkLikes(e,this.medicaCampList)
|
|
|
|
+ console.log(this.mainpro)
|
|
|
|
+ },
|
|
|
|
+ checkLikes(e,list){
|
|
|
|
+ let items = list
|
|
|
|
+ let values = e.detail.value
|
|
|
|
+ let arr = []
|
|
|
|
+ for (let i = 0, lenI = items.length; i < lenI; ++i) {
|
|
|
|
+ const item = items[i]
|
|
|
|
+ if(values.indexOf(item.value) >= 0){
|
|
|
|
+ this.$set(item,'checked',true)
|
|
|
|
+ arr.push(item.name)
|
|
|
|
+ }else{
|
|
|
|
+ this.$set(item,'checked',false)
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ return arr.toString()
|
|
|
|
+ },
|
|
agreeCheck() {
|
|
agreeCheck() {
|
|
this.isCheck = !this.isCheck
|
|
this.isCheck = !this.isCheck
|
|
|
|
+ if(this.isCheck){
|
|
|
|
+ this.isAgreed = 1
|
|
|
|
+ }
|
|
},
|
|
},
|
|
onBlurInput(e){//
|
|
onBlurInput(e){//
|
|
if(e.detail.value ===''){
|
|
if(e.detail.value ===''){
|
|
@@ -582,14 +592,11 @@
|
|
this.isDisabled = false
|
|
this.isDisabled = false
|
|
}
|
|
}
|
|
},
|
|
},
|
|
- getEmailCode(){
|
|
|
|
- this.isDisabled = true
|
|
|
|
- },
|
|
|
|
showAustomItem() {
|
|
showAustomItem() {
|
|
this.isShowAustomItem = !this.isShowAustomItem
|
|
this.isShowAustomItem = !this.isShowAustomItem
|
|
},
|
|
},
|
|
addCustomItem(){
|
|
addCustomItem(){
|
|
- if(this.isOrganizationType == 1){
|
|
|
|
|
|
+ if(this.isOrganizationType == 0){
|
|
let item = {value:`${this.mentuzCampList.length+1}`,name:this.customItemValue}
|
|
let item = {value:`${this.mentuzCampList.length+1}`,name:this.customItemValue}
|
|
this.mentuzCampList.push(item)
|
|
this.mentuzCampList.push(item)
|
|
}else{
|
|
}else{
|
|
@@ -597,11 +604,18 @@
|
|
this.medicaCampList.push(item)
|
|
this.medicaCampList.push(item)
|
|
}
|
|
}
|
|
},
|
|
},
|
|
- showTextarea() {
|
|
|
|
- this.isCompanyPprofile = false
|
|
|
|
- },
|
|
|
|
- showCheckPhone(){
|
|
|
|
|
|
+ showCheckPhone(){//控制修改手机显隐
|
|
this.isShowCheckPhone = !this.isShowCheckPhone
|
|
this.isShowCheckPhone = !this.isShowCheckPhone
|
|
|
|
+ },
|
|
|
|
+ steps(index) {//$attrstab切换
|
|
|
|
+ console.log(index)
|
|
|
|
+ this.tabCurrentIndex = index;
|
|
|
|
+ }
|
|
|
|
+ },
|
|
|
|
+ onShow() {
|
|
|
|
+ if(this.isPreviewImage){
|
|
|
|
+ this.isPreviewImage = false
|
|
|
|
+ return
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
@@ -689,6 +703,10 @@
|
|
&.none{
|
|
&.none{
|
|
color: #999999;
|
|
color: #999999;
|
|
}
|
|
}
|
|
|
|
+ &.picker{
|
|
|
|
+ text-align: left;
|
|
|
|
+ color: #999999;
|
|
|
|
+ }
|
|
&.keshi{
|
|
&.keshi{
|
|
width: 550rpx;
|
|
width: 550rpx;
|
|
}
|
|
}
|
|
@@ -704,17 +722,20 @@
|
|
&.btn{
|
|
&.btn{
|
|
width: 176rpx;
|
|
width: 176rpx;
|
|
float: left;
|
|
float: left;
|
|
|
|
+ background: $btn-confirm;
|
|
.row-input{
|
|
.row-input{
|
|
width: 176rpx;
|
|
width: 176rpx;
|
|
padding: 0;
|
|
padding: 0;
|
|
- background: #F7F7F7;
|
|
|
|
- text-align: center;
|
|
|
|
- }
|
|
|
|
- &.none{
|
|
|
|
|
|
+ color: #FFFFFF;
|
|
background: $btn-confirm;
|
|
background: $btn-confirm;
|
|
- .row-input{
|
|
|
|
- color: #FFFFFF;
|
|
|
|
- background: $btn-confirm;
|
|
|
|
|
|
+ text-align: center;
|
|
|
|
+ &.other{
|
|
|
|
+ width: 240rpx;
|
|
|
|
+ background: #F7F7F7;
|
|
|
|
+ margin-right: 20rpx;
|
|
|
|
+ }
|
|
|
|
+ &.none{
|
|
|
|
+ background: #F7F7F7;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
&.disabled{
|
|
&.disabled{
|
|
@@ -750,6 +771,7 @@
|
|
}
|
|
}
|
|
.row-radio{
|
|
.row-radio{
|
|
float: left;
|
|
float: left;
|
|
|
|
+ transform: scale(0.8);
|
|
}
|
|
}
|
|
.row-text{
|
|
.row-text{
|
|
width: 100rpx;
|
|
width: 100rpx;
|