fix: scope permission
All checks were successful
Spell Check / Spell Check with Typos (push) Successful in 10s
All checks were successful
Spell Check / Spell Check with Typos (push) Successful in 10s
This commit is contained in:
parent
5c58953820
commit
2502b7c68f
1 changed files with 8 additions and 1 deletions
|
|
@ -449,7 +449,14 @@ export class StatsController extends Controller {
|
|||
data: await tx.payment
|
||||
.groupBy({
|
||||
_sum: { amount: true },
|
||||
where: { createdAt: { gte: v, lte: date.endOf("month").toDate() } },
|
||||
where: {
|
||||
createdAt: { gte: v, lte: date.endOf("month").toDate() },
|
||||
invoice: {
|
||||
quotation: {
|
||||
registeredBranch: { OR: permissionCondCompany(req.user) },
|
||||
},
|
||||
},
|
||||
},
|
||||
by: "paymentStatus",
|
||||
})
|
||||
.then((v) =>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue