cloud-ide-core 2.0.143 → 2.0.145
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/fesm2022/cloud-ide-core.mjs +67 -14
- package/fesm2022/cloud-ide-core.mjs.map +1 -1
- package/index.d.ts +7 -6
- package/package.json +1 -1
|
@@ -12343,6 +12343,8 @@ class CideCoreUserCreateComponent {
|
|
|
12343
12343
|
// User type information from route data (TEACHER, STUDENT, USER, etc.)
|
|
12344
12344
|
userType = signal(null, ...(ngDevMode ? [{ debugName: "userType" }] : []));
|
|
12345
12345
|
typeSpecificId = signal(null, ...(ngDevMode ? [{ debugName: "typeSpecificId" }] : []));
|
|
12346
|
+
// Track if userType came from query params/route data (to disable dropdown)
|
|
12347
|
+
userTypeFromQueryParams = signal(false, ...(ngDevMode ? [{ debugName: "userTypeFromQueryParams" }] : []));
|
|
12346
12348
|
userTypeOptions = [
|
|
12347
12349
|
{ value: 'STUDENT', label: 'Student' },
|
|
12348
12350
|
{ value: 'TEACHER', label: 'Faculty/Teacher' },
|
|
@@ -12882,6 +12884,15 @@ class CideCoreUserCreateComponent {
|
|
|
12882
12884
|
});
|
|
12883
12885
|
// Initialize role permissions grid configuration
|
|
12884
12886
|
this.initializeRolePermissionsGrid();
|
|
12887
|
+
// Watch for page code changes and re-initialize rights when userType changes
|
|
12888
|
+
effect(() => {
|
|
12889
|
+
const currentPageCode = this.pageCode();
|
|
12890
|
+
if (!currentPageCode)
|
|
12891
|
+
return;
|
|
12892
|
+
// Re-initialize rights when page code changes (due to userType change)
|
|
12893
|
+
this.rightsService.initializeRights(currentPageCode);
|
|
12894
|
+
console.log('🔐 Rights re-initialized for page code:', currentPageCode);
|
|
12895
|
+
});
|
|
12885
12896
|
}
|
|
12886
12897
|
// FormArray getter for entity mappings
|
|
12887
12898
|
get entityMappingsFormArray() {
|
|
@@ -13235,21 +13246,45 @@ class CideCoreUserCreateComponent {
|
|
|
13235
13246
|
addressCountriesLoading = signal({}, ...(ngDevMode ? [{ debugName: "addressCountriesLoading" }] : []));
|
|
13236
13247
|
postalCodeDataCache = signal({}, ...(ngDevMode ? [{ debugName: "postalCodeDataCache" }] : []));
|
|
13237
13248
|
ngOnInit() {
|
|
13238
|
-
// Initialize
|
|
13239
|
-
this.rightsService.initializeRights('core_user_management_create');
|
|
13249
|
+
// Initialize component first to get userType from route
|
|
13240
13250
|
this.initializeComponent();
|
|
13251
|
+
// Initial rights initialization will happen via effect when pageCode is determined
|
|
13241
13252
|
}
|
|
13242
13253
|
/**
|
|
13243
13254
|
* Initialize component
|
|
13244
13255
|
*/
|
|
13245
13256
|
initializeComponent() {
|
|
13257
|
+
// Check query params first for userType
|
|
13258
|
+
this.route.queryParams.pipe(takeUntilDestroyed(this.destroyRef)).subscribe(params => {
|
|
13259
|
+
const userTypeParam = params['userType'] || params['filterType'];
|
|
13260
|
+
if (userTypeParam) {
|
|
13261
|
+
const resolvedType = userTypeParam.toString().trim().toUpperCase();
|
|
13262
|
+
// Map common variations
|
|
13263
|
+
let finalType = resolvedType;
|
|
13264
|
+
if (resolvedType === 'FACULTY' || resolvedType === 'TEACHER') {
|
|
13265
|
+
finalType = 'TEACHER';
|
|
13266
|
+
}
|
|
13267
|
+
else if (resolvedType === 'STUDENT') {
|
|
13268
|
+
finalType = 'STUDENT';
|
|
13269
|
+
}
|
|
13270
|
+
this.userType.set(finalType);
|
|
13271
|
+
this.userMasterForm.patchValue({ syutm_user_type: finalType });
|
|
13272
|
+
this.userTypeFromQueryParams.set(true);
|
|
13273
|
+
// Disable the user type control when it comes from query params
|
|
13274
|
+
this.userMasterForm.get('syutm_user_type')?.disable();
|
|
13275
|
+
console.log('👤 User type from query params:', finalType);
|
|
13276
|
+
}
|
|
13277
|
+
});
|
|
13246
13278
|
// Read route data for user type (TEACHER, STUDENT, USER, etc.)
|
|
13247
13279
|
this.route.data.pipe(takeUntilDestroyed(this.destroyRef)).subscribe(data => {
|
|
13248
13280
|
if (data['userType']) {
|
|
13249
13281
|
const type = data['userType'].toString().toUpperCase();
|
|
13250
13282
|
this.userType.set(type);
|
|
13251
13283
|
this.userMasterForm.patchValue({ syutm_user_type: type });
|
|
13252
|
-
|
|
13284
|
+
this.userTypeFromQueryParams.set(true);
|
|
13285
|
+
// Disable the user type control when it comes from route data
|
|
13286
|
+
this.userMasterForm.get('syutm_user_type')?.disable();
|
|
13287
|
+
console.log('👤 User type from route data:', type);
|
|
13253
13288
|
}
|
|
13254
13289
|
if (data['typeSpecificId']) {
|
|
13255
13290
|
this.typeSpecificId.set(data['typeSpecificId']);
|
|
@@ -17279,11 +17314,30 @@ class CideCoreUserListComponent {
|
|
|
17279
17314
|
// Page config (title/subtitle) from page API via route data
|
|
17280
17315
|
pageTitle = signal('', ...(ngDevMode ? [{ debugName: "pageTitle" }] : []));
|
|
17281
17316
|
pageSubtitle = signal('', ...(ngDevMode ? [{ debugName: "pageSubtitle" }] : []));
|
|
17282
|
-
|
|
17283
|
-
|
|
17284
|
-
|
|
17317
|
+
// Page code computed based on user type
|
|
17318
|
+
pageCode = computed(() => {
|
|
17319
|
+
const type = this.userType()?.toUpperCase();
|
|
17320
|
+
if (type === 'TEACHER' || type === 'FACULTY') {
|
|
17321
|
+
return 'academics_teacher_list';
|
|
17322
|
+
}
|
|
17323
|
+
else if (type === 'STUDENT') {
|
|
17324
|
+
return 'academics_student_list';
|
|
17325
|
+
}
|
|
17326
|
+
return 'auth_user_mst'; // Default page code
|
|
17327
|
+
}, ...(ngDevMode ? [{ debugName: "pageCode" }] : []));
|
|
17328
|
+
// Shared wrapper setup - computed based on pageCode
|
|
17329
|
+
shared_wrapper_setup_param = computed(() => ({ sypg_page_code: this.pageCode() }), ...(ngDevMode ? [{ debugName: "shared_wrapper_setup_param" }] : []));
|
|
17285
17330
|
// Constructor to set up reactive effect for page data
|
|
17286
17331
|
constructor() {
|
|
17332
|
+
// Watch for page code changes and re-initialize rights when userType changes
|
|
17333
|
+
effect(() => {
|
|
17334
|
+
const currentPageCode = this.pageCode();
|
|
17335
|
+
if (!currentPageCode)
|
|
17336
|
+
return;
|
|
17337
|
+
// Re-initialize rights when page code changes (due to userType change)
|
|
17338
|
+
this.rightsService.initializeRights(currentPageCode);
|
|
17339
|
+
console.log('🔐 Rights re-initialized for page code:', currentPageCode);
|
|
17340
|
+
});
|
|
17287
17341
|
// Watch for page data changes in cache and update title/subtitle reactively
|
|
17288
17342
|
effect(() => {
|
|
17289
17343
|
const currentPageCode = this.pageCode();
|
|
@@ -17410,8 +17464,8 @@ class CideCoreUserListComponent {
|
|
|
17410
17464
|
templateRenderers = {};
|
|
17411
17465
|
ngOnInit() {
|
|
17412
17466
|
console.log('🔧 USER MASTER LIST: Component initializing');
|
|
17413
|
-
// Initialize rights
|
|
17414
|
-
|
|
17467
|
+
// Initialize rights - will be updated when userType is determined
|
|
17468
|
+
// We'll re-initialize after userType is set from route/query params
|
|
17415
17469
|
// Check query params for filtering by user type (from faculty/student list)
|
|
17416
17470
|
this.route.queryParams.pipe(takeUntilDestroyed(this.destroyRef)).subscribe(params => {
|
|
17417
17471
|
const userTypeParam = params['userType'] || params['filterType'];
|
|
@@ -17447,10 +17501,11 @@ class CideCoreUserListComponent {
|
|
|
17447
17501
|
}
|
|
17448
17502
|
console.log('👤 User type set from route data:', this.userType());
|
|
17449
17503
|
}
|
|
17504
|
+
// Note: pageCode is now computed based on userType, so we don't set it directly
|
|
17450
17505
|
const codeFromRoute = data['page']?.sypg_page_code || data['sypg_page_code'];
|
|
17451
17506
|
const codeFromQuery = this.route.snapshot.queryParamMap.get('sypg_page_code');
|
|
17452
17507
|
const finalCode = (codeFromRoute || codeFromQuery || this.pageCode()).toString();
|
|
17453
|
-
this.pageCode.
|
|
17508
|
+
console.log('📄 Page code determined:', finalCode, 'User type:', this.userType(), 'Computed pageCode:', this.pageCode());
|
|
17454
17509
|
// Page title/subtitle will be updated reactively by the effect when page data is loaded
|
|
17455
17510
|
// Also check immediately if data is already available
|
|
17456
17511
|
const cached = finalCode ? this.sharedService.getCachedPageData(finalCode) : null;
|
|
@@ -17897,13 +17952,11 @@ class CideCoreUserListComponent {
|
|
|
17897
17952
|
case 'toggle-status':
|
|
17898
17953
|
this.onToggleUserStatus(user);
|
|
17899
17954
|
break;
|
|
17900
|
-
case
|
|
17901
|
-
this.onDeleteUser(user);
|
|
17902
|
-
break;
|
|
17955
|
+
// Delete case removed - users cannot be deleted from the list
|
|
17903
17956
|
}
|
|
17904
17957
|
}
|
|
17905
17958
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: CideCoreUserListComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
17906
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.15", type: CideCoreUserListComponent, isStandalone: true, selector: "cide-core-user-list", viewQueries: [{ propertyName: "gridComponent", first: true, predicate: CideEleDataGridComponent, descendants: true }, { propertyName: "actionsTemplate", first: true, predicate: ["actionsTemplate"], descendants: true, static: true }, { propertyName: "userDetailsTemplate", first: true, predicate: ["userDetailsTemplate"], descendants: true, static: true }, { propertyName: "contactInfoTemplate", first: true, predicate: ["contactInfoTemplate"], descendants: true, static: true }, { propertyName: "organizationTemplate", first: true, predicate: ["organizationTemplate"], descendants: true, static: true }, { propertyName: "validityTemplate", first: true, predicate: ["validityTemplate"], descendants: true, static: true }, { propertyName: "statusTemplate", first: true, predicate: ["statusTemplate"], descendants: true, static: true }], ngImport: i0, template: "<!-- User List with Shared Wrapper -->\n<cide-lyt-shared-wrapper [shared_wrapper_setup_param]=\"
|
|
17959
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.15", type: CideCoreUserListComponent, isStandalone: true, selector: "cide-core-user-list", viewQueries: [{ propertyName: "gridComponent", first: true, predicate: CideEleDataGridComponent, descendants: true }, { propertyName: "actionsTemplate", first: true, predicate: ["actionsTemplate"], descendants: true, static: true }, { propertyName: "userDetailsTemplate", first: true, predicate: ["userDetailsTemplate"], descendants: true, static: true }, { propertyName: "contactInfoTemplate", first: true, predicate: ["contactInfoTemplate"], descendants: true, static: true }, { propertyName: "organizationTemplate", first: true, predicate: ["organizationTemplate"], descendants: true, static: true }, { propertyName: "validityTemplate", first: true, predicate: ["validityTemplate"], descendants: true, static: true }, { propertyName: "statusTemplate", first: true, predicate: ["statusTemplate"], descendants: true, static: true }], ngImport: i0, template: "<!-- User List with Shared Wrapper -->\n<cide-lyt-shared-wrapper [shared_wrapper_setup_param]=\"shared_wrapper_setup_param()\">\n <!-- Breadcrumb Actions -->\n <div breadcrumb-actions>\n @if (canCreate()) {\n <button cideEleButton variant=\"primary\" size=\"sm\" (click)=\"onAddUser()\" leftIcon=\"add\">\n Add User\n </button>\n }\n </div>\n\n<div class=\"user-master-listing-container tw-bg-white tw-shadow-lg tw-rounded-lg tw-table tw-h-full\">\n\n <!-- Error Message -->\n @if (error()) {\n <div class=\"tw-mt-4 tw-p-4 tw-bg-red-50 tw-border tw-border-red-200 tw-rounded-md\">\n <div class=\"tw-flex\">\n <cide-ele-icon name=\"exclamation-triangle\" class=\"tw-text-red-400\"></cide-ele-icon>\n <div class=\"tw-ml-3\">\n <h3 class=\"tw-text-sm tw-font-medium tw-text-red-800\">Error</h3>\n <p class=\"tw-text-sm tw-text-red-700 tw-mt-1\">{{ error() }}</p>\n </div>\n </div>\n </div>\n }\n <div class=\"tw-table-row\">\n <div class=\"tw-table-cell tw-h-full tw-relative\">\n <div class=\"tw-h-full tw-overflow-auto\">\n <!-- Data Grid Component -->\n <cide-ele-data-grid [config]=\"gridConfig()\" [templateRenderers]=\"templateRenderers\"\n [serverSidePagination]=\"true\" [totalServerItems]=\"totalItems()\" [currentServerPage]=\"currentPage()\"\n [currentServerPageSize]=\"pageSize()\" (gridEvent)=\"onGridEvent($event)\">\n </cide-ele-data-grid>\n </div>\n </div>\n </div>\n\n</div>\n\n<!-- Template Definitions for Grid Renderers -->\n\n<!-- User Details Template -->\n<ng-template #userDetailsTemplate let-value let-row=\"row\" let-column=\"column\">\n <div class=\"tw-flex tw-items-center tw-space-x-3\">\n <div\n class=\"tw-flex-shrink-0 tw-w-12 tw-h-12 tw-bg-blue-100 tw-rounded-full tw-flex tw-items-center tw-justify-center\">\n <span class=\"tw-text-blue-600 tw-font-semibold tw-text-sm\">\n {{ getUserInitials(row.user_firstname, row.user_lastname) }}\n </span>\n </div>\n <div class=\"tw-flex-1 tw-min-w-0\">\n <p class=\"tw-text-sm tw-font-semibold tw-text-gray-900 tw-truncate\" [title]=\"row.user_fullname\">\n {{ row.user_fullname || 'Unknown User' }}\n </p>\n <p class=\"tw-text-xs tw-text-blue-600 tw-truncate tw-font-medium\" [title]=\"'Username: ' + row.user_username\">\n @{{ row.user_username || 'No username' }}\n </p>\n <p class=\"tw-text-xs tw-text-gray-400 tw-truncate\" [title]=\"'ID: ' + row._id\">\n ID: {{ row._id?.substring(0, 8) }}...\n </p>\n </div>\n </div>\n</ng-template>\n\n<!-- Contact Info Template -->\n<ng-template #contactInfoTemplate let-value let-row=\"row\" let-column=\"column\">\n <div class=\"tw-space-y-1\">\n <p class=\"tw-text-xs tw-text-gray-900 tw-flex tw-items-center\" [title]=\"'Email: ' + row.user_emailid\">\n <svg class=\"tw-flex-shrink-0 tw-w-3 tw-h-3 tw-text-gray-400 tw-mr-2\" fill=\"currentColor\" viewBox=\"0 0 20 20\">\n <path d=\"M2.003 5.884L10 9.882l7.997-3.998A2 2 0 0016 4H4a2 2 0 00-1.997 1.884z\" />\n <path d=\"M18 8.118l-8 4-8-4V14a2 2 0 002 2h12a2 2 0 002-2V8.118z\" />\n </svg>\n <span class=\"tw-truncate\">{{ row.user_emailid || 'No email' }}</span>\n </p>\n <p class=\"tw-text-xs tw-text-gray-600 tw-flex tw-items-center\" [title]=\"'Mobile: ' + row.user_mobileno\">\n <svg class=\"tw-flex-shrink-0 tw-w-3 tw-h-3 tw-text-gray-400 tw-mr-2\" fill=\"currentColor\" viewBox=\"0 0 20 20\">\n <path\n d=\"M2 3a1 1 0 011-1h2.153a1 1 0 01.986.836l.74 4.435a1 1 0 01-.54 1.06l-1.548.773a11.037 11.037 0 006.105 6.105l.774-1.548a1 1 0 011.059-.54l4.435.74a1 1 0 01.836.986V17a1 1 0 01-1 1h-2C7.82 18 2 12.18 2 5V3z\" />\n </svg>\n <span class=\"tw-truncate\">{{ row.user_mobileno || 'No mobile' }}</span>\n </p>\n <p class=\"tw-text-xs tw-text-gray-500 tw-flex tw-items-center\"\n [title]=\"'Password Change: ' + getPasswordChangeText(row.user_passwordchangeonlogin)\">\n <svg class=\"tw-flex-shrink-0 tw-w-3 tw-h-3 tw-text-gray-400 tw-mr-2\" fill=\"currentColor\" viewBox=\"0 0 20 20\">\n <path fill-rule=\"evenodd\"\n d=\"M5 9V7a5 5 0 0110 0v2a2 2 0 012 2v5a2 2 0 01-2 2H5a2 2 0 01-2-2v-5a2 2 0 012-2zm8-2v2H7V7a3 3 0 016 0z\"\n clip-rule=\"evenodd\" />\n </svg>\n <span class=\"tw-truncate\">{{ getPasswordChangeText(row.user_passwordchangeonlogin) }}</span>\n </p>\n </div>\n</ng-template>\n\n\n\n<!-- Validity Template -->\n<ng-template #validityTemplate let-value let-row=\"row\" let-column=\"column\">\n <div class=\"tw-text-center tw-space-y-1\">\n <p class=\"tw-text-xs tw-text-gray-900 tw-font-medium\">\n Validity managed per entity\n </p>\n <p class=\"tw-text-xs tw-text-gray-600\">\n Check entity mappings for details\n </p>\n </div>\n</ng-template>\n\n<!-- Status Template -->\n<ng-template #statusTemplate let-value let-row=\"row\" let-column=\"column\">\n <div class=\"tw-flex tw-justify-center\">\n @if (row.user_isactive) {\n <span\n class=\"tw-inline-flex tw-items-center tw-px-2.5 tw-py-0.5 tw-rounded-full tw-text-xs tw-font-medium tw-bg-green-100 tw-text-green-800\">\n <svg class=\"tw-w-1.5 tw-h-1.5 tw-mr-1\" fill=\"currentColor\" viewBox=\"0 0 8 8\">\n <circle cx=\"4\" cy=\"4\" r=\"3\" />\n </svg>\n Active\n </span>\n } @else {\n <span\n class=\"tw-inline-flex tw-items-center tw-px-2.5 tw-py-0.5 tw-rounded-full tw-text-xs tw-font-medium tw-bg-red-100 tw-text-red-800\">\n <svg class=\"tw-w-1.5 tw-h-1.5 tw-mr-1\" fill=\"currentColor\" viewBox=\"0 0 8 8\">\n <circle cx=\"4\" cy=\"4\" r=\"3\" />\n </svg>\n Inactive\n </span>\n }\n </div>\n</ng-template>\n\n<!-- Actions Template using cide-ele-dropdown -->\n<ng-template #actionsTemplate let-value let-row=\"row\" let-column=\"column\">\n <cide-ele-dropdown [items]=\"getDropdownItems(row)\" [config]=\"{ triggerIcon: 'more_vert', triggerSize: 'sm', usePortal: true, minWidth: 200 }\" (itemClick)=\"onDropdownItemClick($event, row)\">\n </cide-ele-dropdown>\n</ng-template>\n</cide-lyt-shared-wrapper>", styles: [".user-master-listing-container{@apply tw-w-full tw-h-full;}:host{@apply tw-w-full tw-h-full tw-flex tw-flex-col;}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "ngmodule", type: FormsModule }, { kind: "component", type: CideIconComponent, selector: "cide-ele-icon", inputs: ["size", "type", "toolTip"] }, { kind: "component", type: CideEleButtonComponent, selector: "button[cideEleButton], a[cideEleButton], cide-ele-button", inputs: ["label", "variant", "size", "type", "shape", "elevation", "disabled", "id", "loading", "fullWidth", "leftIcon", "rightIcon", "customClass", "tooltip", "ariaLabel", "testId", "routerLink", "routerExtras", "preventDoubleClick", "animated"], outputs: ["btnClick", "doubleClick"] }, { kind: "component", type: CideEleDataGridComponent, selector: "cide-ele-data-grid", inputs: ["config", "templateRenderers", "customFormatters", "actionHandlers", "serverSidePagination", "totalServerItems", "currentServerPage", "currentServerPageSize", "dragDropEnabled"], outputs: ["gridEvent"] }, { kind: "component", type: CideEleDropdownComponent, selector: "cide-ele-dropdown", inputs: ["items", "config", "triggerTemplate", "menuTemplate"], outputs: ["itemClick", "dropdownToggle"] }, { kind: "component", type: CideLytSharedWrapperComponent, selector: "cide-lyt-shared-wrapper", inputs: ["shared_wrapper_setup_param", "breadcrumb_data"] }] });
|
|
17907
17960
|
}
|
|
17908
17961
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: CideCoreUserListComponent, decorators: [{
|
|
17909
17962
|
type: Component,
|
|
@@ -17915,7 +17968,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.15", ngImpo
|
|
|
17915
17968
|
CideEleDataGridComponent,
|
|
17916
17969
|
CideEleDropdownComponent,
|
|
17917
17970
|
CideLytSharedWrapperComponent
|
|
17918
|
-
], template: "<!-- User List with Shared Wrapper -->\n<cide-lyt-shared-wrapper [shared_wrapper_setup_param]=\"
|
|
17971
|
+
], template: "<!-- User List with Shared Wrapper -->\n<cide-lyt-shared-wrapper [shared_wrapper_setup_param]=\"shared_wrapper_setup_param()\">\n <!-- Breadcrumb Actions -->\n <div breadcrumb-actions>\n @if (canCreate()) {\n <button cideEleButton variant=\"primary\" size=\"sm\" (click)=\"onAddUser()\" leftIcon=\"add\">\n Add User\n </button>\n }\n </div>\n\n<div class=\"user-master-listing-container tw-bg-white tw-shadow-lg tw-rounded-lg tw-table tw-h-full\">\n\n <!-- Error Message -->\n @if (error()) {\n <div class=\"tw-mt-4 tw-p-4 tw-bg-red-50 tw-border tw-border-red-200 tw-rounded-md\">\n <div class=\"tw-flex\">\n <cide-ele-icon name=\"exclamation-triangle\" class=\"tw-text-red-400\"></cide-ele-icon>\n <div class=\"tw-ml-3\">\n <h3 class=\"tw-text-sm tw-font-medium tw-text-red-800\">Error</h3>\n <p class=\"tw-text-sm tw-text-red-700 tw-mt-1\">{{ error() }}</p>\n </div>\n </div>\n </div>\n }\n <div class=\"tw-table-row\">\n <div class=\"tw-table-cell tw-h-full tw-relative\">\n <div class=\"tw-h-full tw-overflow-auto\">\n <!-- Data Grid Component -->\n <cide-ele-data-grid [config]=\"gridConfig()\" [templateRenderers]=\"templateRenderers\"\n [serverSidePagination]=\"true\" [totalServerItems]=\"totalItems()\" [currentServerPage]=\"currentPage()\"\n [currentServerPageSize]=\"pageSize()\" (gridEvent)=\"onGridEvent($event)\">\n </cide-ele-data-grid>\n </div>\n </div>\n </div>\n\n</div>\n\n<!-- Template Definitions for Grid Renderers -->\n\n<!-- User Details Template -->\n<ng-template #userDetailsTemplate let-value let-row=\"row\" let-column=\"column\">\n <div class=\"tw-flex tw-items-center tw-space-x-3\">\n <div\n class=\"tw-flex-shrink-0 tw-w-12 tw-h-12 tw-bg-blue-100 tw-rounded-full tw-flex tw-items-center tw-justify-center\">\n <span class=\"tw-text-blue-600 tw-font-semibold tw-text-sm\">\n {{ getUserInitials(row.user_firstname, row.user_lastname) }}\n </span>\n </div>\n <div class=\"tw-flex-1 tw-min-w-0\">\n <p class=\"tw-text-sm tw-font-semibold tw-text-gray-900 tw-truncate\" [title]=\"row.user_fullname\">\n {{ row.user_fullname || 'Unknown User' }}\n </p>\n <p class=\"tw-text-xs tw-text-blue-600 tw-truncate tw-font-medium\" [title]=\"'Username: ' + row.user_username\">\n @{{ row.user_username || 'No username' }}\n </p>\n <p class=\"tw-text-xs tw-text-gray-400 tw-truncate\" [title]=\"'ID: ' + row._id\">\n ID: {{ row._id?.substring(0, 8) }}...\n </p>\n </div>\n </div>\n</ng-template>\n\n<!-- Contact Info Template -->\n<ng-template #contactInfoTemplate let-value let-row=\"row\" let-column=\"column\">\n <div class=\"tw-space-y-1\">\n <p class=\"tw-text-xs tw-text-gray-900 tw-flex tw-items-center\" [title]=\"'Email: ' + row.user_emailid\">\n <svg class=\"tw-flex-shrink-0 tw-w-3 tw-h-3 tw-text-gray-400 tw-mr-2\" fill=\"currentColor\" viewBox=\"0 0 20 20\">\n <path d=\"M2.003 5.884L10 9.882l7.997-3.998A2 2 0 0016 4H4a2 2 0 00-1.997 1.884z\" />\n <path d=\"M18 8.118l-8 4-8-4V14a2 2 0 002 2h12a2 2 0 002-2V8.118z\" />\n </svg>\n <span class=\"tw-truncate\">{{ row.user_emailid || 'No email' }}</span>\n </p>\n <p class=\"tw-text-xs tw-text-gray-600 tw-flex tw-items-center\" [title]=\"'Mobile: ' + row.user_mobileno\">\n <svg class=\"tw-flex-shrink-0 tw-w-3 tw-h-3 tw-text-gray-400 tw-mr-2\" fill=\"currentColor\" viewBox=\"0 0 20 20\">\n <path\n d=\"M2 3a1 1 0 011-1h2.153a1 1 0 01.986.836l.74 4.435a1 1 0 01-.54 1.06l-1.548.773a11.037 11.037 0 006.105 6.105l.774-1.548a1 1 0 011.059-.54l4.435.74a1 1 0 01.836.986V17a1 1 0 01-1 1h-2C7.82 18 2 12.18 2 5V3z\" />\n </svg>\n <span class=\"tw-truncate\">{{ row.user_mobileno || 'No mobile' }}</span>\n </p>\n <p class=\"tw-text-xs tw-text-gray-500 tw-flex tw-items-center\"\n [title]=\"'Password Change: ' + getPasswordChangeText(row.user_passwordchangeonlogin)\">\n <svg class=\"tw-flex-shrink-0 tw-w-3 tw-h-3 tw-text-gray-400 tw-mr-2\" fill=\"currentColor\" viewBox=\"0 0 20 20\">\n <path fill-rule=\"evenodd\"\n d=\"M5 9V7a5 5 0 0110 0v2a2 2 0 012 2v5a2 2 0 01-2 2H5a2 2 0 01-2-2v-5a2 2 0 012-2zm8-2v2H7V7a3 3 0 016 0z\"\n clip-rule=\"evenodd\" />\n </svg>\n <span class=\"tw-truncate\">{{ getPasswordChangeText(row.user_passwordchangeonlogin) }}</span>\n </p>\n </div>\n</ng-template>\n\n\n\n<!-- Validity Template -->\n<ng-template #validityTemplate let-value let-row=\"row\" let-column=\"column\">\n <div class=\"tw-text-center tw-space-y-1\">\n <p class=\"tw-text-xs tw-text-gray-900 tw-font-medium\">\n Validity managed per entity\n </p>\n <p class=\"tw-text-xs tw-text-gray-600\">\n Check entity mappings for details\n </p>\n </div>\n</ng-template>\n\n<!-- Status Template -->\n<ng-template #statusTemplate let-value let-row=\"row\" let-column=\"column\">\n <div class=\"tw-flex tw-justify-center\">\n @if (row.user_isactive) {\n <span\n class=\"tw-inline-flex tw-items-center tw-px-2.5 tw-py-0.5 tw-rounded-full tw-text-xs tw-font-medium tw-bg-green-100 tw-text-green-800\">\n <svg class=\"tw-w-1.5 tw-h-1.5 tw-mr-1\" fill=\"currentColor\" viewBox=\"0 0 8 8\">\n <circle cx=\"4\" cy=\"4\" r=\"3\" />\n </svg>\n Active\n </span>\n } @else {\n <span\n class=\"tw-inline-flex tw-items-center tw-px-2.5 tw-py-0.5 tw-rounded-full tw-text-xs tw-font-medium tw-bg-red-100 tw-text-red-800\">\n <svg class=\"tw-w-1.5 tw-h-1.5 tw-mr-1\" fill=\"currentColor\" viewBox=\"0 0 8 8\">\n <circle cx=\"4\" cy=\"4\" r=\"3\" />\n </svg>\n Inactive\n </span>\n }\n </div>\n</ng-template>\n\n<!-- Actions Template using cide-ele-dropdown -->\n<ng-template #actionsTemplate let-value let-row=\"row\" let-column=\"column\">\n <cide-ele-dropdown [items]=\"getDropdownItems(row)\" [config]=\"{ triggerIcon: 'more_vert', triggerSize: 'sm', usePortal: true, minWidth: 200 }\" (itemClick)=\"onDropdownItemClick($event, row)\">\n </cide-ele-dropdown>\n</ng-template>\n</cide-lyt-shared-wrapper>", styles: [".user-master-listing-container{@apply tw-w-full tw-h-full;}:host{@apply tw-w-full tw-h-full tw-flex tw-flex-col;}\n"] }]
|
|
17919
17972
|
}], ctorParameters: () => [], propDecorators: { gridComponent: [{
|
|
17920
17973
|
type: ViewChild,
|
|
17921
17974
|
args: [CideEleDataGridComponent]
|