2
0
mirror of https://github.com/frappe/books.git synced 2025-01-23 15:18:24 +00:00

feat: hide weight enabled barcode

This commit is contained in:
AbleKSaju 2024-12-26 15:12:15 +05:30
parent 627924d9af
commit 364173101b

View File

@ -1,5 +1,5 @@
import { Doc } from 'fyo/model/doc';
import { FiltersMap } from 'fyo/model/types';
import { FiltersMap, HiddenMap } from 'fyo/model/types';
import {
AccountRootTypeEnum,
AccountTypeEnum,
@ -10,6 +10,8 @@ export class POSSettings extends Doc {
inventory?: string;
cashAccount?: string;
writeOffAccount?: string;
weightEnabledBarcode?: boolean;
posUI?: 'Classic' | 'Modern';
static filters: FiltersMap = {
@ -19,4 +21,9 @@ export class POSSettings extends Doc {
isGroup: false,
}),
};
hidden: HiddenMap = {
weightEnabledBarcode: () =>
!this.fyo.singles.InventorySettings?.enableBarcodes,
};
}