fix(admin-web): add operatorId to system-withdrawal request
The wallet-service API requires operatorId parameter but frontend was not sending it, causing 400 error. Now includes operatorId and operatorName from current logged-in user. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
parent
272b4ffdbf
commit
ead1aac60c
|
|
@ -5,6 +5,7 @@ import { Modal, toast, Button } from '@/components/common';
|
|||
import { PageContainer } from '@/components/layout';
|
||||
import { cn } from '@/utils/helpers';
|
||||
import { formatDateTime } from '@/utils/formatters';
|
||||
import { useAppSelector } from '@/store/redux/hooks';
|
||||
import {
|
||||
useSystemWithdrawalAccounts,
|
||||
useSystemWithdrawalOrders,
|
||||
|
|
@ -24,6 +25,9 @@ type TabType = 'transfer' | 'orders';
|
|||
* 系统账户划转管理页面
|
||||
*/
|
||||
export default function SystemTransferPage() {
|
||||
// 获取当前登录用户
|
||||
const currentUser = useAppSelector((state) => state.auth.user);
|
||||
|
||||
// 当前标签页
|
||||
const [activeTab, setActiveTab] = useState<TabType>('transfer');
|
||||
|
||||
|
|
@ -101,6 +105,8 @@ export default function SystemTransferPage() {
|
|||
toAccountSequence: transferForm.toAccountSequence,
|
||||
amount: transferForm.amount,
|
||||
memo: transferForm.memo || undefined,
|
||||
operatorId: currentUser?.id || 'admin',
|
||||
operatorName: currentUser?.nickname || currentUser?.username,
|
||||
});
|
||||
toast.success('划转请求已提交,等待区块链确认');
|
||||
setConfirmModalOpen(false);
|
||||
|
|
|
|||
|
|
@ -43,6 +43,8 @@ export interface SystemWithdrawalRequest {
|
|||
toAccountSequence: string;
|
||||
amount: string;
|
||||
memo?: string;
|
||||
operatorId: string;
|
||||
operatorName?: string;
|
||||
}
|
||||
|
||||
// 划转响应
|
||||
|
|
|
|||
Loading…
Reference in New Issue