= __($page) ?>
Sales Performance
Recent Customers
View All| Name | Phone | Balance |
|---|---|---|
| = htmlspecialchars((string)($c['name'] ?? '')) ?> | = htmlspecialchars((string)($c['phone'] ?? '')) ?> | = $lang === 'ar' ? number_format((float)$c['balance'], 3) . ' ر.ع.' : 'OMR ' . number_format((float)$c['balance'], 3) ?> |
Quick Links
= htmlspecialchars($data['settings']['company_name'] ?? 'Company Name') ?>
= $currTitle['en'] ?> Management
| Name | Tax ID | Phone | Balance | Actions | |
|---|---|---|---|---|---|
| = htmlspecialchars((string)($c['name'] ?? '')) ?> | = htmlspecialchars((string)($c['tax_id'] ?? '---')) ?> | = htmlspecialchars((string)($c['email'] ?? '')) ?> | = htmlspecialchars((string)($c['phone'] ?? '')) ?> | = $lang === 'ar' ? number_format((float)$c['balance'], 3) . ' ر.ع.' : 'OMR ' . number_format((float)$c['balance'], 3) ?> |
|
Stock Categories Management
| ID | Name (EN) | Name (AR) | Actions |
|---|---|---|---|
| = $cat['id'] ?> | = htmlspecialchars($cat['name_en']) ?> | = htmlspecialchars($cat['name_ar']) ?> |
|
Units (= count($data['units'] ?? []) ?>)
Manage the English and Arabic unit names used across items, invoices, and reports.
| Name (EN) | Name (AR) | Actions |
|---|---|---|
No units yetAdd your first unit so items can reuse the same labels in invoices and reports. |
||
| = htmlspecialchars($unitNameEn !== '' ? $unitNameEn : '---') ?> | = htmlspecialchars($unitNameAr !== '' ? $unitNameAr : '---') ?> |
|
Stock Items (= count($data['items'] ?? []) ?>)
| Image | SKU | Name | Category | Supplier | Sale Price | Stock Level | Expiry | VAT | Actions | |
|---|---|---|---|---|---|---|---|---|---|---|
|
|
= htmlspecialchars($item['sku']) ?> |
= htmlspecialchars((string)($item['name_en'] ?? '')) ?>
Promo
= htmlspecialchars((string)($item['name_ar'] ?? '')) ?>
|
= htmlspecialchars((string)($item['cat_en'] ?? '')) ?> | = htmlspecialchars((string)($item['supplier_name'] ?? '---')) ?> |
= number_format((float)$item['sale_price'], 3) ?>
Incl. VAT: = number_format((float)$itemBarcodePrice, 3) ?>
|
= format_quantity($item['stock_quantity']) ?>
Min: = format_quantity($item['min_stock_level']) ?>
Low Stock
|
= !empty($item['expiry_date']) ? htmlspecialchars((string)$item['expiry_date']) : '---' ?> | = number_format((float)$item['vat_rate'], 2) ?>% |
|
Expiry Report
| SKU | Item Name | Category | Stock Level | Expiry Date | Status |
|---|---|---|---|---|---|
| No items found. | |||||
| = htmlspecialchars($item['sku']) ?> |
= htmlspecialchars($item['name_en']) ?>
= htmlspecialchars($item['name_ar']) ?>
|
= htmlspecialchars($item['cat_en'] ?? '---') ?> | = format_quantity($item['stock_quantity']) ?> | = $expiry_date !== '' ? htmlspecialchars((string)$expiry_date) : '---' ?> | Expired Near Expiry Good |
Low Stock Report
| SKU | Item Name | Category | Supplier | Min Level | Current Stock | Shortage |
|---|---|---|---|---|---|---|
| All items are above minimum levels. | ||||||
| = htmlspecialchars($item['sku']) ?> |
= htmlspecialchars($item['name_en']) ?>
= htmlspecialchars($item['name_ar']) ?>
|
= htmlspecialchars($item['cat_en'] ?? '---') ?> | = htmlspecialchars($item['supplier_name'] ?? '---') ?> | = format_quantity($item['min_stock_level']) ?> | = format_quantity($item['stock_quantity']) ?> | = number_format((float)$shortage, 3) ?> |
Loyalty Transaction History
| Date | Customer | Tier | Type | Points | Description |
|---|---|---|---|---|---|
| No transactions found. | |||||
| = date('Y-m-d H:i', strtotime($lt['created_at'])) ?> |
= htmlspecialchars($lt['customer_name']) ?>
Current Balance: = number_format($lt['loyalty_points'], 0) ?> pts
|
= $tier ?> | = ucfirst($type) ?> | = (float)$lt['points_change'] > 0 ? '+' : '' ?>= number_format($lt['points_change'], 0) ?> | = htmlspecialchars($lt['description']) ?> |
= $lang === 'ar' ? 'السلة' : 'Cart' ?>
= $lang === 'ar' ? 'السلة فارغة' : 'Cart is empty' ?>
Quotations
| Quotation # | Date | Valid Until | Customer | Status | Total | Actions |
|---|---|---|---|---|---|---|
| QUO-= str_pad((string)$q['id'], 5, '0', STR_PAD_LEFT) ?> | = $q['quotation_date'] ?> | = $q['valid_until'] ?: '---' ?> | = htmlspecialchars($q['customer_name'] ?? '---') ?> | = htmlspecialchars($q['status']) ?> | OMR = number_format((float)$q['total_with_vat'], 3) ?> |
|
| No quotations found | ||||||
Local Purchase Orders (LPO)
| LPO # | Date | Delivery Date | Supplier | Status | Total | Actions |
|---|---|---|---|---|---|---|
| LPO-= str_pad((string)$q['id'], 5, '0', STR_PAD_LEFT) ?> | = $q['lpo_date'] ?> | = $q['delivery_date'] ?: '---' ?> | = htmlspecialchars($q['supplier_name'] ?? '---') ?> | = htmlspecialchars($q['status']) ?> | OMR = number_format((float)$q['total_with_vat'], 3) ?> |
|
| No LPOs found | ||||||
= $lang === 'ar' ? $page_title_ar : $page_title_en ?>
= htmlspecialchars($data['settings']['company_name'] ?? 'Accounting System') ?>
= nl2br(htmlspecialchars($data['settings']['company_address'] ?? '')) ?>
= $lang === 'ar' ? 'كشف حساب' : 'Statement of Account' ?> - = htmlspecialchars($data['selected_entity']['name']) ?>
= htmlspecialchars($data['selected_entity']['name']) ?>
= htmlspecialchars($data['selected_entity']['email']) ?> | = htmlspecialchars($data['selected_entity']['phone']) ?>
= $lang === 'ar' ? 'الفترة' : 'Period' ?>: = $_GET['start_date'] ?> = $lang === 'ar' ? 'إلى' : 'to' ?> = $_GET['end_date'] ?>
| = $lang === 'ar' ? 'التاريخ' : 'Date' ?> | = $lang === 'ar' ? 'المرجع' : 'Reference' ?> | = $lang === 'ar' ? 'الوصف' : 'Description' ?> | = $lang === 'ar' ? 'مدين' : 'Debit' ?> | = $lang === 'ar' ? 'دائن' : 'Credit' ?> | = $lang === 'ar' ? 'الرصيد' : 'Balance' ?> |
|---|---|---|---|---|---|
| = $t['trans_date'] ?> | = $t['trans_type'] === 'invoice' ? ($lang === 'ar' ? ($page === 'supplier_statement' ? 'شراء-' : 'بيع-') : ($page === 'supplier_statement' ? 'PUR-' : 'INV-')).str_pad((string)$t['ref_no'], 5, '0', STR_PAD_LEFT) : ($lang === 'ar' ? 'قبض-' : 'RCP-').str_pad((string)$t['id'], 5, '0', STR_PAD_LEFT) ?> | = $lang === 'ar' ? 'فاتورة ضريبية' : 'Tax Invoice' ?> = $lang === 'ar' ? 'دفع' : 'Payment' ?> - = $lang === 'ar' ? ($t['payment_method'] === 'cash' ? 'نقد' : ($t['payment_method'] === 'card' ? 'بطاقة ائتمان' : 'آجل')) : $t['payment_method'] ?> | = number_format($debit, 3) ?> | = number_format($credit, 3) ?> | = number_format($running_balance, 3) ?> |
| = $lang === 'ar' ? 'رصيد الإقفال' : 'Closing Balance' ?> | = $lang === 'ar' ? number_format($running_balance, 3) . ' ر.ع.' : 'OMR ' . number_format($running_balance, 3) ?> | ||||
Please select an entity and date range to generate the statement.
Cashflow Statement
= htmlspecialchars($data['settings']['company_name'] ?? 'Accounting System') ?>
= nl2br(htmlspecialchars($data['settings']['company_address'] ?? '')) ?>
Cashflow Statement
Period: = htmlspecialchars($_GET['start_date'] ?? date('Y-m-01')) ?> to = htmlspecialchars($_GET['end_date'] ?? date('Y-m-d')) ?>
| Description | Amount (OMR) |
|---|---|
| Opening Cash Balance | = number_format($data['opening_balance'], 3) ?> |
| Operating Activities | |
| Cash Received from Customers & Others | = number_format($op_inflow, 3) ?> |
| Cash Paid to Suppliers & Expenses | (= number_format($op_outflow, 3) ?>) |
| Net Cash from Operating Activities | = number_format($op_inflow - $op_outflow, 3) ?> |
| Investing Activities | |
| Net Cash from Investing Activities | = number_format($inv_inflow - $inv_outflow, 3) ?> |
| Financing Activities | |
| Net Cash from Financing Activities | = number_format($fin_inflow - $fin_outflow, 3) ?> |
| Net Change in Cash | = number_format($net_change, 3) ?> |
| Closing Cash Balance | = number_format($data['opening_balance'] + $net_change, 3) ?> |
___________________
Prepared By
___________________
Approved By
Payment Methods
| ID | Name (EN) | Name (AR) | Actions |
|---|---|---|---|
| No payment methods found yet. Add one to get started. | |||
| = $paymentMethodId ?> | = htmlspecialchars($paymentMethodNameEn) ?> | = htmlspecialchars($paymentMethodNameAr) ?> |
|
Expense Categories
| ID | Name (EN) | Name (AR) | Actions |
|---|---|---|---|
| = $cat['id'] ?> | = htmlspecialchars($cat['name_en']) ?> | = htmlspecialchars($cat['name_ar']) ?> |
|
Expenses List
| Date | Reference | Category | Description | Amount | Actions |
|---|---|---|---|---|---|
| = $exp['expense_date'] ?> | = htmlspecialchars($exp['reference_no'] ?: '---') ?> | = htmlspecialchars($exp['cat_en'] ?? 'Unknown') ?> | = htmlspecialchars($exp['description']) ?> | OMR = number_format((float)$exp['amount'], 3) ?> |
|
= htmlspecialchars($data['settings']['company_name'] ?? 'Accounting System') ?>
= nl2br(htmlspecialchars($data['settings']['company_address'] ?? '')) ?>
VAT: = htmlspecialchars($data['settings']['vat_number'] ?? '') ?>
Expense Report
Date: = date('Y-m-d') ?>
Period: = htmlspecialchars($_GET['start_date'] ?? date('Y-m-01')) ?> - = htmlspecialchars($_GET['end_date'] ?? date('Y-m-d')) ?>
Expense Report
Total Expenses
OMR = number_format((float)$data['total_expenses'], 3) ?>
For the selected period| Category | Total Amount | % of Total |
|---|---|---|
| No expenses found for this period. | ||
|
= htmlspecialchars($row['name_en']) ?>
= htmlspecialchars($row['name_ar']) ?>
|
OMR = number_format((float)$row['total'], 3) ?> |
|
Prepared By
Approved By
= htmlspecialchars($data['settings']['company_name'] ?? 'Accounting System') ?>
= nl2br(htmlspecialchars($data['settings']['company_address'] ?? '')) ?>
VAT: = htmlspecialchars($data['settings']['vat_number'] ?? '') ?>
Sales Returns Report
Date: = date('Y-m-d') ?>
Sales Returns
| Return # | Date | Invoice # | Customer | Total Amount | Actions |
|---|---|---|---|---|---|
| RET-= str_pad((string)$ret['id'], 5, '0', STR_PAD_LEFT) ?> | = $ret['return_date'] ?> | INV-= str_pad((string)$ret['invoice_id'], 5, '0', STR_PAD_LEFT) ?> | = htmlspecialchars($ret['customer_name'] ?? 'Walk-in') ?> | OMR = number_format((float)$ret['total_amount'], 3) ?> |
|
| No returns found | |||||
Purchase Returns
| Return # | Date | Invoice # | Supplier | Total Amount | Actions |
|---|---|---|---|---|---|
| PRET-= str_pad((string)$ret['id'], 5, '0', STR_PAD_LEFT) ?> | = $ret['return_date'] ?> | PUR-= str_pad((string)$ret['purchase_id'], 5, '0', STR_PAD_LEFT) ?> | = htmlspecialchars($ret['supplier_name'] ?? 'Unknown') ?> | OMR = number_format((float)$ret['total_amount'], 3) ?> |
|
| No returns found | |||||
HR Departments
| ID | Department Name | Actions |
|---|---|---|
| = $d['id'] ?> | = htmlspecialchars($d['name']) ?> |
HR Employees
| Name | Biometric ID | Department | Position | Salary | Status | Actions |
|---|---|---|---|---|---|---|
|
= htmlspecialchars($e['name']) ?>
= htmlspecialchars($e['email']) ?>
|
= htmlspecialchars($e['biometric_id'] ?? '---') ?> | = htmlspecialchars($e['dept_name'] ?? '---') ?> | = htmlspecialchars($e['position']) ?> | OMR = number_format((float)($e['salary'] ?? 0), 3) ?> | = $e['status'] ?> |
HR Attendance
| Employee | Department | Status | Clock In | Clock Out | Action |
|---|---|---|---|---|---|
| = htmlspecialchars($e['name']) ?> | = htmlspecialchars($e['dept_name'] ?? '---') ?> | = $e['status'] ?> Not Marked | = $e['clock_in'] ?? '---' ?> | = $e['clock_out'] ?? '---' ?> |
HR Payroll
| Employee | Basic | Bonus | Deductions | Net Salary | Status | Actions |
|---|---|---|---|---|---|---|
| = htmlspecialchars($p['emp_name']) ?> | OMR = number_format((float)($p['basic_salary'] ?? 0), 3) ?> | + OMR = number_format((float)($p['bonus'] ?? 0), 3) ?> | - OMR = number_format((float)($p['deductions'] ?? 0), 3) ?> | OMR = number_format((float)($p['net_salary'] ?? 0), 3) ?> | = $p['status'] ?> |
Biometric Devices
| Device Name | IP / IO Address | Port | Serial | Last Sync | Status | Actions |
|---|---|---|---|---|---|---|
| = htmlspecialchars($d['device_name']) ?> |
IP: = htmlspecialchars($d['ip_address']) ?>
IO: = htmlspecialchars($d['io_address']) ?>
|
= $d['port'] ?> | = htmlspecialchars($d['serial_number'] ?? '---') ?> | = $d['last_sync'] ?? 'Never' ?> | = $d['status'] ?> |
POS Devices
| Device Name | Type | Connection | Details | Status | Actions |
|---|---|---|---|---|---|
|
= htmlspecialchars($d['device_name']) ?>
|
= $d['device_type'] ?> | = $d['connection_type'] ?> | = htmlspecialchars((string)$d['ip_address']) ?>:= $d['port'] ?> Baud: = $d['baud_rate'] ?> USB Interface | = $d['status'] ?> |
Profile Picture
= htmlspecialchars($data['user']['username']) ?>
= htmlspecialchars($_SESSION['user_role_name'] ?? 'User') ?>
Edit Profile
Customer Display Settings
Backup Settings
Manual Backup
Create a database backup immediately.
Available Backups
Cash Registers Management
Define your shop counters and registers.
| ID | Name | Status | Created At | Actions |
|---|---|---|---|---|
| #= $r['id'] ?> | = htmlspecialchars($r['name']) ?> | = ucfirst($r['status']) ?> | = $r['created_at'] ?> |
|
Register Sessions (= count($data['sessions']) ?>)
Manage daily opening and closing of cash registers.
| ID | Register | Cashier | Opened At | Closed At | Opening Bal. | Cash Sale | Credit Card | Credit | Total Sale | Balance | Status | Report |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| #= $s['id'] ?> | = htmlspecialchars($s['register_name'] ?? 'N/A') ?> | = htmlspecialchars($s['username'] ?? 'N/A') ?> | = $s['opened_at'] ?> | = $s['closed_at'] ?? '---' ?> | OMR = number_format((float)$s['opening_balance'], 3) ?> | prepare("SELECT SUM(CASE WHEN LOWER(payment_method) = 'cash' THEN amount ELSE 0 END) as cash_total, SUM(CASE WHEN LOWER(payment_method) IN ('card', 'credit card', 'visa', 'mastercard') THEN amount ELSE 0 END) as card_total, SUM(CASE WHEN LOWER(payment_method) = 'credit' THEN amount ELSE 0 END) as credit_total, SUM(CASE WHEN LOWER(payment_method) LIKE '%transfer%' OR LOWER(payment_method) LIKE '%bank%' THEN amount ELSE 0 END) as transfer_total, SUM(amount) as total_sales FROM ( SELECT p.payment_method, p.amount FROM payments p JOIN invoices i ON p.invoice_id = i.id WHERE i.register_session_id = ? AND i.status = 'paid' AND i.is_pos = 1 ) as combined_payments"); $stats_stmt->execute([$s['id']]); $st = $stats_stmt->fetch(); $c_total = (float)($st['cash_total'] ?? 0); $cd_total = (float)($st['card_total'] ?? 0); $cr_total = (float)($st['credit_total'] ?? 0); $tr_total = (float)($st['transfer_total'] ?? 0); $t_sales = (float)($st['total_sales'] ?? 0); $row_expected_cash = (float)$s['opening_balance'] + $c_total; ?>OMR = number_format((float)$c_total, 3) ?> | OMR = number_format((float)$cd_total, 3) ?> | OMR = number_format((float)$cr_total, 3) ?> | OMR = number_format((float)$t_sales, 3) ?> | 0 ? 'text-info' : 'text-danger'); ?> OMR = number_format((float)$diff, 3) ?> --- | = ucfirst($s['status']) ?> |