deposit.vue 101 KB

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