diff --git a/packages/server/src/loaders/events.ts b/packages/server/src/loaders/events.ts index f402a6087..9591e6b90 100644 --- a/packages/server/src/loaders/events.ts +++ b/packages/server/src/loaders/events.ts @@ -34,4 +34,4 @@ // import 'services/Sales/SaleInvoiceWriteoffSubscriber'; // import 'subscribers/SaleInvoices/SendSmsNotificationToCustomer'; // import 'subscribers/SaleReceipt/SendNotificationToCustomer'; -// import 'services/Sales/PaymentReceives/PaymentReceiveSmsSubscriber'; \ No newline at end of file +// import 'services/Sales/PaymentReceived/PaymentReceiveSmsSubscriber'; \ No newline at end of file diff --git a/packages/webapp/src/components/DialogsContainer.tsx b/packages/webapp/src/components/DialogsContainer.tsx index 284c3cfbc..94ecdcc4d 100644 --- a/packages/webapp/src/components/DialogsContainer.tsx +++ b/packages/webapp/src/components/DialogsContainer.tsx @@ -49,7 +49,7 @@ import InvoiceExchangeRateChangeDialog from '@/containers/Sales/Invoices/Invoice import InvoiceMailDialog from '@/containers/Sales/Invoices/InvoiceMailDialog/InvoiceMailDialog'; import EstimateMailDialog from '@/containers/Sales/Estimates/EstimateMailDialog/EstimateMailDialog'; import ReceiptMailDialog from '@/containers/Sales/Receipts/ReceiptMailDialog/ReceiptMailDialog'; -import PaymentMailDialog from '@/containers/Sales/PaymentReceives/PaymentMailDialog/PaymentMailDialog'; +import PaymentMailDialog from '@/containers/Sales/PaymentsReceived/PaymentMailDialog/PaymentMailDialog'; import { ExportDialog } from '@/containers/Dialogs/ExportDialog'; import { RuleFormDialog } from '@/containers/Banking/Rules/RuleFormDialog/RuleFormDialog'; import { DisconnectBankAccountDialog } from '@/containers/CashFlow/AccountTransactions/dialogs/DisconnectBankAccountDialog/DisconnectBankAccountDialog'; diff --git a/packages/webapp/src/components/DrawersContainer.tsx b/packages/webapp/src/components/DrawersContainer.tsx index cf9451d1c..6165fda85 100644 --- a/packages/webapp/src/components/DrawersContainer.tsx +++ b/packages/webapp/src/components/DrawersContainer.tsx @@ -39,7 +39,7 @@ export default function DrawersContainer() { - + diff --git a/packages/webapp/src/constants/drawers.ts b/packages/webapp/src/constants/drawers.ts index c4e477352..5a3a96cd3 100644 --- a/packages/webapp/src/constants/drawers.ts +++ b/packages/webapp/src/constants/drawers.ts @@ -6,7 +6,7 @@ export enum DRAWERS { BILL_DETAILS = 'bill-drawer', INVOICE_DETAILS = 'invoice-detail-drawer', RECEIPT_DETAILS = 'receipt-detail-drawer', - PAYMENT_RECEIVE_DETAILS = 'payment-receive-detail-drawer', + PAYMENT_RECEIVED_DETAILS = 'payment-receive-detail-drawer', PAYMENT_MADE_DETAILS = 'payment-made-drawer', ESTIMATE_DETAILS = 'estimate-detail-drawer', ITEM_DETAILS = 'item-detail-drawer', diff --git a/packages/webapp/src/constants/homepageOptions.tsx b/packages/webapp/src/constants/homepageOptions.tsx index 7c050787d..4ce5f2dc4 100644 --- a/packages/webapp/src/constants/homepageOptions.tsx +++ b/packages/webapp/src/constants/homepageOptions.tsx @@ -55,7 +55,7 @@ export const accountsReceivable = [ description: ( ), - link: '/payment-receives', + link: '/payments-received', subject: AbilitySubject.PaymentReceive, ability: PaymentReceiveAction.View, }, diff --git a/packages/webapp/src/constants/sidebarMenu.tsx b/packages/webapp/src/constants/sidebarMenu.tsx index 260a23def..ba2cc0c39 100644 --- a/packages/webapp/src/constants/sidebarMenu.tsx +++ b/packages/webapp/src/constants/sidebarMenu.tsx @@ -179,8 +179,8 @@ export const SidebarMenu = [ type: ISidebarMenuItemType.Link, }, { - text: , - href: '/payment-receives', + text: , + href: '/payments-received', type: ISidebarMenuItemType.Link, permission: { subject: AbilitySubject.PaymentReceive, @@ -226,8 +226,8 @@ export const SidebarMenu = [ type: ISidebarMenuItemType.Link, }, { - text: , - href: '/payment-receives/new', + text: , + href: '/payment-received/new', type: ISidebarMenuItemType.Link, permission: { subject: AbilitySubject.PaymentReceive, diff --git a/packages/webapp/src/containers/Alerts/PaymentReceives/ClearingAllLinesAlert.tsx b/packages/webapp/src/containers/Alerts/PaymentReceived/ClearingAllLinesAlert.tsx similarity index 100% rename from packages/webapp/src/containers/Alerts/PaymentReceives/ClearingAllLinesAlert.tsx rename to packages/webapp/src/containers/Alerts/PaymentReceived/ClearingAllLinesAlert.tsx diff --git a/packages/webapp/src/containers/Alerts/PaymentReceives/PaymentReceiveDeleteAlert.tsx b/packages/webapp/src/containers/Alerts/PaymentReceived/PaymentReceivedDeleteAlert.tsx similarity index 88% rename from packages/webapp/src/containers/Alerts/PaymentReceives/PaymentReceiveDeleteAlert.tsx rename to packages/webapp/src/containers/Alerts/PaymentReceived/PaymentReceivedDeleteAlert.tsx index 553bfb2c7..11ce47773 100644 --- a/packages/webapp/src/containers/Alerts/PaymentReceives/PaymentReceiveDeleteAlert.tsx +++ b/packages/webapp/src/containers/Alerts/PaymentReceived/PaymentReceivedDeleteAlert.tsx @@ -21,7 +21,7 @@ import { DRAWERS } from '@/constants/drawers'; /** * Payment receive delete alert. */ -function PaymentReceiveDeleteAlert({ +function PaymentReceivedDeleteAlert({ name, // #withAlertStoreConnect @@ -48,11 +48,11 @@ function PaymentReceiveDeleteAlert({ .then(() => { AppToaster.show({ message: intl.get( - 'the_payment_receive_has_been_deleted_successfully', + 'the_payment_received_has_been_deleted_successfully', ), intent: Intent.SUCCESS, }); - closeDrawer(DRAWERS.PAYMENT_RECEIVE_DETAILS); + closeDrawer(DRAWERS.PAYMENT_RECEIVED_DETAILS); }) .catch( ({ @@ -81,7 +81,7 @@ function PaymentReceiveDeleteAlert({ >

