管道基础大数据平台系统开发-【后端】-Server
1
13693261870
2023-02-05 d41cd4196d159aa819de0e800d343b7f9edc3d53
src/main/java/com/lf/server/service/all/UploadAttachService.java
@@ -6,6 +6,7 @@
import com.lf.server.entity.all.ResponseMsg;
import com.lf.server.entity.all.SettingData;
import com.lf.server.entity.all.StaticData;
import com.lf.server.entity.ctrl.KeyValueEntity;
import com.lf.server.entity.data.MetaEntity;
import com.lf.server.entity.data.MetaFileEntity;
import com.lf.server.entity.sys.AttachEntity;
@@ -166,12 +167,19 @@
    /**
     * 上传Excel附件
     */
    public Map<String, Integer> uploadXlsAnnex(List<MetaEntity> ms, List<MetaFileEntity> list, String path) {
        Map<String, Integer> map = new HashMap<>(3);
    public List<KeyValueEntity> uploadXlsAnnex(List<MetaEntity> ms, List<MetaFileEntity> list, String path) {
        List<String> files = getAttachFiles(list, path);
        if (files.size() == 0) {
            return null;
        }
        List<KeyValueEntity> rs = new ArrayList<>();
        for (MetaEntity me : ms) {
            int rows = uploadXlsAnnex(me, files);
            rs.add(new KeyValueEntity(me.getName(), String.valueOf(rows)));
        }
        return map;
        return rs;
    }
    /**
@@ -241,4 +249,13 @@
            }
        }
    }
    /**
     * 上传Excel附件
     */
    private int uploadXlsAnnex(MetaEntity me, List<String> files) {
        return 0;
    }
}