@gooddata/sdk-backend-base 11.54.0-alpha.5 → 11.54.0-alpha.7

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 (30) hide show
  1. package/esm/convertors/fromBackend/AfmResultConverter.test.helpers.d.ts +4 -0
  2. package/esm/convertors/fromBackend/AfmResultConverter.test.helpers.d.ts.map +1 -0
  3. package/esm/convertors/fromBackend/AfmResultConverter.test.helpers.js +209 -0
  4. package/esm/customBackend/workspace.d.ts +3 -1
  5. package/esm/customBackend/workspace.d.ts.map +1 -1
  6. package/esm/customBackend/workspace.js +6 -0
  7. package/esm/decoratedBackend/analyticalWorkspace.d.ts +3 -1
  8. package/esm/decoratedBackend/analyticalWorkspace.d.ts.map +1 -1
  9. package/esm/decoratedBackend/analyticalWorkspace.js +10 -0
  10. package/esm/decoratedBackend/catalog.d.ts +2 -1
  11. package/esm/decoratedBackend/catalog.d.ts.map +1 -1
  12. package/esm/decoratedBackend/catalog.js +4 -1
  13. package/esm/decoratedBackend/types.d.ts +6 -1
  14. package/esm/decoratedBackend/types.d.ts.map +1 -1
  15. package/esm/decoratedBackend/workspaceReports.d.ts +28 -0
  16. package/esm/decoratedBackend/workspaceReports.d.ts.map +1 -0
  17. package/esm/decoratedBackend/workspaceReports.js +58 -0
  18. package/esm/dummyBackend/InMemoryWorkspaceReportsService.d.ts +54 -0
  19. package/esm/dummyBackend/InMemoryWorkspaceReportsService.d.ts.map +1 -0
  20. package/esm/dummyBackend/InMemoryWorkspaceReportsService.js +252 -0
  21. package/esm/dummyBackend/index.d.ts.map +1 -1
  22. package/esm/dummyBackend/index.js +24 -2
  23. package/esm/index.d.ts +4 -1
  24. package/esm/index.d.ts.map +1 -1
  25. package/esm/index.js +3 -0
  26. package/esm/ldmFactories/catalog/computedAttributeFactory.d.ts +23 -0
  27. package/esm/ldmFactories/catalog/computedAttributeFactory.d.ts.map +1 -0
  28. package/esm/ldmFactories/catalog/computedAttributeFactory.js +31 -0
  29. package/esm/sdk-backend-base.d.ts +116 -0
  30. package/package.json +9 -9
@@ -0,0 +1,4 @@
1
+ import { type IResultHeader } from "@gooddata/sdk-model";
2
+ export declare const resultHeaders: IResultHeader[][][];
3
+ export declare const transformedResultHeaders: IResultHeader[][][];
4
+ //# sourceMappingURL=AfmResultConverter.test.helpers.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"AfmResultConverter.test.helpers.d.ts","sourceRoot":"","sources":["../../../src/convertors/fromBackend/AfmResultConverter.test.helpers.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,KAAK,aAAa,EAAE,MAAM,qBAAqB,CAAC;AAEzD,eAAO,MAAM,aAAa,EAAE,aAAa,EAAE,EAAE,EAuG5C,CAAC;AAEF,eAAO,MAAM,wBAAwB,EAAE,aAAa,EAAE,EAAE,EAuGvD,CAAC"}
@@ -0,0 +1,209 @@
1
+ // (C) 2020-2026 GoodData Corporation
2
+ export const resultHeaders = [
3
+ [
4
+ [
5
+ {
6
+ attributeHeaderItem: {
7
+ name: "CN",
8
+ uri: "/gdc/md/projectId/obj/319/elements?id=44",
9
+ },
10
+ },
11
+ {
12
+ attributeHeaderItem: {
13
+ name: "JP",
14
+ uri: "/gdc/md/projectId/obj/319/elements?id=58",
15
+ },
16
+ },
17
+ {
18
+ attributeHeaderItem: {
19
+ name: "VN",
20
+ uri: "/gdc/md/projectId/obj/319/elements?id=114",
21
+ },
22
+ },
23
+ ],
24
+ ],
25
+ [
26
+ [
27
+ {
28
+ attributeHeaderItem: {
29
+ name: "Japan",
30
+ uri: "/gdc/md/projectId/obj/323/elements?id=59",
31
+ },
32
+ },
33
+ {
34
+ attributeHeaderItem: {
35
+ name: "China",
36
+ uri: "/gdc/md/projectId/obj/323/elements?id=46",
37
+ },
38
+ },
39
+ {
40
+ attributeHeaderItem: {
41
+ name: "Vietnam",
42
+ uri: "/gdc/md/projectId/obj/323/elements?id=115",
43
+ },
44
+ },
45
+ {
46
+ attributeHeaderItem: {
47
+ name: "Vietnam",
48
+ uri: "/gdc/md/projectId/obj/323/elements?id=115",
49
+ },
50
+ },
51
+ ],
52
+ [
53
+ {
54
+ attributeHeaderItem: {
55
+ name: "04/07/2020",
56
+ uri: "/gdc/md/projectId/obj/272/elements?id=43927",
57
+ },
58
+ },
59
+ {
60
+ attributeHeaderItem: {
61
+ name: "04/07/2020",
62
+ uri: "/gdc/md/projectId/obj/272/elements?id=43927",
63
+ },
64
+ },
65
+ {
66
+ attributeHeaderItem: {
67
+ name: "04/07/2020",
68
+ uri: "/gdc/md/projectId/obj/272/elements?id=43927",
69
+ },
70
+ },
71
+ {
72
+ attributeHeaderItem: {
73
+ name: "05/01/2020",
74
+ uri: "/gdc/md/projectId/obj/272/elements?id=43951",
75
+ },
76
+ },
77
+ ],
78
+ [
79
+ {
80
+ measureHeaderItem: {
81
+ name: "Sum of Cases",
82
+ order: 0,
83
+ },
84
+ },
85
+ {
86
+ measureHeaderItem: {
87
+ name: "Sum of Cases",
88
+ order: 0,
89
+ },
90
+ },
91
+ {
92
+ measureHeaderItem: {
93
+ name: "Sum of Cases",
94
+ order: 0,
95
+ },
96
+ },
97
+ {
98
+ measureHeaderItem: {
99
+ name: "Sum of Cases",
100
+ order: 0,
101
+ },
102
+ },
103
+ ],
104
+ ],
105
+ ];
106
+ export const transformedResultHeaders = [
107
+ [
108
+ [
109
+ {
110
+ attributeHeaderItem: {
111
+ name: "CN-transformed",
112
+ uri: "/gdc/md/projectId/obj/319/elements?id=44",
113
+ },
114
+ },
115
+ {
116
+ attributeHeaderItem: {
117
+ name: "JP-transformed",
118
+ uri: "/gdc/md/projectId/obj/319/elements?id=58",
119
+ },
120
+ },
121
+ {
122
+ attributeHeaderItem: {
123
+ name: "VN-transformed",
124
+ uri: "/gdc/md/projectId/obj/319/elements?id=114",
125
+ },
126
+ },
127
+ ],
128
+ ],
129
+ [
130
+ [
131
+ {
132
+ attributeHeaderItem: {
133
+ name: "Japan-transformed",
134
+ uri: "/gdc/md/projectId/obj/323/elements?id=59",
135
+ },
136
+ },
137
+ {
138
+ attributeHeaderItem: {
139
+ name: "China-transformed",
140
+ uri: "/gdc/md/projectId/obj/323/elements?id=46",
141
+ },
142
+ },
143
+ {
144
+ attributeHeaderItem: {
145
+ name: "Vietnam-transformed",
146
+ uri: "/gdc/md/projectId/obj/323/elements?id=115",
147
+ },
148
+ },
149
+ {
150
+ attributeHeaderItem: {
151
+ name: "Vietnam-transformed",
152
+ uri: "/gdc/md/projectId/obj/323/elements?id=115",
153
+ },
154
+ },
155
+ ],
156
+ [
157
+ {
158
+ attributeHeaderItem: {
159
+ name: "04/07/2020-transformed",
160
+ uri: "/gdc/md/projectId/obj/272/elements?id=43927",
161
+ },
162
+ },
163
+ {
164
+ attributeHeaderItem: {
165
+ name: "04/07/2020-transformed",
166
+ uri: "/gdc/md/projectId/obj/272/elements?id=43927",
167
+ },
168
+ },
169
+ {
170
+ attributeHeaderItem: {
171
+ name: "04/07/2020-transformed",
172
+ uri: "/gdc/md/projectId/obj/272/elements?id=43927",
173
+ },
174
+ },
175
+ {
176
+ attributeHeaderItem: {
177
+ name: "05/01/2020-transformed",
178
+ uri: "/gdc/md/projectId/obj/272/elements?id=43951",
179
+ },
180
+ },
181
+ ],
182
+ [
183
+ {
184
+ measureHeaderItem: {
185
+ name: "Sum of Cases",
186
+ order: 0,
187
+ },
188
+ },
189
+ {
190
+ measureHeaderItem: {
191
+ name: "Sum of Cases",
192
+ order: 0,
193
+ },
194
+ },
195
+ {
196
+ measureHeaderItem: {
197
+ name: "Sum of Cases",
198
+ order: 0,
199
+ },
200
+ },
201
+ {
202
+ measureHeaderItem: {
203
+ name: "Sum of Cases",
204
+ order: 0,
205
+ },
206
+ },
207
+ ],
208
+ ],
209
+ ];
@@ -1,4 +1,4 @@
1
- import { type IAnalyticalWorkspace, type IAttributeHierarchiesService, type IDataFiltersService, type IDateFilterConfigsQuery, type IExecutionFactory, type IGenAIService, type IReferencesService, type IWorkspaceAccessControlService, type IWorkspaceAgentsService, type IWorkspaceAttributesService, type IWorkspaceAutomationService, type IWorkspaceCatalogFactory, type IWorkspaceDashboardsService, type IWorkspaceDatasetsService, type IWorkspaceDescriptor, type IWorkspaceExportDefinitionsService, type IWorkspaceExportTemplatesService, type IWorkspaceFactsService, type IWorkspaceInsightsService, type IWorkspaceKeyDriverAnalysisService, type IWorkspaceLogicalModelService, type IWorkspaceMeasuresService, type IWorkspaceObjectPermissionsService, type IWorkspaceParametersService, type IWorkspacePermissionsService, type IWorkspaceSettingsService, type IWorkspaceStylingService, type IWorkspaceUserGroupsQuery, type IWorkspaceUsersQuery } from "@gooddata/sdk-backend-spi";
1
+ import { type IAnalyticalWorkspace, type IAttributeHierarchiesService, type IDataFiltersService, type IDateFilterConfigsQuery, type IExecutionFactory, type IGenAIService, type IReferencesService, type IWorkspaceAccessControlService, type IWorkspaceAgentsService, type IWorkspaceAttributesService, type IWorkspaceAutomationService, type IWorkspaceCatalogFactory, type IWorkspaceComputedAttributesService, type IWorkspaceDashboardsService, type IWorkspaceDatasetsService, type IWorkspaceDescriptor, type IWorkspaceExportDefinitionsService, type IWorkspaceExportTemplatesService, type IWorkspaceFactsService, type IWorkspaceInsightsService, type IWorkspaceKeyDriverAnalysisService, type IWorkspaceLogicalModelService, type IWorkspaceMeasuresService, type IWorkspaceObjectPermissionsService, type IWorkspaceParametersService, type IWorkspacePermissionsService, type IWorkspaceReportsService, type IWorkspaceSettingsService, type IWorkspaceStylingService, type IWorkspaceUserGroupsQuery, type IWorkspaceUsersQuery } from "@gooddata/sdk-backend-spi";
2
2
  import { type CustomBackendConfig, type CustomBackendState } from "./config.js";
