fix: payment viaVoucherDialog lang.

This commit is contained in:
elforjani3
2021-06-15 15:33:22 +02:00
parent aa21da88b3
commit de2cf8e8f3
4 changed files with 37 additions and 22 deletions

View File

@@ -26,13 +26,10 @@ function PaymentViaLicenseDialogContent({
// #withDialog // #withDialog
closeDialog, closeDialog,
}) { }) {
const history = useHistory(); const history = useHistory();
// Payment via voucher // Payment via voucher
const { const { mutateAsync: paymentViaVoucherMutate } = usePaymentByVoucher();
mutateAsync: paymentViaVoucherMutate,
} = usePaymentByVoucher();
// Handle submit. // Handle submit.
const handleSubmit = (values, { setSubmitting, setErrors }) => { const handleSubmit = (values, { setSubmitting, setErrors }) => {
@@ -41,7 +38,7 @@ function PaymentViaLicenseDialogContent({
paymentViaVoucherMutate({ ...values }) paymentViaVoucherMutate({ ...values })
.then(() => { .then(() => {
Toaster.show({ Toaster.show({
message: 'Payment has been done successfully.', message: intl.get('payment_has_been_done_successfully'),
intent: Intent.SUCCESS, intent: Intent.SUCCESS,
}); });
return closeDialog('payment-via-voucher'); return closeDialog('payment-via-voucher');

View File

@@ -1121,5 +1121,6 @@
"something_went_wrong": "Something went wrong!", "something_went_wrong": "Something went wrong!",
"please_refresh_the_page": "Please refresh the page", "please_refresh_the_page": "Please refresh the page",
"waiting_to_redirect": "Waiting to redirect", "waiting_to_redirect": "Waiting to redirect",
"refresh_the_page_if_redirect_not_worked": "Refresh the page if redirect not worked." "refresh_the_page_if_redirect_not_worked": "Refresh the page if redirect not worked.",
"payment_has_been_done_successfully":"Payment has been done successfully."
} }

View File

@@ -1,4 +1,6 @@
import React from 'react';
import { createReducer } from '@reduxjs/toolkit'; import { createReducer } from '@reduxjs/toolkit';
import { FormattedMessage as T } from 'components';
const initialState = { const initialState = {
plans: [ plans: [
@@ -6,11 +8,12 @@ const initialState = {
name: 'Free', name: 'Free',
slug: 'free', slug: 'free',
description: [ description: [
'Sales/purchases module.', <T id={'sale_and_purchase_invoices'} />,
'Expense module.', <T id={'customers_vendors_accounts'} />,
'Inventory module.', <T id={'expense_tracking'} />,
'Unlimited status pages.', <T id={'manual_journals'} />,
'Unlimited status pages.', <T id={'financial_reports'} />,
<T id={'for_one_user_and_accountant'} />,
], ],
price: { price: {
month: '100', month: '100',
@@ -19,14 +22,15 @@ const initialState = {
currencyCode: 'LYD', currencyCode: 'LYD',
}, },
{ {
name: 'Pro', name: 'Plus',
slug: 'pro', slug: 'plus',
description: [ description: [
'Sales/purchases module.', <T id={'all_capital_starter_features'} />,
'Expense module.', <T id={'multi_currency'} />,
'Inventory module.', <T id={'purchase_and_sell_orders'} />,
'Unlimited status pages.', <T id={'inventory_management'} />,
'Unlimited status pages.', <T id={'three_users_with_your_accountant'} />,
<T id={'advanced_financial_reports'} />,
], ],
price: { price: {
month: '200', month: '200',
@@ -34,6 +38,21 @@ const initialState = {
}, },
currencyCode: 'LYD', currencyCode: 'LYD',
}, },
{
name: 'Enterprise',
slug: 'enterprise',
description: [
<T id={'all_capital_essential_features'} />,
<T id={'track_multi_branches_and_locations'} />,
<T id={'projects_accounting_and_timesheets'} />,
<T id={'accounting_dimensions'} />,
],
price: {
month: '300',
year: '3,400',
},
currencyCode: 'LYD',
},
], ],
periods: [ periods: [
{ {
@@ -47,6 +66,4 @@ const initialState = {
], ],
}; };
export default createReducer(initialState, { export default createReducer(initialState, {});
});

View File

@@ -9,7 +9,7 @@
display: flex; display: flex;
flex-direction: column; flex-direction: column;
width: 215px; width: 215px;
height: 267px; height: 277px;
border-radius: 5px; border-radius: 5px;
padding: 15px; padding: 15px;
border: 1px solid #dcdcdc; border: 1px solid #dcdcdc;