import { IReportContentType, User, IIssueColumnName, ISearchVO } from '@/common/types'; import { IBurndownChartType } from '@/components/charts/burn-down'; import { IPieChartType } from '@/components/charts/pie-chart'; import { IUnit } from '@/components/charts/version-report/search'; import { IChartType, IChartUnit } from '@/routes/ReportHost/custom-report/components/Chart/utils'; export declare type IChartCode = 'burn_down_report' | 'sprint_report' | 'cumulative_flow_diagram' | 'pie_chart' | 'version_chart' | 'epic_chart' | 'version_burn_down_report' | 'epic_burn_down_report' | 'velocity_chart'; interface IBaseReportBlock { key: string; title: string; type: IReportContentType; collapse: boolean; } export declare type BurnDownSearchVO = { projectId: string; type?: IBurndownChartType; sprintId?: string; currentSprint?: boolean; displayNonWorkingDay: boolean; onlyStory: boolean; assigneeId?: string; quickFilterIds: string[]; personalFilterIds: string[]; currentSearchVO?: ISearchVO; }; export declare type SprintSearchVO = { projectId: string; sprintId?: string; currentSprint?: boolean; displayNonWorkingDay: boolean; }; export declare type AccumulationSearchVO = { projectId: string; boardId: string; startDate: string; endDate: string; quickFilterIds?: string[]; }; export declare type PieSearchVO = { sprintId?: string; versionId?: string; statusId?: string; projectId: string; organizationId: string; fieldName: IPieChartType; }; export declare type VersionReportSearchVO = { versionId: string; type: IUnit; projectId: string; }; export declare type EpicReportSearchVO = { epicId: string; type: IUnit; projectId: string; }; export declare type VersionBurndownSearchVO = { type: 'version'; versionId: string; calibrationSprint: boolean; projectId: string; }; export declare type EpicBurndownSearchVO = { type: 'epic'; epicId: string; calibrationSprint: boolean; projectId: string; }; export declare type IterationSpeedSearchVO = { type: IUnit; projectId: string; }; export declare type CustomReportSearchVO = { projectId?: undefined; chartType?: IChartType; statisticsType?: IChartUnit; analysisField?: string; comparedField?: string; analysisFieldPredefined?: boolean; comparedFieldPredefined?: boolean; searchVO?: ISearchVO; currentSearchVO?: ISearchVO; searchJson?: string; }; export declare type ChartSearchVO = BurnDownSearchVO | SprintSearchVO | AccumulationSearchVO | PieSearchVO | VersionReportSearchVO | EpicReportSearchVO | VersionBurndownSearchVO | EpicBurndownSearchVO | IterationSpeedSearchVO | CustomReportSearchVO; export interface IReportChartBlock extends IBaseReportBlock { type: 'chart'; chartCode: IChartCode; chartSearchVO: ChartSearchVO; } export interface SearchVO { advancedSearchArgs?: { issueTypeId?: string[]; reporterIds?: string[]; statusId?: string[]; priorityId?: string[]; }; otherArgs?: { assigneeId?: string[]; issueIds?: string[]; component?: string[]; epic?: string[]; feature?: string[]; label?: string[]; sprint?: string[]; summary?: string[]; version?: string[]; withChildren?: boolean; }; searchArgs?: { createStartDate?: string; createEndDate?: string; updateStartDate?: string; updateEndDate?: string; }; quickFilterIds?: string[]; contents?: string[]; } export interface IReportListBlock extends IBaseReportBlock { type: 'static_list' | 'dynamic_list'; colList: IIssueColumnName[]; searchVO: SearchVO; } export interface IReportTextBlock extends IBaseReportBlock { type: 'text'; content: string; } export declare type IReportBlock = IReportTextBlock | IReportListBlock | IReportChartBlock; export interface IProjectReport { id: string; title: string; description?: string; ccList: User[]; receiverList: User[]; reportUnitList: IReportBlock[]; objectVersionNumber: number; } declare class ProjectReportStore { dirty: boolean; blockList: IReportBlock[]; baseInfo: IProjectReport | null; setDirty(dirty: boolean): void; addBlock(block: IReportBlock): void; updateBlock(index: number, block: IReportBlock): void; removeBlock(index: number): void; setReportData(reportData: IProjectReport): void; setObjectVersionNumber(objectVersionNumber: number): void; sortBlock(sourceIndex: number, destinationIndex: number): void; handleCollapseBlock(collapse: boolean, block: IReportBlock): void; get hasCollapse(): boolean; collapseAll(collapse: boolean): void; } export default ProjectReportStore;