# V7 Mobile Shop ERP Fixes

This version focuses on the final usability changes requested for the sale invoice and wizard flow.

## Main fixes

- Fixed wizard forms moving from step 1 directly to step 3.
  - Removed old duplicate JavaScript wizard handler.
  - Kept one guarded wizard engine only.
  - Next step is blocked until current step required fields are complete.

- Added two sale invoice methods:
  - Sale Wizard Invoice for full customer records.
  - Retail / Simple Invoice for walk-in customers where only customer name is required.

- Added automatic date saving:
  - Gregorian date.
  - Hijri Shamsi / Jalali date is generated automatically and saved in the database.

- Added runtime validation:
  - Required fields checked before moving to next wizard step.
  - Mobile/item selection checked before invoice submit.
  - Invalid fields highlighted.

- Improved invoice item search:
  - Search by IMEI, serial, brand, model, storage, RAM, color, condition, and source.
  - Filter by brand, condition, and source.
  - Selected item counter and total preview.

- Added usability shortcuts:
  - Alt + S = Sale Wizard
  - Alt + I = Retail Invoice
  - Alt + P = Purchase Wizard
  - Alt + T = Stock
  - Alt + R = Reports
  - F1 = Help page
  - Esc = Back / close page

- Added Help / System Usage Guide page.

- Added RTL typography improvement for Pashto/Dari:
  - CSS now prefers Bahij Zar if installed on the user's computer.
  - The font file is not included; install Bahij Zar on Windows to see it exactly.

## After update

Run:

```bash
composer dump-autoload
php artisan migrate
php artisan optimize:clear
php artisan view:clear
php artisan route:clear
php artisan config:clear
php artisan serve
```

If artisan gives mb_split error, enable mbstring in `C:\xampp\php\php.ini`:

```ini
extension=mbstring
```

Then restart XAMPP / terminal.
