Connect all CRM pages to the BFF and CRM service, add module docs, and mark CRM available in the SuperApp catalog. Co-authored-by: Cursor <cursoragent@cursor.com>
94 lines
3.6 KiB
TypeScript
94 lines
3.6 KiB
TypeScript
"use client";
|
||
|
||
import { PageHeader } from "@/components/ds";
|
||
import { CrmScopeNotice } from "@/modules/crm/components/CrmScopeNotice";
|
||
import { CrmBreadcrumbs } from "@/modules/crm/components/CrmBreadcrumbs";
|
||
|
||
export function CampaignsPage() {
|
||
return (
|
||
<div>
|
||
<CrmBreadcrumbs items={[{ label: "کمپینها" }]} />
|
||
<PageHeader title="کمپینها" description="خارج از محدوده CRM Core Platform." />
|
||
<CrmScopeNotice
|
||
title="کمپین در CRM پیادهسازی نشده"
|
||
description="Phase 6.0–6.3 عمداً Marketing/Campaign را مالک نمیشود. از Communication Platform یا ماژول Marketing آینده استفاده کنید."
|
||
alternatives={[
|
||
{ label: "Communication", href: "/dashboard" },
|
||
{ label: "Loyalty Campaigns", href: "/dashboard" },
|
||
]}
|
||
/>
|
||
</div>
|
||
);
|
||
}
|
||
|
||
export function SegmentsPage() {
|
||
return (
|
||
<div>
|
||
<CrmBreadcrumbs items={[{ label: "سگمنتها" }]} />
|
||
<PageHeader title="سگمنتها" description="Segmentation engine در CRM وجود ندارد." />
|
||
<CrmScopeNotice
|
||
title="سگمنت API موجود نیست"
|
||
description="برای فیلتر مخاطب از لیست Contacts/Organizations با جستجوی client-side استفاده کنید."
|
||
alternatives={[{ label: "مخاطبین", href: "/crm/sales/contacts" }]}
|
||
/>
|
||
</div>
|
||
);
|
||
}
|
||
|
||
export function ImportPage() {
|
||
return (
|
||
<div>
|
||
<CrmBreadcrumbs items={[{ label: "ورود داده" }]} />
|
||
<PageHeader title="ورود داده" description="Bulk import API در CRM 6.3 وجود ندارد." />
|
||
<CrmScopeNotice
|
||
title="Import endpoint موجود نیست"
|
||
description="برای ورود داده از API تکتک (POST /leads, /contacts, …) یا اسکript خارجی با JWT + X-Tenant-ID استفاده کنید."
|
||
alternatives={[
|
||
{ label: "سرنخها", href: "/crm/sales/leads" },
|
||
{ label: "خروجی CSV", href: "/crm/sales/export" },
|
||
]}
|
||
/>
|
||
</div>
|
||
);
|
||
}
|
||
|
||
export function AutomationPage() {
|
||
return (
|
||
<div>
|
||
<CrmBreadcrumbs items={[{ label: "اتوماسیون" }]} />
|
||
<PageHeader title="اتوماسیون" description="Workflow automation مالکیت Automation Platform است." />
|
||
<CrmScopeNotice
|
||
title="AutomationProvider فقط contract"
|
||
description="CRM events را publish میکند اما workflow engine ندارد."
|
||
/>
|
||
</div>
|
||
);
|
||
}
|
||
|
||
export function IntegrationsPage() {
|
||
return (
|
||
<div>
|
||
<CrmBreadcrumbs items={[{ label: "یکپارچهسازی" }]} />
|
||
<PageHeader title="یکپارچهسازی" description="Integration registry در CRM HTTP API وجود ندارد." />
|
||
<CrmScopeNotice
|
||
title="Integrations API موجود نیست"
|
||
description="Provider contracts (Notification, Analytics, FileStorage, …) فقط در backend تعریف شدهاند."
|
||
/>
|
||
</div>
|
||
);
|
||
}
|
||
|
||
export function ApiKeysPage() {
|
||
return (
|
||
<div>
|
||
<CrmBreadcrumbs items={[{ label: "کلید API" }]} />
|
||
<PageHeader title="کلید API" description="احراز هویت از Keycloak JWT — API key management در CRM نیست." />
|
||
<CrmScopeNotice
|
||
title="API Keys در Identity/Core"
|
||
description="برای دسترسی programmatic از SSO و tenant header استفاده کنید."
|
||
alternatives={[{ label: "Identity", href: "/dashboard" }]}
|
||
/>
|
||
</div>
|
||
);
|
||
}
|