How nntfb777/99okcode-admin works
This is a browser-based admin console for a multi-site gift-code service. An administrator signs in; the client stores the returned session, and shared auth logic checks access and the active site. From there, dashboard, code, link, account, and history screens call the backend to retrieve or change data and render results. The excerpts show these client-side responsibilities and API interactions; backend internals and HTML wiring are not shown, so the backend is represented as one external service.
Main entry points: auth.js Session and site auth · lich-su.js Usage history · login.js Sign-in · index.js Stats dashboard
Components 11
Access
- Sign-in
js/login.js - Session and site auth
js/auth.js
Dashboard
- Stats dashboard
js/index.js
Admin operations
- Code management
js/quan-ly-ma.js - Link configuration
js/quan-ly-link.js - Admin accounts
js/quan-ly-tai-khoan.js - Usage history
js/lich-su.js
External services
- Browser storage
- Admin API
- SheetJS
Other components
- Administrator
Connections 15
- Administrator → Sign-in: submits credentials
js/login.js - Sign-in → Admin API: authenticates
js/login.js - Sign-in → Browser storage: stores session
js/login.js - Session and site auth → Browser storage: checks session
js/auth.js - Code management → Session and site auth: gets active site
js/quan-ly-ma.js - Link configuration → Session and site auth: gets active site
js/quan-ly-link.js - Usage history → Session and site auth: gets active site
js/lich-su.js - Stats dashboard → Session and site auth: gets active site
js/index.js - Stats dashboard → Admin API: loads stats
js/index.js - Code management → Admin API: manages codes
js/quan-ly-ma.js - Link configuration → Admin API: manages links
js/quan-ly-link.js - Admin accounts → Admin API: manages accounts
js/quan-ly-tai-khoan.js - Admin accounts → Session and site auth: logs out
js/quan-ly-tai-khoan.js - Usage history → Admin API: loads and deletes
js/lich-su.js - Usage history → SheetJS: exports workbook
js/lich-su.js