I am facing this problem that .find is showing an unknown function or method. for this view.query('products', keystone.list('product').model.find()); Then when I open the page product I get this error "Error thrown for request: /products ReferenceError: Unknown keystone list "product" " var keystone= require('keystone');
exports= module.exports=function (req,res) {
var view=new keystone.View(req,res);
var locals=res.locals;
//set locals
locals.section= 'store';
view.query('products', keystone.list('product').model.find());
// load product
view.render('products');
}
via Mohsin Younas
No comments:
Post a Comment