3
3
  /**
4
4
  * @internal
@@ -20,6 +20,7 @@ export declare class CustomWorkspace implements IAnalyticalWorkspace {
20
20
  catalog(): IWorkspaceCatalogFactory;
21
21
  measures(): IWorkspaceMeasuresService;
22
22
  parameters(): IWorkspaceParametersService;
23
+ computedAttributes(): IWorkspaceComputedAttributesService;
23
24
  facts(): IWorkspaceFactsService;
24
25
  datasets(): IWorkspaceDatasetsService;
25
26
  insights(): IWorkspaceInsightsService;
@@ -38,5 +39,6 @@ export declare class CustomWorkspace implements IAnalyticalWorkspace {
38
39
  genAI(): IGenAIService;
39
40
  references(): IReferencesService;
40
41
  exportTemplates(): IWorkspaceExportTemplatesService;
42
+ reports(): IWorkspaceReportsService;
41
43
  }
42
44
  //# sourceMappingURL=workspace.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"workspace.d.ts","sourceRoot":"","sources":["../../src/customBackend/workspace.ts"],"names":[],"mappings":"AAEA,OAAO,EACH,KAAK,oBAAoB,EACzB,KAAK,4BAA4B,EACjC,KAAK,mBAAmB,EACxB,KAAK,uBAAuB,EAC5B,KAAK,iBAAiB,EACtB,KAAK,aAAa,EAClB,KAAK,kBAAkB,EACvB,KAAK,8BAA8B,EACnC,KAAK,uBAAuB,EAC5B,KAAK,2BAA2B,EAChC,KAAK,2BAA2B,EAChC,KAAK,wBAAwB,EAC7B,KAAK,2BAA2B,EAChC,KAAK,yBAAyB,EAC9B,KAAK,oBAAoB,EACzB,KAAK,kCAAkC,EACvC,KAAK,gCAAgC,EACrC,KAAK,sBAAsB,EAC3B,KAAK,yBAAyB,EAC9B,KAAK,kCAAkC,EACvC,KAAK,6BAA6B,EAClC,KAAK,yBAAyB,EAC9B,KAAK,kCAAkC,EACvC,KAAK,2BAA2B,EAChC,KAAK,4BAA4B,EACjC,KAAK,yBAAyB,EAC9B,KAAK,wBAAwB,EAC7B,KAAK,yBAAyB,EAC9B,KAAK,oBAAoB,EAE5B,MAAM,2BAA2B,CAAC;AAEnC,OAAO,EAAE,KAAK,mBAAmB,EAAE,KAAK,kBAAkB,EAAE,MAAM,aAAa,CAAC;AAGhF;;GAEG;AACH,qBAAa,eAAgB,YAAW,oBAAoB;aAEpC,SAAS,EAAE,MAAM;IACjC,OAAO,CAAC,QAAQ,CAAC,MAAM;IACvB,OAAO,CAAC,QAAQ,CAAC,KAAK;IAH1B,YACoB,SAAS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AAU,IAAI,2BAA2B,CAE/C;IAGM,QAAQ,IAAI,yBAAyB,CAE3C;IAGM,OAAO,IAAI,wBAAwB,CAEzC;IAKM,WAAW,IAAI,4BAA4B,CAEjD;IAEM,iBAAiB,IAAI,kCAAkC,CAE7D;IAEM,OAAO,IAAI,wBAAwB,CAEzC;IAEM,QAAQ,IAAI,yBAAyB,CAE3C;IAEM,UAAU,IAAI,2BAA2B,CAE/C;IAEM,kBAAkB,IAAI,mCAAmC,CAE/D;IAEM,KAAK,IAAI,sBAAsB,CAErC;IAEM,QAAQ,IAAI,yBAAyB,CAE3C;IAEM,QAAQ,IAAI,yBAAyB,CAE3C;IAEM,UAAU,IAAI,2BAA2B,CAE/C;IAEM,KAAK,IAAI,oBAAoB,CAEnC;IAEM,iBAAiB,IAAI,uBAAuB,CAElD;IAEM,UAAU,IAAI,yBAAyB,CAE7C;IAEM,aAAa,IAAI,8BAA8B,CAErD;IAEM,iBAAiB,IAAI,kCAAkC,CAE7D;IAEM,oBAAoB,IAAI,4BAA4B,CAE1D;IAEM,MAAM,IAAI,uBAAuB,CAEvC;IAEM,iBAAiB,IAAI,kCAAkC,CAE7D;IAEM,WAAW,IAAI,mBAAmB,CAExC;IAEM,YAAY,IAAI,6BAA6B,CAEnD;IAEM,WAAW,IAAI,2BAA2B,CAEhD;IAEM,KAAK,IAAI,aAAa,CAE5B;IAEM,UAAU,IAAI,kBAAkB,CAEtC;IAEM,eAAe,IAAI,gCAAgC,CAEzD;IAEM,OAAO,IAAI,wBAAwB,CAEzC;CACJ"}
@@ -58,6 +58,9 @@ export class CustomWorkspace {
58
58
  parameters() {
59
59
  throw new NotSupported("parameters service is not supported");
60
60
  }
61
+ computedAttributes() {
62
+ throw new NotSupported("computed attributes service is not supported");
63
+ }
61
64
  facts() {
62
65
  throw new NotSupported("measures service is not supported");
63
66
  }
@@ -112,4 +115,7 @@ export class CustomWorkspace {
112
115
  exportTemplates() {
113
116
  throw new NotSupported("export templates are not supported");
114
117
  }
118
+ reports() {
119
+ throw new NotSupported("reports are not supported");
120
+ }
115
121
  }
@@ -1,4 +1,4 @@
1
- import { type IAnalyticalWorkspace, type IAttributeHierarchiesService, type IDataFiltersService, type IDateFilterConfigsQuery, type IExecutionFactory, type IGenAIService, type IReferencesService, type IWorkspaceAccessControlService, type IWorkspaceAgentsService, type IWorkspaceAttributesService, type IWorkspaceAutomationService, type IWorkspaceCatalogFactory, type IWorkspaceDashboardsService, type IWorkspaceDatasetsService, type IWorkspaceDescriptor, type IWorkspaceDescriptorUpdate, type IWorkspaceExportDefinitionsService, type IWorkspaceExportTemplatesService, type IWorkspaceFactsService, type IWorkspaceInsightsService, type IWorkspaceKeyDriverAnalysisService, type IWorkspaceLogicalModelService, type IWorkspaceMeasuresService, type IWorkspaceObjectPermissionsService, type IWorkspaceParametersService, type IWorkspacePermissionsService, type IWorkspaceSettingsService, type IWorkspaceStylingService, type IWorkspaceUserGroupsQuery, type IWorkspaceUsersQuery } from "@gooddata/sdk-backend-spi";
1
+ import { type IAnalyticalWorkspace, type IAttributeHierarchiesService, type IDataFiltersService, type IDateFilterConfigsQuery, type IExecutionFactory, type IGenAIService, type IReferencesService, type IWorkspaceAccessControlService, type IWorkspaceAgentsService, type IWorkspaceAttributesService, type IWorkspaceAutomationService, type IWorkspaceCatalogFactory, type IWorkspaceComputedAttributesService, type IWorkspaceDashboardsService, type IWorkspaceDatasetsService, type IWorkspaceDescriptor, type IWorkspaceDescriptorUpdate, type IWorkspaceExportDefinitionsService, type IWorkspaceExportTemplatesService, type IWorkspaceFactsService, type IWorkspaceInsightsService, type IWorkspaceKeyDriverAnalysisService, type IWorkspaceLogicalModelService, type IWorkspaceMeasuresService, type IWorkspaceObjectPermissionsService, type IWorkspaceParametersService, type IWorkspacePermissionsService, type IWorkspaceReportsService, type IWorkspaceSettingsService, type IWorkspaceStylingService, type IWorkspaceUserGroupsQuery, type IWorkspaceUsersQuery } from "@gooddata/sdk-backend-spi";
2
2
  import { type DecoratorFactories } from "./types.js";
3
3
  export declare class AnalyticalWorkspaceDecorator implements IAnalyticalWorkspace {
4
4
  workspace: string;
@@ -14,6 +14,7 @@ export declare class AnalyticalWorkspaceDecorator implements IAnalyticalWorkspac
14
14
  keyDriverAnalysis(): IWorkspaceKeyDriverAnalysisService;
15
15
  measures(): IWorkspaceMeasuresService;
16
16
  parameters(): IWorkspaceParametersService;
17
+ computedAttributes(): IWorkspaceComputedAttributesService;
17
18
  facts(): IWorkspaceFactsService;
18
19
  insights(): IWorkspaceInsightsService;
19
20
  dashboards(): IWorkspaceDashboardsService;
@@ -35,5 +36,6 @@ export declare class AnalyticalWorkspaceDecorator implements IAnalyticalWorkspac
35
36
  genAI(): IGenAIService;
36
37
  references(): IReferencesService;
37
38
  exportTemplates(): IWorkspaceExportTemplatesService;
39
+ reports(): IWorkspaceReportsService;
38
40
  }
39
41
  //# sourceMappingURL=analyticalWorkspace.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"analyticalWorkspace.d.ts","sourceRoot":"","sources":["../../src/decoratedBackend/analyticalWorkspace.ts"],"names":[],"mappings":"AAEA,OAAO,EACH,KAAK,oBAAoB,EACzB,KAAK,4BAA4B,EACjC,KAAK,mBAAmB,EACxB,KAAK,uBAAuB,EAC5B,KAAK,iBAAiB,EACtB,KAAK,aAAa,EAClB,KAAK,kBAAkB,EACvB,KAAK,8BAA8B,EACnC,KAAK,uBAAuB,EAC5B,KAAK,2BAA2B,EAChC,KAAK,2BAA2B,EAChC,KAAK,wBAAwB,EAC7B,KAAK,2BAA2B,EAChC,KAAK,yBAAyB,EAC9B,KAAK,oBAAoB,EACzB,KAAK,0BAA0B,EAC/B,KAAK,kCAAkC,EACvC,KAAK,gCAAgC,EACrC,KAAK,sBAAsB,EAC3B,KAAK,yBAAyB,EAC9B,KAAK,kCAAkC,EACvC,KAAK,6BAA6B,EAClC,KAAK,yBAAyB,EAC9B,KAAK,kCAAkC,EACvC,KAAK,2BAA2B,EAChC,KAAK,4BAA4B,EACjC,KAAK,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D;IAEM,KAAK,IAAI,aAAa,CAE5B;IAEM,UAAU,IAAI,kBAAkB,CAEtC;IAEM,eAAe,IAAI,gCAAgC,CAQzD;IAEM,OAAO,IAAI,wBAAwB,CAQzC;CACJ"}
@@ -51,6 +51,9 @@ export class AnalyticalWorkspaceDecorator {
51
51
  parameters() {
52
52
  return this.decorated.parameters();
53
53
  }
54
+ computedAttributes() {
55
+ return this.decorated.computedAttributes();
56
+ }
54
57
  facts() {
55
58
  const { facts } = this.factories;
56
59
  if (facts) {
@@ -142,4 +145,11 @@ export class AnalyticalWorkspaceDecorator {
142
145
  }
143
146
  return this.decorated.exportTemplates();
144
147
  }
148
+ reports() {
149
+ const { workspaceReports } = this.factories;
150
+ if (workspaceReports) {
151
+ return workspaceReports(this.decorated.reports(), this.workspace);
152
+ }
153
+ return this.decorated.reports();
154
+ }
145
155
  }
@@ -1,5 +1,5 @@
1
1
  import { type IWorkspaceCatalog, type IWorkspaceCatalogAvailableItemsFactory, type IWorkspaceCatalogFactory, type IWorkspaceCatalogFactoryOptions } from "@gooddata/sdk-backend-spi";
2
- import { type CatalogItem, type CatalogItemType, type ICatalogAttribute, type ICatalogAttributeHierarchy, type ICatalogDateDataset, type ICatalogFact, type ICatalogGroup, type ICatalogMeasure, type ObjRef } from "@gooddata/sdk-model";
2
+ import { type CatalogItem, type CatalogItemType, type ICatalogAttribute, type ICatalogAttributeHierarchy, type ICatalogComputedAttribute, type ICatalogDateDataset, type ICatalogFact, type ICatalogGroup, type ICatalogMeasure, type ObjRef } from "@gooddata/sdk-model";
3
3
  /**
4
4
  * @alpha
5
5
  */
