@smartbit4all/ng-client 3.0.6 → 3.0.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (57) hide show
  1. package/esm2020/lib/session/dev-tool/smart-dev-tool-dialog/smart-dev-tool-dialog.service.mjs +2 -2
  2. package/esm2020/lib/smart-grid/api/grid-api/api/api.mjs +1 -1
  3. package/esm2020/lib/smart-grid/api/grid-api/api/grid.service.mjs +49 -27
  4. package/esm2020/lib/smart-grid/api/grid-api/api.module.mjs +1 -1
  5. package/esm2020/lib/smart-grid/api/grid-api/configuration.mjs +20 -1
  6. package/esm2020/lib/smart-grid/api/grid-api/encoder.mjs +1 -1
  7. package/esm2020/lib/smart-grid/api/grid-api/index.mjs +2 -1
  8. package/esm2020/lib/smart-grid/api/grid-api/model/gridColumnMeta.mjs +1 -1
  9. package/esm2020/lib/smart-grid/api/grid-api/model/gridDataAccessConfig.mjs +1 -1
  10. package/esm2020/lib/smart-grid/api/grid-api/model/gridModel.mjs +1 -1
  11. package/esm2020/lib/smart-grid/api/grid-api/model/gridPage.mjs +1 -1
  12. package/esm2020/lib/smart-grid/api/grid-api/model/gridRow.mjs +1 -1
  13. package/esm2020/lib/smart-grid/api/grid-api/model/gridSelectionMode.mjs +1 -1
  14. package/esm2020/lib/smart-grid/api/grid-api/model/gridSelectionType.mjs +1 -1
  15. package/esm2020/lib/smart-grid/api/grid-api/model/gridServerModel.mjs +1 -1
  16. package/esm2020/lib/smart-grid/api/grid-api/model/gridUpdateData.mjs +1 -1
  17. package/esm2020/lib/smart-grid/api/grid-api/model/gridView.mjs +1 -1
  18. package/esm2020/lib/smart-grid/api/grid-api/model/gridViewDescriptor.mjs +1 -1
  19. package/esm2020/lib/smart-grid/api/grid-api/model/models.mjs +1 -1
  20. package/esm2020/lib/smart-grid/api/grid-api/param.mjs +2 -0
  21. package/esm2020/lib/smart-grid/api/grid-api/variables.mjs +1 -1
  22. package/esm2020/lib/smart-grid/smart-grid.component.mjs +25 -11
  23. package/esm2020/lib/smart-grid/smart-grid.service.mjs +16 -15
  24. package/esm2020/lib/view-context/api/model/componentModel.mjs +1 -1
  25. package/esm2020/lib/view-context/api/model/link.mjs +21 -0
  26. package/esm2020/lib/view-context/api/model/models.mjs +2 -1
  27. package/esm2020/lib/view-context/api/model/uiAction.mjs +1 -1
  28. package/esm2020/lib/view-context/api/model/view.mjs +1 -1
  29. package/esm2020/lib/view-context/api/model/viewContext.mjs +1 -1
  30. package/esm2020/lib/view-context/api/model/viewContextData.mjs +1 -1
  31. package/esm2020/lib/view-context/projects.mjs +14 -14
  32. package/esm2020/lib/view-context/smart-view-context-error-dialog/smart-view-context-error-dialog.service.mjs +2 -2
  33. package/esm2020/lib/view-context/smart-view-context.module.mjs +4 -2
  34. package/esm2020/lib/view-context/smart-view-context.service.mjs +43 -7
  35. package/fesm2015/smartbit4all-ng-client.mjs +172 -56
  36. package/fesm2015/smartbit4all-ng-client.mjs.map +1 -1
  37. package/fesm2020/smartbit4all-ng-client.mjs +169 -54
  38. package/fesm2020/smartbit4all-ng-client.mjs.map +1 -1
  39. package/lib/session/dev-tool/smart-dev-tool-dialog/smart-dev-tool-dialog.service.d.ts +1 -1
  40. package/lib/smart-grid/api/grid-api/api/grid.service.d.ts +1 -1
  41. package/lib/smart-grid/api/grid-api/configuration.d.ts +24 -0
  42. package/lib/smart-grid/api/grid-api/index.d.ts +1 -0
  43. package/lib/smart-grid/api/grid-api/model/gridViewDescriptor.d.ts +1 -0
  44. package/lib/smart-grid/api/grid-api/param.d.ts +37 -0
  45. package/lib/smart-grid/smart-grid.component.d.ts +2 -0
  46. package/lib/smart-grid/smart-grid.service.d.ts +1 -2
  47. package/lib/view-context/api/model/link.d.ts +38 -0
  48. package/lib/view-context/api/model/models.d.ts +1 -0
  49. package/lib/view-context/api/model/viewContext.d.ts +2 -0
  50. package/lib/view-context/api/model/viewContextData.d.ts +2 -0
  51. package/lib/view-context/projects.d.ts +13 -13
  52. package/lib/view-context/smart-view-context-error-dialog/smart-view-context-error-dialog.service.d.ts +1 -1
  53. package/lib/view-context/smart-view-context.service.d.ts +6 -3
  54. package/package.json +1 -1
  55. package/smartbit4all-ng-client-3.0.8.tgz +0 -0
  56. package/src/lib/smart-grid/api/grid-api/README.md +226 -203
  57. package/smartbit4all-ng-client-3.0.6.tgz +0 -0
