|
|
|
@ -204,10 +204,12 @@ public class StudyFormFillController extends BaseController { |
|
|
|
List<StudyFormFillJcgj> jcgjList = new ArrayList<>(); |
|
|
|
Integer noExport=999; |
|
|
|
Boolean jcgj=false; |
|
|
|
if (form.getJcgjlx() != null && form.getJcgjlx().intValue() > 0&&!form.getJcgjlx().equals(noExport)) { |
|
|
|
if (form.getJcgjlx() != null &&!form.getJcgjlx().equals(noExport)) { |
|
|
|
QueryWrapper<StudyFormFillJcgj> studyFormFillJcgjQueryWrapper = Wrappers.query(); |
|
|
|
studyFormFillJcgjQueryWrapper.eq("form_id", studyFormFill.getId()); |
|
|
|
studyFormFillJcgjQueryWrapper.eq("jcgjlx", form.getJcgjlx()); |
|
|
|
if(form.getJcgjlx()>0){ |
|
|
|
studyFormFillJcgjQueryWrapper.eq("jcgjlx", form.getJcgjlx()); |
|
|
|
} |
|
|
|
studyFormFillJcgjQueryWrapper.orderByDesc("create_time"); |
|
|
|
jcgjList = studyFormFillJcgjService.list(studyFormFillJcgjQueryWrapper); |
|
|
|
jcgj=true; |
|
|
|
@ -231,6 +233,27 @@ public class StudyFormFillController extends BaseController { |
|
|
|
} |
|
|
|
|
|
|
|
/** |
|
|
|
* 导出 |
|
|
|
*/ |
|
|
|
@RequiresPermissions(value = {"business:studyFormFill:bj", "business:studyFormFill:xz", |
|
|
|
"business:nonTrialFormFill:bj", "business:nonTrialFormFill:xz", |
|
|
|
"business:drugFormFill:bj", "business:drugFormFill:xz"}, logical = Logical.OR) |
|
|
|
@GetMapping(value = "/exportTbByFileUrl") |
|
|
|
public AjaxResult exportTbByFileUrl(StudyFormFillExportForm form) { |
|
|
|
StudyFormFill studyFormFill = studyFormFillService.queryInfo(form.getStudyFormFillId()); |
|
|
|
Study study = studyService.getById(studyFormFill.getStudyId()); |
|
|
|
String fileUrl = form.getUrl(); |
|
|
|
fileUrl = fileUrl.replaceFirst(localFilePrefix, ""); |
|
|
|
int indexOf = fileUrl.lastIndexOf("/"); |
|
|
|
String path = fileUrl.substring(0, indexOf); |
|
|
|
String exportFileName = StudyFormFillUtil.exportTb(form.getVersion(), form.getLang(), study.getName() + "(" + study.getSn() + ") " + studyFormFill.getBdmc(), |
|
|
|
localFilePath + fileUrl, localFilePath + File.separator + path); |
|
|
|
|
|
|
|
return AjaxResult.success(localFilePrefix + path + File.separator + exportFileName); |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
* 加签 |
|
|
|
*/ |
|
|
|
@PostMapping("/jq") |
|
|
|
|