register-supplier.vue 31 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138
  1. <template>
  2. <view class="container register" :style="{paddingTop:CustomBar+'px'}" v-if="isWxAuthorize">
  3. <cu-custom :navbar-data='nvabarData' @navigateBack="hanldNavigateBack"></cu-custom>
  4. <view class="register-step">
  5. <view class="step-item" :class="stepIndex == 0 ? 'active' : ''">
  6. <text class="step-num">1</text><text>账户信息</text>
  7. <text class="line"></text>
  8. </view>
  9. <view class="step-item" :class="stepIndex == 1 ? 'active' : ''">
  10. <text class="step-num">2</text><text>基本信息</text>
  11. <text class="line"></text>
  12. </view>
  13. <view class="step-item" :class="stepIndex == 2 ? 'active' : ''">
  14. <text class="step-num">3</text><text>详细信息</text>
  15. </view>
  16. </view>
  17. <view class="register-main clearfix" v-if="stepIndex === 0">
  18. <view class="register-row clearfix">
  19. <view class="register-from">
  20. <view class="label">手机号:</view>
  21. <input class="row-input" type="number" name="input" v-model="firstParmas.bindMobile" placeholder="请输入联系人常用手机号" maxlength="11"/>
  22. </view>
  23. </view>
  24. <view class="register-row clearfix">
  25. <view class="register-from">
  26. <input type="text"
  27. v-model="imageCode"
  28. maxlength="4"
  29. class="row-input imgCode"
  30. placeholder="请输入右侧图形验证码"
  31. />
  32. <view class="vscodeimg">
  33. <image :src="imageCodeUrl" mode=""></image>
  34. </view>
  35. <view class="vscod-refresh" @click.stop="getVerificationCode">
  36. <text class="iconfont icon-shuaxin"></text>
  37. <text class="ref-text">刷新</text>
  38. </view>
  39. </view>
  40. </view>
  41. <view class="register-row clearfix">
  42. <view class="register-from">
  43. <view class="label">短信验证码:</view>
  44. <input class="row-input code" type="text" v-model="firstParmas.mobileCode" placeholder="请输入短信验证码" maxlength="6"/>
  45. <view class="row-btn" :class="[isMobileDisabled ? 'disabled' : '']">
  46. <button class="row-input"
  47. type="button"
  48. @click.stop="getMobileCodeFn"
  49. :disabled="isMobileDisabled">
  50. {{ mobileCodeText }}
  51. </button>
  52. </view>
  53. </view>
  54. </view>
  55. <view class="register-row clearfix">
  56. <view class="register-from">
  57. <view class="label">登录密码:</view>
  58. <input class="row-input" type="password" name="input" v-model="firstParmas.password" placeholder="密码必须为8-16位字母数字组合" maxlength="16"/>
  59. </view>
  60. </view>
  61. <view class="register-row clearfix">
  62. <view class="register-from">
  63. <view class="label">确认密码:</view>
  64. <input class="row-input" type="password" name="input" v-model="firstParmas.passWordConfirm" placeholder="请确认密码" maxlength="16"/>
  65. </view>
  66. </view>
  67. <view class="register-row ">
  68. <view class="register-btn" @click.stop="SupplierRegisteredFirst">下一步</view>
  69. </view>
  70. </view>
  71. <view class="register-main clearfix" v-if="stepIndex === 1">
  72. <view class="register-row clearfix">
  73. <view class="register-from">
  74. <view class="label">公司名称:</view>
  75. <input class="row-input" type="text" name="input" v-model="twoParmas.name" placeholder="请输入您的公司名称" maxlength="30"/>
  76. </view>
  77. </view>
  78. <view class="register-row clearfix">
  79. <view class="register-from">
  80. <view class="label">联系人:</view>
  81. <input class="row-input" type="text" name="input" v-model="twoParmas.linkMan" placeholder="请输入联系人姓名" maxlength="6"/>
  82. </view>
  83. </view>
  84. <view class="register-row none clearfix">
  85. <view class="register-from">
  86. <view class="label">邮箱:</view>
  87. <input class="row-input" type="text" name="input" v-model="twoParmas.email" placeholder="请输入邮箱地址" maxlength="30"/>
  88. </view>
  89. </view>
  90. <view class="register-row text clearfix">
  91. <text>邮箱可用作登录账号,请使用公司邮箱或法人邮箱</text>
  92. </view>
  93. <view class="register-row ">
  94. <view class="register-btn next" @click.stop="SupplierRegisteredTwo">下一步</view>
  95. <view class="register-btn prev" @click.stop="setStep(0)">上一步</view>
  96. </view>
  97. </view>
  98. <view class="register-main clearfix" v-if="stepIndex === 2">
  99. <view class="register-row clearfix">
  100. <view class="register-from">
  101. <view class="label">公司简称:</view>
  102. <input class="row-input" type="text" v-model="threeParmas.sname" placeholder="请输入您的公司简称" maxlength="10"/>
  103. </view>
  104. </view>
  105. <view class="register-row clearfix">
  106. <view class="register-from" @click="showMulLinkageThreePicker">
  107. <view class="label">联系地址:</view>
  108. <text class="row-input" :class="addressText === '请选择公司所在地区' ? 'none' : ''">
  109. {{ addressText }}
  110. </text>
  111. <text class="iconfont icon-xiayibu"></text>
  112. </view>
  113. </view>
  114. <view class="register-row text-textarea clearfix">
  115. <view class="textarea show" v-if="isShowInput" @click="showTextareaFocus">{{threeParmas.address ? threeParmas.address :'详细地址:如道路、门牌号、小区等'}}</view>
  116. <textarea v-else
  117. class="textarea"
  118. type="text"
  119. v-model="threeParmas.address"
  120. placeholder="详细地址:如道路、门牌号、小区等"
  121. placeholder-class="placeholder"
  122. maxlength="40"
  123. @input="onTextareaInput"
  124. :focus="textareaFocus"
  125. @blur="hideTextareaFocus"
  126. :class="isShowInput ? '':''"
  127. />
  128. </view>
  129. <view class="register-row clearfix">
  130. <view class="register-from">
  131. <view class="label">营业执照编号:</view>
  132. <input class="row-input" type="text" v-model="threeParmas.socialCreditCode" placeholder="请填写社会统一信用代码" maxlength="18"/>
  133. </view>
  134. </view>
  135. <view class="register-row clearfix">
  136. <view class="register-picture">
  137. <view class="label">营业执照:</view>
  138. <view class="upload-picture">
  139. <view class="upload-none" v-if="threeParmas.businessLicenseImage === ''" @click="chooseBusinessImage"><text class="iconfont icon-jiahao"></text></view>
  140. <view class="upload-image" v-else>
  141. <image :src="threeParmas.businessLicenseImage" mode="" @click="viewBusinessImage"></image>
  142. <view class="upload-del" @click="delBusinessImage">
  143. <text class='iconfont icon-shanchu1'></text>
  144. </view>
  145. </view>
  146. </view>
  147. </view>
  148. </view>
  149. <view class="register-row clearfix">
  150. <view class="register-from picker">
  151. <view class="label">公司类型:</view>
  152. <view class="row-input picker" @click="bindPickerChange">{{ organizationTypeText }}</view>
  153. <text class="iconfont icon-xiayibu"></text>
  154. </view>
  155. </view>
  156. <view class="register-row none clearfix" v-if="threeParmas.firstShopType == 1">
  157. <view class="register-from radio">
  158. <view class="label">医疗类型:</view>
  159. </view>
  160. </view>
  161. <view class="register-row clearfix" v-if="threeParmas.firstShopType == 1">
  162. <view class="register-from radio">
  163. <radio-group @change="radioChange">
  164. <label class="row-input" v-for="(item, index) in supplierList" :key="item.value">
  165. <radio class="row-radio" :value="item.value" :checked="index === current" color="#E15616"/>
  166. <view class="row-text">{{item.name}}</view>
  167. </label>
  168. </radio-group>
  169. </view>
  170. </view>
  171. <view class="register-row clearfix" v-if="threeParmas.firstShopType != 0">
  172. <view class="register-from group">
  173. <view class="label">主营内容:</view>
  174. <view class="content-class">
  175. <checkbox-group @change="chooseMaleLike" >
  176. <label class="item" v-for="(item, index) in supplierMedicaCampList" :key="index" :class="{on: item.checked}">
  177. <checkbox :value="item.value"></checkbox>
  178. <text class="item-text">{{item.name}}</text>
  179. </label>
  180. </checkbox-group>
  181. </view>
  182. </view>
  183. <view class="register-from group btn">
  184. <view class="content-class btn">
  185. <view class="item" @click="showAustomItem">
  186. <text class="item-text">其他</text>
  187. </view>
  188. </view>
  189. </view>
  190. <view class="register-from group btn" v-show="isShowAustomItem">
  191. <view class="content-class btn">
  192. <input class="row-input other" type="text" v-model="customItemValue" placeholder="请输入自定义项目" @blur="onBlurInput" maxlength="5"/>
  193. <button type="default"
  194. class="confirm-btn"
  195. :class="[isDisabled === true ? 'disabled' : 'none']"
  196. :disabled="isDisabled"
  197. @click.stop="addCustomItem"
  198. >确认添加</button>
  199. </view>
  200. </view>
  201. </view>
  202. <view class="register-main clearfix">
  203. <view class="register-agree">
  204. <view class="agree-text" @tap.stop="agreeCheck()">
  205. <button class="checkbox iconfont" :class="[isCheck?'icon-gouxuan':'icon-weigouxuan']"></button>
  206. 我已阅读并同意
  207. <text @click.stop="this.$api.navigateTo('/pages/service/supplieragree')">《供应商协议》</text>
  208. <text @click.stop="this.$api.navigateTo('/pages/service/useragree')">《用户协议》</text>及
  209. <text @click.stop="this.$api.navigateTo('/pages/service/privacyagree')">《隐私权政策》</text>
  210. </view>
  211. </view>
  212. <view class="register-row ">
  213. <view class="register-btn sub" @click.stop="SupplierRegisteredThree">注册</view>
  214. <view class="register-btn prev" @click.stop="setStep(1)">上一步</view>
  215. </view>
  216. </view>
  217. </view>
  218. <mpvue-city-picker :themeColor="themeColor"
  219. ref="mpvueCityPicker"
  220. :pickerValueDefault="cityPickerValueDefault"
  221. @onCancel="onCancel"
  222. @onConfirm="onConfirm">
  223. </mpvue-city-picker>
  224. <supplier-alert v-if="isSupplierAlert"></supplier-alert>
  225. </view>
  226. </template>
  227. <script>
  228. import { mapState,mapMutations } from 'vuex';
  229. import authorize from '@/common/config/authorize.js'
  230. import wxLogin from "@/common/config/wxLogin.js"
  231. import mpvueCityPicker from '@/components/mpvue-citypicker/mpvueCityPicker.vue'
  232. import supplierAlert from '@/components/cm-module/modelAlert/supplierRegisreAlert.vue'
  233. import { supplierList,supplierMedicaCampNullList } from '@/common/json/data.json.js' //本地数据
  234. import { uploadFileImage } from "@/api/utils.js"
  235. export default{
  236. components:{
  237. mpvueCityPicker,
  238. supplierAlert
  239. },
  240. data() {
  241. return{
  242. nvabarData: {//顶部自定义导航
  243. showCapsule: 1, // 是否显示左上角图标 1表示显示 0表示不显示,
  244. showSearch: 0,
  245. title: '供应商注册', // 导航栏 中间的标题
  246. haveBack:true,
  247. textLeft:this.$store.state.isIphone
  248. },
  249. CustomBar:this.CustomBar,// 顶部导航栏高度
  250. isMobileDisabled: false, //手机验证码按钮控制
  251. mobilCount: '', //倒计时
  252. mobileCodeText: '获取验证码',
  253. mobilTime: null,
  254. imageCode:'', //图形验证码
  255. imageCodeUrl:'', //图形验证码图片
  256. imageCodetoken:'', //图形验证校验
  257. isAgreed:0, //是否勾选协议
  258. isCheck:false, //是否勾选协议
  259. userID:'', //公司userID
  260. clubID:'', //公司ID
  261. stepIndex:0,
  262. firstParmas:{
  263. bindMobile:'',
  264. mobileCode:'',
  265. password:'',
  266. passWordConfirm:'',
  267. whichStep:1
  268. },
  269. twoParmas:{
  270. linkMan:'',
  271. name:'',
  272. email:"",
  273. whichStep:2
  274. },
  275. threeParmas:{
  276. provinceID :'',
  277. cityID : '',
  278. townID : '',
  279. address:'',
  280. sname:'', //公司简称
  281. socialCreditCode:'', //统一社会信用代码
  282. businessLicenseImage:'', //营业执照图片
  283. provinceID :'',
  284. cityID : '',
  285. townID : '',
  286. address:'',
  287. firstShopType:0,
  288. secondShopType: '',
  289. mainpro:'',
  290. isAgreed:0,
  291. whichStep:3
  292. },
  293. addressText:'请选择公司所在地区',
  294. isDisabled:true,
  295. isShowInput:true,
  296. textareaFocus:false,
  297. organizationTypeText:'请选择公司类型',
  298. supplierList:supplierList,//医疗类型
  299. supplierMedicaCampList:supplierMedicaCampNullList,//主营内容
  300. typtIndex:0,
  301. organizationType:0,
  302. current:0,
  303. isShowAustomItem:false, //是否显示其他添加
  304. customItemValue:'', //自定义项目
  305. isMainproCheck:false,
  306. isSupplierAlert:true
  307. }
  308. },
  309. onLoad() {
  310. this.getVerificationCode();
  311. },
  312. computed:{
  313. ...mapState(['isWxAuthorize'])
  314. },
  315. methods:{
  316. ...mapMutations(['login']),
  317. hanldNavigateBack(){
  318. this.$util.modal('','注册尚未完成,确定放弃注册吗?','确定','取消',true,() =>{
  319. this.$api.switchTabTo('/pages/tabBar/home/index')
  320. })
  321. },
  322. // 三级联动选择
  323. showMulLinkageThreePicker() {
  324. this.isShowInput = true
  325. this.$refs.mpvueCityPicker.show()
  326. },
  327. getMobileCodeFn(){
  328. if( this.firstParmas.bindMobile == ''){
  329. this.$util.msg('请输入联系人常用手机号',2000);
  330. return
  331. }
  332. if(!this.$reg.isMobile(this.firstParmas.bindMobile)){
  333. this.$util.msg('请输入正确的手机号',2000);
  334. return
  335. }
  336. if( this.imageCode == ''){
  337. this.$util.msg('请输入图形验证码',2000);
  338. return
  339. }
  340. let params = {
  341. mobile:this.firstParmas.bindMobile,
  342. imgCode:this.imageCode,
  343. activateCodeType:3,
  344. platformType:2,
  345. token:this.imageCodetoken
  346. }
  347. this.isMobileDisabled = true;
  348. this.PublicService.GetMobileCode(params).then(response =>{
  349. this.$util.msg('验证短信已发送',2000);
  350. const TIME_COUNT = 60;
  351. if (!this.mobilTime) {
  352. this.mobilCount = TIME_COUNT;
  353. this.isMobileDisabled = true;
  354. this.mobilTime = setInterval(() => {
  355. if (this.mobilCount > 1 && this.mobilCount <= TIME_COUNT) {
  356. this.mobilCount--
  357. this.mobileCodeText = this.mobilCount +'s重新发送'
  358. } else {
  359. this.isMobileDisabled = false;
  360. clearInterval(this.mobilTime)
  361. this.mobilTime = null
  362. this.mobileCodeText = '获取验证码'
  363. }
  364. },1000)
  365. }
  366. }).catch( error =>{
  367. this.$util.msg(error.msg,2000);
  368. this.isMobileDisabled = false;
  369. })
  370. },
  371. bindPickerChange() {
  372. let self = this
  373. uni.showActionSheet({
  374. title:'标题',
  375. itemList: ['医疗', '非医疗'],
  376. success: (e) => {
  377. self.threeParmas.firstShopType = e.tapIndex+1
  378. switch(e.tapIndex){
  379. case 0:
  380. this.organizationTypeText = '医疗'
  381. break;
  382. case 1:
  383. this.organizationTypeText = '非医疗'
  384. break;
  385. }
  386. }
  387. })
  388. },
  389. setStep(index){
  390. this.stepIndex = index
  391. },
  392. SupplierRegisteredFirst(){//供应商注册第一步
  393. if( this.firstParmas.bindMobile == ''){
  394. this.$util.msg('请输入联系人常用手机号',2000);
  395. return
  396. }
  397. if(!this.$reg.isMobile(this.firstParmas.bindMobile)){
  398. this.$util.msg('请输入正确的手机号',2000);
  399. return
  400. }
  401. if( this.firstParmas.mobileCode == ''){
  402. this.$util.msg('请输入手机验证码',2000);
  403. return
  404. }
  405. if(!this.$reg.isMobileCode(this.firstParmas.mobileCode)){
  406. this.$util.msg('验证码格式不正确',2000);
  407. return
  408. }
  409. if(!this.$reg.checkPwd(this.firstParmas.password)){
  410. uni.showToast({title: '密码必须为8-16位字母数字的组合',duration: 2000,mask:true,icon:'none'})
  411. return
  412. }
  413. if( this.firstParmas.passWordConfirm == ''){
  414. uni.showToast({title: '请再次确认密码',duration: 2000,mask:true,icon:'none'})
  415. return
  416. }
  417. if( this.firstParmas.passWordConfirm !== this.firstParmas.password){
  418. uni.showToast({title: '两次输入的密码不一致',duration: 2000,mask:true,icon:'none'})
  419. return
  420. }
  421. this.ShopService.SupplierAppletsRegistered(this.firstParmas).then(response =>{
  422. this.stepIndex = 1
  423. }).catch(error =>{
  424. this.$util.msg(error.msg,2000);
  425. })
  426. },
  427. SupplierRegisteredTwo(){//供应商注册第二步
  428. if( this.twoParmas.name == ''){
  429. this.$util.msg('请输入您的公司名称',2000);
  430. return
  431. }
  432. if( this.twoParmas.linkMan == ''){
  433. this.$util.msg('请输入联系人名称',2000);
  434. return
  435. }
  436. if( this.twoParmas.email == ''){
  437. this.$util.msg('请输入邮箱地址',2000);
  438. return
  439. }
  440. if(!this.$reg.isEmail(this.twoParmas.email)){
  441. this.$util.msg('请输入正确的邮箱地址',2000);
  442. return
  443. }
  444. this.ShopService.SupplierAppletsRegistered(this.twoParmas).then(response =>{
  445. this.stepIndex = 2
  446. }).catch(error =>{
  447. this.$util.msg(error.msg,2000);
  448. })
  449. },
  450. SupplierRegisteredThree(){
  451. if( this.threeParmas.townID == ''){
  452. this.$util.msg('请选择公司地址',2000);
  453. return
  454. }
  455. if( this.threeParmas.address == ''){
  456. this.$util.msg('请填写公司详细地址',2000);
  457. return
  458. }
  459. if( this.threeParmas.socialCreditCode == ''){
  460. this.$util.msg('请填写统一社会信用代码',2000);
  461. return
  462. }
  463. if( !this.threeParmas.businessLicenseImage){
  464. this.$util.msg('请上传您的营业执照',2000);
  465. return
  466. }
  467. if(this.threeParmas.firstShopType == 0){
  468. this.$util.msg('请选择公司类型',2000);
  469. return
  470. }
  471. if(this.threeParmas.mainpro == ''){
  472. this.$util.msg('请选择主营内容',2000);
  473. return
  474. }
  475. if(this.threeParmas.isAgreed == 0){
  476. this.$util.msg('请勾选同意协议',2000);
  477. return
  478. }
  479. let postParmas = Object.assign(this.firstParmas,this.twoParmas,this.threeParmas);
  480. this.UserService.appSupplierRegister(postParmas).then(response =>{
  481. this.$util.modal('','您的资料已提交成功,系统将在1-2个工作日内进行审核~','知道了','',false,() =>{
  482. this.$api.switchTabTo('/pages/tabBar/home/index')
  483. })
  484. }).catch(error =>{
  485. this.$util.msg(error.msg,2000);
  486. })
  487. },
  488. chooseBusinessImage() {//营业执照图片上传
  489. uploadFileImage().then(res =>{
  490. this.threeParmas.businessLicenseImage = JSON.parse(res.data).data
  491. })
  492. },
  493. viewBusinessImage(e) {
  494. this.myPreviewImageFn(this.businessLicenseImage)
  495. },
  496. myPreviewImageFn(url){
  497. this.isPreviewImage = true
  498. let mentuzArray = []
  499. mentuzArray.push(url)
  500. uni.previewImage({
  501. urls: mentuzArray,
  502. current: 0
  503. });
  504. },
  505. delBusinessImage(){
  506. this.$util.modal('','确定删除营业执照图片吗?','确定','取消',true,() =>{
  507. this.threeParmas.businessLicenseImage = ''
  508. })
  509. },
  510. radioChange(e) {
  511. this.threeParmas.secondShopType = e.target.value;
  512. },
  513. chooseMaleLike(e){
  514. this.isMainproCheck = true
  515. this.threeParmas.mainpro = this.checkLikes(e,this.supplierMedicaCampList)
  516. },
  517. checkLikes(e,list){
  518. let values = e.detail.value
  519. let arr = []
  520. list.forEach(item => {
  521. if(values.indexOf(item.value) >= 0){
  522. this.$set(item,'checked',true)
  523. arr.push(item.name)
  524. }else{
  525. this.$set(item,'checked',false)
  526. }
  527. })
  528. return arr.join('/')
  529. },
  530. getVerificationCode(){//图形验证
  531. this.PublicService.GetImgVerifyCode().then(res => {
  532. this.imageCodeUrl = res.data.baseImage
  533. this.imageCodetoken = res.data.token
  534. })
  535. },
  536. showAustomItem() {
  537. this.isShowAustomItem = !this.isShowAustomItem
  538. },
  539. showTextareaFocus(){//文本框获取焦点
  540. this.isShowInput = false
  541. this.textareaFocus = true
  542. },
  543. hideTextareaFocus(){//文本框失去焦点
  544. this.isShowInput = true
  545. this.textareaFocus = false
  546. },
  547. onConfirm(e) {
  548. this.addressText = e.name;
  549. this.threeParmas.townID = e.townCode;
  550. this.threeParmas.cityID = e.cityCode;
  551. this.threeParmas.provinceID = e.provinceCode;
  552. },
  553. onTextareaInput(e){
  554. this.threeParmas.address = e.detail.value;
  555. },
  556. onBlurInput(e){//
  557. if(e.detail.value ===''){
  558. this.isDisabled = true
  559. }else{
  560. this.isDisabled = false
  561. }
  562. },
  563. addCustomItem(){//添加主营内容
  564. let item = {value:`${this.supplierMedicaCampList.length+1}`,name:this.customItemValue,checked:true}
  565. this.supplierMedicaCampList.push(item)
  566. },
  567. agreeCheck() {
  568. this.isCheck = !this.isCheck
  569. if(this.isCheck){
  570. this.threeParmas.isAgreed = 1
  571. }else{
  572. this.threeParmas.isAgreed = 0
  573. }
  574. }
  575. },
  576. onShow() {
  577. authorize.getSetting().then(wxResponse =>{// console.log('是否已授权',res);//0:为取消授权 1:为已授权 2:为未操作
  578. if(wxResponse == 1){
  579. wxLogin.wxLoginQuick()
  580. }else{
  581. this.$api.navigateTo('/pages/authorization/authorization?type=0')
  582. }
  583. })
  584. }
  585. }
  586. </script>
  587. <style lang="scss">
  588. .register{
  589. width: 100%;
  590. height: 100%;
  591. box-sizing: border-box;
  592. .register-step{
  593. margin:80rpx 0;
  594. width: 100%;
  595. height: 44rpx;
  596. box-sizing: border-box;
  597. padding: 0 90rpx;
  598. .step-item{
  599. line-height: 44rpx;
  600. color: #B2B2B2;
  601. font-size: $font-size-24;
  602. float: left;
  603. margin-right: 60rpx;
  604. position: relative;
  605. &.active{
  606. color: $color-system;
  607. .step-num{
  608. background-color: $color-system;
  609. }
  610. .line{
  611. background-color: $color-system;
  612. }
  613. }
  614. &:last-child{
  615. margin-right: 0;
  616. }
  617. .step-num{
  618. display: inline-block;
  619. width: 40rpx;
  620. height: 40rpx;
  621. border-radius: 50%;
  622. background-color:#e1e1e1;
  623. color: #FFFFFF;
  624. line-height: 40rpx;
  625. text-align: center;
  626. margin-right: 10rpx;
  627. }
  628. .line{
  629. width: 60rpx;
  630. height: 2rpx;
  631. background-color: #B2B2B2;
  632. position: absolute;
  633. right:-60rpx;
  634. top: 50%;
  635. }
  636. }
  637. }
  638. .register-main{
  639. width: 100%;
  640. height: auto;
  641. position: relative;
  642. .register-consult{
  643. width: 110rpx;
  644. height: 68rpx;
  645. background:linear-gradient(223deg,rgba(225,86,21,0.6) 0%,rgba(225,86,10,0.3) 100%);
  646. border-radius: 34rpx 0 0 34rpx;
  647. position: absolute;
  648. right: 0;
  649. bottom: 120rpx;
  650. text-align: left;
  651. line-height: 68rpx;
  652. padding-left: 20rpx;
  653. .icon-kefunv{
  654. font-size: 48rpx;
  655. color: #31313B;
  656. float: left;
  657. }
  658. .text{
  659. font-size: $font-size-24;
  660. display: block;
  661. float: left;
  662. width: 60rpx;
  663. line-height: 30rpx;
  664. color: #FFFFFF;
  665. margin-top: 6rpx;
  666. }
  667. }
  668. .register-agree{
  669. display: flex;
  670. flex-direction: column;
  671. align-items: center;
  672. margin: 100rpx 0 20rpx 0;
  673. .agree-text{
  674. .checkbox{
  675. float: left;
  676. margin: 4rpx 6rpx 0 0;
  677. color: #999999;
  678. font-size: $font-size-34;
  679. &.icon-gouxuan{
  680. color: $color-system;
  681. }
  682. }
  683. font-size: $font-size-22;
  684. line-height: 44rpx;
  685. color: #999999;
  686. text{
  687. color:#1890f9;
  688. }
  689. }
  690. }
  691. .register-logo{
  692. width: 100%;
  693. display: flex;
  694. flex-direction: column;
  695. align-items: center;
  696. height: 189rpx;
  697. padding:60rpx 0 40rpx 0;
  698. .logo{
  699. width:467rpx;
  700. height: 189rpx;
  701. display: block;
  702. }
  703. }
  704. &.detailed{
  705. padding-bottom: 330rpx;
  706. }
  707. .register-row{
  708. width: 100%;
  709. height: auto;
  710. padding: 0 24rpx;
  711. margin-bottom: 30rpx;
  712. box-sizing: border-box;
  713. &.text{
  714. font-size: $font-size-20;
  715. line-height: 40rpx;
  716. color: #fea785;
  717. }
  718. &.none{
  719. margin-bottom: 0;
  720. }
  721. &.login{
  722. display: flex;
  723. }
  724. .register-text{
  725. line-height: 44rpx;
  726. margin-top: 100rpx;
  727. font-size: $font-size-24;
  728. color: #999999;
  729. text-align: justify;
  730. .txt{
  731. margin-right: 15rpx;
  732. }
  733. }
  734. .register-title{
  735. line-height: 44rpx;
  736. font-size: $font-size-24;
  737. color: $text-color;
  738. text-align: left;
  739. &.first{
  740. margin-top: 20rpx;
  741. }
  742. }
  743. .register-tip{
  744. line-height: 64rpx;
  745. font-size: $font-size-24;
  746. color: #CECECE;
  747. text-align: left;
  748. }
  749. .register-from{
  750. width: 100%;
  751. height: 80rpx;
  752. background: #FFFFFF;
  753. position: relative;
  754. border-bottom: 1px solid #e1e1e1;
  755. .label{
  756. text-align: left;
  757. font-size: $font-size-28;
  758. color:#666666;
  759. line-height: 80rpx;
  760. float: left;
  761. }
  762. .row-input{
  763. width: 440rpx;
  764. padding-left:10rpx;
  765. font-size: $font-size-28;
  766. color: $text-color;
  767. line-height: 80rpx;
  768. float: left;
  769. height: 80rpx;
  770. &.none{
  771. color: #999999;
  772. }
  773. &.picker{
  774. text-align: left;
  775. color: #333333;
  776. }
  777. &.keshi{
  778. width: 550rpx;
  779. }
  780. &.code{
  781. width: 350rpx;
  782. }
  783. &.imgCode{
  784. width: 390rpx;
  785. }
  786. }
  787. .vscodeimg{
  788. width: 160rpx;
  789. height: 80;
  790. float: left;
  791. display: flex;
  792. flex-direction: column;
  793. align-items: center;
  794. border-radius: 6rpx;
  795. margin: 0 10rpx;
  796. image{
  797. width: 150rpx;
  798. height: 68rpx;
  799. border-radius: 6rpx;
  800. }
  801. }
  802. .vscod-refresh{
  803. width: 120rpx;
  804. float: right;
  805. line-height: 80rpx;
  806. .ref-text{
  807. float: left;
  808. font-size: 26rpx;
  809. color: #999999;
  810. }
  811. .icon-shuaxin{
  812. float: left;
  813. font-size: 36rpx;
  814. color: #999999;
  815. margin-right: 10rpx;
  816. }
  817. }
  818. &.imgcode{
  819. width: 410rpx;
  820. float: left;
  821. margin-right: 20rpx;
  822. .row-input{
  823. width: 230rpx;
  824. }
  825. }
  826. .row-btn{
  827. width: 180rpx;
  828. height:64rpx;
  829. float: left;
  830. background: $btn-confirm;
  831. padding: 0;
  832. border-radius: 32rpx;
  833. .row-input{
  834. width: 180rpx;
  835. height: 64rpx;
  836. line-height: 64rpx;
  837. padding: 0;
  838. color: #FFFFFF;
  839. background: $btn-confirm;
  840. text-align: center;
  841. border-radius: 32rpx;
  842. font-size: $font-size-24;
  843. &.other{
  844. width: 180rpx;
  845. background: #F7F7F7;
  846. margin-right: 20rpx;
  847. }
  848. &.none{
  849. background: #F7F7F7;
  850. }
  851. }
  852. &.disabled{
  853. background: #F7F7F7;
  854. .row-input{
  855. background: #F7F7F7;
  856. color: #999999;
  857. }
  858. }
  859. }
  860. &.picker{
  861. width: 100%;
  862. height: 80rpx;
  863. line-height: 80rpx;
  864. .label{
  865. line-height: 80rpx;
  866. }
  867. .row-input{
  868. width: 470rpx;
  869. height: 80rpx;
  870. line-height: 80rpx;
  871. padding-left: 30rpx;
  872. }
  873. }
  874. &.radio{
  875. width: 100%;
  876. border-bottom: none;
  877. .row-input{
  878. width: 25%;
  879. height: 80rpx;
  880. line-height: 80rpx;
  881. padding-left: 0;
  882. }
  883. .row-radio{
  884. float: left;
  885. transform: scale(0.8);
  886. }
  887. .row-text{
  888. text-align: center;
  889. float: left;
  890. font-size: $font-size-24;
  891. }
  892. }
  893. &.group{
  894. width: 100%;
  895. height: auto;
  896. background: #FFFFFF;
  897. margin-top: 30rpx;
  898. border-bottom: none;
  899. .label{
  900. line-height: 76rpx;
  901. }
  902. .row-input{
  903. width: 100%;
  904. height: 80rpx;
  905. line-height: 80rpx;
  906. padding-left: 0;
  907. }
  908. .row-radio{
  909. float: left;
  910. }
  911. .row-text{
  912. width: 100rpx;
  913. text-align: center;
  914. float: left;
  915. }
  916. }
  917. &.btn{
  918. margin-top: 0;
  919. }
  920. .content-class {
  921. margin: 20rpx auto;
  922. display: flex;
  923. flex-flow: row wrap;
  924. justify-content: space-between;
  925. align-items: center;
  926. &.btn{
  927. margin: 0 auto;
  928. margin-left: 116rpx;
  929. }
  930. .row-input{
  931. display: flex;
  932. width: 330rpx;
  933. box-sizing: border-box;
  934. height: 64rpx;
  935. padding:0 24rpx;
  936. text-align: left;
  937. border-radius: 32rpx;
  938. font-size: $font-size-28;
  939. color: $text-color;
  940. border: 1px solid #B2B2B2;
  941. line-height: 64rpx;
  942. }
  943. .confirm-btn{
  944. width: 200rpx;
  945. height: 64rpx;
  946. border-radius: 32rpx;
  947. line-height: 64rpx;
  948. text-align: center;
  949. &.other{
  950. width: 213rpx;
  951. }
  952. &.none{
  953. color: $color-system;
  954. background: #ffe6dc;
  955. }
  956. &.disabled{
  957. color: #999999;
  958. }
  959. }
  960. .item {
  961. width: 155rpx;
  962. height: 60rpx;
  963. font-size:$font-size-28;
  964. line-height: 60rpx;
  965. border-radius:30rpx;
  966. margin: 10rpx;
  967. text-align: center;
  968. box-sizing: border-box;
  969. border: 1rpx solid #EFEFEF;
  970. float: left;
  971. checkbox {
  972. display: none;
  973. }
  974. }
  975. .on {
  976. border-color: $color-system;
  977. color:$color-system;
  978. }
  979. }
  980. }
  981. .row-login{
  982. flex: 1;
  983. font-size: $font-size-28;
  984. color: $text-color;
  985. text-align: left;
  986. }
  987. .row-logincode{
  988. flex: 1;
  989. font-size: $font-size-28;
  990. color: $text-color;
  991. text-align: right;
  992. }
  993. .icon-xiayibu{
  994. width: 80rpx;
  995. height: 80rpx;
  996. position: absolute;
  997. right: 0;
  998. top: 0;
  999. line-height: 80rpx;
  1000. text-align: center;
  1001. }
  1002. &.text-textarea{
  1003. background: #FFFFFF;
  1004. .textarea{
  1005. width: 100%;
  1006. height: 180rpx;
  1007. padding: 24rpx;
  1008. box-sizing: border-box;
  1009. font-size: $font-size-28;
  1010. color: $text-color;
  1011. z-index: 1;
  1012. border-bottom: 1px solid #e1e1e1;
  1013. }
  1014. .textarea.hide{
  1015. opacity: 0;
  1016. }
  1017. .textarea.show{
  1018. color: #999999;
  1019. }
  1020. }
  1021. }
  1022. .register-picture{
  1023. height: 180rpx;
  1024. margin: 30rpx 0;
  1025. float: left;
  1026. &.zz{
  1027. width: 100%;
  1028. }
  1029. .label{
  1030. float: left;
  1031. font-size: $font-size-28;
  1032. color: #666666;
  1033. line-height: 180rpx;
  1034. width: 150rpx;
  1035. text-align: left;
  1036. }
  1037. .upload-picture{
  1038. float: left;
  1039. height: 180rpx;
  1040. .upload-none{
  1041. width: 180rpx;
  1042. height: 180rpx;
  1043. text-align: center;
  1044. line-height: 180rpx;
  1045. color: #999999;
  1046. border: 1px solid #999999;
  1047. border-radius: 10rpx;
  1048. margin: 0 20rpx;
  1049. .iconfont{
  1050. font-size: 60rpx;
  1051. }
  1052. }
  1053. .upload-image{
  1054. width: 180rpx;
  1055. height: 180rpx;
  1056. border-radius: 6rpx;
  1057. margin: 0 20rpx;
  1058. position: relative;
  1059. image{
  1060. width: 180rpx;
  1061. height: 180rpx;
  1062. border-radius: 6rpx;
  1063. }
  1064. .upload-del{
  1065. width: 40rpx;
  1066. height: 40rpx;
  1067. position: absolute;
  1068. top: -20rpx;
  1069. right: -20rpx;
  1070. line-height: 40rpx;
  1071. text-align: center;
  1072. .iconfont{
  1073. font-size: $font-size-32;
  1074. color: #999999;
  1075. }
  1076. }
  1077. }
  1078. }
  1079. }
  1080. .register-input{
  1081. width: 654rpx;
  1082. height: 40rpx;
  1083. padding: 24rpx;
  1084. margin: 0 auto;
  1085. margin-bottom: 60rpx;
  1086. background: #F7F7F7;
  1087. border-radius: 14rpx;
  1088. .input{
  1089. width: 100%;
  1090. height: 100%;
  1091. background: #F7F7F7;
  1092. font-size: $font-size-28;
  1093. line-height: 40rpx;
  1094. color: #333333;
  1095. border-radius: 14rpx;
  1096. }
  1097. }
  1098. .register-fiexd{
  1099. width: 100%;
  1100. height: auto;
  1101. position: fixed;
  1102. bottom: 0;
  1103. left: 0;
  1104. z-index: 999;
  1105. background: #FFFFFF;
  1106. }
  1107. .register-btn{
  1108. width: 600rpx;
  1109. height: 88rpx;
  1110. border-radius: 44rpx;
  1111. font-size: $font-size-28;
  1112. line-height: 88rpx;
  1113. color: #FFFFFF;
  1114. margin: 0 auto;
  1115. text-align: center;
  1116. background: $btn-confirm;
  1117. margin-top: 96rpx;
  1118. &.prev{
  1119. background:#ffe6dc;
  1120. color: $color-system;
  1121. margin-top: 20rpx;
  1122. }
  1123. &.none{
  1124. border: 1px solid $color-system;
  1125. background: #FFFFFF;
  1126. color:$color-system;
  1127. margin-top: 0;
  1128. }
  1129. &.sub{
  1130. margin-top: 0;
  1131. }
  1132. }
  1133. }
  1134. }
  1135. </style>