分页和排序
分页
exports.main = async function paging() {
try {
var Product = new BaaS.TableObject(tableName)
var query = new BaaS.Query()
query.compare('amount', '>', 0)
let res = await Product.setQuery(query).limit(10).offset(0).find()
// success
return res
} catch(err) {
// error
throw err
}
}排序
Last updated
Was this helpful?