fix_ismanager
This commit is contained in:
@@ -1445,7 +1445,8 @@ function load(req, res, version) {
|
|||||||
let gasordines = Gasordine.findAllIdApp(idapp);
|
let gasordines = Gasordine.findAllIdApp(idapp);
|
||||||
let ismanager = false;
|
let ismanager = false;
|
||||||
try {
|
try {
|
||||||
ismanager = User.isManager(req.user.perm)
|
if (req.user)
|
||||||
|
ismanager = User.isManager(req.user.perm)
|
||||||
} catch(e) {
|
} catch(e) {
|
||||||
}
|
}
|
||||||
let products = Product.findAllIdApp(idapp, undefined, undefined, ismanager);
|
let products = Product.findAllIdApp(idapp, undefined, undefined, ismanager);
|
||||||
|
|||||||
Reference in New Issue
Block a user