information.vue 32 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026
  1. <template name='information'>
  2. <view class="container">
  3. <view class="wrap-info">
  4. <view class="row">
  5. <view class="info-title">基本信息</view>
  6. </view>
  7. <view class="info-from">
  8. <view class="label">公司名称</view>
  9. <input class="row-input" type="text" v-model="params.name" placeholder="请与营业执照的注册名称保持一致" maxlength="30"/>
  10. </view>
  11. <view class="info-from">
  12. <view class="label">公司简称</view>
  13. <input class="row-input" type="text" v-model="params.sname" placeholder="请输入公司简称" maxlength="10"/>
  14. </view>
  15. <view class="info-from">
  16. <view class="label">公司地址</view>
  17. <view class="row-input" @click="showMulLinkageThreePicker">
  18. <text :class="addressData.address === '请选择公司所在地区' ? 'none' : ''">
  19. {{addressData.address}}
  20. </text>
  21. <text class="iconfont icon-xiayibu"></text>
  22. </view>
  23. </view>
  24. <textarea value="" v-model="params.address" placeholder="请填写详细地址,如街道/小区/门牌等" maxlength="50" class="address-details"/>
  25. <view class="info-from">
  26. <view class="label">联系人</view>
  27. <input class="row-input" v-model="params.linkMan" type="text" placeholder="请输入联系人姓名" maxlength="6"/>
  28. </view>
  29. <view class="info-from">
  30. <view class="label">邮箱</view>
  31. <input class="row-input" v-model="params.email" type="text" placeholder="请输入邮箱地址 " maxlength="6"/>
  32. </view>
  33. <text class="info-email">邮箱可用作登录账号,请使用公司邮箱或法人邮箱</text>
  34. <view class="info-from">
  35. <view class="label">固定电话</view>
  36. <input class="row-input" v-model="params.contractPhone" type="text" placeholder="请在号码前加区 " maxlength="11"/>
  37. </view>
  38. <view class="info-from">
  39. <view class="label">传真</view>
  40. <input class="row-input" v-model="params.fax" type="text" placeholder="请输入公司传真号 " />
  41. </view>
  42. <view class="info-from">
  43. <view class="label">法人代表</view>
  44. <input class="row-input" v-model="params.legalPerson" type="text" placeholder="请输入公司法人代表姓名 " maxlength="6"/>
  45. </view>
  46. <view class="info-from">
  47. <view class="label">注册资本</view>
  48. <input class="row-input" v-model="params.registeredCapital" type="text" placeholder="请填写公司注册资本 " />
  49. </view>
  50. <view class="info-from">
  51. <view class="label">公司性质</view>
  52. <input class="row-input" v-model="params.nature" type="text" placeholder="请填写公司性质 " />
  53. </view>
  54. <view class="info-from">
  55. <view class="label">年营业额</view>
  56. <input class="row-input" v-model="params.turnover" type="text" placeholder="请输入公司年营业额 " />
  57. </view>
  58. </view>
  59. <view class="wrap-content">
  60. <view class="row">
  61. <view class="info-title">经营信息</view>
  62. </view>
  63. <view class="info-from" style="border: 0;">
  64. <view class="label">公司类型</view>
  65. <view class="row-input ShopTyperadio">
  66. <radio-group @change="radioChange">
  67. <label class="radio" v-for="(item, index) in typename" :key="item.value">
  68. <radio :value="item.value" :checked="item.value === params.firstShopType" color='#E15616'/>{{item.name}}
  69. </label>
  70. </radio-group>
  71. </view>
  72. </view>
  73. <view class="secondTyperadio" v-if="isfirstShow" >
  74. <view class="radio" v-for="(item,index) in secondtype" :key="index" @click="secondypeRidio(item)" :class="item.value==params.secondShopType?'active':''">
  75. <view class="secondRadio" >{{item.name}}</view>
  76. </view>
  77. </view>
  78. <view class="zizhi" v-if="issecondshow">
  79. <view class="info2-title zizhi-title">资质</view>
  80. <view class="uploadImage">
  81. <view class="form-upload-image" v-if="params.medicalPracticeLicenseImg1!=''">
  82. <image class="upload-img" :src="params.medicalPracticeLicenseImg1" alt="" ></image>
  83. <view class="iconfont icon-shanchu1" @click="deleteMedicalImage()"></view>
  84. </view>
  85. <view class="formLine-file" @click="uploadzizhiImageFn" v-else>
  86. <view class="file-zizhi"></view>
  87. </view>
  88. <view class="form-upload-tips">
  89. <text class="iconfont icon-wenhao"></text>
  90. <view class="wen-tips">点击图片可放大图片</view>
  91. </view>
  92. </view>
  93. </view>
  94. <view class="business">
  95. <view class="info2-title business-title">主营内容</view>
  96. <view class="business-info">
  97. <checkbox-group class="row-group" @change="chooseMaleLike">
  98. <label class="diyBox" v-for="(item, index) in mentuzCampList" :key="item.value" >
  99. <checkbox :value="item.value" :checked="item.checked"></checkbox>
  100. <view class="row-text">{{item.name}}</view>
  101. </label>
  102. </checkbox-group>
  103. <view class="addbusiness">
  104. <input class="row-input other" type="text" placeholder="请输入自定义项目" v-model="mainProEdit" maxlength="5"/>
  105. <button type="default" class="button" @click.stop="mainProAdd">确认添加</button>
  106. </view>
  107. </view>
  108. </view>
  109. <view class="business">
  110. <view class="info2-title business-title">经营范围</view>
  111. <view class="business-info">
  112. <checkbox-group class="row-group" @change="chooseMaleLikes">
  113. <label class="row-input" v-for="(item, index) in medicaCampList" :key="item.value" >
  114. <checkbox :value="item.value" :checked="item.checked" ></checkbox>
  115. <view class="row-text">{{item.name}}</view>
  116. </label>
  117. </checkbox-group>
  118. <view class="addbusiness">
  119. <input class="row-input other" type="text" placeholder="请输入自定义经营范围" v-model="shopScopeEdit" maxlength="5"/>
  120. <button type="default" class="button" @click.stop="shopScopeAdd">确认添加</button>
  121. </view>
  122. </view>
  123. </view>
  124. <view class="info">
  125. <view class="info2-title">公司介绍</view>
  126. <textarea v-model="params.info" maxlength="2000" placeholder="公司简介会在公司介绍页面展示,有助于机构更好的了解您, 建议从个人规模、代理产品、机构服务、荣誉资质这4方面进行介绍" name="textarea"/>
  127. </view>
  128. <view class="info">
  129. <view class="info2-title">主打系列商品说明</view>
  130. <textarea placeholder="请输入主打系列商品说明" v-model="params.productDesc" maxlength="500" name="textarea"/>
  131. </view>
  132. </view>
  133. <view class="wrap-image">
  134. <view class="row">
  135. <view class="info-title">资质证明</view>
  136. </view>
  137. <view class="info-from">
  138. <view class="label Code">营业执照编号</view>
  139. <input class="row-input Code" v-model.trim="params.socialCreditCode" type="text" placeholder="请输入公司营业执照编号" maxlength="18"/>
  140. </view>
  141. <view class="zizhi">
  142. <view class="info2-title zizhi-title">营业执照图片</view>
  143. <view class="uploadImage">
  144. <view class="form-upload-image" v-if="params.businessLicenseImage!=''">
  145. <image class="upload-img" :src="params.businessLicenseImage" @click="showViewerImageFn()" ></image>
  146. <view class="iconfont icon-shanchu1" @click="deleteBusinessImage()"></view>
  147. </view>
  148. <view class="formLine-file" @click="uploadBusinessLicenseImageFn" v-else>
  149. <view class="file-biss iconImage"></view>
  150. </view>
  151. </view>
  152. </view>
  153. <view class="zizhi">
  154. <view class="info2-title zizhi-title">公司LOGO</view>
  155. <view class="uploadImage">
  156. <view class="form-upload-image" v-if="params.logo!=''">
  157. <image class="upload-img" :src="params.logo" alt="" @click="showViewerImageFn1()"></image>
  158. <view class="iconfont icon-shanchu1" @click="deletelogoImage()"></view>
  159. </view>
  160. <view class="formLine-file" @click="uploadlogoImageFn" v-else>
  161. <view class="file-logo iconImage"></view>
  162. </view>
  163. </view>
  164. </view>
  165. <view class="zizhi">
  166. <view class="info2-title zizhi-title">生产许可证</view>
  167. <view class="uploadImage">
  168. <view class="form-upload-image" v-if="params.productionLicence!=''">
  169. <image class="upload-img" :src="params.productionLicence" alt="" @click="showViewerImageFn2()"></image>
  170. <view class="iconfont icon-shanchu1" @click="deleteproducImage()"></view>
  171. </view>
  172. <view class="formLine-file" @click="uploadproductionLicenceImageFn" v-else>
  173. <view class="file-produce iconImage"></view>
  174. </view>
  175. </view>
  176. </view>
  177. <view class="zizhi">
  178. <view class="info2-title zizhi-title">卫生许可证</view>
  179. <view class="uploadImage">
  180. <view class="form-upload-image" v-if="params.hygienicLicense!=''">
  181. <image class="upload-img" :src="params.hygienicLicense" alt="" @click="showViewerImageFn3()"></image>
  182. <view class="iconfont icon-shanchu1" @click="deletehygienicImage()"></view>
  183. </view>
  184. <view class="formLine-file" @click="uploadhygienicLicenseImageFn" v-else>
  185. <view class="file-health iconImage"></view>
  186. </view>
  187. </view>
  188. </view>
  189. <view class="zizhi">
  190. <view class="info2-title zizhi-title">税务许可证</view>
  191. <view class="uploadImage">
  192. <view class="form-upload-image" v-if="params.taxLicense!=''">
  193. <image class="upload-img" :src="params.taxLicense" alt="" @click="showViewerImageFn4()"></image>
  194. <view class="iconfont icon-shanchu1" @click="deletaxImage()"></view>
  195. </view>
  196. <view class="formLine-file" @click="uploadtaxLicenseImageFn" v-else>
  197. <view class="file-tax iconImage"></view>
  198. </view>
  199. </view>
  200. </view>
  201. <view class="zizhi">
  202. <view class="info2-title zizhi-title hoor">荣誉证书</view>
  203. <view class="uploadImage list-image">
  204. <view class="formLine-file" @click="uploadHonorImageFn" v-if="HonorImagesList.length<5" >
  205. <view class="file-honor iconImage"></view>
  206. </view>
  207. <view class="form-upload-image" v-for="(item, index) in HonorImagesList" :key="index">
  208. <image class="upload-img" :src="item" alt="" @click="showViewerImageFn5()"></image>
  209. <view class="iconfont icon-shanchu1" @click="removeGoodsImagesFn(HonorImagesList)"></view>
  210. </view>
  211. </view>
  212. </view>
  213. <view class="zizhi">
  214. <view class="info2-title zizhi-title hoor">产品证书</view>
  215. <view class="uploadImage list-image">
  216. <view class="formLine-file" @click="uploadproductImageFn" v-if="productImagesList.length<5" >
  217. <view class="file-product iconImage"></view>
  218. </view>
  219. <view class="form-upload-image" v-for="(item, index) in productImagesList" :key="index">
  220. <image class="upload-img" :src="item" alt="" @click="showViewerImageFn6()"></image>
  221. <view class="iconfont icon-shanchu1" @click="removeproductImagesFn(index)"></view>
  222. </view>
  223. </view>
  224. </view>
  225. </view>
  226. <view class="wrap-Btn">
  227. <button type="default" class="confirmBbtn" @click="shopSubmit">确定</button>
  228. </view>
  229. <mpvue-city-picker :themeColor="themeColor"
  230. ref="mpvueCityPicker"
  231. :pickerValueDefault="cityPickerValueDefault"
  232. @onCancel="onCancel"
  233. @onConfirm="onConfirm">
  234. </mpvue-city-picker>
  235. </view>
  236. </template>
  237. <script>
  238. import mpvueCityPicker from '@/components/mpvue-citypicker/mpvueCityPicker.vue'
  239. import { uploadFileImage } from "@/api/utils.js"
  240. import { mapState,mapMutations } from 'vuex';
  241. export default{
  242. name:'information',
  243. components:{
  244. mpvueCityPicker,
  245. },
  246. data(){
  247. return{
  248. isShowInput:false,
  249. firsttype:0,
  250. secontype:0,
  251. isfirstShow:false,
  252. issecondshow:false,
  253. addressData:{
  254. address:'请选择公司所在地区',
  255. townID:'', //区ID
  256. cityID:'', //区ID
  257. provinceID:'', //区ID
  258. addressDetail: '', //地址
  259. },
  260. typename:[
  261. {name:'医疗',value:'1'},
  262. {name:'非医疗',value:'2'}
  263. ],
  264. secondtype:[
  265. {name:'一类器械',value:'1'},
  266. {name:'二类器械',value:'2'},
  267. {name:'三类器械',value:'3'},
  268. {name:'其它',value:'4'}
  269. ],
  270. mentuzCampNullList:[
  271. {value:'1',name:'产品'},
  272. {value:'2',name:'仪器'},
  273. {value:'3',name:'服务'}
  274. ],
  275. medicaCampNullList:[
  276. {value:'1',name:'仪器护理类'},
  277. {value:'2',name:'护肤品类'},
  278. {value:'3',name:'纹绣类'},
  279. {value:'4',name:'美体内衣'},
  280. {value:'5',name:'整形耗材'},
  281. {value:'6',name:'国际品牌'},
  282. {value:'7',name:'美胸类'},
  283. {value:'8',name:'健康保健类'},
  284. {value:'9',name:'面膜类'},
  285. {value:'10',name:'抗衰老'},
  286. {value:'11',name:'生殖保养'},
  287. {value:'12',name:'健康养生'},
  288. {value:'13',name:'纤体减肥'}
  289. ],
  290. params:{
  291. userID:10450,
  292. shopID:10087,
  293. townID:'',
  294. provinceID: '',//省id
  295. cityID: '',
  296. address:'',
  297. name:'',//公司名称
  298. sname:'',//公司简称
  299. linkMan:'',//联系人
  300. email:'',//
  301. contractPhone:'',//固定电话
  302. fax:'',//传真
  303. legalPerson:'',//法人代表
  304. registeredCapital:'',//注册资本
  305. nature:'',//公司性质
  306. turnover:'',//年营业额
  307. firstShopType:'',//公司类型 1医疗 2非医疗
  308. secondShopType:'',//医疗下的二级分类
  309. medicalPracticeLicenseImg1:'',//资质
  310. mainpro:'',//主营产品
  311. businessScope:'',//经营内容
  312. info:'',//公司介绍
  313. productDesc:'',//主打说明
  314. medicalPracticeLicenseImg1:'',//三级器械/医疗执照
  315. socialCreditCode:'',//营业执照编号
  316. businessLicenseImage:'',//营业执照
  317. logo:'',//公司logo
  318. productionLicence:'',//生产
  319. hygienicLicense:'',//卫生
  320. taxLicense:'',//税务
  321. certificateHonor:'',//荣誉
  322. productCertification:'',//产品
  323. },
  324. mentuzCampList:[],
  325. medicaCampList:[],
  326. shopMainPros:[],
  327. shopScope:[],
  328. mainProEdit: '',
  329. shopScopeEdit:'',
  330. HonorImagesList:[],
  331. productImagesList:[],
  332. isPreviewImage:false, //预览图片开关
  333. isMainproCheck:false,
  334. }
  335. },
  336. onLoad() {
  337. // this.$api.getComStorage('userInfo').then((resolve) =>{
  338. // this.params.userID = resolve.userID;
  339. // this.params.shopID = resolve.shopID;
  340. // })
  341. this.shopInfo();
  342. },
  343. methods:{
  344. chooseMaleLike(e){
  345. this.isMainproCheck = true
  346. this.params.mainpro = this.checkLikes(e,this.mentuzCampList)
  347. },
  348. chooseMaleLikes(e){
  349. this.isMainproCheck = true
  350. this.params.businessScope = this.checkLikes(e,this.medicaCampList)
  351. },
  352. checkLikes(e,list){
  353. let values = e.detail.value;
  354. let arr = []
  355. list.forEach(item => {
  356. if(values.indexOf(item.value) >= 0){
  357. this.$set(item,'checked',true)
  358. arr.push(item.name)
  359. }else{
  360. this.$set(item,'checked',false)
  361. }
  362. })
  363. console.log(arr)
  364. return arr.join('/')
  365. },
  366. setNewMainpro(arr){//回显处理主营内容
  367. let _ARRAY = [];
  368. arr.split('/').forEach((item,index) =>{
  369. if(item != ""){
  370. let _OBJ = {value:(index+1).toString(),name:item,checked:true}
  371. _ARRAY.push(_OBJ)
  372. }
  373. })
  374. return _ARRAY
  375. },
  376. shopInfo(){
  377. // this.$api.getStorage().then((resolve) =>{
  378. this.ShopService.shopInfo({userId:10450}).then(response =>{
  379. if(response.code==0){
  380. console.log(response)
  381. let shop = response.data.shop;
  382. let user = response.data.user;
  383. this.params.name = shop.name;
  384. this.params.sname = shop.sname;
  385. this.params.linkMan = shop.linkMan;
  386. this.params.email = user.email;
  387. this.addressData.address = shop.provincialAddress;
  388. this.params.address = shop.address;
  389. this.params.provinceID = shop.provinceID;
  390. this.params.cityID = shop.cityID;
  391. this.params.townID = shop.townID;
  392. this.params.contractPhone = shop.contractPhone;
  393. this.params.fax = shop.fax;
  394. this.params.legalPerson = shop.legalPerson;
  395. this.params.registeredCapital = shop.registeredCapital;
  396. this.params.nature = shop.nature;
  397. this.params.turnover = shop.turnover;
  398. this.params.firstShopType = shop.firstShopType;
  399. this.params.secondShopType = shop.secondShopType;
  400. this.params.medicalPracticeLicenseImg1 = shop.medicalPracticeLicenseImg1;
  401. this.params.info = shop.info;
  402. this.params.productDesc = shop.productDesc;
  403. this.params.socialCreditCode = shop.socialCreditCode;
  404. this.params.businessLicenseImage = shop.businessLicenseImage;
  405. this.params.logo = shop.logo;
  406. this.params.productionLicence = shop.productionLicence;
  407. this.params.hygienicLicense = shop.hygienicLicense;
  408. this.params.taxLicense = shop.taxLicense;
  409. this.params.certificateHonor = shop.hygienicLicense;
  410. this.HonorImagesList = response.data.certificateHonor;
  411. this.productImagesList = response.data.productCertification;
  412. if( response.data.certificateHonor!=''|| response.data.certificateHonor!=null){
  413. this.params.certificateHonor =this.HonorImagesList.toString()+',';
  414. }
  415. if( response.data.productCertification!=''|| response.data.productCertification!=null){
  416. this.params.productCertification =this.productImagesList.toString()+',';
  417. }
  418. if(shop.mainpro == "" || shop.mainpro == null){
  419. this.mentuzCampList = this.mentuzCampNullList
  420. }else{
  421. this.mentuzCampList = this.setNewMainpro(shop.mainpro)
  422. this.params.mainpro = shop.mainpro
  423. }
  424. if(shop.businessScope == "" || shop.businessScope == null){
  425. this.medicaCampList = this.medicaCampNullList
  426. }else{
  427. this.medicaCampList = this.setNewMainpro(shop.businessScope)
  428. this.params.businessScope = shop.businessScope
  429. }
  430. }
  431. })
  432. // })
  433. },
  434. shopSubmit(){//提交修改
  435. console.log(this.params);
  436. if(this.params.name==''){
  437. this.$util.msg('请输入公司名称',2000);
  438. return
  439. }else if(this.params.townID==''){
  440. this.$util.msg('请选择联系地址',2000);
  441. return
  442. }else if(this.params.address==''){
  443. this.$util.msg('请输入正确的联系地址',2000);
  444. return
  445. }else if(this.params.linkMan==''){
  446. this.$util.msg('请输入正确的联系人姓名',2000);
  447. return
  448. }else if(this.params.legalPerson==''){
  449. this.$util.msg('请输入法人代表姓名',2000);
  450. return
  451. }else if(this.params.registeredCapital==''){
  452. this.$util.msg('请输入注册资本',2000);
  453. return
  454. }else if(this.params.nature==''){
  455. this.$util.msg('请输入公司性质',2000);
  456. return
  457. }else if(this.params.turnover==''){
  458. this.$util.msg('请输入年营业额',2000);
  459. return
  460. }else if(this.params.firstShopType==''){
  461. this.$util.msg('请选择公司类型',2000);
  462. return
  463. }else if(this.params.firstShopType==1){
  464. if(this.params.secondShopType==""){
  465. this.$util.msg('请选择公司类型',2000);
  466. return
  467. }
  468. }else if(this.params.mainpro==''){
  469. this.$util.msg('请选择主营内容',2000);
  470. return
  471. }else if(this.params.businessScope==''){
  472. this.$util.msg('请选择经营内容',2000);
  473. return
  474. }else if(this.params.info==''){
  475. this.$util.msg('请填写公司介绍',2000);
  476. return
  477. }else if(this.params.productDesc==''){
  478. this.$util.msg('请填系列商品说明',2000);
  479. return
  480. }else if(this.params.socialCreditCode==''){
  481. this.$util.msg('请输入正确的统一社会信用代码',2000);
  482. return
  483. }else if(this.params.businessLicenseImage==''){
  484. this.$util.msg('请上传营业执照图片',2000);
  485. return
  486. }else if(this.params.logo==''){
  487. this.$util.msg('请上传公司logo',2000);
  488. return
  489. }else if(this.params.productionLicence==''){
  490. this.$util.msg('请上传生产许可证',2000);
  491. return
  492. }else if(this.params.hygienicLicense==''){
  493. this.$util.msg('请上传卫生许可证',2000);
  494. return
  495. }else if(this.params.taxLicense==''){
  496. this.$util.msg('请上传税务许可证',2000);
  497. return
  498. }else if(this.params.certificateHonor==''){
  499. this.$util.msg('请上传荣誉证书',2000);
  500. return
  501. }else if(this.params.productCertification==''){
  502. this.$util.msg('请上传产品证书',2000);
  503. return
  504. }else{
  505. this.ShopService.modifiedData(this.params).then(res=>{
  506. if(res.code === 0){
  507. this.$util.msg('修改成功',2000,true,'success')
  508. setTimeout(()=>{
  509. uni.navigateBack();
  510. },2000)
  511. } else {
  512. this.$util.msg(res.msg,2000);
  513. this.loginLoading = false;
  514. }
  515. })
  516. }
  517. },
  518. mainProAdd(){//添加主营内容
  519. if (this.mainProEdit.length>0) {
  520. let obj = {name:this.mainProEdit,value:`${this.mentuzCampList.length+1}`};
  521. if(this.checkedArray(this.mainProEdit,this.mentuzCampList)){
  522. this.$util.msg('主营内容已存在!',2000)
  523. }else {
  524. this.mentuzCampList.push(obj);
  525. }
  526. }
  527. },
  528. shopScopeAdd(){ //经营内容
  529. if (this.shopScopeEdit.length>0) {
  530. let obj = {name:this.shopScopeEdit,value:`${this.medicaCampList.length+1}`};
  531. if(this.checkedArray(this.shopScopeEdit,this.medicaCampList)){
  532. this.$util.msg('主营内容已存在!',2000)
  533. }else {
  534. this.medicaCampList.push(obj);
  535. }
  536. }
  537. },
  538. checkedArray(content,arr){//判断主营内容是否已存在
  539. console.log(content,arr)
  540. for(var i in arr){
  541. if(arr[i].name == content){
  542. return true;
  543. }
  544. }
  545. return false;
  546. },
  547. radioChange(e){
  548. this.params.firstShopType = e.target.value;
  549. if (e.target.value==1){
  550. this.isfirstShow = true;
  551. }else {
  552. this.isfirstShow = false;
  553. }
  554. console.log(e.target.value)
  555. },
  556. showViewerImageFn6(e) {//预览产品
  557. this.myPreviewImageFnlist(this.productImagesList)
  558. },
  559. showViewerImageFn5(e) {//预览荣誉
  560. this.myPreviewImageFnlist(this.HonorImagesList)
  561. },
  562. showViewerImageFn4(e) {//预览税务
  563. this.myPreviewImageFn(this.params.taxLicense)
  564. },
  565. showViewerImageFn3(e) {//预览卫生
  566. this.myPreviewImageFn(this.params.hygienicLicense)
  567. },
  568. showViewerImageFn2(e) {//预览生产
  569. this.myPreviewImageFn(this.params.productionLicence)
  570. },
  571. showViewerImageFn1(e) {//预览logo
  572. this.myPreviewImageFn(this.params.logo)
  573. },
  574. showViewerImageFn(e) {//预览营业执照
  575. this.myPreviewImageFn(this.params.businessLicenseImage)
  576. },
  577. myPreviewImageFnlist(arr){//多张预览
  578. this.isPreviewImage = true;
  579. uni.previewImage({
  580. urls: arr,
  581. current: 0
  582. })
  583. },
  584. myPreviewImageFn(url){//单张预览
  585. this.isPreviewImage = true
  586. let mentuzArray = []
  587. mentuzArray.push(url)
  588. uni.previewImage({
  589. urls: mentuzArray,
  590. current: 0
  591. });
  592. },
  593. uploadproductImageFn(event){//产品证书
  594. uploadFileImage().then(res =>{
  595. this.productImagesList.push(JSON.parse(res.data).data);
  596. this.params.productCertification =this.productImagesList.toString()+',';
  597. })
  598. },
  599. uploadHonorImageFn(event){//荣誉证书上传
  600. uploadFileImage().then(res =>{
  601. this.HonorImagesList.push(JSON.parse(res.data).data);
  602. this.params.certificateHonor =this.HonorImagesList.toString()+',';
  603. })
  604. },
  605. uploadlogoImageFn(event){//上传公司logo
  606. uploadFileImage().then(res =>{
  607. this.params.logo = JSON.parse(res.data).data;
  608. })
  609. },
  610. uploadproductionLicenceImageFn(event){//上传生产
  611. uploadFileImage().then(res =>{
  612. this.params.productionLicence = JSON.parse(res.data).data;
  613. })
  614. },
  615. uploadhygienicLicenseImageFn(event){//上传卫生
  616. uploadFileImage().then(res =>{
  617. this.params.hygienicLicense = JSON.parse(res.data).data;
  618. })
  619. },
  620. uploadtaxLicenseImageFn(event){//上传税务
  621. uploadFileImage().then(res =>{
  622. this.params.taxLicense = JSON.parse(res.data).data;
  623. })
  624. },
  625. uploadBusinessLicenseImageFn(event){//上传营业执照图片
  626. uploadFileImage().then(res =>{
  627. this.params.businessLicenseImage = JSON.parse(res.data).data;
  628. })
  629. },
  630. uploadzizhiImageFn(event){//上传医疗图片
  631. uploadFileImage().then(res =>{
  632. this.params.medicalPracticeLicenseImg1 = JSON.parse(res.data).data;
  633. })
  634. },
  635. removeGoodsImagesFn(index){//删除荣誉图片
  636. this.HonorImagesList.splice(index,1);
  637. this.params.certificateHonor = this.HonorImagesList.toString()+',';
  638. },
  639. removeproductImagesFn(index){//删除产品图片
  640. this.productImagesList.splice(index,1);
  641. this.params.productCertification = this.productImagesList.toString()+',';
  642. },
  643. deletaxImage(){//删除卫生
  644. this.params.taxLicense = '';
  645. },
  646. deletehygienicImage(){//删除卫生
  647. this.params.hygienicLicense = '';
  648. },
  649. deleteproducImage(){//删除生产
  650. this.params.productionLicence = '';
  651. },
  652. deletelogoImage(){//删除logo图片
  653. this.params.logo = '';
  654. },
  655. deleteBusinessImage(){//删除营业执照图片
  656. this.params.businessLicenseImage = '';
  657. },
  658. deleteMedicalImage(){//删除商品图片
  659. this.medicalPracticeLicenseImg1 = '';
  660. },
  661. secondypeRidio(item){
  662. this.params.secondShopType = item.value;
  663. if (item.value==3){
  664. this.issecondshow = true;
  665. }else {
  666. this.issecondshow = false;
  667. }
  668. },
  669. showMulLinkageThreePicker() {//三级地址联动
  670. this.isShowInput = true
  671. this.$refs.mpvueCityPicker.show()
  672. },
  673. onConfirm(e) {//获取选择的地址信息
  674. console.log('地址',e);
  675. this.addressData.address = e.name;
  676. this.addressData.townID = e.townCode;
  677. this.addressData.cityID = e.cityCode;
  678. this.addressData.provinceID = e.provinceCode;
  679. this.params.townID = this.addressData.townID;
  680. this.params.provinceID = this.addressData.provinceID;
  681. this.params.cityID = this.addressData.cityID;
  682. this.params.address = this.addressData.address;
  683. },
  684. onConfirmbrand(e){
  685. this.brandname = e.name;
  686. },
  687. },
  688. }
  689. </script>
  690. <style lang="scss">
  691. .row{
  692. line-height: 80rpx;
  693. background: #f7f7f7;
  694. padding: 0 24rpx;
  695. .info-title{
  696. font-size: $font-size-30;
  697. color: $text-color;
  698. font-weight: bold;
  699. }
  700. }
  701. .info-from{
  702. width: 702rpx;
  703. height: 90rpx;
  704. line-height: 90rpx;
  705. border-bottom: 2rpx solid #e1e1e1;
  706. margin: auto;
  707. position: relative;
  708. .label{
  709. width: 112rpx;
  710. text-align: left;
  711. font-size: $font-size-28;
  712. color: #666666;
  713. line-height: 90rpx;
  714. float: left;
  715. &.Code{
  716. width: 170rpx;
  717. }
  718. }
  719. .row-input{
  720. width: 520rpx;
  721. padding-left:10rpx;
  722. font-size: $font-size-28;
  723. color: $text-color;
  724. line-height: 90rpx;
  725. float: left;
  726. height: 90rpx;
  727. margin-left: 50rpx;
  728. &.Code{
  729. width: 470rpx;
  730. }
  731. .icon-xiayibu{
  732. position: absolute;
  733. right: 0;
  734. color: #b2b2b2;
  735. }
  736. .none{
  737. color: #b2b2b2;
  738. }
  739. }
  740. }
  741. .address-details{
  742. height: 146rpx;
  743. border-bottom: 2rpx solid #e1e1e1;
  744. width: 702rpx;
  745. margin: auto;
  746. font-size: $font-size-28;
  747. padding-top: 20rpx;
  748. }
  749. input[type="text"]::placeholder,textarea::placeholder {color: #b2b2b2;font-size: $font-size-28;}
  750. .info-email{
  751. color: #fea785;
  752. font-size: $font-size-20;
  753. padding-left: 24rpx ;
  754. }
  755. .ShopTyperadio{
  756. overflow: hidden;
  757. height: auto;
  758. border: 0;
  759. .radio{
  760. float: left;
  761. margin-right: 77rpx;
  762. .iconfont{
  763. margin-right: 10rpx;
  764. font-size: $font-size-36;
  765. }
  766. .icon-weixuanze{
  767. color: #b2b2b2;
  768. }
  769. .icon-yixuanze{
  770. color: $color-system;
  771. }
  772. }
  773. }
  774. .active{
  775. color: $color-system;
  776. }
  777. .secondTyperadio{
  778. overflow: hidden;
  779. height: auto;
  780. padding: 0 24rpx;
  781. margin-bottom: 20rpx;
  782. color: #999999;
  783. .radio{
  784. float: left;
  785. margin-right: 20rpx;
  786. .secondRadio{
  787. border: 2rpx solid #e1e1e1;
  788. padding: 0 30rpx;
  789. text-align: center;
  790. line-height: 42rpx;
  791. font-size: $font-size-26;
  792. border-radius: 21rpx;
  793. }
  794. }
  795. }
  796. .zizhi{
  797. .uploadImage{
  798. padding: 0 24rpx;
  799. &.list-image{
  800. overflow: hidden;
  801. display: flex;
  802. overflow-x: auto;
  803. padding-top: 20rpx;
  804. .formLine-file{
  805. float: left;
  806. }
  807. .form-upload-image{
  808. float: left;
  809. -webkit-flex-shrink: 0;
  810. flex-shrink: 0;
  811. position: relative;
  812. display: inline-block;
  813. margin: 0 15rpx;
  814. }
  815. }
  816. .form-upload-image{
  817. width: 256rpx;
  818. height:180rpx;
  819. position: relative;
  820. .upload-img{
  821. width: 100%;
  822. height: 100%;
  823. }
  824. .icon-shanchu1{
  825. position: absolute;
  826. top: -20rpx;
  827. right:-15rpx;
  828. color: #f94b4b;
  829. font-size: $font-size-36;
  830. }
  831. }
  832. .formLine-file{
  833. width: 270rpx;
  834. height: 200rpx;
  835. display: inline-block;
  836. .file-zizhi{
  837. background: url('https://admin-b.caimei365.com/userfiles/1/images/photo/2020/11/icon-zizhi.png') no-repeat;
  838. width: 270rpx;
  839. height: 200rpx;
  840. }
  841. .iconImage{
  842. width: 256rpx;
  843. height:180rpx;
  844. &.file-biss{
  845. background: url('https://admin-b.caimei365.com/userfiles/1/images/photo/2020/11/icon-business(1).png') no-repeat;
  846. }
  847. &.file-logo{
  848. background: url('https://admin-b.caimei365.com/userfiles/1/images/photo/2020/11/icon-logo.png') no-repeat;
  849. }
  850. &.file-produce{
  851. background: url('https://admin-b.caimei365.com/userfiles/1/images/photo/2020/11/icon-produce.png') no-repeat;
  852. }
  853. &.file-health{
  854. background: url('https://admin-b.caimei365.com/userfiles/1/images/photo/2020/11/icon-health.png') no-repeat;
  855. }
  856. &.file-tax{
  857. background: url('https://admin-b.caimei365.com/userfiles/1/images/photo/2020/11/icon-tax.png') no-repeat;
  858. }
  859. &.file-honor{
  860. background: url('https://admin-b.caimei365.com/userfiles/1/images/photo/2020/11/icon-honor.png') no-repeat;
  861. }
  862. &.file-product{
  863. background: url('https://admin-b.caimei365.com/userfiles/1/images/photo/2020/11/icon-product.png') no-repeat;
  864. }
  865. }
  866. }
  867. .form-upload-tips{
  868. display: inline-block;
  869. vertical-align: top;
  870. position: relative;
  871. .icon-wenhao{
  872. font-size: 41rpx;
  873. color:#1890f9 ;
  874. }
  875. .wen-tips{
  876. width: 360rpx;
  877. height: 64rpx;
  878. line-height: 64rpx;
  879. text-align: center;
  880. color: #FFF;
  881. font-size: 28rpx;
  882. background-color: #1890f9;
  883. position: absolute;
  884. bottom: -80rpx;
  885. left: -4rpx;
  886. border-radius: 2rpx;
  887. display: none ;
  888. }
  889. .wen-tips:before {
  890. content: '';
  891. width: 0px;
  892. height: 0px;
  893. border-width: 20rpx;
  894. border-style: solid;
  895. border-color: transparent transparent #1890f9 transparent;
  896. position: absolute;
  897. top: -35rpx;
  898. left: 10rpx;
  899. }
  900. .form-upload-tips:hover .wen-tips{display: block;}
  901. }
  902. }
  903. }
  904. .business{overflow: hidden;}
  905. .business-info{
  906. float: left;
  907. margin-left: 60rpx;
  908. width: 550rpx;
  909. }
  910. .info2-title{
  911. padding: 0 0 24rpx 24rpx;
  912. font-size: $font-size-28;
  913. color: #666666;
  914. &.zizhi-title{
  915. padding: 24rpx;
  916. &.hoor{padding: 24rpx 24rpx 0 24rpx;}
  917. }
  918. &.business-title{
  919. float: left;
  920. }
  921. }
  922. .addbusiness{
  923. margin: 20rpx 0;
  924. .other{
  925. width: 350rpx;
  926. height: 64rpx;
  927. border: 2rpx solid #b2b2b2;
  928. border-radius: 45rpx;
  929. text-align: center;
  930. line-height: 64rpx;
  931. padding-left: 10rpx;
  932. font-size: 28rpx;
  933. display: inline-block;
  934. }
  935. .button{
  936. width: 160rpx;
  937. height: 64rpx;
  938. text-align: center;
  939. line-height: 64rpx;
  940. display: inline-block;
  941. color: $color-system;
  942. background:#ffe6dc ;
  943. margin-left: 15rpx;
  944. border-radius: 45rpx;
  945. }
  946. }
  947. .row-group{
  948. .row-text{
  949. display: inline-block;
  950. font-size: 28rpx;
  951. color: #333333;
  952. }
  953. .row-input{
  954. width: 50%;
  955. display: inline-block;
  956. margin-bottom: 10rpx;
  957. }
  958. .diyBox{
  959. margin-bottom: 5px;
  960. // width: 33%;
  961. margin-right: 70rpx;
  962. display: inline-block;
  963. }
  964. }
  965. radio .wx-radio-input{
  966. border-radius: 50%;
  967. width: 36rpx;
  968. height: 36rpx;
  969. }
  970. checkbox .wx-checkbox-input{
  971. border-radius: 50%;
  972. width: 36rpx;
  973. height: 36rpx;
  974. }
  975. /* 选中后的 背景样式 */
  976. checkbox .wx-checkbox-input.wx-checkbox-input-checked{
  977. background: #E15616;
  978. }
  979. checkbox .wx-checkbox-input.wx-checkbox-input-checked::before{
  980. border-radius: 50%;
  981. border: 2rpx solid #e15616;
  982. width: 36rpx;
  983. height: 36rpx;
  984. line-height: 36rpx;
  985. text-align: center;
  986. font-size:24rpx;
  987. color:#fff;
  988. background: transparent;
  989. transform:translate(-50%, -50%) scale(1);
  990. -webkit-transform:translate(-50%, -50%) scale(1);
  991. }
  992. .info{
  993. margin: 20rpx 0;
  994. textarea{
  995. width: 680rpx;
  996. height: 200rpx;
  997. border: 2rpx solid #b2b2b2;
  998. border-radius: 6rpx;
  999. font-size: $font-size-28;
  1000. padding: 10rpx;
  1001. margin: auto;
  1002. line-height: 48rpx;
  1003. }
  1004. }
  1005. .wrap-Btn{
  1006. margin:100rpx auto;
  1007. .confirmBbtn{
  1008. width: 600rpx;
  1009. height: 90rpx;
  1010. line-height: 90rpx;
  1011. text-align: center;
  1012. color: #fff;
  1013. background:$btn-confirm;
  1014. border-radius: 45rpx;
  1015. }
  1016. }
  1017. </style>