@@ -44,5 +44,6 @@ export declare abstract class DecoratedWorkspaceCatalog implements IWorkspaceCat
44
44
  allItems(): CatalogItem[];
45
45
  measures(): ICatalogMeasure[];
46
46
  attributeHierarchies(): ICatalogAttributeHierarchy[];
47
+ computedAttributes(): ICatalogComputedAttribute[];
47
48
  }
48
49
  //# sourceMappingURL=catalog.d.ts.map
@@ -1 +1 @@
1
- {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 // (C) 2019-2026 GoodData Corporation
2
2
  /**
3
3
  * @alpha
4
4
  */
@@ -71,4 +71,7 @@ export class DecoratedWorkspaceCatalog {
71
71
  attributeHierarchies() {
72
72
  return this.decorated.attributeHierarchies();
73
73
  }
74
+ computedAttributes() {
75
+ return this.decorated.computedAttributes();
76
+ }
74
77
  }
@@ -1,4 +1,4 @@
1
- import { type IExecutionFactory, type IGeoService, type IOrganizationExportTemplatesService, type ISecuritySettingsService, type IWorkspaceAttributesService, type IWorkspaceAutomationService, type IWorkspaceCatalogFactory, type IWorkspaceDashboardsService, type IWorkspaceDatasetsService, type IWorkspaceExportTemplatesService, type IWorkspaceFactsService, type IWorkspaceInsightsService, type IWorkspaceMeasuresService, type IWorkspaceSettingsService } from "@gooddata/sdk-backend-spi";
1
+ import { type IExecutionFactory, type IGeoService, type IOrganizationExportTemplatesService, type ISecuritySettingsService, type IWorkspaceAttributesService, type IWorkspaceAutomationService, type IWorkspaceCatalogFactory, type IWorkspaceDashboardsService, type IWorkspaceDatasetsService, type IWorkspaceExportTemplatesService, type IWorkspaceFactsService, type IWorkspaceInsightsService, type IWorkspaceMeasuresService, type IWorkspaceReportsService, type IWorkspaceSettingsService } from "@gooddata/sdk-backend-spi";
2
2
  /**
3
3
  * @alpha
4
4
  */
@@ -55,6 +55,10 @@ export type OrganizationExportTemplatesDecoratorFactory = (exportTemplates: IOrg
55
55
  * @alpha
56
56
  */
57
57
  export type WorkspaceExportTemplatesDecoratorFactory = (exportTemplates: IWorkspaceExportTemplatesService, workspace: string) => IWorkspaceExportTemplatesService;
58
+ /**
59
+ * @alpha
60
+ */
61
+ export type WorkspaceReportsDecoratorFactory = (reports: IWorkspaceReportsService, workspace: string) => IWorkspaceReportsService;
58
62
  /**
59
63
  * Provides factory functions for the different decorators (currently only supports execution
60
64
  * decorator). Input to each factory function is the original implementation from the wrapped backend, output
@@ -77,5 +81,6 @@ export type DecoratorFactories = {
77
81
  geo?: GeoDecoratorFactory;
78
82
  organizationExportTemplates?: OrganizationExportTemplatesDecoratorFactory;
79
83
  workspaceExportTemplates?: WorkspaceExportTemplatesDecoratorFactory;
84
+ workspaceReports?: WorkspaceReportsDecoratorFactory;
80
85
  };
81
86
  //# sourceMappingURL=types.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/decoratedBackend/types.ts"],"names":[],"mappings":"AAEA,OAAO,EACH,KAAK,iBAAiB,EACtB,KAAK,WAAW,EAChB,KAAK,mCAAmC,EACxC,KAAK,wBAAwB,EAC7B,KAAK,2BAA2B,EAChC,KAAK,2BAA2B,EAChC,KAAK,wBAAwB,EAC7B,KAAK,2BAA2B,EAChC,KAAK,yBAAyB,EAC9B,KAAK,gCAAgC,EACrC,KAAK,sBAAsB,EAC3B,KAAK,yBAAyB,EAC9B,KAAK,yBAAyB,EAC9B,KAAK,yBAAyB,EACjC,MAAM,2BAA2B,CAAC;AAEnC;;GAEG;AACH,MAAM,MAAM,yBAAyB,GAAG,CAAC,gBAAgB,EAAE,iBAAiB,KAAK,iBAAiB,CAAC;AAEnG;;GAEG;AACH,MAAM,MAAM,uBAAuB,GAAG,CAAC,OAAO,EAAE,wBAAwB,KAAK,wBAAwB,CAAC;AAEtG;;GAEG;AACH,MAAM,MAAM,gCAAgC,GAAG,CAC3C,gBAAgB,EAAE,wBAAwB,KACzC,wBAAwB,CAAC;AAE9B;;GAEG;AACH,MAAM,MAAM,iCAAiC,GAAG,CAC5C,QAAQ,EAAE,yBAAyB,EACnC,SAAS,EAAE,MAAM,KAChB,yBAAyB,CAAC;AAE/B;;GAEG;AACH,MAAM,MAAM,0BAA0B,GAAG,CACrC,UAAU,EAAE,2BAA2B,EACvC,SAAS,EAAE,MAAM,KAChB,2BAA2B,CAAC;AAEjC;;GAEG;AACH,MAAM,MAAM,2BAA2B,GAAG,CACtC,WAAW,EAAE,2BAA2B,EACxC,SAAS,EAAE,MAAM,KAChB,2BAA2B,CAAC;AAEjC;;GAEG;AACH,MAAM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AAO,CAAC,EAAE,uBAAuB,CAAC;IAClC,gBAAgB,CAAC,EAAE,gCAAgC,CAAC;IACpD,iBAAiB,CAAC,EAAE,iCAAiC,CAAC;IACtD,UAAU,CAAC,EAAE,0BAA0B,CAAC;IACxC,WAAW,CAAC,EAAE,2BAA2B,CAAC;IAC1C,QAAQ,CAAC,EAAE,wBAAwB,CAAC;IACpC,QAAQ,CAAC,EAAE,wBAAwB,CAAC;IACpC,QAAQ,CAAC,EAAE,wBAAwB,CAAC;IACpC,UAAU,CAAC,EAAE,0BAA0B,CAAC;IACxC,KAAK,CAAC,EAAE,qBAAqB,CAAC;IAC9B,GAAG,CAAC,EAAE,mBAAmB,CAAC;IAC1B,2BAA2B,CAAC,EAAE,2CAA2C,CAAC;IAC1E,wBAAwB,CAAC,EAAE,wCAAwC,CAAC;IACpE,gBAAgB,CAAC,EAAE,gCAAgC,CAAC;CACvD,CAAC"}
@@ -0,0 +1,28 @@
1
+ import { type IWorkspaceReportsService } from "@gooddata/sdk-backend-spi";
2
+ import { type IReport, type IReportDefinition, type IReportPageLayout, type IReportPageLayoutDefinition, type IReportTemplate, type IReportTemplateDefinition, type ObjRef } from "@gooddata/sdk-model";
3
+ /**
4
+ * Base class for report-service decorators. Delegates every method of the decorated
5
+ * `IWorkspaceReportsService`; subclasses override the methods they customize.
6
+ *
7
+ * @alpha
8
+ */
9
+ export declare abstract class DecoratedWorkspaceReportsService implements IWorkspaceReportsService {
10
+ protected readonly decorated: IWorkspaceReportsService;
11
+ protected constructor(decorated: IWorkspaceReportsService);
12
+ getReportPageLayouts(): Promise<IReportPageLayout[]>;
13
+ getReportPageLayout(ref: ObjRef): Promise<IReportPageLayout>;
14
+ createReportPageLayout(page: IReportPageLayoutDefinition): Promise<IReportPageLayout>;
15
+ updateReportPageLayout(page: IReportPageLayout): Promise<IReportPageLayout>;
16
+ deleteReportPageLayout(ref: ObjRef): Promise<void>;
17
+ getReportTemplates(): Promise<IReportTemplate[]>;
18
+ getReportTemplate(ref: ObjRef): Promise<IReportTemplate>;
19
+ createReportTemplate(template: IReportTemplateDefinition): Promise<IReportTemplate>;
20
+ updateReportTemplate(template: IReportTemplate): Promise<IReportTemplate>;
21
+ deleteReportTemplate(ref: ObjRef): Promise<void>;
22
+ getReports(): Promise<IReport[]>;
23
+ getReport(ref: ObjRef): Promise<IReport>;
24
+ createReport(report: IReportDefinition): Promise<IReport>;
25
+ updateReport(report: IReport): Promise<IReport>;
26
+ deleteReport(ref: ObjRef): Promise<void>;
27
+ }
28
+ //# sourceMappingURL=workspaceReports.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"workspaceReports.d.ts","sourceRoot":"","sources":["../../src/decoratedBackend/workspaceReports.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,KAAK,wBAAwB,EAAE,MAAM,2BAA2B,CAAC;AAC1E,OAAO,EACH,KAAK,OAAO,EACZ,KAAK,iBAAiB,EACtB,KAAK,iBAAiB,EACtB,KAAK,2BAA2B,EAChC,KAAK,eAAe,EACpB,KAAK,yBAAyB,EAC9B,KAAK,MAAM,EACd,MAAM,qBAAqB,CAAC;AAE7B;;;;;GAKG;AACH,8BAAsB,gCAAiC,YAAW,wBAAwB;IAChE,SAAS,CAAC,QAAQ,CAAC,SAAS,EAAE,wBAAwB;IAA5E,SAAS,aAAgC,SAAS,EAAE,wBAAwB,EAAI;IAEzE,oBAAoB,IAAI,OAAO,CAAC,iBAAiB,EAAE,CAAC,CAE1D;IAEM,mBAAmB,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC,iBAAiB,CAAC,CAElE;IAEM,sBAAsB,CAAC,IAAI,EAAE,2BAA2B,GAAG,OAAO,CAAC,iBAAiB,CAAC,CAE3F;IAEM,sBAAsB,CAAC,IAAI,EAAE,iBAAiB,GAAG,OAAO,CAAC,iBAAiB,CAAC,CAEjF;IAEM,sBAAsB,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAExD;IAEM,kBAAkB,IAAI,OAAO,CAAC,eAAe,EAAE,CAAC,CAEtD;IAEM,iBAAiB,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC,eAAe,CAAC,CAE9D;IAEM,oBAAoB,CAAC,QAAQ,EAAE,yBAAyB,GAAG,OAAO,CAAC,eAAe,CAAC,CAEzF;IAEM,oBAAoB,CAAC,QAAQ,EAAE,eAAe,GAAG,OAAO,CAAC,eAAe,CAAC,CAE/E;IAEM,oBAAoB,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAEtD;IAEM,UAAU,IAAI,OAAO,CAAC,OAAO,EAAE,CAAC,CAEtC;IAEM,SAAS,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC,OAAO,CAAC,CAE9C;IAEM,YAAY,CAAC,MAAM,EAAE,iBAAiB,GAAG,OAAO,CAAC,OAAO,CAAC,CAE/D;IAEM,YAAY,CAAC,MAAM,EAAE,OAAO,GAAG,OAAO,CAAC,OAAO,CAAC,CAErD;IAEM,YAAY,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAE9C;CACJ"}
@@ -0,0 +1,58 @@
1
+ // (C) 2026 GoodData Corporation
2
+ /**
3
+ * Base class for report-service decorators. Delegates every method of the decorated
4
+ * `IWorkspaceReportsService`; subclasses override the methods they customize.
5
+ *
6
+ * @alpha
7
+ */
8
+ export class DecoratedWorkspaceReportsService {
9
+ decorated;
10
+ constructor(decorated) {
11
+ this.decorated = decorated;
12
+ }
13
+ getReportPageLayouts() {
14
+ return this.decorated.getReportPageLayouts();
15
+ }
16
+ getReportPageLayout(ref) {
17
+ return this.decorated.getReportPageLayout(ref);
18
+ }
19
+ createReportPageLayout(page) {
20
+ return this.decorated.createReportPageLayout(page);
21
+ }
22
+ updateReportPageLayout(page) {
23
+ return this.decorated.updateReportPageLayout(page);
24
+ }
25
+ deleteReportPageLayout(ref) {
26
+ return this.decorated.deleteReportPageLayout(ref);
27
+ }
28
+ getReportTemplates() {
29
+ return this.decorated.getReportTemplates();
30
+ }
31
+ getReportTemplate(ref) {
32
+ return this.decorated.getReportTemplate(ref);
33
+ }
34
+ createReportTemplate(template) {
35
+ return this.decorated.createReportTemplate(template);
36
+ }
37
+ updateReportTemplate(template) {
38
+ return this.decorated.updateReportTemplate(template);
39
+ }
40
+ deleteReportTemplate(ref) {
41
+ return this.decorated.deleteReportTemplate(ref);
42
+ }
43
+ getReports() {
44
+ return this.decorated.getReports();
45
+ }
46
+ getReport(ref) {
47
+ return this.decorated.getReport(ref);
48
+ }
49
+ createReport(report) {
50
+ return this.decorated.createReport(report);
51
+ }
52
+ updateReport(report) {
53
+ return this.decorated.updateReport(report);
54
+ }
55
+ deleteReport(ref) {
56
+ return this.decorated.deleteReport(ref);
57
+ }
58
+ }
@@ -0,0 +1,54 @@
1
+ import { type IWorkspaceReportsService } from "@gooddata/sdk-backend-spi";
2
+ import { type IReport, type IReportDefinition, type IReportPageLayout, type IReportPageLayoutDefinition, type IReportTemplate, type IReportTemplateDefinition, type ObjRef } from "@gooddata/sdk-model";
3
+ /**
4
+ * Storage hook for {@link InMemoryWorkspaceReportsService}: where the serialized service
5
+ * state is loaded from on construction and saved to after every mutation.
6
+ *
7
+ * @alpha
8
+ */
9
+ export interface IWorkspaceReportsPersistence {
10
+ load(): string | null;
11
+ save(value: string): void;
12
+ }
13
+ /**
14
+ * In-memory implementation of the reports service.
15
+ *
16
+ * @remarks
17
+ * Serves the built-in report page layouts and stores created layouts, templates and reports in memory.
18
+ * Without a persistence hook the state lives only as long as the instance (dummy backend, tests);
19
+ * with one (e.g. localStorage) the state is rehydrated on construction and saved after every mutation.
20
+ *
21
+ * @alpha
22
+ */
23
+ export declare class InMemoryWorkspaceReportsService implements IWorkspaceReportsService {
24
+ private readonly persistence?;
25
+ private readonly pageLayouts;
26
+ private readonly templates;
27
+ private readonly reports;
28
+ private sequence;
29
+ private persistenceDisabled;
30
+ constructor(persistence?: IWorkspaceReportsPersistence | undefined);
31
+ private hydrate;
32
+ private persist;
33
+ private newRef;
34
+ private findBuiltInPageLayout;
35
+ getReportPageLayouts(): Promise<IReportPageLayout[]>;
36
+ getReportPageLayout(ref: ObjRef): Promise<IReportPageLayout>;
37
+ createReportPageLayout(layout: IReportPageLayoutDefinition): Promise<IReportPageLayout>;
38
+ updateReportPageLayout(layout: IReportPageLayout): Promise<IReportPageLayout>;
39
+ deleteReportPageLayout(ref: ObjRef): Promise<void>;
40
+ private assertPageLayoutEditable;
41
+ getReportTemplates(): Promise<IReportTemplate[]>;
42
+ getReportTemplate(ref: ObjRef): Promise<IReportTemplate>;
43
+ createReportTemplate(template: IReportTemplateDefinition): Promise<IReportTemplate>;
44
+ updateReportTemplate(template: IReportTemplate): Promise<IReportTemplate>;
45
+ deleteReportTemplate(ref: ObjRef): Promise<void>;
46
+ getReports(): Promise<IReport[]>;
47
+ getReport(ref: ObjRef): Promise<IReport>;
48
+ createReport(report: IReportDefinition): Promise<IReport>;
49
+ updateReport(report: IReport): Promise<IReport>;
50
+ deleteReport(ref: ObjRef): Promise<void>;
51
+ private store;
52
+ private assertExistsAndUnlocked;
53
+ }
54
+ //# sourceMappingURL=InMemoryWorkspaceReportsService.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"InMemoryWorkspaceReportsService.d.ts","sourceRoot":"","sources":["../../src/dummyBackend/InMemoryWorkspaceReportsService.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,KAAK,wBAAwB,EAAmB,MAAM,2BAA2B,CAAC;AAC3F,OAAO,EAEH,KAAK,OAAO,EACZ,KAAK,iBAAiB,EACtB,KAAK,iBAAiB,EACtB,KAAK,2BAA2B,EAChC,KAAK,eAAe,EACpB,KAAK,yBAAyB,EAC9B,KAAK,MAAM,EAMd,MAAM,qBAAqB,CAAC;AAkC7B;;;;;GAKG;AACH,MAAM,WAAW,4BAA4B;IACzC,IAAI,IAAI,MAAM,GAAG,IAAI,CAAC;IACtB,IAAI,CAAC,KAAK,EAAE,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MtD;IAEM,UAAU,IAAI,OAAO,CAAC,OAAO,EAAE,CAAC,CAGtC;IAEM,SAAS,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC,OAAO,CAAC,CAO9C;IAEM,YAAY,CAAC,MAAM,EAAE,iBAAiB,GAAG,OAAO,CAAC,OAAO,CAAC,CAS/D;IAEM,YAAY,CAAC,MAAM,EAAE,OAAO,GAAG,OAAO,CAAC,OAAO,CAAC,CAOrD;IAEM,YAAY,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAM9C;IAED,OAAO,CAAC,KAAK;IAQb,OAAO,CAAC,uBAAuB;CAalC"}
@@ -0,0 +1,252 @@
1
+ // (C) 2026 GoodData Corporation
2
+ import { UnexpectedError } from "@gooddata/sdk-backend-spi";
3
+ import { BuiltInReportPageLayouts, areObjRefsEqual, idRef, isIdentifierRef, isObjRef, objRefToString, } from "@gooddata/sdk-model";
4
+ // Key ignores the identifier ref's optional object type (typed and untyped identifier
5
+ // refs are equivalent under areObjRefsEqual) but keeps the ref kind, so an identifier
6
+ // and a URI with the same string stay distinct.
7
+ function refKey(ref) {
8
+ return isIdentifierRef(ref) ? `id:${ref.identifier}` : `uri:${ref.uri}`;
9
+ }
10
+ // JSON round-trip detaches stored state from caller-held objects on both the
11
+ // write and the read side, the way a real backend's serialization does.
12
+ function deepClone(value) {
13
+ return JSON.parse(JSON.stringify(value));
14
+ }
15
+ function decode(value) {
16
+ const decoded = new Map();
17
+ if (!Array.isArray(value)) {
18
+ return decoded;
19
+ }
20
+ value.forEach((entry) => {
21
+ if (!isObjRef(entry?.ref)) {
22
+ throw new Error("Persisted report entry has no object reference.");
23
+ }
24
+ decoded.set(refKey(entry.ref), entry);
25
+ });
26
+ return decoded;
27
+ }
28
+ function replace(target, source) {
29
+ target.clear();
30
+ source.forEach((value, key) => target.set(key, value));
31
+ }
32
+ /**
33
+ * In-memory implementation of the reports service.
34
+ *
35
+ * @remarks
36
+ * Serves the built-in report page layouts and stores created layouts, templates and reports in memory.
37
+ * Without a persistence hook the state lives only as long as the instance (dummy backend, tests);
38
+ * with one (e.g. localStorage) the state is rehydrated on construction and saved after every mutation.
39
+ *
40
+ * @alpha
41
+ */
42
+ export class InMemoryWorkspaceReportsService {
43
+ persistence;
44
+ pageLayouts = new Map();
45
+ templates = new Map();
46
+ reports = new Map();
47
+ sequence = 0;
48
+ // Set when the storage rejected a write. Read-through would then restore the older
49
+ // persisted snapshot and silently discard the mutation, so the in-memory state
50
+ // becomes authoritative from that point on.
51
+ persistenceDisabled = false;
52
+ constructor(persistence) {
53
+ this.persistence = persistence;
54
+ this.hydrate();
55
+ }
56
+ // Persisted storage is read through on every operation, so no instance can act on a
57
+ // stale snapshot and overwrite state written by another instance, tab or process.
58
+ // Storage failures (sandboxed embeds, exhausted quota, corrupted value) degrade to
59
+ // the in-memory state rather than propagating to the caller.
60
+ hydrate() {
61
+ if (!this.persistence || this.persistenceDisabled) {
62
+ return;
63
+ }
64
+ try {
65
+ const serialized = this.persistence.load();
66
+ if (!serialized) {
67
+ return;
68
+ }
69
+ const state = JSON.parse(serialized);
70
+ // Decode into fresh maps first: a malformed entry must not leave the service
71
+ // with half-cleared state, so the swap happens only once everything decoded.
72
+ const pageLayouts = decode(state?.pageLayouts);
73
+ const templates = decode(state?.templates);
74
+ const reports = decode(state?.reports);
75
+ replace(this.pageLayouts, pageLayouts);
76
+ replace(this.templates, templates);
77
+ replace(this.reports, reports);
78
+ this.sequence = Math.max(this.sequence, typeof state?.sequence === "number" ? state.sequence : 0);
79
+ }
80
+ catch {
81
+ // unreadable, malformed or schema-incompatible state — keep the in-memory state
82
+ }
83
+ }
84
+ persist() {
85
+ if (!this.persistence || this.persistenceDisabled) {
86
+ return;
87
+ }
88
+ const state = {
89
+ pageLayouts: [...this.pageLayouts.values()],
90
+ templates: [...this.templates.values()],
91
+ reports: [...this.reports.values()],
92
+ sequence: this.sequence,
93
+ };
94
+ try {
95
+ this.persistence.save(JSON.stringify(state));
96
+ }
97
+ catch {
98
+ this.persistenceDisabled = true;
99
+ }
100
+ }
101
+ newRef(type, store) {
102
+ let ref;
103
+ do {
104
+ this.sequence += 1;
105
+ ref = idRef(`${type}_${this.sequence}`, type);
106
+ } while (store.has(refKey(ref)));
107
+ return ref;
108
+ }
109
+ findBuiltInPageLayout(ref) {
110
+ return BuiltInReportPageLayouts.find((layout) => areObjRefsEqual(layout.ref, ref));
111
+ }
112
+ getReportPageLayouts() {
113
+ this.hydrate();
114
+ return Promise.resolve([...BuiltInReportPageLayouts, ...deepClone([...this.pageLayouts.values()])]);
115
+ }
116
+ getReportPageLayout(ref) {
117
+ this.hydrate();
118
+ const builtIn = this.findBuiltInPageLayout(ref);
119
+ if (builtIn) {
120
+ return Promise.resolve(builtIn);
121
+ }
122
+ const layout = this.pageLayouts.get(refKey(ref));
123
+ if (!layout) {
124
+ throw new UnexpectedError(`Report page layout "${objRefToString(ref)}" does not exist.`);
125
+ }
126
+ return Promise.resolve(deepClone(layout));
127
+ }
128
+ createReportPageLayout(layout) {
129
+ this.hydrate();
130
+ if (layout.ref && this.findBuiltInPageLayout(layout.ref)) {
131
+ throw new UnexpectedError(`Report page layout "${objRefToString(layout.ref)}" is built-in and cannot be replaced.`);
132
+ }
133
+ const created = {
134
+ ...deepClone(layout),
135
+ ref: layout.ref ?? this.newRef("reportPageLayout", this.pageLayouts),
136
+ };
137
+ this.store(this.pageLayouts, created, "Report page layout");
138
+ this.persist();
139
+ return Promise.resolve(deepClone(created));
140
+ }
141
+ updateReportPageLayout(layout) {
142
+ this.hydrate();
143
+ this.assertPageLayoutEditable(layout.ref);
144
+ const updated = { ...deepClone(layout), isBuiltIn: undefined };
145
+ this.pageLayouts.set(refKey(layout.ref), updated);
146
+ this.persist();
147
+ return Promise.resolve(deepClone(updated));
148
+ }
149
+ deleteReportPageLayout(ref) {
150
+ this.hydrate();
151
+ this.assertPageLayoutEditable(ref);
152
+ this.pageLayouts.delete(refKey(ref));
153
+ this.persist();
154
+ return Promise.resolve();
155
+ }
156
+ assertPageLayoutEditable(ref) {
157
+ if (this.findBuiltInPageLayout(ref)) {
158
+ throw new UnexpectedError(`Report page layout "${objRefToString(ref)}" is built-in and cannot be changed.`);
159
+ }
160
+ this.assertExistsAndUnlocked(this.pageLayouts, ref, "Report page layout");
161
+ }
162
+ getReportTemplates() {
163
+ this.hydrate();
164
+ return Promise.resolve(deepClone([...this.templates.values()]));
165
+ }
166
+ getReportTemplate(ref) {
167
+ this.hydrate();
168
+ const template = this.templates.get(refKey(ref));
169
+ if (!template) {
170
+ throw new UnexpectedError(`Report template "${objRefToString(ref)}" does not exist.`);
171
+ }
172
+ return Promise.resolve(deepClone(template));
173
+ }
174
+ createReportTemplate(template) {
175
+ this.hydrate();
176
+ const created = {
177
+ ...deepClone(template),
178
+ ref: template.ref ?? this.newRef("reportTemplate", this.templates),
179
+ };
180
+ this.store(this.templates, created, "Report template");
181
+ this.persist();
182
+ return Promise.resolve(deepClone(created));
183
+ }
184
+ updateReportTemplate(template) {
185
+ this.hydrate();
186
+ this.assertExistsAndUnlocked(this.templates, template.ref, "Report template");
187
+ const updated = deepClone(template);
188
+ this.templates.set(refKey(template.ref), updated);
189
+ this.persist();
190
+ return Promise.resolve(deepClone(updated));
191
+ }
192
+ deleteReportTemplate(ref) {
193
+ this.hydrate();
194
+ this.assertExistsAndUnlocked(this.templates, ref, "Report template");
195
+ this.templates.delete(refKey(ref));
196
+ this.persist();
197
+ return Promise.resolve();
198
+ }
199
+ getReports() {
200
+ this.hydrate();
201
+ return Promise.resolve(deepClone([...this.reports.values()]));
202
+ }
203
+ getReport(ref) {
204
+ this.hydrate();
205
+ const report = this.reports.get(refKey(ref));
206
+ if (!report) {
207
+ throw new UnexpectedError(`Report "${objRefToString(ref)}" does not exist.`);
208
+ }
209
+ return Promise.resolve(deepClone(report));
210
+ }
211
+ createReport(report) {
212
+ this.hydrate();
213
+ const created = {
214
+ ...deepClone(report),
215
+ ref: report.ref ?? this.newRef("report", this.reports),
216
+ };
217
+ this.store(this.reports, created, "Report");
218
+ this.persist();
219
+ return Promise.resolve(deepClone(created));
220
+ }
221
+ updateReport(report) {
222
+ this.hydrate();
223
+ this.assertExistsAndUnlocked(this.reports, report.ref, "Report");
224
+ const updated = deepClone(report);
225
+ this.reports.set(refKey(report.ref), updated);
226
+ this.persist();
227
+ return Promise.resolve(deepClone(updated));
228
+ }
229
+ deleteReport(ref) {
230
+ this.hydrate();
231
+ this.assertExistsAndUnlocked(this.reports, ref, "Report");
232
+ this.reports.delete(refKey(ref));
233
+ this.persist();
234
+ return Promise.resolve();
235
+ }
236
+ store(store, object, what) {
237
+ const key = refKey(object.ref);
238
+ if (store.has(key)) {
239
+ throw new UnexpectedError(`${what} "${objRefToString(object.ref)}" already exists.`);
240
+ }
241
+ store.set(key, object);
242
+ }
243
+ assertExistsAndUnlocked(store, ref, what) {
244
+ const existing = store.get(refKey(ref));
245
+ if (!existing) {
246
+ throw new UnexpectedError(`${what} "${objRefToString(ref)}" does not exist.`);
247
+ }
248
+ if (existing.isLocked) {
249
+ throw new UnexpectedError(`${what} "${objRefToString(ref)}" is locked.`);
250
+ }
251
+ }
252
+ }
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/dummyBackend/index.ts"],"names":[],"mappings":"AAIA,OAAO,EAMH,KAAK,kBAAkB,EACvB,KAAK,wBAAwB,EA4B7B,KAAK,SAAS,EAYd,KAAK,gBAAgB,EA2FxB,MAAM,2BAA2B,CAAC;AACnC,OAAO,EAyCH,KAAK,oBAAoB,EA4C5B,MAAM,qBAAqB,CAAC;AAS7B;;GAEG;AACH,MAAM,MAAM,kBAAkB,GAAG,wBAAwB,GAAG;IACxD;;;;;;;;;;OAUG;IACH,qBAAqB,EAAE,KAAK,GAAG,mBAAmB,GAAG,gBAAgB,CAAC;CACzE,CAAC;AAEF;;GAEG;AACH,eAAO,MAAM,yBAAyB,EAAE,kBAGvC,CAAC;AAEF;;;;;;;;;;;GAWG;AACH,wBAAgB,YAAY,CAAC,MAAM,GAAE,kBAA8C,GAAG,kBAAkB,CAqFvG;AAED;;;;;;;;;GASG;AACH,wBAAgB,qBAAqB,IAAI,kBAAkB,CAE1D;AAED;;;;;;;;;;;;GAYG;AACH,wBAAgB,aAAa,CACzB,UAAU,EAAE,oBAAoB,EAChC,MAAM,CAAC,EAAE,gBAAgB,EACzB,MAAM,GAAE,kBAA8C,GACvD,SAAS,CAwDX"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/dummyBackend/index.ts"],"names":[],"mappings":"AAIA,OAAO,EAMH,KAAK,kBAAkB,EACvB,KAAK,wBAAwB,EA4B7B,KAAK,SAAS,EAYd,KAAK,gBAAgB,EA6FxB,MAAM,2BAA2B,CAAC;AACnC,OAAO,EA0CH,KAAK,oBAAoB,EA4C5B,MAAM,qBAAqB,CAAC;AAU7B;;GAEG;AACH,MAAM,MAAM,kBAAkB,GAAG,wBAAwB,GAAG;IACxD;;;;;;;;;;OAUG;IACH,qBAAqB,EAAE,KAAK,GAAG,mBAAmB,GAAG,gBAAgB,CAAC;CACzE,CAAC;AAEF;;GAEG;AACH,eAAO,MAAM,yBAAyB,EAAE,kBAGvC,CAAC;AAEF;;;;;;;;;;;GAWG;AACH,wBAAgB,YAAY,CAAC,MAAM,GAAE,kBAA8C,GAAG,kBAAkB,CA2FvG;AAED;;;;;;;;;GASG;AACH,wBAAgB,qBAAqB,IAAI,kBAAkB,CAE1D;AAED;;;;;;;;;;;;GAYG;AACH,wBAAgB,aAAa,CACzB,UAAU,EAAE,oBAAoB,EAChC,MAAM,CAAC,EAAE,gBAAgB,EACzB,MAAM,GAAE,kBAA8C,GACvD,SAAS,CAwDX"}
@@ -7,6 +7,7 @@ import { DummyAnalyticsCatalogService } from "./DummyAnalyticsCatalogService.js"
7
7
  import { DummyChatConversations, DummyGenAIChatThread } from "./DummyGenAIChatThread.js";
