BC-5 fix: general tab of preferences form submitting.

This commit is contained in:
a.bouhuolia
2021-09-04 18:49:01 +02:00
parent d6d6fefd1f
commit 11df54d4ed
25 changed files with 251 additions and 131 deletions

View File

@@ -2,14 +2,25 @@ import React, { useEffect } from 'react';
import DashboardInsider from 'components/Dashboard/DashboardInsider';
import HomepageContent from './HomepageContent';
import withDashboardActions from 'containers/Dashboard/withDashboardActions';
import withSettings from 'containers/Settings/withSettings';
import withCurrentOrganization from '../Organization/withCurrentOrganization';
import { compose } from 'utils';
function DashboardHomepage({ changePageTitle, name }) {
/**
* Dashboard homepage.
*/
function DashboardHomepage({
// #withDashboardActions
changePageTitle,
// #withCurrentOrganization
organization,
}) {
useEffect(() => {
changePageTitle(name);
}, [name, changePageTitle]);
changePageTitle(organization.name);
}, [organization.name, changePageTitle]);
return (
<DashboardInsider name="homepage">
@@ -20,7 +31,5 @@ function DashboardHomepage({ changePageTitle, name }) {
export default compose(
withDashboardActions,
withSettings(({ organizationSettings }) => ({
name: organizationSettings.name,
})),
withCurrentOrganization(({ organization }) => ({ organization })),
)(DashboardHomepage);