添加石河子本地数据导入接口
This commit is contained in:
@@ -116,4 +116,6 @@ public interface IJobService
|
||||
Long updateReviewStatus(Long jobId, String reviewStatus);
|
||||
|
||||
List<AppUser> getRecommendByJobId(Long jobId);
|
||||
|
||||
void shzLocalUploadFile(List<Job> jobs);
|
||||
}
|
||||
|
||||
@@ -1286,4 +1286,23 @@ public class JobServiceImpl extends ServiceImpl<JobMapper,Job> implements IJobSe
|
||||
}
|
||||
return list;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void shzLocalUploadFile(List<Job> jobs) {
|
||||
List<JobContact> allContactList = new ArrayList<>();
|
||||
for (Job job : jobs) {
|
||||
jobMapper.insert(job);
|
||||
List<JobContact> contactList = job.getJobContactList();
|
||||
if (CollectionUtils.isEmpty(contactList)) {
|
||||
continue;
|
||||
}
|
||||
contactList.forEach(c -> c.setJobId(job.getJobId()));
|
||||
allContactList.addAll(contactList);
|
||||
}
|
||||
if (!allContactList.isEmpty()) {
|
||||
jobContactMapper.batchInsert(allContactList);
|
||||
}
|
||||
//刷新es
|
||||
iesJobSearchService.resetTextCache();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user