Browse Source

调整文件资料,和附件管理功能代码,移除公司代码

zjc 1 year ago
parent
commit
f8e76cfdbc

+ 1 - 7
ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/SysLoginController.java

@@ -2,8 +2,6 @@ package com.ruoyi.web.controller.system;
 
 import java.util.List;
 import java.util.Set;
-import com.ruoyi.system.domain.dhrm.DhrmCompany;
-import com.ruoyi.system.service.dhrm.IDhrmCompanyService;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.web.bind.annotation.*;
 import com.ruoyi.common.constant.Constants;
@@ -33,8 +31,6 @@ public class SysLoginController
     @Autowired
     private SysPermissionService permissionService;
 
-    @Autowired
-    private IDhrmCompanyService dhrmCompanyService;
 
     /**
      * 登录方法
@@ -83,13 +79,11 @@ public class SysLoginController
         Set<String> roles = permissionService.getRolePermission(user);
         // 权限集合
         Set<String> permissions = permissionService.getMenuPermission(user);
-        // 所属公司
-        DhrmCompany dhrmCompany = dhrmCompanyService.selectDhrmCompanyByEmployNo(user.getEmployNo());
+
         AjaxResult ajax = AjaxResult.success();
         ajax.put("user", user);
         ajax.put("roles", roles);
         ajax.put("permissions", permissions);
-        ajax.put("dhrmCompany",dhrmCompany);
         return ajax;
     }
 

+ 104 - 0
ruoyi-admin/src/main/java/com/ruoyi/web/controller/tool/TUnifyFileController.java

@@ -0,0 +1,104 @@
+package com.ruoyi.web.controller.tool;
+
+import java.util.List;
+import javax.servlet.http.HttpServletResponse;
+import org.springframework.security.access.prepost.PreAuthorize;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.GetMapping;
+import org.springframework.web.bind.annotation.PostMapping;
+import org.springframework.web.bind.annotation.PutMapping;
+import org.springframework.web.bind.annotation.DeleteMapping;
+import org.springframework.web.bind.annotation.PathVariable;
+import org.springframework.web.bind.annotation.RequestBody;
+import org.springframework.web.bind.annotation.RequestMapping;
+import org.springframework.web.bind.annotation.RestController;
+import com.ruoyi.common.annotation.Log;
+import com.ruoyi.common.core.controller.BaseController;
+import com.ruoyi.common.core.domain.AjaxResult;
+import com.ruoyi.common.enums.BusinessType;
+import com.ruoyi.tool.domain.TUnifyFile;
+import com.ruoyi.tool.service.ITUnifyFileService;
+import com.ruoyi.common.utils.poi.ExcelUtil;
+import com.ruoyi.common.core.page.TableDataInfo;
+
+/**
+ * 附件Controller
+ * 
+ * @author ruoyi
+ * @date 2024-02-23
+ */
+@RestController
+@RequestMapping("/system/file")
+public class TUnifyFileController extends BaseController
+{
+    @Autowired
+    private ITUnifyFileService tUnifyFileService;
+
+    /**
+     * 查询附件列表
+     */
+    @PreAuthorize("@ss.hasPermi('system:file:list')")
+    @GetMapping("/list")
+    public TableDataInfo list(TUnifyFile tUnifyFile)
+    {
+        startPage();
+        List<TUnifyFile> list = tUnifyFileService.selectTUnifyFileList(tUnifyFile);
+        return getDataTable(list);
+    }
+
+    /**
+     * 导出附件列表
+     */
+    @PreAuthorize("@ss.hasPermi('system:file:export')")
+    @Log(title = "附件", businessType = BusinessType.EXPORT)
+    @PostMapping("/export")
+    public void export(HttpServletResponse response, TUnifyFile tUnifyFile)
+    {
+        List<TUnifyFile> list = tUnifyFileService.selectTUnifyFileList(tUnifyFile);
+        ExcelUtil<TUnifyFile> util = new ExcelUtil<TUnifyFile>(TUnifyFile.class);
+        util.exportExcel(response, list, "附件数据");
+    }
+
+    /**
+     * 获取附件详细信息
+     */
+    @PreAuthorize("@ss.hasPermi('system:file:query')")
+    @GetMapping(value = "/{id}")
+    public AjaxResult getInfo(@PathVariable("id") String id)
+    {
+        return success(tUnifyFileService.selectTUnifyFileById(id));
+    }
+
+    /**
+     * 新增附件
+     */
+    @PreAuthorize("@ss.hasPermi('system:file:add')")
+    @Log(title = "附件", businessType = BusinessType.INSERT)
+    @PostMapping
+    public AjaxResult add(@RequestBody TUnifyFile tUnifyFile)
+    {
+        return toAjax(tUnifyFileService.insertTUnifyFile(tUnifyFile));
+    }
+
+    /**
+     * 修改附件
+     */
+    @PreAuthorize("@ss.hasPermi('system:file:edit')")
+    @Log(title = "附件", businessType = BusinessType.UPDATE)
+    @PutMapping
+    public AjaxResult edit(@RequestBody TUnifyFile tUnifyFile)
+    {
+        return toAjax(tUnifyFileService.updateTUnifyFile(tUnifyFile));
+    }
+
+    /**
+     * 删除附件
+     */
+    @PreAuthorize("@ss.hasPermi('system:file:remove')")
+    @Log(title = "附件", businessType = BusinessType.DELETE)
+	@DeleteMapping("/{ids}")
+    public AjaxResult remove(@PathVariable String[] ids)
+    {
+        return toAjax(tUnifyFileService.deleteTUnifyFileByIds(ids));
+    }
+}

