Skip to main content

Shop Portal — Tổng quan

kioskgaming_shop là ứng dụng web SPA dành cho Shop CDN (Content Delivery Network) trong hệ sinh thái KioskGaming. Shop dùng portal này để quản lý player, nạp/rút credits, duyệt rút tiền, cấu hình phí provider, quản lý cashier và marketing kiosk URL.

Repo: kioskgaming_shop/


Vai trò trong hệ thống

Shop nằm ở tầng thứ tư trong phân cấp tài khoản:

Admin → Super Agent → Agent → Shop → Player

Shop Portal chỉ gọi API backend qua HTTPS. Không có giao tiếp trực tiếp giữa các frontend.

PortalĐối tượng sử dụng
Shop Portal (kioskgaming_shop)Chủ shop / quản lý shop CDN
Cashier App (riêng)Nhân viên thu ngân tại quầy
Player WebNgười chơi cuối
note

Đăng nhập cashier trên Shop Portal bị chặn — cashier được redirect sang Cashier App. Shop Portal chỉ quản lý tài khoản cashier (tạo, suspend, terminate, xem báo cáo).


Hai loại ví của Shop

Tên fieldMục đích
Credits walletcredit_balanceSố dư chính để cấp credits cho player
USD online balanceonline_balance_netVí USD riêng — mua credits hoặc rút crypto

Công thức chuyển đổi: credits = USD ÷ cost_rate (cost rate do agent đặt).


Tính năng chính

NhómChức năng
DashboardSố dư credits/USD, số player, mua credits nhanh
PlayersDanh sách, tạo player, deposit/redeem credits, ban/unban
WithdrawalsDuyệt/từ chối yêu cầu rút tiền của player
TransactionsSổ credits (ledger), export CSV
Online transactionsSổ USD wallet, rút crypto, export CSV
Provider feesBật/tắt phương thức thanh toán, xem phí gateway
CashiersTạo/suspend/terminate cashier, xem báo cáo & shifts
Fraud indicatorsChỉ số gian lận cashier và player
Kiosk URLQuản lý subdomain kiosk + tải poster quảng cáo
CommunicationGửi popup/broadcast tới player (nếu có quyền delegate)
SettingsCost rate, cảnh báo số dư thấp, bật 2FA

Sidebar hiển thị các mục sau (mobile: bottom nav cho mục primary):

RouteLabelGhi chú
/Dashboard
/withdrawalsWithdrawals
/transactionsTransactions
/online-transactionsOnline transactions
/provider-feesProvider fees
/playersPlayers
/cashiersCashiers
/fraud-indicatorsFraud indicators
/kiosk-domainKiosk URL
/popups/sendSend popupChỉ khi can_delegate_popups === true
/broadcasts/sendSend broadcastChỉ khi can_delegate_popups === true
/settingsSettings

Quyền popup/broadcast phụ thuộc hierarchy: Super Agent delegation + agent flag + shop flag.


Tài liệu trong section này

TrangNội dung
Kiến trúc & Tech stackCấu trúc dự án, dependencies, state management, deploy
Routes & PagesToàn bộ route, component, luồng auth
Tích hợp APIDanh sách endpoint backend mà Shop gọi
Tính năng nghiệp vụChi tiết luồng mua credits, player, rút tiền, cashier

Liên kết tài liệu liên quan