vcomply-workflow-engine 7.4.6 → 7.4.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -6,6 +6,7 @@ import { AuthService } from '../workflow-services/auth.service';
6
6
  import { FrequencyBulkService } from '../workflow-services/frequency.service';
7
7
  import { ResponsibilityService } from '../workflow-services/responsibility.service';
8
8
  import { IframeService } from '../services/iframe.service';
9
+ import { BulkUploadService } from '../services/bulk-upload.service';
9
10
  import * as i0 from "@angular/core";
10
11
  export declare class AddMultipleResponsibilityWithTabComponent implements OnInit {
11
12
  private riskService;
@@ -14,6 +15,7 @@ export declare class AddMultipleResponsibilityWithTabComponent implements OnInit
14
15
  private frequencyService;
15
16
  private snackBar;
16
17
  private iframeService;
18
+ private bulkUploadService;
17
19
  pickerChanged: EventEmitter<any>;
18
20
  populateOption: EventEmitter<any>;
19
21
  closeWorkflow: EventEmitter<any>;
@@ -118,12 +120,13 @@ export declare class AddMultipleResponsibilityWithTabComponent implements OnInit
118
120
  };
119
121
  isDayInvalid: boolean;
120
122
  isDateFormatInvalid: boolean;
121
- constructor(riskService: AddRiskService, responsibilityService: ResponsibilityService, authService: AuthService, frequencyService: FrequencyBulkService, snackBar: SnackBarService, iframeService: IframeService);
123
+ constructor(riskService: AddRiskService, responsibilityService: ResponsibilityService, authService: AuthService, frequencyService: FrequencyBulkService, snackBar: SnackBarService, iframeService: IframeService, bulkUploadService: BulkUploadService);
122
124
  ngOnChanges(changes: SimpleChanges): void;
123
125
  ngOnInit(): void;
124
126
  triggerBrowseFile(): void;
125
127
  getUserDetails(): void;
126
128
  uploadedFile(event: any, tabType?: any): void;
129
+ blockUploadForColumnError(columnError: 'ok' | 'missing' | 'extra' | string): boolean;
127
130
  /**
128
131
  * It takes a worksheet and a sheet name, and then it sets the data for different tabs.
129
132
  * @param ws - XLSX.WorkSheet, sheet: string
@@ -220,11 +223,18 @@ export declare class AddMultipleResponsibilityWithTabComponent implements OnInit
220
223
  /**
221
224
  * Adds dropdown-list checks on top of existing row validation.
222
225
  * Empty optional cells are valid. Frequency / due date / due time are skipped for ongoing.
226
+ * Warning and info issues are shown in preview but do not make the row invalid.
223
227
  */
224
228
  withDropdownValidation(obj: any, tabType: string, isProgram: boolean, hasExtendedFrequencyColumns?: boolean): any;
225
229
  applyDropdownValidation(obj: any, tabType: string, isProgram: boolean, hasExtendedFrequencyColumns?: boolean): void;
226
230
  getTemplateListNames(list: any[] | undefined, key: string): string[];
227
231
  getProgramCategoryNames(): string[];
232
+ getProgramCategoryNamesForProgram(programName: any): string[];
233
+ setFieldIssue(obj: any, field: string, severity: string, message: string): void;
234
+ hasBlockingFieldIssues(obj: any): boolean;
235
+ samePerson(left: any, right: any): boolean;
236
+ isValidFormatUrl(value: any): boolean;
237
+ applySheetFieldMessages(obj: any, tabType: string, isProgram: boolean, hasExtendedFrequencyColumns?: boolean): void;
228
238
  /**
229
239
  * Entrusted By in the xlsx dropdown is the people list in `Name (email)` form
230
240
  * (same source as Entrusted To / Reviewer), not the assignor name-only column.
@@ -237,6 +247,13 @@ export declare class AddMultipleResponsibilityWithTabComponent implements OnInit
237
247
  isInDropdownList(value: any, options: string[]): boolean;
238
248
  isValidDropdownDay(value: any): boolean;
239
249
  isValidDropdownMonth(value: any): boolean;
250
+ isValidDueDateMonth(value: any): boolean;
251
+ getDueDateDayMax(frequency: any): number;
252
+ /**
253
+ * G2 / G3: DD-01, DD-02, DD-03, DM-01, DM-02.
254
+ * Blank day and month together stay valid. Warning/info are not used here.
255
+ */
256
+ applyDueDateDayMonthMessages(obj: any): void;
240
257
  isValidDueTime(dueTime: any, hasExtendedFrequencyColumns?: boolean): boolean;
