apply.vue 34 KB

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