mirror of
https://github.com/bigcapitalhq/bigcapital.git
synced 2026-02-18 05:40:31 +00:00
feat(VendorList): add note accessor & personal phone.
This commit is contained in:
@@ -39,7 +39,7 @@ function VendorFormAfterPrimarySection() {
|
|||||||
{({ field, meta: { error, touched } }) => (
|
{({ field, meta: { error, touched } }) => (
|
||||||
<InputGroup
|
<InputGroup
|
||||||
intent={inputIntent({ error, touched })}
|
intent={inputIntent({ error, touched })}
|
||||||
placeholder={intl.get('work')}
|
placeholder={intl.get('personal')}
|
||||||
{...field}
|
{...field}
|
||||||
/>
|
/>
|
||||||
)}
|
)}
|
||||||
@@ -48,7 +48,7 @@ function VendorFormAfterPrimarySection() {
|
|||||||
{({ field, meta: { error, touched } }) => (
|
{({ field, meta: { error, touched } }) => (
|
||||||
<InputGroup
|
<InputGroup
|
||||||
intent={inputIntent({ error, touched })}
|
intent={inputIntent({ error, touched })}
|
||||||
placeholder={intl.get('Mobile')}
|
placeholder={intl.get('work')}
|
||||||
{...field}
|
{...field}
|
||||||
/>
|
/>
|
||||||
)}
|
)}
|
||||||
|
|||||||
@@ -6,7 +6,9 @@ import {
|
|||||||
MenuItem,
|
MenuItem,
|
||||||
MenuDivider,
|
MenuDivider,
|
||||||
Position,
|
Position,
|
||||||
|
Tooltip,
|
||||||
Intent,
|
Intent,
|
||||||
|
Classes,
|
||||||
} from '@blueprintjs/core';
|
} from '@blueprintjs/core';
|
||||||
import intl from 'react-intl-universal';
|
import intl from 'react-intl-universal';
|
||||||
|
|
||||||
@@ -114,6 +116,24 @@ export function BalanceAccessor({ closing_balance, currency_code }) {
|
|||||||
return <Money amount={closing_balance} currency={currency_code} />;
|
return <Money amount={closing_balance} currency={currency_code} />;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Note column accessor.
|
||||||
|
*/
|
||||||
|
export function NoteAccessor(row) {
|
||||||
|
return (
|
||||||
|
<If condition={row.note}>
|
||||||
|
<Tooltip
|
||||||
|
className={Classes.TOOLTIP_INDICATOR}
|
||||||
|
content={row.note}
|
||||||
|
position={Position.LEFT_TOP}
|
||||||
|
hoverOpenDelay={50}
|
||||||
|
>
|
||||||
|
<Icon icon={'file-alt'} iconSize={16} />
|
||||||
|
</Tooltip>
|
||||||
|
</If>
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Retrieve the vendors table columns.
|
* Retrieve the vendors table columns.
|
||||||
*/
|
*/
|
||||||
@@ -148,12 +168,20 @@ export function useVendorsTableColumns() {
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
id: 'work_phone',
|
id: 'work_phone',
|
||||||
Header: intl.get('work_phone'),
|
Header: intl.get('phone_number'),
|
||||||
accessor: PhoneNumberAccessor,
|
accessor: PhoneNumberAccessor,
|
||||||
className: 'work_phone',
|
className: 'work_phone',
|
||||||
width: 100,
|
width: 100,
|
||||||
clickable: true,
|
clickable: true,
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
id: 'note',
|
||||||
|
Header: intl.get('note'),
|
||||||
|
accessor: NoteAccessor,
|
||||||
|
disableSortBy: true,
|
||||||
|
width: 85,
|
||||||
|
clickable: true,
|
||||||
|
},
|
||||||
{
|
{
|
||||||
id: 'balance',
|
id: 'balance',
|
||||||
Header: intl.get('receivable_balance'),
|
Header: intl.get('receivable_balance'),
|
||||||
|
|||||||
Reference in New Issue
Block a user