8
8
  import { DummySemanticQualityService } from "./DummySemanticQualityService.js";
9
9
  import { DummySemanticSearchQueryBuilder } from "./DummySemanticSearch.js";
10
+ import { InMemoryWorkspaceReportsService } from "./InMemoryWorkspaceReportsService.js";
10
11
  /**
11
12
  *
12
13
  */
@@ -27,6 +28,7 @@ export const defaultDummyBackendConfig = {
27
28
  * @internal
28
29
  */
29
30
  export function dummyBackend(config = defaultDummyBackendConfig) {
31
+ const reportsServices = new Map();
30
32
  const noopBackend = {
31
33
  capabilities: {
32
34
  canCalculateTotals: true,
@@ -61,7 +63,12 @@ export function dummyBackend(config = defaultDummyBackendConfig) {
61
63
  throw new NotSupported("not supported");
62
64
  },
63
65
  workspace(id) {
64
- return dummyWorkspace(id, config);
66
+ let reportsService = reportsServices.get(id);
67
+ if (!reportsService) {
68
+ reportsService = new InMemoryWorkspaceReportsService();
69
+ reportsServices.set(id, reportsService);
70
+ }
71
+ return dummyWorkspace(id, config, reportsService);
65
72
  },
66
73
  entitlements() {
67
74
  throw new NotSupported("not supported");
@@ -194,7 +201,7 @@ export function dummyDataView(definition, result, config = defaultDummyBackendCo
194
201
  //
195
202
  // Internals
196
203
  //
197
- function dummyWorkspace(workspace, config) {
204
+ function dummyWorkspace(workspace, config, reportsService) {
198
205
  return {
199
206
  workspace,
200
207
  async getDescriptor() {
@@ -221,6 +228,9 @@ function dummyWorkspace(workspace, config) {
221
228
  parameters() {
222
229
  return new DummyWorkspaceParametersService(workspace);
223
230
  },
231
+ computedAttributes() {
232
+ throw new NotSupported("not supported");
233
+ },
224
234
  facts() {
225
235
  return new DummyWorkspaceFactsService(workspace);
226
236
  },
@@ -328,6 +338,9 @@ function dummyWorkspace(workspace, config) {
328
338
  deleteExportTemplate: () => Promise.resolve(),
329
339
  };
330
340
  },
341
+ reports() {
342
+ return reportsService;
343
+ },
331
344
  };
332
345
  }
333
346
  function dummyDescriptor(workspaceId) {
@@ -533,6 +546,9 @@ class DummyWorkspaceCatalog {
533
546
  attributeHierarchies() {
534
547
  return [];
535
548
  }
549
+ computedAttributes() {
550
+ return [];
551
+ }
536
552
  }
537
553
  class DummyWorkspaceCatalogAvailableItemsFactory {
538
554
  workspace;
@@ -649,6 +665,12 @@ class DummyWorkspaceCatalogWithAvailableItems {
649
665
  availableAttributeHierarchies() {
650
666
  return [];
651
667
  }
668
+ computedAttributes() {
669
+ return [];
670
+ }
671
+ availableComputedAttributes() {
672
+ return [];
673
+ }
652
674
  }
653
675
  class DummyLlmProvidersQuery {
654
676
  withSize(_size) {
package/esm/index.d.ts CHANGED
@@ -12,7 +12,7 @@ export { type DummyBackendConfig, dummyBackend, dummyBackendEmptyData, dummyData
12
12
  export { DummySemanticSearchQueryBuilder } from "./dummyBackend/DummySemanticSearch.js";
13
13
  export { DummyGenAIChatThread, DummyChatConversations } from "./dummyBackend/DummyGenAIChatThread.js";
14
14
  export { decoratedBackend } from "./decoratedBackend/index.js";
15
- export type { DecoratorFactories, CatalogDecoratorFactory, ExecutionDecoratorFactory, SecuritySettingsDecoratorFactory, WorkspaceSettingsDecoratorFactory, AutomationsDecoratorFactory, AttributesDecoratorFactory, InsightsDecoratorFactory, MeasuresDecoratorFactory, DatasetsDecoratorFactory, DashboardsDecoratorFactory, FactsDecoratorFactory, GeoDecoratorFactory, OrganizationExportTemplatesDecoratorFactory, WorkspaceExportTemplatesDecoratorFactory, } from "./decoratedBackend/types.js";
15
+ export type { DecoratorFactories, CatalogDecoratorFactory, ExecutionDecoratorFactory, SecuritySettingsDecoratorFactory, WorkspaceSettingsDecoratorFactory, AutomationsDecoratorFactory, AttributesDecoratorFactory, InsightsDecoratorFactory, MeasuresDecoratorFactory, DatasetsDecoratorFactory, DashboardsDecoratorFactory, FactsDecoratorFactory, GeoDecoratorFactory, OrganizationExportTemplatesDecoratorFactory, WorkspaceExportTemplatesDecoratorFactory, WorkspaceReportsDecoratorFactory, } from "./decoratedBackend/types.js";
16
16
  export { type PreparedExecutionWrapper, DecoratedExecutionFactory, DecoratedPreparedExecution, DecoratedExecutionResult, } from "./decoratedBackend/execution.js";
17
17
  export { DecoratedWorkspaceDashboardsService } from "./decoratedBackend/dashboards.js";
18
18
  export { DecoratedWorkspaceInsightsService } from "./decoratedBackend/insights.js";
@@ -20,6 +20,8 @@ export { type WorkspaceCatalogWrapper, DecoratedWorkspaceCatalogFactory, Decorat
20
20
  export { DecoratedSecuritySettingsService } from "./decoratedBackend/securitySettings.js";
21
21
  export { DecoratedOrganizationExportTemplatesService } from "./decoratedBackend/organizationExportTemplates.js";
22
22
  export { DecoratedWorkspaceExportTemplatesService } from "./decoratedBackend/workspaceExportTemplates.js";
23
+ export { DecoratedWorkspaceReportsService } from "./decoratedBackend/workspaceReports.js";
24
+ export { type IWorkspaceReportsPersistence, InMemoryWorkspaceReportsService, } from "./dummyBackend/InMemoryWorkspaceReportsService.js";
23
25
  export { DecoratedWorkspaceSettingsService } from "./decoratedBackend/workspaceSettings.js";
24
26
  export { type AnalyticalBackendCallbacks, withEventing } from "./eventingBackend/index.js";
25
27
  export { type CachingConfiguration, type CacheControl, withCaching, RecommendedCachingConfiguration, } from "./cachingBackend/index.js";
@@ -40,6 +42,7 @@ export { type IInsightWidgetBuilder, InsightWidgetBuilder, newInsightWidget, } f
40
42
  export { type IKpiWidgetBuilder, KpiWidgetBuilder, newKpiWidget, } from "./ldmFactories/dashboard/kpiWidgetFactory.js";
41
43
  export { type IWidgetBaseBuilder, WidgetBaseBuilder } from "./ldmFactories/dashboard/widgetFactory.js";
42
44
  export { CatalogAttributeBuilder, newCatalogAttribute } from "./ldmFactories/catalog/attributeFactory.js";
45
+ export { CatalogComputedAttributeBuilder, newCatalogComputedAttribute, } from "./ldmFactories/catalog/computedAttributeFactory.js";
43
46
  export { CatalogDateAttributeBuilder, CatalogDateDatasetBuilder, newCatalogDateAttribute, newCatalogDateDataset, } from "./ldmFactories/catalog/dateDatasetFactory.js";
44
47
  export { CatalogFactBuilder, newCatalogFact } from "./ldmFactories/catalog/factFactory.js";
45
48
  export { type IGroupableCatalogItemBuilder, CatalogGroupBuilder, GroupableCatalogItemBuilder, newCatalogGroup, } from "./ldmFactories/catalog/groupFactory.js";
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAIA;;;;;;;;;GASG;AACH,OAAO,EACH,KAAK,kBAAkB,EACvB,YAAY,EACZ,qBAAqB,EACrB,aAAa,GAChB,MAAM,yBAAyB,CAAC;AAEjC,OAAO,EAAE,+BAA+B,EAAE,MAAM,uCAAuC,CAAC;AACxF,OAAO,EAAE,oBAAoB,EAAE,sBAAsB,EAAE,MAAM,wCAAwC,CAAC;AAEtG,OAAO,EAAE,gBAAgB,EAAE,MAAM,6BAA6B,CAAC;AAE/D,YAAY,EACR,kBAAkB,EAClB,uBAAuB,EACvB,yBAAyB,EACzB,gCAAgC,EAChC,iCAAiC,EACjC,2BAA2B,EAC3B,0BAA0B,EAC1B,wBAAwB,EACxB,wBAAwB,EACxB,wBAAwB,EACxB,0BAA0B,EAC1B,qBAAqB,EACrB,mBAAmB,EACnB,2CAA2C,EAC3C,wCAAwC,GAC3C,MAAM,6BAA6B,CAAC;AAErC,OAAO,EACH,KAAK,wBAAwB,EAC7B,yBAAyB,EACzB,0BAA0B,EAC1B,wBAAwB,GAC3B,MAAM,iCAAiC,CAAC;AAEzC,OAAO,EAAE,mCAAmC,EAAE,MAAM,kCAAkC,CAAC;AAEvF,OAAO,EAAE,iCAAiC,EAAE,MAAM,gCAAgC,CAAC;AAEnF,OAAO,EACH,KAAK,uBAAuB,EAC5B,gCAAgC,EAChC,yBAAyB,GAC5B,MAAM,+BAA+B,CAAC;AAEvC,OAAO,EAAE,gCAAgC,EAAE,MAAM,wCAAwC,CAAC;AAE1F,OAAO,EAAE,2CAA2C,EAAE,MAAM,mDAAmD,CAAC;AAEhH,OAAO,EAAE,wCAAwC,EAAE,MAAM,gDAAgD,CAAC;AAE1G,OAAO,EAAE,iCAAiC,EAAE,MAAM,yCAAyC,CAAC;AAE5F,OAAO,EAAE,KAAK,0BAA0B,EAAE,YAAY,EA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AA2B,EAC3B,eAAe,GAClB,MAAM,wCAAwC,CAAC;AAChD,OAAO,EAAE,qBAAqB,EAAE,iBAAiB,EAAE,MAAM,0CAA0C,CAAC;AAEpG,OAAO,EACH,8BAA8B,EAC9B,0BAA0B,GAC7B,MAAM,6CAA6C,CAAC;AACrD,OAAO,EACH,4BAA4B,EAC5B,wBAAwB,GAC3B,MAAM,2CAA2C,CAAC;AACnD,OAAO,EACH,yCAAyC,EACzC,qCAAqC,GACxC,MAAM,+CAA+C,CAAC;AACvD,OAAO,EAAE,KAAK,sBAAsB,EAAE,qBAAqB,EAAE,MAAM,oCAAoC,CAAC;AACxG,OAAO,EAAE,qBAAqB,EAAE,yBAAyB,EAAE,MAAM,wCAAwC,CAAC;AAC1G,OAAO,EACH,4BAA4B,EAC5B,wBAAwB,GAC3B,MAAM,2CAA2C,CAAC;AACnD,OAAO,EACH,yBAAyB,EACzB,6BAA6B,GAChC,MAAM,4CAA4C,CAAC;AACpD,OAAO,EACH,0BAA0B,EAC1B,8BAA8B,GACjC,MAAM,6CAA6C,CAAC;AAErD,OAAO,EAAE,KAAK,uBAAuB,EAAE,sBAAsB,EAAE,MAAM,wCAAwC,CAAC;AAE9G,OAAO,EAAE,iCAAiC,EAAE,MAAM,2CAA2C,CAAC"}
package/esm/index.js CHANGED
@@ -21,6 +21,8 @@ export { DecoratedWorkspaceCatalogFactory, DecoratedWorkspaceCatalog, } from "./
21
21
  export { DecoratedSecuritySettingsService } from "./decoratedBackend/securitySettings.js";
22
22
  export { DecoratedOrganizationExportTemplatesService } from "./decoratedBackend/organizationExportTemplates.js";
23
23
  export { DecoratedWorkspaceExportTemplatesService } from "./decoratedBackend/workspaceExportTemplates.js";
24
+ export { DecoratedWorkspaceReportsService } from "./decoratedBackend/workspaceReports.js";
25
+ export { InMemoryWorkspaceReportsService, } from "./dummyBackend/InMemoryWorkspaceReportsService.js";
24
26
  export { DecoratedWorkspaceSettingsService } from "./decoratedBackend/workspaceSettings.js";
25
27
  export { withEventing } from "./eventingBackend/index.js";
26
28
  export { withCaching, RecommendedCachingConfiguration, } from "./cachingBackend/index.js";
@@ -39,6 +41,7 @@ export { InsightWidgetBuilder, newInsightWidget, } from "./ldmFactories/dashboar
39
41
  export { KpiWidgetBuilder, newKpiWidget, } from "./ldmFactories/dashboard/kpiWidgetFactory.js";
40
42
  export { WidgetBaseBuilder } from "./ldmFactories/dashboard/widgetFactory.js";
41
43
  export { CatalogAttributeBuilder, newCatalogAttribute } from "./ldmFactories/catalog/attributeFactory.js";
44
+ export { CatalogComputedAttributeBuilder, newCatalogComputedAttribute, } from "./ldmFactories/catalog/computedAttributeFactory.js";
42
45
  export { CatalogDateAttributeBuilder, CatalogDateDatasetBuilder, newCatalogDateAttribute, newCatalogDateDataset, } from "./ldmFactories/catalog/dateDatasetFactory.js";
43
46
  export { CatalogFactBuilder, newCatalogFact } from "./ldmFactories/catalog/factFactory.js";
44
47
  export { CatalogGroupBuilder, GroupableCatalogItemBuilder, newCatalogGroup, } from "./ldmFactories/catalog/groupFactory.js";
@@ -0,0 +1,23 @@
1
+ import { type IAttributeDisplayFormMetadataObject, type ICatalogComputedAttribute, type IComputedAttributeMetadataObject } from "@gooddata/sdk-model";
2
+ import { type BuilderModifications } from "../builder.js";
3
+ import { GroupableCatalogItemBuilder } from "./groupFactory.js";
4
+ /**
5
+ * Catalog computed attribute builder
6
+ * See {@link Builder}
7
+ *
8
+ * @beta
9
+ */
10
+ export declare class CatalogComputedAttributeBuilder<T extends ICatalogComputedAttribute = ICatalogComputedAttribute> extends GroupableCatalogItemBuilder<T> {
11
+ computedAttribute(computedAttribute: IComputedAttributeMetadataObject): this;
12
+ defaultDisplayForm(displayForm: IAttributeDisplayFormMetadataObject): this;
13
+ displayForms(displayForms: IAttributeDisplayFormMetadataObject[]): this;
14
+ }
15
+ /**
16
+ * Catalog computed attribute factory
17
+ *
18
+ * @param modifications - catalog computed attribute builder modifications to perform
19
+ * @returns created catalog computed attribute
20
+ * @beta
21
+ */
22
+ export declare const newCatalogComputedAttribute: (modifications: BuilderModifications<CatalogComputedAttributeBuilder<ICatalogComputedAttribute>>) => ICatalogComputedAttribute;
23
+ //# sourceMappingURL=computedAttributeFactory.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"computedAttributeFactory.d.ts","sourceRoot":"","sources":["../../../src/ldmFactories/catalog/computedAttributeFactory.ts"],"names":[],"mappings":"AAEA,OAAO,EACH,KAAK,mCAAmC,EACxC,KAAK,yBAAyB,EAC9B,KAAK,gCAAgC,EACxC,MAAM,qBAAqB,CAAC;AAE7B,OAAO,EAAE,KAAK,oBAAoB,EAAkB,MAAM,eAAe,CAAC;AAE1E,OAAO,EAAE,2BAA2B,EAAE,MAAM,mBAAmB,CAAC;AAEhE;;;;;GAKG;AACH,qBAAa,+BAA+B,CACxC,CAAC,SAAS,yBAAyB,GAAG,yBAAyB,CACjE,SAAQ,2BAA2B,CAAC,CAAC,CAAC;IAC7B,iBAAiB,CAAC,iBAAiB,EAAE,gCAAgC,GAAG,IAAI,CAGlF;IAEM,kBAAkB,CAAC,WAAW,EAAE,mCAAmC,GAAG,IAAI,CAGhF;IAEM,YAAY,CAAC,YAAY,EAAE,mCAAmC,EAAE,GAAG,IAAI,CAG7E;CACJ;AAED;;;;;;GAMG;AACH,eAAO,MAAM,2BAA2B,gIAGyD,CAAC"}
@@ -0,0 +1,31 @@
1
+ // (C) 2026 GoodData Corporation
2
+ import { builderFactory } from "../builder.js";
3
+ import { GroupableCatalogItemBuilder } from "./groupFactory.js";
4
+ /**
5
+ * Catalog computed attribute builder
6
+ * See {@link Builder}
7
+ *
8
+ * @beta
9
+ */
10
+ export class CatalogComputedAttributeBuilder extends GroupableCatalogItemBuilder {
11
+ computedAttribute(computedAttribute) {
12
+ this.item.computedAttribute = computedAttribute;
13
+ return this;
14
+ }
15
+ defaultDisplayForm(displayForm) {
16
+ this.item.defaultDisplayForm = displayForm;
17
+ return this;
18
+ }
19
+ displayForms(displayForms) {
20
+ this.item.displayForms = displayForms;
21
+ return this;
22
+ }
23
+ }
24
+ /**
25
+ * Catalog computed attribute factory
26
+ *
27
+ * @param modifications - catalog computed attribute builder modifications to perform
28
+ * @returns created catalog computed attribute
29
+ * @beta
30
+ */
31
+ export const newCatalogComputedAttribute = (modifications) => builderFactory(CatalogComputedAttributeBuilder, { type: "computedAttribute" }, modifications);
@@ -42,6 +42,7 @@ import { IAuthenticationProvider } from '@gooddata/sdk-backend-spi';
42
42
  import { IBucket } from '@gooddata/sdk-model';
43
43
  import { ICatalogAttribute } from '@gooddata/sdk-model';
44
44
  import { ICatalogAttributeHierarchy } from '@gooddata/sdk-model';
45
+ import { ICatalogComputedAttribute } from '@gooddata/sdk-model';
45
46
  import { ICatalogDateAttribute } from '@gooddata/sdk-model';
46
47
  import { ICatalogDateDataset } from '@gooddata/sdk-model';
47
48
  import { ICatalogFact } from '@gooddata/sdk-model';
@@ -57,6 +58,7 @@ import { IChatThreadQuery } from '@gooddata/sdk-backend-spi';
57
58
  import { IClusteringConfig } from '@gooddata/sdk-backend-spi';
58
59
  import { IClusteringResult } from '@gooddata/sdk-backend-spi';
59
60
  import { ICollectionItemsConfig } from '@gooddata/sdk-backend-spi';
61
+ import { IComputedAttributeMetadataObject } from '@gooddata/sdk-model';
60
62
  import { IDashboard } from '@gooddata/sdk-model';
61
63
  import { IDashboardAttributeFilterConfig } from '@gooddata/sdk-model';
62
64
  import { IDashboardBase } from '@gooddata/sdk-model';
@@ -141,6 +143,12 @@ import { IPostProcessing } from '@gooddata/sdk-model';
141
143
  import { IPreparedExecution } from '@gooddata/sdk-backend-spi';
142
144
  import { IPreparedExecutionOptions } from '@gooddata/sdk-backend-spi';
143
145
  import { IRawExportCustomOverrides } from '@gooddata/sdk-backend-spi';
146
+ import { IReport } from '@gooddata/sdk-model';
147
+ import { IReportDefinition } from '@gooddata/sdk-model';
148
+ import { IReportPageLayout } from '@gooddata/sdk-model';
149
+ import { IReportPageLayoutDefinition } from '@gooddata/sdk-model';
150
+ import { IReportTemplate } from '@gooddata/sdk-model';
151
+ import { IReportTemplateDefinition } from '@gooddata/sdk-model';
144
152
  import { IRequestCorrelationMetadata } from '@gooddata/sdk-backend-spi';
145
153
  import { IResultHeader } from '@gooddata/sdk-model';
146
154
  import { IScheduledMail } from '@gooddata/sdk-model';
@@ -172,6 +180,7 @@ import { IWorkspaceExportTemplatesService } from '@gooddata/sdk-backend-spi';
172
180
  import { IWorkspaceFactsService } from '@gooddata/sdk-backend-spi';
173
181
  import { IWorkspaceInsightsService } from '@gooddata/sdk-backend-spi';
174
182
  import { IWorkspaceMeasuresService } from '@gooddata/sdk-backend-spi';
183
+ import { IWorkspaceReportsService } from '@gooddata/sdk-backend-spi';
175
184
  import { IWorkspaceSettings } from '@gooddata/sdk-backend-spi';
176
185
  import { IWorkspaceSettingsService } from '@gooddata/sdk-backend-spi';
177
186
  import { KpiDrillDefinition } from '@gooddata/sdk-model';
@@ -883,6 +892,18 @@ export declare class CatalogAttributeBuilder<T extends ICatalogAttribute = ICata
883
892
  toExecutionModel(modifications?: AttributeModifications): IAttribute;
884
893
  }
885
894
 
895
+ /**
896
+ * Catalog computed attribute builder
897
+ * See {@link Builder}
898
+ *
899
+ * @beta
900
+ */
901
+ export declare class CatalogComputedAttributeBuilder<T extends ICatalogComputedAttribute = ICatalogComputedAttribute> extends GroupableCatalogItemBuilder<T> {
902
+ computedAttribute(computedAttribute: IComputedAttributeMetadataObject): this;
903
+ defaultDisplayForm(displayForm: IAttributeDisplayFormMetadataObject): this;
904
+ displayForms(displayForms: IAttributeDisplayFormMetadataObject[]): this;
905
+ }
906
+
886
907
  /**
887
908
  * Catalog date attribute builder
888
909
  * See {@link Builder}
@@ -1288,6 +1309,7 @@ export declare abstract class DecoratedWorkspaceCatalog implements IWorkspaceCat
1288
1309
  allItems(): CatalogItem[];
1289
1310
  measures(): ICatalogMeasure[];
1290
1311
  attributeHierarchies(): ICatalogAttributeHierarchy[];
1312
+ computedAttributes(): ICatalogComputedAttribute[];
1291
1313
  }
1292
1314
 
1293
1315
  /**
@@ -1417,6 +1439,32 @@ export declare abstract class DecoratedWorkspaceInsightsService implements IWork
1417
1439
  getInsightWithAddedFilters<T extends IInsightDefinition>(insight: T, filters: IFilter[]): Promise<T>;
1418
1440
  }
1419
1441
 
1442
+ /**
1443
+ * Base class for report-service decorators. Delegates every method of the decorated
1444
+ * `IWorkspaceReportsService`; subclasses override the methods they customize.
1445
+ *
1446
+ * @alpha
1447
+ */
1448
+ export declare abstract class DecoratedWorkspaceReportsService implements IWorkspaceReportsService {
1449
+ protected readonly decorated: IWorkspaceReportsService;
1450
+ protected constructor(decorated: IWorkspaceReportsService);
1451
+ getReportPageLayouts(): Promise<IReportPageLayout[]>;
1452
+ getReportPageLayout(ref: ObjRef): Promise<IReportPageLayout>;
1453
+ createReportPageLayout(page: IReportPageLayoutDefinition): Promise<IReportPageLayout>;
1454
+ updateReportPageLayout(page: IReportPageLayout): Promise<IReportPageLayout>;
1455
+ deleteReportPageLayout(ref: ObjRef): Promise<void>;
1456
+ getReportTemplates(): Promise<IReportTemplate[]>;
1457
+ getReportTemplate(ref: ObjRef): Promise<IReportTemplate>;
1458
+ createReportTemplate(template: IReportTemplateDefinition): Promise<IReportTemplate>;
1459
+ updateReportTemplate(template: IReportTemplate): Promise<IReportTemplate>;
1460
+ deleteReportTemplate(ref: ObjRef): Promise<void>;
1461
+ getReports(): Promise<IReport[]>;
1462
+ getReport(ref: ObjRef): Promise<IReport>;
1463
+ createReport(report: IReportDefinition): Promise<IReport>;
1464
+ updateReport(report: IReport): Promise<IReport>;
1465
+ deleteReport(ref: ObjRef): Promise<void>;
1466
+ }
1467
+
1420
1468
  /**
1421
1469
  * @alpha
1422
1470
  */
@@ -1485,6 +1533,7 @@ export declare type DecoratorFactories = {
1485
1533
  geo?: GeoDecoratorFactory;
1486
1534
  organizationExportTemplates?: OrganizationExportTemplatesDecoratorFactory;
1487
1535
  workspaceExportTemplates?: WorkspaceExportTemplatesDecoratorFactory;
1536
+ workspaceReports?: WorkspaceReportsDecoratorFactory;
1488
1537
  };
1489
1538
 
1490
1539
  /**
@@ -1909,6 +1958,48 @@ export declare class InMemoryPaging<T> implements IPagedResource<T> {
1909
1958
  allSorted(compareFn: (a: T, b: T) => number): Promise<T[]>;
1910
1959
  }
1911
1960
 
1961
+ /**
1962
+ * In-memory implementation of the reports service.
1963
+ *
1964
+ * @remarks
1965
+ * Serves the built-in report page layouts and stores created layouts, templates and reports in memory.
1966
+ * Without a persistence hook the state lives only as long as the instance (dummy backend, tests);
1967
+ * with one (e.g. localStorage) the state is rehydrated on construction and saved after every mutation.
1968
+ *
1969
+ * @alpha
1970
+ */
1971
+ export declare class InMemoryWorkspaceReportsService implements IWorkspaceReportsService {
1972
+ private readonly persistence?;
1973
+ private readonly pageLayouts;
1974
+ private readonly templates;
1975
+ private readonly reports;
1976
+ private sequence;
1977
+ private persistenceDisabled;
1978
+ constructor(persistence?: IWorkspaceReportsPersistence | undefined);
1979
+ private hydrate;
1980
+ private persist;
1981
+ private newRef;
1982
+ private findBuiltInPageLayout;
1983
+ getReportPageLayouts(): Promise<IReportPageLayout[]>;
1984
+ getReportPageLayout(ref: ObjRef): Promise<IReportPageLayout>;
1985
+ createReportPageLayout(layout: IReportPageLayoutDefinition): Promise<IReportPageLayout>;
1986
+ updateReportPageLayout(layout: IReportPageLayout): Promise<IReportPageLayout>;
1987
+ deleteReportPageLayout(ref: ObjRef): Promise<void>;
1988
+ private assertPageLayoutEditable;
1989
+ getReportTemplates(): Promise<IReportTemplate[]>;
1990
+ getReportTemplate(ref: ObjRef): Promise<IReportTemplate>;
1991
+ createReportTemplate(template: IReportTemplateDefinition): Promise<IReportTemplate>;
1992
+ updateReportTemplate(template: IReportTemplate): Promise<IReportTemplate>;
1993
+ deleteReportTemplate(ref: ObjRef): Promise<void>;
1994
+ getReports(): Promise<IReport[]>;
1995
+ getReport(ref: ObjRef): Promise<IReport>;
1996
+ createReport(report: IReportDefinition): Promise<IReport>;
1997
+ updateReport(report: IReport): Promise<IReport>;
1998
+ deleteReport(ref: ObjRef): Promise<void>;
1999
+ private store;
2000
+ private assertExistsAndUnlocked;
2001
+ }
2002
+
1912
2003
  /**
1913
2004
  * @internal
1914
2005
  */
@@ -1972,6 +2063,17 @@ export declare interface IWidgetBaseBuilder<T extends IWidget> extends IBuilder<
1972
2063
  uri(valueOrUpdateCallback: ValueOrUpdateCallback<string>): this;
1973
2064
  }
1974
2065
 
2066
+ /**
2067
+ * Storage hook for {@link InMemoryWorkspaceReportsService}: where the serialized service
2068
+ * state is loaded from on construction and saved to after every mutation.
2069
+ *
2070
+ * @alpha
2071
+ */
2072
+ export declare interface IWorkspaceReportsPersistence {
2073
+ load(): string | null;
2074
+ save(value: string): void;
2075
+ }
2076
+
1975
2077
  /**
1976
2078
  * Specifies workspace settings and current user settings to be adjusted by the decorator.
1977
2079
  *
@@ -2098,6 +2200,15 @@ export declare const newAttributeMetadataObject: (ref: ObjRef, modifications?: B
2098
2200
  */
2099
2201
  export declare const newCatalogAttribute: (modifications?: BuilderModifications<CatalogAttributeBuilder<ICatalogAttribute>>) => ICatalogAttribute;
2100
2202
 
2203
+ /**
2204
+ * Catalog computed attribute factory
2205
+ *
2206
+ * @param modifications - catalog computed attribute builder modifications to perform
2207
+ * @returns created catalog computed attribute
2208
+ * @beta
2209
+ */
2210
+ export declare const newCatalogComputedAttribute: (modifications: BuilderModifications<CatalogComputedAttributeBuilder<ICatalogComputedAttribute>>) => ICatalogComputedAttribute;
2211
+
2101
2212
  /**
2102
2213
  * Catalog date attribute factory
2103
2214
  *
@@ -2569,6 +2680,11 @@ export declare type WorkspaceCatalogWrapper = (catalog: IWorkspaceCatalog) => IW
2569
2680
  */
2570
2681
  export declare type WorkspaceExportTemplatesDecoratorFactory = (exportTemplates: IWorkspaceExportTemplatesService, workspace: string) => IWorkspaceExportTemplatesService;
2571
2682
 
2683
+ /**
2684
+ * @alpha
2685
+ */
2686
+ export declare type WorkspaceReportsDecoratorFactory = (reports: IWorkspaceReportsService, workspace: string) => IWorkspaceReportsService;
2687
+
2572
2688
  /**
2573
2689
  * @alpha
2574
2690
  */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@gooddata/sdk-backend-base",
3
- "version": "11.54.0-alpha.5",
3
+ "version": "11.54.0-alpha.7",
4
4
  "description": "GoodData.UI SDK - Base for backend implementations",
5
5
  "license": "MIT",
6
6
  "author": "GoodData",
@@ -29,15 +29,15 @@
29
29
  "ts-invariant": "0.10.3",
30
30
  "tslib": "2.8.1",
31
31
  "uuid": "11.1.1",
32
- "@gooddata/sdk-backend-spi": "11.54.0-alpha.5",
33
- "@gooddata/sdk-model": "11.54.0-alpha.5",
34
- "@gooddata/util": "11.54.0-alpha.5"
32
+ "@gooddata/sdk-model": "11.54.0-alpha.7",
33
+ "@gooddata/sdk-backend-spi": "11.54.0-alpha.7",
34
+ "@gooddata/util": "11.54.0-alpha.7"
35
35
  },
36
36
  "devDependencies": {
37
- "@microsoft/api-documenter": "^7.17.0",
37
+ "@microsoft/api-documenter": "7.30.10",
38
38
  "@microsoft/api-extractor": "^7.55.2",
39
39
  "@types/lodash-es": "^4.17.12",
40
- "@types/spark-md5": "^3.0.1",
40
+ "@types/spark-md5": "3.0.5",
41
41
  "@typescript-eslint/eslint-plugin": "8.58.0",
42
42
  "@typescript-eslint/parser": "8.58.0",
43
43
  "@typescript/native-preview": "7.0.0-dev.20260202.1",
@@ -56,9 +56,9 @@
56
56
  "oxlint-tsgolint": "0.15.0",
57
57
  "typescript": "5.9.3",
58
58
  "vitest": "4.1.8",
59
- "@gooddata/eslint-config": "11.54.0-alpha.5",
60
- "@gooddata/oxlint-config": "11.54.0-alpha.5",
61
- "@gooddata/reference-workspace": "11.54.0-alpha.5"
59
+ "@gooddata/eslint-config": "11.54.0-alpha.7",
60
+ "@gooddata/oxlint-config": "11.54.0-alpha.7",
61
+ "@gooddata/reference-workspace": "11.54.0-alpha.7"
62
62
  },
63
63
  "scripts": {
64
64
  "_phase:build": "npm run build",