mirror of
https://github.com/bigcapitalhq/bigcapital.git
synced 2026-02-16 21:00:31 +00:00
WIP Version 0.0.1
This commit is contained in:
23
client/src/containers/Views/ViewForm.container.js
Normal file
23
client/src/containers/Views/ViewForm.container.js
Normal file
@@ -0,0 +1,23 @@
|
||||
import {connect} from 'react-redux';
|
||||
import {compose} from 'utils';
|
||||
import DashboardConnect from 'connectors/Dashboard.connector';
|
||||
import withResourceDetail from 'containers/Resources/withResourceDetails';
|
||||
import withViewsActions from 'containers/Views/withViewsActions';
|
||||
import withViewsDetails from 'containers/Views/withViewDetails';
|
||||
|
||||
const mapStateToProps = (state, ownProps) => {
|
||||
return {
|
||||
resourceName: ownProps.viewId ?
|
||||
ownProps.viewMeta.resource?.name : ownProps.resourceName,
|
||||
};
|
||||
};
|
||||
|
||||
const viewFormConnect = connect(mapStateToProps);
|
||||
|
||||
export default compose(
|
||||
DashboardConnect,
|
||||
withViewsActions,
|
||||
withViewsDetails,
|
||||
viewFormConnect,
|
||||
withResourceDetail,
|
||||
);
|
||||
Reference in New Issue
Block a user