feat(admin): add confirmation modal before applying bulk price adjustments and margins
Some checks failed
Deploy Canina / deploy (push) Successful in 33s
E2E Playwright Tests / Run Full E2E & Security Suites (push) Failing after 6s

This commit is contained in:
parsa aghaei 2026-09-02 13:11:51 +03:30
parent ceaab10fdd
commit 3344fe7f8d
12 changed files with 3203 additions and 3106 deletions

View File

@ -326,6 +326,21 @@ export default function Products() {
wholesaleMarginPercent: 15,
});
// Confirm Modal state for Bulk Price actions
const [confirmBulkModal, setConfirmBulkModal] = useState<{
isOpen: boolean;
type: 'adjust' | 'margin';
title: string;
message: string;
confirmText: string;
}>({
isOpen: false,
type: 'adjust',
title: '',
message: '',
confirmText: 'تایید و اعمال',
});
const [draggedMediaIdx, setDraggedMediaIdx] = useState<number | null>(null);
const [dragOverMediaIdx, setDragOverMediaIdx] = useState<number | null>(null);
const [customMediaUrl, setCustomMediaUrl] = useState('');
@ -725,6 +740,74 @@ export default function Products() {
}
};
// Open Confirmation Modal before applying bulk actions
const handleInitiateBulkAction = () => {
if (bulkPriceTab === 'adjust') {
if (!bulkAdjustForm.value || Number(bulkAdjustForm.value) <= 0) {
toast.error('لطفاً مقدار معتبر برای تغییر قیمت وارد نمایید');
return;
}
const scopeText = bulkAdjustForm.scope === 'ALL'
? 'تمامی محصولات کاتالوگ'
: `${bulkAdjustForm.categoryIds.length} دسته‌بندی انتخاب‌شده`;
const dirText = bulkAdjustForm.adjustmentDirection === 'INCREASE' ? 'افزایش' : 'کاهش';
const valText = bulkAdjustForm.adjustmentType === 'PERCENT'
? `${bulkAdjustForm.value} درصد`
: `${Number(bulkAdjustForm.value).toLocaleString('fa-IR')} تومان`;
const fieldText =
bulkAdjustForm.targetField === 'RETAIL' ? 'قیمت مصرف‌کننده (فروش)' :
bulkAdjustForm.targetField === 'WHOLESALE' ? 'قیمت همکار (عمده)' :
bulkAdjustForm.targetField === 'BUY' ? 'قیمت خرید' :
bulkAdjustForm.targetField === 'BOTH_SELLING' ? 'هر دو قیمت فروش (مصرف‌کننده و همکار)' :
'تمامی قیمت‌ها (خرید، فروش و همکار)';
const message = `آیا از اعمال ${dirText} ${valText} بر روی ${fieldText} برای ${scopeText} مطمئن هستید؟ این عملیات بلافاصله قیمت‌های پایگاه داده را به‌روزرسانی خواهد کرد.`;
setConfirmBulkModal({
isOpen: true,
type: 'adjust',
title: 'تأیید اعمال گروهی تغییرات قیمت',
message,
confirmText: 'تایید و تغییر قیمت‌ها',
});
} else {
if (globalMarginForm.retailMarginPercent === undefined || Number(globalMarginForm.retailMarginPercent) < 0) {
toast.error('لطفاً درصد سود مصرف‌کننده معتبر وارد نمایید');
return;
}
if (globalMarginForm.wholesaleMarginPercent === undefined || Number(globalMarginForm.wholesaleMarginPercent) < 0) {
toast.error('لطفاً درصد سود همکار معتبر وارد نمایید');
return;
}
const scopeText = globalMarginForm.scope === 'ALL'
? 'تمامی محصولات کاتالوگ'
: `${globalMarginForm.categoryIds.length} دسته‌بندی انتخاب‌شده`;
const message = `آیا از محاسبه مجدد و اعمال سراسری سود (${globalMarginForm.retailMarginPercent}٪ مصرف‌کننده و ${globalMarginForm.wholesaleMarginPercent}٪ همکار) بر روی ${scopeText} مطمئن هستید؟ قیمت‌های فروش بر اساس قیمت خرید و درصدهای سود جدید بازنویسی و رند خواهند شد.`;
setConfirmBulkModal({
isOpen: true,
type: 'margin',
title: 'تأیید محاسبه و اعمال سراسری درصد سود',
message,
confirmText: 'تایید و محاسبه سود',
});
}
};
const handleConfirmBulkAction = async () => {
if (confirmBulkModal.type === 'adjust') {
await handleBulkPriceAdjustment();
} else {
await handleApplyGlobalMargins();
}
setConfirmBulkModal(prev => ({ ...prev, isOpen: false }));
};
const handleSave = async (e: React.FormEvent) => {
@ -3929,7 +4012,7 @@ export default function Products() {
size="sm"
startIcon={isBulkApplying ? Spinner : CheckCircle2}
isLoading={isBulkApplying}
onClick={bulkPriceTab === 'adjust' ? handleBulkPriceAdjustment : handleApplyGlobalMargins}
onClick={handleInitiateBulkAction}
>
{bulkPriceTab === 'adjust' ? 'اعمال تغییرات قیمت بر روی کالاها' : 'محاسبه و اعمال سراسری سود'}
</Button>
@ -3963,6 +4046,7 @@ export default function Products() {
}
/>
{/* Delete Product Confirmation Modal */}
<ConfirmModal
isOpen={!!deleteTargetId}
title="حذف محصول"
@ -3971,6 +4055,19 @@ export default function Products() {
onCancel={() => setDeleteTargetId(null)}
/>
{/* Bulk Price Operations Confirmation Modal */}
<ConfirmModal
isOpen={confirmBulkModal.isOpen}
title={confirmBulkModal.title}
message={confirmBulkModal.message}
confirmText={confirmBulkModal.confirmText}
cancelText="انصراف و بازگشت"
isDestructive={true}
isLoading={isBulkApplying}
onConfirm={handleConfirmBulkAction}
onCancel={() => setConfirmBulkModal(prev => ({ ...prev, isOpen: false }))}
/>
{/* Product Image Lightbox Modal */}
{previewImage && (
<div

View File

@ -121,13 +121,13 @@
"119": "compilerOptions",
"120": "compilerOptions",
"121": "backend/README.md",
"122": "AdminService",
"122": "AdminController",
"123": "UsersService",
"124": "Repository Map",
"125": "validate_integrity.js",
"126": "admin-panel/package.json",
"127": "Sahel-Font",
"128": "ProductDto",
"128": "AdminService",
"129": "Reports.tsx",
"130": "Sahel-Font",
"131": "Role & Core Objective",
@ -197,7 +197,7 @@
"195": "React + TypeScript + Vite",
"196": "Select.tsx",
"197": "userStore.ts",
"198": "Body",
"198": "@tailwindcss/postcss",
"199": "SmsLogQueryDto",
"200": "application/README.md",
"201": "deploy.sh",
@ -330,6 +330,5 @@
"328": "@types/supertest",
"329": "typescript-eslint",
"330": "@nestjs/swagger",
"331": "tailwindcss",
"332": "eslint-config-next"
"331": "tailwindcss"
}

File diff suppressed because one or more lines are too long

View File

@ -121,13 +121,13 @@
"119": "compilerOptions",
"120": "compilerOptions",
"121": "backend/README.md",
"122": "AdminController",
"122": "AdminService",
"123": "UsersService",
"124": "Repository Map",
"125": "validate_integrity.js",
"126": "admin-panel/package.json",
"127": "Sahel-Font",
"128": "AdminService",
"128": "ProductDto",
"129": "Reports.tsx",
"130": "Sahel-Font",
"131": "Role & Core Objective",
@ -197,7 +197,7 @@
"195": "React + TypeScript + Vite",
"196": "Select.tsx",
"197": "userStore.ts",
"198": "@tailwindcss/postcss",
"198": "Body",
"199": "SmsLogQueryDto",
"200": "application/README.md",
"201": "deploy.sh",
@ -300,7 +300,7 @@
"298": ".initiateOrderPayment",
"299": "@tailwindcss/postcss",
"300": "typescript",
"301": "bcrypt",
"301": "@nestjs/jwt",
"302": "typescript-eslint",
"303": "@nestjs/throttler",
"304": "passport",
@ -323,12 +323,13 @@
"321": "orders/page.tsx",
"322": "pets/page.tsx",
"323": "prettier",
"324": "ts-jest",
"324": "eslint",
"325": "@types/react-dom",
"326": "@types/js-yaml",
"327": "eslint-plugin-react-refresh",
"328": "@types/supertest",
"329": "typescript-eslint",
"330": "@nestjs/swagger",
"331": "tailwindcss"
"331": "tailwindcss",
"332": "eslint-config-next"
}

View File

@ -1,16 +1,16 @@
# Graph Report - canina (2026-09-02)
## Corpus Check
- 599 files · ~1,082,386 words
- 599 files · ~1,084,324 words
- Verdict: corpus is large enough that graph structure adds value.
## Summary
- 4208 nodes · 7643 edges · 332 communities (212 shown, 120 thin omitted)
- 4208 nodes · 7643 edges · 333 communities (214 shown, 119 thin omitted)
- Extraction: 96% EXTRACTED · 4% INFERRED · 0% AMBIGUOUS · INFERRED: 288 edges (avg confidence: 0.79)
- Token cost: 0 input · 0 output
## Graph Freshness
- Built from commit: `9744aa81`
- Built from commit: `68840fbd`
- Run `git rev-parse HEAD` and compare to check if the graph is stale.
- Run `graphify update .` after code changes (no API cost).
@ -136,13 +136,13 @@
- compilerOptions
- compilerOptions
- backend/README.md
- AdminController
- AdminService
- UsersService
- Repository Map
- validate_integrity.js
- admin-panel/package.json
- Sahel-Font
- AdminService
- ProductDto
- Reports.tsx
- Sahel-Font
- Role & Core Objective
@ -211,7 +211,7 @@
- React + TypeScript + Vite
- Select.tsx
- userStore.ts
- @tailwindcss/postcss
- Body
- SmsLogQueryDto
- application/README.md
- deploy.sh
@ -299,7 +299,7 @@
- .initiateOrderPayment
- @tailwindcss/postcss
- typescript
- bcrypt
- @nestjs/jwt
- typescript-eslint
- @nestjs/throttler
- passport
@ -318,7 +318,7 @@
- @nestjs/cli
- @nestjs/testing
- prettier
- ts-jest
- eslint
- @types/react-dom
- @types/js-yaml
- eslint-plugin-react-refresh
@ -326,6 +326,7 @@
- typescript-eslint
- @nestjs/swagger
- tailwindcss
- eslint-config-next
## God Nodes (most connected - your core abstractions)
1. `Roles()` - 106 edges
@ -356,7 +357,7 @@
- 3-file cycle: `frontend/application/lib/services/api.ts -> frontend/application/lib/store/userStore.ts -> frontend/application/lib/services/authService.ts -> frontend/application/lib/services/api.ts`
- 4-file cycle: `frontend/application/lib/services/api.ts -> frontend/application/lib/store/userStore.ts -> frontend/application/lib/store/cartStore.ts -> frontend/application/lib/services/orderService.ts -> frontend/application/lib/services/api.ts`
## Communities (332 total, 120 thin omitted)
## Communities (333 total, 119 thin omitted)
### Community 0 - "Roles"
Cohesion: 0.24
@ -396,15 +397,15 @@ Nodes (17): SettingsController, ApiBearerAuth, ApiOkResponse, ApiOperation, ApiT
### Community 9 - "devDependencies"
Cohesion: 0.22
Nodes (9): devDependencies, eslint, @types/bcryptjs, @types/node, typescript, eslint, @types/node, typescript (+1 more)
Nodes (9): devDependencies, ts-jest, @types/bcryptjs, @types/node, typescript, @types/node, typescript, ts-jest (+1 more)
### Community 10 - "CreateReviewDto"
Cohesion: 0.07
Nodes (30): CreateReviewDto, ApiProperty, IsInt, IsNotEmpty, IsOptional, IsString, Min, ApiProperty (+22 more)
### Community 11 - "WikiController"
Cohesion: 0.21
Nodes (9): ApiNotFoundResponse, ApiOkResponse, ApiOperation, ApiTags, Controller, Get, Param, Query (+1 more)
Cohesion: 0.13
Nodes (13): ApiNotFoundResponse, ApiOkResponse, ApiOperation, ApiTags, Controller, Get, Param, Query (+5 more)
### Community 12 - "index.ts"
Cohesion: 0.06
@ -435,7 +436,7 @@ Cohesion: 0.19
Nodes (8): JwtAuthGuard, Injectable, ROLES_KEY, RequestWithUser, RolesGuard, Injectable, UserReqPayload, ScientificTermData
### Community 19 - "admin.controller.ts"
Cohesion: 0.35
Cohesion: 0.29
Nodes (12): ApplyGlobalMarginsDto, BulkPriceAdjustmentDto, ApiProperty, ApiPropertyOptional, IsArray, IsBoolean, IsIn, IsNumber (+4 more)
### Community 20 - "CreateVideoDto"
@ -552,7 +553,7 @@ Nodes (19): autoprefixer, devDependencies, autoprefixer, eslint, @eslint/js, glo
### Community 50 - "devDependencies"
Cohesion: 0.12
Nodes (17): eslint-config-next, devDependencies, eslint, eslint-config-next, jsdom, @testing-library/jest-dom, @testing-library/react, @types/node (+9 more)
Nodes (17): devDependencies, eslint, jsdom, @tailwindcss/postcss, @testing-library/jest-dom, @testing-library/react, @types/node, @types/react (+9 more)
### Community 51 - "BlogsController"
Cohesion: 0.07
@ -591,7 +592,7 @@ Cohesion: 0.06
Nodes (30): compilerOptions, allowSyntheticDefaultImports, baseUrl, declaration, emitDecoratorMetadata, esModuleInterop, experimentalDecorators, forceConsistentCasingInFileNames (+22 more)
### Community 60 - "CreateUserDto"
Cohesion: 0.23
Cohesion: 0.24
Nodes (10): CreateUserDto, ApiProperty, ApiPropertyOptional, IsEmail, IsNotEmpty, IsNumber, IsOptional, IsString (+2 more)
### Community 61 - "ProductPage.tsx"
@ -600,19 +601,19 @@ Nodes (19): ProductImageZoomModalProps, CalculatorState, GalleryMediaItem, ICON_
### Community 63 - "dependencies"
Cohesion: 0.09
Nodes (23): dependencies, bcryptjs, class-validator, compression, ioredis, @nestjs/common, @nestjs/jwt, @nestjs/passport (+15 more)
Nodes (23): dependencies, bcrypt, bcryptjs, class-validator, compression, ioredis, @nestjs/common, @nestjs/passport (+15 more)
### Community 64 - "compilerOptions"
Cohesion: 0.10
Nodes (20): compilerOptions, allowImportingTsExtensions, erasableSyntaxOnly, lib, module, moduleDetection, moduleResolution, noEmit (+12 more)
### Community 65 - "admin.service.ts"
Cohesion: 0.14
Nodes (15): CouponTargetInput, PaginationQuery, ProductDto, ApiPropertyOptional, IsArray, IsBoolean, IsNumber, IsOptional (+7 more)
Cohesion: 0.22
Nodes (8): CouponTargetInput, PaginationQuery, applyRounding(), calculateSellingPrice(), DEFAULT_PRICING_SETTINGS, PricingSettings, RoundingMode, CANONICAL_ALIASES
### Community 66 - "AdminQueryDto"
Cohesion: 0.13
Nodes (8): ApiQuery, Get, Query, AdminProductQueryDto, AdminQueryDto, ApiPropertyOptional, IsOptional, IsString
Cohesion: 0.18
Nodes (7): ApiQuery, Query, AdminProductQueryDto, AdminQueryDto, ApiPropertyOptional, IsOptional, IsString
### Community 67 - "ReportsController"
Cohesion: 0.14
@ -767,8 +768,8 @@ Cohesion: 0.37
Nodes (10): CreateHeroBannerDto, CreateSmartAdvisorRuleDto, CreateVetTestimonialDto, ApiProperty, ApiPropertyOptional, IsBoolean, IsNumber, IsOptional (+2 more)
### Community 107 - "PaginationDto"
Cohesion: 0.12
Nodes (15): AdminModule, Module, PaginationDto, SortOrder, ApiPropertyOptional, IsEnum, IsInt, IsOptional (+7 more)
Cohesion: 0.18
Nodes (11): AdminModule, Module, PaginationDto, SortOrder, ApiPropertyOptional, IsEnum, IsInt, IsOptional (+3 more)
### Community 108 - "PrismaService"
Cohesion: 0.06
@ -826,9 +827,9 @@ Nodes (9): compilerOptions, esModuleInterop, module, moduleResolution, skipLibCh
Cohesion: 0.20
Nodes (9): Compile and run the project, Deployment, Description, License, Project setup, Resources, Run tests, Stay in touch (+1 more)
### Community 122 - "AdminController"
Cohesion: 0.17
Nodes (12): AdminController, ApiBearerAuth, ApiOperation, ApiTags, Body, Controller, Delete, Param (+4 more)
### Community 122 - "AdminService"
Cohesion: 0.10
Nodes (12): AdminController, ApiBearerAuth, ApiOperation, ApiTags, Controller, Delete, Get, Param (+4 more)
### Community 123 - "UsersService"
Cohesion: 0.07
@ -850,6 +851,10 @@ Nodes (9): name, private, scripts, build, dev, lint, preview, type (+1 more)
Cohesion: 0.20
Nodes (9): Arch Linux, Contributors, Install, Known problems for variable version, License, Sahel-Font, To Do (variable), طریقه استفاده از نسخه متغیر variable (+1 more)
### Community 128 - "ProductDto"
Cohesion: 0.16
Nodes (7): ProductDto, ApiPropertyOptional, IsArray, IsBoolean, IsNumber, IsOptional, IsString
### Community 129 - "Reports.tsx"
Cohesion: 0.20
Nodes (7): BestSellerItem, CategoryDistItem, COLORS, CustomTooltipProps, ReportData, TopCouponItem, Reports
@ -1086,6 +1091,10 @@ Nodes (3): Select, SelectOption, SelectProps
Cohesion: 0.08
Nodes (37): AuthModal, B2BPortal, CartDrawer, ClientLayout(), LoginModal, AuthModal(), AuthModalProps, extractOtpFromText() (+29 more)
### Community 198 - "Body"
Cohesion: 0.21
Nodes (3): Body, Post, CouponInput
### Community 199 - "SmsLogQueryDto"
Cohesion: 0.25
Nodes (7): SmsLogQueryDto, ApiPropertyOptional, IsIn, IsNumber, IsOptional, IsString, Type
@ -1125,7 +1134,7 @@ Nodes (3): GET(), handleRevalidate(), POST()
## Knowledge Gaps
- **1347 isolated node(s):** `$schema`, `collection`, `sourceRoot`, `deleteOutDir`, `name` (+1342 more)
These have ≤1 connection - possible missing edges or undocumented components.
- **120 thin communities (<3 nodes) omitted from report** — run `graphify query` to explore isolated nodes.
- **119 thin communities (<3 nodes) omitted from report** — run `graphify query` to explore isolated nodes.
## Suggested Questions
_Questions this graph is uniquely positioned to answer:_
@ -1134,7 +1143,7 @@ _Questions this graph is uniquely positioned to answer:_
_High betweenness centrality (0.065) - this node is a cross-community bridge._
- **Why does `ApiResponse` connect `src/services/api.ts` to `BlogsController`, `PetsController`, `ProductsService`, `WikiController`, `auth.controller.ts`, `HomeController`, `UsersService`, `OrdersService`?**
_High betweenness centrality (0.057) - this node is a cross-community bridge._
- **Why does `PrismaService` connect `PrismaService` to `app.module.ts`, `CmsController`, `TicketsService`, `CreateReviewDto`, `DoctorQueryDto`, `HomeController`, `CreateVideoDto`, `BlogsService`, `menu.module.ts`, `auth.service.ts`, `MenuService`, `B2BService`, `FaqService`, `ZibalService`, `CategoriesController`, `MediaController`, `ZibalEBankService`, `BannersService`, `TestimonialsService`, `IngredientsService`, `SmartAdvisorService`, `MetricsController`, `WikiService`, `admin.service.ts`, `ReportsController`, `PetsController`, `zibal-ebank.service.ts`, `ProductsService`, `seo.module.ts`, `zibal.service.ts`, `OrdersService`, `BlogsController`, `cms.controller.ts`, `PaginationDto`, `PetsController`, `UsersService`?**
- **Why does `PrismaService` connect `PrismaService` to `app.module.ts`, `CmsController`, `TicketsService`, `CreateReviewDto`, `WikiController`, `DoctorQueryDto`, `HomeController`, `CreateVideoDto`, `BlogsService`, `menu.module.ts`, `auth.service.ts`, `MenuService`, `B2BService`, `FaqService`, `ZibalService`, `CategoriesController`, `MediaController`, `ZibalEBankService`, `BannersService`, `TestimonialsService`, `IngredientsService`, `SmartAdvisorService`, `MetricsController`, `WikiService`, `admin.service.ts`, `ReportsController`, `PetsController`, `zibal-ebank.service.ts`, `ProductsService`, `seo.module.ts`, `zibal.service.ts`, `OrdersService`, `BlogsController`, `cms.controller.ts`, `PaginationDto`, `PetsController`, `UsersService`?**
_High betweenness centrality (0.029) - this node is a cross-community bridge._
- **What connects `$schema`, `collection`, `sourceRoot` to the rest of the system?**
_1347 weakly-connected nodes found - possible documentation gaps or missing edges._

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -1,16 +1,16 @@
# Graph Report - canina (2026-09-02)
## Corpus Check
- 599 files · ~1,084,324 words
- 599 files · ~1,084,689 words
- Verdict: corpus is large enough that graph structure adds value.
## Summary
- 4208 nodes · 7643 edges · 333 communities (214 shown, 119 thin omitted)
- 4208 nodes · 7643 edges · 332 communities (212 shown, 120 thin omitted)
- Extraction: 96% EXTRACTED · 4% INFERRED · 0% AMBIGUOUS · INFERRED: 288 edges (avg confidence: 0.79)
- Token cost: 0 input · 0 output
## Graph Freshness
- Built from commit: `68840fbd`
- Built from commit: `ceaab10f`
- Run `git rev-parse HEAD` and compare to check if the graph is stale.
- Run `graphify update .` after code changes (no API cost).
@ -136,13 +136,13 @@
- compilerOptions
- compilerOptions
- backend/README.md
- AdminService
- AdminController
- UsersService
- Repository Map
- validate_integrity.js
- admin-panel/package.json
- Sahel-Font
- ProductDto
- AdminService
- Reports.tsx
- Sahel-Font
- Role & Core Objective
@ -211,7 +211,7 @@
- React + TypeScript + Vite
- Select.tsx
- userStore.ts
- Body
- @tailwindcss/postcss
- SmsLogQueryDto
- application/README.md
- deploy.sh
@ -326,7 +326,6 @@
- typescript-eslint
- @nestjs/swagger
- tailwindcss
- eslint-config-next
## God Nodes (most connected - your core abstractions)
1. `Roles()` - 106 edges
@ -353,11 +352,11 @@
backend/src/orders/orders.controller.ts → frontend/admin-panel/src/types/admin.ts
## Import Cycles
- 3-file cycle: `frontend/application/lib/services/api.ts -> frontend/application/lib/store/userStore.ts -> frontend/application/lib/store/cartStore.ts -> frontend/application/lib/services/api.ts`
- 3-file cycle: `frontend/application/lib/services/api.ts -> frontend/application/lib/store/userStore.ts -> frontend/application/lib/services/authService.ts -> frontend/application/lib/services/api.ts`
- 3-file cycle: `frontend/application/lib/services/api.ts -> frontend/application/lib/store/userStore.ts -> frontend/application/lib/store/cartStore.ts -> frontend/application/lib/services/api.ts`
- 4-file cycle: `frontend/application/lib/services/api.ts -> frontend/application/lib/store/userStore.ts -> frontend/application/lib/store/cartStore.ts -> frontend/application/lib/services/orderService.ts -> frontend/application/lib/services/api.ts`
## Communities (333 total, 119 thin omitted)
## Communities (332 total, 120 thin omitted)
### Community 0 - "Roles"
Cohesion: 0.24
@ -404,8 +403,8 @@ Cohesion: 0.07
Nodes (30): CreateReviewDto, ApiProperty, IsInt, IsNotEmpty, IsOptional, IsString, Min, ApiProperty (+22 more)
### Community 11 - "WikiController"
Cohesion: 0.13
Nodes (13): ApiNotFoundResponse, ApiOkResponse, ApiOperation, ApiTags, Controller, Get, Param, Query (+5 more)
Cohesion: 0.21
Nodes (9): ApiNotFoundResponse, ApiOkResponse, ApiOperation, ApiTags, Controller, Get, Param, Query (+1 more)
### Community 12 - "index.ts"
Cohesion: 0.06
@ -436,7 +435,7 @@ Cohesion: 0.19
Nodes (8): JwtAuthGuard, Injectable, ROLES_KEY, RequestWithUser, RolesGuard, Injectable, UserReqPayload, ScientificTermData
### Community 19 - "admin.controller.ts"
Cohesion: 0.29
Cohesion: 0.35
Nodes (12): ApplyGlobalMarginsDto, BulkPriceAdjustmentDto, ApiProperty, ApiPropertyOptional, IsArray, IsBoolean, IsIn, IsNumber (+4 more)
### Community 20 - "CreateVideoDto"
@ -553,7 +552,7 @@ Nodes (19): autoprefixer, devDependencies, autoprefixer, eslint, @eslint/js, glo
### Community 50 - "devDependencies"
Cohesion: 0.12
Nodes (17): devDependencies, eslint, jsdom, @tailwindcss/postcss, @testing-library/jest-dom, @testing-library/react, @types/node, @types/react (+9 more)
Nodes (17): eslint-config-next, devDependencies, eslint, eslint-config-next, jsdom, @testing-library/jest-dom, @testing-library/react, @types/node (+9 more)
### Community 51 - "BlogsController"
Cohesion: 0.07
@ -592,7 +591,7 @@ Cohesion: 0.06
Nodes (30): compilerOptions, allowSyntheticDefaultImports, baseUrl, declaration, emitDecoratorMetadata, esModuleInterop, experimentalDecorators, forceConsistentCasingInFileNames (+22 more)
### Community 60 - "CreateUserDto"
Cohesion: 0.24
Cohesion: 0.23
Nodes (10): CreateUserDto, ApiProperty, ApiPropertyOptional, IsEmail, IsNotEmpty, IsNumber, IsOptional, IsString (+2 more)
### Community 61 - "ProductPage.tsx"
@ -608,12 +607,12 @@ Cohesion: 0.10
Nodes (20): compilerOptions, allowImportingTsExtensions, erasableSyntaxOnly, lib, module, moduleDetection, moduleResolution, noEmit (+12 more)
### Community 65 - "admin.service.ts"
Cohesion: 0.22
Nodes (8): CouponTargetInput, PaginationQuery, applyRounding(), calculateSellingPrice(), DEFAULT_PRICING_SETTINGS, PricingSettings, RoundingMode, CANONICAL_ALIASES
Cohesion: 0.14
Nodes (15): CouponTargetInput, PaginationQuery, ProductDto, ApiPropertyOptional, IsArray, IsBoolean, IsNumber, IsOptional (+7 more)
### Community 66 - "AdminQueryDto"
Cohesion: 0.18
Nodes (7): ApiQuery, Query, AdminProductQueryDto, AdminQueryDto, ApiPropertyOptional, IsOptional, IsString
Cohesion: 0.13
Nodes (8): ApiQuery, Get, Query, AdminProductQueryDto, AdminQueryDto, ApiPropertyOptional, IsOptional, IsString
### Community 67 - "ReportsController"
Cohesion: 0.14
@ -768,8 +767,8 @@ Cohesion: 0.37
Nodes (10): CreateHeroBannerDto, CreateSmartAdvisorRuleDto, CreateVetTestimonialDto, ApiProperty, ApiPropertyOptional, IsBoolean, IsNumber, IsOptional (+2 more)
### Community 107 - "PaginationDto"
Cohesion: 0.18
Nodes (11): AdminModule, Module, PaginationDto, SortOrder, ApiPropertyOptional, IsEnum, IsInt, IsOptional (+3 more)
Cohesion: 0.12
Nodes (15): AdminModule, Module, PaginationDto, SortOrder, ApiPropertyOptional, IsEnum, IsInt, IsOptional (+7 more)
### Community 108 - "PrismaService"
Cohesion: 0.06
@ -827,9 +826,9 @@ Nodes (9): compilerOptions, esModuleInterop, module, moduleResolution, skipLibCh
Cohesion: 0.20
Nodes (9): Compile and run the project, Deployment, Description, License, Project setup, Resources, Run tests, Stay in touch (+1 more)
### Community 122 - "AdminService"
Cohesion: 0.10
Nodes (12): AdminController, ApiBearerAuth, ApiOperation, ApiTags, Controller, Delete, Get, Param (+4 more)
### Community 122 - "AdminController"
Cohesion: 0.17
Nodes (12): AdminController, ApiBearerAuth, ApiOperation, ApiTags, Body, Controller, Delete, Param (+4 more)
### Community 123 - "UsersService"
Cohesion: 0.07
@ -851,10 +850,6 @@ Nodes (9): name, private, scripts, build, dev, lint, preview, type (+1 more)
Cohesion: 0.20
Nodes (9): Arch Linux, Contributors, Install, Known problems for variable version, License, Sahel-Font, To Do (variable), طریقه استفاده از نسخه متغیر variable (+1 more)
### Community 128 - "ProductDto"
Cohesion: 0.16
Nodes (7): ProductDto, ApiPropertyOptional, IsArray, IsBoolean, IsNumber, IsOptional, IsString
### Community 129 - "Reports.tsx"
Cohesion: 0.20
Nodes (7): BestSellerItem, CategoryDistItem, COLORS, CustomTooltipProps, ReportData, TopCouponItem, Reports
@ -1091,10 +1086,6 @@ Nodes (3): Select, SelectOption, SelectProps
Cohesion: 0.08
Nodes (37): AuthModal, B2BPortal, CartDrawer, ClientLayout(), LoginModal, AuthModal(), AuthModalProps, extractOtpFromText() (+29 more)
### Community 198 - "Body"
Cohesion: 0.21
Nodes (3): Body, Post, CouponInput
### Community 199 - "SmsLogQueryDto"
Cohesion: 0.25
Nodes (7): SmsLogQueryDto, ApiPropertyOptional, IsIn, IsNumber, IsOptional, IsString, Type
@ -1134,7 +1125,7 @@ Nodes (3): GET(), handleRevalidate(), POST()
## Knowledge Gaps
- **1347 isolated node(s):** `$schema`, `collection`, `sourceRoot`, `deleteOutDir`, `name` (+1342 more)
These have ≤1 connection - possible missing edges or undocumented components.
- **119 thin communities (<3 nodes) omitted from report** — run `graphify query` to explore isolated nodes.
- **120 thin communities (<3 nodes) omitted from report** — run `graphify query` to explore isolated nodes.
## Suggested Questions
_Questions this graph is uniquely positioned to answer:_
@ -1143,7 +1134,7 @@ _Questions this graph is uniquely positioned to answer:_
_High betweenness centrality (0.065) - this node is a cross-community bridge._
- **Why does `ApiResponse` connect `src/services/api.ts` to `BlogsController`, `PetsController`, `ProductsService`, `WikiController`, `auth.controller.ts`, `HomeController`, `UsersService`, `OrdersService`?**
_High betweenness centrality (0.057) - this node is a cross-community bridge._
- **Why does `PrismaService` connect `PrismaService` to `app.module.ts`, `CmsController`, `TicketsService`, `CreateReviewDto`, `WikiController`, `DoctorQueryDto`, `HomeController`, `CreateVideoDto`, `BlogsService`, `menu.module.ts`, `auth.service.ts`, `MenuService`, `B2BService`, `FaqService`, `ZibalService`, `CategoriesController`, `MediaController`, `ZibalEBankService`, `BannersService`, `TestimonialsService`, `IngredientsService`, `SmartAdvisorService`, `MetricsController`, `WikiService`, `admin.service.ts`, `ReportsController`, `PetsController`, `zibal-ebank.service.ts`, `ProductsService`, `seo.module.ts`, `zibal.service.ts`, `OrdersService`, `BlogsController`, `cms.controller.ts`, `PaginationDto`, `PetsController`, `UsersService`?**
- **Why does `PrismaService` connect `PrismaService` to `app.module.ts`, `CmsController`, `TicketsService`, `CreateReviewDto`, `DoctorQueryDto`, `HomeController`, `CreateVideoDto`, `BlogsService`, `menu.module.ts`, `auth.service.ts`, `MenuService`, `B2BService`, `FaqService`, `ZibalService`, `CategoriesController`, `MediaController`, `ZibalEBankService`, `BannersService`, `TestimonialsService`, `IngredientsService`, `SmartAdvisorService`, `MetricsController`, `WikiService`, `admin.service.ts`, `ReportsController`, `PetsController`, `zibal-ebank.service.ts`, `ProductsService`, `seo.module.ts`, `zibal.service.ts`, `OrdersService`, `BlogsController`, `cms.controller.ts`, `PaginationDto`, `PetsController`, `UsersService`?**
_High betweenness centrality (0.029) - this node is a cross-community bridge._
- **What connects `$schema`, `collection`, `sourceRoot` to the rest of the system?**
_1347 weakly-connected nodes found - possible documentation gaps or missing edges._

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 it is too large Load Diff

File diff suppressed because it is too large Load Diff