Initial commit: Hedena Gold monorepo.

First commit of the Hedena Gold product (separate from gold-bank): branding, package names, and deploy defaults aligned to the new brand; legacy Henza trees stay local-only via .gitignore.
This commit is contained in:
s.esmaeili
2026-10-15 17:19:10 +03:30
commit ea86636027
1121 changed files with 401065 additions and 0 deletions
+11
View File
@@ -0,0 +1,11 @@
node_modules
**/node_modules
.turbo
.git
.env
.env.*
!.env.example
*.md
apps/**/tsconfig.tsbuildinfo
apps/**/src
apps/api/dist
+173
View File
@@ -0,0 +1,173 @@
# Database configuration
POSTGRES_USER=postgres
POSTGRES_PASSWORD=postgres
POSTGRES_DB=hedenagold
# Host port for PostgreSQL. Each copy of this stack on the same machine
# must use a different port (the apps talk to hostname "db", not this port).
EXTERNAL_DB_PORT=5432
# Prisma connection string (inside Docker network use hostname "db")
DATABASE_URL=postgresql://${POSTGRES_USER}:${POSTGRES_PASSWORD}@db:5432/${POSTGRES_DB}?schema=public
# ---------------------------------------------------------------------------
# Dev server ports — SINGLE SOURCE OF TRUTH for this monorepo.
# Every app's dev script/config reads its port from here. Do not hardcode a
# port anywhere else. strictPort is enabled everywhere: if a port below is
# already taken, the dev server fails with a clear error instead of silently
# picking another port.
# ---------------------------------------------------------------------------
API_PORT=3000
ADMIN_PANEL_PORT=5180
USER_APP_PORT=5181
# API Configuration (kept for any tooling that still reads bare PORT)
PORT=3000
# ---------------------------------------------------------------------------
# Authentication
# ---------------------------------------------------------------------------
# Admin JWT signing secret. REQUIRED in any real deployment — without it the
# API falls back to a well-known development string.
JWT_SECRET=
# Admin token lifetime (default 12h).
JWT_EXPIRES_IN=
# Customer JWT signing secret. Deliberately SEPARATE from JWT_SECRET so an
# admin token can never validate as a customer token (T1).
JWT_CUSTOMER_SECRET=
# Customer token lifetime (default 30d).
JWT_CUSTOMER_EXPIRES_IN=
# ---------------------------------------------------------------------------
# Accounting software integration (Tahesab / Zarrin, D27). Everything else —
# which software, address, token, mappings — is set in the admin panel
# («پیکر بندی ← اتصال حسابداری»), and the integration is off until then.
# ---------------------------------------------------------------------------
# Encrypts the accounting token at rest. Set a long random value. Blank falls
# back to a key derived from JWT_SECRET (with a boot warning); changing that
# key later means re-entering the token in the admin panel.
ACCOUNTING_SECRET_KEY=
# "off" keeps this API instance out of the background sync (only needed when
# several instances run and you want exactly one doing it; a lease already
# stops two from running the same job).
ACCOUNTING_WORKER=
# ---------------------------------------------------------------------------
# Central IAM — delegated admin login (docs/iam-sso.md)
# ---------------------------------------------------------------------------
# OFF by default. When off, nothing changes: admin login stays a local bcrypt
# check and no request ever leaves this server.
#
# When on, the admin's phone + password are verified against the central
# identity service instead. There is NO UI change: no SSO button, no redirect.
# If the identity service is unreachable or does not know the account, the
# local password check still runs (see IAM_LOGIN_DELEGATION).
IAM_ENABLED=false
IAM_ISSUER=
# The client must be registered there as confidential AND trusted.
IAM_CLIENT_ID=
IAM_CLIENT_SECRET=
# One of the two; tenant_id wins when both are set.
IAM_TENANT_ID=
IAM_TENANT_SLUG=
# off | fallback (default, safest) | exclusive (local password no longer accepted)
IAM_LOGIN_DELEGATION=fallback
IAM_HTTP_TIMEOUT_MS=8000
# صفحه callback اپ کاربر. باید در کلاینت IAM دقیقاً ثبت شود.
IAM_REDIRECT_URI=
# callbackهای اضافه (دولوپ و دامنه دیگر) با کاما. آدرس ناشناس جایگزین نمی‌شود.
IAM_REDIRECT_URIS=
# بعد از ورود محلی، مرورگر برای کوکی نشست مشترک به اینجا برمی‌گردد.
IAM_BROWSER_RETURN_URL=
# خروج سراسری فقط اگر این آدرس در post_logout کلاینت ثبت شده باشد برمی‌گردد.
IAM_POST_LOGOUT_REDIRECT_URI=
# مقصدهای مجاز خروج اپ کاربر، با کاما. باید عیناً در post_logout کلاینت باشند.
IAM_ALLOWED_RETURN_URLS=
# پنل ادمین. خالی یعنی بررسی بی‌صدای ورود در پنل انجام نمی‌شود.
IAM_ADMIN_REDIRECT_URI=
IAM_ADMIN_REDIRECT_URIS=
IAM_ADMIN_BROWSER_RETURN_URL=
IAM_ADMIN_POST_LOGOUT_REDIRECT_URI=
IAM_ADMIN_ALLOWED_RETURN_URLS=
# Revocable admin sessions (AdminSession table).
#
# An admin token is self-contained and lives for JWT_EXPIRES_IN (12h), so until
# this existed nothing could end a session early — not disabling the account, not
# a central sign-out. Every issued token now carries a `jti` recorded in the
# database, and a revoked row is refused on the next request.
#
# Unset = follows IAM_ENABLED (on with the IAM, so central revocation reaches
# here). `true` turns it on without the IAM; `false` opts out of the per-request
# lookup and central revocation then cannot end a session here.
AUTH_SESSION_TRACKING=
# To let the IAM end sessions here, register this path on the client there as its
# backchannel_logout_uri:
# https://<api-host>/api/iam/backchannel-logout
# ---------------------------------------------------------------------------
# ⚠ DELIVERY ONLY — REMOVE BEFORE THE REAL RELEASE (D20 / ISSUES REL-01)
# ---------------------------------------------------------------------------
# A fixed OTP that signs in ANY active customer, alongside the real code.
# MUST BE EXACTLY 4 DIGITS: the apps' login box has four single-character
# inputs and only submits at four (LoginView.vue:43). A longer code still works
# over the API but cannot be typed into either app.
# Leave it EMPTY or unset to disable it completely — that is the correct state
# for production. While it is set, the API prints a warning banner at boot.
OTP_MASTER_CODE=
# ---------------------------------------------------------------------------
# SMS gateway. The default "relay" driver works with everything blank (D26).
# A failed SMS never stops the server or an operation (D20).
# ---------------------------------------------------------------------------
# "relay" (default), "trez", or "none" to disable explicitly.
SMS_PROVIDER=
# relay — the owner's createsms gateway. All four are optional.
# URL and secret have built-in defaults.
SMS_RELAY_URL=
SMS_RELAY_SECRET=
# The "host" field. Blank sends this machine's first external IPv4 — inside
# Docker that is the container's address.
SMS_RELAY_HOST=
# trez — only used with SMS_PROVIDER=trez. Never commit real values.
# Override only for staging; defaults to the provider's live endpoint.
SMS_TREZ_URL=
SMS_TREZ_USERNAME=
SMS_TREZ_PASSWORD=
SMS_TREZ_SENDER_LINE=
# ---------------------------------------------------------------------------
# Uploads
# ---------------------------------------------------------------------------
# Absolute path for uploaded files; defaults to <api>/storage/uploads.
UPLOAD_DIR=
# ---------------------------------------------------------------------------
# Profile completion ("تکمیل پروفایل")
# ---------------------------------------------------------------------------
# Comma-separated admin mobiles told when a customer uploads their documents.
# The reference hardcoded four numbers in its source
# (henza_server Major/CustomerController::sendSmsToAdmin); they live here
# instead so no personal number is committed. Blank means nobody is notified —
# the upload and the customer's own SMS still go through (D20).
PROFILE_ADMIN_MOBILES=
# ---------------------------------------------------------------------------
# Order placement
# ---------------------------------------------------------------------------
# Comma-separated admin mobiles told when a customer places an order. The
# reference hardcoded four numbers (henza_server
# Api/ApiMobileController::setOrder:740-743). Blank means nobody is notified —
# the order, the customer's SMS and the sales expert's SMS still go through.
ORDER_ADMIN_MOBILES=
# ---------------------------------------------------------------------------
# Brand
# ---------------------------------------------------------------------------
# The name at the top of every SMS («هدنا گلد\n…») and the site link in the
# welcome SMS. Blank = the defaults in apps/api/src/common/brand.ts. The
# frontends take their brand from the repo-root brand.ts instead; the full
# rebrand checklist is docs/BRANDING.md.
BRAND_NAME=
BRAND_SITE_URL=
+28
View File
@@ -0,0 +1,28 @@
node_modules/
.turbo/
.env
.env.*
!.env.example
*.log
*.tsbuildinfo
.DS_Store
.idea/
.cursor/
apps/api/generated/
apps/api/dist/
apps/api/storage/uploads/*
!apps/api/storage/uploads/.gitkeep
# Release artifacts ARE committed for Dokploy copy-only deploys:
# apps/api/release/app.js + apps/api/release/vendor/ (Prisma)
# apps/admin-panel/dist/
# apps/user-app/dist/
# Live legacy data dump (customers' personal data). Never commit.
# Only the structure-only oapi-struncture.sql belongs in the repo.
/oapi.sql
# Legacy Henza reference trees — keep locally, never push to Hedena Gold.
/henza_admin/
/henza_pwa/
/henza_server/
+427
View File
@@ -0,0 +1,427 @@
# DELIVERY — gold-banking-monorepo
Branch: **`release/delivery`** · Prepared 2026-09-23
Contains everything from `parity/security-hotfix` and `parity/phase-1-admin`.
Both merged with **no conflicts** (`phase-1-admin` already contained
`security-hotfix`, so the merge was a fast-forward). `main` was not touched.
---
## 0. Quick start — run these in order
Copy-paste, top to bottom. Nothing here needs a decision.
### Step 1 — fill in the environment
Create `.env` in the repo root. These **must** have a value:
```dotenv
# Database
POSTGRES_USER=postgres
POSTGRES_PASSWORD=<choose a strong password>
POSTGRES_DB=goldbank
DATABASE_URL=postgresql://postgres:<the same password>@db:5432/goldbank?schema=public
# Auth — two DIFFERENT random values. Generate each with:
# node -e "console.log(require('crypto').randomBytes(48).toString('base64url'))"
JWT_SECRET=<random value 1, 32+ characters>
JWT_CUSTOMER_SECRET=<random value 2, 32+ characters, NOT the same as above>
# Every origin the panel and the two apps are opened from, comma-separated.
CORS_ORIGINS=https://adm.example.ir,https://app.example.ir,https://app2.example.ir
```
The API **refuses to start** in production until all three are right, and
prints every problem at once (REL-01, REL-03, SEC-04 —
docs/SERVER-SETUP-CHECKLIST.md). A random value:
`node -e "console.log(require('crypto').randomBytes(32).toString('hex'))"`.
Inside Docker the database host is `db`, not `localhost`.
Everything else is optional and may be left blank. Two you may want now:
```dotenv
# Delivery only — a fixed OTP that signs in ANY active customer.
# Exactly 4 digits, or it cannot be typed into the apps. REMOVE before the
# real release (see "Before the real release" below). The production image
# refuses to start with it unless the server is marked as a test server:
OTP_MASTER_CODE=1379
TEST_SERVER_ALLOW_MASTER_CODE=yes
# SMS goes through the "relay" gateway with nothing to set (D26).
# SMS_PROVIDER=none turns sending off; the server still starts either way.
SMS_PROVIDER=
```
### Step 2 — build
```bash
pnpm install
pnpm build:release
```
**Do not skip `pnpm build:release`, and never run `docker compose build`
without it first.** The API image copies a bundle built here on the machine; it
does not build inside the image. Skipping this step produces an image from
**old code** and still reports success. This is real — it happened during this
delivery's own test run, with a bundle four days stale. (DEPLOY-03)
### Step 3 — start
```bash
docker compose up -d --build
```
Database migrations and seeding run **automatically inside the API container**
at boot. There is no manual migration step. Never run `prisma migrate reset`.
### Step 4 — check it came up
```bash
docker compose ps # db healthy, api up
docker compose logs api | tail -40
```
In the log you should see `Nest application successfully started`, and
`Applied migrations: …` (first run) or `No pending migrations` (later runs).
An `OTP_MASTER_CODE IS ACTIVE` banner is **expected** while that variable is
set — it is a reminder, not an error, and it disappears once you remove the
variable before the real release.
A `JWT_CUSTOMER_SECRET IS NOT SET` banner means **Step 1 was not done**. That
one is a real security problem, not a warning to ignore — go back and set it.
### Step 5 — prove the whole flow works
```bash
# Publishes the API on host port 3100 so the test can reach it.
docker compose -f docker-compose.yml -f docker-compose.delivery-test.yml up -d api
node apps/api/scripts/test-compose-e2e.cjs http://localhost:3100/api <OTP_MASTER_CODE>
```
Expect **32 passed, 0 failed**. It signs a sales expert and an ordinary
customer into the app, has both place an order, confirms both orders appear in
the admin panel, and re-checks the token boundaries — all against the real
container.
`docker-compose.delivery-test.yml` exists **only** for that check. The normal
deployment uses `docker-compose.yml` alone, where the API has no host port and
Dokploy/Traefik routes to it by domain.
---
## ⚠ Before the real release
Tonight's build is a **delivery build**. These are the things that must change
before it is a production release. The first three are blocking.
### A. Configuration — blocking
| # | Do this | Why it matters |
|---|---|---|
| **1** | **Set `JWT_CUSTOMER_SECRET` to its own random value**, different from `JWT_SECRET`. | Not a cosmetic default. Unset, the API signs customer and sales-expert **app** tokens with `JWT_SECRET` — *the same key admin tokens use* — and the two token realms stop being cryptographically separate. The only remaining barrier is the `typ` check in `jwt.strategy.ts`, and a sales expert's app token carries their **AdminUser id** in `sub`. Two independent defences collapse into one. A loud boot banner fires while it is missing. **REL-03 (Critical).** |
| **2** | **Remove `OTP_MASTER_CODE` and `TEST_SERVER_ALLOW_MASTER_CODE` from the environment.** The API now refuses to start with the code set unless that flag says this is a test server. | While set, **any active customer signs in with that one fixed code**. Unset or empty disables it completely; the API prints a banner at boot for as long as it is armed. **REL-01 (Critical).** |
| **3** | **Set real `JWT_SECRET` and `CORS_ORIGINS`.** The API refuses to start without them. | Without the key anyone could forge an admin token; without the origin list any website could call the API from a visitor's browser. |
| **4** | **Confirm SMS is going out.** The default `relay` gateway needs no credentials (D26); check `docker compose logs api` for `SMS provider: relay` and send yourself a login code. | If the gateway refuses the `host` value (inside Docker it is the container's IP), set `SMS_RELAY_HOST`. A failed send is only a log line — the server still boots (D20). **REL-02.** |
| **5** | **Accounting integration (D27), only if it will be switched on:** set `ACCOUNTING_SECRET_KEY`; count products with no image (they disappear from the app — query in ISSUES ACC-05) and photograph them first; for Zarrin, run the trial on temporary documents first (ACC-01). | The integration itself is off until an admin turns it on in «اتصال حسابداری»; nothing changes before that except the no-image rule, which applies to every product. |
After changing any of these: `docker compose up -d --build` and confirm the
`OTP_MASTER_CODE` banner is **gone** from `docker compose logs api`.
### B. Credentials to rotate — the reference leaked them
These are committed in plaintext in `henza_server` and must be assumed
compromised by anyone who has ever had repo access. None were copied into this
repository, but they are **the same live accounts**.
- **SMS panel** username + password + sender line (`app/Models/Sms.php:73-77`) — **SEC-12 (Critical)**
- PayPing bearer token, Tahesab bearer token + IP allowlist, wallet hash pepper — **SEC-06**
### C. Parity work not finished
Phase 1 stopped after the Persons section when delivery mode began (D19). The
**Phase 1 gate still stands** as the next milestone.
**Admin — not yet audited field-by-field.** Each has had only the breakage scan
(`scan-admin-b2b.cjs`, 34 endpoints, 0 broken), not a parity audit:
- **Financial documents** (اسناد) — the money path; highest priority of the three
- **Users & permissions** (کاربران و دسترسی‌ها) — includes **PERM-01**, still
open: the database holds **178** distinct permission ids against the UI's
**174**. Unresolved because fixing it means **deleting rows**, which needs
your approval.
- **Reports** (گزارش‌ها)
- Also untouched: products/categories/variants, SMS templates, promotions,
cities, branches, workshops.
**Apps — known gaps.**
| ID | What |
|---|---|
| **MON-08** | `wagePercent`, `discountPercent` and `flatRialCharge` are taken from the **client** on order creation, so a caller can set their own making charge. `rashWeightGrams` is correctly read from the variant. The reference is *worse* (it trusts client `rash_weight` too), so this is already a partial improvement — but it is still a money path trusting client input. **Fix this first in Phase 2.** |
| **STUB-05** | Admin SMS recipients are hardcoded mobile numbers scattered across six places in the reference. Port as `SMS_ADMIN_RECIPIENTS` (comma-separated), the way `PROFILE_ADMIN_MOBILES` already works — not by copying the literals. Staff changes should not need a deploy. |
| **STUB-04** | Live gold price is **pull-on-mount only** — no socket, no polling. `quotedAt` renders as a Jalali **date**, so a stale rate looks current. |
| **STUB-03** | All list filtering and paging is **client-side** over one flat `GET /catalog/products`; no server `page`/`limit`. |
| **Analytics** | The reference PWA calls `useCustomAnalytics` on every route change (`henza_pwa/src/router/index.ts:249`); neither target app has any analytics. Deliberate — it needs a provider decision from you, not a port. |
**`docs/parity/ISSUES.md`** holds the full list with evidence and file
references — currently **40+ entries**, including everything above plus the
reference bugs deliberately not ported (SEC-14, SEC-16, APP-03, and the two
D21 items). Phase 3 is the pass over that file.
---
## 1. Environment variables
Names only — no values here, and none are committed. The full annotated list is
in `.env.example`; `docker-compose.yml` passes each one through to the API
container.
### Required
| Variable | Purpose |
|---|---|
| `DATABASE_URL` | PostgreSQL connection string. Inside Docker the host is `db`. |
| `POSTGRES_USER`, `POSTGRES_PASSWORD`, `POSTGRES_DB` | Credentials for the bundled `db` service. |
| `JWT_SECRET` | Signs **admin** tokens. Without it the API falls back to a well-known development string — set it. |
| `JWT_CUSTOMER_SECRET` | Signs **customer and sales-expert app** tokens. Must be its own value — see the warning at the top of this file. Unset, it falls back to `JWT_SECRET` and the two token realms merge. |
### Optional
| Variable | Default | Purpose |
|---|---|---|
| `PORT` / `API_PORT` | `3000` | API listen port. |
| `JWT_EXPIRES_IN` | `12h` | Admin token lifetime. |
| `JWT_CUSTOMER_EXPIRES_IN` | `30d` | Customer token lifetime. |
| `UPLOAD_DIR` | `<api>/storage/uploads` | Where uploaded files are written. |
| `ADMIN_PANEL_PORT`, `USER_APP_PORT`, `USER_APP_V2_PORT` | 5180–5182 | Dev servers only. |
| `RUN_MIGRATIONS` | `true` | Set `false` to skip the boot-time migration run. |
| `RUN_SEED` | `true` | Set `false` to skip seeding. |
| `ACCOUNTING_SECRET_KEY` | *(derived from `JWT_SECRET`)* | Encrypts the accounting-software token the admin enters (D27). Set its own long random value; changing it later means re-entering the token. |
| `ACCOUNTING_WORKER` | `on` | `off` keeps this instance out of the accounting background sync. |
| `PROFILE_ADMIN_MOBILES` | *(blank)* | Comma-separated admin mobiles told when a customer completes their profile. The reference hardcoded four numbers; blank means nobody is notified and the upload still succeeds. |
### SMS — all optional
`SMS_PROVIDER`: `relay` (default), `trez`, or `none` (D26).
- **relay**: `SMS_RELAY_URL`, `SMS_RELAY_SECRET` (both have built-in
defaults), `SMS_RELAY_HOST` (blank = the machine's first external IPv4).
No `platform` is sent; the gateway picks the line.
- **trez**: `SMS_TREZ_URL`, `SMS_TREZ_USERNAME`, `SMS_TREZ_PASSWORD`,
`SMS_TREZ_SENDER_LINE`.
The server **always starts**; a misconfigured provider is a warning, and a
failed or skipped SMS never blocks an operation, including customer creation.
### ⚠ `OTP_MASTER_CODE` — delivery only
A fixed OTP accepted for **any active customer**, alongside the real code.
- Read only from the environment; never hardcoded.
- Unset or empty → completely disabled.
- **Must be exactly 4 digits.** Both apps' login box is four single-character
inputs and only submits at four, so a longer code works over the API but
cannot be typed into either app.
- Every login through it is logged with the customer's mobile.
- The real OTP keeps working unchanged while it is armed.
---
## 2. Running it
### Development
```bash
pnpm install
pnpm dev # all apps via turbo
```
Ports come from the repo-root `.env` (single source of truth):
API 3000, admin-panel 5180, user-app 5181, user-app-v2 5182.
### Build
```bash
pnpm build # all workspaces
pnpm build:release # the production/Docker build
```
### Deploy (Docker)
```bash
pnpm build:release # ⚠ REQUIRED FIRST — see below
docker compose up -d --build
```
> **⚠ `pnpm build:release` must be run before `docker compose build`.**
> The API image is `COPY release/ ./` — it ships a bundle built on the
> developer machine, not one built inside the image. So `docker compose build`
> will happily produce an image from a **stale** `release/app.js` and report
> success. During this delivery's compose run that bundle was four days old and
> the container was missing every route added since. Tracked as **DEPLOY-03**.
Services: `db` (Postgres 15), `api` (port 3000), `admin-panel`, `user-app`,
`user-app-v2` (each nginx on port 80). The apps expose no host ports —
Dokploy/Traefik routes to them by domain. Uploads persist in the `api_uploads`
volume; without it every previously uploaded image 404s after a redeploy.
---
## 3. How migrations run
**Automatically, inside the API container, at boot.** No manual step.
`src/prisma/bootstrap.ts` calls `runMigrations()` before Nest starts. That
runner (`src/prisma/migrate.ts`) applies the `.sql` files from
`prisma/migrations` and records each one in its own tracking table,
**`_goldbank_migrations`**, so every file runs exactly once.
It exists because **the deploy image is copy-only and ships no Prisma CLI**, so
`prisma migrate deploy` is not available there. This is why the database has two
migration ledgers — `_prisma_migrations` (written by the Prisma CLI in
development) and `_goldbank_migrations` (written by the runtime runner). Both
are intentional. `_goldbank_migrations` is declared in `schema.prisma` with
`@@ignore` so drift checks do not propose dropping it.
**Never** run `prisma migrate reset`, and never edit either table by hand.
In development, migrations are created with `prisma migrate dev`; in production
the container runner applies them.
Seeding runs once after migrations, gated on a marker row, and is skipped when
no seed script is present.
---
## 4. What was verified on this branch
All green on `release/delivery`:
| Suite | Result |
|---|---|
| `pnpm build` (5 workspaces) | ✅ all pass |
| jest (api unit) | **54/54** |
| `smoke-admin.cjs` — admin flows | **43/43** |
| `smoke-apps.cjs` — customer flows, both apps | **43/43** |
| `scan-admin-b2b.cjs` — every B2B read endpoint | **34 ok, 0 broken** |
| `smoke-admin-b2b-writes.cjs` — order + document writes | **25/25** |
| `auth-smoke.sh` — permissions/401/403 | **32/32** |
| `test-sales-expert-roundtrip.cjs` | **33/33** |
| `test-sales-expert-app-login.cjs` — expert app login (D21) | **36/36** |
| `test-complete-profile.cjs` — «تکمیل پروفایل» | **38/38** |
| `test-report.cjs` — «گزارش» | **40/40** |
| `test-compose-e2e.cjs` — **the whole flow inside Docker Compose** | **32/32** |
| `test-name-trigger.cjs` | **9/9** |
| typecheck (api, admin-panel, user-app, user-app-v2) | ✅ clean |
### Verified inside Docker Compose, not just locally
The whole delivery flow was run against the **built container**, which is what
actually ships: `test-compose-e2e.cjs` signs a **sales expert** and an
**ordinary customer** into the app with the master code, has **both place an
order**, and confirms **both orders appear in the admin panel** and open there.
It also re-checks the three token boundaries in the deployed image. **32/32.**
The three page suites were re-run against the container too — complete-profile
38/38, report 40/40, expert login 36/36.
That run found two deployment problems that no local test could have caught:
- **DEPLOY-02 (fixed):** admin login returned **500 for every user in Docker**.
Compose passes optional variables as `${X:-}`, so an unconfigured one arrives
as `""`, not `undefined`; the code used `?? 'default'`, which only falls back
on `undefined`, so the empty string reached `jsonwebtoken` and it threw on
every sign. Fixed with `src/common/env.ts`, applied to every auth, port,
upload and SMS read, and pinned by a test that reproduces the original throw.
- **DEPLOY-03 (process):** the API image ships a **pre-built** bundle, so
`docker compose build` can silently produce an image from stale code. See the
warning in the deploy section above.
Flows walked end to end: admin login, customer creation, sales-expert
create/edit, product and variant create/edit, order list/detail/status change,
wholesale order placement from the admin panel, cash document creation +
confirm + un-confirm; and in **both** customer apps: OTP login with the master
code, product browsing, cart, order placement, order history.
Money paths were checked against the reference's own formulas, not just for a
200: making charge `rash × (1 + (wage − discount)/100)` reproduced exactly, and
the cash-document conversion `price / (price_per_gram / 4.331802)` moved the
customer's gold debt by the expected amount and restored it exactly on
un-confirm.
Every test script deletes only the rows it created; the write test also asserts
the customer's balances end exactly as they started.
---
## 5. Known issues — not done tonight
Nothing here blocks the delivery. Full detail in `docs/parity/ISSUES.md`.
### Missing app pages
**None.** Every page the reference PWA has now exists in both apps.
### Delivered tonight
| Feature | State |
|---|---|
| **Sales-expert app login (D21)** | ✅ Done. An expert signs into both apps with their AdminUser account and the ordinary OTP flow; the master code works for them too. They get the whole app — browsing, cart, ordering, order history — plus their own two screens. |
| **«سفارش مشتریان» (ChildOrder)** | ✅ Done in both apps. Their referred customers' orders at «تحویل مسئول فروش», searchable, infinite-scrolled. |
| **«مشتریان من» (customerChoice)** | ✅ Done in both apps. Their referred customers, searchable, with a read-only detail sheet. |
| **APP-02 — admin home slider in v2** | ✅ Fixed. v2 now prefers admin-configured slides and keeps its category-derived hero as the fallback. |
| **«تکمیل پروفایل» (complete_profile)** | ✅ Done in both apps. Three document uploads (جواز کسب، سردر مغازه، کارت ملی), then the profile is marked verified. Reached from the profile screen, and only while the documents are missing — exactly the reference's condition. |
| **«گزارش» (report + report/detail)** | ✅ Done in both apps. Two tabs («کلیات حساب» / «جزئیات حساب»), a running gold and rial balance per document, and a per-document detail sheet. Built on the **internal ledger** (owner's option الف) — no connection to the external accounting system the reference proxied. See D24. |
An expert's own order lands on their **own trading account**, with the making
charge from `AdminUser.wagePercent` and the credit limit from
`SalesExpertProfile.gramLevel` — the same two numbers the reference read off
the agent's own customer row. See D21.
**Two reference behaviours were deliberately not ported**, both money/session
risks and both recorded in D21:
1. `myChild` minted an `api_token` per listed customer so the agent could act
**as** them — a session-hijack primitive.
2. The child-order edit drawer (`PUT /order/child/{id}`) recalculated an
order's weights and prices from client-sent values. The card opens a
read-only summary instead.
### Behavioural gaps
| ID | What |
|---|---|
| **APP-02** | `user-app-v2` has no `getHomeSlider`, so slides configured in the admin panel appear in **user-app only**; v2 always derives its hero from categories. Not fixed because v2's home is its own design and rewiring it during a delivery risks the page being demonstrated. |
| **PERS-02** | The reference's cities are a province → city **tree** (provinces not selectable); the target flattened this to a `province` string and a flat select on all three Persons forms. The city itself is still captured correctly. |
| **PERS-03** | The reference collects a Jalali **birth date** on the customer forms; the target has no column for it. |
| **PERS-01** | The reference makes a customer's **mobile immutable on edit**; the target allows editing it. Owner ruled this NOT ported — the target keeps its current behaviour. |
| **PERF-01** | `listReagents()` runs one aggregate per row (N+1) for the per-agent sales total. Harmless at the current agent count. |
### Parity work not reached
Phase 1 was not completed: the field-by-field audit stopped after the Persons
section, and products/categories/variants, financial documents, users and
permissions, SMS templates, promotions, cities, branches, workshops and reports
have had only the breakage scan above, not a full parity audit. The
**Phase 1 gate was lifted for tonight only** (D19) and still stands as the next
milestone.
`PERM-01` (the database holds 178 distinct permission ids against the UI's 174)
is still awaiting a decision, because resolving it means deleting rows.
---
## 6. Decisions that shaped this build
Recorded in `docs/parity/DECISIONS.md`:
- **D13** — the retail storefront (`single*`, wallet, comments, `customer.php`,
`site.php`) is **preserved but out of scope**. Nothing there was changed.
- **D19** — delivery mode: implement the main gaps, do not stop to ask, choose
the lowest-risk option, change nothing protected.
- **D20** — SMS can never block a boot or an operation; `OTP_MASTER_CODE` for
the delivery.
- **D26** — SMS goes through the owner's `relay` gateway by default; Trez is
kept as a selectable driver.
- **D11 is cancelled** — superseded by D13.
+57
View File
@@ -0,0 +1,57 @@
# Docker — copy-only deploy (Dokploy)
Build artifacts are produced **on the developer machine** and committed to git.
Dokploy only builds thin images that copy those files (no `pnpm install` on the server).
## One-time / before each deploy
```bash
pnpm install
pnpm build:release
git add -f apps/api/release apps/admin-panel/dist apps/user-app/dist
git commit -m "chore: refresh release artifacts"
git push
```
What this produces:
| App | Artifact | Image |
|---|---|---|
| API | `apps/api/release/app.js` (+ Prisma under `release/vendor`) | `docker.arvancloud.ir/node:20-bookworm` |
| Admin | `apps/admin-panel/dist/` | `docker.arvancloud.ir/nginx:latest` |
| User | `apps/user-app/dist/` | `docker.arvancloud.ir/nginx:latest` |
## Dokploy Environment
```env
POSTGRES_USER=hedenagold
POSTGRES_PASSWORD=...
POSTGRES_DB=hedenagold
EXTERNAL_DB_PORT=5433
DATABASE_URL=postgresql://hedenagold:...@db:5432/hedenagold?schema=public
PORT=3000
```
A second copy on the **same server** is a separate Dokploy application (its own
domains, passwords, and `JWT_SECRET`). Do not set `container_name` in this file:
those names are global in Docker, and a fixed `hedenagold_db` collides with the
first copy. Give the second app its own `EXTERNAL_DB_PORT` (for example `5434`
if `5433` is already taken). Volumes stay separate because Dokploy uses a
different Compose project name for each application.
## Domains (container ports)
| Service | Domain | Port |
|---|---|---|
| `admin-panel` | admin.example.com | **80** |
| `user-app` | app.example.com | **80** |
| `api` | (optional) | **3000** |
Frontends call `/api` on their own domain; nginx proxies to `api:3000`.
## Local compose smoke test
```bash
pnpm build:release
docker compose up --build -d
```
+5
View File
@@ -0,0 +1,5 @@
*
!dist/
!dist/**
!nginx.conf
!Dockerfile
+11
View File
@@ -0,0 +1,11 @@
# Dist is committed for Dokploy copy-only images (see DOCKER.md).
branchDist/
node_modules/
*.tsbuildinfo
# Never commit compiled siblings next to sources — the previous scaffold
# had 17 stale .js/.d.ts files checked in alongside its .ts files.
src/**/*.js
src/**/*.d.ts
!src/env.d.ts
!src/types/**/*.d.ts
+8
View File
@@ -0,0 +1,8 @@
FROM nginx:latest
COPY nginx.conf /etc/nginx/conf.d/default.conf
COPY dist /usr/share/nginx/html
EXPOSE 80
CMD ["nginx", "-g", "daemon off;"]
@@ -0,0 +1 @@
import{c as O,I as x,d as j,x as B,y as m,o as C,a as A,w as y,f as $,t as E,h as P,i as L,m as u,a8 as v,M as b,G as M,r as N}from"./index-B13tkMpd.js";var V={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M168 504.2c1-43.7 10-86.1 26.9-126 17.3-41 42.1-77.7 73.7-109.4S337 212.3 378 195c42.4-17.9 87.4-27 133.9-27s91.5 9.1 133.8 27A341.5 341.5 0 01755 268.8c9.9 9.9 19.2 20.4 27.8 31.4l-60.2 47a8 8 0 003 14.1l175.7 43c5 1.2 9.9-2.6 9.9-7.7l.8-180.9c0-6.7-7.7-10.5-12.9-6.3l-56.4 44.1C765.8 155.1 646.2 92 511.8 92 282.7 92 96.3 275.6 92 503.8a8 8 0 008 8.2h60c4.4 0 7.9-3.5 8-7.8zm756 7.8h-60c-4.4 0-7.9 3.5-8 7.8-1 43.7-10 86.1-26.9 126-17.3 41-42.1 77.8-73.7 109.4A342.45 342.45 0 01512.1 856a342.24 342.24 0 01-243.2-100.8c-9.9-9.9-19.2-20.4-27.8-31.4l60.2-47a8 8 0 00-3-14.1l-175.7-43c-5-1.2-9.9 2.6-9.9 7.7l-.7 181c0 6.7 7.7 10.5 12.9 6.3l56.4-44.1C258.2 868.9 377.8 932 512.2 932c229.2 0 415.5-183.7 419.8-411.8a8 8 0 00-8-8.2z"}}]},name:"sync",theme:"outlined"};function g(o){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?Object(arguments[t]):{},r=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(r=r.concat(Object.getOwnPropertySymbols(n).filter(function(c){return Object.getOwnPropertyDescriptor(n,c).enumerable}))),r.forEach(function(c){z(o,c,n[c])})}return o}function z(o,t,n){return t in o?Object.defineProperty(o,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):o[t]=n,o}var d=function(t,n){var r=g({},t,n.attrs);return O(x,g({},r,{icon:V}),null)};d.displayName="SyncOutlined";d.inheritAttrs=!1;const I=j({__name:"AccountingSyncButton",props:{endpoint:{}},emits:["done"],setup(o,{emit:t}){const n=o,r=t,c=u(!1),p=u(null),i=u(!1),h={customers:"مشتریان",balances:"مانده‌ها",products:"کارساخته‌ها و موجودی"},_={scanned:"بررسی‌شده",inScope:"در گروه‌های انتخابی",refreshed:"به‌روز",linked:"لینک‌شده",imported:"وارد شده",issues:"مغایرت",updated:"به‌روز",items:"کارساخته",stockErrors:"خطای موجودی"},S=e=>e&&typeof e=="object"?Object.entries(e).map(([s,a])=>`${_[s]??s}: ${a}`).join("، "):"";B(async()=>{try{const{data:e}=await m.get("admin/accounting-status");c.value=!!(e!=null&&e.connected),p.value=(e==null?void 0:e.provider)??null}catch{c.value=!1}});async function w(){var e,s;i.value=!0;try{const{data:a}=await m.post(n.endpoint),k=Object.entries(a.results).map(([f,l])=>v("p",{style:l.ok?"":"color:#d4380d"},`${h[f]??f}: ${l.ok?S(l.summary)||"انجام شد":`خطا — ${l.error}`}`));(a.ok?b.success:b.warning)({title:a.ok?"سینک با حسابداری انجام شد":"سینک با حسابداری کامل انجام نشد",content:v("div",k),okText:"باشه"}),r("done")}catch(a){M.error(((s=(e=a==null?void 0:a.response)==null?void 0:e.data)==null?void 0:s.message)||"سینک با حسابداری انجام نشد")}finally{i.value=!1}}return(e,s)=>{const a=N("a-button");return c.value?(C(),A(a,{key:0,loading:i.value,onClick:w},{icon:y(()=>[O(P(d))]),default:y(()=>[$(" سینک با "+E(p.value||"حسابداری"),1)]),_:1},8,["loading"])):L("",!0)}}});export{I as _};
+1
View File
@@ -0,0 +1 @@
import{_ as o}from"./Add.vue_vue_type_script_setup_true_lang-CcEgUcgF.js";import"./index-B13tkMpd.js";import"./BaseFormModal.vue_vue_type_style_index_0_lang-CyAC3-m9.js";import"./ImageUploadInput.vue_vue_type_script_setup_true_lang-C-8ZQMi-.js";export{o as default};
File diff suppressed because one or more lines are too long
+1
View File
@@ -0,0 +1 @@
import{_ as o}from"./AddBranches.vue_vue_type_script_setup_true_lang-O5kvMvjg.js";import"./index-B13tkMpd.js";import"./BaseFormModal.vue_vue_type_style_index_0_lang-CyAC3-m9.js";export{o as default};
@@ -0,0 +1 @@
import{d as L,x as T,y as c,a as v,w as l,h as R,k as q,m as S,z as C,r as i,o as p,p as O,c as n,b as $,e as j,f as g,t as z,F as M,H as I,G as N,l as J}from"./index-B13tkMpd.js";import{_ as K}from"./BaseFormModal.vue_vue_type_style_index_0_lang-CyAC3-m9.js";const P={class:"grid-2"},Q={class:"grid-2"},Y=L({__name:"AddBranches",props:{open:{type:Boolean},id:{}},emits:["update:open","success"],setup(h,{emit:V}){const y=h,w=V,f=y.open!==void 0,E=q(),F=J(),r=f?y.id:E.params.id,m=S(!1),_=S([]),t=C({name:"",phone:"",address:"",user_id:void 0}),d=C({});function k(s,e){var o,u;return String(((u=(o=e==null?void 0:e.children)==null?void 0:o[0])==null?void 0:u.children)??"").includes(s)}async function b(){var s,e;if(Object.keys(d).forEach(o=>delete d[o]),!t.name){d.name="لطفا مقدار را وارد کنید";return}try{m.value=!0,r?await c.put(`branch/${r}`,t):await c.post("branch",t),N.info("اطلاعات با موفقیت به ثبت رسید."),r||Object.assign(t,{name:"",phone:"",address:"",user_id:void 0}),f?(w("success"),w("update:open",!1)):F.push("/branch/list")}catch(o){N.error(((e=(s=o==null?void 0:o.response)==null?void 0:s.data)==null?void 0:e.message)??"خطا در ثبت اطلاعات.")}finally{m.value=!1}}return T(async()=>{try{const{data:s}=await c.get("user/list");_.value=s}catch(s){console.log(s)}if(r)try{const{data:s}=await c.get(`branch/${r}`);Object.assign(t,{name:s.name??"",phone:s.phone??"",address:s.address??"",user_id:s.user_id??void 0})}catch(s){console.log(s)}}),(s,e)=>{const o=i("a-input"),u=i("a-form-item"),U=i("a-select-option"),x=i("a-select"),B=i("a-textarea"),A=i("a-button"),D=i("a-card"),G=i("a-form"),H=i("a-spin");return f?(p(),v(K,{key:0,open:!!h.open,id:R(r),"add-title":"افزودن شعبه","edit-title":"ویرایش شعبه",loading:m.value,submitting:m.value,"onUpdate:open":e[4]||(e[4]=a=>s.$emit("update:open",a)),onSubmit:b},{default:l(()=>[O("div",P,[n(u,{label:"نام شعبه","validate-status":d.name?"error":"",help:d.name},{default:l(()=>[n(o,{value:t.name,"onUpdate:value":e[0]||(e[0]=a=>t.name=a)},null,8,["value"])]),_:1},8,["validate-status","help"]),n(u,{label:"تلفن شعبه"},{default:l(()=>[n(o,{value:t.phone,"onUpdate:value":e[1]||(e[1]=a=>t.phone=a)},null,8,["value"])]),_:1}),n(u,{label:"مدیر"},{default:l(()=>[n(x,{value:t.user_id,"onUpdate:value":e[2]||(e[2]=a=>t.user_id=a),"show-search":"","allow-clear":"",placeholder:"انتخاب کنید","filter-option":k},{default:l(()=>[(p(!0),$(M,null,j(_.value,a=>(p(),v(U,{key:a.id,value:a.id},{default:l(()=>[g(z(a.name),1)]),_:2},1032,["value"]))),128))]),_:1},8,["value"])]),_:1})]),n(u,{label:"آدرس"},{default:l(()=>[n(B,{value:t.address,"onUpdate:value":e[3]||(e[3]=a=>t.address=a),"auto-size":{minRows:2,maxRows:5}},null,8,["value"])]),_:1})]),_:1},8,["open","id","loading","submitting"])):(p(),v(H,{key:1,spinning:m.value},{default:l(()=>[n(G,{layout:"vertical",onSubmit:I(b,["prevent"])},{default:l(()=>[n(D,{title:R(r)?"ویرایش شعبه":"افزودن شعبه",class:"mb-base page-card"},{default:l(()=>[O("div",Q,[n(u,{label:"نام شعبه","validate-status":d.name?"error":"",help:d.name},{default:l(()=>[n(o,{value:t.name,"onUpdate:value":e[5]||(e[5]=a=>t.name=a)},null,8,["value"])]),_:1},8,["validate-status","help"]),n(u,{label:"تلفن شعبه"},{default:l(()=>[n(o,{value:t.phone,"onUpdate:value":e[6]||(e[6]=a=>t.phone=a)},null,8,["value"])]),_:1}),n(u,{label:"مدیر"},{default:l(()=>[n(x,{value:t.user_id,"onUpdate:value":e[7]||(e[7]=a=>t.user_id=a),"show-search":"","allow-clear":"",placeholder:"انتخاب کنید","filter-option":k},{default:l(()=>[(p(!0),$(M,null,j(_.value,a=>(p(),v(U,{key:a.id,value:a.id},{default:l(()=>[g(z(a.name),1)]),_:2},1032,["value"]))),128))]),_:1},8,["value"])]),_:1})]),n(u,{label:"آدرس"},{default:l(()=>[n(B,{value:t.address,"onUpdate:value":e[8]||(e[8]=a=>t.address=a),"auto-size":{minRows:2,maxRows:5}},null,8,["value"])]),_:1}),n(A,{type:"primary",class:"form-submit",onClick:b},{default:l(()=>[...e[9]||(e[9]=[g("ثبت اطلاعات",-1)])]),_:1})]),_:1},8,["title"])]),_:1})]),_:1},8,["spinning"]))}}});export{Y as _};
+1
View File
@@ -0,0 +1 @@
b[data-v-09902473]{font-weight:500}.kind-picker[data-v-09902473]{display:grid;grid-template-columns:repeat(auto-fit,minmax(220px,1fr));gap:12px;margin-bottom:20px}.kind-card[data-v-09902473]{position:relative;display:flex;align-items:center;gap:12px;padding:14px 16px;border:1.5px solid #eef0f5;border-radius:16px;background:#fff;text-align:start;cursor:pointer;font:inherit;transition:border-color .2s ease,box-shadow .2s ease,background .2s ease}.kind-card[data-v-09902473]:hover{border-color:#c9d0dd}.kind-card.is-on[data-v-09902473]{border-color:#1c2d56;background:#1c2d5608;box-shadow:0 0 0 3px #1c2d5614}.kind-card__icon[data-v-09902473]{width:42px;height:42px;flex-shrink:0;display:grid;place-items:center;border-radius:12px;font-size:16px;color:#8a94a6;background:#f2f4f7;transition:color .2s ease,background .2s ease}.kind-card.is-on .kind-card__icon[data-v-09902473]{color:#fff;background:#1c2d56}.kind-card__text[data-v-09902473]{display:flex;flex-direction:column;gap:2px;min-width:0}.kind-card__text b[data-v-09902473]{font-size:14px;color:#101828}.kind-card__text small[data-v-09902473]{font-size:12px;color:#8a94a6}.kind-card__check[data-v-09902473]{margin-inline-start:auto;font-size:16px;color:#1c2d56}@media (max-width: 575px){.kind-picker[data-v-09902473]{grid-template-columns:minmax(0,1fr);gap:8px;margin-bottom:12px}.kind-card[data-v-09902473]{padding:10px 12px}.kind-card__icon[data-v-09902473]{width:36px;height:36px;font-size:16px}}
+1
View File
@@ -0,0 +1 @@
import{c as h,I as w,d as x,u as z,m as B,b as l,p as n,w as I,F as v,e as P,a as m,g as k,i as p,k as R,s as A,r as F,o as i,h as b,R as H,l as V,q as j,t as y,L as M,_ as N}from"./index-B13tkMpd.js";import{_ as D}from"./bulkCustomer.vue_vue_type_script_setup_true_lang-DCiRvD_P.js";import{R as U}from"./ReagentCustomer-XSZR4Hgo.js";import{S as $}from"./singleCustomer-DNW92cmo.js";import{S as q}from"./ShopOutlined-BULNMNmg.js";import{U as E}from"./UserOutlined-tnfFbi-d.js";import"./BaseFormModal.vue_vue_type_style_index_0_lang-CyAC3-m9.js";import"./ImageUploadInput.vue_vue_type_script_setup_true_lang-C-8ZQMi-.js";import"./CityTreeSelect.vue_vue_type_script_setup_true_lang-cGpnZ8Gn.js";import"./DateInput-CVKHy-b9.js";import"./index-DXwUc_-g.js";import"./EnvironmentOutlined-BII2axx6.js";import"./PercentageOutlined-CpguakOP.js";import"./SafetyCertificateOutlined-B7xsdKuU.js";import"./CameraOutlined-CZeD3bSm.js";var L={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M928 160H96c-17.7 0-32 14.3-32 32v640c0 17.7 14.3 32 32 32h832c17.7 0 32-14.3 32-32V192c0-17.7-14.3-32-32-32zm-40 632H136V232h752v560zM610.3 476h123.4c1.3 0 2.3-3.6 2.3-8v-48c0-4.4-1-8-2.3-8H610.3c-1.3 0-2.3 3.6-2.3 8v48c0 4.4 1 8 2.3 8zm4.8 144h185.7c3.9 0 7.1-3.6 7.1-8v-48c0-4.4-3.2-8-7.1-8H615.1c-3.9 0-7.1 3.6-7.1 8v48c0 4.4 3.2 8 7.1 8zM224 673h43.9c4.2 0 7.6-3.3 7.9-7.5 3.8-50.5 46-90.5 97.2-90.5s93.4 40 97.2 90.5c.3 4.2 3.7 7.5 7.9 7.5H522a8 8 0 008-8.4c-2.8-53.3-32-99.7-74.6-126.1a111.8 111.8 0 0029.1-75.5c0-61.9-49.9-112-111.4-112s-111.4 50.1-111.4 112c0 29.1 11 55.5 29.1 75.5a158.09 158.09 0 00-74.6 126.1c-.4 4.6 3.2 8.4 7.8 8.4zm149-262c28.5 0 51.7 23.3 51.7 52s-23.2 52-51.7 52-51.7-23.3-51.7-52 23.2-52 51.7-52z"}}]},name:"idcard",theme:"outlined"};function g(r){for(var e=1;e<arguments.length;e++){var t=arguments[e]!=null?Object(arguments[e]):{},o=Object.keys(t);typeof Object.getOwnPropertySymbols=="function"&&(o=o.concat(Object.getOwnPropertySymbols(t).filter(function(s){return Object.getOwnPropertyDescriptor(t,s).enumerable}))),o.forEach(function(s){T(r,s,t[s])})}return r}function T(r,e,t){return e in r?Object.defineProperty(r,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):r[e]=t,r}var _=function(e,t){var o=g({},e,t.attrs);return h(w,g({},o,{icon:L}),null)};_.displayName="IdcardOutlined";_.inheritAttrs=!1;const G={id:"page-user-view",class:"pf-page"},J={class:"pf-head"},Q={class:"kind-picker",role:"tablist"},W=["aria-selected","onClick"],X={class:"kind-card__icon"},Y={class:"kind-card__text"},Z=x({__name:"AddCustomer",setup(r){const e=R(),t=V(),o=z(),s=B(e.query.tab||"omde"),u=c=>!!o.hasPermission(c),d=A(()=>{const c=[];return u("persons.create.client")&&c.push({key:"omde",title:"مشتری عمده",hint:"مغازه‌دار، بنکدار و خریدار عمده",icon:q}),u("persons.create.seller")&&c.push({key:"reagent",title:"کارشناس فروش",hint:"کارشناس با کمیسیون و سقف اعتبار",icon:_}),o.isSuperAdmin&&c.push({key:"tak",title:"مشتری تک",hint:"مشتری خرده‌فروشی حضوری",icon:E}),c}),O={omde:D,reagent:U,tak:$};function C(){window.history.length>1?t.back():t.push("/customer/omde-list")}return(c,f)=>{const S=F("a-button");return i(),l("div",G,[n("header",J,[h(S,{class:"pf-head__back",shape:"circle",onClick:C},{icon:I(()=>[h(b(H))]),_:1}),f[0]||(f[0]=n("div",{class:"pf-head__text"},[n("h1",null,"افزودن شخص"),n("p",null,"نوع شخص را انتخاب و اطلاعات او را تکمیل کنید.")],-1))]),u("persons.create")&&d.value.length?(i(),l(v,{key:0},[n("div",Q,[(i(!0),l(v,null,P(d.value,a=>(i(),l("button",{key:a.key,type:"button",role:"tab",class:j(["kind-card",{"is-on":s.value===a.key}]),"aria-selected":s.value===a.key,onClick:K=>s.value=a.key},[n("span",X,[(i(),m(k(a.icon)))]),n("span",Y,[n("b",null,y(a.title),1),n("small",null,y(a.hint),1)]),s.value===a.key?(i(),m(b(M),{key:0,class:"kind-card__check"})):p("",!0)],10,W))),128))]),d.value.some(a=>a.key===s.value)?(i(),m(k(O[s.value]),{key:s.value})):p("",!0)],64)):p("",!0)])}}}),_e=N(Z,[["__scopeId","data-v-09902473"]]);export{_e as default};
File diff suppressed because one or more lines are too long
+1
View File
@@ -0,0 +1 @@
.mt-4[data-v-a752a6ce]{margin-top:1rem}.mt-5[data-v-a752a6ce]{margin-top:1.25rem}
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
+1
View File
@@ -0,0 +1 @@
import{_ as o}from"./AddWorkshop.vue_vue_type_script_setup_true_lang-CB5iJH3B.js";import"./index-B13tkMpd.js";import"./BaseFormModal.vue_vue_type_style_index_0_lang-CyAC3-m9.js";export{o as default};
@@ -0,0 +1 @@
import{d as N,x as O,y as v,a as b,w as n,h as g,k as S,m as V,z as y,r as p,o as U,p as x,c as o,f as A,H as E,G as c,l as G}from"./index-B13tkMpd.js";import{_ as H}from"./BaseFormModal.vue_vue_type_style_index_0_lang-CyAC3-m9.js";const T={class:"grid-3"},W={class:"grid-3"},F=N({__name:"AddWorkshop",props:{open:{type:Boolean},id:{}},emits:["update:open","success"],setup(f,{emit:R}){const h=f,w=R,_=h.open!==void 0,B=S(),C=G(),d=_?h.id:B.params.id,i=V(!1),e=y({workshop_name:"",workshop_phone:"",workshop_address:"",user_fname:"",user_lname:"",user_phone:""}),u=y({});async function m(){var t,a;if(Object.keys(u).forEach(l=>delete u[l]),e.workshop_name||(u.workshop_name="لطفا مقدار را وارد کنید"),(e.user_fname||e.user_lname)&&!e.user_phone&&(u.user_phone="موبایل سرپرست کارگاه الزامی است"),!Object.keys(u).length)try{i.value=!0,d?await v.put(`workshop/${d}`,e):await v.post("workshop",e),c.info("اطلاعات با موفقیت به ثبت رسید."),_?(w("success"),w("update:open",!1)):C.push("/workshop/list")}catch(l){c.error(((a=(t=l==null?void 0:l.response)==null?void 0:t.data)==null?void 0:a.message)??"خطا در ثبت اطلاعات.")}finally{i.value=!1}}return O(async()=>{if(d)try{const{data:t}=await v.get(`workshop/${d}`);Object.assign(e,{workshop_name:t.workshop_name??t.name??"",workshop_phone:t.workshop_phone??t.phone??"",workshop_address:t.workshop_address??t.address??"",user_fname:t.user_fname??"",user_lname:t.user_lname??"",user_phone:t.user_phone??""})}catch(t){console.log(t)}}),(t,a)=>{const l=p("a-input"),r=p("a-form-item"),k=p("a-textarea"),$=p("a-button"),j=p("a-card"),z=p("a-form"),M=p("a-spin");return _?(U(),b(H,{key:0,open:!!f.open,id:g(d),"add-title":"افزودن کارگاه","edit-title":"ویرایش کارگاه",loading:i.value,submitting:i.value,width:"lg","onUpdate:open":a[6]||(a[6]=s=>t.$emit("update:open",s)),onSubmit:m},{default:n(()=>[x("div",T,[o(r,{label:"نام کارگاه","validate-status":u.workshop_name?"error":"",help:u.workshop_name},{default:n(()=>[o(l,{value:e.workshop_name,"onUpdate:value":a[0]||(a[0]=s=>e.workshop_name=s)},null,8,["value"])]),_:1},8,["validate-status","help"]),o(r,{label:"تلفن کارگاه"},{default:n(()=>[o(l,{value:e.workshop_phone,"onUpdate:value":a[1]||(a[1]=s=>e.workshop_phone=s)},null,8,["value"])]),_:1}),o(r,{label:"نام سرپرست کارگاه"},{default:n(()=>[o(l,{value:e.user_fname,"onUpdate:value":a[2]||(a[2]=s=>e.user_fname=s)},null,8,["value"])]),_:1}),o(r,{label:"نام خانوادگی سرپرست کارگاه"},{default:n(()=>[o(l,{value:e.user_lname,"onUpdate:value":a[3]||(a[3]=s=>e.user_lname=s)},null,8,["value"])]),_:1}),o(r,{label:"موبایل سرپرست کارگاه","validate-status":u.user_phone?"error":"",help:u.user_phone},{default:n(()=>[o(l,{value:e.user_phone,"onUpdate:value":a[4]||(a[4]=s=>e.user_phone=s)},null,8,["value"])]),_:1},8,["validate-status","help"])]),o(r,{label:"آدرس"},{default:n(()=>[o(k,{value:e.workshop_address,"onUpdate:value":a[5]||(a[5]=s=>e.workshop_address=s),"auto-size":{minRows:2,maxRows:5}},null,8,["value"])]),_:1})]),_:1},8,["open","id","loading","submitting"])):(U(),b(M,{key:1,spinning:i.value},{default:n(()=>[o(z,{layout:"vertical",onSubmit:E(m,["prevent"])},{default:n(()=>[o(j,{title:g(d)?"ویرایش کارگاه":"افزودن کارگاه",class:"mb-base page-card"},{default:n(()=>[x("div",W,[o(r,{label:"نام کارگاه","validate-status":u.workshop_name?"error":"",help:u.workshop_name},{default:n(()=>[o(l,{value:e.workshop_name,"onUpdate:value":a[7]||(a[7]=s=>e.workshop_name=s)},null,8,["value"])]),_:1},8,["validate-status","help"]),o(r,{label:"تلفن کارگاه"},{default:n(()=>[o(l,{value:e.workshop_phone,"onUpdate:value":a[8]||(a[8]=s=>e.workshop_phone=s)},null,8,["value"])]),_:1}),o(r,{label:"نام سرپرست کارگاه"},{default:n(()=>[o(l,{value:e.user_fname,"onUpdate:value":a[9]||(a[9]=s=>e.user_fname=s)},null,8,["value"])]),_:1}),o(r,{label:"نام خانوادگی سرپرست کارگاه"},{default:n(()=>[o(l,{value:e.user_lname,"onUpdate:value":a[10]||(a[10]=s=>e.user_lname=s)},null,8,["value"])]),_:1}),o(r,{label:"موبایل سرپرست کارگاه","validate-status":u.user_phone?"error":"",help:u.user_phone},{default:n(()=>[o(l,{value:e.user_phone,"onUpdate:value":a[11]||(a[11]=s=>e.user_phone=s)},null,8,["value"])]),_:1},8,["validate-status","help"])]),o(r,{label:"آدرس"},{default:n(()=>[o(k,{value:e.workshop_address,"onUpdate:value":a[12]||(a[12]=s=>e.workshop_address=s),"auto-size":{minRows:2,maxRows:5}},null,8,["value"])]),_:1}),o($,{type:"primary",class:"form-submit",onClick:m},{default:n(()=>[...a[13]||(a[13]=[A("ثبت اطلاعات",-1)])]),_:1})]),_:1},8,["title"])]),_:1})]),_:1},8,["spinning"]))}}});export{F as _};
+1
View File
@@ -0,0 +1 @@
.stats[data-v-eef9d79c]{display:flex;flex-wrap:wrap;gap:.5rem}.mt-4[data-v-eef9d79c]{margin-top:1rem}@media (max-width: 575px){.mt-4[data-v-eef9d79c]{margin-top:12px}.stats[data-v-eef9d79c] .ant-tag{margin:0}.detail-tabs[data-v-eef9d79c] .ant-tabs-nav{margin-bottom:8px}.detail-tabs[data-v-eef9d79c] .ant-table-content{overflow-x:auto}.detail-tabs[data-v-eef9d79c] .ant-table-content>table{min-width:max-content}}
+1
View File
@@ -0,0 +1 @@
import{d as D,x as S,y as A,a as b,w as a,k as F,m as y,r as d,o as i,c as l,f as n,t as s,p as E,b as p,F as f,h as I,i as k,_ as M}from"./index-B13tkMpd.js";import{j as h}from"./filters-CHKbSAeg.js";import"./index-DXwUc_-g.js";const R={class:"stats mt-4"},T=D({__name:"AgentDetail",setup($){const j=F().params.id,m=y(!1),o=y(void 0),C=[{title:"نام",dataIndex:"name"},{title:"موبایل",dataIndex:"mobile"},{title:"شهر",dataIndex:"city"},{title:"نوع",dataIndex:"type_str"},{title:"وضعیت",dataIndex:"active"},{title:"تاریخ ثبت",dataIndex:"caj"}],w=[{title:"شماره سفارش",dataIndex:"name"},{title:"مشتری",dataIndex:"customer"},{title:"وزن",dataIndex:"w"},{title:"وضعیت",dataIndex:"status"},{title:"تاریخ",dataIndex:"caj"}];return S(async()=>{try{m.value=!0;const{data:_}=await A.get(`admin/customers-omde/reagent/${j}`);o.value=_}catch(_){console.log(_)}finally{m.value=!1}}),(_,G)=>{const c=d("a-descriptions-item"),u=d("a-tag"),z=d("a-descriptions"),B=d("a-card"),v=d("a-table"),x=d("a-tab-pane"),N=d("a-tabs"),V=d("a-spin");return i(),b(V,{spinning:m.value},{default:a(()=>[l(B,{title:"مشاهده اطلاعات کارشناس فروش",class:"page-card"},{default:a(()=>[l(z,{bordered:"",size:"small",column:{xxl:3,xl:3,lg:3,md:2,sm:2,xs:1}},{default:a(()=>[l(c,{label:"نام"},{default:a(()=>{var e;return[n(s(((e=o.value)==null?void 0:e.name)??"-"),1)]}),_:1}),l(c,{label:"موبایل"},{default:a(()=>{var e;return[n(s(((e=o.value)==null?void 0:e.mobile)??"-"),1)]}),_:1}),l(c,{label:"شعبه"},{default:a(()=>{var e,t;return[n(s(((t=(e=o.value)==null?void 0:e.branch)==null?void 0:t.name)??"-"),1)]}),_:1}),l(c,{label:"درصد کمیسیون"},{default:a(()=>{var e;return[n(s(((e=o.value)==null?void 0:e.percent)??"-"),1)]}),_:1}),l(c,{label:"وضعیت"},{default:a(()=>{var e;return[l(u,{color:((e=o.value)==null?void 0:e.active)===1?"green":"red"},{default:a(()=>{var t;return[n(s(((t=o.value)==null?void 0:t.active)===1?"فعال":"غیر فعال"),1)]}),_:1},8,["color"])]}),_:1}),l(c,{label:"میزان فروش (گرم)"},{default:a(()=>{var e;return[n(s(((e=o.value)==null?void 0:e.grams_sell)??0),1)]}),_:1})]),_:1}),E("div",R,[l(u,{color:"blue"},{default:a(()=>{var e,t;return[n("مشتریان معرفی‌شده: "+s(((t=(e=o.value)==null?void 0:e.referred_customers)==null?void 0:t.length)??0),1)]}),_:1}),l(u,{color:"green"},{default:a(()=>{var e,t;return[n("سفارش‌های ثبت‌شده: "+s(((t=(e=o.value)==null?void 0:e.orders)==null?void 0:t.length)??0),1)]}),_:1})])]),_:1}),l(N,{class:"mt-4 detail-tabs","default-active-key":"referred"},{default:a(()=>[l(x,{key:"referred",tab:"مشتریان معرفی‌شده"},{default:a(()=>{var e;return[l(v,{size:"small","data-source":(e=o.value)==null?void 0:e.referred_customers,columns:C,pagination:{pageSize:10},"row-key":"id"},{bodyCell:a(({column:t,record:r})=>{var g;return[t.dataIndex==="active"?(i(),b(u,{key:0,color:r.active===1?"green":"red"},{default:a(()=>[n(s(r.active===1?"فعال":"غیر فعال"),1)]),_:2},1032,["color"])):t.dataIndex==="city"?(i(),p(f,{key:1},[n(s(((g=r.city)==null?void 0:g.title)??"-"),1)],64)):t.dataIndex==="caj"?(i(),p(f,{key:2},[n(s(I(h)(r.caj)),1)],64)):k("",!0)]}),_:1},8,["data-source"])]}),_:1}),l(x,{key:"orders",tab:"سفارش‌های مشتریان"},{default:a(()=>{var e;return[l(v,{size:"small","data-source":(e=o.value)==null?void 0:e.orders,columns:w,pagination:{pageSize:10},"row-key":"id"},{bodyCell:a(({column:t,record:r})=>[t.dataIndex==="caj"?(i(),p(f,{key:0},[n(s(I(h)(r.caj)),1)],64)):k("",!0)]),_:1},8,["data-source"])]}),_:1})]),_:1})]),_:1},8,["spinning"])}}}),L=M(T,[["__scopeId","data-v-eef9d79c"]]);export{L as default};
@@ -0,0 +1 @@
import{c as i,I as u}from"./index-B13tkMpd.js";var l={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M464 144H160c-8.8 0-16 7.2-16 16v304c0 8.8 7.2 16 16 16h304c8.8 0 16-7.2 16-16V160c0-8.8-7.2-16-16-16zm-52 268H212V212h200v200zm452-268H560c-8.8 0-16 7.2-16 16v304c0 8.8 7.2 16 16 16h304c8.8 0 16-7.2 16-16V160c0-8.8-7.2-16-16-16zm-52 268H612V212h200v200zM464 544H160c-8.8 0-16 7.2-16 16v304c0 8.8 7.2 16 16 16h304c8.8 0 16-7.2 16-16V560c0-8.8-7.2-16-16-16zm-52 268H212V612h200v200zm452-268H560c-8.8 0-16 7.2-16 16v304c0 8.8 7.2 16 16 16h304c8.8 0 16-7.2 16-16V560c0-8.8-7.2-16-16-16zm-52 268H612V612h200v200z"}}]},name:"appstore",theme:"outlined"};function a(r){for(var t=1;t<arguments.length;t++){var e=arguments[t]!=null?Object(arguments[t]):{},n=Object.keys(e);typeof Object.getOwnPropertySymbols=="function"&&(n=n.concat(Object.getOwnPropertySymbols(e).filter(function(c){return Object.getOwnPropertyDescriptor(e,c).enumerable}))),n.forEach(function(c){p(r,c,e[c])})}return r}function p(r,t,e){return t in r?Object.defineProperty(r,t,{value:e,enumerable:!0,configurable:!0,writable:!0}):r[t]=e,r}var o=function(t,e){var n=a({},t,e.attrs);return i(u,a({},n,{icon:l}),null)};o.displayName="AppstoreOutlined";o.inheritAttrs=!1;export{o as A};
+1
View File
@@ -0,0 +1 @@
import{b as m,O as i,a as e}from"./OmdeCustomerList-CM9_pbJI.js";import{d as p,a,h as t,o as s}from"./index-B13tkMpd.js";import"./index-DXwUc_-g.js";import"./model-BNUuQ7S0.js";import"./filters-CHKbSAeg.js";import"./SettingOutlined-C2GWCiUw.js";import"./ListPageHeader.vue_vue_type_script_setup_true_lang-Dv2SKF1q.js";import"./AccountingSyncButton.vue_vue_type_script_setup_true_lang-BmGGSgHW.js";import"./bulkCustomer.vue_vue_type_script_setup_true_lang-DCiRvD_P.js";import"./BaseFormModal.vue_vue_type_style_index_0_lang-CyAC3-m9.js";import"./ImageUploadInput.vue_vue_type_script_setup_true_lang-C-8ZQMi-.js";import"./CityTreeSelect.vue_vue_type_script_setup_true_lang-cGpnZ8Gn.js";import"./DateInput-CVKHy-b9.js";import"./UserOutlined-tnfFbi-d.js";import"./ShopOutlined-BULNMNmg.js";import"./EnvironmentOutlined-BII2axx6.js";import"./PercentageOutlined-CpguakOP.js";import"./SafetyCertificateOutlined-B7xsdKuU.js";import"./UnorderedListOutlined-DVq783q4.js";const j=p({__name:"BankerList",setup(n){const o=i.banker.title,r=m("banker");return(l,c)=>(s(),a(e,{title:t(o),model:t(r)},null,8,["title","model"]))}});export{j as default};
@@ -0,0 +1 @@
@media (max-width: 575px){.base-form-modal .ant-modal{width:100vw!important;max-width:100vw;top:0;margin:0;padding-bottom:0}.base-form-modal .ant-modal-content{display:flex;flex-direction:column;min-height:calc(var(--vh, 1vh) * 100);border-radius:0;padding:14px 16px 0}.base-form-modal .ant-modal-header{margin-bottom:12px}.base-form-modal .ant-modal-body{flex:1}.base-form-modal .ant-modal-footer{position:sticky;bottom:0;display:flex;gap:8px;margin:0 -16px;padding:10px 16px;background:#fff;border-top:1px solid #f0f0f0}.base-form-modal .ant-modal-footer>.ant-btn{flex:1;margin:0!important}}
@@ -0,0 +1 @@
import{d as r,a as g,w as a,r as o,o as k,c as i,a7 as w}from"./index-B13tkMpd.js";const b=r({__name:"BaseFormModal",props:{open:{type:Boolean},id:{default:void 0},addTitle:{},editTitle:{},loading:{type:Boolean,default:!1},submitting:{type:Boolean,default:!1},width:{default:"md"},okText:{default:"ثبت اطلاعات"}},emits:["update:open","submit","cancel"],setup(e,{emit:d}){const n=d,s={sm:520,md:720,lg:900,xl:1140};function m(t){n("update:open",t)}function c(){n("update:open",!1),n("cancel")}return(t,l)=>{const f=o("a-form"),u=o("a-spin"),p=o("a-modal");return k(),g(p,{open:e.open,title:e.id?e.editTitle:e.addTitle,width:s[e.width],"confirm-loading":e.submitting,"ok-text":e.okText,"cancel-text":"انصراف","mask-closable":!1,"wrap-class-name":"base-form-modal","onUpdate:open":m,onOk:l[0]||(l[0]=x=>t.$emit("submit")),onCancel:c},{default:a(()=>[i(u,{spinning:e.loading},{default:a(()=>[i(f,{layout:"vertical"},{default:a(()=>[w(t.$slots,"default")]),_:3})]),_:3},8,["spinning"])]),_:3},8,["open","title","width","confirm-loading","ok-text"])}}});export{b as _};
@@ -0,0 +1 @@
import{c as i,I as u}from"./index-B13tkMpd.js";var o={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M864 248H728l-32.4-90.8a32.07 32.07 0 00-30.2-21.2H358.6c-13.5 0-25.6 8.5-30.1 21.2L296 248H160c-44.2 0-80 35.8-80 80v456c0 44.2 35.8 80 80 80h704c44.2 0 80-35.8 80-80V328c0-44.2-35.8-80-80-80zm8 536c0 4.4-3.6 8-8 8H160c-4.4 0-8-3.6-8-8V328c0-4.4 3.6-8 8-8h186.7l17.1-47.8 22.9-64.2h250.5l22.9 64.2 17.1 47.8H864c4.4 0 8 3.6 8 8v456zM512 384c-88.4 0-160 71.6-160 160s71.6 160 160 160 160-71.6 160-160-71.6-160-160-160zm0 256c-53 0-96-43-96-96s43-96 96-96 96 43 96 96-43 96-96 96z"}}]},name:"camera",theme:"outlined"};function c(r){for(var e=1;e<arguments.length;e++){var t=arguments[e]!=null?Object(arguments[e]):{},a=Object.keys(t);typeof Object.getOwnPropertySymbols=="function"&&(a=a.concat(Object.getOwnPropertySymbols(t).filter(function(n){return Object.getOwnPropertyDescriptor(t,n).enumerable}))),a.forEach(function(n){f(r,n,t[n])})}return r}function f(r,e,t){return e in r?Object.defineProperty(r,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):r[e]=t,r}var l=function(e,t){var a=c({},e,t.attrs);return i(u,c({},a,{icon:o}),null)};l.displayName="CameraOutlined";l.inheritAttrs=!1;export{l as C};
@@ -0,0 +1 @@
import{d as P,x as S,y as u,b as v,c as n,w as l,m as _,r as s,z as T,o as d,p as $,F as w,e as C,f as g,G as z,M as k,a as x,t as B}from"./index-B13tkMpd.js";const D={id:"page-user-list"},E={class:"grid-3"},q=P({__name:"ChangePercent",setup(G){const y=_([]),b=_([]),p=_("-"),f=_(!1),a=T({category_id:void 0,brand_id:void 0,percent:void 0});function h(t,e){var r,c;return String(((c=(r=e==null?void 0:e.children)==null?void 0:r[0])==null?void 0:c.children)??"").toLowerCase().indexOf(t.toLowerCase())>=0}async function m(){try{const{data:t}=await u.post("change/percent/count",{category_id:a.category_id,brand_id:a.brand_id});p.value=t.count}catch(t){console.log("e ==> ",t)}}async function L(){if(a.percent===void 0||a.percent===null){z.error("لطفا اجرت درصدی را وارد کنید");return}try{f.value=!0;const{data:t}=await u.post("change/all",{percent:a.percent,category_id:a.category_id,brand_id:a.brand_id});k.success({title:"تغییرات با موفقیت اعمال شد",okText:"بستن"}),p.value=t.updated}catch(t){k.success({title:"خطا در اعمال تغییرات"}),console.log(t)}finally{f.value=!1}}return S(async()=>{try{const[t,e]=await Promise.all([u.get("brand"),u.post("category")]);y.value=t.data,b.value=(e.data.rows??e.data).map(r=>({id:r.id,title:r.type_str?`${r.title} (${r.type_str}) `:r.title}))}catch(t){console.log(t)}m()}),(t,e)=>{const r=s("a-select-option"),c=s("a-select"),i=s("a-form-item"),M=s("a-input"),N=s("a-input-number"),U=s("a-button"),V=s("a-popconfirm"),F=s("a-form"),O=s("a-card");return d(),v("div",D,[n(O,{title:"تغییر درصد محصولات",class:"page-card"},{default:l(()=>[n(F,{layout:"vertical"},{default:l(()=>[$("div",E,[n(i,{label:"دسته بندی"},{default:l(()=>[n(c,{value:a.category_id,"onUpdate:value":e[0]||(e[0]=o=>a.category_id=o),"allow-clear":"","show-search":"",placeholder:"انتخاب کنید","filter-option":h,onChange:m},{default:l(()=>[(d(!0),v(w,null,C(b.value,o=>(d(),x(r,{key:o.id,value:o.id},{default:l(()=>[g(B(o.title),1)]),_:2},1032,["value"]))),128))]),_:1},8,["value"])]),_:1}),n(i,{label:"برند"},{default:l(()=>[n(c,{value:a.brand_id,"onUpdate:value":e[1]||(e[1]=o=>a.brand_id=o),"allow-clear":"","show-search":"",placeholder:"انتخاب کنید","filter-option":h,onChange:m},{default:l(()=>[(d(!0),v(w,null,C(y.value,o=>(d(),x(r,{key:o.id,value:o.id},{default:l(()=>[g(B(o.title),1)]),_:2},1032,["value"]))),128))]),_:1},8,["value"])]),_:1}),n(i,{label:"تعداد یافت شده"},{default:l(()=>[n(M,{value:p.value,disabled:""},null,8,["value"])]),_:1}),n(i,{label:"اجرت درصدی"},{default:l(()=>[n(N,{value:a.percent,"onUpdate:value":e[2]||(e[2]=o=>a.percent=o),class:"w-full",step:.1},null,8,["value"])]),_:1})]),n(V,{title:"آیا از اعمال تغییرات مطمئن هستید؟","ok-text":"بله","cancel-text":"خیر",onConfirm:L},{default:l(()=>[n(U,{type:"primary",class:"form-submit",loading:f.value},{default:l(()=>[...e[3]||(e[3]=[g("اعمال تغییرات",-1)])]),_:1},8,["loading"])]),_:1})]),_:1})]),_:1})])}}});export{q as default};
@@ -0,0 +1 @@
import{d as m,o as v,a as g,s as w,r as k}from"./index-B13tkMpd.js";const _=m({__name:"CityTreeSelect",props:{value:{},cities:{},parentPicker:{type:Boolean},excludeId:{},placeholder:{}},emits:["update:value","change"],setup(i,{emit:u}){const n=i,d=u,h=w(()=>{const l=new Set(n.cities.map(e=>e.id)),o=new Map;for(const e of n.cities){const a=e.parent&&l.has(e.parent)&&e.parent!==e.id?e.parent:null;o.has(a)||o.set(a,[]),o.get(a).push(e)}const r=new Set,p=(e,a)=>(o.get(e)??[]).filter(t=>!r.has(t.id)&&!(n.parentPicker&&t.id===n.excludeId)).map(t=>{r.add(t.id);const s=p(t.id,a+1),c={value:t.id,key:t.id,title:t.title};return s.length&&(c.children=s),!n.parentPicker&&a===0&&s.length&&(c.disabled=!0),c});return p(null,0)});function f(l){d("update:value",l??void 0),d("change",l??void 0)}return(l,o)=>{const r=k("a-tree-select");return v(),g(r,{value:i.value??void 0,"tree-data":h.value,"show-search":"","allow-clear":"","tree-default-expand-all":"","tree-node-filter-prop":"title","dropdown-style":{maxHeight:"400px",overflow:"auto"},placeholder:i.placeholder??"شهر را انتخاب کنید",class:"w-full","onUpdate:value":f},null,8,["value","tree-data","placeholder"])}}});export{_};
File diff suppressed because one or more lines are too long
+1
View File
@@ -0,0 +1 @@
.mr-3[data-v-26513e49]{margin-left:.75rem}.comments-list ul[data-v-26513e49]{list-style:none;padding-right:0}.comment-item[data-v-26513e49]{display:flex;gap:1rem;flex-wrap:wrap;margin-bottom:1rem}.comment-item .img[data-v-26513e49]{width:65px;height:65px;display:flex;align-items:center;justify-content:center}.comment-body[data-v-26513e49]{flex:1;min-width:240px}.comment-body .time[data-v-26513e49]{font-size:12px;color:#888}.border[data-v-26513e49]{border:1px solid grey;border-radius:50%}@media (max-width: 575px){.comment-item[data-v-26513e49]{gap:10px;flex-wrap:nowrap;margin-bottom:12px}.comment-item .img[data-v-26513e49]{width:40px;height:40px;flex-shrink:0}.comment-body[data-v-26513e49]{min-width:0}}
File diff suppressed because one or more lines are too long
+1
View File
@@ -0,0 +1 @@
.row[data-v-60098c92]{display:flex;gap:.5rem;align-items:center;flex-wrap:wrap}.tags[data-v-60098c92]{display:flex;gap:.5rem;flex-wrap:wrap}.slider-toolbar[data-v-60098c92]{display:flex;justify-content:space-between;align-items:center;gap:.5rem;flex-wrap:wrap;margin-bottom:1rem}.slider-count[data-v-60098c92]{color:#00000073}.slider-grid[data-v-60098c92]{display:grid;grid-template-columns:repeat(auto-fill,minmax(min(100%,220px),1fr));gap:16px}.slide-card[data-v-60098c92]{display:flex;flex-direction:column;gap:10px;min-width:0;padding:12px;border:1px solid #f0f0f0;border-radius:8px;background:#fff}.slide-card__head[data-v-60098c92]{display:flex;justify-content:space-between;align-items:center}.slide-card__title[data-v-60098c92]{font-weight:600}.slide-card__media[data-v-60098c92]{height:140px}.slide-card__media[data-v-60098c92] .image-upload,.slide-card__media[data-v-60098c92] .ant-upload-wrapper,.slide-card__media[data-v-60098c92] .ant-upload-list,.slide-card__media[data-v-60098c92] .ant-upload-list-item-container,.slide-card__media[data-v-60098c92] .ant-upload.ant-upload-select{width:100%!important;height:100%!important;margin:0!important}.slide-card__media[data-v-60098c92] .ant-upload-wrapper{display:block}.slide-card__media[data-v-60098c92] .ant-upload-list-item-thumbnail img{object-fit:cover}.mt-4[data-v-60098c92]{margin-top:1rem}@media (max-width: 575px){.row>.ant-input[data-v-60098c92]{flex:1 1 140px;max-width:none!important}.mt-4[data-v-60098c92]{margin-top:12px}}
@@ -0,0 +1 @@
import{c as u,I as l}from"./index-B13tkMpd.js";var d={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M928 160H96c-17.7 0-32 14.3-32 32v640c0 17.7 14.3 32 32 32h832c17.7 0 32-14.3 32-32V192c0-17.7-14.3-32-32-32zm-792 72h752v120H136V232zm752 560H136V440h752v352zm-237-64h165c4.4 0 8-3.6 8-8v-72c0-4.4-3.6-8-8-8H651c-4.4 0-8 3.6-8 8v72c0 4.4 3.6 8 8 8z"}}]},name:"credit-card",theme:"outlined"};function c(r){for(var t=1;t<arguments.length;t++){var e=arguments[t]!=null?Object(arguments[t]):{},n=Object.keys(e);typeof Object.getOwnPropertySymbols=="function"&&(n=n.concat(Object.getOwnPropertySymbols(e).filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable}))),n.forEach(function(a){o(r,a,e[a])})}return r}function o(r,t,e){return t in r?Object.defineProperty(r,t,{value:e,enumerable:!0,configurable:!0,writable:!0}):r[t]=e,r}var i=function(t,e){var n=c({},t,e.attrs);return u(l,c({},n,{icon:d}),null)};i.displayName="CreditCardOutlined";i.inheritAttrs=!1;export{i as C};
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
+1
View File
@@ -0,0 +1 @@
.hint[data-v-3863c3bc]{color:#ea5455;font-size:11px}
+1
View File
@@ -0,0 +1 @@
import{m}from"./index-DXwUc_-g.js";import{d as _,n as V,o as r,a as Y,w as h,c as D,b,t as j,i as M,m as i,s as x,r as d,_ as y}from"./index-B13tkMpd.js";const k={key:0,class:"hint"},C=_({__name:"DateInput",props:{label:{},modelValue:{},placeholder:{default:"مثال: ۱۴۰۳/۰۵/۱۲"}},emits:["update:modelValue"],setup(o,{emit:p}){const n=o,c=p,t=i(void 0),a=i(""),v=x(()=>{if(t.value!==void 0)return t.value;if(!n.modelValue)return"";const e=m(n.modelValue);return e.isValid()?e.format("jYYYY/jMM/jDD"):""});V(()=>n.modelValue,()=>{t.value=void 0});function f(e){if(t.value=e,!e){a.value="",c("update:modelValue",void 0);return}const u=e.replace(/[۰-۹]/g,s=>String("۰۱۲۳۴۵۶۷۸۹".indexOf(s))),l=m(u,"jYYYY/jMM/jDD");l.isValid()?(a.value="",c("update:modelValue",l.format("YYYY-MM-DD"))):a.value="تاریخ معتبر نیست"}return(e,u)=>{const l=d("a-input"),s=d("a-form-item");return r(),Y(s,{label:o.label},{default:h(()=>[D(l,{value:v.value,placeholder:o.placeholder,"allow-clear":"","onUpdate:value":f},null,8,["value","placeholder"]),a.value?(r(),b("small",k,j(a.value),1)):M("",!0)]),_:1},8,["label"])}}}),I=y(C,[["__scopeId","data-v-3863c3bc"]]);export{I as D};
+1
View File
@@ -0,0 +1 @@
import{_ as o}from"./Add.vue_vue_type_script_setup_true_lang-CcEgUcgF.js";import{d as t,a as e,o as r}from"./index-B13tkMpd.js";import"./BaseFormModal.vue_vue_type_style_index_0_lang-CyAC3-m9.js";import"./ImageUploadInput.vue_vue_type_script_setup_true_lang-C-8ZQMi-.js";const i=t({__name:"Edit",setup(a){return(_,m)=>(r(),e(o))}});export{i as default};
+1
View File
@@ -0,0 +1 @@
import{_ as e}from"./AddBranches.vue_vue_type_script_setup_true_lang-O5kvMvjg.js";import{d as o,a,o as r}from"./index-B13tkMpd.js";import"./BaseFormModal.vue_vue_type_style_index_0_lang-CyAC3-m9.js";const p=o({__name:"EditBranches",setup(t){return(n,s)=>(r(),a(e))}});export{p as default};
@@ -0,0 +1 @@
import{_ as o}from"./bulkCustomer.vue_vue_type_script_setup_true_lang-DCiRvD_P.js";import{d as r,a as t,o as m}from"./index-B13tkMpd.js";import"./BaseFormModal.vue_vue_type_style_index_0_lang-CyAC3-m9.js";import"./ImageUploadInput.vue_vue_type_script_setup_true_lang-C-8ZQMi-.js";import"./CityTreeSelect.vue_vue_type_script_setup_true_lang-cGpnZ8Gn.js";import"./DateInput-CVKHy-b9.js";import"./index-DXwUc_-g.js";import"./UserOutlined-tnfFbi-d.js";import"./ShopOutlined-BULNMNmg.js";import"./EnvironmentOutlined-BII2axx6.js";import"./PercentageOutlined-CpguakOP.js";import"./SafetyCertificateOutlined-B7xsdKuU.js";const C=r({__name:"EditBulkCustomer",setup(p){return(i,a)=>(m(),t(o,{class:"page-card"}))}});export{C as default};
+1
View File
@@ -0,0 +1 @@
import o from"./AddInvoice-BhHiwzHB.js";import{d as t,a as r,o as e}from"./index-B13tkMpd.js";import"./BaseFormModal.vue_vue_type_style_index_0_lang-CyAC3-m9.js";import"./model-BNUuQ7S0.js";import"./filters-CHKbSAeg.js";import"./index-DXwUc_-g.js";import"./SettingOutlined-C2GWCiUw.js";const u=t({__name:"EditInvoice",setup(p){return(i,m)=>(e(),r(o))}});export{u as default};
+1
View File
@@ -0,0 +1 @@
import e from"./AddProduct-CmZKP00e.js";import{d as o,b as t,c as r,o as c}from"./index-B13tkMpd.js";import"./ImageUploadInput.vue_vue_type_script_setup_true_lang-C-8ZQMi-.js";import"./AppstoreOutlined-Ca4USN1F.js";const _=o({__name:"EditProduct",setup(a){return(n,d)=>(c(),t("div",null,[r(e)]))}});export{_ as default};
+1
View File
@@ -0,0 +1 @@
import{R as t}from"./ReagentCustomer-XSZR4Hgo.js";import{d as o,a as r,o as e}from"./index-B13tkMpd.js";import"./CityTreeSelect.vue_vue_type_script_setup_true_lang-cGpnZ8Gn.js";import"./ImageUploadInput.vue_vue_type_script_setup_true_lang-C-8ZQMi-.js";import"./UserOutlined-tnfFbi-d.js";import"./ShopOutlined-BULNMNmg.js";import"./EnvironmentOutlined-BII2axx6.js";import"./CameraOutlined-CZeD3bSm.js";import"./PercentageOutlined-CpguakOP.js";const g=o({__name:"EditReagent",setup(a){return(p,m)=>(e(),r(t,{class:"page-card"}))}});export{g as default};
@@ -0,0 +1 @@
import{S as o}from"./singleCustomer-DNW92cmo.js";import{d as r,a as e,o as t}from"./index-B13tkMpd.js";import"./CityTreeSelect.vue_vue_type_script_setup_true_lang-cGpnZ8Gn.js";import"./DateInput-CVKHy-b9.js";import"./index-DXwUc_-g.js";import"./UserOutlined-tnfFbi-d.js";const u=r({__name:"EditSingleCustomer",setup(a){return(m,p)=>(t(),e(o,{class:"page-card"}))}});export{u as default};
+1
View File
@@ -0,0 +1 @@
import{_ as o}from"./AddWorkshop.vue_vue_type_script_setup_true_lang-CB5iJH3B.js";import{d as e,a as r,o as t}from"./index-B13tkMpd.js";import"./BaseFormModal.vue_vue_type_style_index_0_lang-CyAC3-m9.js";const m=e({__name:"EditWorkshop",setup(a){return(s,_)=>(t(),r(o))}});export{m as default};
@@ -0,0 +1 @@
import{c as o,I as u}from"./index-B13tkMpd.js";var l={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M854.6 289.1a362.49 362.49 0 00-79.9-115.7 370.83 370.83 0 00-118.2-77.8C610.7 76.6 562.1 67 512 67c-50.1 0-98.7 9.6-144.5 28.5-44.3 18.3-84 44.5-118.2 77.8A363.6 363.6 0 00169.4 289c-19.5 45-29.4 92.8-29.4 142 0 70.6 16.9 140.9 50.1 208.7 26.7 54.5 64 107.6 111 158.1 80.3 86.2 164.5 138.9 188.4 153a43.9 43.9 0 0022.4 6.1c7.8 0 15.5-2 22.4-6.1 23.9-14.1 108.1-66.8 188.4-153 47-50.4 84.3-103.6 111-158.1C867.1 572 884 501.8 884 431.1c0-49.2-9.9-97-29.4-142zM512 880.2c-65.9-41.9-300-207.8-300-449.1 0-77.9 31.1-151.1 87.6-206.3C356.3 169.5 431.7 139 512 139s155.7 30.5 212.4 85.9C780.9 280 812 353.2 812 431.1c0 241.3-234.1 407.2-300 449.1zm0-617.2c-97.2 0-176 78.8-176 176s78.8 176 176 176 176-78.8 176-176-78.8-176-176-176zm79.2 255.2A111.6 111.6 0 01512 551c-29.9 0-58-11.7-79.2-32.8A111.6 111.6 0 01400 439c0-29.9 11.7-58 32.8-79.2C454 338.6 482.1 327 512 327c29.9 0 58 11.6 79.2 32.8C612.4 381 624 409.1 624 439c0 29.9-11.6 58-32.8 79.2z"}}]},name:"environment",theme:"outlined"};function c(n){for(var e=1;e<arguments.length;e++){var t=arguments[e]!=null?Object(arguments[e]):{},r=Object.keys(t);typeof Object.getOwnPropertySymbols=="function"&&(r=r.concat(Object.getOwnPropertySymbols(t).filter(function(a){return Object.getOwnPropertyDescriptor(t,a).enumerable}))),r.forEach(function(a){f(n,a,t[a])})}return n}function f(n,e,t){return e in n?Object.defineProperty(n,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):n[e]=t,n}var i=function(e,t){var r=c({},e,t.attrs);return o(u,c({},r,{icon:l}),null)};i.displayName="EnvironmentOutlined";i.inheritAttrs=!1;export{i as E};
+1
View File
@@ -0,0 +1 @@
import{_,b as c,c as e,w as o,f as l,r as s,o as u}from"./index-B13tkMpd.js";const p={},d={class:"full-page-msg"};function i(r,t){const a=s("a-button"),n=s("a-result");return u(),c("div",d,[e(n,{status:"404",title:"صفحه مورد نظر یافت نشد","sub-title":"آدرسی که وارد کرده‌اید وجود ندارد."},{extra:o(()=>[e(a,{type:"primary",onClick:t[0]||(t[0]=f=>r.$router.push("/"))},{default:o(()=>[...t[1]||(t[1]=[l("بازگشت به خانه",-1)])]),_:1})]),_:1})])}const x=_(p,[["render",i],["__scopeId","data-v-82a95474"]]);export{x as default};
+1
View File
@@ -0,0 +1 @@
.full-page-msg[data-v-82a95474]{min-height:100vh;display:flex;align-items:center;justify-content:center}
+1
View File
@@ -0,0 +1 @@
import{_,b as c,c as e,w as o,f as l,r as s,o as u}from"./index-B13tkMpd.js";const p={},d={class:"full-page-msg"};function i(r,t){const a=s("a-button"),n=s("a-result");return u(),c("div",d,[e(n,{status:"500",title:"خطای سرور","sub-title":"مشکلی در سرور رخ داده است. لطفاً بعداً تلاش کنید."},{extra:o(()=>[e(a,{type:"primary",onClick:t[0]||(t[0]=f=>r.$router.push("/"))},{default:o(()=>[...t[1]||(t[1]=[l("بازگشت به خانه",-1)])]),_:1})]),_:1})])}const x=_(p,[["render",i],["__scopeId","data-v-1080291a"]]);export{x as default};
+1
View File
@@ -0,0 +1 @@
.full-page-msg[data-v-1080291a]{min-height:100vh;display:flex;align-items:center;justify-content:center}
@@ -0,0 +1 @@
import{d as E,a as i,w as l,r as x,o as s,c as d,aj as P,p as w,h as u,E as y,W as B,$ as L,a7 as S,m as v,y as A,G as $,l as I}from"./index-B13tkMpd.js";import{X as N}from"./model-BNUuQ7S0.js";import{_ as V}from"./ListPageHeader.vue_vue_type_script_setup_true_lang-Dv2SKF1q.js";const X={class:"flex gap-2"},T=E({__name:"FacilityList",props:{title:{},model:{},editPath:{},activePath:{},addRid:{},addLabel:{}},setup(a){const k=a,h=I(),m=v(null),c=v(!1),f=v(void 0);function _(){f.value=void 0,c.value=!0}function b(e){f.value=e,c.value=!0}function g(e){c.value=e}function O(){var e;(e=m.value)==null||e.fetch()}function R(e){h.push(`${k.editPath}/${e}`)}async function C(e){var o,n,r;try{await A.get(`${k.activePath}/${e}`),$.success("تغییرات ثبت شد"),(o=m.value)==null||o.fetch()}catch(t){$.error(((r=(n=t==null?void 0:t.response)==null?void 0:n.data)==null?void 0:r.message)??"خطا در تغییر وضعیت")}}return(e,o)=>{const n=x("a-tooltip"),r=x("a-card");return s(),i(r,{title:a.title,class:"page-card"},{default:l(()=>[d(N,{ref_key:"tbl",ref:m,model:a.model,"mobile-cards":""},P({actions:l(({record:t})=>[w("div",X,[a.addRid?(s(),i(n,{key:0,title:"ویرایش"},{default:l(()=>[d(u(y),{class:"cursor-pointer mx-1 text-primary",onClick:p=>b(t.id)},null,8,["onClick"])]),_:2},1024)):(s(),i(n,{key:1,title:"ویرایش"},{default:l(()=>[d(u(y),{class:"cursor-pointer mx-1 text-primary",onClick:p=>R(t.id)},null,8,["onClick"])]),_:2},1024)),d(n,{title:"وضعیت"},{default:l(()=>[t.is_active?(s(),i(u(B),{key:0,class:"cursor-pointer mx-1 text-success",onClick:p=>C(t.id)},null,8,["onClick"])):(s(),i(u(L),{key:1,class:"cursor-pointer mx-1 text-danger",onClick:p=>C(t.id)},null,8,["onClick"]))]),_:2},1024)])]),_:2},[a.addRid?{name:"add",fn:l(()=>[d(V,{rid:a.addRid,"add-label":a.addLabel,onAdd:o[0]||(o[0]=t=>_())},null,8,["rid","add-label"])]),key:"0"}:void 0]),1032,["model"]),S(e.$slots,"form",{open:c.value,editingId:f.value,onUpdateOpen:g,onSuccess:O})]),_:3},8,["title"])}}});export{T as _};
+1
View File
@@ -0,0 +1 @@
import{_ as o,b as t,c,r,o as s}from"./index-B13tkMpd.js";const n={},a={class:"layout--full-page"};function _(l,u){const e=r("router-view");return s(),t("div",a,[c(e)])}const i=o(n,[["render",_]]);export{i as default};
Binary file not shown.
Binary file not shown.
Binary file not shown.
+1
View File
@@ -0,0 +1 @@
import{d as r,x as c,y as n,b as i,l as m,o as d}from"./index-B13tkMpd.js";import{u as _}from"./auth-Bz2RUUne.js";const l={style:{"min-height":"100vh",display:"grid","place-items":"center"}},h=r({__name:"IamCallback",setup(p){const t=m(),o=_();return c(async()=>{const e=new URLSearchParams(window.location.search);if(sessionStorage.removeItem("gb_admin_iam_sso_checked"),e.get("error")||!e.get("code")||!e.get("state")){sessionStorage.setItem("gb_admin_iam_sso_skip","1"),await t.replace("/auth/login");return}try{const{data:s}=await n.post("admin/auth/sso/callback",{code:e.get("code"),state:e.get("state")}),a={...s};delete a.roles,delete a.ut,o.inject(a),await t.replace("/dashboard/ecommerce")}catch{sessionStorage.setItem("gb_admin_iam_sso_skip","1"),await t.replace("/auth/login")}}),(e,s)=>(d(),i("div",l,"در حال ورود..."))}});export{h as default};
@@ -0,0 +1 @@
import{d as B,n as P,o as u,b as r,c as m,w as h,a as N,h as b,P as D,p as y,t as I,i as R,m as i,s as S,y as U,G as q,r as f}from"./index-B13tkMpd.js";const z={class:"image-upload"},E={key:0},F={key:1},G={style:{"margin-top":"8px"}},L=["src"],$=B({__name:"ImageUploadInput",props:{modelValue:{default:null},purpose:{default:void 0},placeholder:{default:"بارگذاری"}},emits:["update:modelValue","ok"],setup(g,{emit:w}){const s=g,p=w,c=i(!1),d=i(!1),v=i(""),o=i([]);P(()=>s.modelValue,e=>{var a;e?((a=o.value[0])==null?void 0:a.url)!==e&&(o.value=[{uid:e,name:e.split("/").pop()??"file",status:"done",url:e}]):o.value=[]},{immediate:!0});const V=S(()=>s.placeholder);async function k({file:e}){var l,n;const a=new FormData;a.append("file",e),s.purpose&&a.append("purpose",s.purpose),c.value=!0;try{const{data:t}=await U.post("file/create",a);p("update:modelValue",t.url),p("ok",t)}catch(t){const _=((n=(l=t==null?void 0:t.response)==null?void 0:l.data)==null?void 0:n.message)??"بارگذاری فایل ناموفق بود";q.error(_)}finally{c.value=!1}}function x(){return p("update:modelValue",null),!0}function C(e){v.value=e.url,d.value=!0}return(e,a)=>{const l=f("a-spin"),n=f("a-upload"),t=f("a-modal");return u(),r("div",z,[m(n,{"file-list":o.value,"list-type":"picture-card","max-count":1,accept:"image/*","custom-request":k,onRemove:x,onPreview:C},{default:h(()=>[o.value.length===0?(u(),r("div",E,[c.value?(u(),N(l,{key:0,size:"small"})):(u(),r("div",F,[m(b(D)),y("div",G,I(V.value),1)]))])):R("",!0)]),_:1},8,["file-list"]),m(t,{open:d.value,footer:null,onCancel:a[0]||(a[0]=_=>d.value=!1)},{default:h(()=>[y("img",{src:v.value,style:{width:"100%"},alt:""},null,8,L)]),_:1},8,["open"])])}}});export{$ as _};
+1
View File
@@ -0,0 +1 @@
import{a as $,b as s,X as B}from"./model-BNUuQ7S0.js";import{_ as E}from"./ListPageHeader.vue_vue_type_script_setup_true_lang-Dv2SKF1q.js";import{_ as D}from"./Add.vue_vue_type_script_setup_true_lang-CcEgUcgF.js";import{d as X,u as M,b as O,c as i,w as o,r as u,o as c,h as m,a as f,E as T,i as b,D as V,p as w,m as _}from"./index-B13tkMpd.js";import{u as A}from"./useDeleteHandler-Do5E4sjj.js";import"./filters-CHKbSAeg.js";import"./index-DXwUc_-g.js";import"./SettingOutlined-C2GWCiUw.js";import"./BaseFormModal.vue_vue_type_style_index_0_lang-CyAC3-m9.js";import"./ImageUploadInput.vue_vue_type_script_setup_true_lang-C-8ZQMi-.js";function I(){const t=new $("admin/categories/list","لیست دسته بندی");return t.add(new s("id","شماره").filterNumber()),t.add(new s("image","تصویر").noSort().renderSlot("image")),t.add(new s("type_str","نوع نمایش")),t.add(new s("title","عنوان دسته").filterNumber()),t.add(new s("parent.title","پدر دسته").filterNumber()),t.add(new s("opt","عملیات").noSort().renderSlot("opt")),t}const P={id:"page-user-list"},U=["src"],j="/img/no-items.png",W=X({__name:"List",setup(t){const k=M(),g=n=>!!k.hasPermission(n),y=I(),p=_(null),r=_(!1),l=_(void 0),{remove:x}=A({onSuccess:()=>{var n;return(n=p.value)==null?void 0:n.fetch()},successMessage:"دسته حذف شد",successType:"info",fallbackErrorMessage:"خطا در حذف دسته"});function C(){l.value=void 0,r.value=!0}function S(n){l.value=n,r.value=!0}return(n,a)=>{const v=u("a-tooltip"),h=u("a-popconfirm"),N=u("a-card");return c(),O("div",P,[i(N,{title:"لیست دسته بندی ها",class:"page-card"},{default:o(()=>[i(B,{ref_key:"tbl",ref:p,model:m(y),"mobile-cards":""},{add:o(()=>[i(E,{rid:"collection.create","add-label":"افزودن دسته",onAdd:C})]),image:o(({text:e})=>[w("img",{width:"90px",height:"90px",style:{"object-fit":"scale-down"},src:e&&e.image?e.image:j},null,8,U)]),opt:o(({record:e})=>[g("collection.list.edit")?(c(),f(v,{key:0,title:"ویرایش"},{default:o(()=>[i(m(T),{class:"cursor-pointer mx-1 text-primary",onClick:d=>S(e.id)},null,8,["onClick"])]),_:2},1024)):b("",!0),g("collection.list.remove")?(c(),f(v,{key:1,title:"حذف"},{default:o(()=>[i(h,{placement:"top","ok-text":"بله","cancel-text":"خیر",onConfirm:d=>m(x)(`category/${e.id}`)},{title:o(()=>[...a[2]||(a[2]=[w("p",null,"آیا مطمئن به حذف دسته مورد نظر هستید ؟",-1)])]),default:o(()=>[i(m(V),{class:"cursor-pointer mx-1 text-danger"})]),_:1},8,["onConfirm"])]),_:2},1024)):b("",!0)]),_:1},8,["model"]),(c(),f(D,{key:l.value??"new",open:r.value,id:l.value,"onUpdate:open":a[0]||(a[0]=e=>r.value=e),onSuccess:a[1]||(a[1]=e=>{var d;return(d=p.value)==null?void 0:d.fetch()})},null,8,["open","id"]))]),_:1})])}}});export{W as default};
+1
View File
@@ -0,0 +1 @@
.flex-col[data-v-d7104f94]{flex-direction:column}.flex-1[data-v-d7104f94]{flex:1}.justify-between[data-v-d7104f94]{justify-content:space-between}.mr-3[data-v-d7104f94]{margin-left:.75rem}
File diff suppressed because one or more lines are too long
+1
View File
@@ -0,0 +1 @@
import{_ as m}from"./FacilityList.vue_vue_type_script_setup_true_lang-BCbHBV6c.js";import{_ as c}from"./AddBranches.vue_vue_type_script_setup_true_lang-O5kvMvjg.js";import{a as p,b as t}from"./model-BNUuQ7S0.js";import{d as l,a as n,w as f,h as _,o}from"./index-B13tkMpd.js";import"./ListPageHeader.vue_vue_type_script_setup_true_lang-Dv2SKF1q.js";import"./BaseFormModal.vue_vue_type_style_index_0_lang-CyAC3-m9.js";import"./filters-CHKbSAeg.js";import"./index-DXwUc_-g.js";import"./SettingOutlined-C2GWCiUw.js";function u(){const e=new p("admin/branches/list","لیست شعب");return e.add(new t("name","نام").filterText()),e.add(new t("address","آدرس").filterText()),e.add(new t("phone","شماره تلفن").filterNumber()),e.add(new t("user.name","مدیر شعبه").filterNumber().noSort()),e.add(new t("op","عملیات").noSort().renderSlot("actions")),e}const N=l({__name:"ListBranches",setup(e){const r=u();return(h,b)=>(o(),n(m,{title:"لیست شعب",model:_(r),"edit-path":"/branch/edit","active-path":"branch/active","add-rid":"branch.create","add-label":"افزودن شعبه"},{form:f(({open:d,editingId:a,onUpdateOpen:i,onSuccess:s})=>[(o(),n(c,{key:a??"new",open:d,id:a,"onUpdate:open":i,onSuccess:s},null,8,["open","id","onUpdate:open","onSuccess"]))]),_:1},8,["model"]))}});export{N as default};
+1
View File
@@ -0,0 +1 @@
.mt-4[data-v-7869d72f]{margin-top:1rem}
+1
View File
@@ -0,0 +1 @@
import{a as M,b as d,X as V}from"./model-BNUuQ7S0.js";import{_ as h}from"./ListPageHeader.vue_vue_type_script_setup_true_lang-Dv2SKF1q.js";import z from"./AddInvoice-BhHiwzHB.js";import{j as K}from"./filters-CHKbSAeg.js";import{u as U}from"./useDeleteHandler-Do5E4sjj.js";import{d as H,b as g,c as e,w as t,r as s,o as x,h as p,p as y,Q,E as R,D as q,f as r,t as u,a as C,m as _,y as F,_ as G}from"./index-B13tkMpd.js";import"./SettingOutlined-C2GWCiUw.js";import"./BaseFormModal.vue_vue_type_style_index_0_lang-CyAC3-m9.js";import"./index-DXwUc_-g.js";function J(){const n=new M("admin/invoices/list","لیست فاکتورها");return n.add(new d("id","ردیف").filterNumber()),n.add(new d("name","نام مشتری").filterKey("branch.name").filterText()),n.add(new d("sum_weight","جمع کل سفارش").filterNumber().noSort()),n.add(new d("count_item","تعداد آیتم ها").filterNumber().noSort()),n.add(new d("caj","تاریخ ثبت").filterKey("createdAt").filterDate().noSort()),n.add(new d("allocator_user.name","ثبت کننده").renderSlot("user").noSort()),n.add(new d("note","توضیحات").filterText().noSort()),n.add(new d("op","عملیات").noSort().renderSlot("actions")),n}const P={id:"page-user-list"},W={class:"flex gap-2"},Y={key:0},Z=H({__name:"ListInvoice",setup(n){const S=J(),w=_(null),f=_(!1),l=_(void 0),v=_(!1),b=_(void 0);function I(){b.value=void 0,v.value=!0}function $(c){b.value=c,v.value=!0}const D=[{title:"کد محصول",dataIndex:"product_code"},{title:"نام محصول",dataIndex:"title"},{title:"وزن",dataIndex:"grams"}];async function E(c){const{data:o}=await F.get(`branch/product/${c.id}`);l.value=o,f.value=!0}const{remove:N}=U({onSuccess:()=>{var c;return(c=w.value)==null?void 0:c.fetch()},successMessage:"فاکتور حذف شد",fallbackErrorMessage:"خطا در حذف فاکتور"});return(c,o)=>{const k=s("a-tooltip"),T=s("a-popconfirm"),m=s("a-descriptions-item"),j=s("a-descriptions"),A=s("a-table"),B=s("a-empty"),O=s("a-button"),X=s("a-modal"),L=s("a-card");return x(),g("div",P,[e(L,{title:"لیست فاکتورها",class:"page-card"},{default:t(()=>[e(V,{ref_key:"tbl",ref:w,model:p(S),"mobile-cards":""},{add:t(()=>[e(h,{rid:"invoice.create","add-label":"افزودن فاکتور",onAdd:I})]),user:t(({record:a})=>{var i;return[r(u(((i=a.allocator_user)==null?void 0:i.name)??"-"),1)]}),actions:t(({record:a})=>[y("div",W,[e(k,{title:"مشاهده"},{default:t(()=>[e(p(Q),{class:"cursor-pointer mx-1 text-success",onClick:i=>E(a)},null,8,["onClick"])]),_:2},1024),e(k,{title:"ویرایش"},{default:t(()=>[e(p(R),{class:"cursor-pointer mx-1 text-primary",onClick:i=>$(a.id)},null,8,["onClick"])]),_:2},1024),e(k,{title:"حذف"},{default:t(()=>[e(T,{placement:"top","ok-text":"بله","cancel-text":"خیر",onConfirm:i=>p(N)(`branch/product/${a.id}`)},{title:t(()=>[...o[4]||(o[4]=[y("p",null,"آیا مطمئن به حذف فاکتور مورد نظر هستید ؟",-1)])]),default:t(()=>[e(p(q),{class:"cursor-pointer mx-1 text-danger"})]),_:1},8,["onConfirm"])]),_:2},1024)])]),_:1},8,["model"]),e(X,{open:f.value,"onUpdate:open":o[1]||(o[1]=a=>f.value=a),title:"مشاهده فاکتور",width:"70%","wrap-class-name":"detail-modal"},{footer:t(()=>[e(O,{onClick:o[0]||(o[0]=a=>f.value=!1)},{default:t(()=>[...o[5]||(o[5]=[r("بستن",-1)])]),_:1})]),default:t(()=>[l.value?(x(),g("div",Y,[e(j,{bordered:"",size:"small",column:{xxl:2,xl:2,lg:2,md:2,sm:2,xs:1}},{default:t(()=>[e(m,{label:"شعبه"},{default:t(()=>[r(u(l.value.name),1)]),_:1}),e(m,{label:"ثبت کننده"},{default:t(()=>{var a;return[r(u(((a=l.value.allocator_user)==null?void 0:a.name)??"-"),1)]}),_:1}),e(m,{label:"تاریخ ثبت"},{default:t(()=>[r(u(p(K)(l.value.caj)),1)]),_:1}),e(m,{label:"تعداد آیتم"},{default:t(()=>[r(u(l.value.count_item),1)]),_:1}),e(m,{label:"جمع وزن"},{default:t(()=>[r(u(l.value.sum_weight),1)]),_:1}),e(m,{label:"توضیحات"},{default:t(()=>[r(u(l.value.note??"-"),1)]),_:1})]),_:1}),e(A,{class:"mt-4",size:"small","data-source":l.value.products,columns:D,pagination:!1,"row-key":"id"},null,8,["data-source"])])):(x(),C(B,{key:1}))]),_:1},8,["open"]),(x(),C(z,{key:b.value??"new",open:v.value,id:b.value,"onUpdate:open":o[2]||(o[2]=a=>v.value=a),onSuccess:o[3]||(o[3]=a=>{var i;return(i=w.value)==null?void 0:i.fetch()})},null,8,["open","id"]))]),_:1})])}}}),re=G(Z,[["__scopeId","data-v-7869d72f"]]);export{re as default};
@@ -0,0 +1 @@
import{d,u as i,o as u,a as m,w as s,f as c,t as l,c as f,h as p,P as C,i as P,r as b}from"./index-B13tkMpd.js";const _=d({__name:"ListPageHeader",props:{rid:{default:void 0},addLabel:{default:"افزودن"}},emits:["add"],setup(e){const o=i(),n=t=>!!o.hasPermission(t);return(t,a)=>{const r=b("a-button");return!e.rid||n(e.rid)?(u(),m(r,{key:0,type:"primary",onClick:a[0]||(a[0]=k=>t.$emit("add"))},{icon:s(()=>[f(p(C))]),default:s(()=>[c(" "+l(e.addLabel),1)]),_:1})):P("",!0)}}});export{_};
+1
View File
@@ -0,0 +1 @@
import{a as D,b as a,X as E}from"./model-BNUuQ7S0.js";import{_ as U}from"./ListPageHeader.vue_vue_type_script_setup_true_lang-Dv2SKF1q.js";import $ from"./UserCreate-BAw56L1o.js";import{d as M,u as V,x as X,y as h,b as O,c as r,w as n,m as c,r as _,o as m,h as p,a as v,E as A,i as y,D as K,p as L,f as P,t as H}from"./index-B13tkMpd.js";import{u as I}from"./useDeleteHandler-Do5E4sjj.js";import"./filters-CHKbSAeg.js";import"./index-DXwUc_-g.js";import"./SettingOutlined-C2GWCiUw.js";import"./BaseFormModal.vue_vue_type_style_index_0_lang-CyAC3-m9.js";function j(){const o=new D("admin/users/list","لیست مدیران");return o.add(new a("id","کد مدیر")),o.add(new a("fname","نام").filterKey("fullName").filterText()),o.add(new a("lname","نام خانوادگی").filterKey("fullName").filterText()),o.add(new a("mobile","موبایل").filterText()),o.add(new a("ut","نوع کاربر").filterNumber().renderSlot("ut")),o.add(new a("op","عملیات").noSort().renderSlot("op")),o}const q={id:"page-user-list"},ee=M({__name:"ListUser",setup(o){const k=V(),x=e=>!!k.hasPermission(e),w=j(),f=c(null),b=c([]),l=c(!1),i=c(void 0);function g(e){var t;return e==null?"-":((t=b.value.find(d=>d.id===Number(e)))==null?void 0:t.title)??String(e)}function C(){i.value=void 0,l.value=!0}function T(e){i.value=e.id,l.value=!0}const{remove:N}=I({onSuccess:()=>{var e;return(e=f.value)==null?void 0:e.fetch()},successMessage:"کاربر حذف شد",fallbackErrorMessage:"خطا در حذف کاربر"});return X(async()=>{try{const{data:e}=await h.get("const/__list__ut");b.value=e}catch(e){console.log(e)}}),(e,t)=>{const d=_("a-tooltip"),S=_("a-popconfirm"),B=_("a-card");return m(),O("div",q,[r(B,{title:"لیست مدیران",class:"page-card"},{default:n(()=>[r(E,{ref_key:"tbl",ref:f,model:p(w),"mobile-cards":""},{add:n(()=>[r(U,{rid:"user.list.create","add-label":"افزودن کاربر",onAdd:C})]),ut:n(({text:s})=>[P(H(g(s)),1)]),op:n(({record:s})=>[x("user.list.edit")?(m(),v(d,{key:0,title:"ویرایش"},{default:n(()=>[r(p(A),{class:"cursor-pointer mx-1 text-primary",onClick:u=>T(s)},null,8,["onClick"])]),_:2},1024)):y("",!0),x("user.list.remove")?(m(),v(d,{key:1,title:"حذف"},{default:n(()=>[r(S,{placement:"top","ok-text":"بله","cancel-text":"خیر",onConfirm:u=>p(N)(`users/${s.id}`)},{title:n(()=>[...t[2]||(t[2]=[L("p",null,"آیا مطمئن به حذف کاربر مورد نظر هستید ؟",-1)])]),default:n(()=>[r(p(K),{class:"cursor-pointer mx-1 text-danger"})]),_:1},8,["onConfirm"])]),_:2},1024)):y("",!0)]),_:1},8,["model"]),(m(),v($,{key:i.value??"new",open:l.value,id:i.value,"onUpdate:open":t[0]||(t[0]=s=>l.value=s),onSuccess:t[1]||(t[1]=s=>{var u;return(u=f.value)==null?void 0:u.fetch()})},null,8,["open","id"]))]),_:1})])}}});export{ee as default};
+1
View File
@@ -0,0 +1 @@
import{_ as d}from"./FacilityList.vue_vue_type_script_setup_true_lang-BCbHBV6c.js";import{_ as m}from"./AddWorkshop.vue_vue_type_script_setup_true_lang-CB5iJH3B.js";import{a as c,b as e}from"./model-BNUuQ7S0.js";import{d as l,a as r,w as f,h as _,o as a}from"./index-B13tkMpd.js";import"./ListPageHeader.vue_vue_type_script_setup_true_lang-Dv2SKF1q.js";import"./BaseFormModal.vue_vue_type_style_index_0_lang-CyAC3-m9.js";import"./filters-CHKbSAeg.js";import"./index-DXwUc_-g.js";import"./SettingOutlined-C2GWCiUw.js";function h(){const o=new c("admin/workshops/list","لیست کارگاه ها");return o.add(new e("name","نام").filterText()),o.add(new e("address","آدرس").filterText()),o.add(new e("phone","شماره تلفن").filterNumber()),o.add(new e("op","عملیات").noSort().renderSlot("actions")),o}const U=l({__name:"ListWorkshop",setup(o){const n=h();return(w,u)=>(a(),r(d,{title:"لیست کارگاه ها",model:_(n),"edit-path":"/workshop/edit","active-path":"workshop/active","add-rid":"workshop.create","add-label":"افزودن کارگاه"},{form:f(({open:s,editingId:t,onUpdateOpen:i,onSuccess:p})=>[(a(),r(m,{key:t??"new",open:s,id:t,"onUpdate:open":i,onSuccess:p},null,8,["open","id","onUpdate:open","onSuccess"]))]),_:1},8,["model"]))}});export{U as default};
+1
View File
@@ -0,0 +1 @@
import{c as i,I as l}from"./index-B13tkMpd.js";var u={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M832 464h-68V240c0-70.7-57.3-128-128-128H388c-70.7 0-128 57.3-128 128v224h-68c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h640c17.7 0 32-14.3 32-32V496c0-17.7-14.3-32-32-32zM332 240c0-30.9 25.1-56 56-56h248c30.9 0 56 25.1 56 56v224H332V240zm460 600H232V536h560v304zM484 701v53c0 4.4 3.6 8 8 8h40c4.4 0 8-3.6 8-8v-53a48.01 48.01 0 10-56 0z"}}]},name:"lock",theme:"outlined"};function a(r){for(var t=1;t<arguments.length;t++){var e=arguments[t]!=null?Object(arguments[t]):{},n=Object.keys(e);typeof Object.getOwnPropertySymbols=="function"&&(n=n.concat(Object.getOwnPropertySymbols(e).filter(function(c){return Object.getOwnPropertyDescriptor(e,c).enumerable}))),n.forEach(function(c){f(r,c,e[c])})}return r}function f(r,t,e){return t in r?Object.defineProperty(r,t,{value:e,enumerable:!0,configurable:!0,writable:!0}):r[t]=e,r}var o=function(t,e){var n=a({},t,e.attrs);return i(l,a({},n,{icon:u}),null)};o.displayName="LockOutlined";o.inheritAttrs=!1;export{o as L};
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
+1
View File
@@ -0,0 +1 @@
.full-page-msg[data-v-4e6c833c]{min-height:100vh;display:flex;align-items:center;justify-content:center}
+1
View File
@@ -0,0 +1 @@
import{_ as c,b as _,c as e,w as o,f as l,r as s,o as u}from"./index-B13tkMpd.js";const i={},p={class:"full-page-msg"};function d(n,t){const a=s("a-button"),r=s("a-result");return u(),_("div",p,[e(r,{status:"info",title:"در دست تعمیر","sub-title":"این بخش موقتاً در دسترس نیست."},{extra:o(()=>[e(a,{type:"primary",onClick:t[0]||(t[0]=f=>n.$router.push("/"))},{default:o(()=>[...t[1]||(t[1]=[l("بازگشت به خانه",-1)])]),_:1})]),_:1})])}const x=c(i,[["render",d],["__scopeId","data-v-4e6c833c"]]);export{x as default};
File diff suppressed because one or more lines are too long
+1
View File
@@ -0,0 +1 @@
.flex-1[data-v-4a9a9c66]{flex:1}.gap-8[data-v-4a9a9c66]{gap:2rem}.mr-3[data-v-4a9a9c66]{margin-left:.75rem}@media (max-width: 575px){.make-detail[data-v-4a9a9c66]{flex-direction:column;gap:12px}.make-detail>.flex[data-v-4a9a9c66]{min-width:0}}
@@ -0,0 +1 @@
.full-page-msg[data-v-8b21c139]{min-height:100vh;display:flex;align-items:center;justify-content:center}
@@ -0,0 +1 @@
import{_,b as c,c as e,w as o,f as l,r as s,o as u}from"./index-B13tkMpd.js";const p={},d={class:"full-page-msg"};function i(n,t){const r=s("a-button"),a=s("a-result");return u(),c("div",d,[e(a,{status:"403",title:"دسترسی غیرمجاز","sub-title":"شما دسترسی لازم برای مشاهده این صفحه را ندارید."},{extra:o(()=>[e(r,{type:"primary",onClick:t[0]||(t[0]=f=>n.$router.push("/"))},{default:o(()=>[...t[1]||(t[1]=[l("بازگشت به خانه",-1)])]),_:1})]),_:1})])}const b=_(p,[["render",i],["__scopeId","data-v-8b21c139"]]);export{b as default};
@@ -0,0 +1 @@
import{b as i,O as m,a as e}from"./OmdeCustomerList-CM9_pbJI.js";import{d as p,a as s,h as t,o as a}from"./index-B13tkMpd.js";import"./index-DXwUc_-g.js";import"./model-BNUuQ7S0.js";import"./filters-CHKbSAeg.js";import"./SettingOutlined-C2GWCiUw.js";import"./ListPageHeader.vue_vue_type_script_setup_true_lang-Dv2SKF1q.js";import"./AccountingSyncButton.vue_vue_type_script_setup_true_lang-BmGGSgHW.js";import"./bulkCustomer.vue_vue_type_script_setup_true_lang-DCiRvD_P.js";import"./BaseFormModal.vue_vue_type_style_index_0_lang-CyAC3-m9.js";import"./ImageUploadInput.vue_vue_type_script_setup_true_lang-C-8ZQMi-.js";import"./CityTreeSelect.vue_vue_type_script_setup_true_lang-cGpnZ8Gn.js";import"./DateInput-CVKHy-b9.js";import"./UserOutlined-tnfFbi-d.js";import"./ShopOutlined-BULNMNmg.js";import"./EnvironmentOutlined-BII2axx6.js";import"./PercentageOutlined-CpguakOP.js";import"./SafetyCertificateOutlined-B7xsdKuU.js";import"./UnorderedListOutlined-DVq783q4.js";const U=p({__name:"OmdeArchivedList",setup(d){const o=m.archived.title,r=i("archived");return(l,c)=>(a(),s(e,{title:t(o),model:t(r)},null,8,["title","model"]))}});export{U as default};
File diff suppressed because one or more lines are too long
@@ -0,0 +1 @@
.acc-debt[data-v-287c42bd]{color:#cf1322}.acc-credit[data-v-287c42bd]{color:#389e0d}.acc-none[data-v-287c42bd]{color:#bfbfbf}@media (max-width: 575px){.list-count[data-v-287c42bd]{font-size:12px;margin-bottom:8px}}
+1
View File
@@ -0,0 +1 @@
import{b as i,O as r,a as e}from"./OmdeCustomerList-CM9_pbJI.js";import{d as p,a as s,h as t,o as a}from"./index-B13tkMpd.js";import"./index-DXwUc_-g.js";import"./model-BNUuQ7S0.js";import"./filters-CHKbSAeg.js";import"./SettingOutlined-C2GWCiUw.js";import"./ListPageHeader.vue_vue_type_script_setup_true_lang-Dv2SKF1q.js";import"./AccountingSyncButton.vue_vue_type_script_setup_true_lang-BmGGSgHW.js";import"./bulkCustomer.vue_vue_type_script_setup_true_lang-DCiRvD_P.js";import"./BaseFormModal.vue_vue_type_style_index_0_lang-CyAC3-m9.js";import"./ImageUploadInput.vue_vue_type_script_setup_true_lang-C-8ZQMi-.js";import"./CityTreeSelect.vue_vue_type_script_setup_true_lang-cGpnZ8Gn.js";import"./DateInput-CVKHy-b9.js";import"./UserOutlined-tnfFbi-d.js";import"./ShopOutlined-BULNMNmg.js";import"./EnvironmentOutlined-BII2axx6.js";import"./PercentageOutlined-CpguakOP.js";import"./SafetyCertificateOutlined-B7xsdKuU.js";import"./UnorderedListOutlined-DVq783q4.js";const U=p({__name:"OmdeList",setup(n){const o=r.omde.title,m=i("omde");return(l,c)=>(a(),s(e,{title:t(o),model:t(m),"accounting-sync":""},null,8,["title","model"]))}});export{U as default};
+1
View File
@@ -0,0 +1 @@
.flex-col[data-v-e8d94314]{flex-direction:column}.flex-1[data-v-e8d94314]{flex:1}.mr-3[data-v-e8d94314]{margin-left:.75rem}
File diff suppressed because one or more lines are too long
@@ -0,0 +1 @@
import{b as r,O as e,a as m}from"./OmdeCustomerList-CM9_pbJI.js";import{d as p,a as n,h as t,o as s}from"./index-B13tkMpd.js";import"./index-DXwUc_-g.js";import"./model-BNUuQ7S0.js";import"./filters-CHKbSAeg.js";import"./SettingOutlined-C2GWCiUw.js";import"./ListPageHeader.vue_vue_type_script_setup_true_lang-Dv2SKF1q.js";import"./AccountingSyncButton.vue_vue_type_script_setup_true_lang-BmGGSgHW.js";import"./bulkCustomer.vue_vue_type_script_setup_true_lang-DCiRvD_P.js";import"./BaseFormModal.vue_vue_type_style_index_0_lang-CyAC3-m9.js";import"./ImageUploadInput.vue_vue_type_script_setup_true_lang-C-8ZQMi-.js";import"./CityTreeSelect.vue_vue_type_script_setup_true_lang-cGpnZ8Gn.js";import"./DateInput-CVKHy-b9.js";import"./UserOutlined-tnfFbi-d.js";import"./ShopOutlined-BULNMNmg.js";import"./EnvironmentOutlined-BII2axx6.js";import"./PercentageOutlined-CpguakOP.js";import"./SafetyCertificateOutlined-B7xsdKuU.js";import"./UnorderedListOutlined-DVq783q4.js";const U=p({__name:"OmdeNonVerifiedList",setup(a){const o=e.nonVerified.title,i=r("nonVerified");return(d,l)=>(s(),n(m,{title:t(o),model:t(i)},null,8,["title","model"]))}});export{U as default};
@@ -0,0 +1 @@
import{c as l,I as u}from"./index-B13tkMpd.js";var o={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M855.7 210.8l-42.4-42.4a8.03 8.03 0 00-11.3 0L168.3 801.9a8.03 8.03 0 000 11.3l42.4 42.4c3.1 3.1 8.2 3.1 11.3 0L855.6 222c3.2-3 3.2-8.1.1-11.2zM304 448c79.4 0 144-64.6 144-144s-64.6-144-144-144-144 64.6-144 144 64.6 144 144 144zm0-216c39.7 0 72 32.3 72 72s-32.3 72-72 72-72-32.3-72-72 32.3-72 72-72zm416 344c-79.4 0-144 64.6-144 144s64.6 144 144 144 144-64.6 144-144-64.6-144-144-144zm0 216c-39.7 0-72-32.3-72-72s32.3-72 72-72 72 32.3 72 72-32.3 72-72 72z"}}]},name:"percentage",theme:"outlined"};function c(r){for(var e=1;e<arguments.length;e++){var t=arguments[e]!=null?Object(arguments[e]):{},n=Object.keys(t);typeof Object.getOwnPropertySymbols=="function"&&(n=n.concat(Object.getOwnPropertySymbols(t).filter(function(a){return Object.getOwnPropertyDescriptor(t,a).enumerable}))),n.forEach(function(a){f(r,a,t[a])})}return r}function f(r,e,t){return e in r?Object.defineProperty(r,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):r[e]=t,r}var i=function(e,t){var n=c({},e,t.attrs);return l(u,c({},n,{icon:o}),null)};i.displayName="PercentageOutlined";i.inheritAttrs=!1;export{i as P};
File diff suppressed because one or more lines are too long
+1
View File
@@ -0,0 +1 @@
[dir=rtl] .ant-tree-checkbox-inner:after{right:55%;top:35%;border-left:0!important;-webkit-transform:rotate(-45deg) scale(0) translate(50%,-50%);transform:rotate(-45deg) scale(0) translate(50%,-50%)}[dir=rtl] .ant-tree-checkbox-checked .ant-tree-checkbox-inner:after{border-left:0!important;border-right:2px solid #fff;-webkit-transform:rotate(45deg) scale(1) translate(0%,-60%);transform:rotate(45deg) scale(1) translateY(-60%)}.tree-item[data-v-e837c6b0]{grid-column:1 / -1}@media (max-width: 575px){.tree-item[data-v-e837c6b0] .ant-tree-indent-unit{width:14px}.tree-item[data-v-e837c6b0] .ant-tree-node-content-wrapper{white-space:normal}}

Some files were not shown because too many files have changed in this diff Show More