apply.vue 35 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337
  1. <template>
  2. <view class="container register" :style="{ paddingTop: CustomBar + 'px' }">
  3. <cu-custom :navbar-data="nvabarData" @navigateBack="hanldNavigateBack"></cu-custom>
  4. <view class="register-main title clearfix">
  5. <view class="register-row none clearfix">
  6. <view class="register-title first"
  7. ><text>补充以下详细信息即可升级为资质机构,享受更多更好的服务。</text></view
  8. >
  9. <view class="register-title"><text></text></view>
  10. </view>
  11. </view>
  12. <view class="register-main clearfix" v-if="clubStatus == 92">
  13. <view class="register-row none clearfix">
  14. <view class="error-title">审核未通过原因:</view>
  15. <view class="error-main">
  16. <text class="error-item" v-for="(item, index) in errorList" :key="index"> {{ item }} </text>
  17. </view>
  18. </view>
  19. </view>
  20. <view class="register-main detailed clearfix">
  21. <view class="register-row none clearfix">
  22. <view class="register-from">
  23. <view class="label">邮箱</view>
  24. <input
  25. class="row-input"
  26. type="text"
  27. name="input"
  28. v-model="contractEmail"
  29. placeholder="请输入您的常用邮箱"
  30. placeholder-class="placeholder"
  31. maxlength="30"
  32. />
  33. </view>
  34. <view class="register-tip"><text>提示:邮箱可用作登录账号,请使用公司邮箱或法人邮箱</text></view>
  35. </view>
  36. <view class="register-row none clearfix">
  37. <view class="register-from">
  38. <view class="label">机构名称</view>
  39. <input
  40. class="row-input"
  41. type="text"
  42. v-model="clubName"
  43. placeholder="请输入您的机构名称"
  44. placeholder-class="placeholder"
  45. maxlength="30"
  46. />
  47. </view>
  48. <view class="register-tip"><text>示例:深圳市美丽人生医疗美容有限公司</text></view>
  49. </view>
  50. <view class="register-row none clearfix">
  51. <view class="register-from">
  52. <view class="label">机构简称</view>
  53. <input
  54. class="row-input"
  55. type="text"
  56. v-model="shortName"
  57. placeholder="请输入姓名或常用名"
  58. placeholder-class="placeholder"
  59. maxlength="10"
  60. />
  61. </view>
  62. <view class="register-tip"><text>示例:美丽人生</text></view>
  63. </view>
  64. <view class="register-row clearfix">
  65. <view class="register-from" @click="showMulLinkageThreePicker">
  66. <view class="label">机构地址</view>
  67. <text class="row-input" :class="addressData.address === '请选择机构所在地区' ? 'none' : ''">
  68. {{ addressData.address }}
  69. </text>
  70. <text class="iconfont icon-xiayibu"></text>
  71. </view>
  72. </view>
  73. <view class="register-row text-textarea clearfix">
  74. <view class="textarea show" v-if="isShowInput" @click="showTextareaFocus">{{
  75. addressData.addressDetail ? addressData.addressDetail : '详细地址:如道路、门牌号、小区等'
  76. }}</view>
  77. <textarea
  78. v-else
  79. class="textarea"
  80. type="text"
  81. v-model="addressData.addressDetail"
  82. placeholder="详细地址:如道路、门牌号、小区等"
  83. placeholder-class="placeholder"
  84. maxlength="25"
  85. @input="onTextareaInput"
  86. :focus="textareaFocus"
  87. @blur="hideTextareaFocus"
  88. :class="isShowInput ? '' : ''"
  89. />
  90. </view>
  91. <view class="register-row clearfix">
  92. <view class="register-from">
  93. <view class="label">营业执照编号</view>
  94. <input
  95. class="row-input code"
  96. type="text"
  97. v-model="socialCreditCode"
  98. placeholder="请填写社会统一信用代码"
  99. maxlength="18"
  100. />
  101. </view>
  102. </view>
  103. <view class="register-row clearfix">
  104. <view class="register-picture">
  105. <view class="label">营业执照</view>
  106. <view class="upload-picture">
  107. <view class="upload-none" v-if="businessLicense === ''" @click="chooseBusinessImage">
  108. <image src="https://static.caimei365.com/app/img/upload/club-zizhi.png"></image>
  109. </view>
  110. <view class="upload-image" v-else>
  111. <image :src="businessLicense" mode="" @click="viewBusinessImage"></image>
  112. <view class="upload-del" @click="delBusinessImage">
  113. <text class="iconfont icon-shanchu1"></text>
  114. </view>
  115. </view>
  116. </view>
  117. </view>
  118. </view>
  119. <view class="register-row clearfix">
  120. <view class="register-picture">
  121. <view class="label">门头照</view>
  122. <view class="upload-picture">
  123. <view class="upload-none" v-if="shopPhoto === ''" @click="chooseMentuzImage">
  124. <image src="https://static.caimei365.com/app/img/upload/club-door.png"></image>
  125. </view>
  126. <view class="upload-image" v-else>
  127. <image :src="shopPhoto" mode="" @click="viewMentuzImage"></image>
  128. <view class="upload-del" @click="delMentuzImage">
  129. <text class="iconfont icon-shanchu1"></text>
  130. </view>
  131. </view>
  132. </view>
  133. </view>
  134. </view>
  135. <view class="register-row clearfix">
  136. <view class="register-from picker noneborder">
  137. <view class="label">机构类型</view>
  138. <view class="row-input picker">
  139. <radio-group @change="bindPickerChange">
  140. <label class="label-radio" v-for="(item, index) in typename" :key="item.value">
  141. <radio
  142. class="row-radio"
  143. :value="item.value"
  144. :checked="index === firstClubTypeCurrent"
  145. color="#E15616"
  146. />{{ item.name }}
  147. </label>
  148. </radio-group>
  149. </view>
  150. </view>
  151. </view>
  152. <view class="register-row clearfix" v-if="isOrganizationType == 1">
  153. <view class="register-from noneborder second">
  154. <view
  155. class="secondTyperadio"
  156. v-for="(item, index) in beautyList"
  157. :key="item.value"
  158. @click="radioChange(item)"
  159. :class="item.value == secondClubType ? 'active' : ''"
  160. >
  161. <view class="secondRadio">{{ item.name }}</view>
  162. </view>
  163. </view>
  164. </view>
  165. <view class="register-row clearfix" v-if="isOrganizationType == 2">
  166. <view class="register-from noneborder second">
  167. <view
  168. class="secondTyperadio"
  169. v-for="(item, index) in beautyLists"
  170. :key="item.value"
  171. @click="radioChange(item)"
  172. :class="item.value == secondClubType ? 'active' : ''"
  173. >
  174. <view class="secondRadio">{{ item.name }}</view>
  175. </view>
  176. </view>
  177. </view>
  178. <view class="register-row clearfix" v-if="isOrganizationType == 1">
  179. <view class="register-picture zz">
  180. <view class="label zz">医疗执业许可证</view>
  181. <view class="upload-picture">
  182. <view class="upload-none" v-if="medicalPracticeLicense === ''" @click="chooseMedicalImage">
  183. <image src="https://static.caimei365.com/app/img/upload/club-zizhi.png"></image>
  184. </view>
  185. <view class="upload-image" v-else>
  186. <image :src="medicalPracticeLicense" mode="" @click="viewMedicalImage"></image>
  187. <view class="upload-del" @click="delMedicalImage">
  188. <text class="iconfont icon-shanchu1"></text>
  189. </view>
  190. </view>
  191. </view>
  192. </view>
  193. </view>
  194. <view class="register-row clearfix" v-if="isOrganizationType == 1 && isDepartment">
  195. <view class="register-from" style="height: auto;border: 0;">
  196. <view class="kes-title">科室</view>
  197. <textarea
  198. class="keshi"
  199. placeholder="请填写经营的科室,至少三个,用逗号隔开"
  200. placeholder-style="placeholder"
  201. v-model="department"
  202. maxlength="16"
  203. ></textarea>
  204. </view>
  205. </view>
  206. <view class="register-row clearfix" v-if="isOrganizationType == 1">
  207. <view class="register-from group" style="height: auto;border: 0;">
  208. <view class="label">主营内容</view>
  209. <view class="content-class">
  210. <checkbox-group @change="chooseMaleLike">
  211. <label
  212. class="item"
  213. v-for="(item, index) in mentuzCampList"
  214. :key="index"
  215. :class="{ on: item.checked }"
  216. >
  217. <checkbox class="item-checkbox" :value="item.value"></checkbox>
  218. <text class="item-text">{{ item.name }}</text>
  219. </label>
  220. </checkbox-group>
  221. </view>
  222. </view>
  223. <view class="register-from group btn" style="height: auto;border: 0;">
  224. <view class="content-class btn">
  225. <input
  226. class="row-input other"
  227. type="text"
  228. v-model="customItemValue"
  229. placeholder-style="placeholder"
  230. placeholder="请输入自定义主营内容"
  231. maxlength="5"
  232. />
  233. <button type="default" class="confirm-btn" @click.stop="addCustomItem">确认添加</button>
  234. </view>
  235. </view>
  236. </view>
  237. <view class="register-row clearfix" v-if="isOrganizationType == 2">
  238. <view class="register-from group" style="height: auto;border: 0;">
  239. <view class="label">主营内容</view>
  240. <view class="content-class">
  241. <checkbox-group @change="chooseMaleLikes">
  242. <label
  243. class="item"
  244. v-for="(item, index) in medicaCampList"
  245. :key="index"
  246. :class="{ on: item.checked }"
  247. >
  248. <checkbox class="item-checkbox" :value="item.value" :checked="item.checked"></checkbox>
  249. <text class="item-text">{{ item.name }}</text>
  250. </label>
  251. </checkbox-group>
  252. </view>
  253. </view>
  254. <view class="register-from group btn" style="height: auto;border: 0;">
  255. <view class="content-class btn">
  256. <input
  257. class="row-input other"
  258. type="text"
  259. v-model="customItemValue"
  260. placeholder="请输入自定义主营内容"
  261. placeholder-style="placeholder"
  262. maxlength="5"
  263. />
  264. <button type="default" class="confirm-btn" @click.stop="addCustomItem">确认添加</button>
  265. </view>
  266. </view>
  267. </view>
  268. <view class="register-fiexd clearfix" :style="{ paddingBottom: isIphoneX ? '68rpx' : '36rpx' }">
  269. <view class="register-row ">
  270. <view class="register-btn sub" @click.stop="organizationUpdateInfo">确认升级并提交审核</view>
  271. </view>
  272. </view>
  273. <mpvue-city-picker
  274. :themeColor="themeColor"
  275. ref="mpvueCityPicker"
  276. :pickerValueDefault="cityPickerValueDefault"
  277. @onCancel="onCancel"
  278. @onConfirm="onConfirm"
  279. >
  280. </mpvue-city-picker>
  281. </view>
  282. <!-- 提交审核提示弹窗 -->
  283. <view class="tui-alert-box" v-if="isConfirmShow">
  284. <view class="tui-alert-content">
  285. <view class="tui-alert-main"
  286. >升级信息提交成功,审核通过后您的身份将成为资质机构,并且获得<text class="red">500</text
  287. >采美豆的奖励</view
  288. >
  289. <view class="tui-alert-btn" @click="handleClick">知道了</view>
  290. </view>
  291. </view>
  292. </view>
  293. </template>
  294. <script>
  295. import { mapMutations } from 'vuex'
  296. import mpvueCityPicker from '@/components/mpvue-citypicker/mpvueCityPicker.vue'
  297. import { beautyList, beautyLists, mentuzCampNullList, medicaCampNullList } from '@/common/json/data.json.js' //本地数据
  298. import { uploadFileImage } from '@/services/public.js'
  299. export default {
  300. components: {
  301. mpvueCityPicker
  302. },
  303. data() {
  304. return {
  305. nvabarData: {
  306. //顶部自定义导航
  307. showCapsule: 1, // 是否显示左上角图标 1表示显示 0表示不显示,
  308. showSearch: 0,
  309. title: '升级资质机构', // 导航栏 中间的标题
  310. haveBack: true,
  311. textLeft: this.$store.state.isIphone
  312. },
  313. isIphoneX: this.$store.state.isIphoneX,
  314. CustomBar: this.CustomBar, // 顶部导航栏高度
  315. errorList: [],
  316. tabCurrentIndex: 3,
  317. clubStatus: '', //审核状态
  318. isPreviewImage: false, //预览图片开关
  319. userId: '', //用户ID
  320. clubId: '', //会所ID
  321. contractEmail: '', //邮箱
  322. clubName: '', //机构名称
  323. shortName: '', //机构简称
  324. socialCreditCode: '', //统一社会信用代码
  325. isDisabled: true,
  326. isShowInput: true,
  327. textareaFocus: false,
  328. businessLicense:'', //营业执照图片
  329. shopPhoto: '', //门头照图片
  330. medicalPracticeLicense: '', //资质照图片
  331. department: '', //科室
  332. isDepartment: true, //是否显示科室
  333. secondClubType: '', //机构类型二级分类
  334. mainProduct: '', //主营内容
  335. firstClubType: 1, //机构类型
  336. isOrganizationType: 1,
  337. firstClubTypeCurrent:0,
  338. organizationTypeText: '请选择机构类型',
  339. beautyList: beautyList, //医美分类
  340. beautyLists: beautyLists, //生美分类
  341. mentuzCampNullList: mentuzCampNullList, //医美分类
  342. medicaCampNullList: medicaCampNullList, //生美分类
  343. mentuzCampList: [], //医美主营
  344. medicaCampList: [], //生美主营
  345. typtIndex: 0,
  346. organizationType: 0,
  347. isShowAustomItem: false, //是否显示其他添加
  348. customItemValue: '', //自定义项目
  349. isMainproCheck: false,
  350. isConfirmShow: false,
  351. isFirstAdds:true,
  352. addressData: {
  353. address: '请选择机构所在地区',
  354. townId: '', //区ID
  355. cityId: '', //市ID
  356. provinceId: '', //省ID
  357. addressDetail: '' //地址详情
  358. },
  359. typename: [{ name: '医美', value: 1 }, { name: '生美', value: 2 }]
  360. }
  361. },
  362. onLoad(option) {
  363. this.clubStatus = option.clubStatus
  364. this.organizationInfo()
  365. },
  366. methods: {
  367. hanldNavigateBack() {
  368. this.$util.modal('', '资料尚未提交审核,确定放弃升级吗?', '确定', '取消', true, () => {
  369. uni.navigateBack({
  370. delta: 1
  371. })
  372. })
  373. },
  374. organizationInfo() {
  375. this.$api.getStorage().then(resolve => {
  376. this.userId = resolve.userId ? resolve.userId : 0
  377. this.UserService.OrganizationUpdateModifyInfo({ userId: this.userId })
  378. .then(response => {
  379. let organizationClub = response.data.club
  380. let organizationUser = response.data.user
  381. if (organizationUser.auditNoteList != null) {
  382. this.errorList = organizationUser.auditNoteList
  383. }
  384. this.contractEmail = organizationClub.contractEmail
  385. this.clubId = organizationUser.clubId
  386. if (this.contractEmail) {
  387. this.isFirstAdds = false
  388. this.clubName = this.$reg.checkData(organizationClub.name)
  389. } else {
  390. this.isFirstAdds = true
  391. this.clubName = ''
  392. }
  393. this.shortName = this.$reg.checkData(organizationClub.shortName)
  394. if (organizationClub.provinceId == '' || organizationClub.provinceId == null) {
  395. this.addressData.provinceId = ''
  396. } else {
  397. this.addressData.provinceId = organizationClub.provinceId
  398. }
  399. if (organizationClub.cityId == '' || organizationClub.cityId === null) {
  400. this.addressData.cityId = ''
  401. } else {
  402. this.addressData.cityId = organizationClub.cityId
  403. }
  404. if (organizationClub.townId == '' || organizationClub.townId == null) {
  405. this.addressData.townId = ''
  406. } else {
  407. this.addressData.townId = organizationClub.townId
  408. }
  409. this.addressData.address = organizationClub.provincialAddress
  410. ? organizationClub.provincialAddress
  411. : '请选择机构所在地区'
  412. this.addressData.addressDetail = this.$reg.checkData(organizationClub.address)
  413. this.socialCreditCode = this.$reg.checkData(organizationClub.socialCreditCode)
  414. this.firstClubType = organizationClub.firstClubType
  415. this.secondClubType = this.$reg.checkData(organizationClub.secondClubType)
  416. this.businessLicense = this.$reg.checkData(organizationClub.businessLicense)
  417. this.shopPhoto = this.$reg.checkData(organizationClub.shopPhoto)
  418. this.medicalPracticeLicense = this.$reg.checkData(organizationClub.medicalPracticeLicense)
  419. this.department = this.$reg.checkData(organizationClub.department)
  420. //机构类型&&主营项目
  421. switch (this.firstClubType) {
  422. case 1:
  423. this.organizationTypeText = '医美'
  424. this.isOrganizationType = 1
  425. break
  426. case 2:
  427. this.organizationTypeText = '生美'
  428. this.isOrganizationType = 2
  429. break
  430. case null:
  431. this.organizationTypeText = '请选择机构类型'
  432. this.isOrganizationType = 1
  433. break
  434. }
  435. if (organizationClub.mainProduct == '' || organizationClub.mainProduct == null) {
  436. this.mentuzCampList = this.mentuzCampNullList
  437. this.medicaCampList = this.medicaCampNullList
  438. } else {
  439. if (this.firstClubType == 1) {
  440. this.mentuzCampList = this.setNewMainpro(organizationClub.mainProduct)
  441. this.medicaCampList = this.medicaCampNullList
  442. } else {
  443. this.medicaCampList = this.setNewMainpro(organizationClub.mainProduct)
  444. this.mentuzCampList = this.mentuzCampNullList
  445. }
  446. this.mainProduct = organizationClub.mainProduct
  447. }
  448. //机构类型
  449. switch (this.secondClubType) {
  450. case 1:
  451. this.isDepartment = false
  452. break
  453. case 2:
  454. this.isDepartment = true
  455. break
  456. case 3:
  457. this.isDepartment = true
  458. break
  459. }
  460. })
  461. .catch(error => {
  462. this.$util.msg(error.msg, 2000)
  463. })
  464. })
  465. },
  466. organizationUpdateInfo() {
  467. //提交审核
  468. if (this.isFirstAdds) {
  469. let mainproList = []
  470. if (this.isOrganizationType == 1) {
  471. this.mentuzCampList.forEach(item => {
  472. mainproList.push(item.name)
  473. })
  474. } else {
  475. this.medicaCampList.forEach(item => {
  476. mainproList.push(item.name)
  477. })
  478. }
  479. this.mainProduct = mainproList.join('/')
  480. }
  481. if (this.contractEmail == '') {
  482. this.$util.msg('请输入邮箱地址', 2000)
  483. return
  484. }
  485. if (!this.$reg.isEmail(this.contractEmail)) {
  486. this.$util.msg('请输入正确的邮箱地址', 2000)
  487. return
  488. }
  489. if (this.clubName == '') {
  490. this.$util.msg('请输入机构名称', 2000)
  491. return
  492. }
  493. if (this.addressData.townId == '') {
  494. this.$util.msg('请选择机构地址', 2000)
  495. return
  496. }
  497. if (this.addressData.addressDetail == '') {
  498. this.$util.msg('请填写机构详细地址', 2000)
  499. return
  500. }
  501. if (this.businessLicense == '') {
  502. this.$util.msg('请上传您的营业执照', 2000)
  503. return
  504. }
  505. if (this.medicalPracticeLicense == '') {
  506. this.$util.msg('请上传您的资质许可证', 2000)
  507. return
  508. }
  509. if (this.isOrganizationType == 1 || this.isOrganizationType == 2) {
  510. if(this.secondClubType == ''){
  511. this.$util.msg('选择机构类型', 2000)
  512. return
  513. }
  514. }
  515. if (this.isOrganizationType == 1 || this.isOrganizationType == 2) {
  516. if (this.mainProduct == '') {
  517. this.$util.msg('请选择机构主营内容', 2000)
  518. return
  519. }
  520. }
  521. let params = {
  522. userId: this.userId,
  523. clubId: this.clubId, //会所ID
  524. contractEmail: this.contractEmail,
  525. name: this.clubName,
  526. shortName: this.shortName,
  527. provinceId: this.addressData.provinceId,
  528. cityId: this.addressData.cityId,
  529. townId: this.addressData.townId,
  530. address: this.addressData.addressDetail,
  531. socialCreditCode: this.socialCreditCode,
  532. businessLicense: this.businessLicense,
  533. shopPhoto: this.shopPhoto,
  534. firstClubType: this.isOrganizationType, //机构类型分类 医美:1和生美:2
  535. secondClubType: this.secondClubType, //机构类型二级分类 诊所:1,门诊:2,医院:3
  536. department: this.department, //科室
  537. medicalPracticeLicense: this.medicalPracticeLicense, //资质图片
  538. mainProduct: this.mainProduct
  539. }
  540. // 友盟埋点普通机构确认升级点击事件
  541. if (process.env.NODE_ENV != 'development') {
  542. this.$uma.trackEvent('Um_Event_ConfirmClubUpgrade', {
  543. Um_Key_ClubName: `${this.clubName}`,
  544. Um_Key_PageName: '普通机构确认升级',
  545. Um_Key_SourcePage: '升级页面'
  546. })
  547. }
  548. this.UserService.OrganizationRegister(params)
  549. .then(response => {
  550. this.isConfirmShow = true
  551. })
  552. .catch(error => {
  553. this.$util.msg(error.msg, 2000)
  554. })
  555. },
  556. handleClick() {
  557. //隐藏提示弹窗
  558. this.isConfirmShow = false
  559. setTimeout(() => {
  560. uni.navigateBack()
  561. }, 2000)
  562. },
  563. // 三级联动选择
  564. showMulLinkageThreePicker() {
  565. this.isShowInput = true
  566. this.$refs.mpvueCityPicker.show()
  567. },
  568. onConfirm(e) {
  569. this.addressData.address = e.name
  570. this.addressData.townId = e.townCode
  571. this.addressData.cityId = e.cityCode
  572. this.addressData.provinceId = e.provinceCode
  573. },
  574. onTextareaInput(e) {
  575. this.addressData.addressDetail = e.detail.value
  576. },
  577. showTextareaFocus() {
  578. //文本框获取焦点
  579. this.isShowInput = false
  580. this.textareaFocus = true
  581. },
  582. hideTextareaFocus() {
  583. //文本框失去焦点
  584. this.isShowInput = true
  585. this.textareaFocus = false
  586. },
  587. chooseBusinessImage() {
  588. //营业执照图片上传
  589. uploadFileImage().then(res => {
  590. this.businessLicense = JSON.parse(res.data).data
  591. })
  592. },
  593. chooseMentuzImage() {
  594. //门头照图片上传
  595. uploadFileImage().then(res => {
  596. this.shopPhoto = JSON.parse(res.data).data
  597. })
  598. },
  599. chooseMedicalImage() {
  600. //资质照图片上传
  601. uploadFileImage().then(res => {
  602. this.medicalPracticeLicense = JSON.parse(res.data).data
  603. })
  604. },
  605. viewBusinessImage(e) {
  606. this.myPreviewImageFn(this.businessLicense)
  607. },
  608. viewMentuzImage(e) {
  609. this.myPreviewImageFn(this.shopPhoto)
  610. },
  611. viewMedicalImage(e) {
  612. this.myPreviewImageFn(this.medicalPracticeLicense)
  613. },
  614. myPreviewImageFn(url) {
  615. this.isPreviewImage = true
  616. let mentuzArray = []
  617. mentuzArray.push(url)
  618. uni.previewImage({
  619. urls: mentuzArray,
  620. current: 0
  621. })
  622. },
  623. delBusinessImage() {
  624. this.$util.modal('', '确定删除营业执照图片吗?', '确定', '取消', true, () => {
  625. this.businessLicense = ''
  626. })
  627. },
  628. delMentuzImage() {
  629. this.$util.modal('', '确定删除门头照图片吗?', '确定', '取消', true, () => {
  630. this.shopPhoto = ''
  631. })
  632. },
  633. delMedicalImage() {
  634. this.$util.modal('', '确定删除资质图片吗?', '确定', '取消', true, () => {
  635. this.medicalPracticeLicense = ''
  636. })
  637. },
  638. bindPickerChange(e) {
  639. this.isOrganizationType = e.target.value
  640. for (let i = 0; i < this.typename.length; i++) {
  641. if (this.typename[i].value === e.target.value) {
  642. this.firstClubTypeCurrent = i
  643. break
  644. }
  645. }
  646. // let self = this
  647. // uni.showActionSheet({
  648. // title:'标题',
  649. // itemList: ['医美', '生美'],
  650. // success: (e) => {
  651. // self.isOrganizationType = e.tapIndex+1
  652. // switch(e.tapIndex){
  653. // case 0:
  654. // this.organizationTypeText = '医美'
  655. // break;
  656. // case 1:
  657. // this.organizationTypeText = '生美'
  658. // break;
  659. // }
  660. // }
  661. // })
  662. },
  663. bindPickerChange2(e) {
  664. this.typtIndex = e.target.value
  665. this.isOrganizationType = e.target.value
  666. },
  667. radioChange(item) {
  668. this.secondClubType = item.value
  669. if (this.secondClubType == 2 || this.secondClubType == 3) {
  670. this.isDepartment = true
  671. } else {
  672. this.isDepartment = false
  673. }
  674. },
  675. chooseMaleLike(e) {
  676. this.mainProduct = this.checkLikes(e, this.mentuzCampList)
  677. },
  678. chooseMaleLikes(e) {
  679. this.mainProduct = this.checkLikes(e, this.medicaCampList)
  680. },
  681. checkLikes(e, list) {
  682. let values = e.detail.value
  683. let arr = []
  684. list.forEach(item => {
  685. if (values.indexOf(item.value) >= 0) {
  686. this.$set(item, 'checked', true)
  687. arr.push(item.name)
  688. } else {
  689. this.$set(item, 'checked', false)
  690. }
  691. })
  692. return arr.join('/')
  693. },
  694. // onBlurInput(e){//
  695. // if(e.detail.value ===''){
  696. // this.isDisabled = true
  697. // }else{
  698. // this.isDisabled = false
  699. // }
  700. // },
  701. showAustomItem() {
  702. this.isShowAustomItem = !this.isShowAustomItem
  703. },
  704. setNewMainpro(arr) {
  705. //回显处理主营内容
  706. let _ARRAY = []
  707. arr.split('/').forEach((item, index) => {
  708. let _OBJ = { value: (index + 1).toString(), name: item, checked: true }
  709. _ARRAY.push(_OBJ)
  710. })
  711. return _ARRAY
  712. },
  713. addCustomItem() {
  714. if (this.customItemValue == '') {
  715. this.$util.msg('请输入自定义主营内容', 2000)
  716. } else {
  717. if (this.isOrganizationType == 1) {
  718. let item = { value: `${this.mentuzCampList.length + 1}`, name: this.customItemValue, checked: true }
  719. if (this.checkedArray(this.customItemValue, this.mentuzCampList)) {
  720. this.$util.msg('主营内容已存在!', 2000)
  721. } else {
  722. this.mentuzCampList.push(item)
  723. }
  724. } else {
  725. let item = { value: `${this.medicaCampList.length + 1}`, name: this.customItemValue, checked: true }
  726. if (this.checkedArray(this.customItemValue, this.medicaCampList)) {
  727. this.$util.msg('主营内容已存在!', 2000)
  728. } else {
  729. this.medicaCampList.push(item)
  730. }
  731. }
  732. }
  733. },
  734. checkedArray(content, arr) {
  735. //判断主营内容是否已存在
  736. console.log(content, arr)
  737. for (var i in arr) {
  738. if (arr[i].name == content) {
  739. return true
  740. }
  741. }
  742. return false
  743. }
  744. },
  745. onShow() {
  746. if (this.isPreviewImage) {
  747. this.isPreviewImage = false
  748. return
  749. }
  750. }
  751. }
  752. </script>
  753. <style lang="scss">
  754. .placeholder {
  755. color: #b2b2b2;
  756. }
  757. .register {
  758. width: 100%;
  759. height: auto;
  760. border-top: 1px solid #f7f7f7;
  761. .register-main {
  762. width: 100%;
  763. height: auto;
  764. background: #ffffff;
  765. padding: 20rpx 0;
  766. &.title {
  767. background-image: linear-gradient(
  768. 270deg,
  769. rgba(255, 255, 255, 0.1) 0%,
  770. rgba(255, 86, 11, 0.1) 51%,
  771. rgba(255, 255, 255, 0.1) 100%
  772. );
  773. }
  774. &.detailed {
  775. padding-bottom: 300rpx;
  776. }
  777. &.first {
  778. padding-top: 110rpx;
  779. }
  780. .register-tips {
  781. display: flex;
  782. flex-direction: column;
  783. align-items: center;
  784. line-height: 44rpx;
  785. font-size: $font-size-24;
  786. color: #ff0000;
  787. margin-bottom: 40rpx;
  788. .iconfont {
  789. font-size: $font-size-24;
  790. }
  791. }
  792. .register-row {
  793. width: 702rpx;
  794. height: auto;
  795. padding: 0 24rpx;
  796. margin-bottom: 20rpx;
  797. .secondTyperadio {
  798. border: 2rpx solid #e1e1e1;
  799. display: inline-block;
  800. font-size: 26rpx;
  801. color: #999999;
  802. padding: 0 24rpx;
  803. border-radius: 22rpx;
  804. line-height: 42rpx;
  805. margin-right: 30rpx;
  806. float: left;
  807. &.active {
  808. border: 2rpx solid #ffe6dc;
  809. color: $color-system;
  810. }
  811. }
  812. &.none {
  813. margin-bottom: 0;
  814. }
  815. .error-title {
  816. line-height: 40rpx;
  817. font-size: $font-size-28;
  818. color: $text-color;
  819. text-align: left;
  820. }
  821. .error-main {
  822. padding: 10rpx 0;
  823. .error-item {
  824. padding: 0 20rpx;
  825. margin: 10rpx;
  826. background: #f53636;
  827. height: 52rpx;
  828. line-height: 52rpx;
  829. border-radius: 26rpx;
  830. font-size: $font-size-26;
  831. color: #ffffff;
  832. text-align: center;
  833. display: inline-block;
  834. }
  835. }
  836. .register-tip {
  837. line-height: 64rpx;
  838. font-size: $font-size-20;
  839. color: #fea785;
  840. text-align: left;
  841. }
  842. .register-title {
  843. line-height: 44rpx;
  844. font-size: $font-size-24;
  845. color: $color-system;
  846. text-align: left;
  847. }
  848. .row-btn {
  849. position: absolute;
  850. right: 24rpx;
  851. top: 0;
  852. line-height: 88rpx;
  853. text-align: center;
  854. font-size: $font-size-28;
  855. color: $color-system;
  856. }
  857. .register-from {
  858. width: 100%;
  859. height: 88rpx;
  860. background: #ffffff;
  861. position: relative;
  862. border-bottom: 1px solid #e1e1e1;
  863. box-sizing: border-box;
  864. &.noneborder {
  865. border: none;
  866. }
  867. &.second {
  868. padding-left: 160rpx;
  869. }
  870. .label {
  871. text-align: left;
  872. font-size: $font-size-28;
  873. color: #666666;
  874. line-height: 88rpx;
  875. float: left;
  876. }
  877. .kes-title {
  878. font-size: $font-size-28;
  879. color: #666666;
  880. line-height: 88rpx;
  881. }
  882. .row-input {
  883. width: 520rpx;
  884. padding-left: 10rpx;
  885. font-size: $font-size-28;
  886. color: $text-color;
  887. line-height: 88rpx;
  888. float: right;
  889. height: 88rpx;
  890. &.code {
  891. width: 500rpx;
  892. }
  893. &.none {
  894. color: #999999;
  895. }
  896. &.picker {
  897. text-align: left;
  898. color: #333333;
  899. }
  900. }
  901. .keshi {
  902. width: 678rpx;
  903. border: 2rpx solid #b2b2b2;
  904. border-radius: 6rpx;
  905. height: 160rpx;
  906. font-size: $font-size-28;
  907. padding: 10rpx;
  908. }
  909. &.code {
  910. width: 410rpx;
  911. float: left;
  912. margin-right: 20rpx;
  913. .row-input {
  914. width: 390rpx;
  915. }
  916. }
  917. &.btn {
  918. width: 224rpx;
  919. height: 88rpx;
  920. float: left;
  921. background: $btn-confirm;
  922. padding: 0;
  923. .row-input {
  924. width: 224rpx;
  925. height: 88rpx;
  926. line-height: 88rpx;
  927. padding: 0;
  928. color: #ffffff;
  929. background: $btn-confirm;
  930. text-align: center;
  931. border-radius: 14rpx;
  932. &.other {
  933. width: 350rpx;
  934. background: #fff;
  935. margin-right: 20rpx;
  936. border: 2rpx solid #b2b2b2;
  937. border-radius: 44rpx;
  938. padding: 0 24rpx;
  939. height: 64rpx;
  940. line-height: 64rpx;
  941. }
  942. &.none {
  943. background: #f7f7f7;
  944. }
  945. }
  946. &.disabled {
  947. background: #f7f7f7;
  948. .row-input {
  949. background: #f7f7f7;
  950. color: #999999;
  951. }
  952. }
  953. }
  954. &.picker {
  955. width: 100%;
  956. height: 88rpx;
  957. line-height: 88rpx;
  958. .label {
  959. line-height: 88rpx;
  960. }
  961. .label-radio {
  962. margin-right: 70rpx;
  963. }
  964. .row-radio {
  965. transform: scale(0.8);
  966. }
  967. .row-input {
  968. width: 500rpx;
  969. height: 88rpx;
  970. line-height: 88rpx;
  971. padding-left: 40rpx;
  972. float: left;
  973. }
  974. }
  975. &.radio {
  976. width: 654rpx;
  977. height: 288rpx;
  978. .row-input {
  979. width: 100%;
  980. height: 88rpx;
  981. line-height: 88rpx;
  982. padding-left: 0;
  983. }
  984. .row-radio {
  985. float: left;
  986. transform: scale(0.8);
  987. }
  988. .row-text {
  989. width: 100rpx;
  990. text-align: center;
  991. float: left;
  992. }
  993. }
  994. &.group {
  995. width: 702rpx;
  996. height: auto;
  997. background: #ffffff;
  998. margin-top: 30rpx;
  999. .label {
  1000. line-height: 76rpx;
  1001. }
  1002. .row-input {
  1003. width: 100%;
  1004. height: 88rpx;
  1005. line-height: 88rpx;
  1006. padding-left: 0;
  1007. }
  1008. .row-radio {
  1009. float: left;
  1010. }
  1011. .row-text {
  1012. width: 100rpx;
  1013. text-align: center;
  1014. float: left;
  1015. }
  1016. }
  1017. &.btn {
  1018. margin-top: 0;
  1019. }
  1020. .content-class {
  1021. margin: 20rpx auto;
  1022. display: flex;
  1023. flex-flow: row wrap;
  1024. justify-content: space-between;
  1025. align-items: center;
  1026. &.btn {
  1027. margin: 0 auto;
  1028. margin-left: 116rpx;
  1029. }
  1030. .row-input {
  1031. display: flex;
  1032. width: 220rpx;
  1033. height: 40rpx;
  1034. padding: 24rpx;
  1035. text-align: left;
  1036. border-radius: 10rpx;
  1037. font-size: $font-size-28;
  1038. color: $text-color;
  1039. }
  1040. .confirm-btn {
  1041. width: 160rpx;
  1042. height: 64rpx;
  1043. border-radius: 45rpx;
  1044. line-height: 64rpx;
  1045. text-align: center;
  1046. background: #ffe6dc;
  1047. color: $color-system;
  1048. &.other {
  1049. width: 213rpx;
  1050. }
  1051. // &.none{
  1052. // color: #FFFFFF;
  1053. // }
  1054. // &.disabled{
  1055. // color: #999999;
  1056. // }
  1057. }
  1058. .item {
  1059. // width: 190rpx;
  1060. height: 60rpx;
  1061. font-size: $font-size-28;
  1062. line-height: 60rpx;
  1063. border-radius: 10rpx;
  1064. margin-left: 20rpx;
  1065. margin-bottom: 10rpx;
  1066. box-sizing: border-box;
  1067. // border: 1rpx solid #EFEFEF;
  1068. float: left;
  1069. // checkbox {
  1070. // display: none;
  1071. // }
  1072. }
  1073. .item-checkbox {
  1074. display: none;
  1075. }
  1076. .item-text {
  1077. border: 2rpx solid #e1e1e1;
  1078. display: inline-block;
  1079. font-size: 26rpx;
  1080. color: #999999;
  1081. padding: 0 30rpx;
  1082. border-radius: 28rpx;
  1083. line-height: 50rpx;
  1084. float: left;
  1085. }
  1086. .on {
  1087. .item-text {
  1088. border-color: $color-system;
  1089. color: $color-system;
  1090. }
  1091. }
  1092. }
  1093. }
  1094. .icon-xiayibu {
  1095. width: 88rpx;
  1096. height: 88rpx;
  1097. position: absolute;
  1098. right: 0;
  1099. top: 0;
  1100. line-height: 88rpx;
  1101. text-align: center;
  1102. color: #b2b2b2;
  1103. }
  1104. &.text-textarea {
  1105. background: #ffffff;
  1106. .textarea {
  1107. width: 100%;
  1108. height: 120rpx;
  1109. background: #ffffff;
  1110. padding: 24rpx 0;
  1111. font-size: $font-size-28;
  1112. color: $text-color;
  1113. z-index: 1;
  1114. border-bottom: 1px solid #e1e1e1;
  1115. }
  1116. .textarea.hide {
  1117. opacity: 0;
  1118. }
  1119. .textarea.show {
  1120. color: #999999;
  1121. }
  1122. }
  1123. }
  1124. .register-picture {
  1125. // height: 102rpx;
  1126. margin: 30rpx 0;
  1127. // width: 42%;
  1128. // float: left;
  1129. &.zz {
  1130. width: 100%;
  1131. }
  1132. .label {
  1133. // float: left;
  1134. font-size: $font-size-28;
  1135. color: $text-color;
  1136. line-height: 102rpx;
  1137. // width: 150rpx;
  1138. // text-align: left;
  1139. &.zz {
  1140. width: 230rpx;
  1141. }
  1142. }
  1143. .upload-picture {
  1144. // float: left;
  1145. width: 200rpx;
  1146. height: 180rpx;
  1147. .upload-none {
  1148. width: 200rpx;
  1149. height: 180rpx;
  1150. text-align: center;
  1151. line-height: 100rpx;
  1152. color: #999999;
  1153. // border: 1px solid #999999;
  1154. border-radius: 10rpx;
  1155. // margin: 0 20rpx;
  1156. // .iconfont{
  1157. // font-size: $font-size-28;
  1158. // }
  1159. image {
  1160. width: 100%;
  1161. height: 100%;
  1162. }
  1163. }
  1164. .upload-image {
  1165. width: 200rpx;
  1166. height: 180rpx;
  1167. border-radius: 10rpx;
  1168. margin: 0 20rpx;
  1169. position: relative;
  1170. image {
  1171. width: 100%;
  1172. height: 100%;
  1173. border-radius: 10rpx;
  1174. }
  1175. .upload-del {
  1176. width: 40rpx;
  1177. height: 40rpx;
  1178. position: absolute;
  1179. top: -20rpx;
  1180. right: -20rpx;
  1181. line-height: 40rpx;
  1182. text-align: center;
  1183. .iconfont {
  1184. font-size: $font-size-32;
  1185. color: #999999;
  1186. }
  1187. }
  1188. }
  1189. }
  1190. }
  1191. .register-input {
  1192. width: 654rpx;
  1193. height: 40rpx;
  1194. padding: 24rpx;
  1195. margin: 0 auto;
  1196. margin-bottom: 60rpx;
  1197. background: #f7f7f7;
  1198. border-radius: 14rpx;
  1199. .input {
  1200. width: 100%;
  1201. height: 100%;
  1202. background: #f7f7f7;
  1203. font-size: $font-size-28;
  1204. line-height: 40rpx;
  1205. color: #333333;
  1206. border-radius: 14rpx;
  1207. }
  1208. }
  1209. .register-fiexd {
  1210. width: 100%;
  1211. height: auto;
  1212. padding: 20rpx 0;
  1213. position: fixed;
  1214. bottom: 0;
  1215. left: 0;
  1216. z-index: 99;
  1217. background: #ffffff;
  1218. .register-agree {
  1219. display: flex;
  1220. flex-direction: column;
  1221. align-items: center;
  1222. margin: 32rpx 0;
  1223. .agree-text {
  1224. .checkbox {
  1225. float: left;
  1226. margin: 4rpx 6rpx 0 0;
  1227. color: #999999;
  1228. font-size: $font-size-32;
  1229. &.icon-gouxuan {
  1230. color: $color-system;
  1231. }
  1232. }
  1233. font-size: 20rpx;
  1234. line-height: 44rpx;
  1235. color: #999999;
  1236. text {
  1237. color: #0091ff;
  1238. }
  1239. }
  1240. }
  1241. }
  1242. .register-btn {
  1243. width: 600rpx;
  1244. height: 88rpx;
  1245. border-radius: 44rpx;
  1246. font-size: $font-size-28;
  1247. line-height: 88rpx;
  1248. color: #ffffff;
  1249. margin: 0 auto;
  1250. text-align: center;
  1251. background: $btn-confirm;
  1252. margin-top: 96rpx;
  1253. &.none {
  1254. background: #ffffff;
  1255. color: $text-color;
  1256. margin-top: 0;
  1257. }
  1258. &.sub {
  1259. margin-top: 0;
  1260. }
  1261. }
  1262. }
  1263. }
  1264. checkbox .wx-checkbox-input {
  1265. border-radius: 50%;
  1266. width: 36rpx;
  1267. height: 36rpx;
  1268. }
  1269. /* 选中后的 背景样式 */
  1270. checkbox .wx-checkbox-input.wx-checkbox-input-checked {
  1271. background: #e15616;
  1272. border: 2rpx solid #e15616;
  1273. }
  1274. checkbox .wx-checkbox-input.wx-checkbox-input-checked::before {
  1275. border-radius: 50%;
  1276. width: 36rpx;
  1277. height: 36rpx;
  1278. line-height: 36rpx;
  1279. text-align: center;
  1280. font-size: 20rpx;
  1281. color: #fff;
  1282. transform: scale(0.8);
  1283. -webkit-transform: translate(-50%, -50%) scale(1);
  1284. }
  1285. .tui-alert-box {
  1286. width: 100%;
  1287. height: 100%;
  1288. display: flex;
  1289. align-items: center;
  1290. justify-content: center;
  1291. flex-direction: column;
  1292. position: fixed;
  1293. left: 0;
  1294. top: 0;
  1295. opacity: 1;
  1296. background: rgba(51, 51, 51, 0.5);
  1297. z-index: 99999;
  1298. .tui-alert-content {
  1299. width: 580rpx;
  1300. height: 324rpx;
  1301. border-radius: 16rpx;
  1302. background-color: #ffffff;
  1303. position: absolute;
  1304. top: 0;
  1305. bottom: 0;
  1306. right: 0;
  1307. left: 0;
  1308. margin: auto;
  1309. .tui-alert-main {
  1310. width: 100%;
  1311. height: 234rpx;
  1312. box-sizing: border-box;
  1313. padding: 60rpx 30rpx;
  1314. line-height: 60rpx;
  1315. font-size: $font-size-26;
  1316. color: #666666;
  1317. text-align: justify;
  1318. .red {
  1319. color: #e15616;
  1320. }
  1321. }
  1322. .tui-alert-btn {
  1323. width: 100%;
  1324. height: 90rpx;
  1325. box-sizing: border-box;
  1326. line-height: 90rpx;
  1327. background: $btn-confirm;
  1328. color: #ffffff;
  1329. text-align: center;
  1330. font-size: $font-size-28;
  1331. border-radius: 0 0 16rpx 16rpx;
  1332. }
  1333. }
  1334. }
  1335. </style>