replace randomUUID with something that is available in real live
This commit is contained in:
@@ -111,7 +111,7 @@ export class DashboardComponent implements OnInit {
|
||||
data: {text:""},
|
||||
width: '600px'
|
||||
}).afterClosed().subscribe((text: string) => {
|
||||
const widget = new TextWidget(crypto.randomUUID(),'MEDIUM', text);
|
||||
const widget = new TextWidget((<any>window).randomId(),'MEDIUM', text);
|
||||
this.dashboard!.texts.push(widget);
|
||||
this.dashboard!.arrangement[0].push(widget.id);
|
||||
});
|
||||
@@ -124,7 +124,7 @@ export class DashboardComponent implements OnInit {
|
||||
height: 'calc(100% - 1em)'
|
||||
}).afterClosed().subscribe((config: PlotConfig | "") => {
|
||||
if (config != "" && config.query.length > 0) {
|
||||
const widget = new PlotWidget(crypto.randomUUID(), 'MEDIUM', config);
|
||||
const widget = new PlotWidget((<any>window).randomId(), 'MEDIUM', config);
|
||||
this.dashboard!.plots.push(widget);
|
||||
this.dashboard!.arrangement[0].push(widget.id);
|
||||
this.plotWidgetRenderData.push(new PlotWidgetRenderData(widget));
|
||||
|
||||
Reference in New Issue
Block a user