优化领取页绑定 UID 校验
This commit is contained in:
@@ -181,9 +181,19 @@ export default function ClaimPage() {
|
||||
|
||||
async function handleSubmitAffiliateDash() {
|
||||
const affiliateDash = snapshot.affiliateDash
|
||||
const uid = uidInput.trim() || affiliateDash?.gameAccount || ''
|
||||
const uid =
|
||||
snapshot.expectedUid || affiliateDash?.expectedGameAccount || affiliateDash?.gameAccount || ''
|
||||
const bindUuid = affiliateDash?.bindUuid || ''
|
||||
|
||||
if (!snapshot.isAffiliateDashReadyToSubmit) {
|
||||
showError(
|
||||
snapshot.isAffiliateDashBindMismatch
|
||||
? '绑定账号与填写 UID 不一致,请用正确账号重新扫码绑定'
|
||||
: '绑定尚未完成,请先绑定账号',
|
||||
)
|
||||
return
|
||||
}
|
||||
|
||||
if (!uid || !bindUuid) {
|
||||
showError('绑定尚未完成,请先绑定账号')
|
||||
return
|
||||
@@ -191,7 +201,10 @@ export default function ClaimPage() {
|
||||
|
||||
setSubmittingSubmit(true)
|
||||
try {
|
||||
const response = await submitAffiliateDashClaim(token, { gameAccount: uid, bindUuid })
|
||||
const response = await submitAffiliateDashClaim(token, {
|
||||
gameAccount: uid,
|
||||
bindUuid,
|
||||
})
|
||||
await applyDetail(response.data)
|
||||
showSuccess('发货已提交')
|
||||
} catch (error) {
|
||||
|
||||
Reference in New Issue
Block a user