+ 0 - 135
ruoyi-system/src/main/java/com/ruoyi/system/domain/dhrm/DhrmCompany.java

@@ -1,135 +0,0 @@
-package com.ruoyi.system.domain.dhrm;
-
-import org.apache.commons.lang3.builder.ToStringBuilder;
-import org.apache.commons.lang3.builder.ToStringStyle;
-import com.ruoyi.common.annotation.Excel;
-import com.ruoyi.common.core.domain.BaseEntity;
-
-/**
- * 公司管理对象 dhrm_company
- * 
- * @author ruoyi
- * @date 2023-11-16
- */
-public class DhrmCompany extends BaseEntity
-{
-    private static final long serialVersionUID = 1L;
-
-    /** $column.columnComment */
-    private Long dhrmId;
-
-    /** $column.columnComment */
-    @Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
-    private String dhrmCompanyId;
-
-    /** $column.columnComment */
-    @Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
-    private String dhrmCompanyName;
-
-    /** DSK */
-    @Excel(name = "DSK")
-    private String dhrmCompanyDsk;
-
-    /** $column.columnComment */
-    @Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
-    private String isClose;
-
-    /** 开户行 */
-    @Excel(name = "开户行")
-    private String bankName;
-
-    /** 账号 */
-    @Excel(name = "账号")
-    private String bankNum;
-
-    /** 所属公司 */
-    @Excel(name = "所属公司")
-    private String companyId;
-
-    public void setDhrmId(Long dhrmId) 
-    {
-        this.dhrmId = dhrmId;
-    }
-
-    public Long getDhrmId() 
-    {
-        return dhrmId;
-    }
-    public void setDhrmCompanyId(String dhrmCompanyId) 
-    {
-        this.dhrmCompanyId = dhrmCompanyId;
-    }
-
-    public String getDhrmCompanyId() 
-    {
-        return dhrmCompanyId;
-    }
-    public void setDhrmCompanyName(String dhrmCompanyName) 
-    {
-        this.dhrmCompanyName = dhrmCompanyName;
-    }
-
-    public String getDhrmCompanyName() 
-    {
-        return dhrmCompanyName;
-    }
-    public void setDhrmCompanyDsk(String dhrmCompanyDsk) 
-    {
-        this.dhrmCompanyDsk = dhrmCompanyDsk;
-    }
-
-    public String getDhrmCompanyDsk() 
-    {
-        return dhrmCompanyDsk;
-    }
-    public void setIsClose(String isClose) 
-    {
-        this.isClose = isClose;
-    }
-
-    public String getIsClose() 
-    {
-        return isClose;
-    }
-    public void setBankName(String bankName) 
-    {
-        this.bankName = bankName;
-    }
-
-    public String getBankName() 
-    {
-        return bankName;
-    }
-    public void setBankNum(String bankNum) 
-    {
-        this.bankNum = bankNum;
-    }
-
-    public String getBankNum() 
-    {
-        return bankNum;
-    }
-    public void setCompanyId(String companyId) 
-    {
-        this.companyId = companyId;
-    }
-
-    public String getCompanyId() 
-    {
-        return companyId;
-    }
-
-    @Override
-    public String toString() {
-        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
-            .append("dhrmId", getDhrmId())
-            .append("dhrmCompanyId", getDhrmCompanyId())
-            .append("dhrmCompanyName", getDhrmCompanyName())
-            .append("dhrmCompanyDsk", getDhrmCompanyDsk())
-            .append("isClose", getIsClose())
-            .append("bankName", getBankName())
-            .append("bankNum", getBankNum())
-            .append("companyId", getCompanyId())
-            .toString();
-    }
-}

+ 0 - 70
ruoyi-system/src/main/java/com/ruoyi/system/mapper/dhrm/DhrmCompanyMapper.java

