|
@@ -0,0 +1,41 @@
|
|
|
+package com.lantone.qc.trans.changx;
|
|
|
+
|
|
|
+import com.google.common.collect.Lists;
|
|
|
+import com.lantone.qc.pub.model.doc.StagesSummaryDoc;
|
|
|
+import com.lantone.qc.pub.model.keys.ModelStandardKeys;
|
|
|
+import com.lantone.qc.pub.model.vo.MedrecVo;
|
|
|
+import com.lantone.qc.pub.util.ListUtil;
|
|
|
+import com.lantone.qc.trans.ModelDocTrans;
|
|
|
+import com.lantone.qc.trans.comsis.ModelDocGenerate;
|
|
|
+import com.lantone.qc.trans.comsis.Preproc;
|
|
|
+
|
|
|
+import java.util.List;
|
|
|
+import java.util.Map;
|
|
|
+
|
|
|
+/**
|
|
|
+ * @Description: 阶段小结文档生成
|
|
|
+ * @author: rengb
|
|
|
+ * @time: 2020/3/19 19:41
|
|
|
+ */
|
|
|
+public class ChangxStagesSummaryDocTrans extends ModelDocTrans {
|
|
|
+
|
|
|
+ @Override
|
|
|
+ public List<StagesSummaryDoc> extract(MedrecVo medrecVo) {
|
|
|
+ List<StagesSummaryDoc> retList = Lists.newArrayList();
|
|
|
+ List<String> contents = (List) medrecVo.getContent().get("content");
|
|
|
+ contents.forEach(content -> {
|
|
|
+ Map<String, String> structureMap =
|
|
|
+ Preproc.extract_doc_pub(
|
|
|
+ false,
|
|
|
+ ListUtil.isEmpty(medrecVo.getLabel()) ? ModelStandardKeys.stagesSummary : medrecVo.getLabel(),
|
|
|
+ content
|
|
|
+ );
|
|
|
+
|
|
|
+ StagesSummaryDoc stagesSummaryDoc = ModelDocGenerate.stagesSummaryDocGen(structureMap);
|
|
|
+ stagesSummaryDoc.setText(content);
|
|
|
+ retList.add(stagesSummaryDoc);
|
|
|
+ });
|
|
|
+ return retList;
|
|
|
+ }
|
|
|
+
|
|
|
+}
|