Merge pull request '#7648 add myOpts' (!2672) from 7648-fix-addOpts into dev
gitea/salix/pipeline/head This commit looks good
Details
gitea/salix/pipeline/head This commit looks good
Details
Reviewed-on: #2672 Reviewed-by: Javier Segarra <jsegarra@verdnatura.es>
This commit is contained in:
commit
c7f6ca6db9
|
@ -146,7 +146,7 @@ module.exports = Self => {
|
|||
});
|
||||
filter = mergeFilters(ctx.args.filter, {where});
|
||||
const userId = ctx.req.accessToken.userId;
|
||||
const isSupplier = await Self.app.models.Supplier.findById(userId, options);
|
||||
const isSupplier = await Self.app.models.Supplier.findById(userId, myOptions);
|
||||
if (isSupplier) {
|
||||
if (!filter.where) filter.where = {};
|
||||
filter.where[`e.supplierFk`] = ctx.req.accessToken.userId;
|
||||
|
|
Loading…
Reference in New Issue