Skip to content

Commit 2462f68

Browse files
Last Updated Timestamp for visbuilder saved object is getting Generated (#2628)
Signed-off-by: AbhishekReddy1127 <nallamsa@amazon.com> Signed-off-by: AbhishekReddy1127 <nallamsa@amazon.com> Co-authored-by: Ashwin P Chandran <ashwinpc@amazon.com> (cherry picked from commit a16fe40) Signed-off-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com> # Conflicts: # CHANGELOG.md
1 parent 7ab0e60 commit 2462f68

File tree

4 files changed

+5
-1
lines changed

4 files changed

+5
-1
lines changed

src/plugins/saved_objects/public/types.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -110,6 +110,7 @@ export interface SavedObjectConfig {
110110
path?: string;
111111
searchSource?: ISearchSource | boolean;
112112
type?: string;
113+
updated_at?: string;
113114
}
114115

115116
export type OpenSearchResponse = Record<string, any>;

src/plugins/visualizations/public/vis_types/vis_type_alias_registry.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,7 @@ export interface VisualizationsAppExtension {
5353
id: string;
5454
type: string;
5555
attributes: SavedObjectAttributes;
56+
updated_at?: string;
5657
}) => VisualizationListItem;
5758
}
5859

src/plugins/wizard/common/wizard_saved_object_attributes.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ export interface WizardSavedObjectAttributes extends SavedObjectAttributes {
1111
title: string;
1212
description?: string;
1313
visualizationState?: string;
14+
updated_at?: string;
1415
styleState?: string;
1516
version: number;
1617
searchSourceFields?: {

src/plugins/wizard/public/plugin.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,7 @@ export class WizardPlugin
120120
appExtensions: {
121121
visualizations: {
122122
docTypes: [PLUGIN_ID],
123-
toListItem: ({ id, attributes }) => ({
123+
toListItem: ({ id, attributes, updated_at: updatedAt }) => ({
124124
description: attributes?.description,
125125
editApp: PLUGIN_ID,
126126
editUrl: `${EDIT_PATH}/${encodeURIComponent(id)}`,
@@ -130,6 +130,7 @@ export class WizardPlugin
130130
stage: 'experimental',
131131
title: attributes?.title,
132132
typeTitle: PLUGIN_NAME,
133+
updated_at: updatedAt,
133134
}),
134135
},
135136
},

0 commit comments

Comments
 (0)