Skip to content

Commit bb8fe49

Browse files
committed
fix: pass snapshot request data to snapshot create
1 parent 7540f66 commit bb8fe49

File tree

1 file changed

+13
-1
lines changed

1 file changed

+13
-1
lines changed

src/components/dataset/data/sidebar/panels/ShareSnapshot.jsx

+13-1
Original file line numberDiff line numberDiff line change
@@ -107,17 +107,26 @@ export class ShareSnapshot extends React.PureComponent {
107107
onDismiss: PropTypes.func,
108108
readers: PropTypes.arrayOf(PropTypes.string),
109109
setIsSharing: PropTypes.func,
110+
snapshotRequest: PropTypes.object,
111+
dataset: PropTypes.object,
112+
filterData: PropTypes.object,
110113
};
111114

112115
setAuthDomain = (domain) => {
113116
this.setState({ authDomain: domain });
114117
};
115118

116119
saveSnapshot = () => {
117-
const { dispatch } = this.props;
120+
const { dispatch, snapshotRequest, dataset, filterData } = this.props;
118121
const { authDomain } = this.state;
119122
dispatch(
120123
snapshotCreateDetails({
124+
name: snapshotRequest.name,
125+
description: snapshotRequest.description,
126+
mode: snapshotRequest.mode,
127+
assetName: snapshotRequest.assetName,
128+
dataset,
129+
filterData,
121130
authDomain,
122131
}),
123132
);
@@ -172,6 +181,9 @@ export class ShareSnapshot extends React.PureComponent {
172181
function mapStateToProps(state) {
173182
return {
174183
readers: state.snapshots.snapshotRequest.readers,
184+
snapshotRequest: state.snapshots.snapshotRequest,
185+
dataset: state.datasets.dataset,
186+
filterData: state.query.filterData,
175187
};
176188
}
177189

0 commit comments

Comments
 (0)