Add deal co-assignees and saved filters on people/pipeline lists.
Deals keep a primary owner plus shared assignees with matching visibility; Contacts and Pipeline can save and reuse filter presets.
This commit is contained in:
@@ -10,6 +10,8 @@ export type PipelineDeal = {
|
||||
/** شناسه مرحله فعلی — هنگام جابهجایی بهروز میشود */
|
||||
stageId?: string;
|
||||
currencyUnit?: string;
|
||||
/** نام مسئولان برای نمایش روی کارت */
|
||||
assigneeNames?: string[];
|
||||
};
|
||||
|
||||
export type PipelineUiCopy = {
|
||||
@@ -136,6 +138,8 @@ export function mapBoardToStages(
|
||||
createdAt: string;
|
||||
person: { fullName: string } | null;
|
||||
company: { name: string } | null;
|
||||
owner?: { id: string; fullName: string } | null;
|
||||
assignees?: Array<{ id: string; fullName: string }>;
|
||||
}>;
|
||||
}>;
|
||||
},
|
||||
@@ -164,6 +168,12 @@ export function mapBoardToStages(
|
||||
deal.person?.fullName ||
|
||||
'';
|
||||
const dateIso = deal.expectedCloseAt || deal.createdAt;
|
||||
const assigneeNames = [
|
||||
...(deal.owner?.fullName ? [deal.owner.fullName] : []),
|
||||
...(deal.assignees ?? [])
|
||||
.map((a) => a.fullName)
|
||||
.filter((n) => n && n !== deal.owner?.fullName),
|
||||
];
|
||||
return {
|
||||
id: deal.id,
|
||||
title: deal.title,
|
||||
@@ -175,6 +185,7 @@ export function mapBoardToStages(
|
||||
),
|
||||
stageId: deal.stageId,
|
||||
currencyUnit: currencyUnitLabel(deal.currency),
|
||||
assigneeNames,
|
||||
};
|
||||
}),
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user