@@ -1,70 +0,0 @@
-package com.ruoyi.system.mapper.dhrm;
-
-import com.ruoyi.system.domain.dhrm.DhrmCompany;
-
-import java.util.List;
-
-/**
- * 公司管理Mapper接口
- * 
- * @author ruoyi
- * @date 2023-11-16
- */
-public interface DhrmCompanyMapper 
-{
-    /**
-     * 查询公司管理
-     * 
-     * @param dhrmId 公司管理主键
-     * @return 公司管理
-     */
-    public DhrmCompany selectDhrmCompanyByDhrmId(Long dhrmId);
-
-    /**
-     * 查询公司管理列表
-     * 
-     * @param dhrmCompany 公司管理
-     * @return 公司管理集合
-     */
-    public List<DhrmCompany> selectDhrmCompanyList(DhrmCompany dhrmCompany);
-
-    /**
-     * 新增公司管理
-     * 
-     * @param dhrmCompany 公司管理
-     * @return 结果
-     */
-    public int insertDhrmCompany(DhrmCompany dhrmCompany);
-
-    /**
-     * 修改公司管理
-     * 
-     * @param dhrmCompany 公司管理
-     * @return 结果
-     */
-    public int updateDhrmCompany(DhrmCompany dhrmCompany);
-
-    /**
-     * 删除公司管理
-     * 
-     * @param dhrmId 公司管理主键
-     * @return 结果
-     */
-    public int deleteDhrmCompanyByDhrmId(Long dhrmId);
-
-    /**
-     * 批量删除公司管理
-     * 
-     * @param dhrmIds 需要删除的数据主键集合
-     * @return 结果
-     */
-    public int deleteDhrmCompanyByDhrmIds(Long[] dhrmIds);
-
-    /**
-     * 根据员工编号查询公司数据
-     *
-     * @param employNo
-     * @return
-     */
-    public DhrmCompany selectDhrmCompanyByEmployNo(String employNo);
-}

+ 0 - 69
ruoyi-system/src/main/java/com/ruoyi/system/service/dhrm/IDhrmCompanyService.java

@@ -1,69 +0,0 @@
-package com.ruoyi.system.service.dhrm;
-
-import com.ruoyi.system.domain.dhrm.DhrmCompany;
-
-import java.util.List;
-
-/**
- * 公司管理Service接口
- * 
- * @author ruoyi
- * @date 2023-11-16
- */
-public interface IDhrmCompanyService 
-{
-    /**
-     * 查询公司管理
-     * 
-     * @param dhrmId 公司管理主键
-     * @return 公司管理
-     */
-    public DhrmCompany selectDhrmCompanyByDhrmId(Long dhrmId);
-
-    /**
-     * 查询公司管理列表
-     * 
-     * @param dhrmCompany 公司管理
-     * @return 公司管理集合
-     */
-    public List<DhrmCompany> selectDhrmCompanyList(DhrmCompany dhrmCompany);
-
-    /**
-     * 新增公司管理
-     * 
-     * @param dhrmCompany 公司管理
-     * @return 结果
-     */
-    public int insertDhrmCompany(DhrmCompany dhrmCompany);
-
-    /**
-     * 修改公司管理
-     * 
-     * @param dhrmCompany 公司管理
-     * @return 结果
-     */
-    public int updateDhrmCompany(DhrmCompany dhrmCompany);
-
-    /**
-     * 批量删除公司管理
-     * 
-     * @param dhrmIds 需要删除的公司管理主键集合
-     * @return 结果
-     */
-    public int deleteDhrmCompanyByDhrmIds(Long[] dhrmIds);
-
-    /**
-     * 删除公司管理信息
-     * 
-     * @param dhrmId 公司管理主键
-     * @return 结果
-     */
-    public int deleteDhrmCompanyByDhrmId(Long dhrmId);
-
-    /**
-     * 根据员工编号查询公司数据
-     * @param employNo
-     * @return
-     */
-    public DhrmCompany selectDhrmCompanyByEmployNo(String employNo);
-}

+ 0 - 105
ruoyi-system/src/main/java/com/ruoyi/system/service/dhrm/impl/DhrmCompanyServiceImpl.java

