mirror of
https://github.com/bigcapitalhq/bigcapital.git
synced 2026-02-20 14:50:32 +00:00
feat: closed sale receipt status.
feat: approve and reject sale estimate. feat: initial receipts, invoices, estimates and bills views.
This commit is contained in:
@@ -49,8 +49,9 @@ export default class DynamicFilterViews extends DynamicFilterRoleAbstructor {
|
||||
this.responseMeta = {
|
||||
view: {
|
||||
logicExpression: this.logicExpression,
|
||||
filterRoles: this.filterRoles
|
||||
.map((filterRole) => ({ ...omit(filterRole, ['id', 'viewId']) })),
|
||||
filterRoles: this.filterRoles.map((filterRole) =>
|
||||
({ ...omit(filterRole, ['id', 'viewId']) })
|
||||
),
|
||||
customViewId: this.viewId,
|
||||
}
|
||||
};
|
||||
|
||||
@@ -124,6 +124,12 @@ export function buildRoleQuery(model: IModel, role: IFilterRole) {
|
||||
const fieldRelation = getRoleFieldColumn(model, role.fieldKey);
|
||||
const comparatorColumn = fieldRelation.relationColumn || `${model.tableName}.${fieldRelation.column}`;
|
||||
|
||||
//
|
||||
if (typeof fieldRelation.query !== 'undefined') {
|
||||
return (builder) => {
|
||||
fieldRelation.query(builder, role);
|
||||
};
|
||||
}
|
||||
switch (fieldRelation.columnType) {
|
||||
case 'number':
|
||||
return numberRoleQueryBuilder(role, comparatorColumn);
|
||||
|
||||
Reference in New Issue
Block a user