deposit.vue 99 KB

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