@@ -2,7 +2,7 @@ import { MatDialog } from '@angular/material/dialog';
2
2
  import { Router } from '@angular/router';
3
3
  import { Subject } from 'rxjs';
4
4
  import { SmartDevToolDescriptor, SmartDevToolService } from '../smart-dev-tool.service';
5
- import { SmartdialogService } from '../../../../projects';
5
+ import { SmartdialogService } from '../../../smart-dialog/projects';
6
6
  import * as i0 from "@angular/core";
7
7
  export declare class SmartDevToolDialogService extends SmartdialogService {
8
8
  service: SmartDevToolService;
@@ -11,7 +11,7 @@ export declare class GridService {
11
11
  defaultHeaders: HttpHeaders;
12
12
  configuration: Configuration;
13
13
  encoder: HttpParameterCodec;
14
- constructor(httpClient: HttpClient, basePath: string, configuration: Configuration);
14
+ constructor(httpClient: HttpClient, basePath: string | string[], configuration: Configuration);
15
15
  private addToHttpParams;
16
16
  private addToHttpParamsRecursive;
17
17
  /**
@@ -1,4 +1,5 @@
1
1
  import { HttpParameterCodec } from '@angular/common/http';
2
+ import { Param } from './param';
2
3
  export interface ConfigurationParameters {
3
4
  /**
4
5
  * @deprecated Since 5.0. Use credentials instead
@@ -14,7 +15,18 @@ export interface ConfigurationParameters {
14
15
  accessToken?: string | (() => string);
15
16
  basePath?: string;
16
17
  withCredentials?: boolean;
18
+ /**
19
+ * Takes care of encoding query- and form-parameters.
20
+ */
17
21
  encoder?: HttpParameterCodec;
22
+ /**
23
+ * Override the default method for encoding path parameters in various
24
+ * <a href="https://github.com/OAI/OpenAPI-Specification/blob/main/versions/3.1.0.md#style-values">styles</a>.
25
+ * <p>
26
+ * See {@link README.md} for more details
27
+ * </p>
28
+ */
29
+ encodeParam?: (param: Param) => string;
18
30
  /**
19
31
  * The keys are the names in the securitySchemes section of the OpenAPI
20
32
  * document. They should map to the value used for authentication
@@ -39,7 +51,18 @@ export declare class Configuration {
39
51
  accessToken?: string | (() => string);
40
52
  basePath?: string;
41
53
  withCredentials?: boolean;
54
+ /**
55
+ * Takes care of encoding query- and form-parameters.
56
+ */
42
57
  encoder?: HttpParameterCodec;
58
+ /**
59
+ * Encoding of various path parameter
60
+ * <a href="https://github.com/OAI/OpenAPI-Specification/blob/main/versions/3.1.0.md#style-values">styles</a>.
61
+ * <p>
62
+ * See {@link README.md} for more details
63
+ * </p>
64
+ */
65
+ encodeParam: (param: Param) => string;
43
66
  /**
44
67
  * The keys are the names in the securitySchemes section of the OpenAPI
45
68
  * document. They should map to the value used for authentication
@@ -77,4 +100,5 @@ export declare class Configuration {
77
100
  */
78
101
  isJsonMime(mime: string): boolean;
79
102
  lookupCredential(key: string): string | undefined;
103
+ private defaultEncodeParam;
80
104
  }
@@ -3,3 +3,4 @@ export * from './model/models';
3
3
  export * from './variables';
4
4
  export * from './configuration';
5
5
  export * from './api.module';
6
+ export * from './param';
@@ -23,6 +23,7 @@ export interface GridViewDescriptor {
23
23
  selectionMode?: GridSelectionMode;
24
24
  selectionType?: GridSelectionType;
25
25
  preserveSelectionOnPageChange?: boolean;
26
+ showEditColumns?: boolean;
26
27
  }
27
28
  export declare namespace GridViewDescriptor {
28
29
  type KindEnum = 'TABLE' | 'EXPANDABLECARDS1';
@@ -0,0 +1,37 @@
1
+ /**
2
+ * Standard parameter styles defined by OpenAPI spec
3
+ */
4
+ export declare type StandardParamStyle = 'matrix' | 'label' | 'form' | 'simple' | 'spaceDelimited' | 'pipeDelimited' | 'deepObject';
5
+ /**
6
+ * The OpenAPI standard {@link StandardParamStyle}s may be extended by custom styles by the user.
7
+ */
8
+ export declare type ParamStyle = StandardParamStyle | string;
9
+ /**
10
+ * Standard parameter locations defined by OpenAPI spec
11
+ */
12
+ export declare type ParamLocation = 'query' | 'header' | 'path' | 'cookie';
13
+ /**
14
+ * Standard types as defined in <a href="https://swagger.io/specification/#data-types">OpenAPI Specification: Data Types</a>
15
+ */
16
+ export declare type StandardDataType = "integer" | "number" | "boolean" | "string" | "object" | "array";
17
+ /**
18
+ * Standard {@link DataType}s plus your own types/classes.
19
+ */
20
+ export declare type DataType = StandardDataType | string;
21
+ /**
22
+ * Standard formats as defined in <a href="https://swagger.io/specification/#data-types">OpenAPI Specification: Data Types</a>
23
+ */
24
+ export declare type StandardDataFormat = "int32" | "int64" | "float" | "double" | "byte" | "binary" | "date" | "date-time" | "password";
25
+ export declare type DataFormat = StandardDataFormat | string;
26
+ /**
27
+ * The parameter to encode.
28
+ */
29
+ export interface Param {
30
+ name: string;
31
+ value: unknown;
32
+ in: ParamLocation;
33
+ style: ParamStyle;
34
+ explode: boolean;
35
+ dataType: DataType;
36
+ dataFormat: DataFormat | undefined;
37
+ }
@@ -12,6 +12,8 @@ import * as i0 from "@angular/core";
12
12
  export declare class SmartGridComponent implements AfterViewInit, OnDestroy, OnChanges {
13
13
  private service;
14
14
  private cfService;
15
+ private readonly defaultPageSize;
16
+ private readonly defaultPageSizeOptions;
15
17
  private _destroy$;
16
18
  smartGrid?: SmartGrid;
17
19
  uuid: string;
@@ -9,8 +9,6 @@ export declare class SmartGridService extends SmartdialogService {
9
9
  private api;
10
10
  gridModelChanged: Subject<void>;
11
11
  gridModel: GridModel;
12
- pageSize?: number;
13
- length?: number;
14
12
  constructor(api: GridService, dialog: MatDialog, router: Router);
15
13
  load(uuid: string, gridIdentifier: string): Promise<void>;
16
14
  setPage(uuid: string, gridIdentifier: string, offset: string, limit: string): Promise<void>;
@@ -21,6 +19,7 @@ export declare class SmartGridService extends SmartdialogService {
21
19
  update(uuid: string, identifier: string, updateData: GridUpdateData): Promise<void>;
22
20
  closeDialog(): Promise<void>;
23
21
  handleAfterClosed(): void;
22
+ private updateGrid;
24
23
  static ɵfac: i0.ɵɵFactoryDeclaration<SmartGridService, never>;
25
24
  static ɵprov: i0.ɵɵInjectableDeclaration<SmartGridService>;
26
25
  }
@@ -0,0 +1,38 @@
1
+ /**
2
+ * View API
3
+ * View API
4
+ *
5
+ * The version of the OpenAPI document: 1.0.0
6
+ * Contact: info@it4all.hu
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ /**
13
+ * An anchor with a href representing a hyperlink object, which the client will open. For possible attributes see https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a
14
+ */
15
+ export interface Link {
16
+ /**
17
+ * The URL that this link points to. It will be anchor\'s href attribute\'s value.
18
+ */
19
+ url: string;
20
+ /**
21
+ * Specifies if created anchor should contain download attribute.
22
+ */
23
+ download?: boolean;
24
+ /**
25
+ * Used only when download is true, it will download attribute\'s value
26
+ */
27
+ filename?: string;
28
+ target?: Link.TargetEnum;
29
+ }
30
+ export declare namespace Link {
31
+ type TargetEnum = 'SELF' | 'BLANK' | 'PARENT' | 'TOP';
32
+ const TargetEnum: {
33
+ Self: TargetEnum;
34
+ Blank: TargetEnum;
35
+ Parent: TargetEnum;
36
+ Top: TargetEnum;
37
+ };
38
+ }
@@ -5,6 +5,7 @@ export * from './componentModelChange';
5
5
  export * from './dataChange';
6
6
  export * from './dataChangeEvent';
7
7
  export * from './dataChangeKind';
8
+ export * from './link';
8
9
  export * from './messageData';
9
10
  export * from './messageOption';
10
11
  export * from './messageOptionType';
@@ -11,6 +11,7 @@
11
11
  */
12
12
  import { OpenPendingData } from './openPendingData';
13
13
  import { View } from './view';
14
+ import { Link } from './link';
14
15
  /**
15
16
  * The same session can be valid / used in multiple UIs, this object represents a UI.
16
17
  */
@@ -18,5 +19,6 @@ export interface ViewContext {
18
19
  uri: string;
19
20
  uuid?: string;
20
21
  views: Array<View>;
22
+ links: Array<Link>;
21
23
  openPendingData?: OpenPendingData;
22
24
  }
@@ -10,10 +10,12 @@
10
10
  * Do not edit the class manually.
11
11
  */
12
12
  import { ViewData } from './viewData';
13
+ import { Link } from './link';
13
14
  /**
14
15
  * The same session can be valid / used in multiple UIs, this object represents a UI.
15
16
  */
16
17
  export interface ViewContextData {
17
18
  uuid?: string;
18
19
  views: Array<ViewData>;
20
+ links: Array<Link>;
19
21
  }
@@ -1,13 +1,13 @@
1
- export * from "./smart-view-context.service";
2
- export * from "./smart-view-context.model";
3
- export * from "./smart-view-context.module";
4
- export * from "./smart-view-redirect/smart-view-redirect";
5
- export * from "./api/index";
6
- export * from "./smart-ui-action/ui-action-toolbar.component";
7
- export * from "./smart-ui-action/ui-action.service";
8
- export * from "./smart-ui-action/ui-action.model";
9
- export * from "./smart-ui-action/ui-action.descriptor.service";
10
- export * from "./smart-ui-action/dialogs/ui-action-confirm-dialog/ui-action-confirm-dialog.service";
11
- export * from "./smart-ui-action/dialogs/ui-action-confirm-dialog/ui-action-confirm-dialog.component";
12
- export * from "./smart-ui-action/dialogs/ui-action-input-dialog/ui-action-input-dialog.service";
13
- export * from "./smart-ui-action/dialogs/ui-action-input-dialog/ui-action-input-dialog.component";
1
+ export * from './smart-view-context.service';
2
+ export * from './smart-view-context.model';
3
+ export * from './smart-view-context.module';
4
+ export * from './smart-view-redirect/smart-view-redirect';
5
+ export * from './api/index';
6
+ export * from './smart-ui-action/ui-action-toolbar.component';
7
+ export * from './smart-ui-action/ui-action.service';
8
+ export * from './smart-ui-action/ui-action.model';
9
+ export * from './smart-ui-action/ui-action.descriptor.service';
10
+ export * from './smart-ui-action/dialogs/ui-action-confirm-dialog/ui-action-confirm-dialog.service';
11
+ export * from './smart-ui-action/dialogs/ui-action-confirm-dialog/ui-action-confirm-dialog.component';
12
+ export * from './smart-ui-action/dialogs/ui-action-input-dialog/ui-action-input-dialog.service';
13
+ export * from './smart-ui-action/dialogs/ui-action-input-dialog/ui-action-input-dialog.component';
@@ -1,9 +1,9 @@
1
1
  import { MatDialog, MatDialogRef } from '@angular/material/dialog';
2
2
  import { Router } from '@angular/router';
3
- import { SmartdialogService } from '../../../projects';
4
3
  import { ViewApiError } from '../api';
5
4
  import { SmartViewContextApiError } from '../smart-view-context.model';
6
5
  import { SmartViewContextService } from '../smart-view-context.service';
6
+ import { SmartdialogService } from '../../smart-dialog/projects';
7
7
  import * as i0 from "@angular/core";
8
8
  export declare class SmartViewContextErrorDialogService extends SmartdialogService {
9
9
  private viewContext;
@@ -1,7 +1,7 @@
1
- import { OnDestroy } from '@angular/core';
1
+ import { InjectionToken, Injector, OnDestroy } from '@angular/core';
2
2
  import { Subject } from 'rxjs';
3
3
  import { SmartSessionService } from '../session/smart-session.service';
4
- import { ComponentModel, DataChange, MessageData, MessageResult, UiActionDescriptor, UiActionRequest, ViewConstraint, ViewContextChange, ViewContextData, ViewContextUpdate, ViewData, ViewService } from './api';
4
+ import { ComponentModel, DataChange, Link, MessageData, MessageResult, UiActionDescriptor, UiActionRequest, ViewConstraint, ViewContextChange, ViewContextData, ViewContextUpdate, ViewData, ViewService } from './api';
5
5
  import { SmartTranslateService, SmartViewContextApiError, SmartViewContextApiErrors, SmartViewHandlerModel } from './smart-view-context.model';
6
6
  import { SmartSubject } from '../smart-subject/projects';
7
7
  import { SmartNavigationService } from '../smart-navigation/projects';
@@ -10,12 +10,14 @@ import * as i0 from "@angular/core";
10
10
  export declare const SmartViewContextErrorDialogButtonLabel = "SmartViewContextErrorDialogButtonLabel";
11
11
  export declare const SmartViewContextErrorDialogTitle = "SmartViewContextErrorDialogTitle";
12
12
  export declare const SmartViewContextErrorDialogMessage = "SmartViewContextErrorDialogMessage";
13
+ export declare const DIALOG_DISABLE_CLOSE: InjectionToken<boolean>;
13
14
  export declare class SmartViewContextService implements OnDestroy {
14
15
  private view;
15
16
  private session;
16
17
  private navigation;
17
18
  private dialog;
18
19
  private apiQueueService;
20
+ private inject;
19
21
  private tabIdName;
20
22
  private tabIdhttpHeaderName;
21
23
  messageDialogname: string | undefined;
@@ -39,7 +41,7 @@ export declare class SmartViewContextService implements OnDestroy {
39
41
  get translateService(): SmartTranslateService | undefined;
40
42
  private _translateService?;
41
43
  translateServiceChanged: Subject<void>;
42
- constructor(view: ViewService, session: SmartSessionService, navigation: SmartNavigationService, dialog: SmartdialogService, apiQueueService: ApiQueueService);
44
+ constructor(view: ViewService, session: SmartSessionService, navigation: SmartNavigationService, dialog: SmartdialogService, apiQueueService: ApiQueueService, inject: Injector);
43
45
  ngOnDestroy(): void;
44
46
  follow(uuid: string, detectChange: SmartSubject<any>): void;
45
47
  unfollow(uuid: string): void;
@@ -62,6 +64,7 @@ export declare class SmartViewContextService implements OnDestroy {
62
64
  closeView(view: ViewData): void;
63
65
  restoreViews(uuid: string): Promise<void>;
64
66
  syncView(): void;
67
+ protected createLink(linkData: Link): void;
65
68
  getUuidOfPage(pageName: string): string;
66
69
  message(messageData: MessageData, messageResult: MessageResult): Promise<void>;
67
70
  getSmartViewContextApiErrorByCode(code: string): Promise<SmartViewContextApiError>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@smartbit4all/ng-client",
3
- "version": "3.0.6",
3
+ "version": "3.0.8",
4
4
  "peerDependencies": {
5
5
  "@angular/animations": "^13.3.9",
6
6
  "@angular/common": "^13.2.0",
Binary file