@@ -1,105 +0,0 @@
-package com.ruoyi.system.service.dhrm.impl;
-
-import java.util.List;
-
-import com.ruoyi.system.domain.dhrm.DhrmCompany;
-import com.ruoyi.system.mapper.dhrm.DhrmCompanyMapper;
-import com.ruoyi.system.service.dhrm.IDhrmCompanyService;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-
-/**
- * 公司管理Service业务层处理
- * 
- * @author ruoyi
- * @date 2023-11-16
- */
-@Service
-public class DhrmCompanyServiceImpl implements IDhrmCompanyService
-{
-    @Autowired
-    private DhrmCompanyMapper dhrmCompanyMapper;
-
-    /**
-     * 查询公司管理
-     * 
-     * @param dhrmId 公司管理主键
-     * @return 公司管理
-     */
-    @Override
-    public DhrmCompany selectDhrmCompanyByDhrmId(Long dhrmId)
-    {
-        return dhrmCompanyMapper.selectDhrmCompanyByDhrmId(dhrmId);
-    }
-
-    /**
-     * 查询公司管理列表
-     * 
-     * @param dhrmCompany 公司管理
-     * @return 公司管理
-     */
-    @Override
-    public List<DhrmCompany> selectDhrmCompanyList(DhrmCompany dhrmCompany)
-    {
-        return dhrmCompanyMapper.selectDhrmCompanyList(dhrmCompany);
-    }
-
-    /**
-     * 新增公司管理
-     * 
-     * @param dhrmCompany 公司管理
-     * @return 结果
-     */
-    @Override
-    public int insertDhrmCompany(DhrmCompany dhrmCompany)
-    {
-        return dhrmCompanyMapper.insertDhrmCompany(dhrmCompany);
-    }
-
-    /**
-     * 修改公司管理
-     * 
-     * @param dhrmCompany 公司管理
-     * @return 结果
-     */
-    @Override
-    public int updateDhrmCompany(DhrmCompany dhrmCompany)
-    {
-        return dhrmCompanyMapper.updateDhrmCompany(dhrmCompany);
-    }
-
-    /**
-     * 批量删除公司管理
-     * 
-     * @param dhrmIds 需要删除的公司管理主键
-     * @return 结果
-     */
-    @Override
-    public int deleteDhrmCompanyByDhrmIds(Long[] dhrmIds)
-    {
-        return dhrmCompanyMapper.deleteDhrmCompanyByDhrmIds(dhrmIds);
-    }
-
-    /**
-     * 删除公司管理信息
-     * 
-     * @param dhrmId 公司管理主键
-     * @return 结果
-     */
-    @Override
-    public int deleteDhrmCompanyByDhrmId(Long dhrmId)
-    {
-        return dhrmCompanyMapper.deleteDhrmCompanyByDhrmId(dhrmId);
-    }
-
-    /**
-     *
-     * 根据员工编号查询公司数据
-     * @param employNo
-     * @return
-     */
-    @Override
-    public DhrmCompany selectDhrmCompanyByEmployNo(String employNo) {
-        return dhrmCompanyMapper.selectDhrmCompanyByEmployNo(employNo);
-    }
-}

+ 152 - 0
ruoyi-system/src/main/java/com/ruoyi/tool/domain/TUnifyFile.java

@@ -0,0 +1,152 @@
+package com.ruoyi.tool.domain;
+
+import org.apache.commons.lang3.builder.ToStringBuilder;
+import org.apache.commons.lang3.builder.ToStringStyle;
+import com.ruoyi.common.annotation.Excel;
+import com.ruoyi.common.core.domain.BaseEntity;
+
+/**
+ * 附件对象 t_unify_file
+ * 
+ * @author ruoyi
+ * @date 2024-02-23
+ */
+public class TUnifyFile extends BaseEntity
+{
+    private static final long serialVersionUID = 1L;
+
+    /** 主键ID */
+    private String id;
+
+    /** 文件ID */
+    @Excel(name = "文件ID")
+    private String fileId;
+
+    /** 文件名称 */
+    @Excel(name = "文件名称")
+    private String uploadName;
+
+    /** 文件类别 */
+    @Excel(name = "文件类别")
+    private String uploadType;
+
+    /** 文件地址 */
+    @Excel(name = "文件地址")
+    private String uploadPath;
+
+    /** 文件格式 */
+    @Excel(name = "文件格式")
+    private String uploadFormat;
+
+    /** 新文件名称 */
+    @Excel(name = "新文件名称")
+    private String newUploadName;
+
+    /** 状态 */
+    private String delFlag;
+
+    /** 附件业务ID */
+    @Excel(name = "附件业务ID")
+    private String fileBusinessId;
+
+    public void setId(String id) 
+    {
+        this.id = id;
+    }
+
+    public String getId() 
+    {
+        return id;
+    }
+    public void setFileId(String fileId) 
+    {
+        this.fileId = fileId;
+    }
+
+    public String getFileId() 
+    {
+        return fileId;
+    }
+    public void setUploadName(String uploadName) 
+    {
+        this.uploadName = uploadName;
+    }
+
+    public String getUploadName() 
+    {
+        return uploadName;
+    }
+    public void setUploadType(String uploadType) 
+    {
+        this.uploadType = uploadType;
+    }
+
+    public String getUploadType() 
+    {
+        return uploadType;
+    }
+    public void setUploadPath(String uploadPath) 
+    {
+        this.uploadPath = uploadPath;
+    }
+
+    public String getUploadPath() 
+    {
+        return uploadPath;
+    }
+    public void setUploadFormat(String uploadFormat) 
+    {
+        this.uploadFormat = uploadFormat;
+    }
+
+    public String getUploadFormat() 
+    {
+        return uploadFormat;
+    }
+    public void setNewUploadName(String newUploadName) 
+    {
+        this.newUploadName = newUploadName;
+    }
+
+    public String getNewUploadName() 
+    {
+        return newUploadName;
+    }
+    public void setDelFlag(String delFlag) 
+    {
+        this.delFlag = delFlag;
+    }
+
+    public String getDelFlag() 
+    {
+        return delFlag;
+    }
+    public void setFileBusinessId(String fileBusinessId) 
+    {
+        this.fileBusinessId = fileBusinessId;
+    }
+
+    public String getFileBusinessId() 
+    {
+        return fileBusinessId;
+    }
+
+    @Override
+    public String toString() {
+        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
+            .append("id", getId())
+            .append("fileId", getFileId())
+            .append("uploadName", getUploadName())
+            .append("uploadType", getUploadType())
+            .append("uploadPath", getUploadPath())
+            .append("uploadFormat", getUploadFormat())
+            .append("newUploadName", getNewUploadName())
+            .append("delFlag", getDelFlag())
+            .append("fileBusinessId", getFileBusinessId())
+            .append("createBy", getCreateBy())
+            .append("createTime", getCreateTime())
+            .append("updateBy", getUpdateBy())
+            .append("updateTime", getUpdateTime())
+            .toString();
+    }
+}

