mirror of
https://github.com/bigcapitalhq/bigcapital.git
synced 2026-02-18 05:40:31 +00:00
feat (lang) : add Contacts & Sales & Purchases.
This commit is contained in:
@@ -12,7 +12,7 @@ import { inputIntent } from 'utils';
|
||||
export default function BillFormFooter() {
|
||||
return (
|
||||
<div class={classNames(CLASSES.PAGE_FORM_FOOTER)}>
|
||||
<Postbox title={'Bill details'} defaultOpen={false}>
|
||||
<Postbox title={<T id={'bill_details'} />} defaultOpen={false}>
|
||||
<Row>
|
||||
<Col md={8}>
|
||||
<FastField name={'note'}>
|
||||
@@ -33,7 +33,7 @@ export default function BillFormFooter() {
|
||||
initialFiles={[]}
|
||||
// onDrop={onDropFiles}
|
||||
// onDeleteFile={onDropFiles}
|
||||
hint={'Attachments: Maxiumum size: 20MB'}
|
||||
hint={<T id={'attachments_maximum'} />}
|
||||
/>
|
||||
</Col>
|
||||
</Row>
|
||||
|
||||
@@ -2,6 +2,7 @@ import React, { useMemo } from 'react';
|
||||
import classNames from 'classnames';
|
||||
import { sumBy } from 'lodash';
|
||||
import { useFormikContext } from 'formik';
|
||||
import { formatMessage } from 'services/intl';
|
||||
|
||||
import { CLASSES } from 'common/classes';
|
||||
|
||||
@@ -28,7 +29,7 @@ function BillFormHeader({
|
||||
<div className={classNames(CLASSES.PAGE_FORM_HEADER)}>
|
||||
<BillFormHeaderFields />
|
||||
<PageFormBigNumber
|
||||
label={'Due Amount'}
|
||||
label={formatMessage({id:'due_amount'})}
|
||||
amount={totalDueAmount}
|
||||
currencyCode={baseCurrency}
|
||||
/>
|
||||
|
||||
@@ -2,16 +2,17 @@ import React from 'react';
|
||||
import { Button, Intent } from '@blueprintjs/core';
|
||||
import { useHistory } from 'react-router-dom';
|
||||
import { EmptyStatus } from 'components';
|
||||
import { FormattedMessage as T } from 'react-intl';
|
||||
|
||||
export default function BillsEmptyStatus() {
|
||||
const history = useHistory();
|
||||
|
||||
return (
|
||||
<EmptyStatus
|
||||
title={'Manage the organization’s services and products.'}
|
||||
title={<T id={'manage_the_organization_s_services_and_products'} />}
|
||||
description={
|
||||
<p>
|
||||
Here a list of your organization products and services, to be used when you create invoices or bills to your customers or vendors.
|
||||
<T id={'here_a_list_of_your_organization_products_and_services'} />
|
||||
</p>
|
||||
}
|
||||
action={
|
||||
@@ -23,11 +24,11 @@ export default function BillsEmptyStatus() {
|
||||
history.push('/bills/new');
|
||||
}}
|
||||
>
|
||||
New bill
|
||||
<T id={'new_bill'} />
|
||||
</Button>
|
||||
|
||||
<Button intent={Intent.NONE} large={true}>
|
||||
Learn more
|
||||
<T id={'learn_more'} />
|
||||
</Button>
|
||||
</>
|
||||
}
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
import React, { useCallback } from 'react';
|
||||
import { CloudLoadingIndicator } from 'components';
|
||||
import classNames from 'classnames';
|
||||
import { FormattedMessage as T } from 'react-intl';
|
||||
|
||||
import { CLASSES } from 'common/classes';
|
||||
import { DataTableEditable } from 'components';
|
||||
@@ -42,9 +43,15 @@ export default function PaymentMadeEntriesTable({
|
||||
|
||||
// Detarmines the right no results message before selecting vendor and aftering
|
||||
// selecting vendor id.
|
||||
const noResultsMessage = vendor_id
|
||||
? 'There is no payable bills for this vendor that can be applied for this payment'
|
||||
: 'Please select a vendor to display all open bills for it.';
|
||||
const noResultsMessage = vendor_id ? (
|
||||
<T
|
||||
id={
|
||||
'there_is_no_payable_bills_for_this_vendor_that_can_be_applied_for_this_payment'
|
||||
}
|
||||
/>
|
||||
) : (
|
||||
<T id={'please_select_a_vendor_to_display_all_open_bills_for_it'} />
|
||||
);
|
||||
|
||||
return (
|
||||
<CloudLoadingIndicator isLoading={isNewEntriesFetching}>
|
||||
|
||||
@@ -12,7 +12,7 @@ import { CLASSES } from 'common/classes';
|
||||
export default function PaymentMadeFooter() {
|
||||
return (
|
||||
<div className={classNames(CLASSES.PAGE_FORM_FOOTER)}>
|
||||
<Postbox title={'Payment made details'} defaultOpen={false}>
|
||||
<Postbox title={<T id={'payment_made_details'} />} defaultOpen={false}>
|
||||
<Row>
|
||||
<Col md={8}>
|
||||
{/* --------- Statement --------- */}
|
||||
|
||||
@@ -4,9 +4,9 @@ import { useFormikContext } from 'formik';
|
||||
import { sumBy } from 'lodash';
|
||||
import { CLASSES } from 'common/classes';
|
||||
import { compose } from 'utils';
|
||||
import {
|
||||
Money,
|
||||
} from 'components';
|
||||
import { Money } from 'components';
|
||||
import { FormattedMessage as T } from 'react-intl';
|
||||
|
||||
import PaymentMadeFormHeaderFields from './PaymentMadeFormHeaderFields';
|
||||
import withSettings from 'containers/Settings/withSettings';
|
||||
|
||||
@@ -18,7 +18,9 @@ function PaymentMadeFormHeader({
|
||||
baseCurrency,
|
||||
}) {
|
||||
// Formik form context.
|
||||
const { values: { entries } } = useFormikContext();
|
||||
const {
|
||||
values: { entries },
|
||||
} = useFormikContext();
|
||||
|
||||
// Calculate the payment amount of the entries.
|
||||
const amountPaid = useMemo(() => sumBy(entries, 'payment_amount'), [entries]);
|
||||
@@ -30,7 +32,9 @@ function PaymentMadeFormHeader({
|
||||
|
||||
<div className={classNames(CLASSES.PAGE_FORM_HEADER_BIG_NUMBERS)}>
|
||||
<div class="big-amount">
|
||||
<span class="big-amount__label">Amount Received</span>
|
||||
<span class="big-amount__label">
|
||||
<T id={'amount_received'} />
|
||||
</span>
|
||||
<h1 class="big-amount__number">
|
||||
<Money amount={amountPaid} currency={baseCurrency} />
|
||||
</h1>
|
||||
|
||||
@@ -157,7 +157,7 @@ function PaymentMadeFormHeaderFields({ baseCurrency }) {
|
||||
small={true}
|
||||
minimal={true}
|
||||
>
|
||||
Receive full amount (
|
||||
<T id={'receive_full_amount'} /> (
|
||||
<Money amount={payableFullAmount} currency={baseCurrency} />)
|
||||
</Button>
|
||||
</FormGroup>
|
||||
|
||||
@@ -2,17 +2,17 @@ import React from 'react';
|
||||
import { Button, Intent } from '@blueprintjs/core';
|
||||
import { useHistory } from 'react-router-dom';
|
||||
import { EmptyStatus } from 'components';
|
||||
import { FormattedMessage as T } from 'react-intl';
|
||||
|
||||
export default function PaymentMadesEmptyStatus() {
|
||||
const history = useHistory();
|
||||
|
||||
return (
|
||||
<EmptyStatus
|
||||
title={'The organization does not have invoices, yet!'}
|
||||
title={<T id={'the_organization_doesn_t_receive_money_yet'} />}
|
||||
description={
|
||||
<p>
|
||||
It is a long established fact that a reader will be distracted by the
|
||||
readable content of a page when looking at its layout.
|
||||
<T id={'it_is_a_long_established_fact_that_a_reader'} />
|
||||
</p>
|
||||
}
|
||||
action={
|
||||
@@ -24,11 +24,11 @@ export default function PaymentMadesEmptyStatus() {
|
||||
history.push('/payment-mades/new');
|
||||
}}
|
||||
>
|
||||
New bill payment
|
||||
<T id={'new_bill_payment'} />
|
||||
</Button>
|
||||
|
||||
<Button intent={Intent.NONE} large={true}>
|
||||
Learn more
|
||||
<T id={'learn_more'} />
|
||||
</Button>
|
||||
</>
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user