PublicDashboards: use share type (#63059)

This commit is contained in:
Ezequiel Victorero
2023-02-09 15:44:09 -03:00
committed by GitHub
parent 0018c8e9c1
commit c19f156a96
8 changed files with 130 additions and 29 deletions
@@ -232,10 +232,11 @@ func (d *PublicDashboardStoreImpl) Update(ctx context.Context, cmd SavePublicDas
return err
}
sqlResult, err := sess.Exec("UPDATE dashboard_public SET is_enabled = ?, annotations_enabled = ?, time_selection_enabled = ?, time_settings = ?, updated_by = ?, updated_at = ? WHERE uid = ?",
sqlResult, err := sess.Exec("UPDATE dashboard_public SET is_enabled = ?, annotations_enabled = ?, time_selection_enabled = ?, share = ?, time_settings = ?, updated_by = ?, updated_at = ? WHERE uid = ?",
cmd.PublicDashboard.IsEnabled,
cmd.PublicDashboard.AnnotationsEnabled,
cmd.PublicDashboard.TimeSelectionEnabled,
cmd.PublicDashboard.Share,
string(timeSettingsJSON),
cmd.PublicDashboard.UpdatedBy,
cmd.PublicDashboard.UpdatedAt.UTC().Format("2006-01-02 15:04:05"),