mirror of
https://github.com/apache/superset.git
synced 2026-04-21 00:54:44 +00:00
* Adding full Annotation Framework * Viz types * Re organizing native annotations * liniting * Bug fix * Handle no data * Cleanup * Refactor slice form_data to data
30 lines
868 B
JavaScript
30 lines
868 B
JavaScript
import { connect } from 'react-redux';
|
|
import { bindActionCreators } from 'redux';
|
|
|
|
import * as Actions from './chartAction';
|
|
import Chart from './Chart';
|
|
|
|
function mapStateToProps({ charts }, ownProps) {
|
|
const chart = charts[ownProps.chartKey];
|
|
return {
|
|
annotationData: chart.annotationData,
|
|
chartAlert: chart.chartAlert,
|
|
chartStatus: chart.chartStatus,
|
|
chartUpdateEndTime: chart.chartUpdateEndTime,
|
|
chartUpdateStartTime: chart.chartUpdateStartTime,
|
|
latestQueryFormData: chart.latestQueryFormData,
|
|
lastRendered: chart.lastRendered,
|
|
queryResponse: chart.queryResponse,
|
|
queryRequest: chart.queryRequest,
|
|
triggerQuery: chart.triggerQuery,
|
|
};
|
|
}
|
|
|
|
function mapDispatchToProps(dispatch) {
|
|
return {
|
|
actions: bindActionCreators(Actions, dispatch),
|
|
};
|
|
}
|
|
|
|
export default connect(mapStateToProps, mapDispatchToProps)(Chart);
|