mirror of
https://github.com/bigcapitalhq/bigcapital.git
synced 2026-02-19 06:10:31 +00:00
feat: quick create action on select/suggest items fields.
This commit is contained in:
@@ -108,7 +108,9 @@ const LandedCostHeaderCell = () => {
|
||||
/**
|
||||
* Retrieve editable items entries columns.
|
||||
*/
|
||||
export function useEditableItemsEntriesColumns({ landedCost }) {
|
||||
export function useEditableItemsEntriesColumns({
|
||||
landedCost,
|
||||
}) {
|
||||
return React.useMemo(
|
||||
() => [
|
||||
{
|
||||
@@ -129,6 +131,7 @@ export function useEditableItemsEntriesColumns({ landedCost }) {
|
||||
disableSortBy: true,
|
||||
width: 130,
|
||||
className: 'item',
|
||||
fieldProps: { allowCreate: true },
|
||||
},
|
||||
{
|
||||
Header: intl.get('description'),
|
||||
|
||||
@@ -164,3 +164,12 @@ export const composeRowsOnNewRow = R.curry((rowIndex, newRow, rows) => {
|
||||
updateTableRow(rowIndex, newRow),
|
||||
)(rows);
|
||||
});
|
||||
|
||||
/**
|
||||
*
|
||||
* @param {*} entries
|
||||
* @returns
|
||||
*/
|
||||
export const composeControlledEntries = (entries) => {
|
||||
return R.compose(orderingLinesIndexes, updateItemsEntriesTotal)(entries);
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user