@@ -92,4 +92,4 @@ export default compose( withAlertStoreConnect(), withAlertActions, withDrawerActions, -)(PaymentReceiveDeleteAlert); +)(PaymentReceivedDeleteAlert); diff --git a/packages/webapp/src/containers/Alerts/PaymentReceives/_utils.ts b/packages/webapp/src/containers/Alerts/PaymentReceived/_utils.ts similarity index 100% rename from packages/webapp/src/containers/Alerts/PaymentReceives/_utils.ts rename to packages/webapp/src/containers/Alerts/PaymentReceived/_utils.ts diff --git a/packages/webapp/src/containers/AlertsContainer/registered.tsx b/packages/webapp/src/containers/AlertsContainer/registered.tsx index f585c398f..e2fdb4f97 100644 --- a/packages/webapp/src/containers/AlertsContainer/registered.tsx +++ b/packages/webapp/src/containers/AlertsContainer/registered.tsx @@ -6,7 +6,7 @@ import InventoryAdjustmentsAlerts from '@/containers/InventoryAdjustments/Invent import EstimatesAlerts from '@/containers/Sales/Estimates/EstimatesAlerts'; import InvoicesAlerts from '@/containers/Sales/Invoices/InvoicesAlerts'; import ReceiptsAlerts from '@/containers/Sales/Receipts/ReceiptsAlerts'; -import PaymentReceiveAlerts from '@/containers/Sales/PaymentReceives/PaymentReceiveAlerts'; +import PaymentsReceivedAlerts from '@/containers/Sales/PaymentsReceived/PaymentsReceivedAlerts'; import BillsAlerts from '@/containers/Purchases/Bills/BillsLanding/BillsAlerts'; import PaymentMadesAlerts from '@/containers/Purchases/PaymentMades/PaymentMadesAlerts'; import CustomersAlerts from '@/containers/Customers/CustomersAlerts'; @@ -38,7 +38,7 @@ export default [ ...EstimatesAlerts, ...InvoicesAlerts, ...ReceiptsAlerts, - ...PaymentReceiveAlerts, + ...PaymentsReceivedAlerts, ...BillsAlerts, ...PaymentMadesAlerts, ...CustomersAlerts, diff --git a/packages/webapp/src/containers/CashFlow/AccountTransactions/utils.tsx b/packages/webapp/src/containers/CashFlow/AccountTransactions/utils.tsx index c76ebb813..58535e389 100644 --- a/packages/webapp/src/containers/CashFlow/AccountTransactions/utils.tsx +++ b/packages/webapp/src/containers/CashFlow/AccountTransactions/utils.tsx @@ -66,7 +66,7 @@ export const handleCashFlowTransactionType = (reference, openDrawer) => { expenseId: reference.reference_id, }); case 'PaymentReceive': - return openDrawer(DRAWERS.PAYMENT_RECEIVE_DETAILS, { + return openDrawer(DRAWERS.PAYMENT_RECEIVED_DETAILS, { paymentReceiveId: reference.reference_id, }); case 'BillPayment': diff --git a/packages/webapp/src/containers/Dialogs/PaymentReceivePdfPreviewDialog/index.tsx b/packages/webapp/src/containers/Dialogs/PaymentReceivePdfPreviewDialog/index.tsx index 89a86709d..a4a52fa65 100644 --- a/packages/webapp/src/containers/Dialogs/PaymentReceivePdfPreviewDialog/index.tsx +++ b/packages/webapp/src/containers/Dialogs/PaymentReceivePdfPreviewDialog/index.tsx @@ -25,7 +25,7 @@ function PaymentReceivePdfPreviewDialog({ return ( } + title={} className={classNames(CLASSES.DIALOG_PDF_PREVIEW)} autoFocus={true} canEscapeKeyClose={true} diff --git a/packages/webapp/src/containers/Dialogs/QuickPaymentReceiveFormDialog/QuickPaymentReceive.schema.tsx b/packages/webapp/src/containers/Dialogs/QuickPaymentReceiveFormDialog/QuickPaymentReceive.schema.tsx index ef8c20c2a..46a159e23 100644 --- a/packages/webapp/src/containers/Dialogs/QuickPaymentReceiveFormDialog/QuickPaymentReceive.schema.tsx +++ b/packages/webapp/src/containers/Dialogs/QuickPaymentReceiveFormDialog/QuickPaymentReceive.schema.tsx @@ -9,7 +9,7 @@ const Schema = Yup.object().shape({ .required() .nullable() .max(DATATYPES_LENGTH.STRING) - .label(intl.get('payment_receive_no_')), + .label(intl.get('payment_received_no_')), payment_date: Yup.date().required().label(intl.get('payment_date_')), deposit_account_id: Yup.number() .required() diff --git a/packages/webapp/src/containers/Dialogs/QuickPaymentReceiveFormDialog/QuickPaymentReceiveForm.tsx b/packages/webapp/src/containers/Dialogs/QuickPaymentReceiveFormDialog/QuickPaymentReceiveForm.tsx index b2326c525..2b9d83115 100644 --- a/packages/webapp/src/containers/Dialogs/QuickPaymentReceiveFormDialog/QuickPaymentReceiveForm.tsx +++ b/packages/webapp/src/containers/Dialogs/QuickPaymentReceiveFormDialog/QuickPaymentReceiveForm.tsx @@ -70,7 +70,7 @@ function QuickPaymentReceiveForm({ // Handle request response success. const onSaved = (response) => { AppToaster.show({ - message: intl.get('the_payment_receive_transaction_has_been_created'), + message: intl.get('the_payment_received_transaction_has_been_created'), intent: Intent.SUCCESS, }); closeDialog(dialogName); diff --git a/packages/webapp/src/containers/Dialogs/QuickPaymentReceiveFormDialog/utils.tsx b/packages/webapp/src/containers/Dialogs/QuickPaymentReceiveFormDialog/utils.tsx index c6e7a8bb9..b02e74295 100644 --- a/packages/webapp/src/containers/Dialogs/QuickPaymentReceiveFormDialog/utils.tsx +++ b/packages/webapp/src/containers/Dialogs/QuickPaymentReceiveFormDialog/utils.tsx @@ -34,7 +34,7 @@ export const transformErrors = (errors, { setFieldError }) => { if (getError('PAYMENT_RECEIVE_NO_REQUIRED')) { setFieldError( 'payment_receive_no', - intl.get('payment_receive_number_required'), + intl.get('payment_received_number_required'), ); } if (getError('INVALID_PAYMENT_AMOUNT')) { diff --git a/packages/webapp/src/containers/Drawers/CustomerDetailsDrawer/CustomerDetailsActionsBar.tsx b/packages/webapp/src/containers/Drawers/CustomerDetailsDrawer/CustomerDetailsActionsBar.tsx index 61343f5ec..edaf98c3b 100644 --- a/packages/webapp/src/containers/Drawers/CustomerDetailsDrawer/CustomerDetailsActionsBar.tsx +++ b/packages/webapp/src/containers/Drawers/CustomerDetailsDrawer/CustomerDetailsActionsBar.tsx @@ -68,7 +68,7 @@ function CustomerDetailsActionsBar({ }; // Handle new payment receive button click. const handleNewPaymentClick = () => { - history.push('/payment-receives/new'); + history.push('/payment-received/new'); closeDrawer(DRAWERS.CUSTOMER_DETAILS); }; // Handle new estimate button click. diff --git a/packages/webapp/src/containers/Drawers/InvoiceDetailDrawer/InvoicePaymentTransactions/InvoicePaymentTransactionsTable.tsx b/packages/webapp/src/containers/Drawers/InvoiceDetailDrawer/InvoicePaymentTransactions/InvoicePaymentTransactionsTable.tsx index 2a88ac028..7f778c049 100644 --- a/packages/webapp/src/containers/Drawers/InvoiceDetailDrawer/InvoicePaymentTransactions/InvoicePaymentTransactionsTable.tsx +++ b/packages/webapp/src/containers/Drawers/InvoiceDetailDrawer/InvoicePaymentTransactions/InvoicePaymentTransactionsTable.tsx @@ -47,14 +47,14 @@ function InvoicePaymentTransactionsTable({ // Handles delete payment transactions. const handleDeletePaymentTransactons = ({ payment_receive_id }) => { - openAlert('payment-receive-delete', { + openAlert('payment-received-delete', { paymentReceiveId: payment_receive_id, }); }; // Handles edit payment transactions. const handleEditPaymentTransactions = ({ payment_receive_id }) => { - history.push(`/payment-receives/${payment_receive_id}/edit`); + history.push(`/payments-received/${payment_receive_id}/edit`); closeDrawer(DRAWERS.INVOICE_DETAILS); }; return ( diff --git a/packages/webapp/src/containers/Drawers/PaymentReceiveDetailDrawer/PaymentReceiveActionsBar.tsx b/packages/webapp/src/containers/Drawers/PaymentReceiveDetailDrawer/PaymentReceiveActionsBar.tsx index 6cfa62edc..cad001a72 100644 --- a/packages/webapp/src/containers/Drawers/PaymentReceiveDetailDrawer/PaymentReceiveActionsBar.tsx +++ b/packages/webapp/src/containers/Drawers/PaymentReceiveDetailDrawer/PaymentReceiveActionsBar.tsx @@ -33,7 +33,7 @@ import { DialogsName } from '@/constants/dialogs'; /** * Payment receive actions bar. */ -function PaymentReceiveActionsBar({ +function PaymentsReceivedActionsBar({ // #withAlertsActions openAlert, @@ -50,13 +50,13 @@ function PaymentReceiveActionsBar({ // Handle edit payment receive. const handleEditPaymentReceive = () => { - history.push(`/payment-receives/${paymentReceiveId}/edit`); - closeDrawer(DRAWERS.PAYMENT_RECEIVE_DETAILS); + history.push(`/payments-received/${paymentReceiveId}/edit`); + closeDrawer(DRAWERS.PAYMENT_RECEIVED_DETAILS); }; // Handle delete payment receive. const handleDeletePaymentReceive = () => { - openAlert('payment-receive-delete', { paymentReceiveId }); + openAlert('payment-received-delete', { paymentReceiveId }); }; // Handle notify via SMS. @@ -80,7 +80,7 @@ function PaymentReceiveActionsBar({