Commit Graph
80 Commits
Author SHA1 Message Date
Alireza HassaniandCursor 730407ec3a Split blogs and other modules into child sitemaps.
Move blogs, portfolios, videos, instructions, and workshops out of sitemap-main into dedicated files like products, and allow saving migrated Farsi category color labels without wiping store-item links.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-26 19:02:38 +03:30
Alireza HassaniandCursor 5850c90d84 Re-provision storefront nginx when domain host is renamed.
Also create origin HTTPS with a self-signed cert on provision so Cloudflare Full does not fall through to another site's default SSL vhost.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-26 17:31:56 +03:30
Alireza HassaniandCursor cbe7aced6d Serve public AI prompts as plain text.
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-26 15:47:27 +03:30
Alireza HassaniandCursor 91a20a89d6 Add public AI prompt templates for websites.
Manage reusable templates in Super Admin, attach editable per-site prompts with Meshkee API public links that require no auth.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-26 15:28:41 +03:30
Alireza HassaniandCursor 4db9c7709d Default annual renewal to business created date.
Backfill null renewals from created_at and use now when create omits the date.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-26 10:33:26 +03:30
Alireza HassaniandCursor 92601ae729 Add page-view analytics, product counters, SSL expiry, and business renewal.
Auto-count storefront page views with 6-month event retention and lifetime counters, track product visit/cart/sale stats, persist SSL cert expiry with daily probes, and support owner titles plus annual contract renewal.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-26 10:13:06 +03:30
Alireza HassaniandCursor 6cd0b009ef Call per-tenant dashboard SSL agent when issuing domain SSL.
Issue SSL on one domain now passes tenantApex to the dashboards agent instead of renewing the shared multi-tenant cert.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-26 01:20:03 +03:30
Alireza HassaniandCursor 3f266a2dcb Add website view analytics for dashboard traffic charts.
Track storefront views via POST /tenants/{domain}/analytics/views, expose business activity API, and add product/website/portfolio/blog 30-day chart types for super-admin selection.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-26 01:12:44 +03:30
Alireza HassaniandCursor b8f60c5141 Skip dashboard SSL hosts without DNS and shorten sync errors.
Dashboard cert renewal no longer fails when unrelated tenants lack business/customer DNS records; Issue SSL errors summarize blocked hostnames instead of dumping certbot logs.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-26 00:55:58 +03:30
Alireza HassaniandCursor ead16080b8 Add website favicon API and manual favicon profile updates.
Expose GET /tenants/{domain}/website/favicon for storefront tab icons, allow faviconMediaId on profile PATCH, and sync website API docs.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-26 00:51:11 +03:30
Alireza HassaniandCursor 6ce6f959ac Add dark-mode business logo, payment order steps, and Arvan DNS diagnostics.
Store logo_dark_media_id on businesses, expose logoDarkUrl on tenant/website APIs, prepend awaiting-payment steps to order workflows, and surface clearer Arvan API network errors.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-26 00:21:46 +03:30
Alireza HassaniandCursor e942348b1d Route payment bank callbacks through storefront domains.
ZarinPal rejects api.meshkee.com when the terminal is registered to the store apex; nginx now proxies /meshkee/payments/{gateway}/callback to a host-scoped API route.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-25 21:34:56 +03:30
Alireza HassaniandCursor 40284df880 Surface the real build error when website deploy.sh fails.
Super Admin was only showing "exited with code 1" because the ERR trap never copied the last compiler or module-not-found line from the deploy log.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-25 17:39:03 +03:30
Alireza HassaniandCursor 20cc0bbd78 Fix e-payment settings payload, cart race, and media/content helpers.
Stop returning passwordSet (forbidNonWhitelisted), upsert carts safely, and harden related media/product/workshop flows.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-25 16:41:00 +03:30
Alireza HassaniandCursor ad6f9dcf1d Expose portfolio projectUrl and document it for websites.
Wire create/update/list/detail to project_url and sync website OpenAPI, Postman, and AI brief.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-23 16:47:46 +03:30
Alireza HassaniandCursor 37bce1e9fa Add moveToTop on portfolio update so items pin to absolute list top.
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-23 15:23:17 +03:30
Alireza HassaniandCursor af0573c089 Show newest portfolios first on dashboard and website lists.
Order by sort_order descending and assign new items the next highest sort value so create and move-up stay consistent.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-23 15:01:52 +03:30
Alireza HassaniandCursor ea40ae40d8 Split product sitemap and use Farsi category URLs with ids.
sitemap.xml is now an index of main + products; category loc paths use /products/category/{id}/{nameFaSlug} with a public by-id lookup for storefronts.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-23 00:23:30 +03:30
Alireza HassaniandCursor c4367d8eb0 Include product category URLs in sitemaps and document by-slug lookup.
Adds /products/category/{slug} to default sitemap generation and a public categories/by-slug endpoint for storefront category pages.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-23 00:15:26 +03:30
Alireza HassaniandCursor df17925d3a Keep Farsi characters readable in sitemap loc URLs.
Stop percent-encoding path slugs so <loc> shows UTF-8 Persian text while still sanitizing unsafe URL characters.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-23 00:04:07 +03:30
Alireza HassaniandCursor 7cef24336a Use /{id}/{fa-slug} detail URLs in sitemaps and add public by-id lookups.
Default sitemap templates now emit SEO-friendly Farsi path segments with stable CMS ids; storefronts resolve content via new by-id public endpoints.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-22 23:43:25 +03:30
Alireza HassaniandCursor 1b16e79d3f Add tag filter to blogs, portfolios, and videos list APIs.
Storefronts can filter published content by metadata.tags the same way as products; website API docs are updated to match.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-22 21:14:42 +03:30
Alireza HassaniandCursor e0e122ed57 Add name filter to business store-items list.
Lets the dashboard specials picker search store items without loading the full catalog.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-22 20:38:58 +03:30
Alireza HassaniandCursor 24ce75c2e6 Expand website AI prompt with on-page SEO requirements for every public page.
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-22 19:58:53 +03:30
Alireza HassaniandCursor 2e8d7c1cfd Add backend-generated sitemap with website manifest sync and nginx SEO proxy support.
Stores synced route config from /meshkee/sitemap-config.json, serves sitemap.xml and robots.txt per tenant, and invalidates cache on CMS writes.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-22 15:15:32 +03:30
Alireza HassaniandCursor c7d5204b49 Add workshops CMS API with schedule, registrations, and public storefront routes.
Includes SQL migrations, Prisma models, dashboard CRUD, registration status workflow, and website OpenAPI updates for workshop listing and signup.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-22 12:22:24 +03:30
Alireza HassaniandCursor 9d56ec7396 Fix register transaction typing for cross-site password update.
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-21 12:09:52 +03:30
Alireza HassaniandCursor e027cc96ea Replace Meshkee password when linking an existing account to a new site.
Cross-site register now updates the password to the signup value and documents passwordUpdated for storefronts.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-21 12:07:17 +03:30
Alireza HassaniandCursor b0d4916138 Add website special-products source setting for storefronts.
Let businesses choose product vs store_item sourcing, defaulting from the store module, and expose it on tenant resolve and store-specials.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-21 11:57:49 +03:30
Alireza HassaniandCursor 8609d8d4fd Make Arvan DNS updates opt-in and persist English user names.
Domain add/edit only upserts Arvan records when updateDns is true, and super-admin user PATCH now accepts firstNameEn and lastNameEn.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-20 11:50:57 +03:30
Alireza HassaniandCursor f61bba317e Add SSO handoff tickets and expand seeded countries for address forms.
Support one-time Redis-backed dashboard sign-in handoff and seed European, Middle East, and Far East countries with major cities.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-19 19:46:57 +03:30
Alireza HassaniandCursor 7277817b6e Add store-item Excel export/import for bulk price and stock updates.
Dashboard can download grouped product variants and re-upload to update price and stock. Also expose Content-Disposition for downloads and keep related product/customer API docs in sync.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-19 01:02:43 +03:30
Alireza HassaniandCursor 4a5780e74d Include updatedAt in store-item listings
Backend now returns updated timestamps for variants so the UI can sort by availability.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-18 11:26:20 +03:30
Alireza HassaniandCursor 5e5bfc4aa3 Sync static image slots from the live website catalog.
Refresh now imports keys from the storefront and deletes unused slots plus their files.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-17 09:55:03 +03:30
Alireza HassaniandCursor 1c7678ce67 Add website static image slots with page grouping and bilingual captions.
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-16 23:56:16 +03:30
Alireza HassaniandCursor b991a60cbc Add ZarinPal e-payment and related checkout/search fixes.
Business settings can store ZarinPal merchant credentials, and the payment registry can initiate and verify ZarinPal alongside Mellat.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-16 01:45:41 +03:30
Alireza HassaniandCursor c76c3967bb Point backend deploy docs at gitea.meshkee.com.
Production now pulls meshkee-app/backend over SSH port 2222 instead of the old git.meshkee.com remote.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-14 11:20:48 +03:30
Alireza HassaniandCursor 30119e6d9e Upsert ArvanCloud DNS records when a super-admin adds or updates a domain.
Tenant zones get an apex ANAME and CNAMEs for www, business, customer, and api without storing origin IPs.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-14 11:16:35 +03:30
Alireza HassaniandCursor d08a85cee5 Prune Next build leftovers after standalone website deploys.
Keep only .next/standalone so sites drop cache and duplicate server trees.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-13 20:41:27 +03:30
Alireza HassaniandCursor 9818721bce Document standalone Next.js deploy behavior for websites agent.
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-13 20:34:02 +03:30
Alireza HassaniandCursor f201a6408c Support Next.js standalone runtime in websites deploy agent.
Copy static/public into the standalone bundle, point PM2 at server.js, and drop full node_modules after a successful start.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-13 20:31:39 +03:30
Alireza HassaniandCursor 62f75c3a75 Default business and domain list page size to 24.
Match the dashboard list rule when clients omit pageSize.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-13 15:19:46 +03:30
Alireza HassaniandCursor d5e502cf77 Add Mellat e-payment, videos/instructions CMS, and legacy domain lookup.
Store gateway credentials per business, initiate/verify Mellat at checkout, and resolve old CMS ids from domains in the migrate modal.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-13 09:51:17 +03:30
Alireza HassaniandCursor 513673a7da Add Open Graph HTML for public invoice link previews.
WhatsApp and other crawlers can scrape invoice title and image without running the SPA.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-11 16:15:52 +03:30
Alireza HassaniandCursor d8f4e8c4e5 Support local public invoice URLs with port overrides.
Dev can set INVOICE_PUBLIC_BASE_URL or DEV_PORT/HOST so copied links reach the Vite viewer.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-11 16:03:33 +03:30
Alireza HassaniandCursor 49a9f0c289 Expose invoice locale on public payloads and accept English name fields on create customer.
Public invoices need branding defaultLocale for RTL viewers; customer create aligns with the business add-customer form.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-11 15:46:18 +03:30
Alireza HassaniandCursor 73118f38d5 Add finance as an optional business module.
Super-admin can enable Finance per tenant alongside other dashboard modules.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-11 15:23:53 +03:30
Alireza HassaniandCursor 5734a73c9c Add business-scoped invoices billed to users.
Introduce invoices.user_id, business template/invoice APIs, and tenant-domain public URLs so business dashboards can issue invoices without platform-scope template mismatches.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-11 15:17:03 +03:30
Alireza HassaniandCursor e59db25814 Add business team access controls and customer role filters.
Super-admins can assign Admin; owners/admins manage Editor/Viewer via team/access, and the customers list supports all/customers/managers filtering.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-10 21:31:28 +03:30
Alireza HassaniandCursor 2c4d02bd0e Normalize AI product HTML for the rich text description editor.
Sanitize model output to an allowlisted fragment and convert plain/markdown fallbacks so description text stays inside the advanced editor.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-10 20:44:47 +03:30