use of com.bc.pmpheep.back.vo.DecPositionDisplayVO in project pmph by BCSquad.
the class DeclarationServiceImpl method exportExcel.
@Override
public ApplicationVO exportExcel(Long declarationId) {
// 专家信息显示实体
ApplicationVO applicationVO = new ApplicationVO();
// 作家申报
List<DecPositionDisplayVO> decPositionList = decPositionDao.listDecPositionsOrBook(declarationId);
for (DecPositionDisplayVO decPositions : decPositionList) {
String syllabusId = decPositions.getSyllabusId();
if (StringUtil.notEmpty(syllabusId)) {
// 下载路径
String syllabusIds = RouteUtil.MONGODB_FILE + syllabusId;
decPositions.setSyllabusId(syllabusIds);
}
switch(decPositions.getPresetPosition()) {
case 1:
decPositions.setShowPosition("编委");
break;
case 2:
decPositions.setShowPosition("副主编");
break;
case 3:
decPositions.setShowPosition("副主编,编委");
break;
case 4:
decPositions.setShowPosition("主编");
break;
case 5:
decPositions.setShowPosition("主编,编委");
break;
case 6:
decPositions.setShowPosition("主编,副主编");
break;
case 7:
decPositions.setShowPosition("主编,副主编,编委");
break;
case 8:
decPositions.setShowPosition("数字编委");
break;
case 9:
decPositions.setShowPosition("编委,数字编委");
break;
case 10:
decPositions.setShowPosition("副主编,数字编委");
break;
case 11:
decPositions.setShowPosition("副主编,编委,数字编委");
break;
case 12:
decPositions.setShowPosition("主编,数字编委");
break;
case 13:
decPositions.setShowPosition("主编,编委,数字编委");
break;
case 14:
decPositions.setShowPosition("主编,副主编,数字编委");
break;
case 15:
decPositions.setShowPosition("主编,副主编,编委,数字编委");
break;
default:
break;
}
if (decPositions.getChosenPosition() != 0) {
switch(decPositions.getChosenPosition()) {
case 1:
decPositions.setShowChosenPosition("编委");
break;
case 2:
decPositions.setShowChosenPosition("副主编");
break;
case 3:
decPositions.setShowChosenPosition("副主编,编委");
break;
case 4:
decPositions.setShowChosenPosition("主编");
break;
case 5:
decPositions.setShowChosenPosition("主编,编委");
break;
case 6:
decPositions.setShowChosenPosition("主编,副主编");
break;
case 7:
decPositions.setShowChosenPosition("主编,副主编,编委");
break;
case 8:
decPositions.setShowChosenPosition("数字编委");
break;
case 9:
decPositions.setShowChosenPosition("编委,数字编委");
break;
case 10:
decPositions.setShowChosenPosition("副主编,数字编委");
break;
case 11:
decPositions.setShowChosenPosition("副主编,编委,数字编委");
break;
case 12:
decPositions.setShowChosenPosition("主编,数字编委");
break;
case 13:
decPositions.setShowChosenPosition("主编,编委,数字编委");
break;
case 14:
decPositions.setShowChosenPosition("主编,副主编,数字编委");
break;
case 15:
decPositions.setShowChosenPosition("主编,副主编,编委,数字编委");
break;
default:
break;
}
}
}
// 作家遴选
List<DecPositionPublishedVO> decPositionPublishedVOs = decPositionPublishedDao.listDecPositionDisplayOrPosition(declarationId);
for (DecPositionPublishedVO decPositionPublished : decPositionPublishedVOs) {
if (decPositionPublished.getChosenPosition() != 0) {
switch(decPositionPublished.getChosenPosition()) {
case 1:
decPositionPublished.setShowChosenPosition("编委");
break;
case 2:
decPositionPublished.setShowChosenPosition("副主编");
break;
case 3:
decPositionPublished.setShowChosenPosition("副主编,编委");
break;
case 4:
decPositionPublished.setShowChosenPosition("主编");
break;
case 5:
decPositionPublished.setShowChosenPosition("主编,编委");
break;
case 6:
decPositionPublished.setShowChosenPosition("主编,副主编");
break;
case 7:
decPositionPublished.setShowChosenPosition("主编,副主编,编委");
break;
case 8:
decPositionPublished.setShowChosenPosition("数字编委");
break;
case 9:
decPositionPublished.setShowChosenPosition("编委,数字编委");
break;
case 10:
decPositionPublished.setShowChosenPosition("副主编,数字编委");
break;
case 11:
decPositionPublished.setShowChosenPosition("副主编,编委,数字编委");
break;
case 12:
decPositionPublished.setShowChosenPosition("主编,数字编委");
break;
case 13:
decPositionPublished.setShowChosenPosition("主编,编委,数字编委");
break;
case 14:
decPositionPublished.setShowChosenPosition("主编,副主编,数字编委");
break;
case 15:
decPositionPublished.setShowChosenPosition("主编,副主编,编委,数字编委");
break;
default:
break;
}
}
}
// 作家申报表
DeclarationOrDisplayVO declaration = declarationDao.getDeclarationByIdOrOrgName(declarationId);
WriterUser user = writerUserService.get(declaration.getUserId());
if (user != null) {
declaration.setUsername(user.getUsername());
}
// 作家学习经历
List<DecEduExp> decEduExpList = decEduExpDao.getListDecEduExpByDeclarationId(declarationId);
// 作家工作经历
List<DecWorkExp> decWorkExpList = decWorkExpDao.getListDecWorkExpByDeclarationId(declarationId);
// 作家教学经历
List<DecTeachExp> decTeachExpList = decTeachExpDao.getListDecTeachExpByDeclarationId(declarationId);
// 作家个人成就
DecAchievement decAchievement = decAchievementDao.getDecAchievementByDeclarationId(declarationId);
// 作家兼职学术
List<DecAcade> decAcadeList = decAcadeDao.getListDecAcadeByDeclarationId(declarationId);
// 作家本套上版教材参编情况
List<DecLastPosition> decLastPositionList = decLastPositionDao.getListDecLastPositionByDeclarationId(declarationId);
// 作家主编国家级规划教材情况
List<DecNationalPlan> decNationalPlanList = decNationalPlanDao.getListDecNationalPlanByDeclarationId(declarationId);
// 人卫社教材编写情况表
List<DecTextbookPmph> decTextbookPmphList = decTextbookPmphDao.getListDecTextbookPmphByDeclarationId(declarationId);
// 其他社教材编写情况
List<DecTextbook> decTextbookList = decTextbookDao.getListDecTextbookByDeclarationId(declarationId);
// 参加人卫慕课、数字教材编写情况表
DecMoocDigital decMoocDigital = decMoocDigitalDao.getDecMoocDigitalByDeclarationId(declarationId);
// 作家精品课程建设情况
List<DecCourseConstruction> decCourseConstruction = decCourseConstructionDao.getDecCourseConstructionByDeclarationId(declarationId);
// 作家科研情况
List<DecResearch> decResearchList = decResearchDao.getListDecResearchByDeclarationId(declarationId);
// 主编学术专著情况
List<DecMonograph> decMonographList = decMonographDao.getListDecMonographByDeclarationId(declarationId);
// 出版行业获奖情况
List<DecPublishReward> decPublishRewardList = decPublishRewardDao.getListDecPublishRewardByDeclarationId(declarationId);
// SCI论文投稿及影响因子情况
List<DecSci> decSciList = decSciDao.getListDecSciByDeclarationId(declarationId);
// 临床医学获奖情况
List<DecClinicalReward> decClinicalRewardList = decClinicalRewardDao.getListDecClinicalRewardByDeclarationId(declarationId);
// 学术荣誉授予情况
List<DecAcadeReward> decAcadeRewardList = decAcadeRewardDao.getListDecAcadeRewardByDeclarationId(declarationId);
// 作家扩展项
List<DecExtensionVO> decExtensionList = decExtensionDao.getListDecExtensionByDeclarationId(declarationId);
// 编写内容意向表
DecIntention decIntention = decIntentionDao.getDecIntentionByDeclarationId(declarationId);
// 是否选择必填
Material material = materialService.getMaterialById(declaration.getMaterialId());
// 把查询出来的信息添加进applicationVO
applicationVO.setDecPositionList(decPositionList);
applicationVO.setDecPositionPublishedVOs(decPositionPublishedVOs);
applicationVO.setDeclaration(declaration);
applicationVO.setDecEduExpList(decEduExpList);
applicationVO.setDecWorkExpList(decWorkExpList);
applicationVO.setDecTeachExpList(decTeachExpList);
applicationVO.setDecAchievement(decAchievement);
applicationVO.setDecAcadeList(decAcadeList);
applicationVO.setDecLastPositionList(decLastPositionList);
applicationVO.setDecNationalPlanList(decNationalPlanList);
applicationVO.setDecTextbookPmphList(decTextbookPmphList);
applicationVO.setDecTextbookList(decTextbookList);
applicationVO.setDecMoocDigital(decMoocDigital);
applicationVO.setDecCourseConstruction(decCourseConstruction);
applicationVO.setDecResearchList(decResearchList);
applicationVO.setDecMonographList(decMonographList);
applicationVO.setDecPublishRewardList(decPublishRewardList);
applicationVO.setDecSciList(decSciList);
applicationVO.setDecClinicalRewardList(decClinicalRewardList);
applicationVO.setDecAcadeRewardList(decAcadeRewardList);
applicationVO.setDecExtensionList(decExtensionList);
applicationVO.setDecIntention(decIntention);
applicationVO.setMaterial(material);
return applicationVO;
}
Aggregations