agent-transfer.vue 33 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036
  1. <template>
  2. <cwg-page-wrapper class="create-page" :isHeaderFixed="true">
  3. <cwg-header :title="t('Home.page_ib.item9')" />
  4. <view id="custom_IbTransfer" class="transfer-page">
  5. <view class="main-content">
  6. <!-- 步骤1:选择转出账户 -->
  7. <view class="box box-step1">
  8. <view class="b-card">
  9. <view class="card-top">
  10. <view class="card-row">
  11. <view class="tit">
  12. <text class="iconfont icon-caret-right"></text>
  13. <span>{{ t('Custom.Transfer.Title1') }}</span>
  14. </view>
  15. </view>
  16. <view class="card-row">
  17. <cwg-combox v-model:value="loginValue" :clearable="false" :options="withdrawDisplayList"
  18. :placeholder="t('placeholder.choose')" />
  19. </view>
  20. </view>
  21. </view>
  22. </view>
  23. <!-- 步骤2:转账表单 -->
  24. <view class="box box-step2" v-if="step2">
  25. <view class="b-card">
  26. <view class="card-top">
  27. <view class="card-row card-tit">
  28. <view class="title-wrapper">
  29. <view class="tit">
  30. <text class="iconfont icon-caret-right"></text>
  31. <span>{{ t('Custom.Transfer.Title2') }}</span>
  32. </view>
  33. </view>
  34. </view>
  35. <uni-forms ref="formRef" :model="form" :rules="rules" label-width="300" label-position="top"
  36. validate-trigger="submit">
  37. <view class="form-row">
  38. <view class="form-col">
  39. <!-- 转出账户 -->
  40. <uni-forms-item :label="t('Custom.Transfer.TransferAccounts')"
  41. name="withdrawLogin">
  42. <cwg-combox :disabled="true" v-model:value="form.withdrawLogin"
  43. :clearable="false" :options="withdrawDisplayList"
  44. :placeholder="t('placeholder.choose')" />
  45. </uni-forms-item>
  46. </view>
  47. </view>
  48. <view class="form-row">
  49. <view class="form-col">
  50. <!-- 转入账户 -->
  51. <uni-forms-item :label="t('Custom.Transfer.IntoAccount')" name="depositLogin">
  52. <cwg-combox v-model:value="form.depositLogin" :clearable="false"
  53. :options="depositDisplayList" :placeholder="t('placeholder.choose')" />
  54. </uni-forms-item>
  55. </view>
  56. <view class="form-col">
  57. <!-- 确认转入账户 -->
  58. <uni-forms-item :label="t('Custom.Transfer.ConfirmIntoAccount')"
  59. name="depositLogin1">
  60. <cwg-combox v-model:value="form.depositLogin1" :clearable="false"
  61. :options="depositDisplayList" :placeholder="t('placeholder.choose')" />
  62. </uni-forms-item>
  63. </view>
  64. </view>
  65. <view class="form-row">
  66. <view class="form-col">
  67. <!-- 货币类型 -->
  68. <uni-forms-item :label="t('Custom.Transfer.CurrencyType')" name="currency">
  69. <cwg-combox v-model:value="form.currency" :clearable="false"
  70. :options="currencyOptions" :placeholder="t('placeholder.choose')" />
  71. </uni-forms-item>
  72. </view>
  73. <view class="form-col">
  74. <!-- 转账金额 -->
  75. <uni-forms-item :label="t('Custom.Transfer.Amount')" name="amount"
  76. :error-message="amountErrorMessage">
  77. <uni-easyinput v-model="form.amount" :placeholder="t('placeholder.input')"
  78. @blur="validateAmount" />
  79. </uni-forms-item>
  80. </view>
  81. </view>
  82. <!-- 20%赠金-年中赠金 -->
  83. <view class="form-row" v-if="tableData4TwoFlag">
  84. <view class="form-col-full">
  85. <uni-forms-item class="agree" name="agree5">
  86. <view class="agree-content">
  87. <checkbox :checked="form.agree5" @click="form.agree5 = !form.agree5" />
  88. <view class="agree-text">
  89. <view class="agree-title">{{
  90. t('news_add_field1.activitiesNZTwo.itemDeposit1') }}</view>
  91. </view>
  92. </view>
  93. </uni-forms-item>
  94. <view class="agree-detail">
  95. <text>{{ t('news_add_field1.activitiesNZTwo.itemDeposit2') }}</text>
  96. <text class="clause" @click="dialogClauseNZTwo = true">{{
  97. t('news_add_field1.activitiesNZTwo.itemDeposit3') }}</text>
  98. <text>{{ t('news_add_field1.activitiesNZTwo.itemDeposit4') }}</text>
  99. </view>
  100. </view>
  101. </view>
  102. <!-- 赠送活动 -->
  103. <view class="form-row" v-if="tableDataNewListFlag">
  104. <view class="form-col-full">
  105. <uni-forms-item class="agree" name="agree6">
  106. <view class="agree-content">
  107. <checkbox :checked="form.agree6" @click="form.agree6 = !form.agree6" />
  108. <view class="agree-text">
  109. <view class="agree-title">{{ tableDataNewList.title }}</view>
  110. </view>
  111. </view>
  112. </uni-forms-item>
  113. <view class="agree-detail">
  114. <text>{{ t('news_add_field1.activitiesNewList.item1') }}</text>
  115. <text class="clause" @click="dialogClauseNewList = true">{{
  116. tableDataNewList.title }}</text>
  117. <text>{{ t('news_add_field1.activitiesNewList.item2') }}</text>
  118. </view>
  119. </view>
  120. </view>
  121. <view class="form-row">
  122. <view class="form-col-full">
  123. <uni-forms-item>
  124. <view class="tips">
  125. <view class="title">{{ t('Custom.Transfer.Tips') }}</view>
  126. <view>{{ t('Custom.Transfer.Tips1') }}</view>
  127. <view>{{ t('Custom.Transfer.Tips5') }}</view>
  128. <view>{{ t('Custom.Transfer.Tips3') }}</view>
  129. <view>{{ t('Custom.Transfer.Tips4') }}</view>
  130. </view>
  131. </uni-forms-item>
  132. </view>
  133. </view>
  134. <view class="form-row">
  135. <button class="s-btn reselect" type="primary" @click="toTransfer">{{ locale === 'es'
  136. ?
  137. 'Enviar solicitud' : t('Btn.Submit') }}</button>
  138. </view>
  139. </uni-forms>
  140. </view>
  141. </view>
  142. </view>
  143. </view>
  144. <!-- 失败弹窗 -->
  145. <cwg-error-popup v-model:visible="dialogError" @confirm="closeDia" />
  146. <!-- 成功弹窗 -->
  147. <cwg-success-popup v-model:visible="dialogSuccess" @confirm="closeDia" />
  148. <!-- 等待弹窗 -->
  149. <cwg-wait-popup v-model:visible="dialogCheckWait" type="center" :mask-click="false" :showFooters="false" />
  150. <!-- 不参加活动弹出框 -->
  151. <cwg-dont-active-popup v-model:visible="dialogDontActive" :showFooters="true" @confirm="tosubmitConfirm" />
  152. <!-- 功能关闭弹出 -->
  153. <cwg-function-disabled-popup v-model:visible="InfoStatus5" :showFooters="false" @confirm="toHome" />
  154. <!-- 赠金协议20年中 -->
  155. <BonusAgreementPopup v-model:visible="dialogClauseNZTwo" :title="t('news_add_field1.activitiesNZTwo.item6')"
  156. :type="nzTwo" :tableData4Two="tableData4Two" />
  157. <!-- 赠送活动协议 -->
  158. <BonusAgreementPopup v-model:visible="dialogClauseNewList" :title="tableDataNewList.title"
  159. :content="tableDataNewList.content" :type="newList" />
  160. </view>
  161. </cwg-page-wrapper>
  162. </template>
  163. <script setup>
  164. import { ref, reactive, computed, onMounted, watch, nextTick } from 'vue'
  165. import { useI18n } from 'vue-i18n'
  166. import { onLoad } from '@dcloudio/uni-app'
  167. import { getCurrentInstance } from 'vue'
  168. import { ibApi } from '@/service/ib'
  169. import { activityApi } from '@/service/activity'
  170. import { financialApi } from '@/service/financial'
  171. import Config from '@/config/index'
  172. import useUserStore from '@/stores/use-user-store'
  173. import BonusAgreementPopup from './components/BonusAgreementPopup.vue'
  174. const userStore = useUserStore()
  175. const ibInfo = computed(() => {
  176. return userStore?.userInfo?.ibInfo || {}
  177. })
  178. const { Code } = Config
  179. const { t, locale } = useI18n()
  180. // 获取全局实例(用于访问 Session、$pigeon 等)
  181. const { proxy } = getCurrentInstance()
  182. const $pigeon = proxy?.$pigeon
  183. // 响应式数据
  184. const loginValue = ref('')
  185. const flag = ref(false)
  186. const responseMessage = ref('') // 弹窗响应信息
  187. const giveLoginJoin = ref('')
  188. const loginOptions = ref([])
  189. const toOptions = ref([])
  190. const step2 = ref(false)
  191. const amountLimits = reactive({
  192. minAmount: '',
  193. maxAmount: '',
  194. })
  195. const form = reactive({
  196. currency: 'USD',
  197. depositLogin: null,
  198. depositLogin1: null,
  199. withdrawLogin: null,
  200. amount: '',
  201. agree5: false,
  202. agree6: false,
  203. })
  204. const resetForm = async () => {
  205. await nextTick();
  206. formRef.value?.clearValidate(); // 再次清除可能因数据重置产生的新错误
  207. form.customBankCode = ""
  208. form.depositLogin = ""
  209. form.depositLogin1 = ""
  210. form.withdrawLogin = ""
  211. form.amount = ""
  212. form.agree5 = false
  213. form.agree6 = false
  214. amountErrorMessage.value = ""
  215. submitting.value = false
  216. flag.value = false
  217. }
  218. const dialogSuccess = computed(() => dialogCheck.value && dialogVisible.value)
  219. const dialogError = computed(() => dialogCheck.value && !dialogVisible.value)
  220. const dialogCheck = ref(false)
  221. const dialogVisible = ref(false)
  222. const dialogCheckWait = ref(false)
  223. const InfoStatus5 = ref(false)
  224. const dialogClauseNZTwo = ref(false)
  225. const tableData4TwoFlag = ref(false)
  226. const tableData4Two = ref({})
  227. const dialogClauseNewList = ref(false)
  228. const tableDataNewListFlag = ref(false)
  229. const tableDataNewList = ref({})
  230. const dialogDontActive = ref(false)
  231. const submitting = ref(false)
  232. // 错误信息
  233. const amountErrorMessage = ref('')
  234. // 表单验证规则
  235. const rules = {
  236. withdrawLogin: {
  237. rules: [
  238. {
  239. required: true,
  240. errorMessage: t('vaildate.select.empty')
  241. },
  242. ],
  243. },
  244. depositLogin: {
  245. rules: [
  246. {
  247. required: true,
  248. errorMessage: t('vaildate.select.empty')
  249. },
  250. ],
  251. },
  252. depositLogin1: {
  253. rules: [
  254. {
  255. required: true,
  256. errorMessage: t('Custom.Transfer.ConfirmIntoAccount1')
  257. },
  258. {
  259. validateFunction: (rule, value, data, callback) => {
  260. if (value !== form.depositLogin) {
  261. callback(t('Custom.Transfer.ConfirmIntoAccount1'))
  262. }
  263. return true
  264. }
  265. },
  266. ],
  267. },
  268. amount: {
  269. rules: [
  270. {
  271. required: true,
  272. errorMessage: t('vaildate.amount.format'),
  273. },
  274. {
  275. validateFunction: (rule, value, data, callback) => {
  276. if (!value) {
  277. callback(t('vaildate.amount.format'))
  278. } else if (
  279. amountLimits.minAmount &&
  280. amountLimits.maxAmount &&
  281. (parseFloat(amountLimits.minAmount) > parseFloat(value) ||
  282. parseFloat(amountLimits.maxAmount) < parseFloat(value))
  283. ) {
  284. callback(t('vaildate.amount.amount') +
  285. amountLimits.minAmount +
  286. '-' +
  287. amountLimits.maxAmount)
  288. } else if (!/^[0-9]+([.]{1}[0-9]{1,2})?$/.test(value)) {
  289. callback(t('vaildate.amount.format'))
  290. }
  291. return true
  292. }
  293. },
  294. ],
  295. }
  296. }
  297. function validateAmount() {
  298. const amount = form.amount
  299. if (!amount) {
  300. amountErrorMessage.value = t('vaildate.amount.format')
  301. return false
  302. }
  303. const numValue = parseFloat(amount)
  304. if (isNaN(numValue)) {
  305. amountErrorMessage.value = t('vaildate.amount.format')
  306. return false
  307. }
  308. if (amountLimits.minAmount && numValue < parseFloat(amountLimits.minAmount)) {
  309. amountErrorMessage.value = t('vaildate.amount.amount') + amountLimits.minAmount + '-' + amountLimits.maxAmount
  310. return false
  311. }
  312. if (amountLimits.maxAmount && numValue > parseFloat(amountLimits.maxAmount)) {
  313. amountErrorMessage.value = t('vaildate.amount.amount') + amountLimits.minAmount + '-' + amountLimits.maxAmount
  314. return false
  315. }
  316. if (!/^[0-9]+([.]{1}[0-9]{1,2})?$/.test(amount)) {
  317. amountErrorMessage.value = t('vaildate.amount.format')
  318. return false
  319. }
  320. amountErrorMessage.value = ''
  321. return true
  322. }
  323. // 模板引用
  324. const formRef = ref(null)
  325. // 计算属性
  326. const getInfoStatus5 = computed(() => {
  327. if (ibInfo.value?.closeFunctions) {
  328. return ibInfo.value.closeFunctions.indexOf('5') !== -1
  329. }
  330. return false
  331. })
  332. // 单位类型
  333. function groupCurrency(type) {
  334. const map = { GBP: ': £', USD: ': $', EUR: ': €', USC: ': ¢' }
  335. return map[type] || ': $'
  336. }
  337. function groupCurrency1(type) {
  338. const map = { GBP: '£', USD: '$', EUR: '€', USC: '¢' }
  339. return map[type] || '$'
  340. }
  341. // 账户类型
  342. function groupTypeName(type) {
  343. const typeMap = {
  344. '1': t('AccountType.ClassicAccount'),
  345. '2': t('AccountType.SeniorAccount'),
  346. '5': t('AccountType.SpeedAccount'),
  347. '6': t('AccountType.SpeedAccount'),
  348. '7': t('AccountType.StandardAccount'),
  349. '8': t('AccountType.CentAccount')
  350. }
  351. return typeMap[type] || ''
  352. }
  353. // 转出账户列表
  354. const withdrawDisplayList = computed(() => {
  355. return loginOptions.value.map(item => ({
  356. text: `${item.login} - ${groupTypeName(item.type)} - ${t('Custom.Deposit.AvailableBalance')}${groupCurrency(item.currency)}${item.balance}`,
  357. value: item.login,
  358. disable: item.closeFunctions?.indexOf('3') != -1 || item.closeFunctions?.indexOf('5') != -1
  359. }))
  360. })
  361. // 转入账户列表
  362. const depositDisplayList = computed(() => {
  363. return toOptions.value.map(item => ({
  364. text: `${item.login} - ${item.cId || '--'} - ${groupTypeName(item.type)} - ${t('Custom.Deposit.AvailableBalance')}${groupCurrency(item.currency)}${item.balance}`,
  365. value: item.login
  366. }))
  367. })
  368. const currencyOptions = ref([{ value: 'USD', text: 'USD' }])
  369. function toHome() {
  370. uni.navigateTo({ url: '/pages/ib/index' })
  371. InfoStatus5.value = false
  372. }
  373. function closeDia() {
  374. resetForm()
  375. formRef.value?.resetFields?.()
  376. step2.value = false
  377. loginValue.value = ''
  378. dialogCheck.value = false
  379. dialogVisible.value = false
  380. tableData4TwoFlag.value = false
  381. tableDataNewListFlag.value = false
  382. }
  383. // 内转
  384. async function toTransfer() {
  385. if (submitting.value) return
  386. try {
  387. const valid = await formRef.value?.validate()
  388. if (!valid) {
  389. console.log('表单验证失败')
  390. return
  391. }
  392. openDontActive()
  393. } catch (error) {
  394. console.error('验证失败:', error)
  395. }
  396. }
  397. // 打开不参加活动弹窗
  398. function openDontActive() {
  399. tosubmitConfirm()
  400. }
  401. function tosubmitConfirm() {
  402. dialogDontActive.value = false
  403. transferConfig()
  404. }
  405. async function transferConfig() {
  406. if (submitting.value) return
  407. submitting.value = true
  408. try {
  409. if (flag.value) {
  410. return
  411. }
  412. flag.value = true
  413. form.activityTwoPercentGive = form.agree5 ? 1 : 0
  414. form.activityGive = form.agree6 ? 1 : 0
  415. dialogCheckWait.value = true
  416. const res = await ibApi.agentTransferApply({ ...form })
  417. dialogCheckWait.value = false
  418. if (res.code == Code.StatusOK) {
  419. dialogCheck.value = true
  420. dialogVisible.value = true
  421. flag.value = false
  422. } else {
  423. responseMessage.value = res.msg
  424. dialogCheck.value = true
  425. dialogVisible.value = false
  426. flag.value = false
  427. }
  428. } catch (error) {
  429. console.error('转账失败:', error)
  430. responseMessage.value = error.msg || t('Msg.Fail')
  431. dialogCheck.value = true
  432. dialogVisible.value = false
  433. } finally {
  434. resetForm()
  435. if (dialogCheckWait.value) dialogCheckWait.value = false
  436. }
  437. }
  438. // 取消
  439. function cancle() {
  440. step2.value = false
  441. loginValue.value = ''
  442. }
  443. // 获取账户信息
  444. async function getDateList() {
  445. const res = await ibApi.CustomDropdown({ platform: '' })
  446. if (res.code == Code.StatusOK) {
  447. loginOptions.value = res.data
  448. } else {
  449. $pigeon?.MessageError(res.msg)
  450. }
  451. }
  452. // 获取转入账户信息
  453. async function getToDateList() {
  454. const res = await ibApi.accountCustomList({})
  455. if (res.code == Code.StatusOK) {
  456. toOptions.value = res.data
  457. } else {
  458. $pigeon?.MessageError(res.msg)
  459. }
  460. }
  461. // 获取内转数额区间
  462. async function getAmount() {
  463. const res = await financialApi.transferInfo({})
  464. if (res.code == Code.StatusOK) {
  465. Object.assign(amountLimits, res.data)
  466. } else {
  467. $pigeon?.MessageError(res.msg)
  468. }
  469. }
  470. async function Activity24nianzhongTwoInfo() {
  471. const res = await activityApi.Activity23nianzhongTwoInfo({})
  472. if (res.code == Code.StatusOK) {
  473. tableData4Two.value = res.data
  474. } else {
  475. $pigeon?.MessageError(res.msg)
  476. }
  477. }
  478. // 活动相关方法
  479. function togetActivity() {
  480. get23nianzhongTwoLogin()
  481. getActivityExtensionGiveLogin()
  482. getActivityExtensionGiveLoginJoin()
  483. }
  484. async function get23nianzhongTwoLogin() {
  485. const res = await activityApi.Activity23nianzhongTwoLogin({
  486. login: form.depositLogin,
  487. })
  488. if (res.code == Code.StatusOK) {
  489. tableData4Two.value = res.data
  490. if (tableData4Two.value.show == 1) {
  491. tableData4TwoFlag.value = true
  492. } else if (tableData4Two.value.show == 0) {
  493. tableData4TwoFlag.value = false
  494. }
  495. } else {
  496. $pigeon?.MessageError(res.msg)
  497. }
  498. }
  499. async function getActivityExtensionGiveLogin() {
  500. const res = await activityApi.ActivityExtensionGiveLogin({
  501. login: form.depositLogin,
  502. })
  503. if (res.code == Code.StatusOK) {
  504. tableDataNewList.value = res.data
  505. if (tableDataNewList.value.show == 1) {
  506. tableDataNewListFlag.value = true
  507. } else if (tableDataNewList.value.show == 0) {
  508. tableDataNewListFlag.value = false
  509. }
  510. } else {
  511. $pigeon?.MessageError(res.msg)
  512. }
  513. }
  514. async function getActivityExtensionGiveLoginJoin() {
  515. const res = await activityApi.ActivityExtensionGiveLoginJoin({
  516. login: form.depositLogin,
  517. })
  518. if (res.code == Code.StatusOK) {
  519. giveLoginJoin.value = res.data
  520. } else {
  521. $pigeon?.MessageError(res.msg)
  522. giveLoginJoin.value = ''
  523. }
  524. }
  525. // 监听 loginValue 变化
  526. watch(loginValue, (newVal) => {
  527. if (newVal) {
  528. step2.value = true
  529. form.withdrawLogin = newVal
  530. resetForm()
  531. }
  532. })
  533. // 监听 loginValue 变化
  534. watch(form.depositLogin, (newVal) => {
  535. if (newVal) {
  536. togetActivity()
  537. }
  538. })
  539. // 监听 agree6 变化
  540. watch(() => form.agree6, (newVal) => {
  541. if (newVal && giveLoginJoin.value?.flag === false) {
  542. let tips = ''
  543. if (giveLoginJoin.value.promptType == 1) {
  544. tips = t('surplusList.item10')
  545. } else {
  546. tips = t('surplusList.item11')
  547. }
  548. return
  549. // 活动相关方法,后续需要在调整
  550. if (giveLoginJoin.value.activityCategory == 1) {
  551. $pigeon?.MessageConfirm(
  552. tips,
  553. t('Msg.SystemPrompt'),
  554. t('surplusList.item12'),
  555. t('Home.msg.item3'),
  556. () => {
  557. $pigeon?.MessageConfirm(
  558. t('surplusList.item13'),
  559. t('Msg.SystemPrompt'),
  560. t('Btn.Confirm'),
  561. t('Btn.Cancel'),
  562. async () => {
  563. try {
  564. const res = await activityApi.ActivityGiveCancel({
  565. login: loginValue.value,
  566. })
  567. if (res.code == Code.StatusOK) {
  568. $pigeon?.MessageOK(res.msg || t('Msg.Success'))
  569. } else {
  570. $pigeon?.MessageError(res.msg)
  571. }
  572. } catch (error) {
  573. $pigeon?.MessageError(t('Msg.Fail'))
  574. }
  575. },
  576. () => {
  577. form.agree6 = false
  578. }
  579. )
  580. },
  581. () => {
  582. form.agree6 = false
  583. }
  584. )
  585. } else {
  586. $pigeon?.MessageConfirm(
  587. tips,
  588. t('Msg.SystemPrompt'),
  589. t('Btn.Confirm'),
  590. t('Btn.Cancel'),
  591. () => { },
  592. () => {
  593. form.agree6 = false
  594. }
  595. )
  596. }
  597. }
  598. })
  599. onMounted(() => {
  600. if (getInfoStatus5.value) {
  601. InfoStatus5.value = true
  602. }
  603. getDateList()
  604. getToDateList()
  605. getAmount()
  606. // Activity24nianzhongTwoInfo()
  607. })
  608. onLoad((options) => {
  609. if (options?.login) {
  610. loginValue.value = options.login
  611. step2.value = true
  612. form.withdrawLogin = options.login
  613. }
  614. })
  615. </script>
  616. <style lang="scss" scoped>
  617. @import "@/uni.scss";
  618. .transfer-page {
  619. width: 100%;
  620. padding-bottom: px2rpx(20);
  621. .main-content {
  622. text-align: left;
  623. .box {
  624. padding-top: px2rpx(5);
  625. color: #303133;
  626. .b-card {
  627. background-color: #fff;
  628. margin-bottom: px2rpx(10);
  629. border-radius: px2rpx(6);
  630. box-shadow: 0 px2rpx(1) px2rpx(6) 0 rgba(0, 0, 0, 0.05);
  631. &:hover {
  632. box-shadow: 0 px2rpx(2) px2rpx(8) 0 rgba(0, 0, 0, 0.1);
  633. }
  634. .card-top {
  635. padding: px2rpx(15) px2rpx(20);
  636. box-sizing: border-box;
  637. .card-row {
  638. margin-bottom: px2rpx(12);
  639. &:last-child {
  640. margin-bottom: 0;
  641. }
  642. }
  643. .tit {
  644. font-size: px2rpx(16);
  645. margin-bottom: px2rpx(12);
  646. font-weight: 600;
  647. .iconfont {
  648. font-size: px2rpx(18);
  649. margin-right: px2rpx(8);
  650. color: #409eff;
  651. }
  652. }
  653. .title-wrapper {
  654. display: flex;
  655. justify-content: space-between;
  656. align-items: center;
  657. }
  658. }
  659. }
  660. }
  661. .box-step2 {
  662. .form-row {
  663. display: flex;
  664. flex-wrap: wrap;
  665. margin-bottom: px2rpx(12);
  666. gap: px2rpx(12);
  667. &:last-child {
  668. margin-bottom: 0;
  669. }
  670. .form-col {
  671. flex: 1;
  672. min-width: px2rpx(140);
  673. @media screen and (max-width: 991px) {
  674. flex: 0 0 100%;
  675. width: 100%;
  676. }
  677. }
  678. .form-col-full {
  679. width: 100%;
  680. padding: 0 px2rpx(5);
  681. }
  682. }
  683. .tips {
  684. line-height: 1.8;
  685. font-size: px2rpx(12);
  686. color: #909399;
  687. background-color: #f9f9f9;
  688. padding: px2rpx(12);
  689. border-radius: px2rpx(4);
  690. border-left: px2rpx(2) solid #409eff;
  691. .title {
  692. font-weight: 600;
  693. margin-bottom: px2rpx(6);
  694. color: #606266;
  695. }
  696. }
  697. }
  698. }
  699. .picker-select {
  700. background-color: #f5f7fa;
  701. border: 1px solid #dcdfe6;
  702. border-radius: px2rpx(4);
  703. padding: px2rpx(12) px2rpx(14);
  704. font-size: px2rpx(14);
  705. color: #606266;
  706. line-height: 1.4;
  707. width: 100%;
  708. box-sizing: border-box;
  709. &:hover {
  710. border-color: #409eff;
  711. }
  712. &.picker-disabled {
  713. background-color: #f5f7fa;
  714. color: #c0c4cc;
  715. cursor: not-allowed;
  716. }
  717. }
  718. .disabled-input {
  719. background-color: #f5f7fa;
  720. border: 1px solid #dcdfe6;
  721. border-radius: px2rpx(4);
  722. padding: px2rpx(12) px2rpx(14);
  723. font-size: px2rpx(14);
  724. color: #606266;
  725. width: 100%;
  726. box-sizing: border-box;
  727. }
  728. .m-input {
  729. background-color: #f5f7fa;
  730. border: 1px solid #dcdfe6;
  731. border-radius: px2rpx(4);
  732. padding: px2rpx(12) px2rpx(14);
  733. font-size: px2rpx(14);
  734. width: 100%;
  735. box-sizing: border-box;
  736. &:focus {
  737. border-color: #409eff;
  738. outline: none;
  739. box-shadow: 0 0 0 px2rpx(1) rgba(64, 158, 255, 0.2);
  740. }
  741. }
  742. .popup-content {
  743. padding: px2rpx(30) px2rpx(20);
  744. text-align: center;
  745. min-width: px2rpx(250);
  746. max-width: 80%;
  747. margin: 0 auto;
  748. @media screen and (max-width: 991px) {
  749. min-width: 80%;
  750. max-width: 90%;
  751. margin: 0 px2rpx(10);
  752. }
  753. position: relative;
  754. .icon {
  755. .iconfont {
  756. font-size: px2rpx(60);
  757. display: block;
  758. margin: 0 auto;
  759. }
  760. .icon-chenggong {
  761. color: #67c23a;
  762. }
  763. .icon-jingshi {
  764. color: #f56c6c;
  765. }
  766. .icon-dengdai {
  767. color: #e6a23c;
  768. }
  769. }
  770. .des1 {
  771. font-weight: 600;
  772. font-size: px2rpx(16);
  773. margin: px2rpx(20) 0 px2rpx(15);
  774. color: #303133;
  775. line-height: 1.4;
  776. padding: 0 px2rpx(10);
  777. }
  778. .dialog-footer {
  779. display: flex;
  780. justify-content: center;
  781. gap: px2rpx(10);
  782. margin-top: px2rpx(10);
  783. @media (max-width: 750rpx) {
  784. flex-direction: column;
  785. align-items: center;
  786. gap: px2rpx(6);
  787. }
  788. button {
  789. min-width: px2rpx(90);
  790. padding: 0 px2rpx(12);
  791. border-radius: px2rpx(4);
  792. font-size: px2rpx(14);
  793. transition: all 0.3s ease;
  794. cursor: pointer;
  795. &[type="primary"] {
  796. background-color: #409eff;
  797. color: #fff;
  798. border: none;
  799. &:hover {
  800. background-color: #66b1ff;
  801. transform: translateY(px2rpx(-1));
  802. box-shadow: 0 px2rpx(2) px2rpx(6) 0 rgba(64, 158, 255, 0.3);
  803. }
  804. &:active {
  805. background-color: #3a8ee6;
  806. transform: translateY(0);
  807. }
  808. }
  809. &:not([type="primary"]) {
  810. background-color: #fff;
  811. border: 1px solid #dcdfe6;
  812. color: #606266;
  813. &:hover {
  814. border-color: #409eff;
  815. color: #409eff;
  816. transform: translateY(px2rpx(-1));
  817. }
  818. &:active {
  819. transform: translateY(0);
  820. }
  821. }
  822. }
  823. }
  824. }
  825. .wait-popup {
  826. .des1 {
  827. margin-top: px2rpx(10);
  828. }
  829. .icon {
  830. .iconfont {
  831. animation: spin 1s linear infinite;
  832. }
  833. }
  834. }
  835. }
  836. // 动画
  837. @keyframes popupFadeIn {
  838. from {
  839. opacity: 0;
  840. transform: scale(0.9);
  841. }
  842. to {
  843. opacity: 1;
  844. transform: scale(1);
  845. }
  846. }
  847. @keyframes fadeIn {
  848. from {
  849. opacity: 0;
  850. transform: translateY(px2rpx(10));
  851. }
  852. to {
  853. opacity: 1;
  854. transform: translateY(0);
  855. }
  856. }
  857. @keyframes pulse {
  858. 0% {
  859. transform: scale(1);
  860. }
  861. 50% {
  862. transform: scale(1.05);
  863. }
  864. 100% {
  865. transform: scale(1);
  866. }
  867. }
  868. @keyframes spin {
  869. from {
  870. transform: rotate(0deg);
  871. }
  872. to {
  873. transform: rotate(360deg);
  874. }
  875. }
  876. // 表单错误信息样式
  877. .uni-forms-item__error {
  878. font-size: px2rpx(12);
  879. color: #f56c6c;
  880. margin-top: px2rpx(4);
  881. }
  882. // 适配不同屏幕尺寸(媒体查询中的 750rpx 保持不变)
  883. @media (max-width: 750rpx) {
  884. .transfer-page {
  885. .main-content {
  886. padding: px2rpx(8);
  887. .box {
  888. .b-card {
  889. .card-top {
  890. padding: px2rpx(12) px2rpx(16);
  891. .tit {
  892. font-size: px2rpx(14);
  893. .iconfont {
  894. font-size: px2rpx(16);
  895. }
  896. }
  897. }
  898. }
  899. }
  900. }
  901. .s-btn {
  902. font-size: px2rpx(14);
  903. padding: px2rpx(10) px2rpx(16);
  904. }
  905. .popup-content {
  906. padding: px2rpx(20) px2rpx(16);
  907. .icon {
  908. .iconfont {
  909. font-size: px2rpx(50);
  910. }
  911. }
  912. .des1 {
  913. font-size: px2rpx(14);
  914. margin: px2rpx(15) 0 px2rpx(10);
  915. }
  916. .dialog-footer {
  917. button {
  918. min-width: px2rpx(80);
  919. font-size: px2rpx(13);
  920. }
  921. }
  922. }
  923. }
  924. }
  925. </style>