Skip to content

Commit

Permalink
fix: while exporting CSV , only the entries on first page are getting…
Browse files Browse the repository at this point in the history
… downloaded even when user is on other pages #17861
  • Loading branch information
LahmerIlyas committed Jun 1, 2022
1 parent 1530c34 commit bbbf1cc
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -299,6 +299,7 @@ export default class Chart extends React.Component {
resultType: 'full',
resultFormat: 'csv',
force: true,
ownState: this.props.ownState,
});
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,7 @@ export const ExploreChartHeader = ({
slice,
actions,
formData,
ownState,
chart,
user,
canOverwrite,
Expand Down Expand Up @@ -138,6 +139,7 @@ export const ExploreChartHeader = ({
slice,
actions.redirectSQLLab,
openPropertiesModal,
ownState,
);

const oldSliceName = slice?.slice_name;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -522,6 +522,7 @@ function ExploreViewContainer(props) {
table_name={props.table_name}
formData={props.form_data}
chart={props.chart}
ownState={props.ownState}
user={props.user}
reports={props.reports}
onSaveChart={toggleModal}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,7 @@ export const useExploreAdditionalActionsMenu = (
slice,
onOpenInEditor,
onOpenPropertiesModal,
ownState,
) => {
const theme = useTheme();
const { addDangerToast, addSuccessToast } = useToasts();
Expand Down Expand Up @@ -132,6 +133,7 @@ export const useExploreAdditionalActionsMenu = (
canDownloadCSV
? exportChart({
formData: latestQueryFormData,
ownState,
resultType: 'full',
resultFormat: 'csv',
})
Expand Down

0 comments on commit bbbf1cc

Please sign in to comment.