+ 61 - 0
ruoyi-system/src/main/java/com/ruoyi/tool/mapper/TUnifyFileMapper.java

@@ -0,0 +1,61 @@
+package com.ruoyi.tool.mapper;
+
+import java.util.List;
+import com.ruoyi.tool.domain.TUnifyFile;
+
+/**
+ * 附件Mapper接口
+ * 
+ * @author ruoyi
+ * @date 2024-02-23
+ */
+public interface TUnifyFileMapper 
+{
+    /**
+     * 查询附件
+     * 
+     * @param id 附件主键
+     * @return 附件
+     */
+    public TUnifyFile selectTUnifyFileById(String id);
+
+    /**
+     * 查询附件列表
+     * 
+     * @param tUnifyFile 附件
+     * @return 附件集合
+     */
+    public List<TUnifyFile> selectTUnifyFileList(TUnifyFile tUnifyFile);
+
+    /**
+     * 新增附件
+     * 
+     * @param tUnifyFile 附件
+     * @return 结果
+     */
+    public int insertTUnifyFile(TUnifyFile tUnifyFile);
+
+    /**
+     * 修改附件
+     * 
+     * @param tUnifyFile 附件
+     * @return 结果
+     */
+    public int updateTUnifyFile(TUnifyFile tUnifyFile);
+
+    /**
+     * 删除附件
+     * 
+     * @param id 附件主键
+     * @return 结果
+     */
+    public int deleteTUnifyFileById(String id);
+
+    /**
+     * 批量删除附件
+     * 
+     * @param ids 需要删除的数据主键集合
+     * @return 结果
+     */
+    public int deleteTUnifyFileByIds(String[] ids);
+}

+ 61 - 0
ruoyi-system/src/main/java/com/ruoyi/tool/service/ITUnifyFileService.java

@@ -0,0 +1,61 @@
+package com.ruoyi.tool.service;
+
+import java.util.List;
+import com.ruoyi.tool.domain.TUnifyFile;
+
+/**
+ * 附件Service接口
+ * 
+ * @author ruoyi
+ * @date 2024-02-23
+ */
+public interface ITUnifyFileService 
+{
+    /**
+     * 查询附件
+     * 
+     * @param id 附件主键
+     * @return 附件
+     */
+    public TUnifyFile selectTUnifyFileById(String id);
+
+    /**
+     * 查询附件列表
+     * 
+     * @param tUnifyFile 附件
+     * @return 附件集合
+     */
+    public List<TUnifyFile> selectTUnifyFileList(TUnifyFile tUnifyFile);
+
+    /**
+     * 新增附件
+     * 
+     * @param tUnifyFile 附件
+     * @return 结果
+     */
+    public int insertTUnifyFile(TUnifyFile tUnifyFile);
+
+    /**
+     * 修改附件
+     * 
+     * @param tUnifyFile 附件
+     * @return 结果
+     */
+    public int updateTUnifyFile(TUnifyFile tUnifyFile);
+
+    /**
+     * 批量删除附件
+     * 
+     * @param ids 需要删除的附件主键集合
+     * @return 结果
+     */
+    public int deleteTUnifyFileByIds(String[] ids);
+
+    /**
+     * 删除附件信息
+     * 
+     * @param id 附件主键
+     * @return 结果
+     */
+    public int deleteTUnifyFileById(String id);
+}

+ 98 - 0
ruoyi-system/src/main/java/com/ruoyi/tool/service/impl/TUnifyFileServiceImpl.java

