# Administrator guide

Arabic default. Use the language switcher at any time.

## After installation

1. Sign in.
2. Open **Settings** and set company name, logo, currency, tax, invoice prefix, timezone.
3. Create a **telecom company** (do not hardcode operator names).
4. Create **plans** with the current monthly price.
5. Add **available lines** (phone, ICCID, SIM serial, SIM type).
6. Optionally create **main accounts** and **sub accounts** for companies.

## Selling a line

**Sales → Create**. Choose an existing customer or enter a new customer, select an available line, optionally a plan, prices, discount, tax, paid amount, and payment method.

The system creates the sale, invoice, payment, cash transaction, assigns the line, records ownership history, and writes an audit log.

A line cannot be sold unless its status is **Available**.

## Monthly collection

**Billing**: search by phone, customer, national ID, or account.

The screen shows the current plan, last invoice, last payment, paid-through month, unpaid periods, and outstanding balance.

Select one or more unpaid months and collect. Each period is stored with the price valid for that month. A period cannot be paid twice.

## Overdue

**Overdue** filters by year, month, company, plan, and account. Export CSV or print.

## Cash drawer

The first cash operation opens a drawer if none is open. Record expenses and cash in/out. **Close day** stores expected vs actual cash. Closed drawer rows are not edited; a new drawer is used afterwards.

## Plan price changes

Edit the plan price and set an effective date. Historical invoices and already billed periods keep the old amount.

## Transfers and returns

On the line profile, transfer to another customer or return the line to Available/Returned. Previous ownership rows are never deleted.

## Backups and updates

- **Backups**: create, download, delete, retention in settings.
- **Updates**: `/admin/system/update` — backup, migrate, version history. Never uses `migrate:fresh`.

## Troubleshooting

- Installer blocked: `storage/installed` already exists.
- 403 on a page: the role is missing a permission.
- No cash movements: open or auto-open a drawer, then collect again.
- Duplicate period error: that line already paid the selected month.
