diff --git a/app/admin/controller/game/UserWalletRecord.php b/app/admin/controller/record/UserWalletRecord.php
similarity index 94%
rename from app/admin/controller/game/UserWalletRecord.php
rename to app/admin/controller/record/UserWalletRecord.php
index 34ae598..fa2d638 100644
--- a/app/admin/controller/game/UserWalletRecord.php
+++ b/app/admin/controller/record/UserWalletRecord.php
@@ -1,6 +1,6 @@
'desc'];
- protected array $withJoinTable = ['gameUser', 'channel', 'operatorAdmin'];
+ protected array $withJoinTable = ['user', 'channel', 'operatorAdmin'];
protected function initController(WebmanRequest $request): ?Response
{
- $this->model = new \app\common\model\GameUserWalletRecord();
+ $this->model = new \app\common\model\UserWalletRecord();
return null;
}
@@ -87,7 +87,7 @@ class UserWalletRecord extends Backend
->withJoin($this->withJoinTable, $this->withJoinType)
->with($this->withJoinTable)
->visible([
- 'gameUser' => ['username', 'phone'],
+ 'user' => ['username', 'phone'],
'channel' => ['name'],
'operatorAdmin' => ['username'],
])
diff --git a/app/common/model/GameUserWalletRecord.php b/app/common/model/UserWalletRecord.php
similarity index 68%
rename from app/common/model/GameUserWalletRecord.php
rename to app/common/model/UserWalletRecord.php
index 704e740..b0492c6 100644
--- a/app/common/model/GameUserWalletRecord.php
+++ b/app/common/model/UserWalletRecord.php
@@ -5,11 +5,11 @@ namespace app\common\model;
use support\think\Model;
/**
- * 玩家游戏币钱包流水(只增不改;余额变更须与 game_user.coin 条件更新同事务)
+ * 用户钱包流水(原 game_user_wallet_record)
*/
-class GameUserWalletRecord extends Model
+class UserWalletRecord extends Model
{
- protected $name = 'game_user_wallet_record';
+ protected $name = 'user_wallet_record';
protected $autoWriteTimestamp = false;
@@ -24,9 +24,9 @@ class GameUserWalletRecord extends Model
'balance_after' => 'string',
];
- public function gameUser(): \think\model\relation\BelongsTo
+ public function user(): \think\model\relation\BelongsTo
{
- return $this->belongsTo(GameUser::class, 'user_id', 'id');
+ return $this->belongsTo(User::class, 'user_id', 'id');
}
public function channel(): \think\model\relation\BelongsTo
diff --git a/web/src/lang/backend/en/game/walletRecord.ts b/web/src/lang/backend/en/game/walletRecord.ts
index 0106799..0ac871e 100644
--- a/web/src/lang/backend/en/game/walletRecord.ts
+++ b/web/src/lang/backend/en/game/walletRecord.ts
@@ -1,7 +1,7 @@
export default {
id: 'Record ID',
user_id: 'User ID',
- 'game_user__username': 'Username',
+ 'user__username': 'Username',
'channel__name': 'Channel',
biz_type: 'Biz type',
direction: 'Direction',
diff --git a/web/src/lang/backend/en/record/userWalletRecord.ts b/web/src/lang/backend/en/record/userWalletRecord.ts
new file mode 100644
index 0000000..0ac871e
--- /dev/null
+++ b/web/src/lang/backend/en/record/userWalletRecord.ts
@@ -0,0 +1,33 @@
+export default {
+ id: 'Record ID',
+ user_id: 'User ID',
+ 'user__username': 'Username',
+ 'channel__name': 'Channel',
+ biz_type: 'Biz type',
+ direction: 'Direction',
+ amount: 'Amount',
+ balance_before: 'Balance before',
+ balance_after: 'Balance after',
+ ref_type: 'Ref type',
+ ref_id: 'Ref ID',
+ idempotency_key: 'Idempotency key',
+ 'operator_admin__username': 'Operator',
+ remark: 'Remark',
+ create_time: 'Created at',
+ 'quick Search Fields': 'ID, biz type, ref type, remark, idempotency key',
+ 'direction in': 'Credit',
+ 'direction out': 'Debit',
+ 'biz deposit': 'Deposit',
+ 'biz withdraw': 'Withdraw',
+ 'biz withdraw_freeze': 'Withdraw freeze',
+ 'biz withdraw_unfreeze': 'Withdraw unfreeze',
+ 'biz platform_in': 'Platform credit',
+ 'biz platform_out': 'Platform debit',
+ 'biz admin_credit': 'Admin credit',
+ 'biz admin_deduct': 'Admin debit',
+ 'biz bet': 'Bet',
+ 'biz payout': 'Payout',
+ 'biz fee': 'Fee',
+ 'biz void_refund': 'Void refund',
+ 'biz adjust': 'Adjustment',
+}
diff --git a/web/src/lang/backend/zh-cn/game/walletRecord.ts b/web/src/lang/backend/zh-cn/game/walletRecord.ts
index d6ead7a..a9c1b9d 100644
--- a/web/src/lang/backend/zh-cn/game/walletRecord.ts
+++ b/web/src/lang/backend/zh-cn/game/walletRecord.ts
@@ -1,7 +1,7 @@
export default {
id: '流水ID',
user_id: '用户ID',
- 'game_user__username': '用户名',
+ 'user__username': '用户名',
'channel__name': '渠道',
biz_type: '业务类型',
direction: '方向',
diff --git a/web/src/lang/backend/zh-cn/record/userWalletRecord.ts b/web/src/lang/backend/zh-cn/record/userWalletRecord.ts
new file mode 100644
index 0000000..a9c1b9d
--- /dev/null
+++ b/web/src/lang/backend/zh-cn/record/userWalletRecord.ts
@@ -0,0 +1,33 @@
+export default {
+ id: '流水ID',
+ user_id: '用户ID',
+ 'user__username': '用户名',
+ 'channel__name': '渠道',
+ biz_type: '业务类型',
+ direction: '方向',
+ amount: '变动额',
+ balance_before: '变动前余额',
+ balance_after: '变动后余额',
+ ref_type: '关联类型',
+ ref_id: '关联ID',
+ idempotency_key: '幂等键',
+ 'operator_admin__username': '操作管理员',
+ remark: '备注',
+ create_time: '创建时间',
+ 'quick Search Fields': 'ID、业务类型、关联类型、备注、幂等键',
+ 'direction in': '入金',
+ 'direction out': '出金',
+ 'biz deposit': '充值入账',
+ 'biz withdraw': '提现出账',
+ 'biz withdraw_freeze': '提现冻结',
+ 'biz withdraw_unfreeze': '提现解冻',
+ 'biz platform_in': '平台划入',
+ 'biz platform_out': '平台划出',
+ 'biz admin_credit': '管理员加币',
+ 'biz admin_deduct': '管理员扣币',
+ 'biz bet': '下注扣款',
+ 'biz payout': '派彩',
+ 'biz fee': '手续费',
+ 'biz void_refund': '作废退款',
+ 'biz adjust': '其他调账',
+}
diff --git a/web/src/views/backend/game/walletRecord/index.vue b/web/src/views/backend/record/userWalletRecord/index.vue
similarity index 62%
rename from web/src/views/backend/game/walletRecord/index.vue
rename to web/src/views/backend/record/userWalletRecord/index.vue
index 8fe1694..f1b486d 100644
--- a/web/src/views/backend/game/walletRecord/index.vue
+++ b/web/src/views/backend/record/userWalletRecord/index.vue
@@ -4,7 +4,7 @@