2024-08-22 09:32:29 +00:00
|
|
|
import { Doc } from 'fyo/model/doc';
|
|
|
|
import { FiltersMap, ListViewSettings } from 'fyo/model/types';
|
|
|
|
import { CollectionRulesItems } from '../CollectionRulesItems/CollectionRulesItems';
|
|
|
|
import { AccountRootTypeEnum } from '../Account/types';
|
|
|
|
|
|
|
|
export class LoyaltyProgram extends Doc {
|
|
|
|
collectionRules?: CollectionRulesItems[];
|
|
|
|
expiryDuration?: number;
|
|
|
|
|
|
|
|
static filters: FiltersMap = {
|
|
|
|
expenseAccount: () => ({
|
2024-12-11 05:58:20 +00:00
|
|
|
rootType: AccountRootTypeEnum.Expense,
|
2024-08-22 09:32:29 +00:00
|
|
|
isGroup: false,
|
|
|
|
}),
|
|
|
|
};
|
|
|
|
|
|
|
|
static getListViewSettings(): ListViewSettings {
|
|
|
|
return {
|
|
|
|
columns: ['name', 'fromDate', 'toDate', 'expiryDuration'],
|
|
|
|
};
|
|
|
|
}
|
|
|
|
}
|