|
@@ -5,7 +5,11 @@ import ac.template.model.gui.HeaderVo;
|
|
|
import com.miniframe.core.ext.UtilTools;
|
|
|
import com.miniframe.mappers.ac.dao.ExtAcMapper;
|
|
|
import com.miniframe.mappers.ac.model.ProAttVo;
|
|
|
+import com.miniframe.model.system.SysFile;
|
|
|
+import com.miniframe.model.system.dao.SysFileMapper;
|
|
|
import com.miniframe.tools.XIDateTimeUtils;
|
|
|
+import com.miniframe.tools.XIFileUtils;
|
|
|
+import io.netty.util.internal.StringUtil;
|
|
|
|
|
|
import java.util.ArrayList;
|
|
|
import java.util.List;
|
|
@@ -20,6 +24,14 @@ public class TemplateServer {
|
|
|
public static List<AttVo> getProAttList(String pid,Integer astType){
|
|
|
ExtAcMapper dao = UtilTools.getBean(ExtAcMapper.class);
|
|
|
List<ProAttVo> pvs = dao.getProAttList(pid,astType);
|
|
|
+ for (ProAttVo pv :pvs) {
|
|
|
+ if(pv.getCode().equals("from_file")&& StringUtil.isNullOrEmpty(pv.getVal())&&!"0".equals(pv.getVal())){
|
|
|
+ SysFileMapper fdao = UtilTools.getBean(SysFileMapper.class);
|
|
|
+ SysFile f = fdao.selectByPrimaryKey(pv.getVal());
|
|
|
+// pv.setFilename(f.getFilename());
|
|
|
+ pv.setVal(XIFileUtils.getRootPathStr()+"/"+f.getFilepath());
|
|
|
+ }
|
|
|
+ }
|
|
|
List<AttVo> vos = new ArrayList<>();
|
|
|
List<ProAttVo> gvs=pvs.stream().filter(v-> v.getFatId().equals("0")).collect(Collectors.toList());//根数据
|
|
|
for (ProAttVo gv:gvs) {
|
|
@@ -30,6 +42,7 @@ public class TemplateServer {
|
|
|
}
|
|
|
public static AttVo getAttVo(ProAttVo gv,List<ProAttVo> pvs ){
|
|
|
AttVo vo = new AttVo();
|
|
|
+
|
|
|
vo.setVo(gv);
|
|
|
List<AttVo> svos = new ArrayList<>();
|
|
|
if(gv.getValType().equals(3)){
|