@topconsultnpm/sdkui-react-beta 6.9.131 → 6.9.132

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -6,6 +6,8 @@ import { IconApply, IconHide, IconRefresh, IconShow, SDKUI_Globals, SDKUI_Locali
6
6
  import TMButton from '../base/TMButton';
7
7
  import TMToggleButton from '../base/TMToggleButton';
8
8
  import TMModal from '../base/TMModal';
9
+ import TMLayoutContainer, { TMLayoutItem } from '../base/TMLayout';
10
+ import { TMColors } from '../../utils/theme';
9
11
  const TMChooserForm = ({ children, title, allowMultipleSelection, hasShowOnlySelectedItems = false, allowGrouping, allowSorting = true, width, height, dataSource, selectedIDs, manageUseLocalizedName = true, hasShowId = true, keyName = "id", customButtons, showDefaultColumns = true, columns, summaryItems, convertID, customFilter, getItems, cellRenderIcon, cellRenderNameAndDesc, onChoose, onClose, onShowIdChanged }) => {
10
12
  const [showId, setShowId] = useState(false);
11
13
  const [showOnlySelectedItems, setShowOnlySelectedItems] = useState(selectedIDs != undefined && selectedIDs.length > 0);
@@ -33,7 +35,8 @@ const TMChooserForm = ({ children, title, allowMultipleSelection, hasShowOnlySel
33
35
  return (_jsxs("div", { style: { display: 'flex', flexDirection: 'row', alignItems: 'center', justifyContent: 'flex-start', gap: '2px' }, children: [_jsx(TMButton, { btnStyle: 'toolbar', caption: SDKUI_Localizator.Apply, disabled: selectedItems.length <= 0, icon: _jsx(IconApply, {}), color: 'success', fontSize: '1.3rem', onClick: () => { onChoose?.(getSelectedIDs()); onClose?.(); } }), hasShowId ? _jsx(TMButton, { btnStyle: 'toolbar', caption: showId ? SDKUI_Localizator.ID_Hide : SDKUI_Localizator.ID_Show, icon: showId ? _jsx(IconHide, {}) : _jsx(IconShow, {}), fontSize: '1.3rem', onClick: () => { setShowId(!showId); onShowIdChanged?.(); } }) : _jsx(_Fragment, {}), _jsx(TMButton, { btnStyle: 'toolbar', caption: SDKUI_Localizator.Refresh, icon: _jsx(IconRefresh, {}), fontSize: '1.3rem', onClick: () => { doGetItems(true); } }), customButtons, hasShowOnlySelectedItems && allowMultipleSelection && _jsx(TMToggleButton, { value: showOnlySelectedItems, elementStyle: { marginLeft: '10px' }, label: 'Mostra solo selezionati', onValueChanged: () => setShowOnlySelectedItems(!showOnlySelectedItems) })] }));
34
36
  };
35
37
  useEffect(() => { doGetItems(false); }, []);
36
- return (_jsx(TMModal, { title: renderTitle(), width: width ?? '550px', height: height ?? '600px', toolbar: _jsx(ToolbarButtons, {}), onClose: onClose, children: children ??
38
+ return (_jsx(TMModal, { title: renderTitle(), width: width ?? '550px', height: height ?? '600px', toolbar: _jsx(ToolbarButtons, {}), onClose: onClose, children: (children ??
39
+ items.length > 0) ?
37
40
  _jsxs(DataGrid, { ref: (grid) => (gridInstance = grid), dataSource: getDataSource(), keyExpr: keyName, allowColumnResizing: true, columnResizingMode: "widget", columnAutoWidth: true, allowColumnReordering: true, showBorders: true, showColumnLines: SDKUI_Globals.dataGridShowColumnLines, showRowLines: SDKUI_Globals.dataGridShowRowLines, height: "100%",
38
41
  // selectedRowKeys={selectedItems.map((item: any) => { return item.id })}
39
42
  onContentReady: (e) => {
@@ -50,6 +53,8 @@ const TMChooserForm = ({ children, title, allowMultipleSelection, hasShowOnlySel
50
53
  onChoose?.(getSelectedIDs());
51
54
  onClose?.();
52
55
  }, onSelectionChanged: (e) => { setSelectedItems(e.selectedRowsData); }, onToolbarPreparing: (e) => { e.toolbarOptions.items.forEach((item) => { if (item.name === "searchPanel")
53
- item.location = "before"; }); }, children: [cellRenderIcon && _jsx(Column, { width: 30, allowResizing: false, allowFiltering: false, allowSorting: false, cellRender: cellRenderIcon }, 0), showDefaultColumns && _jsx(Column, { dataField: "id", visible: showId, dataType: 'number' }, 1), showDefaultColumns && _jsx(Column, { dataField: SDK_Globals.useLocalizedName && manageUseLocalizedName ? "nameLoc" : "name", caption: SDKUI_Localizator.Name, dataType: 'string', defaultSortOrder: allowSorting ? "asc" : undefined, cellRender: cellRenderNameAndDesc }, 2), showDefaultColumns && _jsx(Column, { dataField: "description", dataType: 'string', caption: SDKUI_Localizator.Description, cellRender: cellRenderNameAndDesc }, 3), columns, allowGrouping && _jsx(Grouping, { autoExpandAll: false, expandMode: 'rowClick' }), _jsx(HeaderFilter, { visible: true }), _jsx(Selection, { mode: allowMultipleSelection ? "multiple" : "single", showCheckBoxesMode: "onClick", selectAllMode: 'allPages' }), _jsx(Scrolling, { mode: "standard", useNative: SDKUI_Globals.dataGridUseNativeScrollbar }), _jsx(LoadPanel, { enabled: true }), _jsx(SearchPanel, { visible: true }), _jsx(Paging, { pageSize: 100 }), _jsx(Pager, { visible: true, showInfo: true, showNavigationButtons: true }), _jsxs(Summary, { children: [_jsx(TotalItem, { column: SDK_Globals.useLocalizedName && manageUseLocalizedName ? "nameLoc" : "name", summaryType: "count" }), summaryItems] })] }) }));
56
+ item.location = "before"; }); }, children: [cellRenderIcon && _jsx(Column, { width: 30, allowResizing: false, allowFiltering: false, allowSorting: false, cellRender: cellRenderIcon }, 0), showDefaultColumns && _jsx(Column, { dataField: "id", visible: showId, dataType: 'number' }, 1), showDefaultColumns && _jsx(Column, { dataField: SDK_Globals.useLocalizedName && manageUseLocalizedName ? "nameLoc" : "name", caption: SDKUI_Localizator.Name, dataType: 'string', defaultSortOrder: allowSorting ? "asc" : undefined, cellRender: cellRenderNameAndDesc }, 2), showDefaultColumns && _jsx(Column, { dataField: "description", dataType: 'string', caption: SDKUI_Localizator.Description, cellRender: cellRenderNameAndDesc }, 3), columns, allowGrouping && _jsx(Grouping, { autoExpandAll: false, expandMode: 'rowClick' }), _jsx(HeaderFilter, { visible: true }), _jsx(Selection, { mode: allowMultipleSelection ? "multiple" : "single", showCheckBoxesMode: "onClick", selectAllMode: 'allPages' }), _jsx(Scrolling, { mode: "standard", useNative: SDKUI_Globals.dataGridUseNativeScrollbar }), _jsx(LoadPanel, { enabled: true }), _jsx(SearchPanel, { visible: true }), _jsx(Paging, { pageSize: 100 }), _jsx(Pager, { visible: true, showInfo: true, showNavigationButtons: true }), _jsxs(Summary, { children: [_jsx(TotalItem, { column: SDK_Globals.useLocalizedName && manageUseLocalizedName ? "nameLoc" : "name", summaryType: "count" }), summaryItems] })] })
57
+ :
58
+ _jsx(TMLayoutContainer, { gap: 30, alignItems: 'center', justifyContent: 'center', children: _jsx(TMLayoutItem, { children: _jsx("p", { style: { height: "100%", color: TMColors.primaryColor, fontSize: "1.5rem", display: 'flex', alignItems: 'center', justifyContent: 'center' }, children: SDKUI_Localizator.NoDataToDisplay }) }) }) }));
54
59
  };
