mirror of
https://github.com/bigcapitalhq/bigcapital.git
synced 2026-02-17 21:30:31 +00:00
fix(webapp): code cleanup
This commit is contained in:
@@ -7,7 +7,6 @@ import { useDeleteTaxRate } from '@/hooks/query/taxRates';
|
||||
|
||||
import withAlertStoreConnect from '@/containers/Alert/withAlertStoreConnect';
|
||||
import withAlertActions from '@/containers/Alert/withAlertActions';
|
||||
import withItemsActions from '@/containers/Items/withItemsActions';
|
||||
import withDrawerActions from '@/containers/Drawer/withDrawerActions';
|
||||
|
||||
import { compose } from '@/utils';
|
||||
@@ -51,7 +50,10 @@ function TaxRateDeleteAlert({
|
||||
data: { errors },
|
||||
},
|
||||
}) => {
|
||||
// handleDeleteErrors(errors);
|
||||
AppToaster.show({
|
||||
message: 'Something went wrong.',
|
||||
intent: Intent.DANGER,
|
||||
});
|
||||
},
|
||||
)
|
||||
.finally(() => {
|
||||
@@ -86,6 +88,5 @@ function TaxRateDeleteAlert({
|
||||
export default compose(
|
||||
withAlertStoreConnect(),
|
||||
withAlertActions,
|
||||
withItemsActions,
|
||||
withDrawerActions,
|
||||
)(TaxRateDeleteAlert);
|
||||
|
||||
@@ -4,8 +4,6 @@ import React from 'react';
|
||||
const TaxRateDeleteAlert = React.lazy(() => import('./TaxRateDeleteAlert'));
|
||||
|
||||
/**
|
||||
* Project alerts.
|
||||
* Tax rates alerts.
|
||||
*/
|
||||
export default [
|
||||
{ name: 'tax-rate-delete', component: TaxRateDeleteAlert },
|
||||
];
|
||||
export default [{ name: 'tax-rate-delete', component: TaxRateDeleteAlert }];
|
||||
|
||||
@@ -29,7 +29,7 @@ function TaxRatesLandingProvider({ tableState, ...props }) {
|
||||
};
|
||||
|
||||
return (
|
||||
<DashboardInsider name={'cashflow-accounts'}>
|
||||
<DashboardInsider name={'tax-rate-form'}>
|
||||
<TaxRatesLandingContext.Provider value={provider} {...props} />
|
||||
</DashboardInsider>
|
||||
);
|
||||
|
||||
@@ -9,12 +9,8 @@ const TaxRateFormDialogContent = lazy(
|
||||
() => import('./TaxRateFormDialogContent'),
|
||||
);
|
||||
|
||||
const TaxRateDialog = styled(Dialog)`
|
||||
max-width: 450px;
|
||||
`;
|
||||
|
||||
/**
|
||||
* Account form dialog.
|
||||
* Tax rate form dialog.
|
||||
*/
|
||||
function TaxRateFormDialog({
|
||||
dialogName,
|
||||
@@ -39,4 +35,8 @@ function TaxRateFormDialog({
|
||||
);
|
||||
}
|
||||
|
||||
const TaxRateDialog = styled(Dialog)`
|
||||
max-width: 450px;
|
||||
`;
|
||||
|
||||
export default compose(withDialogRedux())(TaxRateFormDialog);
|
||||
|
||||
@@ -9,7 +9,7 @@ interface TaxRateFormDialogContentProps {
|
||||
}
|
||||
|
||||
/**
|
||||
* Account dialog content.
|
||||
* Tax rate form dialog content.
|
||||
*/
|
||||
export default function TaxRateFormDialogContent({
|
||||
dialogName,
|
||||
|
||||
Reference in New Issue
Block a user