@@ -0,0 +1,98 @@
+package com.ruoyi.tool.service.impl;
+
+import java.util.List;
+import com.ruoyi.common.utils.DateUtils;
+import com.ruoyi.common.utils.uuid.IdUtils;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+import com.ruoyi.tool.mapper.TUnifyFileMapper;
+import com.ruoyi.tool.domain.TUnifyFile;
+import com.ruoyi.tool.service.ITUnifyFileService;
+
+/**
+ * 附件Service业务层处理
+ * 
+ * @author ruoyi
+ * @date 2024-02-23
+ */
+@Service
+public class TUnifyFileServiceImpl implements ITUnifyFileService 
+{
+    @Autowired
+    private TUnifyFileMapper tUnifyFileMapper;
+
+    /**
+     * 查询附件
+     * 
+     * @param id 附件主键
+     * @return 附件
+     */
+    @Override
+    public TUnifyFile selectTUnifyFileById(String id)
+    {
+        return tUnifyFileMapper.selectTUnifyFileById(id);
+    }
+
+    /**
+     * 查询附件列表
+     * 
+     * @param tUnifyFile 附件
+     * @return 附件
+     */
+    @Override
+    public List<TUnifyFile> selectTUnifyFileList(TUnifyFile tUnifyFile)
+    {
+        return tUnifyFileMapper.selectTUnifyFileList(tUnifyFile);
+    }
+
+    /**
+     * 新增附件
+     * 
+     * @param tUnifyFile 附件
+     * @return 结果
+     */
+    @Override
+    public int insertTUnifyFile(TUnifyFile tUnifyFile)
+    {
+        tUnifyFile.setCreateTime(DateUtils.getNowDate());
+        tUnifyFile.setId(IdUtils.fastSimpleUUID());
+        return tUnifyFileMapper.insertTUnifyFile(tUnifyFile);
+    }
+
+    /**
+     * 修改附件
+     * 
+     * @param tUnifyFile 附件
+     * @return 结果
+     */
+    @Override
+    public int updateTUnifyFile(TUnifyFile tUnifyFile)
+    {
+        tUnifyFile.setUpdateTime(DateUtils.getNowDate());
+        return tUnifyFileMapper.updateTUnifyFile(tUnifyFile);
+    }
+
+    /**
+     * 批量删除附件
+     * 
+     * @param ids 需要删除的附件主键
+     * @return 结果
+     */
+    @Override
+    public int deleteTUnifyFileByIds(String[] ids)
+    {
+        return tUnifyFileMapper.deleteTUnifyFileByIds(ids);
+    }
+
+    /**
+     * 删除附件信息
+     * 
+     * @param id 附件主键
+     * @return 结果
+     */
+    @Override
+    public int deleteTUnifyFileById(String id)
+    {
+        return tUnifyFileMapper.deleteTUnifyFileById(id);
+    }
+}

+ 0 - 96
ruoyi-system/src/main/resources/mapper/dhrm/DhrmCompanyMapper.xml