241
258
  /**
242
259
  * Optional field. When filled, the value must be a non-negative whole number.
@@ -1,13 +1,66 @@
1
1
  export declare const RISK_CLASS_LIST: string[];
2
+ export declare const VALIDATION_SEVERITY: {
3
+ readonly ERROR: "error";
4
+ readonly WARNING: "warning";
5
+ readonly INFO: "info";
6
+ };
7
+ export declare const NON_BLOCKING_DROPDOWN_FIELDS: string[];
2
8
  export declare const YES_NO_DROPDOWN_LIST: string[];
3
9
  export declare const PROGRAM_TYPE_DROPDOWN_LIST: string[];
4
10
  export declare const ASSIGNEE_TYPE_DROPDOWN_LIST: string[];
5
11
  export declare const RC_TYPE_DROPDOWN_LIST: string[];
6
12
  export declare const REVIEWER_TYPE_DROPDOWN_LIST: string[];
7
13
  export declare const FREQUENCY_DROPDOWN_LIST: string[];
14
+ /** Due Date (Day) max is 7 for these frequencies (DD-02). */
15
+ export declare const WEEKDAY_FREQUENCIES: string[];
16
+ export declare const SHORT_MONTH_NAMES: string[];
8
17
  export declare const FULL_MONTH_NAMES: string[];
