feat: bulk transcations delete

This commit is contained in:
Ahmed Bouhuolia
2025-11-03 21:40:24 +02:00
parent 8161439365
commit a0bc9db9a6
107 changed files with 2213 additions and 156 deletions

View File

@@ -12,6 +12,10 @@ const BillLocatedLandedCostDeleteAlert = React.lazy(
() => import('@/containers/Alerts/Bills/BillLocatedLandedCostDeleteAlert'),
);
const BillBulkDeleteAlert = React.lazy(
() => import('@/containers/Alerts/Bills/BillBulkDeleteAlert'),
);
export default [
{ name: 'bill-delete', component: BillDeleteAlert },
{ name: 'bill-open', component: BillOpenAlert },
@@ -19,4 +23,5 @@ export default [
name: 'bill-located-cost-delete',
component: BillLocatedLandedCostDeleteAlert,
},
{ name: 'bills-bulk-delete', component: BillBulkDeleteAlert },
];

View File

@@ -106,7 +106,7 @@ export function StatusAccessor(bill) {
<div className={'status-accessor'}>
<Choose>
<Choose.When condition={bill.is_fully_paid && bill.is_open}>
<Tag round intent={Intent.SUCCESS}>
<Tag round minimal intent={Intent.SUCCESS}>
<T id={'paid'} />
</Tag>
</Choose.When>
@@ -114,18 +114,18 @@ export function StatusAccessor(bill) {
<Choose.When condition={bill.is_open}>
<Choose>
<Choose.When condition={bill.is_overdue}>
<Tag round intent={Intent.DANGER}>
<Tag round minimal intent={Intent.DANGER}>
{intl.get('overdue_by', { overdue: bill.overdue_days })}
</Tag>
</Choose.When>
<Choose.Otherwise>
<Tag round intent={Intent.WARNING}>
<Tag round minimal intent={Intent.WARNING}>
{intl.get('due_in', { due: bill.remaining_days })}
</Tag>
</Choose.Otherwise>
</Choose>
<If condition={bill.is_partially_paid}>
<Tag round intent={Intent.PRIMARY}>
<Tag round minimal intent={Intent.PRIMARY}>
{intl.get('day_partially_paid', {
due: formattedAmount(bill.due_amount, bill.currency_code),
})}
@@ -134,7 +134,7 @@ export function StatusAccessor(bill) {
</Choose.When>
<Choose.Otherwise>
<Tag round>
<Tag round minimal>
<T id={'draft'} />
</Tag>
</Choose.Otherwise>

View File

@@ -81,19 +81,19 @@ export function StatusAccessor(creditNote) {
<div>
<Choose>
<Choose.When condition={creditNote.is_open}>
<Tag intent={Intent.WARNING} round>
<Tag intent={Intent.WARNING} round minimal>
<T id={'open'} />
</Tag>
</Choose.When>
<Choose.When condition={creditNote.is_closed}>
<Tag intent={Intent.SUCCESS} round>
<Tag intent={Intent.SUCCESS} round minimal>
<T id={'closed'} />
</Tag>
</Choose.When>
<Choose.When condition={creditNote.is_draft}>
<Tag round>
<Tag round minimal>
<T id={'draft'} />
</Tag>
</Choose.When>

View File

@@ -23,6 +23,11 @@ const ReconcileVendorCreditDeleteAlert = React.lazy(
),
);
const VendorCreditBulkDeleteAlert = React.lazy(
() =>
import('@/containers/Alerts/VendorCeditNotes/VendorCreditBulkDeleteAlert'),
);
/**
* Vendor Credit notes alerts.
*/
@@ -43,4 +48,8 @@ export default [
name: 'reconcile-vendor-delete',
component: ReconcileVendorCreditDeleteAlert,
},
{
name: 'vendor-credits-bulk-delete',
component: VendorCreditBulkDeleteAlert,
},
];