55
60
  export default TMChooserForm;
@@ -39,9 +39,9 @@ export declare class SDKUI_Localizator {
39
39
  static get Browser(): "Browsertyp" | "Browser type" | "tipo de navegador" | "Type de navigateur" | "Tipo de navegador" | "Tipo di Browser";
40
40
  static get BrowseAreaFile(): "Dateien in den Supportbereichen durchsuchen" | "Browse files on support areas" | "Explorar los archivos en las áreas de apoyo" | "Parcourir les fichiers dans les zones de support" | "Procurar os arquivos nas áreas de suporte" | "Sfoglia i file nelle aree di appoggio";
41
41
  static get BrowseAreaFolder(): "Ordner in den Supportbereichen durchsuchen" | "Browse folders on support areas" | "Explorar las carpetas en las áreas de apoyo" | "Parcourir les dossiers dans les zones de support" | "Percorra as pastas nas áreas de apoio" | "Sfoglia le cartelle nelle aree di appoggio";
42
- static get CassettoDoganaleExportMRN(): "Zollfach – MRN-Erholung für den Export" | "Customs drawer - MRN recovery for export" | "Cajón aduanero - Recuperación MRN para exportación" | "Tiroir douanier - Récupération MRN pour l'export" | "Gaveta Aduaneira - Recuperação MRN para exportação" | "Cassetto doganale - Recupero MRN per Export";
43
- static get CassettoDoganaleExportVU(): "Zollfach – Wiederherstellung des Ausreisevisums" | "Customs drawer - Exit Visa Recovery" | "Cajón aduanero - Recuperación de Visa de Salida" | "Tiroir douanier - Sortie Récupération Visa" | "Gaveta Aduaneira - Recuperação de Visto de Saída" | "Cassetto doganale - Recupero Visto Uscire per Export";
44
- static get CassettoDoganaleImportMRN(): "Zollfach – MRN-Erholung für den Import" | "Customs drawer - MRN recovery for import" | "Cajón aduanero - Recuperación MRN para importación" | "Tiroir douanier - Récupération MRN à l'import" | "Gaveta Aduaneira - Recuperação MRN para importação" | "Cassetto doganale - Recupero MRN per Import";
42
+ static get CassettoDoganaleExportMRN(): "MRN-Erholung für den Export" | "MRN recovery for export" | "Recuperación MRN para exportación" | "Récupération MRN pour l'export" | "Recuperação MRN para exportação" | "Recupero MRN per Export";
43
+ static get CassettoDoganaleExportVU(): "Wiederherstellung des Ausreisevisums" | "Exit Visa Recovery" | "Recuperación de Visa de Salida" | "Sortie Récupération Visa" | "Recuperação de Visto de Saída" | "Recupero Visto Uscire per Export";
44
+ static get CassettoDoganaleImportMRN(): "MRN-Erholung für den Import" | "MRN recovery for import" | "Recuperación MRN para importación" | "Récupération MRN à l'import" | "Recuperação MRN para importação" | "Recupero MRN per Import";
45
45
  static get Cancel(): "Abbrechen" | "Cancel" | "Anular" | "Annuler" | "Cancelar" | "Annulla";
46
46
  static get ChangePassword(): "Kennwort ändern" | "Change password" | "Cambiar la contraseña" | "Changer le mot de passe" | "Alterar a senha" | "Cambia password";
47
47
  static get CheckIn(): "Check in" | "Enregistrement";
@@ -172,6 +172,7 @@ export declare class SDKUI_Localizator {
172
172
  static get Next(): "Weiter" | "Next" | "Siguiente" | "Suivant" | "Seguinte" | "Successivo";
173
173
  static get No(): "Nein" | "No" | "Non" | "Não";
174
174
  static get NoCredentialsSaved(): "Keine gespeicherten Anmeldedaten" | "No credentials saved" | "No se han guardado credenciales" | "Aucune information d'identification enregistrée" | "Nenhuma credencial salva" | "Nessuna credenziale salvata";
175
+ static get NoDataToDisplay(): "Keine Daten zum Anzeigen" | "No data to display" | "No hay datos para mostrar" | "Aucune donnée à afficher" | "Sem dados para exibir" | "Nessun dato da visualizzare";
175
176
  static get NoDcmtFound(): "Kein Dokument gefunden" | "No documents found" | "Ningún documento encontrado" | "Pas de documents trouvés" | "Nenhum documento encontrado" | "Nessun documento trovato";
176
177
  static get NoneSelection(): "Keine Auswahl" | "No selection" | "Ninguna selección" | "Pas de sélections" | "Nenhuma seleção" | "Nessuna selezione";
177
178
  static get OldPassword(): "Altes Kennwort" | "Old password" | "Contraseña anterior" | "Ancien mot de passe" | "Senha Antiga" | "Password vecchia";
@@ -341,32 +341,32 @@ export class SDKUI_Localizator {
341
341
  }
342
342
  static get CassettoDoganaleExportMRN() {
343
343
  switch (this._cultureID) {
344
- case CultureIDs.De_DE: return "Zollfach – MRN-Erholung für den Export";
345
- case CultureIDs.En_US: return "Customs drawer - MRN recovery for export";
346
- case CultureIDs.Es_ES: return "Cajón aduanero - Recuperación MRN para exportación";
347
- case CultureIDs.Fr_FR: return "Tiroir douanier - Récupération MRN pour l'export";
348
- case CultureIDs.Pt_PT: return "Gaveta Aduaneira - Recuperação MRN para exportação";
349
- default: return "Cassetto doganale - Recupero MRN per Export";
344
+ case CultureIDs.De_DE: return "MRN-Erholung für den Export";
345
+ case CultureIDs.En_US: return "MRN recovery for export";
346
+ case CultureIDs.Es_ES: return "Recuperación MRN para exportación";
347
+ case CultureIDs.Fr_FR: return "Récupération MRN pour l'export";
348
+ case CultureIDs.Pt_PT: return "Recuperação MRN para exportação";
349
+ default: return "Recupero MRN per Export";
350
350
  }
351
351
  }
352
352
  static get CassettoDoganaleExportVU() {
353
353
  switch (this._cultureID) {
354
- case CultureIDs.De_DE: return "Zollfach – Wiederherstellung des Ausreisevisums";
355
- case CultureIDs.En_US: return "Customs drawer - Exit Visa Recovery";
356
- case CultureIDs.Es_ES: return "Cajón aduanero - Recuperación de Visa de Salida";
357
- case CultureIDs.Fr_FR: return "Tiroir douanier - Sortie Récupération Visa";
358
- case CultureIDs.Pt_PT: return "Gaveta Aduaneira - Recuperação de Visto de Saída";
359
- default: return "Cassetto doganale - Recupero Visto Uscire per Export";
354
+ case CultureIDs.De_DE: return "Wiederherstellung des Ausreisevisums";
355
+ case CultureIDs.En_US: return "Exit Visa Recovery";
356
+ case CultureIDs.Es_ES: return "Recuperación de Visa de Salida";
357
+ case CultureIDs.Fr_FR: return "Sortie Récupération Visa";
358
+ case CultureIDs.Pt_PT: return "Recuperação de Visto de Saída";
359
+ default: return "Recupero Visto Uscire per Export";
360
360
  }
361
361
  }
362
362
  static get CassettoDoganaleImportMRN() {
363
363
  switch (this._cultureID) {
364
- case CultureIDs.De_DE: return "Zollfach – MRN-Erholung für den Import";
365
- case CultureIDs.En_US: return "Customs drawer - MRN recovery for import";
366
- case CultureIDs.Es_ES: return "Cajón aduanero - Recuperación MRN para importación";
367
- case CultureIDs.Fr_FR: return "Tiroir douanier - Récupération MRN à l'import";
368
- case CultureIDs.Pt_PT: return "Gaveta Aduaneira - Recuperação MRN para importação";
369
- default: return "Cassetto doganale - Recupero MRN per Import";
364
+ case CultureIDs.De_DE: return "MRN-Erholung für den Import";
365
+ case CultureIDs.En_US: return "MRN recovery for import";
366
+ case CultureIDs.Es_ES: return "Recuperación MRN para importación";
367
+ case CultureIDs.Fr_FR: return "Récupération MRN à l'import";
368
+ case CultureIDs.Pt_PT: return "Recuperação MRN para importação";
369
+ default: return "Recupero MRN per Import";
370
370
  }
371
371
  }
372
372
  static get Cancel() {
@@ -1671,6 +1671,16 @@ export class SDKUI_Localizator {
1671
1671
  default: return "Nessuna credenziale salvata";
1672
1672
  }
1673
1673
  }
1674
+ static get NoDataToDisplay() {
1675
+ switch (this._cultureID) {
1676
+ case CultureIDs.De_DE: return "Keine Daten zum Anzeigen";
1677
+ case CultureIDs.En_US: return "No data to display";
1678
+ case CultureIDs.Es_ES: return "No hay datos para mostrar";
1679
+ case CultureIDs.Fr_FR: return "Aucune donnée à afficher";
1680
+ case CultureIDs.Pt_PT: return "Sem dados para exibir";
1681
+ default: return "Nessun dato da visualizzare";
1682
+ }
1683
+ }
1674
1684
  static get NoDcmtFound() {
1675
1685
  switch (this._cultureID) {
1676
1686
  case CultureIDs.De_DE: return "Kein Dokument gefunden";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@topconsultnpm/sdkui-react-beta",
3
- "version": "6.9.131",
3
+ "version": "6.9.132",
4
4
  "description": "",
5
5
  "scripts": {
6
6
  "test": "echo \"Error: no test specified\" && exit 1",