UNIPOS MULTI-SHOP REPORTS — INSTALLATION

1. BACK UP the existing /shoppy/pos_reports/ folder and its private/ directory.
2. Upload PHP files from this ZIP into /shoppy/pos_reports/. Do not delete the existing private/transactions.csv or private/updated.txt on your live server.
3. Open https://unicomlb.com/shoppy/pos_reports/admin.php
4. Use the ORIGINAL dashboard password (from your previous installation) once to initialize the Super Admin, then create a NEW Super Admin username/password.
5. Log in as Super Admin and create your first shop with user/POS limits and initial Shop Admin login.
6. The Shop Admin logs in at login.php and can add users and rename POS.
7. For each Windows POS run the included LIVE_POS.PRG with FIVE arguments:
   DO LIVE_POS WITH "C:\POS\INV_I_O.DBF", ;
      "https://unicomlb.com/shoppy/pos_reports/", ;
      "SHOP_POS_UPLOAD_TOKEN", "pos1", "s123456789abc"
   Replace token and shop ID with values shown in Super Admin.
8. For the initial shop, if you want historical CSV data, manually COPY the existing server private/transactions.csv into private/shops/<SHOP_ID>/transactions.csv (create directory if needed). Do not move it to another shop.
9. HTTPS required. PHP 8.0+ recommended; file locking and random_bytes required.

SECURITY: Each shop has a separate token, data directory, dashboard users and terminal list. Only the Super Admin can change limits. Shop Admin counts as a user. Tokens are visible only to Super Admin. This ZIP intentionally does not include your config.php or your transaction CSV data. KEEP your current server config.php unchanged.

NOTE: The initial POS terminals pos1..posN are created automatically when a shop is created. Removing them allows Shop Admin to add new ones up to the limit. Live requests time out after 60 seconds, preserving partial results.

IMPORTANT: The older standalone UPLOAD_POS.PRG uses a different endpoint; new shop-aware uploads require the included LIVE_POS.PRG.
