information.vue 29 KB

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