deposit.vue 98 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603
  1. <template>
  2. <cwg-page-wrapper class="create-page" :isHeaderFixed="true">
  3. <cwg-header :title="t('Home.page_customer.item2')" />
  4. <view class="container">
  5. <uni-loading v-if="loading" />
  6. <view class="row" v-else>
  7. <!-- 电汇提示 -->
  8. <p v-if="isStep3 && ['UNION_PAY_TELEGRAPHIC', 'UNION_PAY_TELEGRAPHIC_SPECIAL', 'UNION_PAY_TELEGRAPHIC_TWO'].includes(channelData.code)"
  9. class="text-secondary" v-t="'Custom.Deposit.Tips'" />
  10. <!-- 特别提示(B2BINPAY) -->
  11. <p v-if="isStep3 && bankOptions.length && channelData.code == 'B2BINPAY'" class="text-secondary"
  12. v-t="'Custom.Deposit.Des'" />
  13. <view class="col-lg-8">
  14. <view class="card">
  15. <view class="border-0 card-header">
  16. <uni-forms v-if="isStep3" ref="formRef" :model="params" :rules="rules" label-position="top"
  17. validate-trigger="submit" :label-width="300" class="base-info-form">
  18. <view class="row">
  19. <!-- 步骤1:选择账户 -->
  20. <view class="col-lg-6" v-if="step2">
  21. <h5 class="mb-3" v-t="'Custom.Deposit.Title1'"></h5>
  22. <uni-forms-item>
  23. <cwg-combox :clearable="false" v-model:value="loginValue"
  24. :options="loginComboxOptions"
  25. :placeholder="t('placeholder.choose')" /></uni-forms-item>
  26. </view>
  27. <!-- 步骤2:支付通道列表(卡片布局) -->
  28. <view class="col-lg-6" v-if="step2">
  29. <h5 class="mb-3" v-t="'Custom.Deposit.Title2'"></h5>
  30. <uni-forms-item>
  31. <cwg-combox :clearable="false" v-model:value="channelId"
  32. :options="channelListOptions" :placeholder="t('placeholder.choose')">
  33. </cwg-combox></uni-forms-item>
  34. </view>
  35. <!-- 信用卡选择区域 -->
  36. <view class="col-lg-6" v-if="isStep3 && channelData.confirmCreditCard == 1">
  37. <h5 class="mb-3" v-t="'PersonalManagement.Label.selectCreditCard'"></h5>
  38. <uni-forms-item>
  39. <cwg-combox :clearable="false" v-model:value="myId"
  40. :options="creditCardOptions" :placeholder="t('placeholder.choose')"
  41. @change="selectCode" />
  42. </uni-forms-item>
  43. <h5 class="add-back mb-3">
  44. <text>{{ t('PersonalManagement.Label.addCreditCard') }}</text>
  45. <text class="add-btn crm-cursor" @click="openAddBankCard">{{
  46. t('Custom.Withdraw.addBank1') }}</text>
  47. </h5>
  48. </view>
  49. <!-- 银行选择(如有) -->
  50. <view class="col-lg-6" v-if="isStep3 && bankOptions.length">
  51. <h5 class="mb-3" v-t="'news_add_field.Label.Title4'"></h5>
  52. <uni-forms-item>
  53. <cwg-combox :clearable="false" v-model:value="code" :options="bankOptions"
  54. :placeholder="t('placeholder.choose')" @change="selectCode" />
  55. </uni-forms-item>
  56. </view>
  57. <!-- 电汇信息展示 -->
  58. <view class="col-lg-6"
  59. v-if="isStep3 && ['UNION_PAY_TELEGRAPHIC', 'UNION_PAY_TELEGRAPHIC_SPECIAL', 'UNION_PAY_TELEGRAPHIC_TWO'].includes(channelData.code)">
  60. <h5 class="mb-3" v-t="'Custom.Deposit.Title5'"></h5>
  61. <view class="wire-transfer-account">
  62. <view class="row"><text class="label SpecialColor">{{
  63. t('Custom.Deposit.bankUname') }}</text><text
  64. class="content SpecialColor">{{
  65. WireTransferAccount.bankUname || '--'
  66. }}</text></view>
  67. <view class="row"><text class="label">{{ t('Custom.Deposit.bankName')
  68. }}</text><text class="content">{{ WireTransferAccount.bankName
  69. ||
  70. '--'
  71. }}</text></view>
  72. <view class="row"><text class="label SpecialColor">{{
  73. t('Custom.Deposit.bankCardNum') }}</text><text
  74. class="content SpecialColor">{{
  75. WireTransferAccount.bankCardNum || '--'
  76. }}</text></view>
  77. <view class="row"><text class="label">{{ t('Custom.Deposit.bankAddr')
  78. }}</text><text class="content">{{ WireTransferAccount.bankAddr
  79. ||
  80. '--'
  81. }}</text></view>
  82. <view class="row"><text class="label SpecialColor">{{
  83. t('Custom.Deposit.swiftCode') }}</text><text
  84. class="content SpecialColor">{{
  85. WireTransferAccount.swiftCode || '--'
  86. }}</text></view>
  87. <view class="row"><text class="label">{{ t('Custom.Deposit.bankCode')
  88. }}</text><text class="content">{{ WireTransferAccount.bankCode
  89. ||
  90. '--'
  91. }}</text></view>
  92. <view class="row"><text class="label SpecialColor">{{
  93. t('Custom.Recording.Note')
  94. }}</text><text class="content SpecialColor">{{
  95. WireTransferAccount.bankMsg || '--' }}</text></view>
  96. </view>
  97. </view>
  98. <!-- 数字货币信息展示 -->
  99. <!-- <view class="col-lg-6"
  100. v-if="isStep3 && channelData.code && channelData.code.indexOf('DIGITAL_PAY_TYPE_KEY') === 0">
  101. <h5 class="mb-3" v-t="'Custom.Deposit.DigitalAcc'"></h5>
  102. <view class="wire-transfer-account">
  103. <view class="row"><text class="label SpecialColor">{{
  104. t('Custom.Deposit.DigitalName') }}</text><text
  105. class="content SpecialColor">{{ WireTransferAccount.name
  106. + '-' +
  107. WireTransferAccount.type }}</text></view>
  108. <view class="row"><text class="label">{{ t('Custom.Withdraw.Title6')
  109. }}</text><text class="content">{{ WireTransferAccount.address ||
  110. '--'
  111. }}</text></view>
  112. <view class="row"><text class="label">QR Code</text>
  113. <image :src="Host05 + WireTransferAccount.url" mode="aspectFit"
  114. style="width: 100rpx; height: 100rpx;" />
  115. </view>
  116. </view>
  117. </view> -->
  118. <!-- 表单区域(含金额、预估金额、上传凭证、优惠码) -->
  119. <view class="col-lg-6">
  120. <h5 class="mb-3">
  121. {{ t('Custom.Deposit.Title3') + '(' + channelData.currency + ')' }}
  122. </h5>
  123. <!-- 金额输入 -->
  124. <view class="amount-box">
  125. <uni-forms-item name="amount" :error-message="amountErrorMessage"
  126. class="amount-input">
  127. <uni-easyinput type="number" v-model="params.amount"
  128. :placeholder="t('placeholder.input')" @blur="validateAmount" />
  129. </uni-forms-item>
  130. <!-- <view class="btn" v-t="'State.All'" @click="setAllAmount"></view> -->
  131. </view>
  132. </view>
  133. <!-- 预估金额(若有汇率) -->
  134. <view class="col-lg-6" v-if="channelData.rate">
  135. <h5 class="mb-3">
  136. <view class="label-with-icon">
  137. <text>{{ t('Custom.Deposit.EstimatedAmount') + '(' +
  138. `${channelData.transformCurrency || channelData.currency}` + ')'
  139. }}</text>
  140. <uni-tooltip placement="right">
  141. <!-- <view class="help-icon">ⓘ</view> -->
  142. <cwg-icon name="icon_about us" :size="16" />
  143. <template #content>
  144. <text>{{ t('Custom.Deposit.des') }}</text>
  145. </template>
  146. </uni-tooltip>
  147. </view>
  148. </h5>
  149. <uni-forms-item>
  150. <uni-easyinput v-model="params.amount1" disabled :placeholder="''" />
  151. </uni-forms-item>
  152. </view>
  153. <!-- 优惠码 -->
  154. <view class="col-lg-6">
  155. <h5 class="mb-3">
  156. <view class="label-with-icon">
  157. <text>{{ t('Custom.Deposit.PromoCode') }}</text>
  158. <uni-tooltip placement="right">
  159. <!-- <view class="help-icon">ⓘ</view> -->
  160. <cwg-icon name="icon_about us" :size="16" />
  161. <template #content>
  162. <text>{{ t('news_add_field.Des.item3') }}</text>
  163. </template>
  164. </uni-tooltip>
  165. </view>
  166. </h5>
  167. <uni-forms-item name="promoCode">
  168. <uni-easyinput v-model="params.promoCode"
  169. :placeholder="t('placeholder.input')" />
  170. </uni-forms-item>
  171. </view>
  172. <!-- 上传汇款凭证(特定渠道) -->
  173. <view class="col-lg-6" v-if="
  174. channelData.code == 'UNION_PAY_TELEGRAPHIC' ||
  175. channelData.code == 'UNION_PAY_TELEGRAPHIC_SPECIAL' ||
  176. channelData.code == 'UNION_PAY_TELEGRAPHIC_TWO'
  177. ">
  178. <h5 class="mb-3" v-t="'Custom.Deposit.UploadRemittanceVoucher'"></h5>
  179. <view>
  180. <uni-forms-item>
  181. <cwg-file-picker-wrapper v-model="imageUrl" :limit="1" :editable="true"
  182. :imageWidth="100" :imageHeight="100" :fileMediatype="'all'"
  183. uploadUrl="/common/upload" :baseUrl="Host80" />
  184. </uni-forms-item>
  185. </view>
  186. </view>
  187. <!-- ========== 赠金活动部分 ========== -->
  188. <!-- 10%赠金(年中赠金) -->
  189. <view v-if="tableData4Flag">
  190. <uni-forms-item class="agree" name="agree4">
  191. <label class="checkbox">
  192. <checkbox :checked="params.agree4"
  193. @click="params.agree4 = !params.agree4" />
  194. <text>{{ t('news_add_field1.activitiesNZ.itemDeposit1')
  195. }}</text>
  196. </label>
  197. <view style="line-height: 1.5; font-size: 14px">
  198. <text>{{ t('news_add_field1.activitiesNZ.itemDeposit2')
  199. }}</text>
  200. <text class="clause crm-cursor" @click="dialogClauseNZ = true">{{
  201. t('news_add_field1.activitiesNZ.itemDeposit3')
  202. }}</text>
  203. <text>{{ t('news_add_field1.activitiesNZ.itemDeposit4')
  204. }}</text>
  205. </view>
  206. </uni-forms-item>
  207. </view>
  208. <!-- 20%赠金(年中赠金) -->
  209. <view v-if="tableData4TwoFlag">
  210. <uni-forms-item class="agree" name="agree5">
  211. <label class="checkbox">
  212. <checkbox :checked="params.agree5"
  213. @click="params.agree5 = !params.agree5" />
  214. <text>{{ t('news_add_field1.activitiesNZTwo.itemDeposit1')
  215. }}</text>
  216. </label>
  217. <view style="line-height: 1.5; font-size: 14px">
  218. <text>{{ t('news_add_field1.activitiesNZTwo.itemDeposit2')
  219. }}</text>
  220. <text class="clause crm-cursor" @click="dialogClauseNZTwo = true">{{
  221. t('news_add_field1.activitiesNZTwo.itemDeposit3') }}</text>
  222. <text>{{ t('news_add_field1.activitiesNZTwo.itemDeposit4')
  223. }}</text>
  224. </view>
  225. </uni-forms-item>
  226. </view>
  227. <!-- 赠送活动(动态) -->
  228. <view v-if="tableDataNewListFlag">
  229. <uni-forms-item class="agree" name="agree6">
  230. <label>
  231. <checkbox :checked="params.agree6"
  232. @click="params.agree6 = !params.agree6" />
  233. <text>{{ tableDataNewList.title }}</text>
  234. </label>
  235. <view style="line-height: 1.5; font-size: 14px">
  236. <text>{{ t('news_add_field1.activitiesNewList.item1') }}</text>
  237. <text class="clause crm-cursor" @click="dialogClauseNewList = true">{{
  238. tableDataNewList.title }}</text>
  239. <text>{{ t('news_add_field1.activitiesNewList.item2') }}</text>
  240. </view>
  241. </uni-forms-item>
  242. </view>
  243. <!-- 20%赠金申请(特定账户类型) -->
  244. <view
  245. v-if="(ACCType == 1 || ACCType == 2 || ACCType == 5 || ACCType == 6 || ACCType == 7) && anshiClose">
  246. <uni-forms-item class="agree" name="agree3">
  247. <label class="checkbox">
  248. <checkbox :checked="params.agree3"
  249. @click="params.agree3 = !params.agree3" />
  250. <text>{{ t('news_add_field1.deposit.item3') }}</text>
  251. </label>
  252. <view style="line-height: 1.5; font-size: 14px">
  253. <text>{{ t('news_add_field1.deposit.item4') }}</text>
  254. <text class="clause crm-cursor" @click="dialogClause1 = true">{{
  255. t('news_add_field1.deposit.item5') }}</text>
  256. <text>{{ t('news_add_field1.deposit.item6') }}</text>
  257. </view>
  258. </uni-forms-item>
  259. </view>
  260. <!-- 普通10%赠金(非年中、非特定账户) -->
  261. <view
  262. v-if="!tableData4Flag && !tableData4TwoFlag && !tableDataNewListFlag && (country != 'CN' || (country == 'CN' && (ACCType == 1 || ACCType == 2 || ACCType == 7 || ACCType == 5 || ACCType == 6 || ACCType == 8))) && ACCType != 3">
  263. <template v-if="isSupportedCountry && (ACCType == 2 || ACCType == 7)">
  264. <uni-forms-item class="agree" name="agree2">
  265. <label>
  266. <checkbox :checked="params.agree2"
  267. @click="params.agree2 = !params.agree2" />
  268. <text>{{ t('news_add_field1.deposit.item2_1') }}</text>
  269. </label>
  270. <view style="line-height: 1.5; font-size: 14px">
  271. <text>{{ t('Custom.Deposit.agree21') }}</text>
  272. <cwg-link type="pdf" title="Custom.Deposit.agree22_2"
  273. :url="`pdf/pdf4/100Bonus-en.pdf`" style="color: black" />
  274. <text>{{ t('Custom.Deposit.agree23_2') }}</text>
  275. </view>
  276. </uni-forms-item>
  277. </template>
  278. <template
  279. v-else-if="!isSupportedCountry && ACCType != 8 && !isAfterSeptember30()">
  280. <uni-forms-item class="agree" name="agree2">
  281. <label>
  282. <checkbox :checked="params.agree2"
  283. @click="params.agree2 = !params.agree2" />
  284. <text>{{ t('news_add_field1.deposit.item1') }}</text>
  285. </label>
  286. <view style="line-height: 1.5; font-size: 14px">
  287. <text>{{ t('Custom.Deposit.agree21') }}</text>
  288. <cwg-link type="pdf" title="Custom.Deposit.agree22"
  289. :url="`pdf/pdf4/${langCN}.pdf`" style="color: black" />
  290. <text>{{ t('Custom.Deposit.agree23_1') }}</text>
  291. </view>
  292. </uni-forms-item>
  293. </template>
  294. </view>
  295. <button class="btn btn-dark waves-effect waves-light" @click="submitConfirm">{{
  296. t('Btn.Submit')
  297. }}</button>
  298. </view>
  299. </uni-forms>
  300. </view>
  301. </view>
  302. </view>
  303. <view class="col-lg-4">
  304. <view class="tips" v-if="(introduce.introduce || introduce.enIntroduce)">
  305. <view class="card card-body">
  306. <cwg-rich-text class="attention"
  307. :nodes="isZh ? introduce.introduce : introduce.enIntroduce" />
  308. </view>
  309. </view>
  310. </view>
  311. </view>
  312. </view>
  313. <!-- 不参加活动弹出框 -->
  314. <cwg-dont-active-popup v-model:visible="dialogDontActive" :showFooters="true" @confirm="tosubmitConfirm" />
  315. <!-- 新年24用户提示弹窗 -->
  316. <NewYear24Popup v-model:visible="tableDataNewYear24Flag" />
  317. <!-- 越南用户提示弹窗 -->
  318. <VietnamNoticePopup v-model:visible="dialogVietnamNotice" />
  319. <!-- 提交后确认弹窗 -->
  320. <cwg-check-confirm-popup v-model:visible="dialogCheckConfirm" :title="t('Home.page_customer.item2')"
  321. :channelData="channelData" :code="code" :selectCodes="selectCodes" :params="params" :userName="userName"
  322. :login="loginValue" :loginDoc="loginValueDoc" @confirm="submit" />
  323. <!--提交后的弹出框-->
  324. <CheckPopup v-model:visible="dialogCheckSuccess" :goPayLink="goPayLink" @close="closeDia" />
  325. <!-- 提交后失败弹窗 -->
  326. <cwg-error-popup v-model:visible="dialogCheckError" :responseMessage="RES" @confirm="closeErrorDia" />
  327. <!-- 最后失败弹窗 -->
  328. <cwg-error-popup v-model:visible="dialogError" @confirm="closeErrorDia" :responseMessage="RES" />
  329. <!-- 最后成功弹窗 -->
  330. <cwg-success-popup v-model:visible="dialogSuccess" @confirm="closeDia" />
  331. <!-- 等待弹窗 -->
  332. <cwg-wait-popup v-model:visible="dialogCheckWait" :showFooters="false" />
  333. <!-- 赠金协议 -->
  334. <ClausePopup v-model:visible="dialogClause" country="CN" :isGuoQin="isGuoQin" />
  335. <!-- 赠金协议20 -->
  336. <Clause20Popup v-model:visible="dialogClause1" />
  337. <!-- 赠金协议10年中 -->
  338. <ClauseNZPopup v-model:visible="dialogClauseNZ" :title="t('news_add_field1.activitiesNZ.item6')"
  339. :startDate="tableData4.applicationStartTime" :endDate="tableData4.applicationEndTime" />
  340. <!-- 赠金协议20年中 -->
  341. <ClauseNZTwoPopup v-model:visible="dialogClauseNZTwo" :title="t('news_add_field1.activitiesNZTwo.item6')"
  342. :startDate="tableData4Two.applicationStartTime" :endDate="tableData4Two.applicationEndTime" />
  343. <!-- 赠送活动详情-协议 -->
  344. <ClauseNewListPopup v-model:visible="dialogClauseNewList" :content="tableDataNewList.content"
  345. :title="tableDataNewList.title" />
  346. <!--提交后完成弹出框-->
  347. <ChinaUnionPayPopup v-model:visible="dialogChinaUnionPay" />
  348. <!-- 重新提交弹窗 -->
  349. <DealResultPopup v-model:visible="dialogDealResult" :responseMessage="responseMessage"
  350. :title="dialogDealResultTitle" :initialData="dialogDealResult_form" :type="DealResultType"
  351. @confirm="submitDealResult" />
  352. <!-- KYC成功弹窗 -->
  353. <cwg-kyc-popup v-model:visible="dialogKyc" :qrText="text1" />
  354. <!-- 数字支付确认弹窗 -->
  355. <DigitalPayConfirmPopup v-model:visible="dialogDigitalPayConfirm" :WireTransferAccount="WireTransferAccount"
  356. @close="closeDigitalPayConfirm" @confirm="confirmDigitalPayModal" />
  357. </cwg-page-wrapper>
  358. </template>
  359. <script setup>
  360. import { ref, reactive, computed, watch, onMounted, nextTick, onUnmounted } from 'vue'
  361. import { useI18n } from 'vue-i18n'
  362. const { t, locale } = useI18n()
  363. import useUserStore from '@/stores/use-user-store'
  364. import { customApi } from '@/service/custom'
  365. import { financialApi } from '@/service/financial'
  366. import { activityApi } from '@/service/activity'
  367. import Config from '@/config/index'
  368. const { Code, Host80, Host04 } = Config
  369. import { initLink } from '@/utils/setUrl'
  370. import isImageType from '@/global/isImageType'
  371. import PaymentMethodsList from './components/PaymentMethodsList.vue'
  372. import CwgKycPopup from './components/KycPopup.vue'
  373. import DealResultPopup from './components/DealResultPopup.vue'
  374. import ChinaUnionPayPopup from './components/ChinaUnionPayPopup.vue'
  375. import ClauseNewListPopup from './components/ClauseNewListPopup.vue'
  376. import ClauseNZTwoPopup from './components/ClauseNZTwoPopup.vue'
  377. import ClauseNZPopup from './components/ClauseNZPopup.vue'
  378. import Clause20Popup from './components/Clause20Popup.vue'
  379. import ClausePopup from './components/ClausePopup.vue'
  380. import CheckPopup from './components/CheckPopup.vue'
  381. import CwgCheckConfirmPopup from './components/DepositCheckConfirmPopup.vue'
  382. import VietnamNoticePopup from './components/VietnamNoticePopup.vue'
  383. import NewYear24Popup from './components/NewYear24Popup.vue'
  384. import DigitalPayConfirmPopup from './components/digitalPayConfirmPopup.vue'
  385. // 假设原有导入路径保持不变
  386. import tool from "@/global/tool"
  387. import { userToken } from '@/composables/config'
  388. // import { createUploadRequest } from "@/lib/upload"
  389. // 常量
  390. const countries = [
  391. "DZ", "AO", "BJ", "BW", "BF", "CM", "CG", "CD", "CI", "DJ", "EG", "ET", "GA", "GM", "GH", "GN", "KE", "MG", "MW", "ML", "MR", "MA", "MZ", "NA", "NE", "NG", "RW", "SN", "SL", "SO", "ZA", "SS", "SD", "TZ", "TG", "TN", "UG", "ZM", "ZW", "LS", "BH", "IR", "IQ", "IL", "JO", "KW", "LB", "OM", "PS", "QA", "SA", "SY", "TR", "AE", "YE", "AR", "BO", "BR", "CL", "CO", "EC", "GY", "PY", "PE", "SR", "UY", "VE", "BZ", "CR", "SV", "GT", "HN", "NI", "PA", "AU", "CA", "AL", "AD", "AM", "AT", "AZ", "BY", "BE", "BA", "BG", "HR", "CY", "CZ", "DK", "EE", "FI", "FR", "GE", "DE", "GR", "HU", "IS", "IE", "IT", "XK", "LV", "LI", "LT", "LU", "MT", "MD", "MC", "ME", "NL", "MK", "NO", "PL", "PT", "RO", "RU", "SM", "RS", "SK", "SI", "ES", "SE", "CH", "UA", "VA",
  392. ]
  393. // 用户信息
  394. const userStore = useUserStore()
  395. const userInfo = computed(() => userStore.userInfo)
  396. // 获取全局 Session 等,假设它们挂载在 uni 或 global 上
  397. const Session = {
  398. Get: (key, parse = false) => {
  399. const val = uni.getStorageSync(key)
  400. return parse ? JSON.parse(val) : val
  401. }
  402. }
  403. const handleFileUpdate = (val, type) => {
  404. if (type == '1') {
  405. params.requiteVoucherUrl = val
  406. }
  407. }
  408. const isZh = computed(() => ['cn', 'zhHant'].includes(locale.value))
  409. function isPdf(url, image) {
  410. let res = !!url
  411. if (image) {
  412. return res && url.substr(-3, 3) == 'pdf' &&
  413. url.substr(-3, 3) == 'PDF'
  414. }
  415. return res && (url.substr(-3, 3) == 'pdf' ||
  416. url.substr(-3, 3) == 'PDF')
  417. }
  418. const $pigeon = {
  419. MessageError: (msg) => uni.showToast({ title: msg, icon: 'none' }),
  420. MessageOK: (msg) => uni.showToast({ title: msg, icon: 'success' }),
  421. MessageWarning: (msg) => uni.showToast({ title: msg, icon: 'none' }),
  422. MessageConfirm: (msg, title, confirmText, cancelText, onConfirm, onCancel, options = {}) => {
  423. uni.showModal({
  424. title,
  425. content: msg,
  426. confirmText,
  427. cancelText,
  428. success: (res) => {
  429. if (res.confirm) onConfirm && onConfirm()
  430. else if (res.cancel) onCancel && onCancel()
  431. }
  432. })
  433. }
  434. }
  435. const $route = { query: {} } // 需从外部注入
  436. // 响应式数据
  437. const loginValue = ref("")
  438. const loginValueDoc = ref("")
  439. const metaInfo = ref(null)
  440. const text1 = ref("")
  441. const dialogKyc = ref(false)
  442. const requiteVoucherUrl = ref("")
  443. const limitedStatus = ref(null)
  444. const limitedStatusCheck = ref(false)
  445. const pictLoadingImg = ref(false)
  446. const flag = ref(false)
  447. const RES = ref("")
  448. const imgUrl = ref(Host80)
  449. const Host05 = ref(Config.Host05)
  450. const loginOptions = ref([])
  451. const code = ref("")
  452. const selectCodes = ref("")
  453. const bankValid = ref("")
  454. const requestUrl = ref("")
  455. const isStep3 = ref(false)
  456. const step2 = ref(false)
  457. const step3 = ref(false)
  458. const value = ref("")
  459. const giveLoginJoin = ref("")
  460. const openType = ref("")
  461. const dialogInfoTradingAdd = ref(false)
  462. const ruleForm = reactive({
  463. bankInfo: [],
  464. bankWrit: [],
  465. bankCredit: []
  466. })
  467. const bankInfoList = ref([])
  468. const bank = ref("")
  469. const myId = ref(null)
  470. const bankPayType = ref("")
  471. const form = reactive({})
  472. const dialogDealResult = ref(false)
  473. const dialogDealResult_form = reactive({})
  474. const DealResultType = ref(null)
  475. const DealResultResult = ref("")
  476. const dialogDealResultTitle = ref("")
  477. const anshiClose = ref(true)
  478. const isChannel = ref(true)
  479. const pictLoading = ref(false)
  480. const tableData = reactive({
  481. International_Transfer: [],
  482. China_UnionPay: [],
  483. Digital_Currency: [],
  484. Electronic_Wallet: [],
  485. Ucard_Wallet: []
  486. })
  487. const tableData1 = reactive({
  488. International_Transfer: [],
  489. China_UnionPay: [],
  490. Digital_Currency: [],
  491. Electronic_Wallet: [],
  492. Ucard_Wallet: []
  493. })
  494. //通道table-选择前后
  495. const activeTab = ref(1)
  496. // 🔥 自动过滤掉空数据的 tab
  497. const tabsConfig = computed(() => {
  498. const allTabs = [
  499. { text: t('Custom.Deposit.Channel3'), value: 1, type: 'Digital_Currency' },
  500. { text: t('Custom.Deposit.Channel2'), value: 2, type: 'China_UnionPay' },
  501. { text: t('Custom.Deposit.Channel4'), value: 3, type: 'Electronic_Wallet' },
  502. { text: t('Custom.Deposit.Channel1'), value: 4, type: 'International_Transfer' },
  503. { text: t('card.title'), value: 5, type: 'Ucard_Wallet' },
  504. ]
  505. // ✅ 只保留有数据的 tab
  506. return allTabs.filter(tab => {
  507. console.log(tableData1[tab.type], tab.type);
  508. return tableData1[tab.type]?.length > 0
  509. })
  510. })
  511. // 当前选中的 tab 项
  512. const currentTab = computed(() => tabsConfig.value.find(t => t.value === activeTab.value))
  513. // 当前要渲染的表格数据
  514. const currentTableData = computed(() => {
  515. const type = currentTab.value?.type
  516. return type ? tableData[type] || [] : []
  517. })
  518. // ✅ 监听 tab 变化,自动选中第一个有数据的 tab
  519. watch(
  520. tabsConfig,
  521. (newTabs) => {
  522. if (newTabs.length > 0) {
  523. activeTab.value = newTabs[0].value // 选中第一个
  524. }
  525. },
  526. { immediate: true }
  527. )
  528. watch(
  529. currentTab,
  530. (newTabs) => {
  531. // showTable()
  532. },
  533. { immediate: true }
  534. )
  535. const bankDate = ref([])
  536. const channelData = reactive({
  537. rate: ''
  538. })
  539. const WireTransferAccount = reactive({})
  540. const actionAdd1 = ref("")
  541. const actionAdd2 = ref(Host04 + "/activity/requite/voucher/upload")
  542. const imageUrl = ref("")
  543. const hashCode = ref("")
  544. const imageUrl1 = ref("")
  545. const introduce = reactive({
  546. introduce: "",
  547. enIntroduce: ""
  548. })
  549. const params = reactive({
  550. amount: "",
  551. amount1: "",
  552. promoCode: "",
  553. agree: false,
  554. agree2: false,
  555. agree3: false,
  556. agree4: false,
  557. agree5: false,
  558. agree6: false
  559. })
  560. const resetForm = () => {
  561. //表单重置后,需要手动重置一些状态
  562. params.amount = ""
  563. params.amount1 = ""
  564. params.promoCode = ""
  565. params.agree = false
  566. params.agree2 = false
  567. params.agree3 = false
  568. params.agree4 = false
  569. params.agree5 = false
  570. params.agree6 = false
  571. form.bankUname = undefined
  572. form.bankCardNum = undefined
  573. form.cvv = undefined
  574. form.expiryMonth = undefined
  575. form.expiryYear = undefined
  576. form.pin = undefined
  577. amountErrorMessage.value = ""
  578. requiteVoucherUrl.value = ""
  579. imageUrl.value = ""
  580. imageUrl1.value = ""
  581. }
  582. const formRef = ref(null)
  583. const mAmount = reactive({
  584. minAmount: "",
  585. maxAmount: ""
  586. })
  587. const dialogCheck = ref(false)
  588. const dialogVisible = ref(false)
  589. const dialogCheckWait = ref(false)
  590. const dialogCheckOK = ref(false)
  591. const goPayLink = ref("")
  592. const dialogCheckConfirm = ref(false)
  593. const dialogCheckConfirm_form = reactive({
  594. confirmName: "",
  595. confirmAreaCode: "",
  596. confirmPhone: ""
  597. })
  598. const dialogClause = ref(false)
  599. const dialogClause1 = ref(false)
  600. const dialogClauseNZ = ref(false)
  601. const dialogClauseNZTwo = ref(false)
  602. const dialogClauseNewList = ref(false)
  603. const ACCType = ref(null)
  604. const CheckExistSuccess = ref(false)
  605. const dialogChinaUnionPay = ref(false)
  606. const tableData4Flag = ref(false)
  607. const tableData4 = reactive({})
  608. const tableData4TwoFlag = ref(false)
  609. const tableData4Two = reactive({})
  610. const tableDataNewListFlag = ref(false)
  611. const tableDataNewList = reactive({})
  612. const dialogDontActive = ref(false)
  613. const dialogVietnamNotice = ref(false)
  614. const tableDataNewYear24Flag = ref(false)
  615. const tableDataNewYear24 = ref(false)
  616. const rules = computed(() => ({
  617. amount: {
  618. rules: [
  619. {
  620. required: true,
  621. errorMessage: t('vaildate.amount.format1'),
  622. },
  623. {
  624. validateFunction: (rule, value, data, callback) => {
  625. // 空值处理:直接报格式错误
  626. if (!value) {
  627. callback(t('vaildate.amount.format1'))
  628. return false
  629. }
  630. // 范围校验
  631. if (
  632. mAmount.minAmount &&
  633. mAmount.maxAmount &&
  634. (Number(mAmount.minAmount) > Number(value) ||
  635. Number(mAmount.maxAmount) < Number(value))
  636. ) {
  637. callback(
  638. t('vaildate.amount.amount') +
  639. mAmount.minAmount +
  640. ' - ' +
  641. mAmount.maxAmount
  642. )
  643. return false
  644. }
  645. // 正整数校验(原正则)
  646. if (!/^[1-9]\d*$/.test(value)) {
  647. callback(t('vaildate.amount.format1'))
  648. return false
  649. }
  650. return true
  651. },
  652. trigger: 'change',
  653. },
  654. ],
  655. },
  656. agree: {
  657. rules: [
  658. {
  659. required: true,
  660. errorMessage: t('vaildate.agree.empty'),
  661. trigger: 'change',
  662. },
  663. ],
  664. },
  665. confirmAreaCode: {
  666. rules: [
  667. {
  668. required: true,
  669. errorMessage: t('vaildate.input.empty'),
  670. trigger: 'blur',
  671. },
  672. ],
  673. },
  674. confirmPhone: {
  675. rules: [
  676. {
  677. required: true,
  678. errorMessage: t('vaildate.input.empty'),
  679. trigger: 'blur',
  680. },
  681. ],
  682. },
  683. myId: {
  684. rules: [
  685. {
  686. required: true,
  687. errorMessage: t('vaildate.select.empty'),
  688. trigger: 'change',
  689. },
  690. ],
  691. },
  692. pin: {
  693. rules: [
  694. {
  695. required: true,
  696. errorMessage: t('PersonalManagement.Label.item1'),
  697. trigger: 'blur',
  698. },
  699. ],
  700. },
  701. phone: {
  702. rules: [
  703. {
  704. required: true,
  705. errorMessage: t('vaildate.input.empty'),
  706. trigger: 'blur',
  707. },
  708. ],
  709. },
  710. otp: {
  711. rules: [
  712. {
  713. required: true,
  714. errorMessage: t('vaildate.input.empty'),
  715. trigger: 'blur',
  716. },
  717. ],
  718. },
  719. state: {
  720. rules: [
  721. {
  722. required: true,
  723. errorMessage: t('vaildate.input.empty'),
  724. trigger: 'blur',
  725. },
  726. ],
  727. },
  728. city: {
  729. rules: [
  730. {
  731. required: true,
  732. errorMessage: t('vaildate.input.empty'),
  733. trigger: 'blur',
  734. },
  735. ],
  736. },
  737. country: {
  738. rules: [
  739. {
  740. required: true,
  741. errorMessage: t('vaildate.select.empty'),
  742. trigger: 'change',
  743. },
  744. ],
  745. },
  746. address: {
  747. rules: [
  748. {
  749. required: true,
  750. errorMessage: t('vaildate.input.empty'),
  751. trigger: 'blur',
  752. },
  753. ],
  754. },
  755. zipCode: {
  756. rules: [
  757. {
  758. required: true,
  759. errorMessage: t('vaildate.input.empty'),
  760. trigger: 'blur',
  761. },
  762. ],
  763. },
  764. }))
  765. const amountErrorMessage = ref('')
  766. const setTipsAmount = () => {
  767. const min = Number(mAmount.minAmount);
  768. const max = Number(mAmount.maxAmount);
  769. amountErrorMessage.value = t('vaildate.amount.amount') + min + '-' + max
  770. }
  771. const validateAmount = (value) => {
  772. const amount = params.amount
  773. if (!amount && amount !== 0) {
  774. const min = Number(mAmount.minAmount);
  775. const max = Number(mAmount.maxAmount);
  776. amountErrorMessage.value = t('vaildate.amount.amount') + min + '-' + max
  777. return false
  778. }
  779. if (mAmount.minAmount && mAmount.maxAmount) {
  780. const min = Number(mAmount.minAmount);
  781. const max = Number(mAmount.maxAmount);
  782. const numValue = Number(amount);
  783. if (numValue < min || numValue > max) {
  784. amountErrorMessage.value = t('vaildate.amount.amount') + min + '-' + max
  785. return false
  786. }
  787. }
  788. if (!/^[1-9]\d*$/.test(amount)) {
  789. amountErrorMessage.value = t('vaildate.amount.format1')
  790. return false
  791. }
  792. amountErrorMessage.value = ''
  793. return true
  794. }
  795. const NewYear24Data = reactive({
  796. balance: 0,
  797. income: 0,
  798. rate: 0,
  799. index: 0
  800. })
  801. const AccessToken = computed(() => ({
  802. "Access-Token": Session.Get("access_token")
  803. }))
  804. const lang = computed(() => {
  805. return locale.value == "en" && document.body.clientWidth < 1200
  806. })
  807. const langCN = computed(() => locale.value)
  808. const isSupportedCountry = computed(() => {
  809. try {
  810. const country = userInfo.value.customInfo.country
  811. return countries.includes(country)
  812. } catch {
  813. return false
  814. }
  815. })
  816. const country = computed(() => {
  817. return userInfo.value.customInfo.country
  818. })
  819. const userName = computed(() => {
  820. let first = userInfo.value.customInfo.firstName
  821. let last = userInfo.value.customInfo.lastName
  822. let middle = userInfo.value.customInfo.middle
  823. if (!first && !last && !middle) return false
  824. return (first ? first + " " : "") + (middle ? middle + " " : "") + (last ? last : "")
  825. })
  826. const areaCode = computed(() => userInfo.value.customInfo.areaCode)
  827. const phone = computed(() => userInfo.value.customInfo.phone)
  828. // 是否是国庆节
  829. const isGuoQin = computed(() => {
  830. let flag = false
  831. let startTime1 = "2024/10/01 00:00:00"
  832. let endTime1 = "2024/10/07 23:59:59"
  833. let timezone = 8
  834. let offset_GMT = new Date().getTimezoneOffset()
  835. let nowDate = new Date().getTime()
  836. let now = new Date(nowDate + offset_GMT * 60 * 1000 + timezone * 60 * 60 * 1000).getTime()
  837. let end = new Date(endTime1).getTime()
  838. let start = new Date(startTime1).getTime()
  839. if (now > start && now < end) flag = true
  840. return flag
  841. })
  842. const groupTitleMap = {
  843. 1: 'Custom.Deposit.Channel1',
  844. 2: 'Custom.Deposit.Channel2',
  845. 3: 'Custom.Deposit.Channel3',
  846. 4: 'Custom.Deposit.Channel4',
  847. 5: 'card.title'
  848. }
  849. // 排序表格数据
  850. const sortedTableData = computed(() => {
  851. const order = [
  852. tableData.Digital_Currency,
  853. tableData.China_UnionPay,
  854. tableData.Electronic_Wallet,
  855. tableData.International_Transfer,
  856. tableData.Ucard_Wallet
  857. ]
  858. return order.filter(item => item && item.length > 0)
  859. })
  860. // 方法
  861. const isAfterJuly21 = () => {
  862. const currentDate = new Date()
  863. const july21 = new Date(currentDate.getFullYear(), 6, 21)
  864. return currentDate >= july21
  865. }
  866. // 货币
  867. const groupCurrency = (type) => {
  868. if (type == "GBP") return ": £"
  869. else if (type == "USD") return ": $"
  870. else if (type == "EUR") return ": €"
  871. else if (type == "USC") return ": ¢"
  872. else return ": $"
  873. }
  874. // 货币符号
  875. const groupCurrency1 = (type) => {
  876. if (type == "GBP") return "£"
  877. else if (type == "USD") return "$"
  878. else if (type == "EUR") return "€"
  879. else if (type == "USC") return "¢"
  880. else return "$"
  881. }
  882. // 选择银行
  883. const selectCode = (codeVal) => {
  884. bankDate.value.forEach(item => {
  885. if (item.code == codeVal) {
  886. selectCodes.value = lang.value == "cn" ? item.name : item.enName
  887. mAmount.minAmount = item.minAmount || mAmount.minAmount
  888. mAmount.maxAmount = item.maxAmount || mAmount.maxAmount
  889. channelData.rate = item.rate || channelData.rate
  890. channelData.transformCurrency = item.currency || channelData.transformCurrency
  891. }
  892. })
  893. }
  894. // 账户类型
  895. const groupTypeName = (type) => {
  896. if (type == "1") return t("AccountType.ClassicAccount")
  897. else if (type == "2") return t("AccountType.SeniorAccount")
  898. else if (type == "5") return t("AccountType.SpeedAccount")
  899. else if (type == "6") return t("AccountType.SpeedAccount")
  900. else if (type == "7") return t("AccountType.StandardAccount")
  901. else if (type == "8") return t("AccountType.CentAccount")
  902. }
  903. const selectChange = () => {
  904. // 强制更新,在 Vue 3 中通常不需要
  905. }
  906. const handleProgress1 = () => {
  907. pictLoadingImg.value = true
  908. }
  909. const handleAvatarError1 = (err) => {
  910. let errorMessage = t("Msg.Fail")
  911. if (err && err.status) {
  912. switch (err.status) {
  913. case 400: errorMessage = t("Msg.UploadInvalidFormat"); break
  914. case 401: errorMessage = t("Msg.UploadUnauthorized"); break
  915. case 403: errorMessage = t("Msg.UploadForbidden"); break
  916. case 413: errorMessage = t("Msg.UploadFileTooLarge"); break
  917. case 500: errorMessage = t("Msg.UploadServerError"); break
  918. case 502:
  919. case 503:
  920. case 504: errorMessage = t("Msg.UploadNetworkError"); break
  921. default:
  922. if (err.message) errorMessage = err.message
  923. else if (err.response && err.response.data && err.response.data.msg) errorMessage = err.response.data.msg
  924. }
  925. } else if (err && err.message) {
  926. if (err.message.includes("Network Error") || err.message.includes("timeout")) errorMessage = t("Msg.UploadNetworkError")
  927. else if (err.message.includes("File too large")) errorMessage = t("Msg.UploadFileTooLarge")
  928. else errorMessage = err.message
  929. }
  930. $pigeon.MessageError(errorMessage)
  931. pictLoadingImg.value = false
  932. }
  933. const handleAvatarSuccess1 = (res) => {
  934. if (res.code == Code.StatusOK) {
  935. $pigeon.MessageOK(res.msg)
  936. imageUrl1.value = res.data
  937. requiteVoucherUrl.value = res.data
  938. } else {
  939. uni.showToast({ title: res.msg, icon: 'none' })
  940. }
  941. pictLoadingImg.value = false
  942. }
  943. // 上传凭证前校验
  944. const beforeAvatarUpload1 = (file) => {
  945. const isJPG = isImageType.checkFile(file.type)
  946. const isLt2M = isImageType.checkSize(file.size)
  947. if (!isJPG) $pigeon.MessageError(t("Msg.JPG"))
  948. if (!isLt2M) $pigeon.MessageError(t("Msg.3IMG"))
  949. return isJPG && isLt2M
  950. }
  951. // 上传凭证进度
  952. const handleProgress = () => {
  953. pictLoadingImg.value = true
  954. }
  955. // 上传凭证失败
  956. const handleAvatarError = (err) => {
  957. let errorMessage = t("Msg.Fail")
  958. if (err && err.status) {
  959. switch (err.status) {
  960. case 400: errorMessage = t("Msg.UploadInvalidFormat"); break
  961. case 401: errorMessage = t("Msg.UploadUnauthorized"); break
  962. case 403: errorMessage = t("Msg.UploadForbidden"); break
  963. case 413: errorMessage = t("Msg.UploadFileTooLarge"); break
  964. case 500: errorMessage = t("Msg.UploadServerError"); break
  965. case 502:
  966. case 503:
  967. case 504: errorMessage = t("Msg.UploadNetworkError"); break
  968. default:
  969. if (err.message) errorMessage = err.message
  970. else if (err.response && err.response.data && err.response.data.msg) errorMessage = err.response.data.msg
  971. }
  972. } else if (err && err.message) {
  973. if (err.message.includes("Network Error") || err.message.includes("timeout")) errorMessage = t("Msg.UploadNetworkError")
  974. else if (err.message.includes("File too large")) errorMessage = t("Msg.UploadFileTooLarge")
  975. else errorMessage = err.message
  976. }
  977. $pigeon.MessageError(errorMessage)
  978. pictLoadingImg.value = false
  979. }
  980. // 上传凭证
  981. const handleUploadDeposit = (options) => {
  982. const originalUrl = actionAdd1.value || Config.Host80 + "/common/upload"
  983. return createUploadRequest(originalUrl, userToken.value, 1)(options)
  984. }
  985. // 上传凭证成功
  986. const handleAvatarSuccess = (res) => {
  987. if (res.code == Code.StatusOK) {
  988. $pigeon.MessageOK(res.msg)
  989. imageUrl.value = res.data
  990. requiteVoucherUrl.value = res.data
  991. } else {
  992. uni.showToast({ title: res.msg, icon: 'none' })
  993. }
  994. pictLoadingImg.value = false
  995. }
  996. // 上传凭证前校验
  997. const beforeAvatarUpload = (file) => {
  998. const isJPG = isImageType.checkFile(file.type)
  999. const isLt2M = isImageType.checkSize(file.size)
  1000. if (!isJPG) $pigeon.MessageError(t("Msg.JPG"))
  1001. if (!isLt2M) $pigeon.MessageError(t("Msg.3IMG"))
  1002. return isJPG && isLt2M
  1003. }
  1004. // 打开添加银行弹窗
  1005. const openAddBankCard = () => {
  1006. if (ruleForm.bankCredit.length == 2) {
  1007. $pigeon.MessageConfirm(
  1008. t("Msg.WireTransfers"),
  1009. t("Msg.SystemPrompt"),
  1010. t("Btn.Confirm"),
  1011. t("Btn.Cancel"),
  1012. async () => { },
  1013. () => { }
  1014. )
  1015. } else {
  1016. openType.value = "add_CreditCard"
  1017. dialogInfoTradingAdd.value = true
  1018. }
  1019. }
  1020. const closeDiaAdd = () => {
  1021. dialogInfoTradingAdd.value = false
  1022. }
  1023. // 关闭添加银行弹窗
  1024. const closeAdd = (val) => {
  1025. dialogInfoTradingAdd.value = val
  1026. }
  1027. // 确认重新加载银行信息
  1028. const confirmToReload = () => {
  1029. dialogInfoTradingAdd.value = false
  1030. getBankInfo()
  1031. }
  1032. // 获取银行信息
  1033. const getBankInfo = async () => {
  1034. let res = await financialApi.customBankList({})
  1035. if (res.code == Code.StatusOK) {
  1036. ruleForm.bankCredit = []
  1037. res.data.forEach(item => {
  1038. if (item.type == 3) {
  1039. item.customBankCode = item.bankCode
  1040. item.bankCode = null
  1041. ruleForm.bankCredit.push(item)
  1042. }
  1043. if (item.defaultBank && item.type == 3) {
  1044. myId.value = item.id
  1045. form.bankUname = item.bankUname
  1046. form.bankCardNum = item.bankCardNum
  1047. form.cvv = item.cvv
  1048. form.expiryMonth = item.expiryMonth
  1049. form.expiryYear = item.expiryYear
  1050. form.pin = item.pin
  1051. }
  1052. })
  1053. } else {
  1054. uni.showToast({ title: res.msg, icon: 'none' })
  1055. }
  1056. }
  1057. // 选择银行
  1058. const chooseBank = (item) => {
  1059. if (formRef.value) formRef.value.clearValidate()
  1060. form.bankUname = item.bankUname
  1061. form.bankCardNum = item.bankCardNum
  1062. form.cvv = item.cvv
  1063. form.expiryMonth = item.expiryMonth
  1064. form.expiryYear = item.expiryYear
  1065. form.pin = item.pin
  1066. }
  1067. // 返回首页
  1068. const toHome = () => {
  1069. uni.switchTab({ url: "/pages/customer/index" })
  1070. }
  1071. const dialogDigitalPayConfirm = ref(false)
  1072. // 提交确认信息弹窗
  1073. const submitConfirm = async () => {
  1074. if (channelData.confirmCreditCard == 1 && !myId.value) {
  1075. $pigeon.MessageWarning(t("PersonalManagement.Label.selectCreditCard"))
  1076. return
  1077. }
  1078. if (channelData.bankValid == 1 && !code.value) {
  1079. $pigeon.MessageWarning(t("vaildate.depositCurrency.empty"))
  1080. return
  1081. }
  1082. if ((channelData.code == "UNION_PAY_TELEGRAPHIC" || channelData.code == "UNION_PAY_TELEGRAPHIC_SPECIAL" || channelData.code == "UNION_PAY_TELEGRAPHIC_TWO") && !imageUrl.value) {
  1083. $pigeon.MessageWarning(t("vaildate.depositVoucher.empty"))
  1084. return
  1085. }
  1086. if (params.promoCode && params.agree2) {
  1087. $pigeon.MessageWarning(t("news_add_field.Des.item2"))
  1088. return
  1089. }
  1090. if (params.promoCode && params.agree3) {
  1091. $pigeon.MessageWarning(t("news_add_field.Des.item2"))
  1092. return
  1093. }
  1094. if (params.promoCode && params.agree4) {
  1095. $pigeon.MessageWarning(t("news_add_field.Des.item2"))
  1096. return
  1097. }
  1098. if (params.promoCode && params.agree5) {
  1099. $pigeon.MessageWarning(t("news_add_field.Des.item2"))
  1100. return
  1101. }
  1102. if (params.promoCode && params.agree6) {
  1103. $pigeon.MessageWarning(t("news_add_field.Des.item2"))
  1104. return
  1105. }
  1106. // if (channelData.code && channelData.code.indexOf('DIGITAL_PAY_TYPE_KEY') === 0 && !imageUrl.value) {
  1107. // $pigeon.MessageWarning(t("vaildate.depositVoucher.empty"))
  1108. // return
  1109. // }
  1110. try {
  1111. if (formRef.value) {
  1112. await formRef.value.validate()
  1113. console.log(channelData, channelData.code, 12);
  1114. if (
  1115. channelData.code &&
  1116. channelData.code.indexOf("DIGITAL_PAY_TYPE_KEY") === 0
  1117. ) {
  1118. imageUrl.value = "";
  1119. dialogDigitalPayConfirm.value = true;
  1120. } else {
  1121. openDontActive();
  1122. }
  1123. }
  1124. } catch (error) {
  1125. if (error instanceof Array) {
  1126. uni.showToast({ title: error[0].errorMessage, icon: 'none' });
  1127. return
  1128. } else {
  1129. responseMessage.value = error.msg;
  1130. }
  1131. }
  1132. }
  1133. const confirmDigitalPayModal = (e) => {
  1134. dialogDigitalPayConfirm.value = false;
  1135. imageUrl.value = e.voucherUrl || e.image || '';
  1136. hashCode.value = e.hashCode || '';
  1137. openDontActive();
  1138. }
  1139. // 关闭数字支付确认弹窗
  1140. const closeDigitalPayConfirm = () => {
  1141. dialogDigitalPayConfirm.value = false;
  1142. }
  1143. // 打开不参加活动弹窗
  1144. const openDontActive = () => {
  1145. if (!tableData4Flag.value && !tableData4TwoFlag.value && !tableDataNewListFlag.value && (country.value != "CN" || (country.value == "CN" && (ACCType.value == 1 || ACCType.value == 2 || ACCType.value == 7))) && ACCType.value != 3 && params.agree2) {
  1146. tosubmitConfirm()
  1147. return
  1148. }
  1149. if (tableData4Flag.value && params.agree4) {
  1150. tosubmitConfirm()
  1151. return
  1152. }
  1153. if (tableData4TwoFlag.value && params.agree5) {
  1154. tosubmitConfirm()
  1155. return
  1156. }
  1157. if (tableDataNewListFlag.value && params.agree6) {
  1158. tosubmitConfirm()
  1159. return
  1160. }
  1161. if (limitedStatus.value && limitedStatusCheck.value) {
  1162. tosubmitConfirm()
  1163. return
  1164. }
  1165. if ((ACCType.value == 1 || ACCType.value == 2 || ACCType.value == 5 || ACCType.value == 6 || ACCType.value == 7) && anshiClose.value && params.agree3) {
  1166. tosubmitConfirm()
  1167. return
  1168. }
  1169. tosubmitConfirm()
  1170. }
  1171. // 打开提交前信息弹窗
  1172. const tosubmitConfirm = () => {
  1173. dialogDontActive.value = false
  1174. dialogCheckConfirm_form.confirmAreaCode = areaCode.value
  1175. dialogCheckConfirm_form.confirmPhone = phone.value
  1176. dialogCheckConfirm.value = true
  1177. }
  1178. // 最后确认
  1179. const dialogSuccess = computed(() => dialogCheckOK.value && dialogVisible.value)
  1180. // 最后失败
  1181. const dialogError = computed(() => dialogCheckOK.value && !dialogVisible.value)
  1182. // 提交后确认
  1183. const dialogCheckSuccess = computed(() => dialogCheck.value && dialogVisible.value)
  1184. // 提交后失败
  1185. const dialogCheckError = computed(() => dialogCheck.value && !dialogVisible.value)
  1186. // 提交申请
  1187. const submit = async () => {
  1188. if (flag.value) return
  1189. flag.value = true
  1190. dialogCheckConfirm.value = false
  1191. dialogCheckWait.value = true
  1192. try {
  1193. if (channelData.code == "UNION_PAY_TELEGRAPHIC" || channelData.code == "UNION_PAY_TELEGRAPHIC_SPECIAL" || channelData.code == "UNION_PAY_TELEGRAPHIC_TWO") {
  1194. let res = await financialApi.telegraphicPay({
  1195. requiteVoucherUrl: imageUrl1.value,
  1196. amount: params.amount,
  1197. login: loginValue.value,
  1198. voucherUrl: imageUrl.value,
  1199. activityDeposit: params.agree2 ? 1 : 0,
  1200. activityPercentageGive: params.agree3 ? 1 : 0,
  1201. activityMidyearTenPercentGive: params.agree4 ? 1 : 0,
  1202. activityTwoPercentGive: params.agree5 ? 1 : 0,
  1203. activityGive: params.agree6 ? 1 : 0,
  1204. promoCode: params.promoCode,
  1205. code: channelData.code,
  1206. bankMsg: WireTransferAccount.bankMsg || "",
  1207. name: channelData.confirmName ? userName.value : null,
  1208. areaCode: channelData.confirmAreaCode ? dialogCheckConfirm_form.confirmAreaCode : null,
  1209. phone: channelData.confirmPhone ? dialogCheckConfirm_form.confirmPhone : null,
  1210. ip: uni.getStorageSync("CLIENT")
  1211. })
  1212. dialogCheckWait.value = false
  1213. if (res.code == Code.StatusOK) {
  1214. imageUrl1.value = ""
  1215. limitedStatusCheck.value = false
  1216. dialogCheckOK.value = true
  1217. dialogVisible.value = true
  1218. flag.value = false
  1219. } else {
  1220. RES.value = res.msg
  1221. dialogCheckOK.value = true
  1222. dialogVisible.value = false
  1223. flag.value = false
  1224. }
  1225. } else if (channelData.code && channelData.code.indexOf('DIGITAL_PAY_TYPE_KEY') === 0) {
  1226. let res = await financialApi.digitalPay({
  1227. requiteVoucherUrl: imageUrl1.value,
  1228. amount: params.amount,
  1229. login: loginValue.value,
  1230. voucherUrl: imageUrl.value,
  1231. hashCode: hashCode.value,
  1232. activityDeposit: params.agree2 ? 1 : 0,
  1233. activityPercentageGive: params.agree3 ? 1 : 0,
  1234. activityMidyearTenPercentGive: params.agree4 ? 1 : 0,
  1235. activityTwoPercentGive: params.agree5 ? 1 : 0,
  1236. activityGive: params.agree6 ? 1 : 0,
  1237. promoCode: params.promoCode,
  1238. ip: uni.getStorageSync("CLIENT")
  1239. })
  1240. dialogCheckWait.value = false
  1241. if (res.code == Code.StatusOK) {
  1242. dialogCheckOK.value = true
  1243. dialogVisible.value = true
  1244. flag.value = false
  1245. } else {
  1246. RES.value = res.msg
  1247. dialogCheckOK.value = true
  1248. dialogVisible.value = false
  1249. flag.value = false
  1250. }
  1251. } else {
  1252. let par = ""
  1253. if (channelData.bankValid == 1) {
  1254. par = `${channelData.requestUrl}/${loginValue.value}/${params.amount}/${code.value}/${(params.agree2 ? 1 : 0)}`
  1255. } else {
  1256. par = `${channelData.requestUrl}/${loginValue.value}/${params.amount}/${(params.agree2 ? 1 : 0)}`
  1257. }
  1258. let res = await financialApi.PayBankCode(par, {
  1259. requiteVoucherUrl: imageUrl1.value,
  1260. promoCode: params.promoCode,
  1261. name: channelData.confirmName ? userName.value : null,
  1262. areaCode: channelData.confirmAreaCode ? dialogCheckConfirm_form.confirmAreaCode : null,
  1263. phone: channelData.confirmPhone ? dialogCheckConfirm_form.confirmPhone : null,
  1264. activityPercentageGive: params.agree3 ? 1 : 0,
  1265. activityMidyearTenPercentGive: params.agree4 ? 1 : 0,
  1266. activityTwoPercentGive: params.agree5 ? 1 : 0,
  1267. activityGive: params.agree6 ? 1 : 0,
  1268. ip: uni.getStorageSync("CLIENT"),
  1269. ...form
  1270. })
  1271. dialogCheckWait.value = false
  1272. if (res.code == Code.StatusOK) {
  1273. if (res.data && (res.data.type == 3 || res.data.type == 4 || res.data.type == 6 || res.data.type == 7)) {
  1274. dealResult(res.data)
  1275. } else {
  1276. if (res.data.type == 1) {
  1277. goPayLink.value = res.data.result
  1278. window.open(res.data.result)
  1279. } else if (res.data.type == 2) {
  1280. let token = userToken.value
  1281. token = tool.tokenReplace(token)
  1282. goPayLink.value = `${Host04}/finance/deposit/get?serial=${res.data.result}&Access-Token=${token}`
  1283. window.open(goPayLink.value)
  1284. } else if (res.data.type == 5) {
  1285. $pigeon.MessageConfirm(
  1286. t("PersonalManagement.Label.item2"),
  1287. t("Msg.SystemPrompt"),
  1288. t("Btn.Cancel"),
  1289. t("Btn.Confirm"),
  1290. async () => { },
  1291. () => {
  1292. goPayLink.value = res.data.result
  1293. dialogCheck.value = true
  1294. dialogVisible.value = true
  1295. window.open(res.data.result)
  1296. }
  1297. )
  1298. } else if (res.data.type == 8) {
  1299. goPayLink.value = Host04 + res.data.result
  1300. window.open(goPayLink.value)
  1301. } else if (res.data.type == 9) {
  1302. goPayLink.value = setCardUrl(res.data.result)
  1303. window.open(goPayLink.value)
  1304. } else if (res.data.type == 10) {
  1305. goPayLink.value = Host80 + '/pay/onchainpay.html?params=' + res.data.result
  1306. window.open(goPayLink.value)
  1307. }
  1308. if (res.data.type != 5) {
  1309. dialogCheck.value = true
  1310. dialogVisible.value = true
  1311. }
  1312. }
  1313. flag.value = false
  1314. } else {
  1315. RES.value = res.msg
  1316. dialogCheck.value = true
  1317. dialogVisible.value = false
  1318. flag.value = false
  1319. }
  1320. }
  1321. } catch (error) {
  1322. dialogCheckWait.value = false
  1323. flag.value = false
  1324. dialogCheckOK.value = true
  1325. dialogVisible.value = false
  1326. RES.value = error.msg
  1327. }
  1328. }
  1329. const setCardUrl = (serial) => {
  1330. let params = `${userToken.value}/${locale.value}/${serial}/1/pay`
  1331. return initLink({ link: imgUrl.value + '/pay/paycard.html', params })
  1332. }
  1333. //处理申请返回result
  1334. const dealResult = (data) => {
  1335. DealResultType.value = data.type
  1336. DealResultResult.value = data.result
  1337. if (data.type == 3) {
  1338. dialogDealResult_form.pin = ""
  1339. } else if (data.type == 4) {
  1340. dialogDealResult_form.otp = ""
  1341. } else if (data.type == 6) {
  1342. dialogDealResult_form.state = userInfo.value.state
  1343. dialogDealResult_form.city = userInfo.value.city
  1344. dialogDealResult_form.country = (["cn", "zhHant"].indexOf(locale.value) != -1) ? userInfo.value.countryName : userInfo.value.countryEnName
  1345. dialogDealResult_form.address = (userInfo.value.addressLines && userInfo.value.addressLines[0]) || ""
  1346. dialogDealResult_form.zipCode = userInfo.value.zipCode
  1347. dialogDealResultTitle.value = t("PersonalManagement.Label.item3")
  1348. } else if (data.type == 7) {
  1349. dialogDealResult_form.phone = userInfo.value.phone
  1350. dialogDealResultTitle.value = t("PersonalManagement.Label.item4")
  1351. }
  1352. dialogDealResult.value = true
  1353. }
  1354. //重新提交
  1355. const submitDealResult = async () => {
  1356. if (flag.value) return
  1357. flag.value = true
  1358. dialogCheckConfirm.value = false
  1359. dialogCheckWait.value = true
  1360. let par = Host04 + DealResultResult.value
  1361. let dataList = {}
  1362. if (DealResultType.value == 3) dataList = { pin: dialogDealResult_form.pin }
  1363. else if (DealResultType.value == 4) dataList = { otp: dialogDealResult_form.otp }
  1364. else if (DealResultType.value == 6) {
  1365. dataList = {
  1366. state: dialogDealResult_form.state,
  1367. city: dialogDealResult_form.city,
  1368. country: dialogDealResult_form.country,
  1369. address: dialogDealResult_form.address,
  1370. zipCode: dialogDealResult_form.zipCode
  1371. }
  1372. } else if (DealResultType.value == 7) dataList = { phone: dialogDealResult_form.phone }
  1373. let res = await financialApi.PayDealResult(par, dataList)
  1374. dialogCheckWait.value = false
  1375. dialogDealResult.value = false
  1376. if (res.code == Code.StatusOK) {
  1377. if (res.data && (res.data.type == 3 || res.data.type == 4 || res.data.type == 6 || res.data.type == 7)) {
  1378. dealResult(res.data)
  1379. } else {
  1380. if (res.data.type == 1) {
  1381. goPayLink.value = res.data.result
  1382. window.open(res.data.result)
  1383. } else if (res.data.type == 2) {
  1384. let token = userToken.value
  1385. token = tool.tokenReplace(token)
  1386. goPayLink.value = `${Host04}/finance/deposit/get?serial=${res.data.result}&Access-Token=${token}`
  1387. window.open(goPayLink.value)
  1388. } else if (res.data.type == 5) {
  1389. $pigeon.MessageConfirm(
  1390. t("PersonalManagement.Label.item2"),
  1391. t("Msg.SystemPrompt"),
  1392. t("Btn.Cancel"),
  1393. t("Btn.Confirm"),
  1394. async () => { },
  1395. () => {
  1396. goPayLink.value = res.data.result
  1397. dialogCheck.value = true
  1398. dialogVisible.value = true
  1399. window.open(res.data.result)
  1400. }
  1401. )
  1402. } else if (res.data.type == 8) {
  1403. goPayLink.value = Host04 + res.data.result
  1404. window.open(goPayLink.value)
  1405. } else if (res.data.type == 9) {
  1406. dialogCheckOK.value = true
  1407. dialogVisible.value = true
  1408. flag.value = false
  1409. return
  1410. }
  1411. if (res.data.type != 5) {
  1412. dialogCheck.value = true
  1413. dialogVisible.value = true
  1414. }
  1415. }
  1416. flag.value = false
  1417. } else {
  1418. RES.value = res.msg
  1419. dialogCheck.value = true
  1420. dialogVisible.value = false
  1421. flag.value = false
  1422. dialogDealResult.value = false
  1423. }
  1424. }
  1425. const closeErrorDia = () => {
  1426. dialogCheck.value = false
  1427. dialogVisible.value = false
  1428. dialogCheckOK.value = false
  1429. }
  1430. const closeDia = () => {
  1431. closeErrorDia()
  1432. showTable()
  1433. }
  1434. const isStep3Open = () => {
  1435. isStep3.value = true
  1436. //中国网银弹窗
  1437. if (tableData.China_UnionPay.length && tableData.China_UnionPay[0].type == 2) {
  1438. let timezone = 8
  1439. let offset_GMT = new Date().getTimezoneOffset()
  1440. let nowDate = new Date().getTime()
  1441. let now = new Date(nowDate + offset_GMT * 60 * 1000 + timezone * 60 * 60 * 1000)
  1442. let newTime = now.getHours().toString()
  1443. if ((newTime.length == 1 && newTime >= 0 && newTime < 8) || (newTime.length == 2 && newTime >= 22 && newTime < 24)) {
  1444. dialogChinaUnionPay.value = true
  1445. }
  1446. }
  1447. }
  1448. // 判断是否在9月30日晚上12点之后,用于隐藏特定活动
  1449. const isAfterSeptember30 = () => {
  1450. // const currentDate = new Date();
  1451. // const september30 = new Date(
  1452. // currentDate.getFullYear(),
  1453. // 8,
  1454. // 30,
  1455. // 23,
  1456. // 59,
  1457. // 59
  1458. // ); // 月份从0开始,8表示9月,设置为23:59:59
  1459. // return currentDate > september30;
  1460. return true
  1461. }
  1462. const getMetaInfo = () => {
  1463. metaInfo.value = window.getMetaInfo()
  1464. metaInfo.value = { ...metaInfo.value, deviceType: "h5" }
  1465. }
  1466. //获取kyc二维码
  1467. const qrCode = async (depositChannelCode, row) => {
  1468. getMetaInfo()
  1469. let res = await activityApi.getWebsdkLink({
  1470. depositChannelCode,
  1471. metaInfo: metaInfo.value
  1472. })
  1473. if (res.code == Code.StatusOK) {
  1474. if (res.data) {
  1475. text1.value = JSON.parse(res.data).url
  1476. dialogKyc.value = true
  1477. flag.value = false
  1478. } else {
  1479. doShowStep3(row)
  1480. }
  1481. } else {
  1482. flag.value = false
  1483. uni.showToast({ title: res.msg, icon: 'none' })
  1484. }
  1485. }
  1486. const doShowStep3 = (row) => {
  1487. if (row.confirmCreditCard == 1) getBankInfo()
  1488. getCheckExistSuccess()
  1489. if (row.bankValid && isChannel.value) {
  1490. getBankList(row)
  1491. isChannel.value = false
  1492. step3.value = true
  1493. Object.assign(channelData, row)
  1494. console.log(channel.value, channelListOptions.value, channelData, 1112);
  1495. mAmount.minAmount = row.minAmount
  1496. mAmount.maxAmount = row.maxAmount
  1497. } else {
  1498. step3.value = true
  1499. bankDate.value = []
  1500. Object.assign(channelData, row)
  1501. mAmount.minAmount = row.minAmount
  1502. mAmount.maxAmount = row.maxAmount
  1503. }
  1504. tableData.International_Transfer = []
  1505. tableData.China_UnionPay = []
  1506. tableData.Digital_Currency = []
  1507. tableData.Electronic_Wallet = []
  1508. tableData.Ucard_Wallet = []
  1509. if (row.type == 1) tableData.International_Transfer[0] = row
  1510. if (row.type == 2) tableData.China_UnionPay[0] = row
  1511. if (row.type == 3) tableData.Digital_Currency[0] = row
  1512. if (row.type == 4) tableData.Electronic_Wallet[0] = row
  1513. if (row.type == 5) tableData.Ucard_Wallet[0] = row
  1514. introduce.introduce = row.introduce
  1515. introduce.enIntroduce = row.enIntroduce
  1516. if (row.code == "UNION_PAY_TELEGRAPHIC" || row.code == "UNION_PAY_TELEGRAPHIC_SPECIAL" || row.code == "UNION_PAY_TELEGRAPHIC_TWO" || (row.code && row.code.indexOf('DIGITAL_PAY_TYPE_KEY') === 0)) {
  1517. let pro = []
  1518. if (row.property && row.property.substring(0, 1) == "[") {
  1519. pro = JSON.parse(row.property)
  1520. } else if (row.property && row.property.substring(0, 1) != "[") {
  1521. let proper = "[" + row.property + "]"
  1522. pro = JSON.parse(proper)
  1523. }
  1524. let ind = pro.length
  1525. if (ind) {
  1526. let index = parseInt(Math.random() * ind + 1)
  1527. Object.assign(WireTransferAccount, pro[index - 1])
  1528. actionAdd1.value = Host80 + "/common/upload"
  1529. } else {
  1530. Object.assign(WireTransferAccount, {})
  1531. actionAdd1.value = Host80 + "/common/upload"
  1532. }
  1533. }
  1534. }
  1535. //选择支付方式
  1536. const isShowStep3 = (row) => {
  1537. if (row.kycChannel != 1) {
  1538. doShowStep3(row)
  1539. } else {
  1540. qrCode(row.code, row)
  1541. }
  1542. }
  1543. //更换支付方式
  1544. const showTable = () => {
  1545. resetForm();
  1546. dialogCheckWait.value = false;
  1547. dialogVisible.value = false;
  1548. flag.value = false;
  1549. form.bankUname = undefined
  1550. form.bankCardNum = undefined
  1551. form.cvv = undefined
  1552. form.expiryMonth = undefined
  1553. form.expiryYear = undefined
  1554. form.pin = undefined
  1555. myId.value = null
  1556. params.amount = ""
  1557. params.amount1 = ""
  1558. params.agree = false
  1559. params.agree2 = false
  1560. params.agree3 = false
  1561. params.agree4 = false
  1562. params.agree5 = false
  1563. params.agree6 = false
  1564. params.promoCode = ""
  1565. isChannel.value = true
  1566. imageUrl.value = ""
  1567. requiteVoucherUrl.value = ""
  1568. code.value = ""
  1569. WireTransferAccount.bankMsg = ""
  1570. introduce.introduce = ""
  1571. introduce.enIntroduce = ""
  1572. }
  1573. const loginComboxOptions = computed(() => {
  1574. return loginOptions.value.map((item) => ({
  1575. text: item.label,
  1576. value: item.login
  1577. }))
  1578. })
  1579. const creditCardOptions = computed(() => {
  1580. return ruleForm.bankCredit.map((item, index) => ({
  1581. text: `${item.bankUname}-${item.bankCardNum}`,
  1582. value: item.id
  1583. }))
  1584. })
  1585. const bankOptions = computed(() => {
  1586. return bankDate.value.map((item, index) => ({
  1587. text: (locale.value === 'cn' || locale.value === 'zhHant') ? item.name : item.enName,
  1588. value: item.code
  1589. }))
  1590. })
  1591. // 获取账户信息
  1592. const getDateList = async () => {
  1593. loading.value = true
  1594. let res = await customApi.CustomDropdown({ platform: "" })
  1595. if (res.code == Code.StatusOK) {
  1596. loginOptions.value = res.data.map(item => ({
  1597. ...item,
  1598. label: `${item.login} - ${groupTypeName(item.type)} - ${t('Custom.Deposit.AvailableBalance')}${groupCurrency(item.currency)}${item.balance}`
  1599. }))
  1600. const pages = getCurrentPages()
  1601. const route = pages[pages.length - 1].$page?.options || {}
  1602. if (route.login) {
  1603. const found = loginOptions.value.find(opt => opt.login === Number(route.login))
  1604. loginValue.value = found.login
  1605. loginValueDoc.value = found.label
  1606. step2.value = true
  1607. }
  1608. } else {
  1609. uni.showToast({ title: res.msg, icon: 'none' })
  1610. }
  1611. loading.value = false
  1612. }
  1613. //获取入金通道
  1614. const getDepositList = async () => {
  1615. pictLoading.value = true
  1616. tableData.International_Transfer = []
  1617. tableData.China_UnionPay = []
  1618. tableData.Digital_Currency = []
  1619. tableData.Electronic_Wallet = []
  1620. tableData.Ucard_Wallet = []
  1621. let res = await financialApi.RemittanceChannelList({})
  1622. if (res.code == Code.StatusOK) {
  1623. res.data.forEach(item => {
  1624. if (item.type == 1) tableData.International_Transfer.push(item), tableData1.International_Transfer.push(item)
  1625. if (item.type == 2) tableData.China_UnionPay.push(item), tableData1.China_UnionPay.push(item)
  1626. if (item.type == 3) tableData.Digital_Currency.push(item), tableData1.Digital_Currency.push(item)
  1627. if (item.type == 4) tableData.Electronic_Wallet.push(item), tableData1.Electronic_Wallet.push(item)
  1628. if (item.type == 5) tableData.Ucard_Wallet.push(item), tableData1.Ucard_Wallet.push(item)
  1629. })
  1630. pictLoading.value = false
  1631. } else {
  1632. uni.showToast({ title: res.msg, icon: 'none' })
  1633. pictLoading.value = false
  1634. }
  1635. }
  1636. //获取银行列表
  1637. const getBankList = async (row) => {
  1638. let res = await financialApi.BankList({ channelCode: row.code })
  1639. try {
  1640. if (res.code == Code.StatusOK) {
  1641. let bank = res.data
  1642. let data = []
  1643. bank.forEach(j => {
  1644. if (!j.minAmount && j.minAmount != 0) j.minAmount = row.minAmount
  1645. if (!j.maxAmount && j.maxAmount != 0) j.maxAmount = row.maxAmount
  1646. j.bankValid = row.bankValid
  1647. j.requestUrl = row.requestUrl
  1648. data.push(j)
  1649. })
  1650. bankDate.value = data
  1651. } else {
  1652. uni.showToast({ title: res.msg, icon: 'none' })
  1653. }
  1654. } catch (error) {
  1655. uni.showToast({ title: error.msg, icon: 'none' })
  1656. }
  1657. }
  1658. //获取20赠金活动信息
  1659. const getCheckExistSuccess = async () => {
  1660. let res = await financialApi.depositCheckExistSuccess({})
  1661. if (res.code == Code.StatusOK) {
  1662. CheckExistSuccess.value = res.data
  1663. } else {
  1664. uni.showToast({ title: res.msg, icon: 'none' })
  1665. }
  1666. }
  1667. //20赠金是否到期-4月30号23:59:59的时候关闭申请
  1668. const is20Open = () => {
  1669. let endTime1 = "2023/04/30 23:59:59"
  1670. let timezone = 2
  1671. let offset_GMT = new Date().getTimezoneOffset()
  1672. let nowDate = new Date().getTime()
  1673. let now = new Date(nowDate + offset_GMT * 60 * 1000 + timezone * 60 * 60 * 1000).getTime()
  1674. let end = new Date(endTime1).getTime()
  1675. if (now > end) anshiClose.value = false
  1676. }
  1677. //限时活动
  1678. const ActivityRequiteInfo = async () => {
  1679. let res = await activityApi.ActivityRequiteInfo({})
  1680. if (res.code == Code.StatusOK) {
  1681. limitedStatus.value = res.data
  1682. } else {
  1683. uni.showToast({ title: res.msg, icon: 'none' })
  1684. }
  1685. }
  1686. //2023年中赠金活动数据-10
  1687. const Activity24nianzhongInfo = async () => {
  1688. let res = await activityApi.Activity23nianzhongInfo({})
  1689. if (res.code == Code.StatusOK) {
  1690. Object.assign(tableData4, res.data)
  1691. // const Data4 = {
  1692. // "activityEndTime": null,
  1693. // "activityStartTime": null,
  1694. // "applicationEndTime": null,
  1695. // "applicationStartTime": null,
  1696. // "loginTypes": [5, 6],
  1697. // "show": 1,
  1698. // "useApply": 1
  1699. // };
  1700. // Object.assign(tableData4, Data4)
  1701. // tableData4Flag.value = tableData4.show == 1 && tableData4.useApply == 1
  1702. } else {
  1703. uni.showToast({ title: res.msg, icon: 'none' })
  1704. }
  1705. }
  1706. //2023年中赠金活动数据-20
  1707. const Activity24nianzhongTwoInfo = async () => {
  1708. let res = await activityApi.Activity23nianzhongTwoInfo({})
  1709. if (res.code == Code.StatusOK) {
  1710. Object.assign(tableData4Two, res.data)
  1711. // const Data4 = {
  1712. // "activityEndTime": null,
  1713. // "activityStartTime": null,
  1714. // "applicationEndTime": null,
  1715. // "applicationStartTime": null,
  1716. // "loginTypes": [5, 6],
  1717. // "show": 1,
  1718. // "useApply": 1
  1719. // };
  1720. // Object.assign(tableData4Two, Data4)
  1721. // tableData4Flag.value = tableData4Two.show == 1 && tableData4Two.useApply == 1
  1722. } else {
  1723. uni.showToast({ title: res.msg, icon: 'none' })
  1724. }
  1725. }
  1726. //2023年中赠金活动权限
  1727. const get23nianzhongTwoLogin = async (newVal) => {
  1728. let res = await activityApi.Activity23nianzhongTwoLogin({ login: newVal })
  1729. if (res.code == Code.StatusOK) {
  1730. Object.assign(tableData4Two, res.data)
  1731. tableData4TwoFlag.value = tableData4Two.show == 1
  1732. } else {
  1733. uni.showToast({ title: res.msg, icon: 'none' })
  1734. }
  1735. }
  1736. const getActivityExtensionGiveLogin = async (newVal) => {
  1737. let res = await activityApi.ActivityExtensionGiveLogin({ login: newVal })
  1738. if (res.code == Code.StatusOK) {
  1739. Object.assign(tableDataNewList, res.data)
  1740. tableDataNewListFlag.value = tableDataNewList.show == 1
  1741. } else {
  1742. uni.showToast({ title: res.msg, icon: 'none' })
  1743. }
  1744. }
  1745. const getActivityExtensionGiveLoginJoin = async (newVal) => {
  1746. let res = await activityApi.ActivityExtensionGiveLoginJoin({ login: newVal })
  1747. if (res.code == Code.StatusOK) {
  1748. giveLoginJoin.value = res.data
  1749. } else {
  1750. uni.showToast({ title: res.msg, icon: 'none' })
  1751. giveLoginJoin.value = ""
  1752. }
  1753. }
  1754. //24新年庆典 开始
  1755. const isNewYear24Open = () => {
  1756. let endTime1 = "2025/3/31 23:59:59"
  1757. let startTime1 = "2025/1/1 00:00:00"
  1758. let timezone = 2
  1759. let offset_GMT = new Date().getTimezoneOffset()
  1760. let nowDate = new Date().getTime()
  1761. let now = new Date(nowDate + offset_GMT * 60 * 1000 + timezone * 60 * 60 * 1000).getTime()
  1762. let end = new Date(endTime1).getTime()
  1763. let start = new Date(startTime1).getTime()
  1764. if (now < end && start < now) ActivityNewYear24()
  1765. }
  1766. const ActivityNewYear24 = async () => {
  1767. let res = await activityApi.ActivityNewYear24({})
  1768. if (res.code == Code.StatusOK) {
  1769. tableDataNewYear24.value = res.data
  1770. if (typeof tableDataNewYear24.value == "object") toIncome()
  1771. } else {
  1772. uni.showToast({ title: res.msg, icon: 'none' })
  1773. }
  1774. }
  1775. const toIncome = () => {
  1776. let balance = Number(tableDataNewYear24.value.balance) || 0
  1777. tableDataNewYear24.value.details.forEach((item, index) => {
  1778. if (balance > item.min && balance <= item.max) {
  1779. NewYear24Data.rate = item.rate
  1780. NewYear24Data.index = item.index
  1781. NewYear24Data.balance = (Number(tableDataNewYear24.value.details[index + 1].min) - balance).toFixed(2)
  1782. NewYear24Data.income = ((Number(tableDataNewYear24.value.details[index + 1].min) * Number(tableDataNewYear24.value.details[index + 1].rate) / 100 / 365) * 365).toFixed(2)
  1783. tableDataNewYear24Flag.value = true
  1784. } else if (balance > item.min && balance >= item.max && item.max == 0) {
  1785. tableDataNewYear24Flag.value = false
  1786. }
  1787. })
  1788. }
  1789. //24新年庆典 结束
  1790. // 新改内容
  1791. // userStore.paymentChannel.value
  1792. // userStore.channelList.value
  1793. const channel = computed(() => userStore.paymentChannel)
  1794. const channelList = computed(() => userStore.channelList)
  1795. const channelListOptions = ref([])
  1796. const channelId = ref(null)
  1797. const loading = ref(false)
  1798. const setAllAmount = () => {
  1799. const found = loginOptions.value.find(opt => opt.login === Number(loginValue.value))
  1800. params.amount = parseInt(found.balance)
  1801. validateAmount()
  1802. }
  1803. const allTabs = computed(() => {
  1804. return {
  1805. "Digital_Currency": t('Custom.Deposit.Channel3'),
  1806. "China_UnionPay": t('Custom.Deposit.Channel2'),
  1807. "Electronic_Wallet": t('Custom.Deposit.Channel4'),
  1808. "International_Transfer": t('Custom.Deposit.Channel1'),
  1809. "Ucard_Wallet": t('card.title'),
  1810. }
  1811. })
  1812. function formatChannels(data) {
  1813. const result = []
  1814. // 遍历每个分类
  1815. for (const key in data) {
  1816. const list = data[key] || []
  1817. // 插入分类标题(禁用项)
  1818. if (list.length) {
  1819. result.push({
  1820. text: allTabs.value[key],
  1821. value: key,
  1822. disable: true
  1823. })
  1824. }
  1825. list.forEach(item => {
  1826. result.push({
  1827. ...item,
  1828. text: `${item.name}`,
  1829. value: item.code
  1830. })
  1831. })
  1832. }
  1833. return result
  1834. }
  1835. // 生命周期
  1836. onMounted(() => {
  1837. if (channelList.value) {
  1838. channelListOptions.value = formatChannels(channelList.value)
  1839. }
  1840. channelId.value = channel.value
  1841. getDateList()
  1842. isStep3Open()
  1843. setTimeout(() => {
  1844. if (country.value === "VN") dialogVietnamNotice.value = true
  1845. is20Open()
  1846. // Activity24nianzhongInfo();
  1847. // Activity24nianzhongTwoInfo();
  1848. // dealResult({ "type": 7, "result": "/krad/pin?serial=123123" })
  1849. isNewYear24Open()
  1850. ActivityRequiteInfo()
  1851. }, 800);
  1852. })
  1853. onUnmounted(() => {
  1854. // userStore.savePaymentChannel('')
  1855. // userStore.saveChannelList('')
  1856. })
  1857. watch(channelId, async (newVal) => {
  1858. if (newVal) {
  1859. showTable()
  1860. let row = channelListOptions.value.find(item => item.code == newVal)
  1861. console.log(newVal, channelListOptions, 12);
  1862. console.log(row, 12);
  1863. isShowStep3(row, 1111)
  1864. setTipsAmount()
  1865. }
  1866. });
  1867. watch(isStep3, async (newVal) => {
  1868. if (newVal) {
  1869. await nextTick();
  1870. formRef.value?.clearValidate();
  1871. resetForm();
  1872. await nextTick();
  1873. formRef.value?.clearValidate();
  1874. }
  1875. });
  1876. // Watch
  1877. watch(loginValue, (login) => {
  1878. if (login) {
  1879. step3.value = true
  1880. get23nianzhongTwoLogin(login);
  1881. getActivityExtensionGiveLogin(login);
  1882. getActivityExtensionGiveLoginJoin(login);
  1883. // showCentAccountTransferTip(login);
  1884. setTipsAmount()
  1885. }
  1886. })
  1887. watch(() => params.amount, (newVal) => {
  1888. if (newVal && channelData.rate) {
  1889. params.amount1 = (newVal * channelData.rate).toFixed(2)
  1890. }
  1891. })
  1892. watch(() => channelData.rate, (newVal) => {
  1893. console.log(newVal, 'channel')
  1894. if (newVal && params.amount) {
  1895. params.amount1 = (newVal * params.amount).toFixed(2)
  1896. }
  1897. })
  1898. watch(() => imageUrl, (newVal) => {
  1899. console.log(newVal, 12);
  1900. }, { deep: true })
  1901. watch(() => params.agree3, (newVal) => {
  1902. if (newVal) {
  1903. params.agree2 = false
  1904. params.agree4 = false
  1905. params.agree5 = false
  1906. params.agree6 = false
  1907. }
  1908. })
  1909. watch(() => params.agree2, (newVal) => {
  1910. if (newVal) {
  1911. params.agree3 = false
  1912. params.agree4 = false
  1913. params.agree5 = false
  1914. params.agree6 = false
  1915. }
  1916. })
  1917. watch(() => params.agree4, (newVal) => {
  1918. if (newVal) {
  1919. params.agree3 = false
  1920. params.agree2 = false
  1921. params.agree5 = false
  1922. params.agree6 = false
  1923. }
  1924. })
  1925. watch(() => params.agree5, (newVal) => {
  1926. if (newVal) {
  1927. params.agree3 = false
  1928. params.agree2 = false
  1929. params.agree4 = false
  1930. params.agree6 = false
  1931. }
  1932. })
  1933. watch(() => params.agree6, (newVal) => {
  1934. if (newVal) {
  1935. params.agree3 = false
  1936. params.agree2 = false
  1937. params.agree4 = false
  1938. params.agree5 = false
  1939. if (giveLoginJoin.value.flag == false) {
  1940. let tips = ""
  1941. if (giveLoginJoin.value.promptType == 1) tips = t("surplusList.item10")
  1942. else tips = t("surplusList.item11")
  1943. if (giveLoginJoin.value.activityCategory == 1) {
  1944. $pigeon.MessageConfirm(
  1945. tips,
  1946. t("Msg.SystemPrompt"),
  1947. t("surplusList.item12"),
  1948. t("Home.msg.item3"),
  1949. () => {
  1950. $pigeon.MessageConfirm(
  1951. t("surplusList.item13"),
  1952. t("Msg.SystemPrompt"),
  1953. t("Btn.Confirm"),
  1954. t("Btn.Cancel"),
  1955. async () => {
  1956. try {
  1957. const res = await activityApi.ActivityGiveCancel({ login: loginValue.value, })
  1958. if (res.code == Code.StatusOK) $pigeon.MessageOK(res.msg || t("Msg.Success"))
  1959. else uni.showToast({ title: res.msg, icon: 'none' })
  1960. } catch (error) {
  1961. $pigeon.MessageError(t("Msg.Fail"))
  1962. }
  1963. },
  1964. () => { params.agree6 = false }
  1965. )
  1966. },
  1967. () => { },
  1968. { showCancelButton: true }
  1969. )
  1970. } else if (giveLoginJoin.value.activityCategory == 2) {
  1971. $pigeon.MessageConfirm(
  1972. tips,
  1973. t("Msg.SystemPrompt"),
  1974. "跳转",
  1975. t("Btn.Cancel"),
  1976. () => {
  1977. $pigeon.MessageConfirm(
  1978. "是否跳转到对应活动取消",
  1979. t("Msg.SystemPrompt"),
  1980. t("Btn.Confirm"),
  1981. t("Btn.Cancel"),
  1982. () => {
  1983. uni.navigateTo({ url: "/pages/customer/monthly/list" })
  1984. },
  1985. () => { params.agree6 = false }
  1986. )
  1987. },
  1988. () => { },
  1989. { showCancelButton: false }
  1990. )
  1991. } else {
  1992. $pigeon.MessageConfirm(
  1993. tips,
  1994. t("Msg.SystemPrompt"),
  1995. t("Btn.Confirm"),
  1996. t("Btn.Cancel")
  1997. )
  1998. }
  1999. }
  2000. }
  2001. })
  2002. </script>
  2003. <style lang="scss" scoped>
  2004. @import "@/uni.scss";
  2005. :deep(.base-info-form .uni-forms-item.agree) {
  2006. label {
  2007. display: flex;
  2008. align-items: flex-start;
  2009. gap: px2rpx(8);
  2010. text {
  2011. color: #000;
  2012. font-weight: 600;
  2013. font-size: px2rpx(14);
  2014. line-height: 1.5;
  2015. }
  2016. }
  2017. }
  2018. .custom-deposit {
  2019. width: px2rpx(566);
  2020. flex-shrink: 0;
  2021. .crm-title-box {
  2022. margin-bottom: px2rpx(20);
  2023. .tit {
  2024. font-size: px2rpx(20);
  2025. font-weight: 700;
  2026. color: var(--bs-heading-color);
  2027. }
  2028. }
  2029. .box {
  2030. margin-bottom: px2rpx(20);
  2031. .b-card {
  2032. // background: #fff;
  2033. // border-radius: px2rpx(12);
  2034. // padding: px2rpx(20);
  2035. // box-shadow: 0 px2rpx(4) px2rpx(12) rgba(0, 0, 0, 0.03);
  2036. .card-top {
  2037. .tit {
  2038. font-size: px2rpx(16);
  2039. font-weight: 600;
  2040. margin-bottom: px2rpx(16);
  2041. display: flex;
  2042. align-items: center;
  2043. color: var(--bs-heading-color);
  2044. position: relative;
  2045. padding-left: 20px;
  2046. &:after {
  2047. content: '';
  2048. position: absolute;
  2049. left: 0;
  2050. top: 50%;
  2051. transform: translateY(-50%);
  2052. width: 0;
  2053. height: 0;
  2054. border-top: 6px solid transparent;
  2055. border-bottom: 6px solid transparent;
  2056. border-left: 8px solid currentColor;
  2057. }
  2058. }
  2059. }
  2060. .channelType {
  2061. font-size: px2rpx(15);
  2062. font-weight: 600;
  2063. margin: px2rpx(24) 0 px2rpx(12);
  2064. color: var(--color-navy-700);
  2065. padding-left: px2rpx(8);
  2066. border-left: px2rpx(4) solid var(--color-primary);
  2067. }
  2068. }
  2069. }
  2070. .reselect-btn {
  2071. margin-top: px2rpx(20);
  2072. display: flex;
  2073. justify-content: flex-end;
  2074. .reselect {
  2075. background-color: var(--color-zinc-100);
  2076. color: var(--color-navy-700);
  2077. border: none;
  2078. font-size: px2rpx(14);
  2079. padding: px2rpx(8) px2rpx(20);
  2080. border-radius: px2rpx(8);
  2081. &:active {
  2082. background-color: var(--color-zinc-200);
  2083. }
  2084. }
  2085. }
  2086. .s-btn[type="primary"] {
  2087. width: 100%;
  2088. height: px2rpx(48);
  2089. background-color: #cf1322;
  2090. color: var(--bs-emphasis-color);
  2091. border-radius: px2rpx(12);
  2092. font-size: px2rpx(16);
  2093. font-weight: 600;
  2094. display: flex;
  2095. align-items: center;
  2096. justify-content: center;
  2097. border: none;
  2098. margin-top: px2rpx(30);
  2099. transition: all 0.2s;
  2100. &:active {
  2101. transform: scale(0.98);
  2102. background-color: #cf1322;
  2103. }
  2104. }
  2105. .add-back {
  2106. display: flex;
  2107. justify-content: space-between;
  2108. align-items: center;
  2109. margin-bottom: px2rpx(12);
  2110. padding: px2rpx(12) px2rpx(16);
  2111. background: var(--color-zinc-100);
  2112. border-radius: px2rpx(8);
  2113. text {
  2114. font-size: px2rpx(14);
  2115. color: var(--color-navy-700);
  2116. font-weight: 500;
  2117. }
  2118. .add-btn {
  2119. color: var(--color-primary);
  2120. font-weight: 600;
  2121. text-decoration: underline;
  2122. &:active {
  2123. opacity: 0.7;
  2124. }
  2125. }
  2126. }
  2127. .wire-transfer-account {
  2128. background: var(--color-zinc-50);
  2129. padding: px2rpx(16);
  2130. border-radius: px2rpx(12);
  2131. margin: px2rpx(16) 0;
  2132. // .row {
  2133. // display: flex;
  2134. // margin-bottom: px2rpx(12);
  2135. // font-size: px2rpx(14);
  2136. // &:last-child {
  2137. // margin-bottom: 0;
  2138. // }
  2139. // .label {
  2140. // width: px2rpx(120);
  2141. // color: var(--color-zinc-500);
  2142. // }
  2143. // .content {
  2144. // flex: 1;
  2145. // color: var(--bs-heading-color);
  2146. // font-weight: 500;
  2147. // }
  2148. // .SpecialColor {
  2149. // color: var(--color-error);
  2150. // }
  2151. // }
  2152. }
  2153. .activities {
  2154. margin: px2rpx(24) 0;
  2155. .checkbox {
  2156. display: flex;
  2157. align-items: flex-start;
  2158. gap: px2rpx(8);
  2159. margin-bottom: px2rpx(12);
  2160. :deep(uni-checkbox .uni-checkbox-input) {
  2161. border-radius: px2rpx(4);
  2162. width: px2rpx(18);
  2163. height: px2rpx(18);
  2164. }
  2165. text {
  2166. font-size: px2rpx(14);
  2167. color: var(--color-navy-700);
  2168. font-weight: 500;
  2169. line-height: 1.5;
  2170. }
  2171. }
  2172. .clause-text {
  2173. font-size: px2rpx(13);
  2174. color: var(--color-zinc-500);
  2175. line-height: 1.6;
  2176. padding-left: px2rpx(26);
  2177. .clause {
  2178. color: var(--color-primary);
  2179. text-decoration: underline;
  2180. }
  2181. }
  2182. }
  2183. .step3-attention {
  2184. // background: var(--color-error-50, #fff1f0);
  2185. border-radius: px2rpx(12);
  2186. margin-bottom: px2rpx(20);
  2187. .tips {
  2188. line-height: 1.8;
  2189. font-size: px2rpx(12);
  2190. color: var(--bs-heading-color);
  2191. background-color: rgba(var(--bs-body-bg-rgb), 1) !important;
  2192. padding: px2rpx(12);
  2193. border-radius: px2rpx(4);
  2194. border-left: px2rpx(2) solid #cf1322;
  2195. .title {
  2196. font-weight: 600;
  2197. margin-bottom: px2rpx(6);
  2198. color: var(--bs-heading-color);
  2199. }
  2200. }
  2201. .attention {
  2202. font-size: px2rpx(14);
  2203. // color: var(--color-error-600, #cf1322);
  2204. line-height: 1.6;
  2205. }
  2206. .btn-bottom {
  2207. margin-top: px2rpx(20);
  2208. display: flex;
  2209. justify-content: center;
  2210. .btn {
  2211. color: var(--bs-emphasis-color);
  2212. padding: px2rpx(10) px2rpx(48);
  2213. border-radius: px2rpx(24);
  2214. font-size: px2rpx(15);
  2215. font-weight: 700;
  2216. box-shadow: 0 px2rpx(4) px2rpx(10) rgba(207, 19, 34, 0.2);
  2217. transition: all 0.2s;
  2218. &:active {
  2219. transform: scale(0.96);
  2220. opacity: 0.8;
  2221. }
  2222. }
  2223. }
  2224. }
  2225. .upload-box {
  2226. display: flex;
  2227. align-items: center;
  2228. gap: px2rpx(12);
  2229. .btn-upload {
  2230. background: var(--color-zinc-100);
  2231. border: px2rpx(1) dashed var(--color-zinc-300);
  2232. border-radius: px2rpx(8);
  2233. height: px2rpx(44);
  2234. font-size: px2rpx(14);
  2235. color: var(--color-zinc-600);
  2236. display: flex;
  2237. align-items: center;
  2238. justify-content: center;
  2239. padding: 0 px2rpx(20);
  2240. }
  2241. .img-preview {
  2242. width: px2rpx(44);
  2243. height: px2rpx(44);
  2244. border-radius: px2rpx(4);
  2245. object-fit: cover;
  2246. }
  2247. }
  2248. .error {
  2249. color: var(--color-error);
  2250. font-size: px2rpx(12);
  2251. margin-top: px2rpx(4);
  2252. display: block;
  2253. }
  2254. :deep(.base-info-form) {
  2255. .uni-row1 {
  2256. .uni-col {
  2257. padding: 0 px2rpx(10) !important;
  2258. }
  2259. .uni-forms-item {
  2260. min-height: px2rpx(79);
  2261. margin-bottom: px2rpx(10);
  2262. position: relative;
  2263. }
  2264. .uni-easyinput__content-input {
  2265. height: px2rpx(35) !important;
  2266. }
  2267. }
  2268. }
  2269. .popup-content {
  2270. background: #fff;
  2271. border-radius: px2rpx(20);
  2272. padding: px2rpx(24);
  2273. width: px2rpx(320);
  2274. text-align: center;
  2275. .popup-title {
  2276. font-size: px2rpx(18);
  2277. font-weight: 700;
  2278. margin-bottom: px2rpx(20);
  2279. color: var(--bs-heading-color);
  2280. display: block;
  2281. }
  2282. .popup-text {
  2283. font-size: px2rpx(14);
  2284. line-height: 1.6;
  2285. color: var(--color-zinc-600);
  2286. margin-bottom: px2rpx(20);
  2287. display: block;
  2288. }
  2289. .popup-form {
  2290. background: var(--color-zinc-50);
  2291. border-radius: px2rpx(12);
  2292. padding: px2rpx(16);
  2293. margin-bottom: px2rpx(24);
  2294. text-align: left;
  2295. .popup-row {
  2296. display: flex;
  2297. justify-content: space-between;
  2298. margin-bottom: px2rpx(12);
  2299. font-size: px2rpx(14);
  2300. &:last-child {
  2301. margin-bottom: 0;
  2302. }
  2303. .label {
  2304. color: var(--color-zinc-500);
  2305. font-weight: 500;
  2306. }
  2307. text:not(.label) {
  2308. color: var(--bs-heading-color);
  2309. font-weight: 500;
  2310. }
  2311. .small-input {
  2312. width: px2rpx(60);
  2313. background: #fff;
  2314. border: px2rpx(1) solid var(--color-zinc-200);
  2315. border-radius: px2rpx(4);
  2316. padding: 0 px2rpx(4);
  2317. height: px2rpx(24);
  2318. font-size: px2rpx(12);
  2319. }
  2320. }
  2321. }
  2322. .popup-buttons {
  2323. display: flex;
  2324. gap: px2rpx(12);
  2325. button {
  2326. flex: 1;
  2327. height: px2rpx(44);
  2328. border-radius: px2rpx(10);
  2329. font-size: px2rpx(15);
  2330. font-weight: 600;
  2331. display: flex;
  2332. align-items: center;
  2333. justify-content: center;
  2334. border: none;
  2335. &[type="primary"] {
  2336. background-color: #cf1322;
  2337. color: var(--bs-emphasis-color);
  2338. }
  2339. &:not([type="primary"]) {
  2340. background: var(--color-zinc-100);
  2341. color: var(--color-zinc-600);
  2342. }
  2343. }
  2344. }
  2345. .result-icon {
  2346. display: flex;
  2347. justify-content: center;
  2348. margin-bottom: px2rpx(16);
  2349. .iconfont {
  2350. font-size: px2rpx(48);
  2351. &.iconchenggong {
  2352. color: #52c41a;
  2353. }
  2354. &.iconjingshi {
  2355. color: #faad14;
  2356. }
  2357. &.icondengdai {
  2358. color: var(--color-primary);
  2359. animation: rotate 2s linear infinite;
  2360. }
  2361. }
  2362. }
  2363. }
  2364. @keyframes rotate {
  2365. from {
  2366. transform: rotate(0deg);
  2367. }
  2368. to {
  2369. transform: rotate(360deg);
  2370. }
  2371. }
  2372. .avatar-uploader {
  2373. border: 1px dashed;
  2374. width: px2rpx(200);
  2375. height: px2rpx(150);
  2376. display: flex;
  2377. flex-direction: column;
  2378. align-items: center;
  2379. justify-content: center;
  2380. /*float: left;*/
  2381. //overflow: hidden;
  2382. }
  2383. :deep(.files-button) {
  2384. .file-item {
  2385. .icon,
  2386. .avatar {
  2387. width: px2rpx(200);
  2388. height: px2rpx(150);
  2389. }
  2390. }
  2391. }
  2392. }
  2393. .label-with-icon {
  2394. display: flex;
  2395. align-items: center;
  2396. gap: px2rpx(8);
  2397. uni-text {
  2398. font-weight: 600;
  2399. }
  2400. :deep(.uni-tooltip) {
  2401. display: flex;
  2402. align-items: center;
  2403. justify-content: center;
  2404. }
  2405. }
  2406. .tooltip-content {
  2407. :deep(.uni-tooltip-popup) {
  2408. background-color: #fff !important;
  2409. box-shadow: 0 2px 12px 0 rgba(0, 0, 0, 0.1) !important;
  2410. width: px2rpx(300) !important;
  2411. color: var(--color-zinc-500);
  2412. line-height: 1.6;
  2413. }
  2414. }
  2415. .help-icon {
  2416. margin-left: px2rpx(8);
  2417. width: px2rpx(16);
  2418. height: px2rpx(16);
  2419. background: var(--color-zinc-200);
  2420. border-radius: 50%;
  2421. display: flex;
  2422. align-items: center;
  2423. justify-content: center;
  2424. font-size: px2rpx(12);
  2425. color: var(--color-zinc-600);
  2426. cursor: pointer;
  2427. }
  2428. .amount-box {
  2429. display: flex;
  2430. align-items: center;
  2431. gap: px2rpx(12);
  2432. .amount-input {
  2433. flex: 1;
  2434. }
  2435. .btn {
  2436. display: flex;
  2437. align-items: center;
  2438. justify-content: center;
  2439. font-size: px2rpx(14);
  2440. margin-bottom: px2rpx(12);
  2441. height: px2rpx(35);
  2442. color: #fff;
  2443. border-radius: px2rpx(4);
  2444. font-weight: 600;
  2445. display: flex;
  2446. align-items: center;
  2447. justify-content: center;
  2448. border: none;
  2449. padding: 0 px2rpx(20);
  2450. margin-top: px2rpx(21);
  2451. cursor: pointer;
  2452. }
  2453. }
  2454. .custom-deposit-container {
  2455. width: 100%;
  2456. display: flex;
  2457. gap: px2rpx(60);
  2458. justify-content: space-between;
  2459. }
  2460. @media (max-width: 992px) {
  2461. .custom-deposit {
  2462. width: 100%;
  2463. margin-top: px2rpx(20);
  2464. }
  2465. .custom-deposit-container {
  2466. display: flex;
  2467. gap: px2rpx(30);
  2468. flex-wrap: wrap;
  2469. }
  2470. }
  2471. </style>