()
| 323 | |
| 324 | // 划转邀请额度 |
| 325 | const transfer = async () => { |
| 326 | if (transferAmount < getQuotaPerUnit()) { |
| 327 | showError(t('划转金额最低为') + ' ' + renderQuota(getQuotaPerUnit())); |
| 328 | return; |
| 329 | } |
| 330 | const res = await API.post(`/api/user/aff_transfer`, { |
| 331 | quota: transferAmount, |
| 332 | }); |
| 333 | const { success, message } = res.data; |
| 334 | if (success) { |
| 335 | showSuccess(message); |
| 336 | setOpenTransfer(false); |
| 337 | getUserQuota().then(); |
| 338 | } else { |
| 339 | showError(message); |
| 340 | } |
| 341 | }; |
| 342 | |
| 343 | // 复制邀请链接 |
| 344 | const handleAffLinkClick = async () => { |
nothing calls this directly
no test coverage detected