This commit is contained in:
parent
22eb76a440
commit
8d83be7cb3
|
|
@ -295,9 +295,9 @@ const sendCodeApi = async (receiver: string) => {
|
||||||
params.email = receiver
|
params.email = receiver
|
||||||
} else {
|
} else {
|
||||||
params.mobile = receiver
|
params.mobile = receiver
|
||||||
// 从手机号中提取区号
|
// 手机区号取缓存 foreign_userInfo 的 mobile_area
|
||||||
const match = receiver.match(/^\+(\d{1,4})/)
|
const foreignUserInfo = getStorage<any>('foreign_userInfo')
|
||||||
params.mobile_area = match ? '+' + match[1] : '+86'
|
params.mobile_area = foreignUserInfo?.mobile_area || '+86'
|
||||||
}
|
}
|
||||||
return userStore.sendCode(params)
|
return userStore.sendCode(params)
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -36,9 +36,9 @@
|
||||||
<template #floatProfitLoss="{ row }">
|
<template #floatProfitLoss="{ row }">
|
||||||
<span>{{ getMarketFloatProfit(row.id) }}</span>
|
<span>{{ getMarketFloatProfit(row.id) }}</span>
|
||||||
</template>
|
</template>
|
||||||
<template #closeProfitLoss="{ row }">
|
<!-- <template #closeProfitLoss="{ row }">
|
||||||
<span>{{ getMarketCloseProfit(row.id) }}</span>
|
<span>{{ getMarketCloseProfit(row.id) }}</span>
|
||||||
</template>
|
</template> -->
|
||||||
<template #pointSpread="{ row }">
|
<template #pointSpread="{ row }">
|
||||||
<el-button type="primary" size="small" @click="handleViewPointDiff(row)"> 查看 </el-button>
|
<el-button type="primary" size="small" @click="handleViewPointDiff(row)"> 查看 </el-button>
|
||||||
</template>
|
</template>
|
||||||
|
|
|
||||||
|
|
@ -51,7 +51,7 @@ export const marketTableColumns = [
|
||||||
//浮动盈亏
|
//浮动盈亏
|
||||||
{ label: '浮动盈亏', slotName: 'floatProfitLoss', align: 'center' as const, width: '100px', isNumber: true },
|
{ label: '浮动盈亏', slotName: 'floatProfitLoss', align: 'center' as const, width: '100px', isNumber: true },
|
||||||
//平仓盈亏
|
//平仓盈亏
|
||||||
{ label: '平仓盈亏', slotName: 'closeProfitLoss', align: 'center' as const, width: '150px', isNumber: true },
|
{ label: '平仓盈亏', prop: 'closeProfitLoss', align: 'center' as const, width: '150px', isNumber: true },
|
||||||
//风险金
|
//风险金
|
||||||
{ label: '风险金', prop: 'riskMargin', align: 'center' as const, width: '150px', isNumber: true },
|
{ label: '风险金', prop: 'riskMargin', align: 'center' as const, width: '150px', isNumber: true },
|
||||||
//服务费
|
//服务费
|
||||||
|
|
|
||||||
|
|
@ -536,10 +536,10 @@ const handlePasswordConfirm = async () => {
|
||||||
};
|
};
|
||||||
|
|
||||||
// 如果是手机验证,添加 mobile_area 参数
|
// 如果是手机验证,添加 mobile_area 参数
|
||||||
if (passwordForm.verifyType === 'mobile' && userInfo.mobile) {
|
// if (passwordForm.verifyType === 'mobile' && userInfo.mobile) {
|
||||||
const match = userInfo.mobile.match(/^\+(\d{1,4})/);
|
// // 手机区号取缓存 userInfo 的 mobile_area
|
||||||
params.mobile_area = match ? '+' + match[1] : '+86';
|
// params.mobile_area = userInfo.mobile_area || '+86';
|
||||||
}
|
// }
|
||||||
|
|
||||||
await updatePwdByCaptchaApi(params);
|
await updatePwdByCaptchaApi(params);
|
||||||
passwordDialogVisible.value = false;
|
passwordDialogVisible.value = false;
|
||||||
|
|
|
||||||
|
|
@ -71,7 +71,7 @@
|
||||||
|
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import mammoth from 'mammoth'
|
import mammoth from 'mammoth'
|
||||||
import { ref, onUnmounted, onMounted } from 'vue'
|
import { ref, onUnmounted, onMounted, watch } from 'vue'
|
||||||
import termFile from '@/assets/file/服务条款.docx?url'
|
import termFile from '@/assets/file/服务条款.docx?url'
|
||||||
import privacyFile from '@/assets/file/隐私协议.docx?url'
|
import privacyFile from '@/assets/file/隐私协议.docx?url'
|
||||||
import riskFile from '@/assets/file/风险提示.docx?url'
|
import riskFile from '@/assets/file/风险提示.docx?url'
|
||||||
|
|
@ -136,6 +136,17 @@ const registerForm = ref<any>({
|
||||||
inviteCode: '',
|
inviteCode: '',
|
||||||
agreeAgreement: false,
|
agreeAgreement: false,
|
||||||
})
|
})
|
||||||
|
|
||||||
|
// 切换注册方式时,清空上次输入的数据与校验状态
|
||||||
|
watch(activeTab, () => {
|
||||||
|
registerForm.value.email = ''
|
||||||
|
registerForm.value.countryCode = '+86'
|
||||||
|
registerForm.value.phone = ''
|
||||||
|
registerForm.value.code = ''
|
||||||
|
// 清除表单校验提示,避免上一次的错误一直显示
|
||||||
|
registerFormRef.value?.clearValidate()
|
||||||
|
})
|
||||||
|
|
||||||
const registerRules = ref<FormRules>({
|
const registerRules = ref<FormRules>({
|
||||||
email: emailRules().email,
|
email: emailRules().email,
|
||||||
phone: phoneRules(registerForm.value).phone,
|
phone: phoneRules(registerForm.value).phone,
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue