@lightdash/common 0.1377.3 → 0.1378.0

Sign up to get free protection for your applications and to get access to all the features.
package/dist/index.d.ts CHANGED
@@ -28,7 +28,7 @@ import { type ProjectMemberRole } from './types/projectMemberRole';
28
28
  import { DbtProjectType, ProjectType, type CreateWarehouseCredentials, type DbtProjectConfig, type Project, type WarehouseCredentials } from './types/projects';
29
29
  import { type MostPopularAndRecentlyUpdated } from './types/resourceViewItem';
30
30
  import { type ResultRow } from './types/results';
31
- import { type ApiJobScheduledResponse, type ApiJobStatusResponse, type ApiSchedulerJobIdResponse, type SchedulerAndTargets, type SchedulerJobStatus, type SchedulerWithLogs } from './types/scheduler';
31
+ import { type ApiJobScheduledResponse, type ApiJobStatusResponse, type SchedulerAndTargets, type SchedulerJobStatus, type SchedulerWithLogs } from './types/scheduler';
32
32
  import { type ApiSlackChannelsResponse } from './types/slack';
33
33
  import { type Space } from './types/space';
34
34
  import { type ApiSshKeyPairResponse } from './types/SshKeyPair';
@@ -362,6 +362,10 @@ export type CreateInviteLink = Pick<InviteLink, 'expiresAt' | 'email'> & {
362
362
  email: string;
363
363
  role?: OrganizationMemberRole;
364
364
  };
365
+ export type ApiCreateProjectResults = {
366
+ project: Project;
367
+ hasContentCopy: boolean;
368
+ };
365
369
  export type ProjectSavedChartStatus = boolean;
366
370
  export type ApiFlashResults = Record<string, string[]>;
