SHYNAZ V4 — LIVE WEBSITE UPDATE
Owner: Jitesh

INSTALL ON YOUR EXISTING WEBSITE
1. Export a backup of the live database and keep a copy of the current website files.
2. Extract this ZIP into the same website folder as index.php. Overwrite the included application files.
3. KEEP your existing config.php, uploads and storage/documents folders. This ZIP deliberately contains no production config.php, sessions, database dump or client documents.
4. Sign in using your EXISTING Supreme Admin account.
5. Open the admin dashboard and click “Activate workspace update”. This applies the required database additions, including earlier prerequisites if missing. It can be run again without recreating records.
6. Refresh with Ctrl+F5. Close/reopen the installed app after visiting the website online so the service worker receives the new offline files.

NO MANUAL PHPMYADMIN IMPORT IS NEEDED FOR THIS UPDATE.
The database SQL files are included for the dashboard updater. WORKSPACE-V4.sql alone is not a standalone complete upgrade: column changes are handled by the PHP updater. Do not import a full installation schema or your exported database over live records.
The supplied live ZIP was missing the database folder required by its upgrade code. This package restores that folder and its access protection.
If activation fails, retain the backup, check the hosting error log, and confirm the MySQL user has CREATE and ALTER privileges.

WHERE TO FIND EACH FEATURE
- Login: Account login in header/footer, with Client, Student and Staff/Admin choices. They use one account system. The server routes you according to your assigned role. A choice does not change permissions.
- Attendance: HRM → Attendance. Staff use Start work / Check in and Finish work / Check out on phones or desktops. Date/time use India Standard Time. Actual request IP is captured for new online events. Management corrections open in compact dialogs and retain an audit record.
- Salon network: Supreme Admin → Attendance → Salon network settings. Enter the public IP(s) used by salon Wi-Fi. A match is labelled; a different network remains visible for review. It is not a GPS location or proof of physical presence. Cellular connections and changing public IPs may differ. Offline events retain an offline source and do not claim a salon IP.
- Salary: HRM → Salary records → Add salary entry. Choose employee, month and amount. Use Record payment to choose payment date/mode/reference and attach an image or PDF proof. Payment creates one linked salary expense. Paid records remain visible. Existing recorded salary expenses can be linked without recording another expense.
- Academy: Courses → create/save course → Manage learning. Lessons & PDFs, Quizzes, and Students & downloads are sections inside the course. The old independent Lessons sidebar tab is removed.
- Reading: Approved active/completed students open My learning → Open lessons, PDFs & quizzes. PDFs are stored privately, not in public uploads. Student downloads are denied by the download endpoint until authorised on the specific registration.
- Download permission: Course → Students & downloads → Authorised downloads → Save. Change back to Read online only to revoke. This permission covers that registration's PDFs.
- Quiz: Course → Quizzes → Add question. Enter four answers and select the correct one. Published questions appear in the enrolled student's course workspace. Scores are calculated on the server and saved. Quiz scores do not automatically issue a certificate or mark a course completed.
- Reviews: Website & content → Reviews. Add a genuine copied Google review with its attribution/source link or accept a guest review submitted on the website. Both begin pending. Change to approved to display publicly for that salon. Rejected/pending reviews remain hidden. This is manual import, not an automatic Google API connection.
- New salon: Administration → Branch settings → Add branch. Its selector appears automatically. Ten starter pages, four categories and eleven enquiry services are prepared for that branch. Set real details, prices, durations, artist assignments and images before accepting bookings. No existing staff, students, clients, reviews or photos are copied.
- Website content: Existing custom page text is preserved. Recognised starter pages receive expanded reading content; missing standard footer pages have branch-specific fallback content. Admin → Pages & menus can replace that text. Inactive pages remain inactive.
- Invoice: Reception → Invoices & estimates → New service selection. Choose services/artists and create the pending estimate. Authorised approval converts it into confirmed billing. Open the document for Print / Save as PDF, WhatsApp, email and Share / Copy link. WhatsApp opens a prepared message; the operator sends it. General sharing uses the device's supported share menu, or copies the link. Email needs working SMTP settings. Only Supreme Admin can edit invoice financial details or delete invoices.
- Forms: Expense, attendance correction, salary and generic record editors use compact popup windows. Tables remain searchable/filterable and paginated. Without JavaScript, the native expandable forms still work.

OFFLINE PC/LAPTOP OPERATION
- HTTPS is required for service workers and normal PWA installation. A site opened over plain HTTP will not provide the same offline/install features.
- While ONLINE, sign in as staff and open Offline desk → choose branch → Prepare this device for offline work. Wait for success, visit the offline desk, then install through the browser's Install SHYNAZ option if supported.
- On a prepared device, opening the installed app during a connection failure opens the offline desk. You can also bookmark offline.html on that device.
- Create service estimate, expense and attendance drafts. They stay in this browser/device. Service draft prices/tax are saved with the draft for printing. Choose Print draft / Save PDF for a clearly marked offline estimate. Use a locally connected printer or PDF output; a printer requiring internet may not work.
- Reconnect, keep the app open and sign in as the draft owner. Sync checks permissions, service prices, artist availability and duplicate draft references. Conflicts remain in the review queue; they are not silently overwritten.
- Offline drafts are NOT confirmed invoices or receipts. Full live dashboard access, payment posting, stock changes, approvals, certificates, online PDFs and SMTP sending require a connection.
- This update does not cache private confirmed invoice pages for offline reprinting. Save an approved invoice as a PDF while online when a copy must be available offline.
- Do not clear browser storage before syncing. Export unsynced draft backups and keep the device secure. Installing alone does not download the whole database or guarantee synchronisation while the app is closed.

READ-ONLY MATERIAL LIMIT
The app restricts its download action and checks registration access. PDF reading still delivers content to the browser; no website can guarantee that a viewer cannot save the received file, photograph the screen or capture it. These controls are access permissions, not absolute DRM.

VALIDATION
412 PHP 8.3 runtime checks using isolated SQLite test databases, including a smoke test restored from the supplied SQL export; 24 JavaScript/offline asset checks; all 29 PHP source files parsed. Upload checks included multipart private PDF and salary-proof uploads. Original regression checks cover bookings, invoice approval, accounting, role limits, certificates and offline duplicate/conflict handling.
The tests do not modify the live server. Live MySQL execution, SMTP delivery, physical printers, PWA installation and visual layout at every device size were not verified here. Browser preview was unavailable in this session. Check those on your hosting after applying the update.
