mirror of
https://github.com/bigcapitalhq/bigcapital.git
synced 2026-02-16 12:50:38 +00:00
BIG-202 Remove the allocate actions bar.
This commit is contained in:
@@ -69,6 +69,11 @@ function BillDetailActionsBar({
|
||||
openDialog('quick-payment-made', { billId });
|
||||
};
|
||||
|
||||
// Handle allocate landed cost button click.
|
||||
const handleAllocateCostClick = () => {
|
||||
openDialog('allocate-landed-cost', { billId });
|
||||
};
|
||||
|
||||
return (
|
||||
<DrawerActionsBar>
|
||||
<NavbarGroup>
|
||||
@@ -106,6 +111,7 @@ function BillDetailActionsBar({
|
||||
<BillMenuItem
|
||||
payload={{
|
||||
onConvert: handleConvertToVendorCredit,
|
||||
onAllocateLandedCost: handleAllocateCostClick,
|
||||
}}
|
||||
/>
|
||||
</Can>
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
import React from 'react';
|
||||
import { DataTable, Card, FormattedMessage as T } from 'components';
|
||||
import { Button, Classes, NavbarGroup } from '@blueprintjs/core';
|
||||
|
||||
import { useLocatedLandedCostColumns, ActionsMenu } from './components';
|
||||
import { useBillDrawerContext } from './BillDrawerProvider';
|
||||
@@ -13,8 +12,7 @@ import { TableStyle } from '../../../common';
|
||||
import TableSkeletonRows from 'components/Datatable/TableSkeletonRows';
|
||||
|
||||
import { compose } from 'utils';
|
||||
import DashboardActionsBar from 'components/Dashboard/DashboardActionsBar';
|
||||
import Icon from 'components/Icon';
|
||||
|
||||
|
||||
/**
|
||||
* Located landed cost table.
|
||||
@@ -32,10 +30,7 @@ function LocatedLandedCostTable({
|
||||
const columns = useLocatedLandedCostColumns();
|
||||
const { transactions, billId } = useBillDrawerContext();
|
||||
|
||||
// Handle allocate landed cost button click.
|
||||
const handleAllocateCostClick = () => {
|
||||
openDialog('allocate-landed-cost', { billId });
|
||||
};
|
||||
|
||||
|
||||
// Handle the transaction delete action.
|
||||
const handleDeleteTransaction = ({ id }) => {
|
||||
@@ -60,17 +55,6 @@ function LocatedLandedCostTable({
|
||||
|
||||
return (
|
||||
<div>
|
||||
<DashboardActionsBar>
|
||||
<NavbarGroup>
|
||||
<Button
|
||||
className={Classes.MINIMAL}
|
||||
icon={<Icon icon="receipt-24" />}
|
||||
text={<T id={'allocate_landed_coast'} />}
|
||||
onClick={handleAllocateCostClick}
|
||||
/>
|
||||
</NavbarGroup>
|
||||
</DashboardActionsBar>
|
||||
|
||||
<Card>
|
||||
<DataTable
|
||||
columns={columns}
|
||||
|
||||
@@ -101,7 +101,9 @@ export function BillDetailsStatus({ bill }) {
|
||||
);
|
||||
}
|
||||
|
||||
export const BillMenuItem = ({ payload: { onConvert } }) => {
|
||||
export const BillMenuItem = ({
|
||||
payload: { onConvert, onAllocateLandedCost },
|
||||
}) => {
|
||||
return (
|
||||
<Popover
|
||||
minimal={true}
|
||||
@@ -112,6 +114,10 @@ export const BillMenuItem = ({ payload: { onConvert } }) => {
|
||||
}}
|
||||
content={
|
||||
<Menu>
|
||||
<MenuItem
|
||||
onClick={onAllocateLandedCost}
|
||||
text={<T id={'bill.allocate_landed_coast'} />}
|
||||
/>
|
||||
<MenuItem
|
||||
onClick={onConvert}
|
||||
text={<T id={'bill.convert_to_credit_note'} />}
|
||||
|
||||
@@ -1682,6 +1682,7 @@
|
||||
"inventory_adjustment.column.product":"المنتج",
|
||||
"invoice.convert_to_credit_note":"تحويل إلى إشعار دائن",
|
||||
"bill.convert_to_credit_note":"تحويل إلى إشعار مدين",
|
||||
"bill.allocate_landed_coast":"تحميل تكلفة اضافية",
|
||||
"overdue":"متأخرّة",
|
||||
"invite_user.label.role_name":"دور المستخدم",
|
||||
"permissions.column.view": "عرض",
|
||||
|
||||
@@ -1670,6 +1670,7 @@
|
||||
"inventory_adjustment.column.product":"Product",
|
||||
"invoice.convert_to_credit_note":"Convert to Credit Note",
|
||||
"bill.convert_to_credit_note":"Convert to Vendor Credit",
|
||||
"bill.allocate_landed_coast":"Allocate Landed Cost",
|
||||
"overdue":"Overdue",
|
||||
"permissions.column.view": "View",
|
||||
"permissions.column.full_access": "Full Access",
|
||||
|
||||
Reference in New Issue
Block a user