zs 1 anno fa
parent
commit
419fe399dd
1 ha cambiato i file con 1 aggiunte e 6 eliminazioni
  1. 1 6
      src/service/patent.service.ts

+ 1 - 6
src/service/patent.service.ts

@@ -263,11 +263,6 @@ export class PatentService extends BaseService<modelType> {
     const total = await this.model.count(query.filter);
     const total = await this.model.count(query.filter);
     let skip = 0;
     let skip = 0;
     const meta = query.file;
     const meta = query.file;
-    const projection = {};
-    for (const m of meta) {
-      const { model } = m;
-      projection[model] = 1;
-    }
     // 将数据分割,否则容易直接把js堆栈干满了,服务就炸了
     // 将数据分割,否则容易直接把js堆栈干满了,服务就炸了
     const head = meta.map(i => i.label);
     const head = meta.map(i => i.label);
     for (let i = 0; i < total; i = i + parseInt(query.end_num)) {
     for (let i = 0; i < total; i = i + parseInt(query.end_num)) {
@@ -571,7 +566,7 @@ export class PatentService extends BaseService<modelType> {
   }
   }
 
 
   // 每天晚上11点执行一次检查并创建预警信息
   // 每天晚上11点执行一次检查并创建预警信息
-  @TaskLocal('0 0 23 * *')
+  @TaskLocal('0 0 23 * * *')
   async createWarnning() {
   async createWarnning() {
     // console.log('定时任务');
     // console.log('定时任务');
     let data = await this.model.find({ term: '1' });
     let data = await this.model.find({ term: '1' });