mirror of
https://github.com/bigcapitalhq/bigcapital.git
synced 2026-02-16 04:40:32 +00:00
BC-5 fix: general tab of preferences form submitting.
This commit is contained in:
@@ -19,7 +19,6 @@ import { Icon, Hint, If } from 'components';
|
||||
import withUniversalSearchActions from 'containers/UniversalSearch/withUniversalSearchActions';
|
||||
import withDashboardActions from 'containers/Dashboard/withDashboardActions';
|
||||
import withDashboard from 'containers/Dashboard/withDashboard';
|
||||
import withSettings from 'containers/Settings/withSettings';
|
||||
|
||||
import QuickNewDropdown from 'containers/QuickNewDropdown/QuickNewDropdown';
|
||||
import { compose } from 'utils';
|
||||
@@ -76,9 +75,6 @@ function DashboardTopbar({
|
||||
// #withDashboard
|
||||
sidebarExpended,
|
||||
|
||||
// #withSettings
|
||||
organizationName,
|
||||
|
||||
// #withGlobalSearch
|
||||
openGlobalSearch,
|
||||
|
||||
@@ -190,9 +186,6 @@ export default compose(
|
||||
sidebarExpended,
|
||||
pageHint,
|
||||
})),
|
||||
withSettings(({ organizationSettings }) => ({
|
||||
organizationName: organizationSettings.name,
|
||||
})),
|
||||
withDashboardActions,
|
||||
withSubscriptions(
|
||||
({ isSubscriptionActive, isSubscriptionInactive }) => ({
|
||||
|
||||
@@ -2,8 +2,8 @@ import React from 'react';
|
||||
import { Button, Popover, Menu, Position } from '@blueprintjs/core';
|
||||
import Icon from 'components/Icon';
|
||||
import { useAuthUser } from 'hooks/state';
|
||||
import withSettings from 'containers/Settings/withSettings';
|
||||
import { compose, firstLettersArgs } from 'utils';
|
||||
import withCurrentOrganization from '../../containers/Organization/withCurrentOrganization';
|
||||
|
||||
// Popover modifiers.
|
||||
const POPOVER_MODIFIERS = {
|
||||
@@ -14,8 +14,8 @@ const POPOVER_MODIFIERS = {
|
||||
* Sideabr head.
|
||||
*/
|
||||
function SidebarHead({
|
||||
// #withSettings
|
||||
organizationName,
|
||||
// #withCurrentOrganization
|
||||
organization,
|
||||
}) {
|
||||
const user = useAuthUser();
|
||||
|
||||
@@ -29,9 +29,9 @@ function SidebarHead({
|
||||
<Menu className={'menu--dashboard-organization'}>
|
||||
<div class="org-item">
|
||||
<div class="org-item__logo">
|
||||
{firstLettersArgs(...organizationName.split(' '))}{' '}
|
||||
{firstLettersArgs(...(organization.name || '').split(' '))}{' '}
|
||||
</div>
|
||||
<div class="org-item__name">{organizationName}</div>
|
||||
<div class="org-item__name">{organization.name}</div>
|
||||
</div>
|
||||
</Menu>
|
||||
}
|
||||
@@ -42,7 +42,7 @@ function SidebarHead({
|
||||
className="title"
|
||||
rightIcon={<Icon icon={'caret-down-16'} size={16} />}
|
||||
>
|
||||
{organizationName}
|
||||
{organization.name}
|
||||
</Button>
|
||||
</Popover>
|
||||
<span class="subtitle">{user.full_name}</span>
|
||||
@@ -61,7 +61,5 @@ function SidebarHead({
|
||||
}
|
||||
|
||||
export default compose(
|
||||
withSettings(({ organizationSettings }) => ({
|
||||
organizationName: organizationSettings.name,
|
||||
})),
|
||||
withCurrentOrganization(({ organization }) => ({ organization })),
|
||||
)(SidebarHead);
|
||||
|
||||
Reference in New Issue
Block a user