deposit.vue 98 KB

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