@@ -1,96 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!DOCTYPE mapper
-PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
-"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
-<mapper namespace="com.ruoyi.system.mapper.dhrm.DhrmCompanyMapper">
-    
-    <resultMap type="DhrmCompany" id="DhrmCompanyResult">
-        <result property="dhrmId"    column="dhrm_id"    />
-        <result property="dhrmCompanyId"    column="dhrm_company_id"    />
-        <result property="dhrmCompanyName"    column="dhrm_company_name"    />
-        <result property="dhrmCompanyDsk"    column="dhrm_company_DSK"    />
-        <result property="isClose"    column="is_close"    />
-        <result property="bankName"    column="bank_name"    />
-        <result property="bankNum"    column="bank_num"    />
-        <result property="companyId"    column="companyId"    />
-    </resultMap>
-
-    <sql id="selectDhrmCompanyVo">
-        select dhrm_id, dhrm_company_id, dhrm_company_name, dhrm_company_DSK, is_close, bank_name, bank_num, companyId from dhrm_company
-    </sql>
-
-    <select id="selectDhrmCompanyList" parameterType="DhrmCompany" resultMap="DhrmCompanyResult">
-        <include refid="selectDhrmCompanyVo"/>
-        <where>  
-            <if test="dhrmCompanyId != null  and dhrmCompanyId != ''"> and dhrm_company_id = #{dhrmCompanyId}</if>
-            <if test="dhrmCompanyName != null  and dhrmCompanyName != ''"> and dhrm_company_name like concat('%', #{dhrmCompanyName}, '%')</if>
-            <if test="dhrmCompanyDsk != null  and dhrmCompanyDsk != ''"> and dhrm_company_DSK = #{dhrmCompanyDsk}</if>
-            <if test="isClose != null  and isClose != ''"> and is_close = #{isClose}</if>
-            <if test="bankName != null  and bankName != ''"> and bank_name like concat('%', #{bankName}, '%')</if>
-            <if test="bankNum != null  and bankNum != ''"> and bank_num = #{bankNum}</if>
-            <if test="companyId != null  and companyId != ''"> and companyId = #{companyId}</if>
-        </where>
-    </select>
-    
-    <select id="selectDhrmCompanyByDhrmId" parameterType="Long" resultMap="DhrmCompanyResult">
-        <include refid="selectDhrmCompanyVo"/>
-        where dhrm_id = #{dhrmId}
-    </select>
-        
-    <insert id="insertDhrmCompany" parameterType="DhrmCompany" useGeneratedKeys="true" keyProperty="dhrmId">
-        insert into dhrm_company
-        <trim prefix="(" suffix=")" suffixOverrides=",">
-            <if test="dhrmCompanyId != null and dhrmCompanyId != ''">dhrm_company_id,</if>
-            <if test="dhrmCompanyName != null">dhrm_company_name,</if>
-            <if test="dhrmCompanyDsk != null">dhrm_company_DSK,</if>
-            <if test="isClose != null">is_close,</if>
-            <if test="bankName != null">bank_name,</if>
-            <if test="bankNum != null">bank_num,</if>
-            <if test="companyId != null">companyId,</if>
-         </trim>
-        <trim prefix="values (" suffix=")" suffixOverrides=",">
-            <if test="dhrmCompanyId != null and dhrmCompanyId != ''">#{dhrmCompanyId},</if>
-            <if test="dhrmCompanyName != null">#{dhrmCompanyName},</if>
-            <if test="dhrmCompanyDsk != null">#{dhrmCompanyDsk},</if>
-            <if test="isClose != null">#{isClose},</if>
-            <if test="bankName != null">#{bankName},</if>
-            <if test="bankNum != null">#{bankNum},</if>
-            <if test="companyId != null">#{companyId},</if>
-         </trim>
-    </insert>
-
-    <update id="updateDhrmCompany" parameterType="DhrmCompany">
-        update dhrm_company
-        <trim prefix="SET" suffixOverrides=",">
-            <if test="dhrmCompanyId != null and dhrmCompanyId != ''">dhrm_company_id = #{dhrmCompanyId},</if>
-            <if test="dhrmCompanyName != null">dhrm_company_name = #{dhrmCompanyName},</if>
-            <if test="dhrmCompanyDsk != null">dhrm_company_DSK = #{dhrmCompanyDsk},</if>
-            <if test="isClose != null">is_close = #{isClose},</if>
-            <if test="bankName != null">bank_name = #{bankName},</if>
-            <if test="bankNum != null">bank_num = #{bankNum},</if>
-            <if test="companyId != null">companyId = #{companyId},</if>
-        </trim>
-        where dhrm_id = #{dhrmId}
-    </update>
-
-    <delete id="deleteDhrmCompanyByDhrmId" parameterType="Long">
-        delete from dhrm_company where dhrm_id = #{dhrmId}
-    </delete>
-
-    <delete id="deleteDhrmCompanyByDhrmIds" parameterType="String">
-        delete from dhrm_company where dhrm_id in 
-        <foreach item="dhrmId" collection="array" open="(" separator="," close=")">
-            #{dhrmId}
-        </foreach>
-    </delete>
-
-    <select id="selectDhrmCompanyByEmployNo" parameterType="String" resultMap="DhrmCompanyResult">
-        select
-            c.dhrm_id, c.dhrm_company_id, c.dhrm_company_name, c.dhrm_company_DSK, c.is_close, c.bank_name, c.bank_num, c.companyId
-        from
-            dhrm_company c
-        LEFT JOIN dhrm_employee_info e ON e.dhrm_company = c.dhrm_company_id
-        where e.employee_no = #{employNo}
-    </select>
-
-</mapper>

+ 1 - 1
ruoyi-system/src/main/resources/mapper/invest/TProjectInformationMapper.xml

@@ -2,7 +2,7 @@
 <!DOCTYPE mapper
 PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
 "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
-<mapper namespace="com.ruoyi.invest.mapper.TProjectInformationMapper">
+<mapper namespace="com.ruoyi.system.mapper.invest.TProjectInformationMapper">
     
     <resultMap type="TProjectInformation" id="TProjectInformationResult">
         <result property="id"    column="id"    />

+ 108 - 0
ruoyi-system/src/main/resources/mapper/tool/TUnifyFileMapper.xml

@@ -0,0 +1,108 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!DOCTYPE mapper
+PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
+"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.ruoyi.tool.mapper.TUnifyFileMapper">
+    
+    <resultMap type="TUnifyFile" id="TUnifyFileResult">
+        <result property="id"    column="id"    />
+        <result property="fileId"    column="file_id"    />
+        <result property="uploadName"    column="upload_name"    />
+        <result property="uploadType"    column="upload_type"    />
+        <result property="uploadPath"    column="upload_path"    />
+        <result property="uploadFormat"    column="upload_format"    />
+        <result property="newUploadName"    column="new_upload_name"    />
+        <result property="delFlag"    column="del_flag"    />
+        <result property="fileBusinessId"    column="file_business_id"    />
+        <result property="createBy"    column="create_by"    />
+        <result property="createTime"    column="create_time"    />
+        <result property="updateBy"    column="update_by"    />
+        <result property="updateTime"    column="update_time"    />
+    </resultMap>
+
+    <sql id="selectTUnifyFileVo">
+        select id, file_id, upload_name, upload_type, upload_path, upload_format, new_upload_name, del_flag, file_business_id, create_by, create_time, update_by, update_time from t_unify_file
+    </sql>
+
+    <select id="selectTUnifyFileList" parameterType="TUnifyFile" resultMap="TUnifyFileResult">
+        <include refid="selectTUnifyFileVo"/>
+        <where>  
+            <if test="fileId != null  and fileId != ''"> and file_id = #{fileId}</if>
+            <if test="uploadName != null  and uploadName != ''"> and upload_name like concat('%', #{uploadName}, '%')</if>
+            <if test="uploadType != null  and uploadType != ''"> and upload_type = #{uploadType}</if>
+            <if test="uploadPath != null  and uploadPath != ''"> and upload_path = #{uploadPath}</if>
+            <if test="uploadFormat != null  and uploadFormat != ''"> and upload_format = #{uploadFormat}</if>
+            <if test="newUploadName != null  and newUploadName != ''"> and new_upload_name like concat('%', #{newUploadName}, '%')</if>
+            <if test="fileBusinessId != null  and fileBusinessId != ''"> and file_business_id = #{fileBusinessId}</if>
+        </where>
+    </select>
+    
+    <select id="selectTUnifyFileById" parameterType="String" resultMap="TUnifyFileResult">
+        <include refid="selectTUnifyFileVo"/>
+        where id = #{id}
+    </select>
+        
+    <insert id="insertTUnifyFile" parameterType="TUnifyFile">
+        insert into t_unify_file
+        <trim prefix="(" suffix=")" suffixOverrides=",">
+            <if test="id != null">id,</if>
+            <if test="fileId != null">file_id,</if>
+            <if test="uploadName != null">upload_name,</if>
+            <if test="uploadType != null">upload_type,</if>
+            <if test="uploadPath != null">upload_path,</if>
+            <if test="uploadFormat != null">upload_format,</if>
+            <if test="newUploadName != null">new_upload_name,</if>
+            <if test="delFlag != null">del_flag,</if>
+            <if test="fileBusinessId != null">file_business_id,</if>
+            <if test="createBy != null">create_by,</if>
+            <if test="createTime != null">create_time,</if>
+            <if test="updateBy != null">update_by,</if>
+            <if test="updateTime != null">update_time,</if>
+         </trim>
+        <trim prefix="values (" suffix=")" suffixOverrides=",">
+            <if test="id != null">#{id},</if>
+            <if test="fileId != null">#{fileId},</if>
+            <if test="uploadName != null">#{uploadName},</if>
+            <if test="uploadType != null">#{uploadType},</if>
+            <if test="uploadPath != null">#{uploadPath},</if>
+            <if test="uploadFormat != null">#{uploadFormat},</if>
+            <if test="newUploadName != null">#{newUploadName},</if>
+            <if test="delFlag != null">#{delFlag},</if>
+            <if test="fileBusinessId != null">#{fileBusinessId},</if>
+            <if test="createBy != null">#{createBy},</if>
+            <if test="createTime != null">#{createTime},</if>
+            <if test="updateBy != null">#{updateBy},</if>
+            <if test="updateTime != null">#{updateTime},</if>
+         </trim>
+    </insert>
+
+    <update id="updateTUnifyFile" parameterType="TUnifyFile">
+        update t_unify_file
+        <trim prefix="SET" suffixOverrides=",">
+            <if test="fileId != null">file_id = #{fileId},</if>
+            <if test="uploadName != null">upload_name = #{uploadName},</if>
+            <if test="uploadType != null">upload_type = #{uploadType},</if>
+            <if test="uploadPath != null">upload_path = #{uploadPath},</if>
+            <if test="uploadFormat != null">upload_format = #{uploadFormat},</if>
+            <if test="newUploadName != null">new_upload_name = #{newUploadName},</if>
+            <if test="delFlag != null">del_flag = #{delFlag},</if>
+            <if test="fileBusinessId != null">file_business_id = #{fileBusinessId},</if>
+            <if test="createBy != null">create_by = #{createBy},</if>
+            <if test="createTime != null">create_time = #{createTime},</if>
+            <if test="updateBy != null">update_by = #{updateBy},</if>
+            <if test="updateTime != null">update_time = #{updateTime},</if>
+        </trim>
+        where id = #{id}
+    </update>
+
+    <delete id="deleteTUnifyFileById" parameterType="String">
+        delete from t_unify_file where id = #{id}
+    </delete>
+
+    <delete id="deleteTUnifyFileByIds" parameterType="String">
+        delete from t_unify_file where id in 
+        <foreach item="id" collection="array" open="(" separator="," close=")">
+            #{id}
+        </foreach>
+    </delete>
+</mapper>