mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
Chore: Add type info for grafana boot data (#45322)
Co-authored-by: Levente Balogh <balogh.levente.hu@gmail.com>
This commit is contained in:
@@ -53,7 +53,7 @@ describe('ShareEmbed', () => {
|
||||
user: {
|
||||
orgId: 1,
|
||||
},
|
||||
};
|
||||
} as any;
|
||||
});
|
||||
|
||||
afterAll(() => {
|
||||
|
||||
@@ -110,7 +110,7 @@ describe('ShareModal', () => {
|
||||
user: {
|
||||
orgId: 1,
|
||||
},
|
||||
};
|
||||
} as any;
|
||||
ctx.mount({
|
||||
panel: new PanelModel({ id: 22, options: {}, fieldConfig: { defaults: {}, overrides: [] } }),
|
||||
});
|
||||
@@ -202,7 +202,7 @@ describe('when default_home_dashboard_path is set in the grafana config', () =>
|
||||
user: {
|
||||
orgId: 1,
|
||||
},
|
||||
};
|
||||
} as any;
|
||||
});
|
||||
|
||||
afterAll(() => {
|
||||
|
||||
@@ -36,7 +36,7 @@ describe('buildParams', () => {
|
||||
to: 2000,
|
||||
raw: { from: 'now-6h', to: 'now' },
|
||||
} as unknown as TimeRange;
|
||||
const orgId = '2';
|
||||
const orgId = 2;
|
||||
const result = buildParams({ useCurrentTimeRange, selectedTheme, panel, search, range, orgId });
|
||||
|
||||
expect(result.toString()).toEqual(expected);
|
||||
|
||||
@@ -9,7 +9,7 @@ export interface BuildParamsArgs {
|
||||
panel?: PanelModel;
|
||||
search?: string;
|
||||
range?: TimeRange;
|
||||
orgId?: string;
|
||||
orgId?: number;
|
||||
}
|
||||
|
||||
export function buildParams({
|
||||
@@ -24,7 +24,7 @@ export function buildParams({
|
||||
|
||||
searchParams.set('from', String(range.from.valueOf()));
|
||||
searchParams.set('to', String(range.to.valueOf()));
|
||||
searchParams.set('orgId', orgId);
|
||||
searchParams.set('orgId', String(orgId));
|
||||
|
||||
if (!useCurrentTimeRange) {
|
||||
searchParams.delete('from');
|
||||
|
||||
Reference in New Issue
Block a user