|
@@ -33,9 +33,13 @@ class PatentinfoService extends CrudService {
|
|
|
this.export_limit = 50;
|
|
|
}
|
|
|
|
|
|
- async query(query, { skip = 0, limit = 0 }) {
|
|
|
+ async query(query, { skip = 0, limit = 0, projection }) {
|
|
|
const newquery = await this.resetCode(query);
|
|
|
- const res = await this.model.find(newquery).skip(parseInt(skip)).limit(parseInt(limit)).sort({ create_date: -1 });
|
|
|
+ const res = await this.model
|
|
|
+ .find(newquery, projection)
|
|
|
+ .skip(parseInt(skip))
|
|
|
+ .limit(parseInt(limit))
|
|
|
+ .sort({ create_date: -1 });
|
|
|
return res;
|
|
|
}
|
|
|
async count(query) {
|