18
+ export declare const FILE_VALIDATION_MESSAGES: {
19
+ HEADERS_MISSING: string;
20
+ EXTRA_COLUMNS: string;
21
+ };
22
+ export declare const REQUIRED_TEMPLATE_HEADERS: string[];
23
+ export declare const REQUIRED_FREQUENCY_HEADERS: string[];
24
+ export declare const REQUIRED_ASSIGNEE_HEADERS: string[];
25
+ export declare const ALLOWED_TEMPLATE_HEADERS: string[];
9
26
  export declare const VALIDATION_MESSAGES: {
10
27
  DROPDOWN: string;
28
+ FILE_HEADERS_MISSING: string;
29
+ FILE_EXTRA_COLUMNS: string;
30
+ RESPONSIBILITY_NAME_REQUIRED: string;
31
+ RESPONSIBILITY_NAME_WHITESPACE: string;
32
+ PROGRAM_CATEGORY_MISMATCH: string;
33
+ PROGRAM_CATEGORY_WITHOUT_PROGRAM: string;
34
+ PROGRAM_TYPE_WITHOUT_PROGRAM: string;
35
+ ENTRUSTED_BY_INVALID: string;
36
+ ENTRUSTED_BY_INACTIVE: string;
37
+ ASSIGNEE_REQUIRED: string;
38
+ ASSIGNEE_INVALID: string;
39
+ ASSIGNEE_INACTIVE: string;
40
+ ASSIGNEE_TYPE_INVALID: string;
41
+ GROUP_ALL_ANY_BLANK: string;
42
+ KEY_RESPONSIBILITY_INVALID: string;
43
+ FREQUENCY_REQUIRED: string;
44
+ DUE_DATE_DAY_NOT_NUMBER: string;
45
+ DUE_DATE_DAY_OUT_OF_RANGE: string;
46
+ DUE_DATE_REQUIRED: string;
47
+ DUE_DATE_MONTH_INVALID: string;
48
+ DUE_TIME_BLANK: string;
49
+ RC_TYPE_WITHOUT_NAME: string;
50
+ RC_INACTIVE: string;
51
+ FORMAT_LINK_WITHOUT_YES: string;
52
+ FORMAT_INVALID_URL: string;
53
+ REVIEWER_INACTIVE: string;
54
+ REVIEW_WINDOW_WITHOUT_REVIEWER: string;
55
+ OVERSIGHT_DUPLICATE_ASSIGNEE: string;
56
+ OVERSIGHT_DUPLICATE_ASSIGNOR: string;
57
+ OVERSIGHT_INACTIVE: string;
58
+ COLLABORATOR_INACTIVE: string;
59
+ COLLABORATOR_GROUP: string;
60
+ ONE_TIME_LIFECYCLE: string;
61
+ ENDS_AFTER_ONE_OCCURRENCE: string;
62
+ USER_NOT_IN_PROGRAM: string;
63
+ PAST_DUE_DATE: string;
11
64
  RISK_CLASS: string;
12
65
  DAY: string;
13
66
  DATE_FORMAT: string;
@@ -22,3 +75,4 @@ export declare const VALIDATION_MESSAGES: {
22
75
  ENDS_BY_DATE_PAST: string;
23
76
  ENDS_BY_DATE_CONFLICT: string;
24
77
  };
78
+ export declare function dueDateDayOutOfRangeMessage(frequency: string): string;
@@ -4,6 +4,26 @@ export declare class BulkUploadService {
4
4
  hasDataInList(data: any, dataStartIndex: number): boolean;
5
5
  checkEmptyFile(data: any): boolean;
6
6
  checkCorrectFile(data: any, headerIndex: number): boolean;
7
+ getHeaderRows(data: any): {
8
+ header: any[];
9
+ subHeading: any[];
10
+ };
11
+ /**
12
+ * F-02: required header missing or renamed.
13
+ * F-03: extra columns inserted.
14
+ */
15
+ validateResponsibilityHeaders(sheets: Array<{
16
+ header?: any[];
17
+ subHeading?: any[];
18
+ sheet?: string;
19
+ }>): 'ok' | 'missing' | 'extra';
20
+ validateSheetHeaders(header?: any[], subHeading?: any[], sheet?: string): 'ok' | 'missing' | 'extra';
21
+ hasProgramColumns(header?: any[]): boolean;
22
+ findLabelIndex(header: any[] | undefined, subHeading: any[] | undefined, needle: string): number;
23
+ getExpectedLastHeaderIndex(header?: any[], subHeading?: any[], sheet?: string): number;
24
+ getMaxHeaderIndex(header?: any[], subHeading?: any[], sheet?: string): number;
25
+ normalizeHeaderLabel(value: any): string;
26
+ lastFilledIndex(row?: any[]): number;
7
27
  static ɵfac: i0.ɵɵFactoryDeclaration<BulkUploadService, never>;
8
28
  static ɵprov: i0.ɵɵInjectableDeclaration<BulkUploadService>;
9
29
  }
@@ -1,22 +1,11 @@
1
1
  import { EventEmitter } from '@angular/core';
2
2
  import * as i0 from "@angular/core";
3
3
  export declare class BulkResponsibilityViewComponent {
4
- VALIDATION_MESSAGES: {
5
- DROPDOWN: string;
6
- RISK_CLASS: string;
7
- DAY: string;
8
- DATE_FORMAT: string;
9
- DUE_DATE: string;
10
- DUE_TIME: string;
11
- ENDS_AFTER_OCCURRENCES_GREATER_THAN_ZERO: string;
12
- ENDS_AFTER_OCCURRENCES_NUMERIC: string;
13
- WHOLE_NUMBER_NON_NEGATIVE: string;
14
- POSITIVE_NUMBER: string;
15
- ENDS_BY_DATE_INVALID_VALUE: string;
16
- ENDS_BY_DATE_INCOMPLETE: string;
17
- ENDS_BY_DATE_PAST: string;
18
- ENDS_BY_DATE_CONFLICT: string;
19
- };
4
+ cellSeverity(report: any, field: string): string;
5
+ cellMessage(report: any, field: string): string;
6
+ cellClass(report: any, field: string): string;
7
+ rowIndexClass(report: any): string;
8
+ isUploadable(report: any): boolean;
20
9
  responsibilityBulkUpload: any;
21
10
  fileName: any;
22
11
  defaultOwner: any;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "vcomply-workflow-engine",
3
- "version": "7.4.6",
3
+ "version": "7.4.8",
4
4
  "peerDependencies": {
5
5
  "@angular/common": " 12.x || 13.x || 14.x || 15.x || 16.x || 17.x || 18.x || 19.x ",
6
6
  "@angular/core": " 12.x || 13.x || 14.x || 15.x || 16.x || 17.x || 18.x || 19.x "