367
371
  export type ApiAiDashboardSummaryResponse = {
@@ -372,7 +376,7 @@ export type ApiAiGetDashboardSummaryResponse = {
372
376
  status: 'ok';
373
377
  results: DashboardSummary;
374
378
  };
375
- type ApiResults = ApiQueryResults | ApiSqlQueryResults | ApiCompiledQueryResults | ApiExploresResults | ApiExploreResults | ApiStatusResults | ApiRefreshResults | ApiHealthResults | Organization | LightdashUser | LoginOptions | SavedChart | SavedChart[] | Space[] | InviteLink | OrganizationProject[] | Project | WarehouseCredentials | OrganizationMemberProfile[] | ProjectCatalog | TablesConfiguration | Dashboard | DashboardBasicDetails[] | OnboardingStatus | Dashboard[] | DeleteOpenIdentity | ApiFlashResults | Record<OpenIdIdentitySummary['issuerType'], OpenIdIdentitySummary[]> | FilterableField[] | DashboardAvailableFilters | ProjectSavedChartStatus | null | Array<unknown> | ApiJobStartedResults | ApiCreateUserTokenResults | CreatePersonalAccessToken | PersonalAccessToken | ProjectMemberProfile[] | ProjectGroupAccess | SearchResults | Space | ShareUrl | SlackSettings | ApiSlackChannelsResponse['results'] | UserActivity | SchedulerAndTargets | SchedulerAndTargets[] | FieldValueSearchResult | ApiDownloadCsv | AllowedEmailDomains | UpdateAllowedEmailDomains | UserAllowedOrganization[] | EmailStatusExpiring | ApiScheduledDownloadCsv | PinnedItems | ViewStatistics | SchedulerWithLogs | ValidationResponse[] | ChartHistory | ChartVersion | Array<GitRepo> | PullRequestCreated | GitIntegrationConfiguration | UserWarehouseCredentials | ApiJobStatusResponse['results'] | ApiJobScheduledResponse['results'] | ApiSshKeyPairResponse['results'] | MostPopularAndRecentlyUpdated | ApiCalculateTotalResponse['results'] | Record<string, DbtExposure> | ApiCreateComment['results'] | ApiGetComments['results'] | ApiDeleteComment | ApiSuccessEmpty | ApiAiDashboardSummaryResponse['results'] | ApiAiGetDashboardSummaryResponse['results'] | ApiCatalogMetadataResults | ApiCatalogAnalyticsResults | ApiPromotionChangesResponse['results'] | ApiWarehouseTableFields['results'] | ApiTogglePinnedItem['results'] | ApiOrganizationMemberProfiles['results'] | ApiSqlChart['results'] | ApiCreateSqlChart['results'] | ApiUpdateSqlChart['results'] | ApiContentResponse['results'] | ApiChartContentResponse['results'] | ApiSqlRunnerJobStatusResponse['results'] | ApiSemanticLayerClientInfo['results'] | ApiSemanticViewerChartCreate['results'] | ApiSemanticViewerChartGet['results'] | ApiSemanticViewerChartUpdate['results'] | ApiCreateVirtualView['results'] | ApiGithubDbtWritePreview['results'] | ApiMetricsCatalog['results'] | ApiGroupListResponse['results'] | ApiCreateTagResponse['results'] | ApiSchedulerJobIdResponse['results'];
379
+ type ApiResults = ApiQueryResults | ApiSqlQueryResults | ApiCompiledQueryResults | ApiExploresResults | ApiExploreResults | ApiStatusResults | ApiRefreshResults | ApiHealthResults | Organization | LightdashUser | LoginOptions | SavedChart | SavedChart[] | Space[] | InviteLink | OrganizationProject[] | Project | WarehouseCredentials | OrganizationMemberProfile[] | ProjectCatalog | TablesConfiguration | Dashboard | DashboardBasicDetails[] | OnboardingStatus | Dashboard[] | DeleteOpenIdentity | ApiFlashResults | Record<OpenIdIdentitySummary['issuerType'], OpenIdIdentitySummary[]> | FilterableField[] | DashboardAvailableFilters | ProjectSavedChartStatus | null | Array<unknown> | ApiJobStartedResults | ApiCreateUserTokenResults | CreatePersonalAccessToken | PersonalAccessToken | ProjectMemberProfile[] | ProjectGroupAccess | SearchResults | Space | ShareUrl | SlackSettings | ApiSlackChannelsResponse['results'] | UserActivity | SchedulerAndTargets | SchedulerAndTargets[] | FieldValueSearchResult | ApiDownloadCsv | AllowedEmailDomains | UpdateAllowedEmailDomains | UserAllowedOrganization[] | EmailStatusExpiring | ApiScheduledDownloadCsv | PinnedItems | ViewStatistics | SchedulerWithLogs | ValidationResponse[] | ChartHistory | ChartVersion | Array<GitRepo> | PullRequestCreated | GitIntegrationConfiguration | UserWarehouseCredentials | ApiJobStatusResponse['results'] | ApiJobScheduledResponse['results'] | ApiSshKeyPairResponse['results'] | MostPopularAndRecentlyUpdated | ApiCalculateTotalResponse['results'] | Record<string, DbtExposure> | ApiCreateComment['results'] | ApiGetComments['results'] | ApiDeleteComment | ApiSuccessEmpty | ApiCreateProjectResults | ApiAiDashboardSummaryResponse['results'] | ApiAiGetDashboardSummaryResponse['results'] | ApiCatalogMetadataResults | ApiCatalogAnalyticsResults | ApiPromotionChangesResponse['results'] | ApiWarehouseTableFields['results'] | ApiTogglePinnedItem['results'] | ApiOrganizationMemberProfiles['results'] | ApiSqlChart['results'] | ApiCreateSqlChart['results'] | ApiUpdateSqlChart['results'] | ApiContentResponse['results'] | ApiChartContentResponse['results'] | ApiSqlRunnerJobStatusResponse['results'] | ApiSemanticLayerClientInfo['results'] | ApiSemanticViewerChartCreate['results'] | ApiSemanticViewerChartGet['results'] | ApiSemanticViewerChartUpdate['results'] | ApiCreateVirtualView['results'] | ApiGithubDbtWritePreview['results'] | ApiMetricsCatalog['results'] | ApiGroupListResponse['results'] | ApiCreateTagResponse['results'];
376
380
  export type ApiResponse<T extends ApiResults = ApiResults> = {
377
381
  status: 'ok';
378
382
  results: T;
@@ -258,7 +258,3 @@ export type PreviewContentMapping = {
258
258
  export type UpdateSchedulerSettings = {
259
259
  schedulerTimezone: string;
260
260
  };
261
- export type CreateProjectResult = {
262
- project: Project;
263
- hasContentCopy: boolean;
264
- };
@@ -1,4 +1,3 @@
1
- import type { CreateProject } from '..';
2
1
  import { type Explore, type ExploreError } from './explore';
3
2
  import { type DashboardFilterRule } from './filter';
4
3
  import { type MetricQuery } from './metricQuery';
@@ -30,7 +29,7 @@ export declare enum SchedulerFormat {
30
29
  GSHEETS = "gsheets"
31
30
  }
32
31
  export type SchedulerLog = {
33
- task: 'handleScheduledDelivery' | 'sendEmailNotification' | 'sendSlackNotification' | 'uploadGsheets' | 'downloadCsv' | 'uploadGsheetFromQuery' | 'createProjectWithoutCompile' | 'compileProject' | 'testAndCompileProject' | 'validateProject' | 'sqlRunner' | 'sqlRunnerPivotQuery' | 'semanticLayer' | 'indexCatalog';
32
+ task: 'handleScheduledDelivery' | 'sendEmailNotification' | 'sendSlackNotification' | 'uploadGsheets' | 'downloadCsv' | 'uploadGsheetFromQuery' | 'compileProject' | 'testAndCompileProject' | 'validateProject' | 'sqlRunner' | 'sqlRunnerPivotQuery' | 'semanticLayer' | 'indexCatalog';
34
33
  schedulerUuid?: string;
35
34
  jobId: string;
36
35
  jobGroup?: string;
@@ -169,12 +168,6 @@ export type ApiTestSchedulerResponse = {
169
168
  jobId: string;
170
169
  };
171
170
  };
172
- export type ApiSchedulerJobIdResponse = {
173
- status: 'ok';
174
- results: {
175
- jobId: string;
176
- };
177
- };
178
171
  export type ScheduledDeliveryPayload = {
179
172
  schedulerUuid: string;
180
173
  } | CreateSchedulerAndTargets;
@@ -251,13 +244,6 @@ export type ApiCsvUrlResponse = {
251
244
  truncated: boolean;
252
245
  };
253
246
  };
254
- export type SchedulerCreateProjectWithoutCompilePayload = {
255
- createdByUserUuid: string;
256
- organizationUuid: string;
257
- requestMethod: string;
258
- isPreview: boolean;
259
- data: CreateProject;
260
- };
261
247
  export type CompileProjectPayload = {
262
248
  createdByUserUuid: string;
263
249
  organizationUuid: string;
@@ -120,10 +120,14 @@ class CartesianChartDataModel {
120
120
  : types_1.VizAggregationOptions.COUNT,
121
121
  },
122
122
  ];
123
+ const sortBy = [
124
+ { reference: x.reference, direction: types_1.SortByDirection.ASC },
125
+ ];
123
126
  return {
124
127
  x,
125
128
  y,
126
129
  groupBy: [],
130
+ sortBy,
127
131
  };
128
132
  }
129
133
  getConfigErrors(fieldConfig) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lightdash/common",
3
- "version": "0.1377.3",
3
+ "version": "0.1378.0",
4
4
  "main": "dist/index.js",
5
5
  "types": "dist/index.d.ts",
6
6
  "files": [