feat: setting up the date format in the whole system dates

This commit is contained in:
Ahmed Bouhuolia
2024-06-12 19:43:42 +02:00
parent 265ea9ca48
commit 3a0a0db8a7
24 changed files with 62 additions and 52 deletions

View File

@@ -161,8 +161,7 @@ export function useBillsTableColumns() {
{
id: 'bill_date',
Header: intl.get('bill_date'),
accessor: 'bill_date',
Cell: FormatDateCell,
accessor: 'formatted_bill_date',
width: 110,
className: 'bill_date',
clickable: true,

View File

@@ -5,14 +5,7 @@ import clsx from 'classnames';
import { Intent, Tag, Menu, MenuItem, MenuDivider } from '@blueprintjs/core';
import { CLASSES } from '@/constants/classes';
import {
FormatDateCell,
FormattedMessage as T,
Choose,
If,
Icon,
Can,
} from '@/components';
import { FormattedMessage as T, Choose, If, Icon, Can } from '@/components';
import { safeCallback } from '@/utils';
import { VendorCreditAction, AbilitySubject } from '@/constants/abilityOption';
@@ -119,7 +112,6 @@ export function useVendorsCreditNoteTableColumns() {
id: 'credit_date',
Header: intl.get('date'),
accessor: 'formatted_vendor_credit_date',
Cell: FormatDateCell,
width: 110,
className: 'credit_date',
clickable: true,

View File

@@ -11,7 +11,7 @@ import {
Position,
} from '@blueprintjs/core';
import { Icon, Money, FormatDateCell, Can } from '@/components';
import { Icon, Money, Can } from '@/components';
import { PaymentMadeAction, AbilitySubject } from '@/constants/abilityOption';
import { safeCallback } from '@/utils';
@@ -29,7 +29,7 @@ export function ActionsMenu({
}) {
return (
<Menu>
<MenuItem
<MenuItem
icon={<Icon icon="reader-18" />}
text={intl.get('view_details')}
onClick={safeCallback(onViewDetails, original)}
@@ -79,8 +79,7 @@ export function usePaymentMadesTableColumns() {
{
id: 'payment_date',
Header: intl.get('payment_date'),
Cell: FormatDateCell,
accessor: 'payment_date',
accessor: 'formatted_payment_date',
width: 140,
className: 'payment_date',
clickable: true,