@sunbird-cb/cbp-ai 0.1.100 → 0.1.102
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.
- package/esm2022/lib/components/dashboard/dashboard.component.mjs +25 -21
- package/esm2022/lib/components/role-mapping-generation/role-mapping-generation.component.mjs +26 -35
- package/esm2022/lib/modules/shared/services/shared.service.mjs +2 -2
- package/fesm2022/sunbird-cb-cbp-ai.mjs +50 -55
- package/fesm2022/sunbird-cb-cbp-ai.mjs.map +1 -1
- package/lib/components/dashboard/dashboard.component.d.ts +2 -0
- package/lib/components/dashboard/dashboard.component.d.ts.map +1 -1
- package/lib/components/role-mapping-generation/role-mapping-generation.component.d.ts +3 -0
- package/lib/components/role-mapping-generation/role-mapping-generation.component.d.ts.map +1 -1
- package/package.json +1 -1
- package/sunbird-cb-cbp-ai-0.1.102.tgz +0 -0
|
@@ -880,7 +880,7 @@ class SharedService {
|
|
|
880
880
|
getCenterBasedDepartment(state_center_id, options) {
|
|
881
881
|
const headers = this.headers;
|
|
882
882
|
let params = new HttpParams()
|
|
883
|
-
.set('limit', String(options?.limit !== undefined ? options.limit :
|
|
883
|
+
.set('limit', String(options?.limit !== undefined ? options.limit : 50))
|
|
884
884
|
.set('offset', String(options?.offset !== undefined ? options.offset : 0))
|
|
885
885
|
.set('sub_org_type', 'ministry');
|
|
886
886
|
if (options?.query) {
|
|
@@ -7798,6 +7798,7 @@ class DashboardComponent {
|
|
|
7798
7798
|
this.departmentPanelOpen = false;
|
|
7799
7799
|
this.filteredList = [];
|
|
7800
7800
|
this.filteredDepartmentList = [];
|
|
7801
|
+
this.pinnedDepartmentOptions = [];
|
|
7801
7802
|
this.ministryData = [];
|
|
7802
7803
|
this.ministryFullData = [];
|
|
7803
7804
|
this.departmentData = [];
|
|
@@ -7962,7 +7963,7 @@ class DashboardComponent {
|
|
|
7962
7963
|
}
|
|
7963
7964
|
});
|
|
7964
7965
|
this.filteredDepartmentList = reset ? items : [...this.filteredDepartmentList, ...items];
|
|
7965
|
-
|
|
7966
|
+
this.ensureSelectedDepartmentOptions();
|
|
7966
7967
|
if (reset && !items.length && !this.departmentSearchQuery && this.selectedMinistryType === 'ministry') {
|
|
7967
7968
|
this.snackBar.open('No Department Found for Selected Ministry', 'X', {
|
|
7968
7969
|
duration: 3000,
|
|
@@ -7978,23 +7979,26 @@ class DashboardComponent {
|
|
|
7978
7979
|
}
|
|
7979
7980
|
});
|
|
7980
7981
|
}
|
|
7981
|
-
//
|
|
7982
|
-
//
|
|
7983
|
-
//
|
|
7984
|
-
|
|
7985
|
-
|
|
7986
|
-
|
|
7987
|
-
|
|
7988
|
-
|
|
7989
|
-
|
|
7990
|
-
|
|
7991
|
-
|
|
7992
|
-
|
|
7993
|
-
|
|
7994
|
-
|
|
7995
|
-
|
|
7996
|
-
|
|
7997
|
-
|
|
7982
|
+
// mat-select only displays selections while a mat-option with that value is
|
|
7983
|
+
// rendered; selected departments missing from the current search/page from
|
|
7984
|
+
// the server are rendered as hidden options instead of in the list
|
|
7985
|
+
ensureSelectedDepartmentOptions() {
|
|
7986
|
+
const value = this.filtersForm?.get('departments')?.value;
|
|
7987
|
+
const selectedIds = Array.isArray(value) ? value : (value ? [value] : []);
|
|
7988
|
+
const pinned = [];
|
|
7989
|
+
selectedIds.forEach((id) => {
|
|
7990
|
+
if (!id || this.filteredDepartmentList.some(d => d?.identifier === id)) {
|
|
7991
|
+
return;
|
|
7992
|
+
}
|
|
7993
|
+
const selected = this.departmentData.find(d => d?.identifier === id)
|
|
7994
|
+
|| (this.cbpFinalObj?.departments === id && this.cbpFinalObj?.department_name
|
|
7995
|
+
? { identifier: id, orgName: this.cbpFinalObj.department_name } : null);
|
|
7996
|
+
if (selected) {
|
|
7997
|
+
pinned.push(selected);
|
|
7998
|
+
}
|
|
7999
|
+
});
|
|
8000
|
+
this.pinnedDepartmentOptions = pinned;
|
|
8001
|
+
}
|
|
7998
8002
|
filterData(event) {
|
|
7999
8003
|
if (event && event.target && event.target.value) {
|
|
8000
8004
|
const s = event.target.value.toLowerCase();
|
|
@@ -8093,11 +8097,11 @@ class DashboardComponent {
|
|
|
8093
8097
|
this.router.navigate(['/ai/initial']);
|
|
8094
8098
|
}
|
|
8095
8099
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DashboardComponent, deps: [{ token: i2.FormBuilder }, { token: SharedService }, { token: i3$1.MatSnackBar }, { token: i3.Router }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
8096
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.12", type: DashboardComponent, selector: "app-dashboard", viewQueries: [{ propertyName: "departmentSelect", first: true, predicate: ["departmentSelect"], descendants: true }], ngImport: i0, template: "<div class=\"dashboard-wrapper\">\n <div class=\"header\">\n <div class=\"sub-heading mt-10 mb-10 cursor-pointer\">\n <p (click)=\"routeToInitial()\"><mat-icon style=\"vertical-align: middle;\">arrow_back</mat-icon><span\n class=\"pl-10\">Back to Role Mapping Generation</span></p>\n </div>\n\n </div>\n <div class=\"dashboard-container\">\n\n <!-- FILTERS SECTION -->\n <form [formGroup]=\"filtersForm\" class=\"filters-form\">\n\n <mat-card class=\"filters-card\">\n <div class=\"filters-header\">\n <mat-icon>filter_list</mat-icon>\n <span>Filters</span>\n </div>\n\n <div class=\"filters-row\">\n <div>\n <label>Centre / State </label>\n <!-- Centre / State -->\n <mat-form-field appearance=\"fill\"\n style=\"background: white; border-radius: 25px; padding: 0 12px; border: 1px solid #ccc;width: 100%;\">\n\n <mat-select formControlName=\"centreState\" [disabled]=\"!isSuperAdmin\"\n (selectionChange)=\"onMinistryTypeChange($event)\">\n <mat-option value=\"\">Select Center/State</mat-option>\n <mat-option value=\"ministry\">Center</mat-option>\n <mat-option value=\"state\">State</mat-option>\n </mat-select>\n </mat-form-field>\n </div>\n <div>\n <label>{{selectedMinistryType === 'ministry' ? 'Ministry':'State'}} </label>\n <!-- Centre / State -->\n <mat-form-field appearance=\"fill\"\n style=\"background: white; border-radius: 25px; padding: 0 12px; border: 1px solid #ccc;width: 100%;\">\n <mat-select panelClass=\"select-with-search\" [disabled]=\"!isSuperAdmin\" multiple\n [placeholder]=\"selectedMinistryType === 'ministry' ? 'Select Ministry/ Department':'Select State'\"\n (selectionChange)=\"onMinistryChange($event)\" formControlName=\"ministries\"\n style=\"border-radius: 25px; background: white; width:100%\"\n (openedChange)=\"onOpened($event)\">\n <div class=\"search-wrapper\" *ngIf=\"panelOpen\">\n <input type=\"text\" placeholder=\"Search...\" (input)=\"filterData($event)\"\n class=\"search-input\" (keydown.space)=\"$event.stopPropagation()\"\n (keydown)=\"$event.stopPropagation()\">\n </div>\n <!-- [selected]=\"selectedMinistryId === item?.identifier\" -->\n <mat-option [value]=\"item?.identifier\" *ngFor=\"let item of filteredList\"\n >{{item?.orgName}}</mat-option>\n </mat-select>\n </mat-form-field>\n </div>\n <div>\n <label>Department</label>\n <!-- Centre / State -->\n <mat-form-field appearance=\"fill\"\n style=\"background: white; border-radius: 25px; padding: 0 12px;border: 1px solid #ccc;\">\n <mat-select #departmentSelect panelClass=\"select-with-search\" placeholder=\"Select Department\"\n [disabled]=\"!isSuperAdmin\" multiple formControlName=\"departments\"\n style=\"border-radius: 25px; background: white;\" (selectionChange)=\"onDepartmentChange()\"\n (openedChange)=\"onOpenedDepartment($event)\">\n <div class=\"search-wrapper\" *ngIf=\"departmentPanelOpen\">\n <input type=\"text\" placeholder=\"Search...\" (input)=\"filterDepartmentData($event)\"\n class=\"search-input\" (keydown.space)=\"$event.stopPropagation()\"\n (keydown)=\"$event.stopPropagation()\">\n </div>\n <mat-option [value]=\"item?.identifier\"\n *ngFor=\"let item of filteredDepartmentList\">{{item?.orgName}}</mat-option>\n <mat-option disabled *ngIf=\"departmentLoading\">Loading...</mat-option>\n <mat-option disabled\n *ngIf=\"!departmentLoading && !filteredDepartmentList?.length\">No department found</mat-option>\n\n </mat-select>\n </mat-form-field>\n </div>\n\n <!-- Date Range -->\n <div>\n <label>Date Range </label>\n <mat-form-field appearance=\"outline\">\n\n <input matInput ngxDaterangepickerMd formControlName=\"dateRange\" style=\"margin:10px\"\n placeholder=\"Select date range\" [autoApply]=\"true\" [linkedCalendars]=\"true\"\n [locale]=\"{ format: 'DD MMM YYYY' }\" />\n </mat-form-field>\n </div>\n\n\n </div>\n </mat-card>\n </form>\n\n <!-- OVERVIEW METRICS -->\n <h2 class=\"section-title\">\n <mat-icon>dashboard</mat-icon>\n Overview Metrics\n </h2>\n\n <div class=\"card-grid\">\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">States/Ministries which generated Role Mapping</p>\n <h2>{{this.dashboardData?.ministry_count}}</h2>\n <!-- <p class=\"card-subtitle\">At least 1 designation/role mapping</p> -->\n </div>\n <mat-icon class=\"icon primary\">public</mat-icon>\n </div>\n </mat-card>\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Departments which generated Role Mapping</p>\n <h2>{{this.dashboardData?.department_count}}</h2>\n <!-- <p class=\"card-subtitle\">At least 1 designation/role mapping</p> -->\n </div>\n <mat-icon class=\"icon teal\">apartment</mat-icon>\n </div>\n </mat-card>\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Total Capacity Building Plans Created</p>\n <h2>{{this.dashboardData?.total_cbp_plan_count}}</h2>\n </div>\n <mat-icon class=\"icon green\">description</mat-icon>\n </div>\n </mat-card>\n\n </div>\n\n <!-- COMPETENCIES -->\n <h2 class=\"section-title\">\n <mat-icon>psychology</mat-icon>\n Competencies Recommended\n </h2>\n\n <div class=\"card-grid\">\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Behavioral Competencies</p>\n <h2>{{this.dashboardData?.behavioral_competencies_count}}</h2>\n </div>\n <mat-icon class=\"icon purple\">psychology</mat-icon>\n </div>\n </mat-card>\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Functional Competencies</p>\n <h2>{{this.dashboardData?.functional_competencies_count}}</h2>\n </div>\n <mat-icon class=\"icon teal\">settings</mat-icon>\n </div>\n </mat-card>\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Domain Competencies</p>\n <h2>{{this.dashboardData?.domain_competencies_count}}</h2>\n </div>\n <mat-icon class=\"icon orange\">tune</mat-icon>\n </div>\n </mat-card>\n\n </div>\n\n <!-- DOCUMENTS -->\n <h2 class=\"section-title\">\n <mat-icon>menu_book</mat-icon>\n Documents & Course Recommendations\n </h2>\n\n <div class=\"card-grid\">\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Total Documents Uploaded</p>\n <h2>{{this.dashboardData?.total_documents}}</h2>\n <!-- <p class=\"card-subtitle\">Min 1, Max 10 per role mapping</p> -->\n </div>\n <mat-icon class=\"icon amber\">upload_file</mat-icon>\n </div>\n </mat-card>\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Role Mappings with Course Recommendations</p>\n <h2>{{this.dashboardData?.role_mappings_with_recommendations}}</h2>\n <!-- <p class=\"card-subtitle\">8500 of 50,000 role mappings</p> -->\n </div>\n <mat-icon class=\"icon green\">menu_book</mat-icon>\n </div>\n </mat-card>\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Course Recommendations Saved</p>\n <h2>{{this.dashboardData?.saved_recommended_courses_count}}</h2>\n <!-- <p class=\"card-subtitle\">{{this.dashboardData?.saved_recommended_courses_count}} of 8500\n recommendations</p> -->\n </div>\n <mat-icon class=\"icon teal\">save</mat-icon>\n </div>\n </mat-card>\n\n </div>\n\n <!-- GAP ANALYSIS -->\n <div class=\"gap-section\">\n <h2 class=\"section-title warning\">\n <mat-icon>warning</mat-icon>\n Gap Analysis\n </h2>\n\n <div class=\"card-grid-alone\">\n\n <mat-card class=\"metric-card warning-bg\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Competencies Without Courses</p>\n <h2>{{this.dashboardData?.competencies_without_courses}}</h2>\n <p class=\"card-subtitle\">Unique competencies with no identified courses</p>\n </div>\n <mat-icon class=\"icon red\">cancel</mat-icon>\n </div>\n </mat-card>\n\n <!-- <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Manually Added Courses</p>\n <h2>-</h2>\n <p class=\"card-subtitle\">Competencies with user-added courses</p>\n </div>\n <mat-icon class=\"icon green\">add_circle</mat-icon>\n </div>\n </mat-card> -->\n\n </div>\n\n <div class=\"card-grid mt-2\">\n\n <mat-card class=\"metric-card warning-bg\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Behavioral Competencies Without Courses</p>\n <h2>{{this.dashboardData?.behavioral_without_courses}}</h2>\n </div>\n <mat-icon class=\"icon red\">cancel</mat-icon>\n </div>\n </mat-card>\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Functional Competencies Without Courses</p>\n <h2>{{this.dashboardData?.functional_without_courses}}</h2>\n </div>\n <mat-icon class=\"icon red\">cancel</mat-icon>\n </div>\n </mat-card>\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Domain Competencies Without Courses</p>\n <h2>{{this.dashboardData?.domain_without_courses}}</h2>\n </div>\n <mat-icon class=\"icon red\">cancel</mat-icon>\n </div>\n </mat-card>\n\n </div>\n </div>\n\n <!-- OVERVIEW METRICS -->\n <h2 class=\"section-title\">\n <mat-icon>dashboard</mat-icon>\n Users and Role Mapping Metrics\n </h2>\n\n <div class=\"card-grid\">\n\n <mat-card class=\"metric-card\" *ngIf=\"!isSuperAdmin\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Unique Users (Credentials)</p>\n <h2>{{this.dashboardData?.total_users}}</h2>\n </div>\n <mat-icon class=\"icon primary\">public</mat-icon>\n </div>\n </mat-card>\n\n <mat-card class=\"metric-card\" *ngIf=\"!isSuperAdmin\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Unique Users with Role Mappings</p>\n <h2>{{this.dashboardData?.users_with_role_mappings}}</h2>\n <!-- <p class=\"card-subtitle\">Generated atleast 1 role mapping</p> -->\n </div>\n <mat-icon class=\"icon teal\">apartment</mat-icon>\n </div>\n </mat-card>\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Total Designation/Role Mappings Generated</p>\n <h2>{{this.dashboardData?.total_role_mappings}}</h2>\n </div>\n <mat-icon class=\"icon green\">description</mat-icon>\n </div>\n </mat-card>\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Unique Role Mappings</p>\n <h2>{{this.dashboardData?.unique_role_mappings}}</h2>\n <!-- <p class=\"card-subtitle\">10,000 unique of 50,000 total</p> -->\n </div>\n <mat-icon class=\"icon teal\">apartment</mat-icon>\n </div>\n </mat-card>\n\n </div>\n </div>\n</div>", styles: [".dashboard-wrapper{background:transparent;min-height:100vh;padding:24px 10px;margin:0 30px 0 60px}.dashboard-container{max-width:auto;margin:0 auto}.section-title{display:flex;align-items:center;gap:10px;font-size:18px;font-weight:600;color:#000;margin:20px 0}.card-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:32px}.card-grid-alone{display:grid;grid-template-columns:repeat(1,1fr);gap:32px}.metric-card{padding:24px;border-radius:12px;box-shadow:none;border:1px solid #e5e7eb}.card-content{display:flex;justify-content:space-between;align-items:center}.card-title{font-size:14px;color:#6b7280;margin-bottom:6px}.metric-card h2{font-size:28px;font-weight:700;color:#000;margin:0}.card-subtitle{font-size:12px;color:#9ca3af;margin-top:6px}.icon{font-size:28px;width:40px;height:40px;border-radius:8px;display:flex;align-items:center;justify-content:center}.primary{color:#2563eb}.teal{color:#059669}.green{color:#16a34a}.purple{color:#9333ea}.orange{color:#f97316}.amber{color:#f59e0b}.red,.section-title.warning{color:#dc2626}.warning-card{background:#fdeaea;border:1px solid #f5c2c7}.filters-card{padding:20px 24px;border-radius:12px;border:1px solid #e5e7eb;box-shadow:none}.filters-header{display:flex;align-items:center;gap:8px;font-weight:600;margin-bottom:16px}.filters-row{display:flex;gap:24px;flex-wrap:wrap}.filters-row mat-form-field{flex:1;min-width:220px}:host ::ng-deep .mat-form-field-appearance-outline .mat-form-field-outline{color:#ccc}:host ::ng-deep .mat-form-field-appearance-outline.mat-focused .mat-form-field-outline-thick{color:#1b4ca1;border-color:#1b4ca1!important}::ng-deep .select-search-panel .mat-option.mat-selected:not(.mat-option-disabled){background-color:#1b4ca1!important;color:#fff!important}:host ::ng-deep .mat-form-field-appearance-outline{border-radius:25px;border:1px solid #ccc}:host ::ng-deep .mat-form-field-focused .mat-form-field-appearance-outline{border-color:#1b4ca1!important}:host ::ng-deep .mat-form-field-appearance-outline .mat-form-field-outline-start{border-radius:25px 0 0 25px;border:none!important}:host ::ng-deep .mat-form-field-appearance-outline .mat-form-field-outline-end{border-right:none!important;border:none!important;border-radius:0 25px 25px 0}:host ::ng-deep .mat-form-field-appearance-outline .mat-form-field-outline-gap{border:none!important;border-radius:25px}:host::ng-deep .mat-form-field-appearance-outline .mat-form-field-infix{background-color:transparent!important}.dashboard-container .mat-card{background-color:#fff}.gap-title{color:#b91c1c}.gap-section{background-color:#d926621a;padding:10px;border-radius:12px;border:1px solid #f5c2c7;margin:16px 0}.gap-card{background-color:#d926621a;border:1px solid #f8d7da}.gap-card h2{color:#dc2626}@media (max-width: 1200px){.card-grid{grid-template-columns:repeat(2,1fr)}}@media (max-width: 768px){.card-grid{grid-template-columns:1fr}}.mat-select-panel .search-wrapper{width:100%!important;box-sizing:border-box;padding:8px;position:sticky;top:0;z-index:2;background:#fff}.search-input{width:100%;padding:6px 10px;border:1px solid #ccc;border-radius:6px;outline:none;box-sizing:border-box}.mat-select-panel mat-option{padding-top:10px}::ng-deep .mat-select-panel-wrap{overflow:visible!important;padding:0;margin-top:42px}::ng-deep .mat-select-panel{border:1px solid #ccc!important;box-sizing:border-box;max-height:250px}::ng-deep .select-with-search.mat-select-panel{padding-top:0;overflow:auto}::ng-deep .select-with-search .search-wrapper{position:sticky;top:0;z-index:10;background:#fff;padding:8px;border-bottom:1px solid #e0e0e0}::ng-deep .select-with-search .search-input{width:100%;padding:6px 10px;border:1px solid #ccc;border-radius:6px;outline:none;box-sizing:border-box}::ng-deep .select-with-search mat-option:first-of-type{margin-top:4px}::ng-deep .md-drppicker.ltr{min-width:500px!important}.sub-heading p{color:#000;font-family:Montserrat;font-size:18px;font-style:normal;font-weight:600;line-height:normal}.mb-10{margin-bottom:10px}.cursor-pointer{cursor:pointer}\n"], dependencies: [{ kind: "directive", type: i5.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i5.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i6.MatLegacyCard, selector: "mat-card", exportAs: ["matCard"] }, { kind: "directive", type: i2.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i2.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "component", type: i7.MatLegacyFormField, selector: "mat-form-field", inputs: ["color", "appearance", "hideRequiredMarker", "hintLabel", "floatLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: i8.MatLegacyInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", exportAs: ["matInput"] }, { kind: "component", type: i9.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "component", type: i10.MatLegacySelect, selector: "mat-select", inputs: ["disabled", "disableRipple", "tabIndex"], exportAs: ["matSelect"] }, { kind: "component", type: i11.MatLegacyOption, selector: "mat-option", exportAs: ["matOption"] }, { kind: "directive", type: i2.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i2.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "directive", type: i12$2.DaterangepickerDirective, selector: "input[ngxDaterangepickerMd]", inputs: ["minDate", "maxDate", "autoApply", "alwaysShowCalendars", "showCustomRangeLabel", "linkedCalendars", "dateLimit", "singleDatePicker", "showWeekNumbers", "showISOWeekNumbers", "showDropdowns", "isInvalidDate", "isCustomDate", "isTooltipDate", "showClearButton", "customRangeDirection", "ranges", "opens", "drops", "firstMonthDayClass", "lastMonthDayClass", "emptyWeekRowClass", "emptyWeekColumnClass", "firstDayOfNextMonthClass", "lastDayOfPreviousMonthClass", "keepCalendarOpeningWithRange", "showRangeLabelOnInput", "showCancel", "lockStartDate", "timePicker", "timePicker24Hour", "timePickerIncrement", "timePickerSeconds", "closeOnAutoApply", "endKeyHolder", "startKey", "locale", "endKey"], outputs: ["change", "rangeClicked", "datesUpdated", "startDateChanged", "endDateChanged", "clearClicked"] }] }); }
|
|
8100
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.12", type: DashboardComponent, selector: "app-dashboard", viewQueries: [{ propertyName: "departmentSelect", first: true, predicate: ["departmentSelect"], descendants: true }], ngImport: i0, template: "<div class=\"dashboard-wrapper\">\n <div class=\"header\">\n <div class=\"sub-heading mt-10 mb-10 cursor-pointer\">\n <p (click)=\"routeToInitial()\"><mat-icon style=\"vertical-align: middle;\">arrow_back</mat-icon><span\n class=\"pl-10\">Back to Role Mapping Generation</span></p>\n </div>\n\n </div>\n <div class=\"dashboard-container\">\n\n <!-- FILTERS SECTION -->\n <form [formGroup]=\"filtersForm\" class=\"filters-form\">\n\n <mat-card class=\"filters-card\">\n <div class=\"filters-header\">\n <mat-icon>filter_list</mat-icon>\n <span>Filters</span>\n </div>\n\n <div class=\"filters-row\">\n <div>\n <label>Centre / State </label>\n <!-- Centre / State -->\n <mat-form-field appearance=\"fill\"\n style=\"background: white; border-radius: 25px; padding: 0 12px; border: 1px solid #ccc;width: 100%;\">\n\n <mat-select formControlName=\"centreState\" [disabled]=\"!isSuperAdmin\"\n (selectionChange)=\"onMinistryTypeChange($event)\">\n <mat-option value=\"\">Select Center/State</mat-option>\n <mat-option value=\"ministry\">Center</mat-option>\n <mat-option value=\"state\">State</mat-option>\n </mat-select>\n </mat-form-field>\n </div>\n <div>\n <label>{{selectedMinistryType === 'ministry' ? 'Ministry':'State'}} </label>\n <!-- Centre / State -->\n <mat-form-field appearance=\"fill\"\n style=\"background: white; border-radius: 25px; padding: 0 12px; border: 1px solid #ccc;width: 100%;\">\n <mat-select panelClass=\"select-with-search\" [disabled]=\"!isSuperAdmin\" multiple\n [placeholder]=\"selectedMinistryType === 'ministry' ? 'Select Ministry/ Department':'Select State'\"\n (selectionChange)=\"onMinistryChange($event)\" formControlName=\"ministries\"\n style=\"border-radius: 25px; background: white; width:100%\"\n (openedChange)=\"onOpened($event)\">\n <div class=\"search-wrapper\" *ngIf=\"panelOpen\">\n <input type=\"text\" placeholder=\"Search...\" (input)=\"filterData($event)\"\n class=\"search-input\" (keydown.space)=\"$event.stopPropagation()\"\n (keydown)=\"$event.stopPropagation()\">\n </div>\n <!-- [selected]=\"selectedMinistryId === item?.identifier\" -->\n <mat-option [value]=\"item?.identifier\" *ngFor=\"let item of filteredList\"\n >{{item?.orgName}}</mat-option>\n </mat-select>\n </mat-form-field>\n </div>\n <div>\n <label>Department</label>\n <!-- Centre / State -->\n <mat-form-field appearance=\"fill\"\n style=\"background: white; border-radius: 25px; padding: 0 12px;border: 1px solid #ccc;\">\n <mat-select #departmentSelect panelClass=\"select-with-search\" placeholder=\"Select Department\"\n [disabled]=\"!isSuperAdmin\" multiple formControlName=\"departments\"\n style=\"border-radius: 25px; background: white;\" (selectionChange)=\"onDepartmentChange()\"\n (openedChange)=\"onOpenedDepartment($event)\">\n <div class=\"search-wrapper\" *ngIf=\"departmentPanelOpen\">\n <input type=\"text\" placeholder=\"Search...\" (input)=\"filterDepartmentData($event)\"\n class=\"search-input\" (keydown.space)=\"$event.stopPropagation()\"\n (keydown)=\"$event.stopPropagation()\">\n </div>\n <mat-option [value]=\"item?.identifier\"\n *ngFor=\"let item of filteredDepartmentList\">{{item?.orgName}}</mat-option>\n <!-- selected departments not present in the current search/page:\n kept rendered (hidden) so mat-select does not clear the selection -->\n <mat-option [value]=\"item?.identifier\" style=\"display: none\"\n *ngFor=\"let item of pinnedDepartmentOptions\">{{item?.orgName}}</mat-option>\n <mat-option disabled *ngIf=\"departmentLoading\">Loading...</mat-option>\n <mat-option disabled\n *ngIf=\"!departmentLoading && !filteredDepartmentList?.length\">No department found</mat-option>\n\n </mat-select>\n </mat-form-field>\n </div>\n\n <!-- Date Range -->\n <div>\n <label>Date Range </label>\n <mat-form-field appearance=\"outline\">\n\n <input matInput ngxDaterangepickerMd formControlName=\"dateRange\" style=\"margin:10px\"\n placeholder=\"Select date range\" [autoApply]=\"true\" [linkedCalendars]=\"true\"\n [locale]=\"{ format: 'DD MMM YYYY' }\" />\n </mat-form-field>\n </div>\n\n\n </div>\n </mat-card>\n </form>\n\n <!-- OVERVIEW METRICS -->\n <h2 class=\"section-title\">\n <mat-icon>dashboard</mat-icon>\n Overview Metrics\n </h2>\n\n <div class=\"card-grid\">\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">States/Ministries which generated Role Mapping</p>\n <h2>{{this.dashboardData?.ministry_count}}</h2>\n <!-- <p class=\"card-subtitle\">At least 1 designation/role mapping</p> -->\n </div>\n <mat-icon class=\"icon primary\">public</mat-icon>\n </div>\n </mat-card>\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Departments which generated Role Mapping</p>\n <h2>{{this.dashboardData?.department_count}}</h2>\n <!-- <p class=\"card-subtitle\">At least 1 designation/role mapping</p> -->\n </div>\n <mat-icon class=\"icon teal\">apartment</mat-icon>\n </div>\n </mat-card>\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Total Capacity Building Plans Created</p>\n <h2>{{this.dashboardData?.total_cbp_plan_count}}</h2>\n </div>\n <mat-icon class=\"icon green\">description</mat-icon>\n </div>\n </mat-card>\n\n </div>\n\n <!-- COMPETENCIES -->\n <h2 class=\"section-title\">\n <mat-icon>psychology</mat-icon>\n Competencies Recommended\n </h2>\n\n <div class=\"card-grid\">\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Behavioral Competencies</p>\n <h2>{{this.dashboardData?.behavioral_competencies_count}}</h2>\n </div>\n <mat-icon class=\"icon purple\">psychology</mat-icon>\n </div>\n </mat-card>\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Functional Competencies</p>\n <h2>{{this.dashboardData?.functional_competencies_count}}</h2>\n </div>\n <mat-icon class=\"icon teal\">settings</mat-icon>\n </div>\n </mat-card>\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Domain Competencies</p>\n <h2>{{this.dashboardData?.domain_competencies_count}}</h2>\n </div>\n <mat-icon class=\"icon orange\">tune</mat-icon>\n </div>\n </mat-card>\n\n </div>\n\n <!-- DOCUMENTS -->\n <h2 class=\"section-title\">\n <mat-icon>menu_book</mat-icon>\n Documents & Course Recommendations\n </h2>\n\n <div class=\"card-grid\">\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Total Documents Uploaded</p>\n <h2>{{this.dashboardData?.total_documents}}</h2>\n <!-- <p class=\"card-subtitle\">Min 1, Max 10 per role mapping</p> -->\n </div>\n <mat-icon class=\"icon amber\">upload_file</mat-icon>\n </div>\n </mat-card>\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Role Mappings with Course Recommendations</p>\n <h2>{{this.dashboardData?.role_mappings_with_recommendations}}</h2>\n <!-- <p class=\"card-subtitle\">8500 of 50,000 role mappings</p> -->\n </div>\n <mat-icon class=\"icon green\">menu_book</mat-icon>\n </div>\n </mat-card>\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Course Recommendations Saved</p>\n <h2>{{this.dashboardData?.saved_recommended_courses_count}}</h2>\n <!-- <p class=\"card-subtitle\">{{this.dashboardData?.saved_recommended_courses_count}} of 8500\n recommendations</p> -->\n </div>\n <mat-icon class=\"icon teal\">save</mat-icon>\n </div>\n </mat-card>\n\n </div>\n\n <!-- GAP ANALYSIS -->\n <div class=\"gap-section\">\n <h2 class=\"section-title warning\">\n <mat-icon>warning</mat-icon>\n Gap Analysis\n </h2>\n\n <div class=\"card-grid-alone\">\n\n <mat-card class=\"metric-card warning-bg\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Competencies Without Courses</p>\n <h2>{{this.dashboardData?.competencies_without_courses}}</h2>\n <p class=\"card-subtitle\">Unique competencies with no identified courses</p>\n </div>\n <mat-icon class=\"icon red\">cancel</mat-icon>\n </div>\n </mat-card>\n\n <!-- <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Manually Added Courses</p>\n <h2>-</h2>\n <p class=\"card-subtitle\">Competencies with user-added courses</p>\n </div>\n <mat-icon class=\"icon green\">add_circle</mat-icon>\n </div>\n </mat-card> -->\n\n </div>\n\n <div class=\"card-grid mt-2\">\n\n <mat-card class=\"metric-card warning-bg\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Behavioral Competencies Without Courses</p>\n <h2>{{this.dashboardData?.behavioral_without_courses}}</h2>\n </div>\n <mat-icon class=\"icon red\">cancel</mat-icon>\n </div>\n </mat-card>\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Functional Competencies Without Courses</p>\n <h2>{{this.dashboardData?.functional_without_courses}}</h2>\n </div>\n <mat-icon class=\"icon red\">cancel</mat-icon>\n </div>\n </mat-card>\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Domain Competencies Without Courses</p>\n <h2>{{this.dashboardData?.domain_without_courses}}</h2>\n </div>\n <mat-icon class=\"icon red\">cancel</mat-icon>\n </div>\n </mat-card>\n\n </div>\n </div>\n\n <!-- OVERVIEW METRICS -->\n <h2 class=\"section-title\">\n <mat-icon>dashboard</mat-icon>\n Users and Role Mapping Metrics\n </h2>\n\n <div class=\"card-grid\">\n\n <mat-card class=\"metric-card\" *ngIf=\"!isSuperAdmin\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Unique Users (Credentials)</p>\n <h2>{{this.dashboardData?.total_users}}</h2>\n </div>\n <mat-icon class=\"icon primary\">public</mat-icon>\n </div>\n </mat-card>\n\n <mat-card class=\"metric-card\" *ngIf=\"!isSuperAdmin\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Unique Users with Role Mappings</p>\n <h2>{{this.dashboardData?.users_with_role_mappings}}</h2>\n <!-- <p class=\"card-subtitle\">Generated atleast 1 role mapping</p> -->\n </div>\n <mat-icon class=\"icon teal\">apartment</mat-icon>\n </div>\n </mat-card>\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Total Designation/Role Mappings Generated</p>\n <h2>{{this.dashboardData?.total_role_mappings}}</h2>\n </div>\n <mat-icon class=\"icon green\">description</mat-icon>\n </div>\n </mat-card>\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Unique Role Mappings</p>\n <h2>{{this.dashboardData?.unique_role_mappings}}</h2>\n <!-- <p class=\"card-subtitle\">10,000 unique of 50,000 total</p> -->\n </div>\n <mat-icon class=\"icon teal\">apartment</mat-icon>\n </div>\n </mat-card>\n\n </div>\n </div>\n</div>", styles: [".dashboard-wrapper{background:transparent;min-height:100vh;padding:24px 10px;margin:0 30px 0 60px}.dashboard-container{max-width:auto;margin:0 auto}.section-title{display:flex;align-items:center;gap:10px;font-size:18px;font-weight:600;color:#000;margin:20px 0}.card-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:32px}.card-grid-alone{display:grid;grid-template-columns:repeat(1,1fr);gap:32px}.metric-card{padding:24px;border-radius:12px;box-shadow:none;border:1px solid #e5e7eb}.card-content{display:flex;justify-content:space-between;align-items:center}.card-title{font-size:14px;color:#6b7280;margin-bottom:6px}.metric-card h2{font-size:28px;font-weight:700;color:#000;margin:0}.card-subtitle{font-size:12px;color:#9ca3af;margin-top:6px}.icon{font-size:28px;width:40px;height:40px;border-radius:8px;display:flex;align-items:center;justify-content:center}.primary{color:#2563eb}.teal{color:#059669}.green{color:#16a34a}.purple{color:#9333ea}.orange{color:#f97316}.amber{color:#f59e0b}.red,.section-title.warning{color:#dc2626}.warning-card{background:#fdeaea;border:1px solid #f5c2c7}.filters-card{padding:20px 24px;border-radius:12px;border:1px solid #e5e7eb;box-shadow:none}.filters-header{display:flex;align-items:center;gap:8px;font-weight:600;margin-bottom:16px}.filters-row{display:flex;gap:24px;flex-wrap:wrap}.filters-row mat-form-field{flex:1;min-width:220px}:host ::ng-deep .mat-form-field-appearance-outline .mat-form-field-outline{color:#ccc}:host ::ng-deep .mat-form-field-appearance-outline.mat-focused .mat-form-field-outline-thick{color:#1b4ca1;border-color:#1b4ca1!important}::ng-deep .select-search-panel .mat-option.mat-selected:not(.mat-option-disabled){background-color:#1b4ca1!important;color:#fff!important}:host ::ng-deep .mat-form-field-appearance-outline{border-radius:25px;border:1px solid #ccc}:host ::ng-deep .mat-form-field-focused .mat-form-field-appearance-outline{border-color:#1b4ca1!important}:host ::ng-deep .mat-form-field-appearance-outline .mat-form-field-outline-start{border-radius:25px 0 0 25px;border:none!important}:host ::ng-deep .mat-form-field-appearance-outline .mat-form-field-outline-end{border-right:none!important;border:none!important;border-radius:0 25px 25px 0}:host ::ng-deep .mat-form-field-appearance-outline .mat-form-field-outline-gap{border:none!important;border-radius:25px}:host::ng-deep .mat-form-field-appearance-outline .mat-form-field-infix{background-color:transparent!important}.dashboard-container .mat-card{background-color:#fff}.gap-title{color:#b91c1c}.gap-section{background-color:#d926621a;padding:10px;border-radius:12px;border:1px solid #f5c2c7;margin:16px 0}.gap-card{background-color:#d926621a;border:1px solid #f8d7da}.gap-card h2{color:#dc2626}@media (max-width: 1200px){.card-grid{grid-template-columns:repeat(2,1fr)}}@media (max-width: 768px){.card-grid{grid-template-columns:1fr}}.mat-select-panel .search-wrapper{width:100%!important;box-sizing:border-box;padding:8px;position:sticky;top:0;z-index:2;background:#fff}.search-input{width:100%;padding:6px 10px;border:1px solid #ccc;border-radius:6px;outline:none;box-sizing:border-box}.mat-select-panel mat-option{padding-top:10px}::ng-deep .mat-select-panel-wrap{overflow:visible!important;padding:0;margin-top:42px}::ng-deep .mat-select-panel{border:1px solid #ccc!important;box-sizing:border-box;max-height:250px}::ng-deep .select-with-search.mat-select-panel{padding-top:0;overflow:auto}::ng-deep .select-with-search .search-wrapper{position:sticky;top:0;z-index:10;background:#fff;padding:8px;border-bottom:1px solid #e0e0e0}::ng-deep .select-with-search .search-input{width:100%;padding:6px 10px;border:1px solid #ccc;border-radius:6px;outline:none;box-sizing:border-box}::ng-deep .select-with-search mat-option:first-of-type{margin-top:4px}::ng-deep .md-drppicker.ltr{min-width:500px!important}.sub-heading p{color:#000;font-family:Montserrat;font-size:18px;font-style:normal;font-weight:600;line-height:normal}.mb-10{margin-bottom:10px}.cursor-pointer{cursor:pointer}\n"], dependencies: [{ kind: "directive", type: i5.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i5.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i6.MatLegacyCard, selector: "mat-card", exportAs: ["matCard"] }, { kind: "directive", type: i2.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i2.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "component", type: i7.MatLegacyFormField, selector: "mat-form-field", inputs: ["color", "appearance", "hideRequiredMarker", "hintLabel", "floatLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: i8.MatLegacyInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", exportAs: ["matInput"] }, { kind: "component", type: i9.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "component", type: i10.MatLegacySelect, selector: "mat-select", inputs: ["disabled", "disableRipple", "tabIndex"], exportAs: ["matSelect"] }, { kind: "component", type: i11.MatLegacyOption, selector: "mat-option", exportAs: ["matOption"] }, { kind: "directive", type: i2.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i2.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "directive", type: i12$2.DaterangepickerDirective, selector: "input[ngxDaterangepickerMd]", inputs: ["minDate", "maxDate", "autoApply", "alwaysShowCalendars", "showCustomRangeLabel", "linkedCalendars", "dateLimit", "singleDatePicker", "showWeekNumbers", "showISOWeekNumbers", "showDropdowns", "isInvalidDate", "isCustomDate", "isTooltipDate", "showClearButton", "customRangeDirection", "ranges", "opens", "drops", "firstMonthDayClass", "lastMonthDayClass", "emptyWeekRowClass", "emptyWeekColumnClass", "firstDayOfNextMonthClass", "lastDayOfPreviousMonthClass", "keepCalendarOpeningWithRange", "showRangeLabelOnInput", "showCancel", "lockStartDate", "timePicker", "timePicker24Hour", "timePickerIncrement", "timePickerSeconds", "closeOnAutoApply", "endKeyHolder", "startKey", "locale", "endKey"], outputs: ["change", "rangeClicked", "datesUpdated", "startDateChanged", "endDateChanged", "clearClicked"] }] }); }
|
|
8097
8101
|
}
|
|
8098
8102
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DashboardComponent, decorators: [{
|
|
8099
8103
|
type: Component,
|
|
8100
|
-
args: [{ selector: 'app-dashboard', template: "<div class=\"dashboard-wrapper\">\n <div class=\"header\">\n <div class=\"sub-heading mt-10 mb-10 cursor-pointer\">\n <p (click)=\"routeToInitial()\"><mat-icon style=\"vertical-align: middle;\">arrow_back</mat-icon><span\n class=\"pl-10\">Back to Role Mapping Generation</span></p>\n </div>\n\n </div>\n <div class=\"dashboard-container\">\n\n <!-- FILTERS SECTION -->\n <form [formGroup]=\"filtersForm\" class=\"filters-form\">\n\n <mat-card class=\"filters-card\">\n <div class=\"filters-header\">\n <mat-icon>filter_list</mat-icon>\n <span>Filters</span>\n </div>\n\n <div class=\"filters-row\">\n <div>\n <label>Centre / State </label>\n <!-- Centre / State -->\n <mat-form-field appearance=\"fill\"\n style=\"background: white; border-radius: 25px; padding: 0 12px; border: 1px solid #ccc;width: 100%;\">\n\n <mat-select formControlName=\"centreState\" [disabled]=\"!isSuperAdmin\"\n (selectionChange)=\"onMinistryTypeChange($event)\">\n <mat-option value=\"\">Select Center/State</mat-option>\n <mat-option value=\"ministry\">Center</mat-option>\n <mat-option value=\"state\">State</mat-option>\n </mat-select>\n </mat-form-field>\n </div>\n <div>\n <label>{{selectedMinistryType === 'ministry' ? 'Ministry':'State'}} </label>\n <!-- Centre / State -->\n <mat-form-field appearance=\"fill\"\n style=\"background: white; border-radius: 25px; padding: 0 12px; border: 1px solid #ccc;width: 100%;\">\n <mat-select panelClass=\"select-with-search\" [disabled]=\"!isSuperAdmin\" multiple\n [placeholder]=\"selectedMinistryType === 'ministry' ? 'Select Ministry/ Department':'Select State'\"\n (selectionChange)=\"onMinistryChange($event)\" formControlName=\"ministries\"\n style=\"border-radius: 25px; background: white; width:100%\"\n (openedChange)=\"onOpened($event)\">\n <div class=\"search-wrapper\" *ngIf=\"panelOpen\">\n <input type=\"text\" placeholder=\"Search...\" (input)=\"filterData($event)\"\n class=\"search-input\" (keydown.space)=\"$event.stopPropagation()\"\n (keydown)=\"$event.stopPropagation()\">\n </div>\n <!-- [selected]=\"selectedMinistryId === item?.identifier\" -->\n <mat-option [value]=\"item?.identifier\" *ngFor=\"let item of filteredList\"\n >{{item?.orgName}}</mat-option>\n </mat-select>\n </mat-form-field>\n </div>\n <div>\n <label>Department</label>\n <!-- Centre / State -->\n <mat-form-field appearance=\"fill\"\n style=\"background: white; border-radius: 25px; padding: 0 12px;border: 1px solid #ccc;\">\n <mat-select #departmentSelect panelClass=\"select-with-search\" placeholder=\"Select Department\"\n [disabled]=\"!isSuperAdmin\" multiple formControlName=\"departments\"\n style=\"border-radius: 25px; background: white;\" (selectionChange)=\"onDepartmentChange()\"\n (openedChange)=\"onOpenedDepartment($event)\">\n <div class=\"search-wrapper\" *ngIf=\"departmentPanelOpen\">\n <input type=\"text\" placeholder=\"Search...\" (input)=\"filterDepartmentData($event)\"\n class=\"search-input\" (keydown.space)=\"$event.stopPropagation()\"\n (keydown)=\"$event.stopPropagation()\">\n </div>\n <mat-option [value]=\"item?.identifier\"\n *ngFor=\"let item of filteredDepartmentList\">{{item?.orgName}}</mat-option>\n <mat-option disabled *ngIf=\"departmentLoading\">Loading...</mat-option>\n <mat-option disabled\n *ngIf=\"!departmentLoading && !filteredDepartmentList?.length\">No department found</mat-option>\n\n </mat-select>\n </mat-form-field>\n </div>\n\n <!-- Date Range -->\n <div>\n <label>Date Range </label>\n <mat-form-field appearance=\"outline\">\n\n <input matInput ngxDaterangepickerMd formControlName=\"dateRange\" style=\"margin:10px\"\n placeholder=\"Select date range\" [autoApply]=\"true\" [linkedCalendars]=\"true\"\n [locale]=\"{ format: 'DD MMM YYYY' }\" />\n </mat-form-field>\n </div>\n\n\n </div>\n </mat-card>\n </form>\n\n <!-- OVERVIEW METRICS -->\n <h2 class=\"section-title\">\n <mat-icon>dashboard</mat-icon>\n Overview Metrics\n </h2>\n\n <div class=\"card-grid\">\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">States/Ministries which generated Role Mapping</p>\n <h2>{{this.dashboardData?.ministry_count}}</h2>\n <!-- <p class=\"card-subtitle\">At least 1 designation/role mapping</p> -->\n </div>\n <mat-icon class=\"icon primary\">public</mat-icon>\n </div>\n </mat-card>\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Departments which generated Role Mapping</p>\n <h2>{{this.dashboardData?.department_count}}</h2>\n <!-- <p class=\"card-subtitle\">At least 1 designation/role mapping</p> -->\n </div>\n <mat-icon class=\"icon teal\">apartment</mat-icon>\n </div>\n </mat-card>\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Total Capacity Building Plans Created</p>\n <h2>{{this.dashboardData?.total_cbp_plan_count}}</h2>\n </div>\n <mat-icon class=\"icon green\">description</mat-icon>\n </div>\n </mat-card>\n\n </div>\n\n <!-- COMPETENCIES -->\n <h2 class=\"section-title\">\n <mat-icon>psychology</mat-icon>\n Competencies Recommended\n </h2>\n\n <div class=\"card-grid\">\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Behavioral Competencies</p>\n <h2>{{this.dashboardData?.behavioral_competencies_count}}</h2>\n </div>\n <mat-icon class=\"icon purple\">psychology</mat-icon>\n </div>\n </mat-card>\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Functional Competencies</p>\n <h2>{{this.dashboardData?.functional_competencies_count}}</h2>\n </div>\n <mat-icon class=\"icon teal\">settings</mat-icon>\n </div>\n </mat-card>\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Domain Competencies</p>\n <h2>{{this.dashboardData?.domain_competencies_count}}</h2>\n </div>\n <mat-icon class=\"icon orange\">tune</mat-icon>\n </div>\n </mat-card>\n\n </div>\n\n <!-- DOCUMENTS -->\n <h2 class=\"section-title\">\n <mat-icon>menu_book</mat-icon>\n Documents & Course Recommendations\n </h2>\n\n <div class=\"card-grid\">\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Total Documents Uploaded</p>\n <h2>{{this.dashboardData?.total_documents}}</h2>\n <!-- <p class=\"card-subtitle\">Min 1, Max 10 per role mapping</p> -->\n </div>\n <mat-icon class=\"icon amber\">upload_file</mat-icon>\n </div>\n </mat-card>\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Role Mappings with Course Recommendations</p>\n <h2>{{this.dashboardData?.role_mappings_with_recommendations}}</h2>\n <!-- <p class=\"card-subtitle\">8500 of 50,000 role mappings</p> -->\n </div>\n <mat-icon class=\"icon green\">menu_book</mat-icon>\n </div>\n </mat-card>\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Course Recommendations Saved</p>\n <h2>{{this.dashboardData?.saved_recommended_courses_count}}</h2>\n <!-- <p class=\"card-subtitle\">{{this.dashboardData?.saved_recommended_courses_count}} of 8500\n recommendations</p> -->\n </div>\n <mat-icon class=\"icon teal\">save</mat-icon>\n </div>\n </mat-card>\n\n </div>\n\n <!-- GAP ANALYSIS -->\n <div class=\"gap-section\">\n <h2 class=\"section-title warning\">\n <mat-icon>warning</mat-icon>\n Gap Analysis\n </h2>\n\n <div class=\"card-grid-alone\">\n\n <mat-card class=\"metric-card warning-bg\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Competencies Without Courses</p>\n <h2>{{this.dashboardData?.competencies_without_courses}}</h2>\n <p class=\"card-subtitle\">Unique competencies with no identified courses</p>\n </div>\n <mat-icon class=\"icon red\">cancel</mat-icon>\n </div>\n </mat-card>\n\n <!-- <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Manually Added Courses</p>\n <h2>-</h2>\n <p class=\"card-subtitle\">Competencies with user-added courses</p>\n </div>\n <mat-icon class=\"icon green\">add_circle</mat-icon>\n </div>\n </mat-card> -->\n\n </div>\n\n <div class=\"card-grid mt-2\">\n\n <mat-card class=\"metric-card warning-bg\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Behavioral Competencies Without Courses</p>\n <h2>{{this.dashboardData?.behavioral_without_courses}}</h2>\n </div>\n <mat-icon class=\"icon red\">cancel</mat-icon>\n </div>\n </mat-card>\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Functional Competencies Without Courses</p>\n <h2>{{this.dashboardData?.functional_without_courses}}</h2>\n </div>\n <mat-icon class=\"icon red\">cancel</mat-icon>\n </div>\n </mat-card>\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Domain Competencies Without Courses</p>\n <h2>{{this.dashboardData?.domain_without_courses}}</h2>\n </div>\n <mat-icon class=\"icon red\">cancel</mat-icon>\n </div>\n </mat-card>\n\n </div>\n </div>\n\n <!-- OVERVIEW METRICS -->\n <h2 class=\"section-title\">\n <mat-icon>dashboard</mat-icon>\n Users and Role Mapping Metrics\n </h2>\n\n <div class=\"card-grid\">\n\n <mat-card class=\"metric-card\" *ngIf=\"!isSuperAdmin\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Unique Users (Credentials)</p>\n <h2>{{this.dashboardData?.total_users}}</h2>\n </div>\n <mat-icon class=\"icon primary\">public</mat-icon>\n </div>\n </mat-card>\n\n <mat-card class=\"metric-card\" *ngIf=\"!isSuperAdmin\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Unique Users with Role Mappings</p>\n <h2>{{this.dashboardData?.users_with_role_mappings}}</h2>\n <!-- <p class=\"card-subtitle\">Generated atleast 1 role mapping</p> -->\n </div>\n <mat-icon class=\"icon teal\">apartment</mat-icon>\n </div>\n </mat-card>\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Total Designation/Role Mappings Generated</p>\n <h2>{{this.dashboardData?.total_role_mappings}}</h2>\n </div>\n <mat-icon class=\"icon green\">description</mat-icon>\n </div>\n </mat-card>\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Unique Role Mappings</p>\n <h2>{{this.dashboardData?.unique_role_mappings}}</h2>\n <!-- <p class=\"card-subtitle\">10,000 unique of 50,000 total</p> -->\n </div>\n <mat-icon class=\"icon teal\">apartment</mat-icon>\n </div>\n </mat-card>\n\n </div>\n </div>\n</div>", styles: [".dashboard-wrapper{background:transparent;min-height:100vh;padding:24px 10px;margin:0 30px 0 60px}.dashboard-container{max-width:auto;margin:0 auto}.section-title{display:flex;align-items:center;gap:10px;font-size:18px;font-weight:600;color:#000;margin:20px 0}.card-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:32px}.card-grid-alone{display:grid;grid-template-columns:repeat(1,1fr);gap:32px}.metric-card{padding:24px;border-radius:12px;box-shadow:none;border:1px solid #e5e7eb}.card-content{display:flex;justify-content:space-between;align-items:center}.card-title{font-size:14px;color:#6b7280;margin-bottom:6px}.metric-card h2{font-size:28px;font-weight:700;color:#000;margin:0}.card-subtitle{font-size:12px;color:#9ca3af;margin-top:6px}.icon{font-size:28px;width:40px;height:40px;border-radius:8px;display:flex;align-items:center;justify-content:center}.primary{color:#2563eb}.teal{color:#059669}.green{color:#16a34a}.purple{color:#9333ea}.orange{color:#f97316}.amber{color:#f59e0b}.red,.section-title.warning{color:#dc2626}.warning-card{background:#fdeaea;border:1px solid #f5c2c7}.filters-card{padding:20px 24px;border-radius:12px;border:1px solid #e5e7eb;box-shadow:none}.filters-header{display:flex;align-items:center;gap:8px;font-weight:600;margin-bottom:16px}.filters-row{display:flex;gap:24px;flex-wrap:wrap}.filters-row mat-form-field{flex:1;min-width:220px}:host ::ng-deep .mat-form-field-appearance-outline .mat-form-field-outline{color:#ccc}:host ::ng-deep .mat-form-field-appearance-outline.mat-focused .mat-form-field-outline-thick{color:#1b4ca1;border-color:#1b4ca1!important}::ng-deep .select-search-panel .mat-option.mat-selected:not(.mat-option-disabled){background-color:#1b4ca1!important;color:#fff!important}:host ::ng-deep .mat-form-field-appearance-outline{border-radius:25px;border:1px solid #ccc}:host ::ng-deep .mat-form-field-focused .mat-form-field-appearance-outline{border-color:#1b4ca1!important}:host ::ng-deep .mat-form-field-appearance-outline .mat-form-field-outline-start{border-radius:25px 0 0 25px;border:none!important}:host ::ng-deep .mat-form-field-appearance-outline .mat-form-field-outline-end{border-right:none!important;border:none!important;border-radius:0 25px 25px 0}:host ::ng-deep .mat-form-field-appearance-outline .mat-form-field-outline-gap{border:none!important;border-radius:25px}:host::ng-deep .mat-form-field-appearance-outline .mat-form-field-infix{background-color:transparent!important}.dashboard-container .mat-card{background-color:#fff}.gap-title{color:#b91c1c}.gap-section{background-color:#d926621a;padding:10px;border-radius:12px;border:1px solid #f5c2c7;margin:16px 0}.gap-card{background-color:#d926621a;border:1px solid #f8d7da}.gap-card h2{color:#dc2626}@media (max-width: 1200px){.card-grid{grid-template-columns:repeat(2,1fr)}}@media (max-width: 768px){.card-grid{grid-template-columns:1fr}}.mat-select-panel .search-wrapper{width:100%!important;box-sizing:border-box;padding:8px;position:sticky;top:0;z-index:2;background:#fff}.search-input{width:100%;padding:6px 10px;border:1px solid #ccc;border-radius:6px;outline:none;box-sizing:border-box}.mat-select-panel mat-option{padding-top:10px}::ng-deep .mat-select-panel-wrap{overflow:visible!important;padding:0;margin-top:42px}::ng-deep .mat-select-panel{border:1px solid #ccc!important;box-sizing:border-box;max-height:250px}::ng-deep .select-with-search.mat-select-panel{padding-top:0;overflow:auto}::ng-deep .select-with-search .search-wrapper{position:sticky;top:0;z-index:10;background:#fff;padding:8px;border-bottom:1px solid #e0e0e0}::ng-deep .select-with-search .search-input{width:100%;padding:6px 10px;border:1px solid #ccc;border-radius:6px;outline:none;box-sizing:border-box}::ng-deep .select-with-search mat-option:first-of-type{margin-top:4px}::ng-deep .md-drppicker.ltr{min-width:500px!important}.sub-heading p{color:#000;font-family:Montserrat;font-size:18px;font-style:normal;font-weight:600;line-height:normal}.mb-10{margin-bottom:10px}.cursor-pointer{cursor:pointer}\n"] }]
|
|
8104
|
+
args: [{ selector: 'app-dashboard', template: "<div class=\"dashboard-wrapper\">\n <div class=\"header\">\n <div class=\"sub-heading mt-10 mb-10 cursor-pointer\">\n <p (click)=\"routeToInitial()\"><mat-icon style=\"vertical-align: middle;\">arrow_back</mat-icon><span\n class=\"pl-10\">Back to Role Mapping Generation</span></p>\n </div>\n\n </div>\n <div class=\"dashboard-container\">\n\n <!-- FILTERS SECTION -->\n <form [formGroup]=\"filtersForm\" class=\"filters-form\">\n\n <mat-card class=\"filters-card\">\n <div class=\"filters-header\">\n <mat-icon>filter_list</mat-icon>\n <span>Filters</span>\n </div>\n\n <div class=\"filters-row\">\n <div>\n <label>Centre / State </label>\n <!-- Centre / State -->\n <mat-form-field appearance=\"fill\"\n style=\"background: white; border-radius: 25px; padding: 0 12px; border: 1px solid #ccc;width: 100%;\">\n\n <mat-select formControlName=\"centreState\" [disabled]=\"!isSuperAdmin\"\n (selectionChange)=\"onMinistryTypeChange($event)\">\n <mat-option value=\"\">Select Center/State</mat-option>\n <mat-option value=\"ministry\">Center</mat-option>\n <mat-option value=\"state\">State</mat-option>\n </mat-select>\n </mat-form-field>\n </div>\n <div>\n <label>{{selectedMinistryType === 'ministry' ? 'Ministry':'State'}} </label>\n <!-- Centre / State -->\n <mat-form-field appearance=\"fill\"\n style=\"background: white; border-radius: 25px; padding: 0 12px; border: 1px solid #ccc;width: 100%;\">\n <mat-select panelClass=\"select-with-search\" [disabled]=\"!isSuperAdmin\" multiple\n [placeholder]=\"selectedMinistryType === 'ministry' ? 'Select Ministry/ Department':'Select State'\"\n (selectionChange)=\"onMinistryChange($event)\" formControlName=\"ministries\"\n style=\"border-radius: 25px; background: white; width:100%\"\n (openedChange)=\"onOpened($event)\">\n <div class=\"search-wrapper\" *ngIf=\"panelOpen\">\n <input type=\"text\" placeholder=\"Search...\" (input)=\"filterData($event)\"\n class=\"search-input\" (keydown.space)=\"$event.stopPropagation()\"\n (keydown)=\"$event.stopPropagation()\">\n </div>\n <!-- [selected]=\"selectedMinistryId === item?.identifier\" -->\n <mat-option [value]=\"item?.identifier\" *ngFor=\"let item of filteredList\"\n >{{item?.orgName}}</mat-option>\n </mat-select>\n </mat-form-field>\n </div>\n <div>\n <label>Department</label>\n <!-- Centre / State -->\n <mat-form-field appearance=\"fill\"\n style=\"background: white; border-radius: 25px; padding: 0 12px;border: 1px solid #ccc;\">\n <mat-select #departmentSelect panelClass=\"select-with-search\" placeholder=\"Select Department\"\n [disabled]=\"!isSuperAdmin\" multiple formControlName=\"departments\"\n style=\"border-radius: 25px; background: white;\" (selectionChange)=\"onDepartmentChange()\"\n (openedChange)=\"onOpenedDepartment($event)\">\n <div class=\"search-wrapper\" *ngIf=\"departmentPanelOpen\">\n <input type=\"text\" placeholder=\"Search...\" (input)=\"filterDepartmentData($event)\"\n class=\"search-input\" (keydown.space)=\"$event.stopPropagation()\"\n (keydown)=\"$event.stopPropagation()\">\n </div>\n <mat-option [value]=\"item?.identifier\"\n *ngFor=\"let item of filteredDepartmentList\">{{item?.orgName}}</mat-option>\n <!-- selected departments not present in the current search/page:\n kept rendered (hidden) so mat-select does not clear the selection -->\n <mat-option [value]=\"item?.identifier\" style=\"display: none\"\n *ngFor=\"let item of pinnedDepartmentOptions\">{{item?.orgName}}</mat-option>\n <mat-option disabled *ngIf=\"departmentLoading\">Loading...</mat-option>\n <mat-option disabled\n *ngIf=\"!departmentLoading && !filteredDepartmentList?.length\">No department found</mat-option>\n\n </mat-select>\n </mat-form-field>\n </div>\n\n <!-- Date Range -->\n <div>\n <label>Date Range </label>\n <mat-form-field appearance=\"outline\">\n\n <input matInput ngxDaterangepickerMd formControlName=\"dateRange\" style=\"margin:10px\"\n placeholder=\"Select date range\" [autoApply]=\"true\" [linkedCalendars]=\"true\"\n [locale]=\"{ format: 'DD MMM YYYY' }\" />\n </mat-form-field>\n </div>\n\n\n </div>\n </mat-card>\n </form>\n\n <!-- OVERVIEW METRICS -->\n <h2 class=\"section-title\">\n <mat-icon>dashboard</mat-icon>\n Overview Metrics\n </h2>\n\n <div class=\"card-grid\">\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">States/Ministries which generated Role Mapping</p>\n <h2>{{this.dashboardData?.ministry_count}}</h2>\n <!-- <p class=\"card-subtitle\">At least 1 designation/role mapping</p> -->\n </div>\n <mat-icon class=\"icon primary\">public</mat-icon>\n </div>\n </mat-card>\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Departments which generated Role Mapping</p>\n <h2>{{this.dashboardData?.department_count}}</h2>\n <!-- <p class=\"card-subtitle\">At least 1 designation/role mapping</p> -->\n </div>\n <mat-icon class=\"icon teal\">apartment</mat-icon>\n </div>\n </mat-card>\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Total Capacity Building Plans Created</p>\n <h2>{{this.dashboardData?.total_cbp_plan_count}}</h2>\n </div>\n <mat-icon class=\"icon green\">description</mat-icon>\n </div>\n </mat-card>\n\n </div>\n\n <!-- COMPETENCIES -->\n <h2 class=\"section-title\">\n <mat-icon>psychology</mat-icon>\n Competencies Recommended\n </h2>\n\n <div class=\"card-grid\">\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Behavioral Competencies</p>\n <h2>{{this.dashboardData?.behavioral_competencies_count}}</h2>\n </div>\n <mat-icon class=\"icon purple\">psychology</mat-icon>\n </div>\n </mat-card>\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Functional Competencies</p>\n <h2>{{this.dashboardData?.functional_competencies_count}}</h2>\n </div>\n <mat-icon class=\"icon teal\">settings</mat-icon>\n </div>\n </mat-card>\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Domain Competencies</p>\n <h2>{{this.dashboardData?.domain_competencies_count}}</h2>\n </div>\n <mat-icon class=\"icon orange\">tune</mat-icon>\n </div>\n </mat-card>\n\n </div>\n\n <!-- DOCUMENTS -->\n <h2 class=\"section-title\">\n <mat-icon>menu_book</mat-icon>\n Documents & Course Recommendations\n </h2>\n\n <div class=\"card-grid\">\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Total Documents Uploaded</p>\n <h2>{{this.dashboardData?.total_documents}}</h2>\n <!-- <p class=\"card-subtitle\">Min 1, Max 10 per role mapping</p> -->\n </div>\n <mat-icon class=\"icon amber\">upload_file</mat-icon>\n </div>\n </mat-card>\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Role Mappings with Course Recommendations</p>\n <h2>{{this.dashboardData?.role_mappings_with_recommendations}}</h2>\n <!-- <p class=\"card-subtitle\">8500 of 50,000 role mappings</p> -->\n </div>\n <mat-icon class=\"icon green\">menu_book</mat-icon>\n </div>\n </mat-card>\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Course Recommendations Saved</p>\n <h2>{{this.dashboardData?.saved_recommended_courses_count}}</h2>\n <!-- <p class=\"card-subtitle\">{{this.dashboardData?.saved_recommended_courses_count}} of 8500\n recommendations</p> -->\n </div>\n <mat-icon class=\"icon teal\">save</mat-icon>\n </div>\n </mat-card>\n\n </div>\n\n <!-- GAP ANALYSIS -->\n <div class=\"gap-section\">\n <h2 class=\"section-title warning\">\n <mat-icon>warning</mat-icon>\n Gap Analysis\n </h2>\n\n <div class=\"card-grid-alone\">\n\n <mat-card class=\"metric-card warning-bg\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Competencies Without Courses</p>\n <h2>{{this.dashboardData?.competencies_without_courses}}</h2>\n <p class=\"card-subtitle\">Unique competencies with no identified courses</p>\n </div>\n <mat-icon class=\"icon red\">cancel</mat-icon>\n </div>\n </mat-card>\n\n <!-- <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Manually Added Courses</p>\n <h2>-</h2>\n <p class=\"card-subtitle\">Competencies with user-added courses</p>\n </div>\n <mat-icon class=\"icon green\">add_circle</mat-icon>\n </div>\n </mat-card> -->\n\n </div>\n\n <div class=\"card-grid mt-2\">\n\n <mat-card class=\"metric-card warning-bg\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Behavioral Competencies Without Courses</p>\n <h2>{{this.dashboardData?.behavioral_without_courses}}</h2>\n </div>\n <mat-icon class=\"icon red\">cancel</mat-icon>\n </div>\n </mat-card>\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Functional Competencies Without Courses</p>\n <h2>{{this.dashboardData?.functional_without_courses}}</h2>\n </div>\n <mat-icon class=\"icon red\">cancel</mat-icon>\n </div>\n </mat-card>\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Domain Competencies Without Courses</p>\n <h2>{{this.dashboardData?.domain_without_courses}}</h2>\n </div>\n <mat-icon class=\"icon red\">cancel</mat-icon>\n </div>\n </mat-card>\n\n </div>\n </div>\n\n <!-- OVERVIEW METRICS -->\n <h2 class=\"section-title\">\n <mat-icon>dashboard</mat-icon>\n Users and Role Mapping Metrics\n </h2>\n\n <div class=\"card-grid\">\n\n <mat-card class=\"metric-card\" *ngIf=\"!isSuperAdmin\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Unique Users (Credentials)</p>\n <h2>{{this.dashboardData?.total_users}}</h2>\n </div>\n <mat-icon class=\"icon primary\">public</mat-icon>\n </div>\n </mat-card>\n\n <mat-card class=\"metric-card\" *ngIf=\"!isSuperAdmin\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Unique Users with Role Mappings</p>\n <h2>{{this.dashboardData?.users_with_role_mappings}}</h2>\n <!-- <p class=\"card-subtitle\">Generated atleast 1 role mapping</p> -->\n </div>\n <mat-icon class=\"icon teal\">apartment</mat-icon>\n </div>\n </mat-card>\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Total Designation/Role Mappings Generated</p>\n <h2>{{this.dashboardData?.total_role_mappings}}</h2>\n </div>\n <mat-icon class=\"icon green\">description</mat-icon>\n </div>\n </mat-card>\n\n <mat-card class=\"metric-card\">\n <div class=\"card-content\">\n <div>\n <p class=\"card-title\">Unique Role Mappings</p>\n <h2>{{this.dashboardData?.unique_role_mappings}}</h2>\n <!-- <p class=\"card-subtitle\">10,000 unique of 50,000 total</p> -->\n </div>\n <mat-icon class=\"icon teal\">apartment</mat-icon>\n </div>\n </mat-card>\n\n </div>\n </div>\n</div>", styles: [".dashboard-wrapper{background:transparent;min-height:100vh;padding:24px 10px;margin:0 30px 0 60px}.dashboard-container{max-width:auto;margin:0 auto}.section-title{display:flex;align-items:center;gap:10px;font-size:18px;font-weight:600;color:#000;margin:20px 0}.card-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:32px}.card-grid-alone{display:grid;grid-template-columns:repeat(1,1fr);gap:32px}.metric-card{padding:24px;border-radius:12px;box-shadow:none;border:1px solid #e5e7eb}.card-content{display:flex;justify-content:space-between;align-items:center}.card-title{font-size:14px;color:#6b7280;margin-bottom:6px}.metric-card h2{font-size:28px;font-weight:700;color:#000;margin:0}.card-subtitle{font-size:12px;color:#9ca3af;margin-top:6px}.icon{font-size:28px;width:40px;height:40px;border-radius:8px;display:flex;align-items:center;justify-content:center}.primary{color:#2563eb}.teal{color:#059669}.green{color:#16a34a}.purple{color:#9333ea}.orange{color:#f97316}.amber{color:#f59e0b}.red,.section-title.warning{color:#dc2626}.warning-card{background:#fdeaea;border:1px solid #f5c2c7}.filters-card{padding:20px 24px;border-radius:12px;border:1px solid #e5e7eb;box-shadow:none}.filters-header{display:flex;align-items:center;gap:8px;font-weight:600;margin-bottom:16px}.filters-row{display:flex;gap:24px;flex-wrap:wrap}.filters-row mat-form-field{flex:1;min-width:220px}:host ::ng-deep .mat-form-field-appearance-outline .mat-form-field-outline{color:#ccc}:host ::ng-deep .mat-form-field-appearance-outline.mat-focused .mat-form-field-outline-thick{color:#1b4ca1;border-color:#1b4ca1!important}::ng-deep .select-search-panel .mat-option.mat-selected:not(.mat-option-disabled){background-color:#1b4ca1!important;color:#fff!important}:host ::ng-deep .mat-form-field-appearance-outline{border-radius:25px;border:1px solid #ccc}:host ::ng-deep .mat-form-field-focused .mat-form-field-appearance-outline{border-color:#1b4ca1!important}:host ::ng-deep .mat-form-field-appearance-outline .mat-form-field-outline-start{border-radius:25px 0 0 25px;border:none!important}:host ::ng-deep .mat-form-field-appearance-outline .mat-form-field-outline-end{border-right:none!important;border:none!important;border-radius:0 25px 25px 0}:host ::ng-deep .mat-form-field-appearance-outline .mat-form-field-outline-gap{border:none!important;border-radius:25px}:host::ng-deep .mat-form-field-appearance-outline .mat-form-field-infix{background-color:transparent!important}.dashboard-container .mat-card{background-color:#fff}.gap-title{color:#b91c1c}.gap-section{background-color:#d926621a;padding:10px;border-radius:12px;border:1px solid #f5c2c7;margin:16px 0}.gap-card{background-color:#d926621a;border:1px solid #f8d7da}.gap-card h2{color:#dc2626}@media (max-width: 1200px){.card-grid{grid-template-columns:repeat(2,1fr)}}@media (max-width: 768px){.card-grid{grid-template-columns:1fr}}.mat-select-panel .search-wrapper{width:100%!important;box-sizing:border-box;padding:8px;position:sticky;top:0;z-index:2;background:#fff}.search-input{width:100%;padding:6px 10px;border:1px solid #ccc;border-radius:6px;outline:none;box-sizing:border-box}.mat-select-panel mat-option{padding-top:10px}::ng-deep .mat-select-panel-wrap{overflow:visible!important;padding:0;margin-top:42px}::ng-deep .mat-select-panel{border:1px solid #ccc!important;box-sizing:border-box;max-height:250px}::ng-deep .select-with-search.mat-select-panel{padding-top:0;overflow:auto}::ng-deep .select-with-search .search-wrapper{position:sticky;top:0;z-index:10;background:#fff;padding:8px;border-bottom:1px solid #e0e0e0}::ng-deep .select-with-search .search-input{width:100%;padding:6px 10px;border:1px solid #ccc;border-radius:6px;outline:none;box-sizing:border-box}::ng-deep .select-with-search mat-option:first-of-type{margin-top:4px}::ng-deep .md-drppicker.ltr{min-width:500px!important}.sub-heading p{color:#000;font-family:Montserrat;font-size:18px;font-style:normal;font-weight:600;line-height:normal}.mb-10{margin-bottom:10px}.cursor-pointer{cursor:pointer}\n"] }]
|
|
8101
8105
|
}], ctorParameters: function () { return [{ type: i2.FormBuilder }, { type: SharedService }, { type: i3$1.MatSnackBar }, { type: i3.Router }]; }, propDecorators: { departmentSelect: [{
|
|
8102
8106
|
type: ViewChild,
|
|
8103
8107
|
args: ['departmentSelect', { static: false }]
|
|
@@ -11337,6 +11341,8 @@ class RoleMappingGenerationComponent {
|
|
|
11337
11341
|
this.departmentPanelOpen = false;
|
|
11338
11342
|
this.filteredList = [];
|
|
11339
11343
|
this.filteredDepartmentList = [];
|
|
11344
|
+
this.selectedDepartmentObj = null;
|
|
11345
|
+
this.pinnedDepartmentOptions = [];
|
|
11340
11346
|
this.departmentPageSize = 50;
|
|
11341
11347
|
this.departmentOffset = 0;
|
|
11342
11348
|
this.departmentHasMore = true;
|
|
@@ -11472,21 +11478,8 @@ class RoleMappingGenerationComponent {
|
|
|
11472
11478
|
this.selectedMinistryType = this.cbpFinalObj?.ministry.sbOrgType;
|
|
11473
11479
|
await this.getMinistryData();
|
|
11474
11480
|
if (this.cbpFinalObj?.ministry?.sbOrgType) {
|
|
11475
|
-
|
|
11476
|
-
|
|
11477
|
-
this.departmentData = res;
|
|
11478
|
-
this.filteredDepartmentList = res;
|
|
11479
|
-
}
|
|
11480
|
-
else {
|
|
11481
|
-
this.snackBar.open('No Department Found for Selected Ministry', 'X', {
|
|
11482
|
-
duration: 3000,
|
|
11483
|
-
panelClass: ['snackbar-error']
|
|
11484
|
-
});
|
|
11485
|
-
this.sharedService.cbpPlanFinalObj['department_name'] = '';
|
|
11486
|
-
this.sharedService.cbpPlanFinalObj['departments'] = '';
|
|
11487
|
-
localStorage.setItem('cbpPlanFinalObj', JSON.stringify(this.sharedService.cbpPlanFinalObj));
|
|
11488
|
-
}
|
|
11489
|
-
});
|
|
11481
|
+
this.departmentMinistryId = this.cbpFinalObj?.ministry?.identifier;
|
|
11482
|
+
this.loadDepartments(true);
|
|
11490
11483
|
}
|
|
11491
11484
|
this.roleMappingForm = this.fb.group({
|
|
11492
11485
|
ministryType: [this.selectedMinistryType, Validators.required],
|
|
@@ -12221,7 +12214,7 @@ class RoleMappingGenerationComponent {
|
|
|
12221
12214
|
}
|
|
12222
12215
|
});
|
|
12223
12216
|
this.filteredDepartmentList = reset ? items : [...this.filteredDepartmentList, ...items];
|
|
12224
|
-
|
|
12217
|
+
this.ensureSelectedDepartmentOption();
|
|
12225
12218
|
if (reset && !items.length && !this.departmentSearchQuery && this.selectedMinistryType === 'ministry') {
|
|
12226
12219
|
this.snackBar.open('No Department Found for Selected Ministry', 'X', {
|
|
12227
12220
|
duration: 3000,
|
|
@@ -12240,22 +12233,21 @@ class RoleMappingGenerationComponent {
|
|
|
12240
12233
|
}
|
|
12241
12234
|
});
|
|
12242
12235
|
}
|
|
12243
|
-
//
|
|
12244
|
-
// search/page from the server does not include
|
|
12245
|
-
//
|
|
12246
|
-
|
|
12247
|
-
|
|
12248
|
-
|
|
12249
|
-
|
|
12250
|
-
|
|
12251
|
-
|
|
12252
|
-
|
|
12253
|
-
|
|
12254
|
-
|
|
12255
|
-
|
|
12256
|
-
|
|
12257
|
-
|
|
12258
|
-
// }
|
|
12236
|
+
// mat-select only displays a selection while a mat-option with that value is
|
|
12237
|
+
// rendered; when the current search/page from the server does not include the
|
|
12238
|
+
// selected department, it is rendered as a hidden option instead of in the list
|
|
12239
|
+
ensureSelectedDepartmentOption() {
|
|
12240
|
+
const selectedId = this.roleMappingForm?.get('departments')?.value;
|
|
12241
|
+
if (!selectedId || Array.isArray(selectedId)
|
|
12242
|
+
|| this.filteredDepartmentList.some(d => d?.identifier === selectedId)) {
|
|
12243
|
+
this.pinnedDepartmentOptions = [];
|
|
12244
|
+
return;
|
|
12245
|
+
}
|
|
12246
|
+
const selected = this.departmentData.find(d => d?.identifier === selectedId)
|
|
12247
|
+
|| (this.selectedDepartmentObj?.identifier === selectedId ? this.selectedDepartmentObj : null)
|
|
12248
|
+
|| (this.cbpFinalObj?.department_name ? { identifier: selectedId, orgName: this.cbpFinalObj.department_name } : null);
|
|
12249
|
+
this.pinnedDepartmentOptions = selected ? [selected] : [];
|
|
12250
|
+
}
|
|
12259
12251
|
filterData(event) {
|
|
12260
12252
|
if (event && event.target && event.target.value) {
|
|
12261
12253
|
const s = event.target.value.toLowerCase();
|
|
@@ -12285,6 +12277,9 @@ class RoleMappingGenerationComponent {
|
|
|
12285
12277
|
const selectedMinistry = this.ministryData.find(item => item.identifier === formData.ministry);
|
|
12286
12278
|
this.sharedService.cbpPlanFinalObj['ministry'] = selectedMinistry;
|
|
12287
12279
|
const departmentName = this.departmentData.find(u => u.identifier === formData.departments);
|
|
12280
|
+
if (departmentName) {
|
|
12281
|
+
this.selectedDepartmentObj = departmentName;
|
|
12282
|
+
}
|
|
12288
12283
|
this.sharedService.cbpPlanFinalObj['department_name'] = departmentName?.orgName;
|
|
12289
12284
|
localStorage.setItem('cbpPlanFinalObj', JSON.stringify(this.sharedService.cbpPlanFinalObj));
|
|
12290
12285
|
this.getUploadedDocuments();
|
|
@@ -12335,11 +12330,11 @@ class RoleMappingGenerationComponent {
|
|
|
12335
12330
|
});
|
|
12336
12331
|
}
|
|
12337
12332
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: RoleMappingGenerationComponent, deps: [{ token: EventService }, { token: SharedService }, { token: i2.FormBuilder }, { token: i3$1.MatSnackBar }, { token: i1$1.MatDialog }, { token: RoleMappingService }, { token: i3.Router }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
12338
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.12", type: RoleMappingGenerationComponent, selector: "app-role-mapping-generation", inputs: { loginStatusFlag: "loginStatusFlag" }, outputs: { successRoleMapping: "successRoleMapping", alreadyAvailableRoleMapping: "alreadyAvailableRoleMapping", loginSuccess: "loginSuccess" }, viewQueries: [{ propertyName: "pdfContent", first: true, predicate: ["pdfContent"], descendants: true }, { propertyName: "departmentSelect", first: true, predicate: ["departmentSelect"], descendants: true }], usesOnChanges: true, ngImport: i0, template: "<div class=\"container\">\n <!-- <input class=\"btn-active\" type=\"button\" value=\"Download as PDF\" (click)=\"downloadPDF()\" /> -->\n <div class=\"logo-container\" *ngIf=\"login\">\n <div>\n <span class=\"ai-loader-icon-medium\"><img src=\"assets/icons/ai-loader.gif\"></span>\n </div>\n <div>\n <h2 class=\"highlight-ai\">\n <span>iGOT AI Driven CBP</span>\n </h2>\n </div>\n <!-- <div class=\"sub-heading\">\n <p>Build Your Capacity With Customized Role Mapping</p>\n </div> -->\n </div>\n <mat-card *ngIf=\"login && roleMappingForm\" class=\"mt-2\" [formGroup]=\"roleMappingForm\">\n <div class=\"depatment-container\">\n <!-- <div class=\"section-header\">-->\n <!-- <div class=\"sub-heading\">-->\n <!-- <p>Choose Your Department</p>-->\n <!-- </div>-->\n <!-- </div>-->\n\n <div class=\"radio-group mt-4\">\n <mat-radio-group class=\"radio-btn-group\" formControlName=\"ministryType\"\n [(ngModel)]=\"selectedMinistryType\" (change)=\"onMinistryTypeChange($event)\">\n\n <!-- Left radio button -->\n <mat-radio-button value=\"ministry\" class=\"radio-btn left-radio\">\n <span class=\"radio-label\">\n <!-- <mat-icon class=\"radio-icon\" [ngClass]=\"selectedMinistryType === 'center'? 'checked-label':''\">domain</mat-icon> -->\n <span [ngClass]=\"selectedMinistryType === 'ministry'? 'checked-label':''\">Centre</span>\n </span>\n </mat-radio-button>\n\n <!-- Right radio button -->\n <mat-radio-button value=\"state\" class=\"radio-btn right-radio\">\n <span class=\"radio-label\">\n <!-- <mat-icon class=\"radio-icon\" [ngClass]=\"selectedMinistryType === 'state'? 'checked-label':''\">location_on</mat-icon> -->\n <span [ngClass]=\"selectedMinistryType === 'state'? 'checked-label':''\">State</span>\n </span>\n </mat-radio-button>\n\n </mat-radio-group>\n </div>\n <div class=\"mt-4\">\n\n <label class=\"label\">\n <span *ngIf=\"selectedMinistryType === 'ministry'\">Ministry</span>\n <span *ngIf=\"selectedMinistryType === 'state'\">State</span>\n </label>\n <div class=\"mt-2 search-box-with-select\">\n\n <mat-form-field appearance=\"fill\"\n style=\"background: white; border-radius: 25px; padding: 0 12px; border: 1px solid #ccc;width: 100%;\">\n <mat-select panelClass=\"select-with-search\"\n [placeholder]=\"selectedMinistryType === 'ministry' ? 'Select Ministry/ Department':'Select State'\"\n (selectionChange)=\"onMinistryChange($event)\" formControlName=\"ministry\"\n style=\"border-radius: 25px; background: white; width:100%\"\n (openedChange)=\"onOpened($event)\">\n <div class=\"search-wrapper\" *ngIf=\"panelOpen\">\n <input type=\"text\" placeholder=\"Search...\" (input)=\"filterData($event)\"\n class=\"search-input\" (keydown.space)=\"$event.stopPropagation()\"\n (keydown)=\"$event.stopPropagation()\">\n </div>\n <!-- [selected]=\"selectedMinistryId === item?.identifier\" -->\n <mat-option [value]=\"item?.identifier\"\n *ngFor=\"let item of filteredList\">{{item?.orgName}}</mat-option>\n </mat-select>\n </mat-form-field>\n </div>\n </div>\n <div class=\"mt-4\" *ngIf=\"departmentData?.length\">\n <label class=\"label\">Department</label>\n <div class=\"mt-2\">\n <mat-form-field appearance=\"fill\"\n style=\"background: white; border-radius: 25px; padding: 0 12px;border: 1px solid #ccc;\">\n <mat-select #departmentSelect panelClass=\"select-with-search\" placeholder=\"Select Department\"\n formControlName=\"departments\" style=\"border-radius: 25px; background: white;\"\n (selectionChange)=\"onDepartmentChange()\" (openedChange)=\"onOpenedDepartment($event)\">\n <div class=\"search-wrapper\" *ngIf=\"departmentPanelOpen\">\n <input type=\"text\" placeholder=\"Search...\" (input)=\"filterDepartmentData($event)\"\n class=\"search-input\" (keydown.space)=\"$event.stopPropagation()\"\n (keydown)=\"$event.stopPropagation()\">\n </div>\n <mat-option [value]=\"item?.identifier\"\n *ngFor=\"let item of filteredDepartmentList\">{{item?.orgName}}</mat-option>\n <mat-option disabled *ngIf=\"departmentLoading\">Loading...</mat-option>\n <mat-option disabled\n *ngIf=\"!departmentLoading && !filteredDepartmentList?.length\">No department found</mat-option>\n\n </mat-select>\n </mat-form-field>\n </div>\n\n </div>\n <!-- <div class=\"mt-4\">\n <label class=\"label\">Sector</label>\n <div>\n <mat-form-field appearance=\"fill\" style=\"background: white; border-radius: 25px; padding: 0 12px;\">\n <mat-select placeholder=\"Select Sector\" multiple formControlName=\"sectors\"\n style=\"border-radius: 25px; background: white;\">\n <mat-option [value]=\"item?.value\"\n *ngFor=\"let item of sectorData\">{{item?.value}}</mat-option>\n\n </mat-select>\n </mat-form-field>\n </div>\n\n </div> -->\n <!-- *ngIf=\"roleMappingForm.get('ministryType')?.value === 'state'\" -->\n <div class=\"mt-4 additional-details\">\n <textarea rows=\"5\" placeholder=\"Additional details\" formControlName=\"additionalDetails\"></textarea>\n </div>\n <div class=\"mt-4\">\n\n <button [ngClass]=\"disableUploadDocument ? 'btn-active-primary-disable':'btn-active-primary'\" class=\"\"\n [disabled]=\"disableUploadDocument\" mat-raised-button color=\"primary\" (click)=\"goToUploadDocument()\">\n <mat-icon>upload</mat-icon> Manage Documents\n </button>\n </div>\n <!-- *ngIf=\"roleMappingForm.get('ministryType')?.value === 'state'\" -->\n <!-- <div class=\"mt-4 section\" >\n <div class=\"sub-heading\">\n <p>Upload Document (PDF)</p>\n </div>\n <div class=\"file-upload-wrapper\">\n <label for=\"uploadDoc\" class=\"file-upload-label\">\n <span class=\"file-upload-icon\">\uD83D\uDCCE</span>\n <span *ngIf=\"!uploadedFile || uploadedFile.length === 0\">\n Choose up to 3 files (PDF/TXT)\n </span>\n <div *ngIf=\"uploadedFile?.length > 0\" class=\"file-list\">\n <div *ngFor=\"let file of uploadedFile; let i = index\" class=\"file-item\">\n {{ file.name }}\n <span class=\"remove-file-icon\" (click)=\"removeFile(i);$event.preventDefault()\">\n <mat-icon>close</mat-icon>\n </span>\n </div>\n </div>\n </label>\n <input\n id=\"uploadDoc\"\n type=\"file\"\n multiple\n (change)=\"onFileChange($event)\"\n hidden\n /> \n\n <small class=\"file-upload-hint\">Max file size: {{maxFileSizeMB}}MB</small>\n\n <input id=\"uploadDoc\" multiple type=\"file\" (change)=\"onFileChange($event)\"\n accept=\".pdf,.doc,.docx,.xls,.xlsx,.txt\" class=\"file-upload-input\" />\n\n <div *ngIf=\"uploadError\" class=\"error\">{{ uploadError }}</div>\n </div>\n </div> -->\n <!-- *ngIf=\"roleMappingForm.get('ministryType')?.value === 'state'\" -->\n <!-- <div class=\"mt-2 section\">\n <div class=\"disclaimer-text\">\n <p>Disclaimer: Please do not upload any confidential documents. </p>\n </div>\n </div> -->\n <div class=\"mt-2\" *ngIf=\"documents?.length < 1 && !(roleMappingForm?.invalid) || showWorkAllocationOrderDocumentMissing\">\n <p><span style=\"font-size: .875rem;font-weight: bold;\">Note: </span>\n <span class=\"error\">Please upload the Work Allocation Order document to generate the Capacity Building Plan (CBP)</span>\n </p>\n </div>\n <!-- <div class=\"mt-2\" *ngIf=\"documents?.length > 0\">\n <p *ngIf=\"workAllocationOrderDocumentMissing\"><span style=\"font-size: .875rem;font-weight: bold;\">Note:\n </span>\n <span class=\"error\">Please upload the Work Allocation Order document to generate the Capacity\n Building Plan (CBP)</span>\n </p>\n </div> -->\n <div class=\"mt-4\">\n <input\n [disabled]=\"roleMappingForm?.invalid || (roleMappingForm.get('ministryType')?.value === 'state' && !roleMappingForm.get('departments')?.value) || loading || documents?.length < 1 \"\n [ngClass]=\"roleMappingForm?.invalid || (roleMappingForm.get('ministryType')?.value === 'state' && !roleMappingForm.get('departments')?.value) || loading || documents?.length < 1 ? 'btn-disable':'btn-active'\"\n type=\"button\" [value]=\"loading ? 'Generating CBP...' : 'Generate CBP'\"\n (click)=\"onGenerateRoleMapping()\" />\n </div>\n </div>\n </mat-card>\n\n</div>\n<!-- <div *ngIf=\"!login\">\n <app-login (success)=\"loginStatus($event)\"></app-login>\n </div> -->\n\n<div class=\"overlay-loader\" *ngIf=\"apiLoading\">\n <mat-spinner diameter=\"50\"></mat-spinner>\n</div>\n\n<div class=\"overlay-loader\" *ngIf=\"loading\">\n <div class=\"loading-content\">\n <mat-spinner diameter=\"50\"></mat-spinner>\n <div class=\"loading-text mt-3\">\n <p class=\"main-message\">{{ currentProcessingStage || 'Preparing CBP Plan generation...' }}</p>\n <div class=\"progress-details\">\n <div class=\"progress-indicator\" *ngIf=\"chunks.length > 0\">\n <div class=\"progress-bar-container\">\n <div class=\"progress-bar\" [style.width.%]=\"getDisplayProgressPercentage()\">\n </div>\n </div>\n <small class=\"progress-text\">{{ getDisplayProgressPercentage() }}% Complete</small>\n </div>\n <small class=\"time-estimate\">\n Real-time streaming in progress. This may take 2-3 minutes.\n </small>\n </div>\n </div>\n </div>\n</div>", styles: [".container{width:40%}.sub-heading p{color:#000;font-family:Montserrat;font-size:18px;font-style:normal;font-weight:600;line-height:normal}.radio-btn-group{display:flex;justify-content:space-between;border-radius:8px;padding:12px 16px;align-items:center;max-width:600px;margin:0 auto;gap:20px}.radio-btn{flex:1;display:flex;align-items:center;justify-content:center;padding:10px;border-radius:6px;transition:background-color .3s ease}.radio-btn,.radio-btn:hover{background-color:#eef2f7}.radio-label{display:flex;align-items:center;gap:6px;font-weight:500;font-size:16px}.radio-icon{font-size:24px;color:gray}.radio-label{color:#000;font-family:Lato;font-size:18px;font-style:normal;font-weight:400;line-height:normal}.label{color:var(--Body-Text-Body-Color, #212529);font-family:Lato;font-size:18px;font-style:normal;font-weight:700;line-height:150%}::ng-deep mat-form-field{background-color:#fff!important;border-radius:25px!important;padding-left:12px;padding-right:12px;height:42px;width:100%}::ng-deep mat-select{border-radius:25px!important;background-color:#fff!important}::ng-deep .mat-select-panel{background-color:#fff!important}::ng-deep .mat-select-panel .mat-option{border-radius:0!important}::ng-deep mat-form-field .mat-form-field-underline{display:none!important}::ng-deep mat-select .mat-select-placeholder{color:#0006;font-family:Lato;font-size:14px;font-style:normal;font-weight:400;line-height:normal}::ng-deep mat-select .mat-select-value-text{color:#000;font-family:Lato;font-size:14px;font-style:normal;font-weight:400;line-height:normal;line-height:normal!important;padding-top:0!important;padding-bottom:0!important}::ng-deep mat-select .mat-select-value{display:flex!important;align-items:center!important;height:100%!important}.additional-details textarea{display:flex;padding:16px 16px 0;flex-direction:column;align-items:flex-start;gap:10px;flex:1 0 0;align-self:stretch;width:100%;color:#0006;font-family:Lato;font-size:14px;font-style:normal;font-weight:400;line-height:normal;border:none;outline:none;resize:none;box-shadow:none;border-radius:4px;border:1px solid #ccc}.section-header{display:flex;flex-direction:row;align-items:center;justify-content:center}.btn-disable{border-radius:var(--Radius-Full-Round, 9999999px);opacity:.4;background:var(--Primary-KB-Primary-Light, #1B4CA1);color:var(--white-kb-white-100, #FFF);text-align:center;font-family:Lato;font-size:14px;font-style:normal;font-weight:700;line-height:normal;display:flex;height:48px;padding:0 16px;justify-content:center;align-items:center;gap:8px;border:none;width:100%}.btn-active{border-radius:var(--Radius-Full-Round, 9999999px);opacity:1;background:var(--Primary-KB-Primary-Light, #1B4CA1);color:var(--white-kb-white-100, #FFF);text-align:center;font-family:Lato;font-size:14px;font-style:normal;font-weight:700;line-height:normal;display:flex;height:48px;padding:0 16px;justify-content:center;align-items:center;gap:8px;border:none;width:100%}.btn-group{display:flex;flex-direction:row;justify-content:space-between}.pl-2{padding-left:10px}.search-filter-section{display:flex;flex-direction:row;justify-content:space-between}.search .rsearch{position:relative}.search .search-icon{position:absolute;top:15px;font-size:20px;left:10px}.search .sinput{border-radius:4px;border:1px solid #d5d0d0;padding:15px 36px;font:400 14px Lato}.select-map-route-container{display:flex;flex-direction:row}.selected-mapping-route p{color:#1b4ca1;font-family:Lato;font-size:20px;font-style:normal;font-weight:400;line-height:normal;text-decoration-line:underline;text-decoration-style:solid;-webkit-text-decoration-skip:ink;text-decoration-skip-ink:auto;text-decoration-thickness:auto;text-underline-offset:auto;text-underline-position:from-font}.edit-plan{display:flex;padding:4px;justify-content:center;align-items:center;gap:8px;border-radius:4px;background:#1b4ca129;color:#1b4ca1;font-family:Lato;font-size:14px;font-style:normal;font-weight:400;line-height:normal;margin-left:10px}.search-container{display:flex;flex-direction:row}.course-container{display:flex;width:100%;padding:16px;flex-direction:column;align-items:flex-start;gap:24px;grid-row:2/span 1;grid-column:1/span 1;border-radius:12px;border:1px solid var(--borders-black-border-16-black, rgba(0, 0, 0, .16));background:#fff}.course-header{display:flex;flex-direction:row;justify-content:space-between;width:100%}.course-pill{display:flex;height:24px;padding:8px;align-items:center;gap:4px;border-radius:16px;border:1px solid var(--borders-border-fill-focussed-4-light-100, #EF951E);background:#fefaf4}.ai-recommened-pill{display:flex;padding:4px 8px;align-items:center;gap:8px;border-radius:var(--Radius-4, 4px);border:1px solid #1B4CA1;background:#1b4ca129}.igot-platform-pill{display:flex;padding:4px 8px;align-items:center;gap:8px;border-radius:var(--Radius-4, 4px);border:1px solid #EF951E;background:#ef951e29}.course-title{color:var(--Primary-KB-Primary-Light, #1B4CA1);font-family:Montserrat;font-size:20px;font-style:normal;font-weight:600;line-height:30px}.course-desc{color:#0009;font-family:Lato;font-size:14px;font-style:normal;font-weight:400;line-height:normal}.relevancy,.competencies-matched{color:var(--accessbility-shades-with-opacity-kb-greys-black-60, rgba(0, 0, 0, .6));font-family:Lato;font-size:14px;font-style:normal;font-weight:400;line-height:normal;align-items:center}.percentage{color:#1d8923;font-family:Lato;font-size:14px;font-style:normal;font-weight:800;line-height:normal}.relevancy-container,.competencies-matched-container{display:flex;flex-direction:row;align-items:center}.dash{padding:0 5px}::ng-deep .mat-radio-checked .mat-radio-inner-circle{background:#1b4ca1!important}.course-list-container{display:flex;flex-wrap:wrap;gap:16px}.course-list-item{flex:0 0 48%;box-sizing:border-box;border:1px solid #ccc;padding:16px;background-color:#fff;border-radius:8px}.checked-course-container{display:flex}.ml-2{margin-left:8px}::ng-deep .mat-checkbox-checked .mat-checkbox-background{background:#1b4ca1!important}.ai-recommened-pill-text,.igot-platform-pill-text{color:#1b4ca1;font-family:Lato;font-size:12px;font-style:normal;font-weight:700;line-height:normal}.course-pill-text{color:var(--accessbility-shades-without-opacity-kb-greys-black-87, #212121);text-align:center;font-family:Poppins;font-size:12px;font-style:normal;font-weight:400;line-height:normal}.ai-loader-icon img,.igot-platform-icon img{width:15.714px;height:15.714px;flex-shrink:0}.competency-container{display:flex}.outside-layer{display:flex;padding:4px 12px;justify-content:center;align-items:center;gap:16px;border-radius:12px 4px 4px 12px;border-left:2px solid #F8B861;background:#fde8cc;width:132px}.suggest-courses-header{display:flex;flex-direction:row;justify-content:space-between}.suggest-course-control{display:flex;flex-direction:row}.course-card-container{width:172px;border-radius:3.307px;border:.827px solid var(--borders-border-8-black, rgba(0, 0, 0, .08));background-color:#fff}.highlight-ai{font-family:Montserrat;font-size:28px;font-style:normal;font-weight:600;line-height:normal;background:linear-gradient(90deg,#3b27ff,#2de3d6);background-clip:text;-webkit-background-clip:text;color:transparent;-webkit-text-fill-color:transparent;display:inline-block}.ai-loader-icon-medium img{width:60px;height:60px;flex-shrink:0}.overlay-loader{position:fixed;top:0;left:0;width:100vw;height:100vh;background:#ffffffbf;z-index:9999;display:flex;justify-content:center;align-items:center}.overlay-loader .loading-content{display:flex;flex-direction:column;align-items:center;text-align:center;background:#fff;padding:2rem;border-radius:8px;box-shadow:0 4px 12px #00000026}.overlay-loader .loading-content .loading-text{color:#1b4ca1;font-family:Lato,sans-serif;min-width:300px}.overlay-loader .loading-content .loading-text .main-message{margin:0 0 16px;font-size:18px;font-weight:600;text-align:center}.overlay-loader .loading-content .loading-text .progress-details{margin-top:16px}.overlay-loader .loading-content .loading-text .progress-details .progress-indicator{margin-bottom:12px}.overlay-loader .loading-content .loading-text .progress-details .progress-indicator .progress-bar-container{width:100%;height:8px;background-color:#e0e0e0;border-radius:4px;overflow:hidden;margin-bottom:8px}.overlay-loader .loading-content .loading-text .progress-details .progress-indicator .progress-bar-container .progress-bar{height:100%;background:linear-gradient(90deg,#1b4ca1,#2563eb);border-radius:4px;transition:width .5s ease-in-out}.overlay-loader .loading-content .loading-text .progress-details .progress-indicator .progress-text{font-size:14px;font-weight:500;color:#1b4ca1;display:block;text-align:center}.overlay-loader .loading-content .loading-text .progress-details .time-estimate{color:#666;font-size:12px;font-style:italic;display:block;text-align:center;margin-top:8px}::ng-deep mat-option .mat-option-text{font-size:16px;color:#000;font-family:Lato}:host ::ng-deep mat-select .mat-select-placeholder{font-size:16px}:host mat-select .mat-select-value-text{font-size:16px!important}.logo-container{display:flex;justify-content:center;align-items:center;flex-direction:column}.depatment-container{background:#fff;border:1px solid rgba(27,76,161,.12);padding:5%;box-shadow:0 4px 6px #0000001a,0 8px 20px #00000026;border-radius:8px}.checked-label{color:#1b4ca1}.file-upload-wrapper{position:relative;margin:16px 0}.file-upload-label{display:inline-flex;align-items:center;padding:10px 16px;background-color:#1b4ca1;color:#fff;font-weight:500;cursor:pointer;transition:background-color .3s;-webkit-user-select:none;user-select:none;border-radius:8px}.file-upload-label:hover{background-color:#1b4ca1}.file-upload-icon{margin-right:8px;font-size:18px}.file-upload-input{display:none}.error{color:red;margin-top:6px;font-size:.875rem}.file-upload-hint{display:block;font-size:1rem;color:#000;font-family:Lato;font-size:14px;margin-top:4px;margin-bottom:8px}.disclaimer-text p{font-size:16px;font-family:Lato;font-weight:400}.mat-select-panel .search-wrapper{width:100%!important;box-sizing:border-box;padding:8px;position:sticky;top:0;z-index:2;background:#fff}.search-input{width:100%;padding:6px 10px;border:1px solid #ccc;border-radius:6px;outline:none;box-sizing:border-box}.mat-select-panel mat-option{padding-top:10px}::ng-deep .mat-select-panel-wrap{overflow:visible!important;padding:0;margin-top:42px}::ng-deep .mat-select-panel{border:1px solid #ccc!important;box-sizing:border-box;max-height:250px}::ng-deep .select-with-search.mat-select-panel{padding-top:0;overflow:auto}::ng-deep .select-with-search .search-wrapper{position:sticky;top:0;z-index:10;background:#fff;padding:8px;border-bottom:1px solid #e0e0e0}::ng-deep .select-with-search .search-input{width:100%;padding:6px 10px;border:1px solid #ccc;border-radius:6px;outline:none;box-sizing:border-box}::ng-deep .select-with-search mat-option:first-of-type{margin-top:4px}.btn-active-disable{border-radius:var(--Radius-Full-Round, 9999999px);opacity:.5;background:var(--Primary-KB-Primary-Light, #1B4CA1);color:var(--white-kb-white-100, #FFF);text-align:center;font-family:Lato;font-size:14px;font-style:normal;font-weight:700;line-height:normal;display:flex;height:48px;padding:0 16px;justify-content:center;align-items:center;gap:8px;border:none;width:100%}.btn-active-primary{border-radius:var(--Radius-Full-Round, 9999999px);opacity:1;background:var(--Primary-KB-Primary-Light, #fff);color:#1b4ca1;text-align:center;border:1px solid #1B4CA1!important;font-family:Lato;font-size:14px;font-style:normal;font-weight:700;line-height:normal;display:flex;height:48px;padding:0 16px;justify-content:center;align-items:center;gap:8px;border:none;width:100%}.btn-active-primary-disable{border-radius:var(--Radius-Full-Round, 9999999px);opacity:.5;background:var(--Primary-KB-Primary-Light, #fff);color:#1b4ca1;text-align:center;border:1px solid #1B4CA1!important;font-family:Lato;font-size:14px;font-style:normal;font-weight:700;line-height:normal;display:flex;height:48px;padding:0 16px;justify-content:center;align-items:center;gap:8px;border:none;width:100%}\n"], dependencies: [{ kind: "directive", type: i5.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i5.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i5.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i6.MatLegacyCard, selector: "mat-card", exportAs: ["matCard"] }, { kind: "directive", type: i2.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "component", type: i7.MatLegacyFormField, selector: "mat-form-field", inputs: ["color", "appearance", "hideRequiredMarker", "hintLabel", "floatLabel"], exportAs: ["matFormField"] }, { kind: "component", type: i8$1.MatLegacyButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { kind: "component", type: i9.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "directive", type: i13$1.MatLegacyRadioGroup, selector: "mat-radio-group", exportAs: ["matRadioGroup"] }, { kind: "component", type: i13$1.MatLegacyRadioButton, selector: "mat-radio-button", inputs: ["disableRipple", "tabIndex"], exportAs: ["matRadioButton"] }, { kind: "component", type: i10.MatLegacySelect, selector: "mat-select", inputs: ["disabled", "disableRipple", "tabIndex"], exportAs: ["matSelect"] }, { kind: "component", type: i11.MatLegacyOption, selector: "mat-option", exportAs: ["matOption"] }, { kind: "directive", type: i2.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i2.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "component", type: i11$1.MatProgressSpinner, selector: "mat-progress-spinner, mat-spinner", inputs: ["color", "mode", "value", "diameter", "strokeWidth"], exportAs: ["matProgressSpinner"] }] }); }
|
|
12333
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.12", type: RoleMappingGenerationComponent, selector: "app-role-mapping-generation", inputs: { loginStatusFlag: "loginStatusFlag" }, outputs: { successRoleMapping: "successRoleMapping", alreadyAvailableRoleMapping: "alreadyAvailableRoleMapping", loginSuccess: "loginSuccess" }, viewQueries: [{ propertyName: "pdfContent", first: true, predicate: ["pdfContent"], descendants: true }, { propertyName: "departmentSelect", first: true, predicate: ["departmentSelect"], descendants: true }], usesOnChanges: true, ngImport: i0, template: "<div class=\"container\">\n <!-- <input class=\"btn-active\" type=\"button\" value=\"Download as PDF\" (click)=\"downloadPDF()\" /> -->\n <div class=\"logo-container\" *ngIf=\"login\">\n <div>\n <span class=\"ai-loader-icon-medium\"><img src=\"assets/icons/ai-loader.gif\"></span>\n </div>\n <div>\n <h2 class=\"highlight-ai\">\n <span>iGOT AI Driven CBP</span>\n </h2>\n </div>\n <!-- <div class=\"sub-heading\">\n <p>Build Your Capacity With Customized Role Mapping</p>\n </div> -->\n </div>\n <mat-card *ngIf=\"login && roleMappingForm\" class=\"mt-2\" [formGroup]=\"roleMappingForm\">\n <div class=\"depatment-container\">\n <!-- <div class=\"section-header\">-->\n <!-- <div class=\"sub-heading\">-->\n <!-- <p>Choose Your Department</p>-->\n <!-- </div>-->\n <!-- </div>-->\n\n <div class=\"radio-group mt-4\">\n <mat-radio-group class=\"radio-btn-group\" formControlName=\"ministryType\"\n [(ngModel)]=\"selectedMinistryType\" (change)=\"onMinistryTypeChange($event)\">\n\n <!-- Left radio button -->\n <mat-radio-button value=\"ministry\" class=\"radio-btn left-radio\">\n <span class=\"radio-label\">\n <!-- <mat-icon class=\"radio-icon\" [ngClass]=\"selectedMinistryType === 'center'? 'checked-label':''\">domain</mat-icon> -->\n <span [ngClass]=\"selectedMinistryType === 'ministry'? 'checked-label':''\">Centre</span>\n </span>\n </mat-radio-button>\n\n <!-- Right radio button -->\n <mat-radio-button value=\"state\" class=\"radio-btn right-radio\">\n <span class=\"radio-label\">\n <!-- <mat-icon class=\"radio-icon\" [ngClass]=\"selectedMinistryType === 'state'? 'checked-label':''\">location_on</mat-icon> -->\n <span [ngClass]=\"selectedMinistryType === 'state'? 'checked-label':''\">State</span>\n </span>\n </mat-radio-button>\n\n </mat-radio-group>\n </div>\n <div class=\"mt-4\">\n\n <label class=\"label\">\n <span *ngIf=\"selectedMinistryType === 'ministry'\">Ministry</span>\n <span *ngIf=\"selectedMinistryType === 'state'\">State</span>\n </label>\n <div class=\"mt-2 search-box-with-select\">\n\n <mat-form-field appearance=\"fill\"\n style=\"background: white; border-radius: 25px; padding: 0 12px; border: 1px solid #ccc;width: 100%;\">\n <mat-select panelClass=\"select-with-search\"\n [placeholder]=\"selectedMinistryType === 'ministry' ? 'Select Ministry/ Department':'Select State'\"\n (selectionChange)=\"onMinistryChange($event)\" formControlName=\"ministry\"\n style=\"border-radius: 25px; background: white; width:100%\"\n (openedChange)=\"onOpened($event)\">\n <div class=\"search-wrapper\" *ngIf=\"panelOpen\">\n <input type=\"text\" placeholder=\"Search...\" (input)=\"filterData($event)\"\n class=\"search-input\" (keydown.space)=\"$event.stopPropagation()\"\n (keydown)=\"$event.stopPropagation()\">\n </div>\n <!-- [selected]=\"selectedMinistryId === item?.identifier\" -->\n <mat-option [value]=\"item?.identifier\"\n *ngFor=\"let item of filteredList\">{{item?.orgName}}</mat-option>\n </mat-select>\n </mat-form-field>\n </div>\n </div>\n <div class=\"mt-4\" *ngIf=\"departmentData?.length\">\n <label class=\"label\">Department</label>\n <div class=\"mt-2\">\n <mat-form-field appearance=\"fill\"\n style=\"background: white; border-radius: 25px; padding: 0 12px;border: 1px solid #ccc;\">\n <mat-select #departmentSelect panelClass=\"select-with-search\" placeholder=\"Select Department\"\n formControlName=\"departments\" style=\"border-radius: 25px; background: white;\"\n (selectionChange)=\"onDepartmentChange()\" (openedChange)=\"onOpenedDepartment($event)\">\n <div class=\"search-wrapper\" *ngIf=\"departmentPanelOpen\">\n <input type=\"text\" placeholder=\"Search...\" (input)=\"filterDepartmentData($event)\"\n class=\"search-input\" (keydown.space)=\"$event.stopPropagation()\"\n (keydown)=\"$event.stopPropagation()\">\n </div>\n <mat-option [value]=\"item?.identifier\"\n *ngFor=\"let item of filteredDepartmentList\">{{item?.orgName}}</mat-option>\n <!-- selected department not present in the current search/page:\n kept rendered (hidden) so mat-select does not clear the selection -->\n <mat-option [value]=\"item?.identifier\" style=\"display: none\"\n *ngFor=\"let item of pinnedDepartmentOptions\">{{item?.orgName}}</mat-option>\n <mat-option disabled *ngIf=\"departmentLoading\">Loading...</mat-option>\n <mat-option disabled\n *ngIf=\"!departmentLoading && !filteredDepartmentList?.length\">No department found</mat-option>\n\n </mat-select>\n </mat-form-field>\n </div>\n\n </div>\n <!-- <div class=\"mt-4\">\n <label class=\"label\">Sector</label>\n <div>\n <mat-form-field appearance=\"fill\" style=\"background: white; border-radius: 25px; padding: 0 12px;\">\n <mat-select placeholder=\"Select Sector\" multiple formControlName=\"sectors\"\n style=\"border-radius: 25px; background: white;\">\n <mat-option [value]=\"item?.value\"\n *ngFor=\"let item of sectorData\">{{item?.value}}</mat-option>\n\n </mat-select>\n </mat-form-field>\n </div>\n\n </div> -->\n <!-- *ngIf=\"roleMappingForm.get('ministryType')?.value === 'state'\" -->\n <div class=\"mt-4 additional-details\">\n <textarea rows=\"5\" placeholder=\"Additional details\" formControlName=\"additionalDetails\"></textarea>\n </div>\n <div class=\"mt-4\">\n\n <button [ngClass]=\"disableUploadDocument ? 'btn-active-primary-disable':'btn-active-primary'\" class=\"\"\n [disabled]=\"disableUploadDocument\" mat-raised-button color=\"primary\" (click)=\"goToUploadDocument()\">\n <mat-icon>upload</mat-icon> Manage Documents\n </button>\n </div>\n <!-- *ngIf=\"roleMappingForm.get('ministryType')?.value === 'state'\" -->\n <!-- <div class=\"mt-4 section\" >\n <div class=\"sub-heading\">\n <p>Upload Document (PDF)</p>\n </div>\n <div class=\"file-upload-wrapper\">\n <label for=\"uploadDoc\" class=\"file-upload-label\">\n <span class=\"file-upload-icon\">\uD83D\uDCCE</span>\n <span *ngIf=\"!uploadedFile || uploadedFile.length === 0\">\n Choose up to 3 files (PDF/TXT)\n </span>\n <div *ngIf=\"uploadedFile?.length > 0\" class=\"file-list\">\n <div *ngFor=\"let file of uploadedFile; let i = index\" class=\"file-item\">\n {{ file.name }}\n <span class=\"remove-file-icon\" (click)=\"removeFile(i);$event.preventDefault()\">\n <mat-icon>close</mat-icon>\n </span>\n </div>\n </div>\n </label>\n <input\n id=\"uploadDoc\"\n type=\"file\"\n multiple\n (change)=\"onFileChange($event)\"\n hidden\n /> \n\n <small class=\"file-upload-hint\">Max file size: {{maxFileSizeMB}}MB</small>\n\n <input id=\"uploadDoc\" multiple type=\"file\" (change)=\"onFileChange($event)\"\n accept=\".pdf,.doc,.docx,.xls,.xlsx,.txt\" class=\"file-upload-input\" />\n\n <div *ngIf=\"uploadError\" class=\"error\">{{ uploadError }}</div>\n </div>\n </div> -->\n <!-- *ngIf=\"roleMappingForm.get('ministryType')?.value === 'state'\" -->\n <!-- <div class=\"mt-2 section\">\n <div class=\"disclaimer-text\">\n <p>Disclaimer: Please do not upload any confidential documents. </p>\n </div>\n </div> -->\n <div class=\"mt-2\" *ngIf=\"documents?.length < 1 && !(roleMappingForm?.invalid) || showWorkAllocationOrderDocumentMissing\">\n <p><span style=\"font-size: .875rem;font-weight: bold;\">Note: </span>\n <span class=\"error\">Please upload the Work Allocation Order document to generate the Capacity Building Plan (CBP)</span>\n </p>\n </div>\n <!-- <div class=\"mt-2\" *ngIf=\"documents?.length > 0\">\n <p *ngIf=\"workAllocationOrderDocumentMissing\"><span style=\"font-size: .875rem;font-weight: bold;\">Note:\n </span>\n <span class=\"error\">Please upload the Work Allocation Order document to generate the Capacity\n Building Plan (CBP)</span>\n </p>\n </div> -->\n <div class=\"mt-4\">\n <input\n [disabled]=\"roleMappingForm?.invalid || (roleMappingForm.get('ministryType')?.value === 'state' && !roleMappingForm.get('departments')?.value) || loading || documents?.length < 1 \"\n [ngClass]=\"roleMappingForm?.invalid || (roleMappingForm.get('ministryType')?.value === 'state' && !roleMappingForm.get('departments')?.value) || loading || documents?.length < 1 ? 'btn-disable':'btn-active'\"\n type=\"button\" [value]=\"loading ? 'Generating CBP...' : 'Generate CBP'\"\n (click)=\"onGenerateRoleMapping()\" />\n </div>\n </div>\n </mat-card>\n\n</div>\n<!-- <div *ngIf=\"!login\">\n <app-login (success)=\"loginStatus($event)\"></app-login>\n </div> -->\n\n<div class=\"overlay-loader\" *ngIf=\"apiLoading\">\n <mat-spinner diameter=\"50\"></mat-spinner>\n</div>\n\n<div class=\"overlay-loader\" *ngIf=\"loading\">\n <div class=\"loading-content\">\n <mat-spinner diameter=\"50\"></mat-spinner>\n <div class=\"loading-text mt-3\">\n <p class=\"main-message\">{{ currentProcessingStage || 'Preparing CBP Plan generation...' }}</p>\n <div class=\"progress-details\">\n <div class=\"progress-indicator\" *ngIf=\"chunks.length > 0\">\n <div class=\"progress-bar-container\">\n <div class=\"progress-bar\" [style.width.%]=\"getDisplayProgressPercentage()\">\n </div>\n </div>\n <small class=\"progress-text\">{{ getDisplayProgressPercentage() }}% Complete</small>\n </div>\n <small class=\"time-estimate\">\n Real-time streaming in progress. This may take 2-3 minutes.\n </small>\n </div>\n </div>\n </div>\n</div>", styles: [".container{width:40%}.sub-heading p{color:#000;font-family:Montserrat;font-size:18px;font-style:normal;font-weight:600;line-height:normal}.radio-btn-group{display:flex;justify-content:space-between;border-radius:8px;padding:12px 16px;align-items:center;max-width:600px;margin:0 auto;gap:20px}.radio-btn{flex:1;display:flex;align-items:center;justify-content:center;padding:10px;border-radius:6px;transition:background-color .3s ease}.radio-btn,.radio-btn:hover{background-color:#eef2f7}.radio-label{display:flex;align-items:center;gap:6px;font-weight:500;font-size:16px}.radio-icon{font-size:24px;color:gray}.radio-label{color:#000;font-family:Lato;font-size:18px;font-style:normal;font-weight:400;line-height:normal}.label{color:var(--Body-Text-Body-Color, #212529);font-family:Lato;font-size:18px;font-style:normal;font-weight:700;line-height:150%}::ng-deep mat-form-field{background-color:#fff!important;border-radius:25px!important;padding-left:12px;padding-right:12px;height:42px;width:100%}::ng-deep mat-select{border-radius:25px!important;background-color:#fff!important}::ng-deep .mat-select-panel{background-color:#fff!important}::ng-deep .mat-select-panel .mat-option{border-radius:0!important}::ng-deep mat-form-field .mat-form-field-underline{display:none!important}::ng-deep mat-select .mat-select-placeholder{color:#0006;font-family:Lato;font-size:14px;font-style:normal;font-weight:400;line-height:normal}::ng-deep mat-select .mat-select-value-text{color:#000;font-family:Lato;font-size:14px;font-style:normal;font-weight:400;line-height:normal;line-height:normal!important;padding-top:0!important;padding-bottom:0!important}::ng-deep mat-select .mat-select-value{display:flex!important;align-items:center!important;height:100%!important}.additional-details textarea{display:flex;padding:16px 16px 0;flex-direction:column;align-items:flex-start;gap:10px;flex:1 0 0;align-self:stretch;width:100%;color:#0006;font-family:Lato;font-size:14px;font-style:normal;font-weight:400;line-height:normal;border:none;outline:none;resize:none;box-shadow:none;border-radius:4px;border:1px solid #ccc}.section-header{display:flex;flex-direction:row;align-items:center;justify-content:center}.btn-disable{border-radius:var(--Radius-Full-Round, 9999999px);opacity:.4;background:var(--Primary-KB-Primary-Light, #1B4CA1);color:var(--white-kb-white-100, #FFF);text-align:center;font-family:Lato;font-size:14px;font-style:normal;font-weight:700;line-height:normal;display:flex;height:48px;padding:0 16px;justify-content:center;align-items:center;gap:8px;border:none;width:100%}.btn-active{border-radius:var(--Radius-Full-Round, 9999999px);opacity:1;background:var(--Primary-KB-Primary-Light, #1B4CA1);color:var(--white-kb-white-100, #FFF);text-align:center;font-family:Lato;font-size:14px;font-style:normal;font-weight:700;line-height:normal;display:flex;height:48px;padding:0 16px;justify-content:center;align-items:center;gap:8px;border:none;width:100%}.btn-group{display:flex;flex-direction:row;justify-content:space-between}.pl-2{padding-left:10px}.search-filter-section{display:flex;flex-direction:row;justify-content:space-between}.search .rsearch{position:relative}.search .search-icon{position:absolute;top:15px;font-size:20px;left:10px}.search .sinput{border-radius:4px;border:1px solid #d5d0d0;padding:15px 36px;font:400 14px Lato}.select-map-route-container{display:flex;flex-direction:row}.selected-mapping-route p{color:#1b4ca1;font-family:Lato;font-size:20px;font-style:normal;font-weight:400;line-height:normal;text-decoration-line:underline;text-decoration-style:solid;-webkit-text-decoration-skip:ink;text-decoration-skip-ink:auto;text-decoration-thickness:auto;text-underline-offset:auto;text-underline-position:from-font}.edit-plan{display:flex;padding:4px;justify-content:center;align-items:center;gap:8px;border-radius:4px;background:#1b4ca129;color:#1b4ca1;font-family:Lato;font-size:14px;font-style:normal;font-weight:400;line-height:normal;margin-left:10px}.search-container{display:flex;flex-direction:row}.course-container{display:flex;width:100%;padding:16px;flex-direction:column;align-items:flex-start;gap:24px;grid-row:2/span 1;grid-column:1/span 1;border-radius:12px;border:1px solid var(--borders-black-border-16-black, rgba(0, 0, 0, .16));background:#fff}.course-header{display:flex;flex-direction:row;justify-content:space-between;width:100%}.course-pill{display:flex;height:24px;padding:8px;align-items:center;gap:4px;border-radius:16px;border:1px solid var(--borders-border-fill-focussed-4-light-100, #EF951E);background:#fefaf4}.ai-recommened-pill{display:flex;padding:4px 8px;align-items:center;gap:8px;border-radius:var(--Radius-4, 4px);border:1px solid #1B4CA1;background:#1b4ca129}.igot-platform-pill{display:flex;padding:4px 8px;align-items:center;gap:8px;border-radius:var(--Radius-4, 4px);border:1px solid #EF951E;background:#ef951e29}.course-title{color:var(--Primary-KB-Primary-Light, #1B4CA1);font-family:Montserrat;font-size:20px;font-style:normal;font-weight:600;line-height:30px}.course-desc{color:#0009;font-family:Lato;font-size:14px;font-style:normal;font-weight:400;line-height:normal}.relevancy,.competencies-matched{color:var(--accessbility-shades-with-opacity-kb-greys-black-60, rgba(0, 0, 0, .6));font-family:Lato;font-size:14px;font-style:normal;font-weight:400;line-height:normal;align-items:center}.percentage{color:#1d8923;font-family:Lato;font-size:14px;font-style:normal;font-weight:800;line-height:normal}.relevancy-container,.competencies-matched-container{display:flex;flex-direction:row;align-items:center}.dash{padding:0 5px}::ng-deep .mat-radio-checked .mat-radio-inner-circle{background:#1b4ca1!important}.course-list-container{display:flex;flex-wrap:wrap;gap:16px}.course-list-item{flex:0 0 48%;box-sizing:border-box;border:1px solid #ccc;padding:16px;background-color:#fff;border-radius:8px}.checked-course-container{display:flex}.ml-2{margin-left:8px}::ng-deep .mat-checkbox-checked .mat-checkbox-background{background:#1b4ca1!important}.ai-recommened-pill-text,.igot-platform-pill-text{color:#1b4ca1;font-family:Lato;font-size:12px;font-style:normal;font-weight:700;line-height:normal}.course-pill-text{color:var(--accessbility-shades-without-opacity-kb-greys-black-87, #212121);text-align:center;font-family:Poppins;font-size:12px;font-style:normal;font-weight:400;line-height:normal}.ai-loader-icon img,.igot-platform-icon img{width:15.714px;height:15.714px;flex-shrink:0}.competency-container{display:flex}.outside-layer{display:flex;padding:4px 12px;justify-content:center;align-items:center;gap:16px;border-radius:12px 4px 4px 12px;border-left:2px solid #F8B861;background:#fde8cc;width:132px}.suggest-courses-header{display:flex;flex-direction:row;justify-content:space-between}.suggest-course-control{display:flex;flex-direction:row}.course-card-container{width:172px;border-radius:3.307px;border:.827px solid var(--borders-border-8-black, rgba(0, 0, 0, .08));background-color:#fff}.highlight-ai{font-family:Montserrat;font-size:28px;font-style:normal;font-weight:600;line-height:normal;background:linear-gradient(90deg,#3b27ff,#2de3d6);background-clip:text;-webkit-background-clip:text;color:transparent;-webkit-text-fill-color:transparent;display:inline-block}.ai-loader-icon-medium img{width:60px;height:60px;flex-shrink:0}.overlay-loader{position:fixed;top:0;left:0;width:100vw;height:100vh;background:#ffffffbf;z-index:9999;display:flex;justify-content:center;align-items:center}.overlay-loader .loading-content{display:flex;flex-direction:column;align-items:center;text-align:center;background:#fff;padding:2rem;border-radius:8px;box-shadow:0 4px 12px #00000026}.overlay-loader .loading-content .loading-text{color:#1b4ca1;font-family:Lato,sans-serif;min-width:300px}.overlay-loader .loading-content .loading-text .main-message{margin:0 0 16px;font-size:18px;font-weight:600;text-align:center}.overlay-loader .loading-content .loading-text .progress-details{margin-top:16px}.overlay-loader .loading-content .loading-text .progress-details .progress-indicator{margin-bottom:12px}.overlay-loader .loading-content .loading-text .progress-details .progress-indicator .progress-bar-container{width:100%;height:8px;background-color:#e0e0e0;border-radius:4px;overflow:hidden;margin-bottom:8px}.overlay-loader .loading-content .loading-text .progress-details .progress-indicator .progress-bar-container .progress-bar{height:100%;background:linear-gradient(90deg,#1b4ca1,#2563eb);border-radius:4px;transition:width .5s ease-in-out}.overlay-loader .loading-content .loading-text .progress-details .progress-indicator .progress-text{font-size:14px;font-weight:500;color:#1b4ca1;display:block;text-align:center}.overlay-loader .loading-content .loading-text .progress-details .time-estimate{color:#666;font-size:12px;font-style:italic;display:block;text-align:center;margin-top:8px}::ng-deep mat-option .mat-option-text{font-size:16px;color:#000;font-family:Lato}:host ::ng-deep mat-select .mat-select-placeholder{font-size:16px}:host mat-select .mat-select-value-text{font-size:16px!important}.logo-container{display:flex;justify-content:center;align-items:center;flex-direction:column}.depatment-container{background:#fff;border:1px solid rgba(27,76,161,.12);padding:5%;box-shadow:0 4px 6px #0000001a,0 8px 20px #00000026;border-radius:8px}.checked-label{color:#1b4ca1}.file-upload-wrapper{position:relative;margin:16px 0}.file-upload-label{display:inline-flex;align-items:center;padding:10px 16px;background-color:#1b4ca1;color:#fff;font-weight:500;cursor:pointer;transition:background-color .3s;-webkit-user-select:none;user-select:none;border-radius:8px}.file-upload-label:hover{background-color:#1b4ca1}.file-upload-icon{margin-right:8px;font-size:18px}.file-upload-input{display:none}.error{color:red;margin-top:6px;font-size:.875rem}.file-upload-hint{display:block;font-size:1rem;color:#000;font-family:Lato;font-size:14px;margin-top:4px;margin-bottom:8px}.disclaimer-text p{font-size:16px;font-family:Lato;font-weight:400}.mat-select-panel .search-wrapper{width:100%!important;box-sizing:border-box;padding:8px;position:sticky;top:0;z-index:2;background:#fff}.search-input{width:100%;padding:6px 10px;border:1px solid #ccc;border-radius:6px;outline:none;box-sizing:border-box}.mat-select-panel mat-option{padding-top:10px}::ng-deep .mat-select-panel-wrap{overflow:visible!important;padding:0;margin-top:42px}::ng-deep .mat-select-panel{border:1px solid #ccc!important;box-sizing:border-box;max-height:250px}::ng-deep .select-with-search.mat-select-panel{padding-top:0;overflow:auto}::ng-deep .select-with-search .search-wrapper{position:sticky;top:0;z-index:10;background:#fff;padding:8px;border-bottom:1px solid #e0e0e0}::ng-deep .select-with-search .search-input{width:100%;padding:6px 10px;border:1px solid #ccc;border-radius:6px;outline:none;box-sizing:border-box}::ng-deep .select-with-search mat-option:first-of-type{margin-top:4px}.btn-active-disable{border-radius:var(--Radius-Full-Round, 9999999px);opacity:.5;background:var(--Primary-KB-Primary-Light, #1B4CA1);color:var(--white-kb-white-100, #FFF);text-align:center;font-family:Lato;font-size:14px;font-style:normal;font-weight:700;line-height:normal;display:flex;height:48px;padding:0 16px;justify-content:center;align-items:center;gap:8px;border:none;width:100%}.btn-active-primary{border-radius:var(--Radius-Full-Round, 9999999px);opacity:1;background:var(--Primary-KB-Primary-Light, #fff);color:#1b4ca1;text-align:center;border:1px solid #1B4CA1!important;font-family:Lato;font-size:14px;font-style:normal;font-weight:700;line-height:normal;display:flex;height:48px;padding:0 16px;justify-content:center;align-items:center;gap:8px;border:none;width:100%}.btn-active-primary-disable{border-radius:var(--Radius-Full-Round, 9999999px);opacity:.5;background:var(--Primary-KB-Primary-Light, #fff);color:#1b4ca1;text-align:center;border:1px solid #1B4CA1!important;font-family:Lato;font-size:14px;font-style:normal;font-weight:700;line-height:normal;display:flex;height:48px;padding:0 16px;justify-content:center;align-items:center;gap:8px;border:none;width:100%}\n"], dependencies: [{ kind: "directive", type: i5.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i5.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i5.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i6.MatLegacyCard, selector: "mat-card", exportAs: ["matCard"] }, { kind: "directive", type: i2.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "component", type: i7.MatLegacyFormField, selector: "mat-form-field", inputs: ["color", "appearance", "hideRequiredMarker", "hintLabel", "floatLabel"], exportAs: ["matFormField"] }, { kind: "component", type: i8$1.MatLegacyButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { kind: "component", type: i9.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "directive", type: i13$1.MatLegacyRadioGroup, selector: "mat-radio-group", exportAs: ["matRadioGroup"] }, { kind: "component", type: i13$1.MatLegacyRadioButton, selector: "mat-radio-button", inputs: ["disableRipple", "tabIndex"], exportAs: ["matRadioButton"] }, { kind: "component", type: i10.MatLegacySelect, selector: "mat-select", inputs: ["disabled", "disableRipple", "tabIndex"], exportAs: ["matSelect"] }, { kind: "component", type: i11.MatLegacyOption, selector: "mat-option", exportAs: ["matOption"] }, { kind: "directive", type: i2.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i2.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "component", type: i11$1.MatProgressSpinner, selector: "mat-progress-spinner, mat-spinner", inputs: ["color", "mode", "value", "diameter", "strokeWidth"], exportAs: ["matProgressSpinner"] }] }); }
|
|
12339
12334
|
}
|
|
12340
12335
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: RoleMappingGenerationComponent, decorators: [{
|
|
12341
12336
|
type: Component,
|
|
12342
|
-
args: [{ selector: 'app-role-mapping-generation', template: "<div class=\"container\">\n <!-- <input class=\"btn-active\" type=\"button\" value=\"Download as PDF\" (click)=\"downloadPDF()\" /> -->\n <div class=\"logo-container\" *ngIf=\"login\">\n <div>\n <span class=\"ai-loader-icon-medium\"><img src=\"assets/icons/ai-loader.gif\"></span>\n </div>\n <div>\n <h2 class=\"highlight-ai\">\n <span>iGOT AI Driven CBP</span>\n </h2>\n </div>\n <!-- <div class=\"sub-heading\">\n <p>Build Your Capacity With Customized Role Mapping</p>\n </div> -->\n </div>\n <mat-card *ngIf=\"login && roleMappingForm\" class=\"mt-2\" [formGroup]=\"roleMappingForm\">\n <div class=\"depatment-container\">\n <!-- <div class=\"section-header\">-->\n <!-- <div class=\"sub-heading\">-->\n <!-- <p>Choose Your Department</p>-->\n <!-- </div>-->\n <!-- </div>-->\n\n <div class=\"radio-group mt-4\">\n <mat-radio-group class=\"radio-btn-group\" formControlName=\"ministryType\"\n [(ngModel)]=\"selectedMinistryType\" (change)=\"onMinistryTypeChange($event)\">\n\n <!-- Left radio button -->\n <mat-radio-button value=\"ministry\" class=\"radio-btn left-radio\">\n <span class=\"radio-label\">\n <!-- <mat-icon class=\"radio-icon\" [ngClass]=\"selectedMinistryType === 'center'? 'checked-label':''\">domain</mat-icon> -->\n <span [ngClass]=\"selectedMinistryType === 'ministry'? 'checked-label':''\">Centre</span>\n </span>\n </mat-radio-button>\n\n <!-- Right radio button -->\n <mat-radio-button value=\"state\" class=\"radio-btn right-radio\">\n <span class=\"radio-label\">\n <!-- <mat-icon class=\"radio-icon\" [ngClass]=\"selectedMinistryType === 'state'? 'checked-label':''\">location_on</mat-icon> -->\n <span [ngClass]=\"selectedMinistryType === 'state'? 'checked-label':''\">State</span>\n </span>\n </mat-radio-button>\n\n </mat-radio-group>\n </div>\n <div class=\"mt-4\">\n\n <label class=\"label\">\n <span *ngIf=\"selectedMinistryType === 'ministry'\">Ministry</span>\n <span *ngIf=\"selectedMinistryType === 'state'\">State</span>\n </label>\n <div class=\"mt-2 search-box-with-select\">\n\n <mat-form-field appearance=\"fill\"\n style=\"background: white; border-radius: 25px; padding: 0 12px; border: 1px solid #ccc;width: 100%;\">\n <mat-select panelClass=\"select-with-search\"\n [placeholder]=\"selectedMinistryType === 'ministry' ? 'Select Ministry/ Department':'Select State'\"\n (selectionChange)=\"onMinistryChange($event)\" formControlName=\"ministry\"\n style=\"border-radius: 25px; background: white; width:100%\"\n (openedChange)=\"onOpened($event)\">\n <div class=\"search-wrapper\" *ngIf=\"panelOpen\">\n <input type=\"text\" placeholder=\"Search...\" (input)=\"filterData($event)\"\n class=\"search-input\" (keydown.space)=\"$event.stopPropagation()\"\n (keydown)=\"$event.stopPropagation()\">\n </div>\n <!-- [selected]=\"selectedMinistryId === item?.identifier\" -->\n <mat-option [value]=\"item?.identifier\"\n *ngFor=\"let item of filteredList\">{{item?.orgName}}</mat-option>\n </mat-select>\n </mat-form-field>\n </div>\n </div>\n <div class=\"mt-4\" *ngIf=\"departmentData?.length\">\n <label class=\"label\">Department</label>\n <div class=\"mt-2\">\n <mat-form-field appearance=\"fill\"\n style=\"background: white; border-radius: 25px; padding: 0 12px;border: 1px solid #ccc;\">\n <mat-select #departmentSelect panelClass=\"select-with-search\" placeholder=\"Select Department\"\n formControlName=\"departments\" style=\"border-radius: 25px; background: white;\"\n (selectionChange)=\"onDepartmentChange()\" (openedChange)=\"onOpenedDepartment($event)\">\n <div class=\"search-wrapper\" *ngIf=\"departmentPanelOpen\">\n <input type=\"text\" placeholder=\"Search...\" (input)=\"filterDepartmentData($event)\"\n class=\"search-input\" (keydown.space)=\"$event.stopPropagation()\"\n (keydown)=\"$event.stopPropagation()\">\n </div>\n <mat-option [value]=\"item?.identifier\"\n *ngFor=\"let item of filteredDepartmentList\">{{item?.orgName}}</mat-option>\n <mat-option disabled *ngIf=\"departmentLoading\">Loading...</mat-option>\n <mat-option disabled\n *ngIf=\"!departmentLoading && !filteredDepartmentList?.length\">No department found</mat-option>\n\n </mat-select>\n </mat-form-field>\n </div>\n\n </div>\n <!-- <div class=\"mt-4\">\n <label class=\"label\">Sector</label>\n <div>\n <mat-form-field appearance=\"fill\" style=\"background: white; border-radius: 25px; padding: 0 12px;\">\n <mat-select placeholder=\"Select Sector\" multiple formControlName=\"sectors\"\n style=\"border-radius: 25px; background: white;\">\n <mat-option [value]=\"item?.value\"\n *ngFor=\"let item of sectorData\">{{item?.value}}</mat-option>\n\n </mat-select>\n </mat-form-field>\n </div>\n\n </div> -->\n <!-- *ngIf=\"roleMappingForm.get('ministryType')?.value === 'state'\" -->\n <div class=\"mt-4 additional-details\">\n <textarea rows=\"5\" placeholder=\"Additional details\" formControlName=\"additionalDetails\"></textarea>\n </div>\n <div class=\"mt-4\">\n\n <button [ngClass]=\"disableUploadDocument ? 'btn-active-primary-disable':'btn-active-primary'\" class=\"\"\n [disabled]=\"disableUploadDocument\" mat-raised-button color=\"primary\" (click)=\"goToUploadDocument()\">\n <mat-icon>upload</mat-icon> Manage Documents\n </button>\n </div>\n <!-- *ngIf=\"roleMappingForm.get('ministryType')?.value === 'state'\" -->\n <!-- <div class=\"mt-4 section\" >\n <div class=\"sub-heading\">\n <p>Upload Document (PDF)</p>\n </div>\n <div class=\"file-upload-wrapper\">\n <label for=\"uploadDoc\" class=\"file-upload-label\">\n <span class=\"file-upload-icon\">\uD83D\uDCCE</span>\n <span *ngIf=\"!uploadedFile || uploadedFile.length === 0\">\n Choose up to 3 files (PDF/TXT)\n </span>\n <div *ngIf=\"uploadedFile?.length > 0\" class=\"file-list\">\n <div *ngFor=\"let file of uploadedFile; let i = index\" class=\"file-item\">\n {{ file.name }}\n <span class=\"remove-file-icon\" (click)=\"removeFile(i);$event.preventDefault()\">\n <mat-icon>close</mat-icon>\n </span>\n </div>\n </div>\n </label>\n <input\n id=\"uploadDoc\"\n type=\"file\"\n multiple\n (change)=\"onFileChange($event)\"\n hidden\n /> \n\n <small class=\"file-upload-hint\">Max file size: {{maxFileSizeMB}}MB</small>\n\n <input id=\"uploadDoc\" multiple type=\"file\" (change)=\"onFileChange($event)\"\n accept=\".pdf,.doc,.docx,.xls,.xlsx,.txt\" class=\"file-upload-input\" />\n\n <div *ngIf=\"uploadError\" class=\"error\">{{ uploadError }}</div>\n </div>\n </div> -->\n <!-- *ngIf=\"roleMappingForm.get('ministryType')?.value === 'state'\" -->\n <!-- <div class=\"mt-2 section\">\n <div class=\"disclaimer-text\">\n <p>Disclaimer: Please do not upload any confidential documents. </p>\n </div>\n </div> -->\n <div class=\"mt-2\" *ngIf=\"documents?.length < 1 && !(roleMappingForm?.invalid) || showWorkAllocationOrderDocumentMissing\">\n <p><span style=\"font-size: .875rem;font-weight: bold;\">Note: </span>\n <span class=\"error\">Please upload the Work Allocation Order document to generate the Capacity Building Plan (CBP)</span>\n </p>\n </div>\n <!-- <div class=\"mt-2\" *ngIf=\"documents?.length > 0\">\n <p *ngIf=\"workAllocationOrderDocumentMissing\"><span style=\"font-size: .875rem;font-weight: bold;\">Note:\n </span>\n <span class=\"error\">Please upload the Work Allocation Order document to generate the Capacity\n Building Plan (CBP)</span>\n </p>\n </div> -->\n <div class=\"mt-4\">\n <input\n [disabled]=\"roleMappingForm?.invalid || (roleMappingForm.get('ministryType')?.value === 'state' && !roleMappingForm.get('departments')?.value) || loading || documents?.length < 1 \"\n [ngClass]=\"roleMappingForm?.invalid || (roleMappingForm.get('ministryType')?.value === 'state' && !roleMappingForm.get('departments')?.value) || loading || documents?.length < 1 ? 'btn-disable':'btn-active'\"\n type=\"button\" [value]=\"loading ? 'Generating CBP...' : 'Generate CBP'\"\n (click)=\"onGenerateRoleMapping()\" />\n </div>\n </div>\n </mat-card>\n\n</div>\n<!-- <div *ngIf=\"!login\">\n <app-login (success)=\"loginStatus($event)\"></app-login>\n </div> -->\n\n<div class=\"overlay-loader\" *ngIf=\"apiLoading\">\n <mat-spinner diameter=\"50\"></mat-spinner>\n</div>\n\n<div class=\"overlay-loader\" *ngIf=\"loading\">\n <div class=\"loading-content\">\n <mat-spinner diameter=\"50\"></mat-spinner>\n <div class=\"loading-text mt-3\">\n <p class=\"main-message\">{{ currentProcessingStage || 'Preparing CBP Plan generation...' }}</p>\n <div class=\"progress-details\">\n <div class=\"progress-indicator\" *ngIf=\"chunks.length > 0\">\n <div class=\"progress-bar-container\">\n <div class=\"progress-bar\" [style.width.%]=\"getDisplayProgressPercentage()\">\n </div>\n </div>\n <small class=\"progress-text\">{{ getDisplayProgressPercentage() }}% Complete</small>\n </div>\n <small class=\"time-estimate\">\n Real-time streaming in progress. This may take 2-3 minutes.\n </small>\n </div>\n </div>\n </div>\n</div>", styles: [".container{width:40%}.sub-heading p{color:#000;font-family:Montserrat;font-size:18px;font-style:normal;font-weight:600;line-height:normal}.radio-btn-group{display:flex;justify-content:space-between;border-radius:8px;padding:12px 16px;align-items:center;max-width:600px;margin:0 auto;gap:20px}.radio-btn{flex:1;display:flex;align-items:center;justify-content:center;padding:10px;border-radius:6px;transition:background-color .3s ease}.radio-btn,.radio-btn:hover{background-color:#eef2f7}.radio-label{display:flex;align-items:center;gap:6px;font-weight:500;font-size:16px}.radio-icon{font-size:24px;color:gray}.radio-label{color:#000;font-family:Lato;font-size:18px;font-style:normal;font-weight:400;line-height:normal}.label{color:var(--Body-Text-Body-Color, #212529);font-family:Lato;font-size:18px;font-style:normal;font-weight:700;line-height:150%}::ng-deep mat-form-field{background-color:#fff!important;border-radius:25px!important;padding-left:12px;padding-right:12px;height:42px;width:100%}::ng-deep mat-select{border-radius:25px!important;background-color:#fff!important}::ng-deep .mat-select-panel{background-color:#fff!important}::ng-deep .mat-select-panel .mat-option{border-radius:0!important}::ng-deep mat-form-field .mat-form-field-underline{display:none!important}::ng-deep mat-select .mat-select-placeholder{color:#0006;font-family:Lato;font-size:14px;font-style:normal;font-weight:400;line-height:normal}::ng-deep mat-select .mat-select-value-text{color:#000;font-family:Lato;font-size:14px;font-style:normal;font-weight:400;line-height:normal;line-height:normal!important;padding-top:0!important;padding-bottom:0!important}::ng-deep mat-select .mat-select-value{display:flex!important;align-items:center!important;height:100%!important}.additional-details textarea{display:flex;padding:16px 16px 0;flex-direction:column;align-items:flex-start;gap:10px;flex:1 0 0;align-self:stretch;width:100%;color:#0006;font-family:Lato;font-size:14px;font-style:normal;font-weight:400;line-height:normal;border:none;outline:none;resize:none;box-shadow:none;border-radius:4px;border:1px solid #ccc}.section-header{display:flex;flex-direction:row;align-items:center;justify-content:center}.btn-disable{border-radius:var(--Radius-Full-Round, 9999999px);opacity:.4;background:var(--Primary-KB-Primary-Light, #1B4CA1);color:var(--white-kb-white-100, #FFF);text-align:center;font-family:Lato;font-size:14px;font-style:normal;font-weight:700;line-height:normal;display:flex;height:48px;padding:0 16px;justify-content:center;align-items:center;gap:8px;border:none;width:100%}.btn-active{border-radius:var(--Radius-Full-Round, 9999999px);opacity:1;background:var(--Primary-KB-Primary-Light, #1B4CA1);color:var(--white-kb-white-100, #FFF);text-align:center;font-family:Lato;font-size:14px;font-style:normal;font-weight:700;line-height:normal;display:flex;height:48px;padding:0 16px;justify-content:center;align-items:center;gap:8px;border:none;width:100%}.btn-group{display:flex;flex-direction:row;justify-content:space-between}.pl-2{padding-left:10px}.search-filter-section{display:flex;flex-direction:row;justify-content:space-between}.search .rsearch{position:relative}.search .search-icon{position:absolute;top:15px;font-size:20px;left:10px}.search .sinput{border-radius:4px;border:1px solid #d5d0d0;padding:15px 36px;font:400 14px Lato}.select-map-route-container{display:flex;flex-direction:row}.selected-mapping-route p{color:#1b4ca1;font-family:Lato;font-size:20px;font-style:normal;font-weight:400;line-height:normal;text-decoration-line:underline;text-decoration-style:solid;-webkit-text-decoration-skip:ink;text-decoration-skip-ink:auto;text-decoration-thickness:auto;text-underline-offset:auto;text-underline-position:from-font}.edit-plan{display:flex;padding:4px;justify-content:center;align-items:center;gap:8px;border-radius:4px;background:#1b4ca129;color:#1b4ca1;font-family:Lato;font-size:14px;font-style:normal;font-weight:400;line-height:normal;margin-left:10px}.search-container{display:flex;flex-direction:row}.course-container{display:flex;width:100%;padding:16px;flex-direction:column;align-items:flex-start;gap:24px;grid-row:2/span 1;grid-column:1/span 1;border-radius:12px;border:1px solid var(--borders-black-border-16-black, rgba(0, 0, 0, .16));background:#fff}.course-header{display:flex;flex-direction:row;justify-content:space-between;width:100%}.course-pill{display:flex;height:24px;padding:8px;align-items:center;gap:4px;border-radius:16px;border:1px solid var(--borders-border-fill-focussed-4-light-100, #EF951E);background:#fefaf4}.ai-recommened-pill{display:flex;padding:4px 8px;align-items:center;gap:8px;border-radius:var(--Radius-4, 4px);border:1px solid #1B4CA1;background:#1b4ca129}.igot-platform-pill{display:flex;padding:4px 8px;align-items:center;gap:8px;border-radius:var(--Radius-4, 4px);border:1px solid #EF951E;background:#ef951e29}.course-title{color:var(--Primary-KB-Primary-Light, #1B4CA1);font-family:Montserrat;font-size:20px;font-style:normal;font-weight:600;line-height:30px}.course-desc{color:#0009;font-family:Lato;font-size:14px;font-style:normal;font-weight:400;line-height:normal}.relevancy,.competencies-matched{color:var(--accessbility-shades-with-opacity-kb-greys-black-60, rgba(0, 0, 0, .6));font-family:Lato;font-size:14px;font-style:normal;font-weight:400;line-height:normal;align-items:center}.percentage{color:#1d8923;font-family:Lato;font-size:14px;font-style:normal;font-weight:800;line-height:normal}.relevancy-container,.competencies-matched-container{display:flex;flex-direction:row;align-items:center}.dash{padding:0 5px}::ng-deep .mat-radio-checked .mat-radio-inner-circle{background:#1b4ca1!important}.course-list-container{display:flex;flex-wrap:wrap;gap:16px}.course-list-item{flex:0 0 48%;box-sizing:border-box;border:1px solid #ccc;padding:16px;background-color:#fff;border-radius:8px}.checked-course-container{display:flex}.ml-2{margin-left:8px}::ng-deep .mat-checkbox-checked .mat-checkbox-background{background:#1b4ca1!important}.ai-recommened-pill-text,.igot-platform-pill-text{color:#1b4ca1;font-family:Lato;font-size:12px;font-style:normal;font-weight:700;line-height:normal}.course-pill-text{color:var(--accessbility-shades-without-opacity-kb-greys-black-87, #212121);text-align:center;font-family:Poppins;font-size:12px;font-style:normal;font-weight:400;line-height:normal}.ai-loader-icon img,.igot-platform-icon img{width:15.714px;height:15.714px;flex-shrink:0}.competency-container{display:flex}.outside-layer{display:flex;padding:4px 12px;justify-content:center;align-items:center;gap:16px;border-radius:12px 4px 4px 12px;border-left:2px solid #F8B861;background:#fde8cc;width:132px}.suggest-courses-header{display:flex;flex-direction:row;justify-content:space-between}.suggest-course-control{display:flex;flex-direction:row}.course-card-container{width:172px;border-radius:3.307px;border:.827px solid var(--borders-border-8-black, rgba(0, 0, 0, .08));background-color:#fff}.highlight-ai{font-family:Montserrat;font-size:28px;font-style:normal;font-weight:600;line-height:normal;background:linear-gradient(90deg,#3b27ff,#2de3d6);background-clip:text;-webkit-background-clip:text;color:transparent;-webkit-text-fill-color:transparent;display:inline-block}.ai-loader-icon-medium img{width:60px;height:60px;flex-shrink:0}.overlay-loader{position:fixed;top:0;left:0;width:100vw;height:100vh;background:#ffffffbf;z-index:9999;display:flex;justify-content:center;align-items:center}.overlay-loader .loading-content{display:flex;flex-direction:column;align-items:center;text-align:center;background:#fff;padding:2rem;border-radius:8px;box-shadow:0 4px 12px #00000026}.overlay-loader .loading-content .loading-text{color:#1b4ca1;font-family:Lato,sans-serif;min-width:300px}.overlay-loader .loading-content .loading-text .main-message{margin:0 0 16px;font-size:18px;font-weight:600;text-align:center}.overlay-loader .loading-content .loading-text .progress-details{margin-top:16px}.overlay-loader .loading-content .loading-text .progress-details .progress-indicator{margin-bottom:12px}.overlay-loader .loading-content .loading-text .progress-details .progress-indicator .progress-bar-container{width:100%;height:8px;background-color:#e0e0e0;border-radius:4px;overflow:hidden;margin-bottom:8px}.overlay-loader .loading-content .loading-text .progress-details .progress-indicator .progress-bar-container .progress-bar{height:100%;background:linear-gradient(90deg,#1b4ca1,#2563eb);border-radius:4px;transition:width .5s ease-in-out}.overlay-loader .loading-content .loading-text .progress-details .progress-indicator .progress-text{font-size:14px;font-weight:500;color:#1b4ca1;display:block;text-align:center}.overlay-loader .loading-content .loading-text .progress-details .time-estimate{color:#666;font-size:12px;font-style:italic;display:block;text-align:center;margin-top:8px}::ng-deep mat-option .mat-option-text{font-size:16px;color:#000;font-family:Lato}:host ::ng-deep mat-select .mat-select-placeholder{font-size:16px}:host mat-select .mat-select-value-text{font-size:16px!important}.logo-container{display:flex;justify-content:center;align-items:center;flex-direction:column}.depatment-container{background:#fff;border:1px solid rgba(27,76,161,.12);padding:5%;box-shadow:0 4px 6px #0000001a,0 8px 20px #00000026;border-radius:8px}.checked-label{color:#1b4ca1}.file-upload-wrapper{position:relative;margin:16px 0}.file-upload-label{display:inline-flex;align-items:center;padding:10px 16px;background-color:#1b4ca1;color:#fff;font-weight:500;cursor:pointer;transition:background-color .3s;-webkit-user-select:none;user-select:none;border-radius:8px}.file-upload-label:hover{background-color:#1b4ca1}.file-upload-icon{margin-right:8px;font-size:18px}.file-upload-input{display:none}.error{color:red;margin-top:6px;font-size:.875rem}.file-upload-hint{display:block;font-size:1rem;color:#000;font-family:Lato;font-size:14px;margin-top:4px;margin-bottom:8px}.disclaimer-text p{font-size:16px;font-family:Lato;font-weight:400}.mat-select-panel .search-wrapper{width:100%!important;box-sizing:border-box;padding:8px;position:sticky;top:0;z-index:2;background:#fff}.search-input{width:100%;padding:6px 10px;border:1px solid #ccc;border-radius:6px;outline:none;box-sizing:border-box}.mat-select-panel mat-option{padding-top:10px}::ng-deep .mat-select-panel-wrap{overflow:visible!important;padding:0;margin-top:42px}::ng-deep .mat-select-panel{border:1px solid #ccc!important;box-sizing:border-box;max-height:250px}::ng-deep .select-with-search.mat-select-panel{padding-top:0;overflow:auto}::ng-deep .select-with-search .search-wrapper{position:sticky;top:0;z-index:10;background:#fff;padding:8px;border-bottom:1px solid #e0e0e0}::ng-deep .select-with-search .search-input{width:100%;padding:6px 10px;border:1px solid #ccc;border-radius:6px;outline:none;box-sizing:border-box}::ng-deep .select-with-search mat-option:first-of-type{margin-top:4px}.btn-active-disable{border-radius:var(--Radius-Full-Round, 9999999px);opacity:.5;background:var(--Primary-KB-Primary-Light, #1B4CA1);color:var(--white-kb-white-100, #FFF);text-align:center;font-family:Lato;font-size:14px;font-style:normal;font-weight:700;line-height:normal;display:flex;height:48px;padding:0 16px;justify-content:center;align-items:center;gap:8px;border:none;width:100%}.btn-active-primary{border-radius:var(--Radius-Full-Round, 9999999px);opacity:1;background:var(--Primary-KB-Primary-Light, #fff);color:#1b4ca1;text-align:center;border:1px solid #1B4CA1!important;font-family:Lato;font-size:14px;font-style:normal;font-weight:700;line-height:normal;display:flex;height:48px;padding:0 16px;justify-content:center;align-items:center;gap:8px;border:none;width:100%}.btn-active-primary-disable{border-radius:var(--Radius-Full-Round, 9999999px);opacity:.5;background:var(--Primary-KB-Primary-Light, #fff);color:#1b4ca1;text-align:center;border:1px solid #1B4CA1!important;font-family:Lato;font-size:14px;font-style:normal;font-weight:700;line-height:normal;display:flex;height:48px;padding:0 16px;justify-content:center;align-items:center;gap:8px;border:none;width:100%}\n"] }]
|
|
12337
|
+
args: [{ selector: 'app-role-mapping-generation', template: "<div class=\"container\">\n <!-- <input class=\"btn-active\" type=\"button\" value=\"Download as PDF\" (click)=\"downloadPDF()\" /> -->\n <div class=\"logo-container\" *ngIf=\"login\">\n <div>\n <span class=\"ai-loader-icon-medium\"><img src=\"assets/icons/ai-loader.gif\"></span>\n </div>\n <div>\n <h2 class=\"highlight-ai\">\n <span>iGOT AI Driven CBP</span>\n </h2>\n </div>\n <!-- <div class=\"sub-heading\">\n <p>Build Your Capacity With Customized Role Mapping</p>\n </div> -->\n </div>\n <mat-card *ngIf=\"login && roleMappingForm\" class=\"mt-2\" [formGroup]=\"roleMappingForm\">\n <div class=\"depatment-container\">\n <!-- <div class=\"section-header\">-->\n <!-- <div class=\"sub-heading\">-->\n <!-- <p>Choose Your Department</p>-->\n <!-- </div>-->\n <!-- </div>-->\n\n <div class=\"radio-group mt-4\">\n <mat-radio-group class=\"radio-btn-group\" formControlName=\"ministryType\"\n [(ngModel)]=\"selectedMinistryType\" (change)=\"onMinistryTypeChange($event)\">\n\n <!-- Left radio button -->\n <mat-radio-button value=\"ministry\" class=\"radio-btn left-radio\">\n <span class=\"radio-label\">\n <!-- <mat-icon class=\"radio-icon\" [ngClass]=\"selectedMinistryType === 'center'? 'checked-label':''\">domain</mat-icon> -->\n <span [ngClass]=\"selectedMinistryType === 'ministry'? 'checked-label':''\">Centre</span>\n </span>\n </mat-radio-button>\n\n <!-- Right radio button -->\n <mat-radio-button value=\"state\" class=\"radio-btn right-radio\">\n <span class=\"radio-label\">\n <!-- <mat-icon class=\"radio-icon\" [ngClass]=\"selectedMinistryType === 'state'? 'checked-label':''\">location_on</mat-icon> -->\n <span [ngClass]=\"selectedMinistryType === 'state'? 'checked-label':''\">State</span>\n </span>\n </mat-radio-button>\n\n </mat-radio-group>\n </div>\n <div class=\"mt-4\">\n\n <label class=\"label\">\n <span *ngIf=\"selectedMinistryType === 'ministry'\">Ministry</span>\n <span *ngIf=\"selectedMinistryType === 'state'\">State</span>\n </label>\n <div class=\"mt-2 search-box-with-select\">\n\n <mat-form-field appearance=\"fill\"\n style=\"background: white; border-radius: 25px; padding: 0 12px; border: 1px solid #ccc;width: 100%;\">\n <mat-select panelClass=\"select-with-search\"\n [placeholder]=\"selectedMinistryType === 'ministry' ? 'Select Ministry/ Department':'Select State'\"\n (selectionChange)=\"onMinistryChange($event)\" formControlName=\"ministry\"\n style=\"border-radius: 25px; background: white; width:100%\"\n (openedChange)=\"onOpened($event)\">\n <div class=\"search-wrapper\" *ngIf=\"panelOpen\">\n <input type=\"text\" placeholder=\"Search...\" (input)=\"filterData($event)\"\n class=\"search-input\" (keydown.space)=\"$event.stopPropagation()\"\n (keydown)=\"$event.stopPropagation()\">\n </div>\n <!-- [selected]=\"selectedMinistryId === item?.identifier\" -->\n <mat-option [value]=\"item?.identifier\"\n *ngFor=\"let item of filteredList\">{{item?.orgName}}</mat-option>\n </mat-select>\n </mat-form-field>\n </div>\n </div>\n <div class=\"mt-4\" *ngIf=\"departmentData?.length\">\n <label class=\"label\">Department</label>\n <div class=\"mt-2\">\n <mat-form-field appearance=\"fill\"\n style=\"background: white; border-radius: 25px; padding: 0 12px;border: 1px solid #ccc;\">\n <mat-select #departmentSelect panelClass=\"select-with-search\" placeholder=\"Select Department\"\n formControlName=\"departments\" style=\"border-radius: 25px; background: white;\"\n (selectionChange)=\"onDepartmentChange()\" (openedChange)=\"onOpenedDepartment($event)\">\n <div class=\"search-wrapper\" *ngIf=\"departmentPanelOpen\">\n <input type=\"text\" placeholder=\"Search...\" (input)=\"filterDepartmentData($event)\"\n class=\"search-input\" (keydown.space)=\"$event.stopPropagation()\"\n (keydown)=\"$event.stopPropagation()\">\n </div>\n <mat-option [value]=\"item?.identifier\"\n *ngFor=\"let item of filteredDepartmentList\">{{item?.orgName}}</mat-option>\n <!-- selected department not present in the current search/page:\n kept rendered (hidden) so mat-select does not clear the selection -->\n <mat-option [value]=\"item?.identifier\" style=\"display: none\"\n *ngFor=\"let item of pinnedDepartmentOptions\">{{item?.orgName}}</mat-option>\n <mat-option disabled *ngIf=\"departmentLoading\">Loading...</mat-option>\n <mat-option disabled\n *ngIf=\"!departmentLoading && !filteredDepartmentList?.length\">No department found</mat-option>\n\n </mat-select>\n </mat-form-field>\n </div>\n\n </div>\n <!-- <div class=\"mt-4\">\n <label class=\"label\">Sector</label>\n <div>\n <mat-form-field appearance=\"fill\" style=\"background: white; border-radius: 25px; padding: 0 12px;\">\n <mat-select placeholder=\"Select Sector\" multiple formControlName=\"sectors\"\n style=\"border-radius: 25px; background: white;\">\n <mat-option [value]=\"item?.value\"\n *ngFor=\"let item of sectorData\">{{item?.value}}</mat-option>\n\n </mat-select>\n </mat-form-field>\n </div>\n\n </div> -->\n <!-- *ngIf=\"roleMappingForm.get('ministryType')?.value === 'state'\" -->\n <div class=\"mt-4 additional-details\">\n <textarea rows=\"5\" placeholder=\"Additional details\" formControlName=\"additionalDetails\"></textarea>\n </div>\n <div class=\"mt-4\">\n\n <button [ngClass]=\"disableUploadDocument ? 'btn-active-primary-disable':'btn-active-primary'\" class=\"\"\n [disabled]=\"disableUploadDocument\" mat-raised-button color=\"primary\" (click)=\"goToUploadDocument()\">\n <mat-icon>upload</mat-icon> Manage Documents\n </button>\n </div>\n <!-- *ngIf=\"roleMappingForm.get('ministryType')?.value === 'state'\" -->\n <!-- <div class=\"mt-4 section\" >\n <div class=\"sub-heading\">\n <p>Upload Document (PDF)</p>\n </div>\n <div class=\"file-upload-wrapper\">\n <label for=\"uploadDoc\" class=\"file-upload-label\">\n <span class=\"file-upload-icon\">\uD83D\uDCCE</span>\n <span *ngIf=\"!uploadedFile || uploadedFile.length === 0\">\n Choose up to 3 files (PDF/TXT)\n </span>\n <div *ngIf=\"uploadedFile?.length > 0\" class=\"file-list\">\n <div *ngFor=\"let file of uploadedFile; let i = index\" class=\"file-item\">\n {{ file.name }}\n <span class=\"remove-file-icon\" (click)=\"removeFile(i);$event.preventDefault()\">\n <mat-icon>close</mat-icon>\n </span>\n </div>\n </div>\n </label>\n <input\n id=\"uploadDoc\"\n type=\"file\"\n multiple\n (change)=\"onFileChange($event)\"\n hidden\n /> \n\n <small class=\"file-upload-hint\">Max file size: {{maxFileSizeMB}}MB</small>\n\n <input id=\"uploadDoc\" multiple type=\"file\" (change)=\"onFileChange($event)\"\n accept=\".pdf,.doc,.docx,.xls,.xlsx,.txt\" class=\"file-upload-input\" />\n\n <div *ngIf=\"uploadError\" class=\"error\">{{ uploadError }}</div>\n </div>\n </div> -->\n <!-- *ngIf=\"roleMappingForm.get('ministryType')?.value === 'state'\" -->\n <!-- <div class=\"mt-2 section\">\n <div class=\"disclaimer-text\">\n <p>Disclaimer: Please do not upload any confidential documents. </p>\n </div>\n </div> -->\n <div class=\"mt-2\" *ngIf=\"documents?.length < 1 && !(roleMappingForm?.invalid) || showWorkAllocationOrderDocumentMissing\">\n <p><span style=\"font-size: .875rem;font-weight: bold;\">Note: </span>\n <span class=\"error\">Please upload the Work Allocation Order document to generate the Capacity Building Plan (CBP)</span>\n </p>\n </div>\n <!-- <div class=\"mt-2\" *ngIf=\"documents?.length > 0\">\n <p *ngIf=\"workAllocationOrderDocumentMissing\"><span style=\"font-size: .875rem;font-weight: bold;\">Note:\n </span>\n <span class=\"error\">Please upload the Work Allocation Order document to generate the Capacity\n Building Plan (CBP)</span>\n </p>\n </div> -->\n <div class=\"mt-4\">\n <input\n [disabled]=\"roleMappingForm?.invalid || (roleMappingForm.get('ministryType')?.value === 'state' && !roleMappingForm.get('departments')?.value) || loading || documents?.length < 1 \"\n [ngClass]=\"roleMappingForm?.invalid || (roleMappingForm.get('ministryType')?.value === 'state' && !roleMappingForm.get('departments')?.value) || loading || documents?.length < 1 ? 'btn-disable':'btn-active'\"\n type=\"button\" [value]=\"loading ? 'Generating CBP...' : 'Generate CBP'\"\n (click)=\"onGenerateRoleMapping()\" />\n </div>\n </div>\n </mat-card>\n\n</div>\n<!-- <div *ngIf=\"!login\">\n <app-login (success)=\"loginStatus($event)\"></app-login>\n </div> -->\n\n<div class=\"overlay-loader\" *ngIf=\"apiLoading\">\n <mat-spinner diameter=\"50\"></mat-spinner>\n</div>\n\n<div class=\"overlay-loader\" *ngIf=\"loading\">\n <div class=\"loading-content\">\n <mat-spinner diameter=\"50\"></mat-spinner>\n <div class=\"loading-text mt-3\">\n <p class=\"main-message\">{{ currentProcessingStage || 'Preparing CBP Plan generation...' }}</p>\n <div class=\"progress-details\">\n <div class=\"progress-indicator\" *ngIf=\"chunks.length > 0\">\n <div class=\"progress-bar-container\">\n <div class=\"progress-bar\" [style.width.%]=\"getDisplayProgressPercentage()\">\n </div>\n </div>\n <small class=\"progress-text\">{{ getDisplayProgressPercentage() }}% Complete</small>\n </div>\n <small class=\"time-estimate\">\n Real-time streaming in progress. This may take 2-3 minutes.\n </small>\n </div>\n </div>\n </div>\n</div>", styles: [".container{width:40%}.sub-heading p{color:#000;font-family:Montserrat;font-size:18px;font-style:normal;font-weight:600;line-height:normal}.radio-btn-group{display:flex;justify-content:space-between;border-radius:8px;padding:12px 16px;align-items:center;max-width:600px;margin:0 auto;gap:20px}.radio-btn{flex:1;display:flex;align-items:center;justify-content:center;padding:10px;border-radius:6px;transition:background-color .3s ease}.radio-btn,.radio-btn:hover{background-color:#eef2f7}.radio-label{display:flex;align-items:center;gap:6px;font-weight:500;font-size:16px}.radio-icon{font-size:24px;color:gray}.radio-label{color:#000;font-family:Lato;font-size:18px;font-style:normal;font-weight:400;line-height:normal}.label{color:var(--Body-Text-Body-Color, #212529);font-family:Lato;font-size:18px;font-style:normal;font-weight:700;line-height:150%}::ng-deep mat-form-field{background-color:#fff!important;border-radius:25px!important;padding-left:12px;padding-right:12px;height:42px;width:100%}::ng-deep mat-select{border-radius:25px!important;background-color:#fff!important}::ng-deep .mat-select-panel{background-color:#fff!important}::ng-deep .mat-select-panel .mat-option{border-radius:0!important}::ng-deep mat-form-field .mat-form-field-underline{display:none!important}::ng-deep mat-select .mat-select-placeholder{color:#0006;font-family:Lato;font-size:14px;font-style:normal;font-weight:400;line-height:normal}::ng-deep mat-select .mat-select-value-text{color:#000;font-family:Lato;font-size:14px;font-style:normal;font-weight:400;line-height:normal;line-height:normal!important;padding-top:0!important;padding-bottom:0!important}::ng-deep mat-select .mat-select-value{display:flex!important;align-items:center!important;height:100%!important}.additional-details textarea{display:flex;padding:16px 16px 0;flex-direction:column;align-items:flex-start;gap:10px;flex:1 0 0;align-self:stretch;width:100%;color:#0006;font-family:Lato;font-size:14px;font-style:normal;font-weight:400;line-height:normal;border:none;outline:none;resize:none;box-shadow:none;border-radius:4px;border:1px solid #ccc}.section-header{display:flex;flex-direction:row;align-items:center;justify-content:center}.btn-disable{border-radius:var(--Radius-Full-Round, 9999999px);opacity:.4;background:var(--Primary-KB-Primary-Light, #1B4CA1);color:var(--white-kb-white-100, #FFF);text-align:center;font-family:Lato;font-size:14px;font-style:normal;font-weight:700;line-height:normal;display:flex;height:48px;padding:0 16px;justify-content:center;align-items:center;gap:8px;border:none;width:100%}.btn-active{border-radius:var(--Radius-Full-Round, 9999999px);opacity:1;background:var(--Primary-KB-Primary-Light, #1B4CA1);color:var(--white-kb-white-100, #FFF);text-align:center;font-family:Lato;font-size:14px;font-style:normal;font-weight:700;line-height:normal;display:flex;height:48px;padding:0 16px;justify-content:center;align-items:center;gap:8px;border:none;width:100%}.btn-group{display:flex;flex-direction:row;justify-content:space-between}.pl-2{padding-left:10px}.search-filter-section{display:flex;flex-direction:row;justify-content:space-between}.search .rsearch{position:relative}.search .search-icon{position:absolute;top:15px;font-size:20px;left:10px}.search .sinput{border-radius:4px;border:1px solid #d5d0d0;padding:15px 36px;font:400 14px Lato}.select-map-route-container{display:flex;flex-direction:row}.selected-mapping-route p{color:#1b4ca1;font-family:Lato;font-size:20px;font-style:normal;font-weight:400;line-height:normal;text-decoration-line:underline;text-decoration-style:solid;-webkit-text-decoration-skip:ink;text-decoration-skip-ink:auto;text-decoration-thickness:auto;text-underline-offset:auto;text-underline-position:from-font}.edit-plan{display:flex;padding:4px;justify-content:center;align-items:center;gap:8px;border-radius:4px;background:#1b4ca129;color:#1b4ca1;font-family:Lato;font-size:14px;font-style:normal;font-weight:400;line-height:normal;margin-left:10px}.search-container{display:flex;flex-direction:row}.course-container{display:flex;width:100%;padding:16px;flex-direction:column;align-items:flex-start;gap:24px;grid-row:2/span 1;grid-column:1/span 1;border-radius:12px;border:1px solid var(--borders-black-border-16-black, rgba(0, 0, 0, .16));background:#fff}.course-header{display:flex;flex-direction:row;justify-content:space-between;width:100%}.course-pill{display:flex;height:24px;padding:8px;align-items:center;gap:4px;border-radius:16px;border:1px solid var(--borders-border-fill-focussed-4-light-100, #EF951E);background:#fefaf4}.ai-recommened-pill{display:flex;padding:4px 8px;align-items:center;gap:8px;border-radius:var(--Radius-4, 4px);border:1px solid #1B4CA1;background:#1b4ca129}.igot-platform-pill{display:flex;padding:4px 8px;align-items:center;gap:8px;border-radius:var(--Radius-4, 4px);border:1px solid #EF951E;background:#ef951e29}.course-title{color:var(--Primary-KB-Primary-Light, #1B4CA1);font-family:Montserrat;font-size:20px;font-style:normal;font-weight:600;line-height:30px}.course-desc{color:#0009;font-family:Lato;font-size:14px;font-style:normal;font-weight:400;line-height:normal}.relevancy,.competencies-matched{color:var(--accessbility-shades-with-opacity-kb-greys-black-60, rgba(0, 0, 0, .6));font-family:Lato;font-size:14px;font-style:normal;font-weight:400;line-height:normal;align-items:center}.percentage{color:#1d8923;font-family:Lato;font-size:14px;font-style:normal;font-weight:800;line-height:normal}.relevancy-container,.competencies-matched-container{display:flex;flex-direction:row;align-items:center}.dash{padding:0 5px}::ng-deep .mat-radio-checked .mat-radio-inner-circle{background:#1b4ca1!important}.course-list-container{display:flex;flex-wrap:wrap;gap:16px}.course-list-item{flex:0 0 48%;box-sizing:border-box;border:1px solid #ccc;padding:16px;background-color:#fff;border-radius:8px}.checked-course-container{display:flex}.ml-2{margin-left:8px}::ng-deep .mat-checkbox-checked .mat-checkbox-background{background:#1b4ca1!important}.ai-recommened-pill-text,.igot-platform-pill-text{color:#1b4ca1;font-family:Lato;font-size:12px;font-style:normal;font-weight:700;line-height:normal}.course-pill-text{color:var(--accessbility-shades-without-opacity-kb-greys-black-87, #212121);text-align:center;font-family:Poppins;font-size:12px;font-style:normal;font-weight:400;line-height:normal}.ai-loader-icon img,.igot-platform-icon img{width:15.714px;height:15.714px;flex-shrink:0}.competency-container{display:flex}.outside-layer{display:flex;padding:4px 12px;justify-content:center;align-items:center;gap:16px;border-radius:12px 4px 4px 12px;border-left:2px solid #F8B861;background:#fde8cc;width:132px}.suggest-courses-header{display:flex;flex-direction:row;justify-content:space-between}.suggest-course-control{display:flex;flex-direction:row}.course-card-container{width:172px;border-radius:3.307px;border:.827px solid var(--borders-border-8-black, rgba(0, 0, 0, .08));background-color:#fff}.highlight-ai{font-family:Montserrat;font-size:28px;font-style:normal;font-weight:600;line-height:normal;background:linear-gradient(90deg,#3b27ff,#2de3d6);background-clip:text;-webkit-background-clip:text;color:transparent;-webkit-text-fill-color:transparent;display:inline-block}.ai-loader-icon-medium img{width:60px;height:60px;flex-shrink:0}.overlay-loader{position:fixed;top:0;left:0;width:100vw;height:100vh;background:#ffffffbf;z-index:9999;display:flex;justify-content:center;align-items:center}.overlay-loader .loading-content{display:flex;flex-direction:column;align-items:center;text-align:center;background:#fff;padding:2rem;border-radius:8px;box-shadow:0 4px 12px #00000026}.overlay-loader .loading-content .loading-text{color:#1b4ca1;font-family:Lato,sans-serif;min-width:300px}.overlay-loader .loading-content .loading-text .main-message{margin:0 0 16px;font-size:18px;font-weight:600;text-align:center}.overlay-loader .loading-content .loading-text .progress-details{margin-top:16px}.overlay-loader .loading-content .loading-text .progress-details .progress-indicator{margin-bottom:12px}.overlay-loader .loading-content .loading-text .progress-details .progress-indicator .progress-bar-container{width:100%;height:8px;background-color:#e0e0e0;border-radius:4px;overflow:hidden;margin-bottom:8px}.overlay-loader .loading-content .loading-text .progress-details .progress-indicator .progress-bar-container .progress-bar{height:100%;background:linear-gradient(90deg,#1b4ca1,#2563eb);border-radius:4px;transition:width .5s ease-in-out}.overlay-loader .loading-content .loading-text .progress-details .progress-indicator .progress-text{font-size:14px;font-weight:500;color:#1b4ca1;display:block;text-align:center}.overlay-loader .loading-content .loading-text .progress-details .time-estimate{color:#666;font-size:12px;font-style:italic;display:block;text-align:center;margin-top:8px}::ng-deep mat-option .mat-option-text{font-size:16px;color:#000;font-family:Lato}:host ::ng-deep mat-select .mat-select-placeholder{font-size:16px}:host mat-select .mat-select-value-text{font-size:16px!important}.logo-container{display:flex;justify-content:center;align-items:center;flex-direction:column}.depatment-container{background:#fff;border:1px solid rgba(27,76,161,.12);padding:5%;box-shadow:0 4px 6px #0000001a,0 8px 20px #00000026;border-radius:8px}.checked-label{color:#1b4ca1}.file-upload-wrapper{position:relative;margin:16px 0}.file-upload-label{display:inline-flex;align-items:center;padding:10px 16px;background-color:#1b4ca1;color:#fff;font-weight:500;cursor:pointer;transition:background-color .3s;-webkit-user-select:none;user-select:none;border-radius:8px}.file-upload-label:hover{background-color:#1b4ca1}.file-upload-icon{margin-right:8px;font-size:18px}.file-upload-input{display:none}.error{color:red;margin-top:6px;font-size:.875rem}.file-upload-hint{display:block;font-size:1rem;color:#000;font-family:Lato;font-size:14px;margin-top:4px;margin-bottom:8px}.disclaimer-text p{font-size:16px;font-family:Lato;font-weight:400}.mat-select-panel .search-wrapper{width:100%!important;box-sizing:border-box;padding:8px;position:sticky;top:0;z-index:2;background:#fff}.search-input{width:100%;padding:6px 10px;border:1px solid #ccc;border-radius:6px;outline:none;box-sizing:border-box}.mat-select-panel mat-option{padding-top:10px}::ng-deep .mat-select-panel-wrap{overflow:visible!important;padding:0;margin-top:42px}::ng-deep .mat-select-panel{border:1px solid #ccc!important;box-sizing:border-box;max-height:250px}::ng-deep .select-with-search.mat-select-panel{padding-top:0;overflow:auto}::ng-deep .select-with-search .search-wrapper{position:sticky;top:0;z-index:10;background:#fff;padding:8px;border-bottom:1px solid #e0e0e0}::ng-deep .select-with-search .search-input{width:100%;padding:6px 10px;border:1px solid #ccc;border-radius:6px;outline:none;box-sizing:border-box}::ng-deep .select-with-search mat-option:first-of-type{margin-top:4px}.btn-active-disable{border-radius:var(--Radius-Full-Round, 9999999px);opacity:.5;background:var(--Primary-KB-Primary-Light, #1B4CA1);color:var(--white-kb-white-100, #FFF);text-align:center;font-family:Lato;font-size:14px;font-style:normal;font-weight:700;line-height:normal;display:flex;height:48px;padding:0 16px;justify-content:center;align-items:center;gap:8px;border:none;width:100%}.btn-active-primary{border-radius:var(--Radius-Full-Round, 9999999px);opacity:1;background:var(--Primary-KB-Primary-Light, #fff);color:#1b4ca1;text-align:center;border:1px solid #1B4CA1!important;font-family:Lato;font-size:14px;font-style:normal;font-weight:700;line-height:normal;display:flex;height:48px;padding:0 16px;justify-content:center;align-items:center;gap:8px;border:none;width:100%}.btn-active-primary-disable{border-radius:var(--Radius-Full-Round, 9999999px);opacity:.5;background:var(--Primary-KB-Primary-Light, #fff);color:#1b4ca1;text-align:center;border:1px solid #1B4CA1!important;font-family:Lato;font-size:14px;font-style:normal;font-weight:700;line-height:normal;display:flex;height:48px;padding:0 16px;justify-content:center;align-items:center;gap:8px;border:none;width:100%}\n"] }]
|
|
12343
12338
|
}], ctorParameters: function () { return [{ type: EventService }, { type: SharedService }, { type: i2.FormBuilder }, { type: i3$1.MatSnackBar }, { type: i1$1.MatDialog }, { type: RoleMappingService }, { type: i3.Router }]; }, propDecorators: { pdfContent: [{
|
|
12344
12339
|
type: ViewChild,
|
|
12345
12340
|
args: ['pdfContent', { static: false }]
|