shop-info.vue 42 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481
  1. <template>
  2. <view>
  3. <u-navbar title="店铺资料" :border-bottom="false"></u-navbar>
  4. <view v-show="!loading">
  5. <view class="title u-flex u-row-between u-col-center">
  6. <text v-if="step==1">请选择商家类型</text>
  7. <text v-else>完善商家资料</text>
  8. <text v-show="stepShow" @click="prevStep" class="u-font-24" style="color: #999">上一步</text>
  9. </view>
  10. <view class="card">
  11. <view class="margin-bottom-30" v-if="$isNotEmpty(failReason)">
  12. <u-alert-tips @close="failReason=null" type="error" :close-able="true" :show-icon="true"
  13. title="审核意见" :description="failReason"></u-alert-tips>
  14. </view>
  15. <u-form :model="form" :label-width="labelWidth" ref="uForm" :label-style="labelStyle">
  16. <view v-if="step==1" class="steps1" style="padding-bottom: 40rpx;">
  17. <view @click="clickType(1)" class="item u-border-bottom">
  18. <view class="flex">
  19. <view class="center">
  20. <image class="icon" src="../../static/icon/shop2.png" mode=""></image>
  21. </view>
  22. <view class="item-content">
  23. <text>小微商户</text>
  24. <text>小微商户,需提供店铺门头照及实景照,店主身份证件及银行账户</text>
  25. </view>
  26. </view>
  27. <view class="center">
  28. <image v-if="typeIndex==1" style="width: 40rpx;height: 40rpx;"
  29. src="../../static/icon/check.png" mode=""></image>
  30. <image v-else style="width: 40rpx;height: 40rpx;" src="../../static/icon/uncheck.png"
  31. mode=""></image>
  32. </view>
  33. </view>
  34. <view @click="clickType(0)" class="item ">
  35. <view class="flex">
  36. <view class="center">
  37. <image class="icon" src="../../static/icon/shop1.png" mode=""></image>
  38. </view>
  39. <view class="item-content">
  40. <text>企业商户/个体工商户</text>
  41. <text>企业商户,需提供营业执照,企业法人证件,企业对公结算银行账户,特殊行业还需提供生产经营许可证(例如:食品、化妆品、药品等)</text>
  42. </view>
  43. </view>
  44. <view class="center">
  45. <image v-if="typeIndex==0" style="width: 40rpx;height: 40rpx;"
  46. src="../../static/icon/check.png" mode=""></image>
  47. <image v-else style="width: 40rpx;height: 40rpx;" src="../../static/icon/uncheck.png"
  48. mode=""></image>
  49. </view>
  50. </view>
  51. </view>
  52. <view v-show="step==2">
  53. <view class="border">
  54. <u-form-item v-if="typeIndex==1" label="店铺全称" prop="name" label-position="top">
  55. <u-input :disabled="isEdit" :border="false" placeholder="比如:哈尔滨杨国福麻辣烫餐饮服务有限公司"
  56. v-model="auditForm.signName">
  57. </u-input>
  58. </u-form-item>
  59. </view>
  60. <view class="border">
  61. <u-form-item label="商户简称" prop="name">
  62. <u-input :border="false" placeholder="比如:杨国福麻辣烫(时尚天河2店)" v-model="form.name"></u-input>
  63. </u-form-item>
  64. </view>
  65. <view class="border">
  66. <u-form-item label="商户联系人手机号" prop="personTel" label-width="250">
  67. <u-input disabled placeholder="请输入联系方式" v-model="form.personTel" type="number">
  68. </u-input>
  69. </u-form-item>
  70. </view>
  71. <view class="border">
  72. <u-form-item label="所在商场" prop="phone">
  73. <u-input @click="mallShow=true" :select-open="mallShow" :border="false"
  74. placeholder="请选择所在商场(非必填项)" v-model="mallLabel" type="select"></u-input>
  75. <u-icon class="clear" color="#999" v-if="mallLabel" name="close-circle-fill"
  76. @click.stop="clear('mallLabel')"></u-icon>
  77. </u-form-item>
  78. </view>
  79. <view class="border">
  80. <u-form-item label="商户联系人邮箱" prop="email" label-width="240">
  81. <u-input :border="false" placeholder="请输入商户联系人邮箱" v-model="form.email"></u-input>
  82. </u-form-item>
  83. </view>
  84. <view class="border" v-if="form.mallId&&!$isEmpty(mallAreaList)">
  85. <u-form-item label="所在区域" prop="phone">
  86. <u-input @click="mallAreaShow=true" :border="false" placeholder="请选择所在区域"
  87. v-model="mallAreaLabel" type="select"></u-input>
  88. <u-icon class="clear" color="#999" v-if="mallAreaLabel" name="close-circle-fill"
  89. @click.stop="clear('mallAreaLabel')"></u-icon>
  90. </u-form-item>
  91. </view>
  92. <view class="border">
  93. <u-form-item label="店铺标语" prop="name">
  94. <u-input :border="false" placeholder="请输入店铺标语(非必填项)" v-model="form.slogan"></u-input>
  95. </u-form-item>
  96. </view>
  97. <view class="border">
  98. <u-form-item label-width="200" label="公司种类" left-icon="grid">
  99. <view class="flex justify-between " @click="chooseLabel">
  100. <view class="u-flex u-flex-wrap">
  101. <text v-if="form.labelKey" class="text-cut-1">{{form.labelKey}}</text>
  102. <text v-else style="color: #c0c4cc;">请选择</text>
  103. </view>
  104. <view>
  105. <u-icon name="arrow-right" color="#737373"></u-icon>
  106. </view>
  107. </view>
  108. </u-form-item>
  109. </view>
  110. <view class="border">
  111. <u-form-item label="所在地区" prop="address">
  112. <u-input :disabled="true" :border="false" placeholder="请选择所在地区" @click="regionShow=true"
  113. v-model="form.location"></u-input>
  114. </u-form-item>
  115. </view>
  116. <view class="border">
  117. <u-form-item label="店铺地址" label-position="top" prop="address">
  118. <u-input :border="false" disabled placeholder="请选择店铺地址" v-model="form.address">
  119. </u-input>
  120. <view slot="right">
  121. <u-button @click="chooseAddress" size="mini">获取地址</u-button>
  122. </view>
  123. </u-form-item>
  124. </view>
  125. <view class="border">
  126. <view style="padding: 30rpx 0 10rpx;">
  127. <text :style="{'color':'#6d6d6d'}">店铺封面</text>
  128. <text style="font-size: 24rpx;color: #999999;">(请上传店铺封面)</text>
  129. <mp-upload-img style="height: 120rpx;" ref="mpUploadCover" @click='uploadShopCover'
  130. col="4" :count="1"></mp-upload-img>
  131. </view>
  132. </view>
  133. <view class="border">
  134. <view style="padding: 30rpx 0 10rpx;">
  135. <text :style="{'color':'#6d6d6d'}">店铺实况</text>
  136. <text style="font-size: 24rpx;color: #999999;">(请依次上传门头、店内照片)</text>
  137. <mp-upload-img ref="mpUploadImg" @click='uploadShopPics' :count="2" col="4">
  138. </mp-upload-img>
  139. </view>
  140. </view>
  141. </view>
  142. <view v-show="merchantSubjectShow">
  143. <view class="border">
  144. <u-form-item label="上传营业执照" prop="businessLicense" label-position="top" label-width="180">
  145. <upload-img title="请上传营业执照" @click="chooseBizilicense"
  146. :model="auditForm.businessLicense" dataName="businessLicense"></upload-img>
  147. </u-form-item>
  148. </view>
  149. <view class="border">
  150. <u-form-item label="公司主体" prop="entity" label-width="210">
  151. <u-input :border="false" placeholder="请输入公司主体" v-model="auditForm.entity">
  152. </u-input>
  153. </u-form-item>
  154. </view>
  155. <view class="border">
  156. <u-form-item label="营业执照编号" prop="licenceNo" label-width="210">
  157. <u-input :border="false" placeholder="请填写营业执照编号" v-model="auditForm.licenceNo">
  158. </u-input>
  159. </u-form-item>
  160. </view>
  161. <view class="border">
  162. <u-form-item label="开户许可证编号" prop="licenceNo" label-width="210">
  163. <u-input :border="false" placeholder="请填写开户许可证编号"
  164. v-model="auditForm.openAccountLicenceNo">
  165. </u-input>
  166. </u-form-item>
  167. <u-form-item label="开户许可证照片" prop="openAccountLicenceUrl" label-position="top">
  168. <upload-img title="请上传开户许可证照片" @click="chooseImageAudit"
  169. :model="auditForm.openAccountLicenceUrl" dataName="openAccountLicenceUrl">
  170. </upload-img>
  171. </u-form-item>
  172. </view>
  173. <view class="border">
  174. <u-form-item label="手持营业执照在经营场所的照片" prop="handLicenceUrl" label-position="top">
  175. <upload-img title="请上传手持营业执照在经营场所的照片" @click="chooseImageAudit"
  176. :model="auditForm.handLicenceUrl" dataName="handLicenceUrl"></upload-img>
  177. </u-form-item>
  178. </view>
  179. </view>
  180. <view v-show="merchantCorporationShow">
  181. <view class="photo border">
  182. <text>请拿出商户法人有效二代身份证件准备拍摄</text>
  183. <view class="box">
  184. <ocr-navigator @onSuccess="idCardSuccess" certificateType="idCard" :opposite="false">
  185. <upload-img :width="520" :height="300" title="上传人像面照片"
  186. :model="auditForm.idCardFront" dataName="idCardFront" :enableImg="true">
  187. </upload-img>
  188. </ocr-navigator>
  189. </view>
  190. <view class="box" style="margin-top: 0;">
  191. <ocr-navigator @onSuccess="idCardSuccess" certificateType="idCard" :opposite="true">
  192. <upload-img :width="520" :height="300" title="上传国徽面照片"
  193. :model="auditForm.idCardContrary" dataName="idCardContrary" :enableImg="true"
  194. :bgImg="idCardContraryBgImg"></upload-img>
  195. </ocr-navigator>
  196. </view>
  197. <view style="margin: 30rpx 0;" class="tips">
  198. <text>拍摄时确保身份证边框完整,字体清晰,亮度均匀</text>
  199. </view>
  200. </view>
  201. <view class="border">
  202. <u-form-item label="商户法人姓名" prop="legalPerson" label-width="230">
  203. <u-input :border="false" placeholder="请输入公司法人姓名" v-model="auditForm.legalPerson">
  204. </u-input>
  205. </u-form-item>
  206. </view>
  207. <view class="border" v-if="typeIndex==1">
  208. <u-form-item label="商户法人手机号" prop="mobile" label-width="230">
  209. <u-input :border="false" placeholder="请输入商户法人手机号" v-model="auditForm.contactMobile">
  210. </u-input>
  211. </u-form-item>
  212. </view>
  213. <view class="border">
  214. <u-form-item label="商户法人身份证号码" prop="personIdCard" label-position="top">
  215. <u-input :border="false" placeholder="请输入商户法人身份证号码" v-model="auditForm.idCard">
  216. </u-input>
  217. </u-form-item>
  218. </view>
  219. <view class="border" v-if="typeIndex==0">
  220. <u-form-item label="商户联系人姓名" prop="personName" label-width="230">
  221. <u-input :disabled="isEdit" :border="false" placeholder="商户联系人姓名"
  222. v-model="form.personName">
  223. </u-input>
  224. </u-form-item>
  225. </view>
  226. <view class="border" v-if="typeIndex==0">
  227. <u-form-item label="商户联系人身份证号" prop="email" label-position="top">
  228. <u-input :border="false" placeholder="请输入商户联系人身份证号"
  229. v-model="auditForm.contactLicenceNo">
  230. </u-input>
  231. </u-form-item>
  232. </view>
  233. </view>
  234. <view v-show="settlementAccountShow" style="padding-bottom: 40rpx;">
  235. <view class="">
  236. <u-form-item :request="true" label="请填写结算银行账户号码" prop="bankCardNo" label-position="top">
  237. <u-input :border="false" placeholder="请填写结算银行账户号码" v-model="auditForm.bankCardNo">
  238. </u-input>
  239. <ocr-navigator slot="right" hover-class="none" @onSuccess="bankSuccess"
  240. certificateType="bankCard">
  241. <u-icon name="scan" size="42"></u-icon>
  242. </ocr-navigator>
  243. </u-form-item>
  244. <u-form-item :request="true" label="银行类型" label-position="top">
  245. <u-input :border="false" :select-open="bankCodeShow" type="select" placeholder="请选择银行类型"
  246. v-model="auditForm.bankCodeLabel" @click="bankCodeShow = true" />
  247. </u-form-item>
  248. <u-form-item :request="true" label="账户类型" label-position="top">
  249. <u-input type="select" placeholder="请选银行择账户类型" v-model="auditForm.bankAccountTypeLabel" @click="bankAccountTypeShow = true"/>
  250. <!-- <u-input :border="false" placeholder="请选银行择账户类型"
  251. v-model="auditForm.bankAccountTypeLabel" /> -->
  252. </u-form-item>
  253. </view>
  254. </view>
  255. </u-form>
  256. </view>
  257. <view v-if="step<totalStep" class="center flex-direction" style="margin: 100rpx 0 ;">
  258. <view @click="nextStep" class="btn cu-btn round" style="width:90%;height: 90rpx;font-size: 34rpx;">
  259. 下一步
  260. </view>
  261. </view>
  262. <view v-else class="center flex-direction margin-bottom-30" style="margin-top: 100rpx;">
  263. <view v-if="!isEdit" class=" margin-bottom-20 text-sm center ">
  264. <text style="color: #949494;">确认注册即代表已阅读并同意</text>
  265. <text style="color: #104DFF;" @click="protocol">《联兑通软件服务协议》</text>
  266. </view>
  267. <view @click="submit" class="btn cu-btn round" style="width:90%;height: 90rpx;font-size: 34rpx;">
  268. 提交资料
  269. </view>
  270. </view>
  271. </view>
  272. <!-- 商场 -->
  273. <u-popup border-radius="8" height="60%" mode="bottom" v-model="mallShow">
  274. <view class="fixed cu-bar search bg-white">
  275. <view class="search-form radius">
  276. <text class="cuIcon-search"></text>
  277. <u-input style="width: 90%;" v-model="mallKeyWord" type="text" :adjust-position="false"
  278. placeholder="请输入关键字搜索" confirm-type="search" />
  279. </view>
  280. </view>
  281. <scroll-view v-if="!$isEmpty(mallList)" style="padding-top: 110rpx;height: 100%;" :scroll-y="true">
  282. <view @click="selectMall(item)" hover-class="hoverClass"
  283. :class="{'solid-bottom':mallList.length!=(index+1)} " class="text-center padding-30"
  284. v-for="(item,index) in mallList" :key="index">
  285. <text>{{item.mallName}}</text>
  286. </view>
  287. <u-divider fontSize="24" v-if="mallList.length>=8" height="80">只显示8条数据,其余数据请搜索</u-divider>
  288. </scroll-view>
  289. <u-empty v-else name="search"></u-empty>
  290. </u-popup>
  291. <u-popup border-radius="8" height="60%" mode="bottom" v-model="bankCodeShow">
  292. <view class="fixed cu-bar search bg-white">
  293. <view class="search-form radius">
  294. <text class="cuIcon-search"></text>
  295. <u-input style="width: 100%;" v-model="bankKeyword" type="text" :adjust-position="false"
  296. placeholder="请输入关键字搜索" confirm-type="search" />
  297. </view>
  298. </view>
  299. <scroll-view v-if="!$isEmpty(bankCodeList)" style="padding-top: 110rpx;height: 100%;" :scroll-y="true">
  300. <view @click="bankTypeConfirm(item)" hover-class="hoverClass"
  301. :class="{'solid-bottom':bankCodeList.length!=(index+1)} " class="item text-center padding-30 "
  302. v-for="(item,index) in bankCodeList" :key="index">
  303. <text>{{item.label}}</text>
  304. </view>
  305. <u-divider fontSize="24" v-if="bankCodeList.length>=8" height="80">只显示8条数据,其余数据请搜索</u-divider>
  306. </scroll-view>
  307. <u-empty v-else name="search"></u-empty>
  308. </u-popup>
  309. <u-select confirm-color="#EF9944" v-model="mallAreaShow" label-name="name" value-name="id" mode="single-column"
  310. :list="mallAreaList" @confirm="mallAreaConfirm"></u-select>
  311. <!-- 地区 -->
  312. <!-- <u-picker confirm-color="#EF9944" @confirm="regionConfirm" v-model="regionShow" mode="region"></u-picker> -->
  313. <city-select :defaultRegion="defaultRegion" v-model="regionShow" @city-change="regionConfirm"></city-select>
  314. <!-- <u-select v-model="bankCodeShow" :list="bankCodeList" @confirm="bankTypeConfirm"></u-select> -->
  315. <u-select confirm-color="#EF9944" v-model="bankAccountTypeShow" :list="bankAccountTypeList"
  316. @confirm="bankAccountTypeConfirm">
  317. </u-select>
  318. <toast ref="toast"></toast>
  319. <loading ref="loading" type="3" />
  320. </view>
  321. </template>
  322. <script>
  323. import citySelect from './u-city-select.vue';
  324. import mpUploadImg from "@/components/mp-uploadImg/mp-uploadImg.vue"
  325. import uploadImg from "@/components/uploadimg/uploadImg.vue"
  326. export default {
  327. components: {
  328. citySelect,
  329. uploadImg,
  330. mpUploadImg
  331. },
  332. computed: {
  333. stepShow: {
  334. get() {
  335. if (this.isEdit) {
  336. if (this.step <= this.totalStep && this.step != 2) {
  337. return true
  338. }
  339. return false
  340. }
  341. if (this.step <= this.totalStep && this.step != 1) {
  342. return true
  343. } else {
  344. return false
  345. }
  346. }
  347. },
  348. settlementAccountShow: {
  349. get() {
  350. if (!this.needBankInfo) {
  351. return false
  352. }
  353. if (this.typeIndex == 0 && this.step == 5) {
  354. return true
  355. }
  356. if (this.typeIndex == 1 && this.step == 4) {
  357. return true
  358. }
  359. return false
  360. }
  361. },
  362. merchantCorporationShow: {
  363. get() {
  364. if (this.typeIndex == 0 && this.step == 4) {
  365. return true
  366. }
  367. if (this.typeIndex == 1 && this.step == 3) {
  368. return true
  369. }
  370. return false
  371. }
  372. },
  373. merchantSubjectShow: {
  374. get() {
  375. if (this.typeIndex == 0 && this.step == 3) {
  376. return true
  377. }
  378. return false
  379. }
  380. },
  381. },
  382. data() {
  383. return {
  384. labelStyle: {
  385. 'color': '#6d6d6d'
  386. },
  387. loading: true,
  388. typeIndex: 1,
  389. step:1,
  390. totalStep: 4,
  391. //银行类型
  392. bankKeyword: '',
  393. bankCodeShow: false,
  394. bankCodeList: [],
  395. //账户类型
  396. bankAccountTypeShow: false,
  397. bankAccountTypeList: [],
  398. //身份证正面背景图
  399. idCardContraryBgImg: 'https://guosen-bucket-ldt.obs.cn-south-1.myhuaweicloud.com:443/525724b4977d457eafea331f8595a675-6MM5CLdbBt1z7042ac12465719c764f2ca05a37ffee9.png',
  400. //上传图片
  401. imgList: [],
  402. title: '',
  403. labelWidth: 170,
  404. form: {
  405. /**
  406. * 主键
  407. */
  408. id: "",
  409. /**
  410. * 商户名称
  411. */
  412. name: "",
  413. /**
  414. * 代理人
  415. */
  416. agenter: "",
  417. /**
  418. * 代理人头像
  419. */
  420. agentAvatar: "",
  421. /**
  422. * 代理人姓名
  423. */
  424. agentName: "",
  425. /**
  426. * 商场id
  427. */
  428. mallId: "",
  429. /**
  430. * 商场label
  431. */
  432. mallLabel: "",
  433. /**
  434. * 负责人
  435. */
  436. personName: "",
  437. /**
  438. * 联系方式
  439. */
  440. personTel: "",
  441. /**
  442. * 区域编码
  443. */
  444. locationCode: "",
  445. /**
  446. * 所在地区
  447. */
  448. location: "",
  449. /**
  450. * 商户封面
  451. */
  452. cover: "",
  453. /**
  454. * 商户logo
  455. */
  456. logo: "",
  457. /**
  458. * 父标签ids,逗号分割
  459. */
  460. labelParentIds: "",
  461. /**
  462. * 商户标签json字符串
  463. */
  464. labelJson: "",
  465. /**
  466. * 商户标签key
  467. */
  468. labelKey: "",
  469. /**
  470. * 店铺图片
  471. */
  472. shopPic: "",
  473. /**
  474. * 邮箱
  475. */
  476. email: "",
  477. /**
  478. * 标语,逗号分割
  479. */
  480. slogan: "",
  481. /**
  482. * 审核状态
  483. */
  484. auditStatus: "",
  485. /**
  486. * 审核意见
  487. */
  488. auditAdvice: "",
  489. /**
  490. * 经度
  491. */
  492. longitude: "",
  493. /**
  494. * 纬度
  495. */
  496. latitude: "",
  497. /**
  498. * 详细地址
  499. */
  500. address: "",
  501. /**
  502. * 易宝商户编号
  503. */
  504. merchantNo: "",
  505. /**
  506. * openId
  507. */
  508. openId: "",
  509. },
  510. //审核表单
  511. auditForm: {
  512. /**
  513. * 主键
  514. */
  515. id: "",
  516. /**
  517. * 流程定义主键
  518. */
  519. processDefinitionId: "",
  520. /**
  521. * 流程实例主键
  522. */
  523. processInstanceId: "",
  524. /**
  525. * 主体信息
  526. */
  527. entity: "",
  528. /**
  529. * 商场或商店ID
  530. */
  531. entityId: "",
  532. /**
  533. * 身份证号
  534. */
  535. idCard: "",
  536. /**
  537. * 商户名称
  538. */
  539. shopName: "",
  540. /**
  541. * 商户logo
  542. */
  543. shopLogo: "",
  544. /**
  545. * 审核状态
  546. */
  547. auditStatus: "",
  548. /**
  549. * 商户申请号
  550. */
  551. requestNo: "",
  552. /**
  553. * 入网商户的业务角色
  554. */
  555. businessRole: "",
  556. /**
  557. * 商户签约类型
  558. */
  559. signType: "ENTERPRISE",
  560. /**
  561. * 企业名称【商户全称】
  562. */
  563. enterpriseName: "",
  564. /**
  565. * 组成形式
  566. */
  567. typeOfOrganization: "",
  568. /**
  569. * 企业类型
  570. */
  571. typeOfEnterprise: "MINICRO",
  572. /**
  573. * 经营范围
  574. */
  575. businessScope: "",
  576. /**
  577. * 注册资本
  578. */
  579. registeredCapital: "",
  580. /**
  581. * 实收资本
  582. */
  583. paidInCapital: "",
  584. /**
  585. * 营业期限
  586. */
  587. validPeriod: "",
  588. /**
  589. * 成立日期
  590. */
  591. registeredDate: "",
  592. /**
  593. * 注册号
  594. */
  595. regNum: "",
  596. /**
  597. * 商户证件编号
  598. */
  599. licenceNo: "",
  600. /**
  601. * 营业执照【易宝:商户证件照片】
  602. */
  603. businessLicense: "",
  604. /**
  605. * 商户签约名称
  606. */
  607. signName: "",
  608. /**
  609. * 商户简称
  610. */
  611. shortName: "",
  612. /**
  613. * 开户许可证编号
  614. */
  615. openAccountLicenceNo: "",
  616. /**
  617. * 开户许可证照片
  618. */
  619. openAccountLicenceUrl: "",
  620. /**
  621. * 手持营业执照在经营场所的照片
  622. */
  623. handLicenceUrl: "",
  624. /**
  625. * 法人姓名【legalName】
  626. */
  627. legalPerson: "",
  628. /**
  629. * 法人证件类型
  630. */
  631. legalLicenceType: "ID_CARD",
  632. /**
  633. * 法人证件号码
  634. */
  635. legalLicenceNo: "",
  636. /**
  637. * 身份证-正面【legalLicenceFrontUrl】
  638. */
  639. idCardFront: "",
  640. /**
  641. * 身份证-反面【legalLicenceBackUrl】
  642. */
  643. idCardContrary: "",
  644. /**
  645. * 性别
  646. */
  647. gender: "",
  648. /**
  649. * 住址
  650. */
  651. addr: "",
  652. /**
  653. * 民族
  654. */
  655. nationality: "",
  656. /**
  657. * 有效日期
  658. */
  659. validDate: "",
  660. /**
  661. * 商户联系人姓名
  662. */
  663. contactName: "",
  664. /**
  665. * 商户联系人证件号码
  666. */
  667. contactLicenceNo: "",
  668. /**
  669. * 商户联系人手机号
  670. */
  671. contactMobile: "",
  672. /**
  673. * 商户联系人邮箱
  674. */
  675. contactEmail: "",
  676. /**
  677. * 客服电话
  678. */
  679. servicePhone: "",
  680. /**
  681. * 商户实际经营地所在省
  682. */
  683. province: "",
  684. /**
  685. * 商户实际经营地所在市
  686. */
  687. city: "",
  688. /**
  689. * 商户实际经营地所在区
  690. */
  691. district: "",
  692. /**
  693. * 商户实际经营详细地址
  694. */
  695. address: "",
  696. /**
  697. * 结算方向
  698. */
  699. settlementDirection: "",
  700. /**
  701. * 银行账户类型
  702. */
  703. bankAccountType: "",
  704. /**
  705. * 银行账户类型label
  706. */
  707. bankAccountTypeLabel: "",
  708. /**
  709. * 银行账户号码
  710. */
  711. bankCardNo: "",
  712. /**
  713. * 银行账户开户总行编码
  714. */
  715. bankCode: "",
  716. /**
  717. * 银行账户开户总行编码label
  718. */
  719. bankCodeLabel: "",
  720. /**
  721. * 注册地址
  722. */
  723. officeAddress: ""
  724. },
  725. //OCR营业执照
  726. OCRBizilicenseInfo: {},
  727. //OCR身份证
  728. OCRBiziIdCardInfo: {},
  729. //商场
  730. mallShow: false,
  731. mallKeyWord: '',
  732. mallList: [],
  733. mallLabel: '',
  734. //区域
  735. mallAreaShow: false,
  736. mallAreaList: [],
  737. mallAreaLabel: '',
  738. //所在地区
  739. regionShow: false,
  740. defaultRegion: [],
  741. //门店地址
  742. shopAddress: '',
  743. needBankInfo: true,
  744. //编辑还是修改
  745. isEdit: false,
  746. //审核失败,重新申请
  747. isFail: false,
  748. shopId: "",
  749. flowDetail: {},
  750. failReason: "",
  751. flowList: []
  752. }
  753. },
  754. watch: {
  755. mallKeyWord() {
  756. let that = this
  757. //节流函数
  758. if (this.timer) {
  759. clearTimeout(this.timer)
  760. }
  761. this.timer = setTimeout(() => {
  762. this.mallList = []
  763. that.fetchMallList()
  764. }, 500)
  765. },
  766. bankKeyword() {
  767. console.log("1111");
  768. let that = this
  769. //节流函数
  770. if (this.timer) {
  771. clearTimeout(this.timer)
  772. }
  773. this.timer = setTimeout(() => {
  774. this.bankCodeList = []
  775. that.getBankType()
  776. }, 500)
  777. },
  778. imgList() {
  779. if (!this.$isEmpty(this.imgList)) {
  780. this.form.shopPic = this.imgList.join(",")
  781. }
  782. },
  783. },
  784. onShow() {
  785. uni.hideLoading()
  786. },
  787. async onLoad(options) {
  788. this.$refs.loading.showLoading()
  789. this.form.personTel = this.$cache.get('phone')
  790. this.auditForm.contactMobile = this.form.personTel
  791. //监听从chooseLable页面返回的数据
  792. uni.$on('labelData', (labelData) => {
  793. this.form.labelJson = labelData.labelJson
  794. this.form.labelKey = labelData.labelKey
  795. this.form.labelParentIds = labelData.labelParentIds
  796. this.$forceUpdate()
  797. })
  798. if (options.edit) {
  799. //修改资料
  800. this.isEdit = true
  801. this.step = 2
  802. await this.fetchShopDetail(this.vuex_shopId)
  803. await this.fetchAuditDetail(this.vuex_shopId)
  804. } else if (options.isFail) {
  805. //审核失败,重新申请
  806. this.isFail = true
  807. this.shopId = options.shopId
  808. await this.fetchShopDetail(this.shopId)
  809. await this.fetchAuditDetail(this.shopId)
  810. } else {
  811. this.initCacheData()
  812. //新增数据时才跑流程
  813. this.getProcessDefinitionId()
  814. }
  815. await this.initDict()
  816. await this.fetchMallList()
  817. this.$refs.loading.hide()
  818. this.loading = false
  819. },
  820. methods: {
  821. clickType(index) {
  822. this.typeIndex = index
  823. if (this.typeIndex == 0) {
  824. //企业
  825. this.auditForm.bankAccountType = 'PUBLIC_CARD'
  826. this.auditForm.bankAccountTypeLabel = '对公卡'
  827. }
  828. if (this.typeIndex == 1) {
  829. //小微企业
  830. this.auditForm.bankAccountType = 'DEBIT_CARD'
  831. this.auditForm.bankAccountTypeLabel = '借记卡'
  832. }
  833. },
  834. async getHistoryFlowList() {
  835. let processInstanceId = this.auditForm.processInstanceId
  836. this.flowList = (await this.$api.flow.historyFlowList({
  837. processInstanceId
  838. })).data
  839. let failList = this.flowList.filter(item => !item.pass && item.comment)
  840. if (this.$isNotEmpty(failList)) {
  841. let index = failList.length - 1
  842. this.failReason = failList[index].comment
  843. }
  844. },
  845. getTaskId() {
  846. let params = {
  847. assignee: '$INITIATOR',
  848. processInstanceId: this.auditForm.processInstanceId
  849. }
  850. this.$api.flow.getTaskId(params).then(res => {
  851. this.flowDetail = res.data.records[0]
  852. })
  853. },
  854. initCacheData() {
  855. let shopAuditInfo = this.$cache.get('shopAuditInfo')
  856. if (shopAuditInfo) {
  857. this.form = shopAuditInfo.shop
  858. this.auditForm = shopAuditInfo.audit
  859. this.mallLabel = this.form.mallLabel
  860. this.imgList = this.$isNotEmpty(this.form.shopPic) ? this.form.shopPic.split(",") : []
  861. this.$refs.mpUploadCover.changeImgList([this.form.cover])
  862. this.$refs.mpUploadImg.changeImgList(this.imgList)
  863. }
  864. },
  865. async getOpenId() {
  866. if (this.$isEmpty(this.form.openId)) {
  867. let code = (await this.$mpi.wxLogin()).code
  868. let params = {
  869. code,
  870. type: "SHOP"
  871. }
  872. let res = await this.$api.wxApp.getOpenId(params)
  873. this.form.openId = res.data.openid
  874. }
  875. },
  876. //获取商户审核流程id
  877. getProcessDefinitionId() {
  878. let params = {
  879. category: 'flow_3',
  880. mode: 1
  881. }
  882. this.$api.flow.getProcessDefinitionId(params).then(res => {
  883. this.auditForm.processDefinitionId = res.data.records[0].id
  884. if (this.$isEmpty(this.auditForm.processDefinitionId)) {
  885. this.$dialog.showModalAndBack("系统错误,获取流程主键失败")
  886. return
  887. }
  888. })
  889. },
  890. //所在地区
  891. regionConfirm(e) {
  892. this.form.location = e.location
  893. this.form.locationCode = e.locationCode
  894. // this.form.location = e.province.label + "-" + e.city.label + "-" + e.area.label
  895. // this.form.locationCode = e.province.value + "0000," + e.city.value + "00," + e.area.value
  896. },
  897. //具体地址
  898. chooseAddress() {
  899. this.$mpi.chooseLocation().then(res => {
  900. this.form.address = res.address
  901. this.form.longitude = res.longitude
  902. this.form.latitude = res.latitude
  903. })
  904. },
  905. //选择标签
  906. chooseLabel() {
  907. uni.navigateTo({
  908. url: "../chooseLable/chooseLable?label=" + this.form.labelJson
  909. })
  910. },
  911. uploadShopCover(data) {
  912. this.form.cover = data[0]
  913. this.$refs.mpUploadCover.changeImgList(data)
  914. },
  915. uploadShopPics(data) {
  916. this.imgList = data
  917. this.$refs.mpUploadImg.changeImgList(this.imgList)
  918. },
  919. bankSuccess(e) {
  920. console.log(e);
  921. this.auditForm.bankCardNo = e.detail.number.text
  922. },
  923. async chooseBank() {
  924. let image = (await this.$mpi.chooseImage())[0]
  925. this.$api.ocr.bank(image).then(res => {
  926. console.log(res);
  927. })
  928. console.log(res);
  929. },
  930. async fetchShopDetail(id) {
  931. let params = {
  932. id
  933. }
  934. let res = await this.$api.shop.detail(params)
  935. this.$util.objectCopy(this.form, res.data)
  936. if (this.$isNotEmpty(res.data.mallId) && res.data.mallId != -1) {
  937. this.mallLabel = (await this.$api.mall.detail({
  938. id: res.data.mallId
  939. })).data.mallName
  940. }
  941. console.log(this.form.location.split('-'));
  942. this.defaultRegion = this.form.location.split('-')
  943. this.imgList = this.$isNotEmpty(this.form.shopPic) ? this.form.shopPic.split(",") : []
  944. this.$refs.mpUploadCover.changeImgList([this.form.cover])
  945. this.$refs.mpUploadImg.changeImgList(this.imgList)
  946. },
  947. async fetchAuditDetail(id) {
  948. let params = {
  949. entityId: id
  950. }
  951. let res = await this.$api.audit.detail(params)
  952. this.$util.objectCopy(this.auditForm, res.data)
  953. if (this.auditForm.typeOfEnterprise == 'ENTERPRISE') {
  954. this.typeIndex=0
  955. }
  956. if (this.isFail) {
  957. //获取流程历史
  958. this.getHistoryFlowList()
  959. this.getTaskId()
  960. }
  961. },
  962. prevStep() {
  963. this.step--
  964. },
  965. nextStep() {
  966. if (this.step == 1) {
  967. if (this.typeIndex == 0) {
  968. this.auditForm.typeOfEnterprise = 'ENTERPRISE'
  969. //企业
  970. if (this.needBankInfo) {
  971. this.totalStep = 5
  972. } else {
  973. this.totalStep = 4
  974. }
  975. }
  976. if (this.typeIndex == 1) {
  977. //小微企业
  978. this.auditForm.typeOfEnterprise = 'MINICRO'
  979. if (this.needBankInfo) {
  980. this.totalStep = 4
  981. } else {
  982. this.totalStep = 3
  983. }
  984. }
  985. }
  986. if (this.step == 2) {
  987. if (this.$isEmpty(this.auditForm.signName) && this.typeIndex == 1) {
  988. this.$refs.toast.info('请输入店铺全称')
  989. return
  990. }
  991. if (this.$isEmpty(this.form.name)) {
  992. this.$refs.toast.info('请输入店铺简称')
  993. return
  994. }
  995. if (this.$isEmpty(this.form.personTel)) {
  996. this.$refs.toast.info('请输入商户联系人手机号')
  997. return
  998. }
  999. if (this.$isEmpty(this.form.email)) {
  1000. this.$refs.toast.info('请输入商户联系人邮箱')
  1001. return
  1002. }
  1003. if (this.$isEmpty(this.form.labelKey)) {
  1004. this.$refs.toast.info('请选择公司种类')
  1005. return
  1006. }
  1007. if (this.$isEmpty(this.form.location)) {
  1008. this.$refs.toast.info('请选择所在地区')
  1009. return
  1010. }
  1011. if (this.$isEmpty(this.form.address)) {
  1012. this.$refs.toast.info('请选择具体地址')
  1013. return
  1014. }
  1015. if (this.$isEmpty(this.form.cover)) {
  1016. this.$refs.toast.info('请上传店铺封面')
  1017. return
  1018. }
  1019. if (this.$isEmpty(this.form.shopPic)) {
  1020. this.$refs.toast.info('请上传店铺实况')
  1021. return
  1022. }
  1023. if (this.imgList.length < 2) {
  1024. this.$refs.toast.info('请依次上传门头,店内照片')
  1025. return
  1026. }
  1027. }
  1028. if (this.step == 3 && this.typeIndex == 0) {
  1029. if (this.$isEmpty(this.auditForm.businessLicense)) {
  1030. this.$refs.toast.info('请上传营业执照')
  1031. return
  1032. }
  1033. if (this.$isEmpty(this.auditForm.openAccountLicenceNo)) {
  1034. this.$refs.toast.info('请填写开户许可证编号')
  1035. return
  1036. }
  1037. if (this.$isEmpty(this.auditForm.openAccountLicenceUrl)) {
  1038. this.$refs.toast.info('请上传开户许可证照片')
  1039. return
  1040. }
  1041. if (this.$isEmpty(this.auditForm.openAccountLicenceUrl)) {
  1042. this.$refs.toast.info('请上传手持营业执照在经营场所的照片')
  1043. return
  1044. }
  1045. }
  1046. if (this.step > 0 && this.step < this.totalStep) {
  1047. this.step++
  1048. }
  1049. },
  1050. clear(t) {
  1051. if (t == 'mallAreaLabel') {
  1052. this.mallAreaLabel = ''
  1053. } else if (t == 'mallLabel') {
  1054. this.mallLabel = ''
  1055. this.form.mallId = null
  1056. }
  1057. },
  1058. async chooseImageShop(name) {
  1059. let res = await this.$mpi.chooseImage()
  1060. this.$api.uploadFile(res[0]).then(res => {
  1061. this.form[name] = res.data.link
  1062. })
  1063. },
  1064. async chooseImageAudit(name) {
  1065. if (this.isEdit) {
  1066. this.$refs.toast.info('不可修改')
  1067. return
  1068. }
  1069. let res = await this.$mpi.chooseImage()
  1070. this.$api.uploadFile(res[0]).then(res => {
  1071. this.auditForm[name] = res.data.link
  1072. })
  1073. },
  1074. idCardSuccess(e) {
  1075. console.log(e, "e********");
  1076. let data = e.detail
  1077. console.log(data, "data******");
  1078. if (data.type == 0) {
  1079. //身份证正面
  1080. this.auditForm.addr = data.address.text
  1081. this.auditForm.gender = data.gender.text
  1082. this.auditForm.idCard = data.id.text
  1083. this.auditForm.nationality = data.nationality.text
  1084. this.auditForm.name = data.name.text
  1085. this.auditForm.legalPerson = data.name.text
  1086. this.form.personName = data.name.text
  1087. this.auditForm.contactLicenceNo = data.id.text
  1088. } else {
  1089. this.auditForm.validDate = data.valid_date.text
  1090. }
  1091. this.$api.uploadFile(data.image_path).then(res => {
  1092. if (data.type == 0) {
  1093. //正面
  1094. this.auditForm.idCardFront = res.data.link
  1095. } else {
  1096. //反面
  1097. this.auditForm.idCardContrary = res.data.link
  1098. }
  1099. })
  1100. },
  1101. async chooseIdCard(name) {
  1102. if (this.isEdit) {
  1103. this.$refs.toast.info('不可修改')
  1104. return
  1105. }
  1106. let image = (await this.$mpi.chooseImage())[0]
  1107. this.$dialog.showLoading('证件上传中...')
  1108. this.$api.ocr.idcard(image).then(res => {
  1109. if (res.data[0].errmsg != "ok") {
  1110. this.$refs.toast.error('非法证件照')
  1111. return
  1112. }
  1113. if (name == 'idCardFront') {
  1114. //上传身份证正面照解析数据
  1115. this.OCRBiziIdCardInfo = res.data[0]
  1116. this.OCRBiziIdCardInfo.idCard = this.OCRBiziIdCardInfo.id
  1117. //删除OCRBiziIdCardInfo 的id防止将id值覆盖调auditForm的id值
  1118. delete this.OCRBiziIdCardInfo.id
  1119. delete this.OCRBiziIdCardInfo.validDate
  1120. Object.assign(this.auditForm, this.OCRBiziIdCardInfo)
  1121. this.auditForm.legalPerson = this.OCRBiziIdCardInfo.name
  1122. this.form.personName = this.OCRBiziIdCardInfo.name
  1123. this.auditForm.contactLicenceNo = this.OCRBiziIdCardInfo.idCard
  1124. } else {
  1125. this.OCRBiziIdCardInfo.validDate = res.data[0].validDate
  1126. this.auditForm.validDate = res.data[0].validDate
  1127. }
  1128. this.auditForm[name] = res.data[1].link
  1129. uni.hideLoading()
  1130. }).catch(err => {
  1131. uni.hideLoading()
  1132. })
  1133. },
  1134. async chooseBizilicense() {
  1135. if (this.isEdit) {
  1136. this.$refs.toast.info('不可修改')
  1137. return
  1138. }
  1139. let image = (await this.$mpi.chooseImage())[0]
  1140. this.$dialog.showLoading('证件上传中...')
  1141. this.$api.ocr.bizilicense(image).then(res => {
  1142. if (res.data[0].errmsg != "ok") {
  1143. this.$refs.toast.error('非法证件照')
  1144. return
  1145. }
  1146. this.OCRBizilicenseInfo = res.data[0]
  1147. delete this.OCRBizilicenseInfo.typeOfEnterprise
  1148. Object.assign(this.auditForm, this.OCRBizilicenseInfo)
  1149. this.auditForm.businessLicense = res.data[1].link
  1150. this.auditForm.licenceNo = this.OCRBizilicenseInfo.serial
  1151. this.auditForm.officeAddress = this.OCRBizilicenseInfo.address
  1152. this.auditForm.entity = this.OCRBizilicenseInfo.enterpriseName
  1153. uni.hideLoading()
  1154. }).catch(err => {
  1155. uni.hideLoading()
  1156. })
  1157. },
  1158. async fetchMallList() {
  1159. let params = {
  1160. name: this.mallKeyWord,
  1161. auditStatus: 'PASS',
  1162. size: 20
  1163. }
  1164. let res = await this.$api.mall.list(params)
  1165. this.mallList = res.data.records
  1166. },
  1167. fetchMallAreaList() {
  1168. this.$api.mall.getMallAreaByMallId(this.form.mallId).then(res => {
  1169. this.mallAreaList = res.data
  1170. })
  1171. },
  1172. selectMall(item) {
  1173. this.mallLabel = item.mallName
  1174. this.form.mallId = item.id
  1175. this.form.mallLabel = this.mallLabel
  1176. this.mallShow = false
  1177. // this.fetchMallAreaList()
  1178. },
  1179. mallAreaConfirm(e) {
  1180. this.mallAreaLabel = e[0].label
  1181. this.form.mallAreaId = e[0].value
  1182. },
  1183. async submit() {
  1184. let _this = this
  1185. if (this.$isEmpty(this.auditForm.idCardFront)) {
  1186. this.$refs.toast.info('请上传身份证人像面')
  1187. return
  1188. }
  1189. if (this.$isEmpty(this.auditForm.idCardContrary)) {
  1190. this.$refs.toast.info('请上传身份证国徽面')
  1191. return
  1192. }
  1193. if (this.$isEmpty(this.form.personName)) {
  1194. this.$refs.toast.info('请填写商户联系人姓名')
  1195. return
  1196. }
  1197. if (this.$isEmpty(this.auditForm.contactLicenceNo)) {
  1198. this.$refs.toast.info('请填写商户联系人身份证号')
  1199. return
  1200. }
  1201. if (this.$isEmpty(this.auditForm.bankCardNo)) {
  1202. this.$refs.toast.info('请填写结算银行账户号码')
  1203. return
  1204. }
  1205. if (this.$cache.get('promotionCode')) {
  1206. this.form.agenter = this.$cache.get('promotionCode')
  1207. }
  1208. this.$refs.loading.showLoading('资料提交中..')
  1209. this.initAuditInfo()
  1210. await this.getOpenId()
  1211. let params = {
  1212. shop: this.form,
  1213. audit: this.auditForm,
  1214. }
  1215. this.$cache.put('shopAuditInfo', params)
  1216. this.$api.shop.submitAudit(params).then(res => {
  1217. setTimeout(() => {
  1218. if (res.success == true) {
  1219. _this.$cache.remove('shopAuditInfo')
  1220. _this.doReSubmit()
  1221. _this.jump()
  1222. }
  1223. _this.$refs.loading.hide()
  1224. }, 300)
  1225. }).catch(err => {
  1226. setTimeout(() => {
  1227. _this.$refs.loading.hide()
  1228. }, 300)
  1229. })
  1230. },
  1231. jump() {
  1232. let jumpData = {
  1233. path: '/pages/index/index',
  1234. title: this.isEdit ? '资料修改成功' : '资料提交成功,请耐心等待审核'
  1235. }
  1236. uni.redirectTo({
  1237. url: '/pages/login/submit-success?params=' + JSON.stringify(jumpData)
  1238. })
  1239. },
  1240. protocol() {
  1241. uni.navigateTo({
  1242. url: "/pages/webView/webView?url=" + this.$global.shopRegister
  1243. })
  1244. },
  1245. doReSubmit() {
  1246. if (this.isFail) {
  1247. this.flowDetail.comment = '重新修改并提交'
  1248. this.flowDetail.flag = 'ok'
  1249. this.flowDetail.variables.pass = true
  1250. this.flowDetail.variables.applyPass = false
  1251. this.$api.flow.flowAuditSubmit(this.flowDetail)
  1252. }
  1253. },
  1254. //获取推荐人的信息
  1255. async initAgenterInfo() {
  1256. if (this.$cache.get('promotionCode')) {
  1257. let agenter = this.$cache.get('promotionCode')
  1258. let records = (await this.$api.loginUser.list({
  1259. id: agenter
  1260. })).data.records
  1261. let user = records[0]
  1262. this.form.agenter = this.$isNotEmpty(user) ? user.id : ""
  1263. this.form.agentAvatar = user.avatar
  1264. this.form.agentName = user.nickName
  1265. }
  1266. },
  1267. //经营地址
  1268. initAuditInfo() {
  1269. let locationCode = this.form.locationCode.split(",")
  1270. this.auditForm.province = locationCode[0],
  1271. this.auditForm.city = locationCode[1],
  1272. this.auditForm.district = locationCode[2],
  1273. this.auditForm.address = this.form.address
  1274. this.auditForm.contactEmail = this.form.email
  1275. this.auditForm.shopName = this.form.name
  1276. this.auditForm.shopLogo = this.form.cover
  1277. this.auditForm.contactMobile = this.form.personTel
  1278. this.auditForm.contactName = this.form.personName
  1279. this.auditForm.shortName = this.form.name
  1280. if (this.$isEmpty(this.auditForm.signName)) {
  1281. this.auditForm.signName = this.auditForm.enterpriseName
  1282. }
  1283. this.auditForm.legalLicenceNo = this.auditForm.idCard
  1284. },
  1285. //字典 begin
  1286. async initDict() {
  1287. await this.getBankType()
  1288. await this.getBankAccountType()
  1289. },
  1290. async getBankType() {
  1291. let params = {
  1292. code: 'bank_type',
  1293. size: 9
  1294. }
  1295. if (this.$isNotEmpty(this.bankKeyword)) {
  1296. params.keyword = this.bankKeyword
  1297. }
  1298. let res = await this.$api.dict.dictionaryPage(params)
  1299. let list = res.data.records
  1300. if (list[0].parentId == '0') {
  1301. list.shift()
  1302. }
  1303. list.forEach(item => {
  1304. let obj = {
  1305. label: JSON.parse(item.dictValue).name,
  1306. value: item.dictKey
  1307. }
  1308. this.bankCodeList.push(obj)
  1309. })
  1310. if (this.$isEmpty(this.auditForm.bankCodeLabel) && this.$isEmpty(this.auditForm.bankCode)) {
  1311. this.auditForm.bankCodeLabel = this.bankCodeList[0].label
  1312. this.auditForm.bankCode = this.bankCodeList[0].value
  1313. }
  1314. },
  1315. async getBankAccountType() {
  1316. let res = await this.$api.dict.list({
  1317. code: 'bank_account_type'
  1318. })
  1319. res.data.forEach(item => {
  1320. let obj = {
  1321. label: item.dictValue,
  1322. value: item.dictKey
  1323. }
  1324. this.bankAccountTypeList.push(obj)
  1325. this.auditForm.bankAccountType = this.bankAccountTypeList[0].value
  1326. this.auditForm.bankAccountTypeLabel = this.bankAccountTypeList[0].label
  1327. })
  1328. },
  1329. //字典 end
  1330. bankTypeConfirm(e) {
  1331. this.bankCodeShow = false
  1332. this.auditForm.bankCodeLabel = e.label
  1333. this.auditForm.bankCode = e.value
  1334. },
  1335. bankAccountTypeConfirm(e) {
  1336. this.auditForm.bankAccountTypeLabel = e[0].label
  1337. this.auditForm.bankAccountType = e[0].value
  1338. },
  1339. }
  1340. }
  1341. </script>
  1342. <style lang="scss" scoped>
  1343. .clear {
  1344. position: absolute;
  1345. right: 50rpx;
  1346. top: 50%;
  1347. transform: translateY(-50%);
  1348. z-index: 99;
  1349. }
  1350. .title {
  1351. padding: 30rpx 40rpx;
  1352. font-size: 34rpx;
  1353. color: #000;
  1354. font-weight: 800;
  1355. }
  1356. .bg {
  1357. height: 220rpx;
  1358. background-image: linear-gradient(#D18C42, #C99864);
  1359. border-radius: 0 0 30% 30%;
  1360. }
  1361. .btn {
  1362. background-color: #EF9944;
  1363. color: #FFFFFF;
  1364. }
  1365. .border {
  1366. // border-bottom: 1rpx solid #F4F4F4;
  1367. }
  1368. .tips {
  1369. color: $color;
  1370. text-align: right;
  1371. margin-top: 10rpx;
  1372. font-size: 22rpx;
  1373. }
  1374. .card {
  1375. background-color: #FFFFFF;
  1376. padding: 40rpx;
  1377. .photo {
  1378. font-size: 26rpx;
  1379. padding-top: 20rpx;
  1380. .box {
  1381. display: flex;
  1382. justify-content: center;
  1383. align-items: center;
  1384. margin-top: 30rpx;
  1385. }
  1386. }
  1387. }
  1388. .steps1 {
  1389. display: flex;
  1390. justify-content: flex-start;
  1391. flex-direction: column;
  1392. .item {
  1393. background-color: #FFFFFF;
  1394. display: flex;
  1395. width: 100%;
  1396. justify-content: space-between;
  1397. padding: 60rpx 0rpx;
  1398. border-radius: 30rpx;
  1399. .icon {
  1400. width: 120rpx;
  1401. height: 120rpx;
  1402. border-radius: 50%;
  1403. }
  1404. .item-content {
  1405. display: flex;
  1406. flex-direction: column;
  1407. width: 70%;
  1408. margin-left: 20rpx;
  1409. text:first-child {
  1410. color: #353535;
  1411. font-size: 32rpx;
  1412. font-weight: 800;
  1413. }
  1414. text:last-child {
  1415. margin-top: 20rpx;
  1416. color: #999999;
  1417. font-size: 26rpx;
  1418. }
  1419. }
  1420. }
  1421. }
  1422. .ocr-wrapper {
  1423. margin: 40rpx auto;
  1424. width: 375rpx;
  1425. }
  1426. .intro {
  1427. margin: 40rpx;
  1428. }
  1429. </style>