@nettyapps/ntybase 21.1.7 → 21.1.10
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.
|
@@ -644,13 +644,14 @@ class CommonService {
|
|
|
644
644
|
*/
|
|
645
645
|
normalizeTurkish(text) {
|
|
646
646
|
return text
|
|
647
|
-
.
|
|
647
|
+
.replace(/I/g, 'i')
|
|
648
648
|
.replace(/[ıİ]/g, 'i')
|
|
649
649
|
.replace(/[ğĞ]/g, 'g')
|
|
650
650
|
.replace(/[üÜ]/g, 'u')
|
|
651
651
|
.replace(/[şŞ]/g, 's')
|
|
652
652
|
.replace(/[öÖ]/g, 'o')
|
|
653
|
-
.replace(/[çÇ]/g, 'c')
|
|
653
|
+
.replace(/[çÇ]/g, 'c')
|
|
654
|
+
.toLocaleLowerCase('tr-TR');
|
|
654
655
|
}
|
|
655
656
|
/**
|
|
656
657
|
* Gets the clean URL path without fragments or query params
|
|
@@ -704,7 +705,6 @@ class CommonService {
|
|
|
704
705
|
* @returns merged string
|
|
705
706
|
*/
|
|
706
707
|
mergeColumns(columns, seperator = ' ') {
|
|
707
|
-
console.log('mergeColumns', columns);
|
|
708
708
|
let result = '';
|
|
709
709
|
columns.forEach((column) => {
|
|
710
710
|
if (!(column == undefined || column == null)) {
|
|
@@ -1328,15 +1328,19 @@ class NettyAgGridBase extends NettyAppsBase {
|
|
|
1328
1328
|
backClicked() {
|
|
1329
1329
|
this.commonService.goBack();
|
|
1330
1330
|
}
|
|
1331
|
-
/**
|
|
1332
|
-
|
|
1331
|
+
/**
|
|
1332
|
+
* Set data into the grid
|
|
1333
|
+
* @param data Array of records to set
|
|
1334
|
+
* @param hideWarning hide the warning message if no records found
|
|
1335
|
+
*/
|
|
1336
|
+
setData(data, hideWarning = false) {
|
|
1333
1337
|
this.recordList.set(data);
|
|
1334
1338
|
if (this.columnDefs() == null || this.columnDefs().length == 0) {
|
|
1335
1339
|
this.initAgGrid();
|
|
1336
1340
|
}
|
|
1337
1341
|
if (this.searchValue() && this.gridApi) {
|
|
1338
1342
|
this.gridApi.setGridOption('quickFilterText', this.searchValue());
|
|
1339
|
-
if (!
|
|
1343
|
+
if (!hideWarning) {
|
|
1340
1344
|
if (this.recordList() == undefined || this.recordList().length == 0) {
|
|
1341
1345
|
if (!this._isEmbedded()) {
|
|
1342
1346
|
this.alertService.showWarning('@recordNotFoundSearch');
|
|
@@ -1582,7 +1586,7 @@ class NettyAgGridBase extends NettyAppsBase {
|
|
|
1582
1586
|
});
|
|
1583
1587
|
this.gridApi.setGridOption('rowSelection', { mode: 'singleRow', checkboxes: false });
|
|
1584
1588
|
}
|
|
1585
|
-
if (
|
|
1589
|
+
if (this.readOnly()) {
|
|
1586
1590
|
this.columnDefs().unshift({
|
|
1587
1591
|
headerName: this.translateService.instant('@select'), sortable: false, resizable: false,
|
|
1588
1592
|
filter: false, minWidth: 80, maxWidth: 80, suppressSizeToFit: true,
|
|
@@ -1603,28 +1607,37 @@ class NettyAgGridBase extends NettyAppsBase {
|
|
|
1603
1607
|
// ---------------------------------------------
|
|
1604
1608
|
onShowHideColumns() {
|
|
1605
1609
|
this.gridColumnsVisible.update((a) => !a);
|
|
1606
|
-
this.
|
|
1607
|
-
}
|
|
1608
|
-
showHideColumnsAsync() {
|
|
1609
|
-
setTimeout(() => this.showHideColumns(), 400);
|
|
1610
|
-
}
|
|
1611
|
-
showHideColumns() {
|
|
1612
|
-
var fields = this.columnDefs()
|
|
1613
|
-
.filter((columnDef) => columnDef.ntyHide === 'x')
|
|
1614
|
-
.map((columnDef) => columnDef.field);
|
|
1615
|
-
this.gridApi?.setColumnsVisible(fields, this.gridColumnsVisible());
|
|
1616
|
-
}
|
|
1617
|
-
showHideEmbeddedColumnsAsync() {
|
|
1618
|
-
setTimeout(() => this.showHideEmbeddedColumns(), 100);
|
|
1610
|
+
this.initAgGrid();
|
|
1619
1611
|
}
|
|
1620
|
-
|
|
1621
|
-
|
|
1622
|
-
|
|
1623
|
-
|
|
1624
|
-
|
|
1625
|
-
|
|
1626
|
-
|
|
1627
|
-
|
|
1612
|
+
// showHideColumnsAsync() {
|
|
1613
|
+
// setTimeout(() => this.showHideColumns(), 400);
|
|
1614
|
+
// }
|
|
1615
|
+
// showHideColumns() {
|
|
1616
|
+
// var fields = this.columnDefs()
|
|
1617
|
+
// .filter((columnDef: any) => columnDef.ntyHide === 'x')
|
|
1618
|
+
// .map((columnDef: any) => columnDef.field);
|
|
1619
|
+
// this.gridApi?.setColumnsVisible(fields, this.gridColumnsVisible());
|
|
1620
|
+
// }
|
|
1621
|
+
// showHideEmbeddedColumnsAsync() {
|
|
1622
|
+
// setTimeout(() => this.showHideEmbeddedColumns(), 100);
|
|
1623
|
+
// }
|
|
1624
|
+
// showHideEmbeddedColumns() {
|
|
1625
|
+
// if (this.columnDefs() == undefined || this.columnDefs() == null) {
|
|
1626
|
+
// return;
|
|
1627
|
+
// }
|
|
1628
|
+
// var fields = this.columnDefs()
|
|
1629
|
+
// .filter((columnDef: any) => columnDef.ntyEmbeddedHide == 'x')
|
|
1630
|
+
// .map((columnDef: any) => columnDef.field);
|
|
1631
|
+
// this.gridApi?.setColumnsVisible(fields, !this._isEmbedded());
|
|
1632
|
+
// }
|
|
1633
|
+
isHidden(isEmbeddedHide, isVisibleHide) {
|
|
1634
|
+
const isEmbedded = this._isEmbedded();
|
|
1635
|
+
const isVisibleSwitchOn = this.gridColumnsVisible();
|
|
1636
|
+
if (isVisibleHide && !isVisibleSwitchOn)
|
|
1637
|
+
return true;
|
|
1638
|
+
if (isEmbeddedHide && isEmbedded)
|
|
1639
|
+
return true;
|
|
1640
|
+
return false;
|
|
1628
1641
|
}
|
|
1629
1642
|
// *****************************************
|
|
1630
1643
|
// *** Logging Functions ***
|
|
@@ -2000,7 +2013,7 @@ class NettyAgGridListBase extends NettyAgGridBase {
|
|
|
2000
2013
|
}
|
|
2001
2014
|
//this.loadData();
|
|
2002
2015
|
}
|
|
2003
|
-
else {
|
|
2016
|
+
else if (!this._isPopupValid()) {
|
|
2004
2017
|
// Clear right side nav if parameterGUID is not provided
|
|
2005
2018
|
this.commonService.clearOutlet();
|
|
2006
2019
|
}
|
|
@@ -2022,7 +2035,7 @@ class NettyAgGridListBase extends NettyAgGridBase {
|
|
|
2022
2035
|
// Manage filter expanded state
|
|
2023
2036
|
effect(() => {
|
|
2024
2037
|
this._isEmbedded();
|
|
2025
|
-
this.
|
|
2038
|
+
this.initAgGrid();
|
|
2026
2039
|
});
|
|
2027
2040
|
effect(() => {
|
|
2028
2041
|
const name = this.pageName();
|
|
@@ -4566,5 +4579,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.2", ngImpor
|
|
|
4566
4579
|
* Generated bundle index. Do not edit.
|
|
4567
4580
|
*/
|
|
4568
4581
|
|
|
4569
|
-
export { AlertService, AuthenticationGuard, AuthenticationInterceptor, AuthenticationService, ButtonRenderer, CanDeactivateGuard, CheckboxRenderer, CommonService, ConfirmDialog, CredentialsService, CurrentUserPreference, ENVIRONMENT_CONFIG, EnvironmentInfo, EnvironmentInfoService, ExcelImportBase, ForgotPassword, Login, LoginDto, MFACodeDto, MfaLogin, NettyAgGridBase, NettyAgGridListBase, NettyAgGridListFilterBase, NettyAgGridLogBase, NettyAgGridSaveBase, NettyAgGridService, NettyAppsBase, NettyAppsFilterBase, NettyBaseApp, NettyHelper, NettyImageService, NettyMenuService, NtyLoadingComponent, NtyLoadingInterceptor, Ntybase, NtybaseModule, PageTitle, RangeDateTimeFilter, RangeNumberFilter, RangeStringFilter, UrlHelperService, ntyAuthenticationInterceptor };
|
|
4582
|
+
export { AlertService, AuthenticationGuard, AuthenticationInterceptor, AuthenticationService, ButtonRenderer, CanDeactivateGuard, CheckboxRenderer, CommonService, ConfirmDialog, CredentialsService, CurrentUserPreference, ENVIRONMENT_CONFIG, EnvironmentInfo, EnvironmentInfoService, ExcelImportBase, ForgotPassword, Login, LoginDto, MFACodeDto, MfaLogin, NettyAgGridBase, NettyAgGridListBase, NettyAgGridListFilterBase, NettyAgGridLogBase, NettyAgGridSaveBase, NettyAgGridService, NettyAppsBase, NettyAppsFilterBase, NettyBaseApp, NettyHelper, NettyImageService, NettyMenuService, NtyLoadingComponent, NtyLoadingInterceptor, NtyLoadingService, Ntybase, NtybaseModule, PageTitle, RangeDateTimeFilter, RangeNumberFilter, RangeStringFilter, UrlHelperService, ntyAuthenticationInterceptor };
|
|
4570
4583
|
//# sourceMappingURL=nettyapps-ntybase.mjs.map
|