Browse Source

修改内容第一部分

dujunlong 1 year ago
parent
commit
48c80b40f3
22 changed files with 1216 additions and 39 deletions
  1. 1 1
      ruoyi-admin/src/main/resources/application.yml
  2. 18 3
      ruoyi-ent/src/main/java/com/ruoyi/enterprise/controller/EntQualificationController.java
  3. 15 1
      ruoyi-ent/src/main/java/com/ruoyi/enterprise/controller/FilesController.java
  4. 9 6
      ruoyi-ent/src/main/java/com/ruoyi/enterprise/controller/ProductController.java
  5. 104 0
      ruoyi-ent/src/main/java/com/ruoyi/enterprise/controller/SupplyController.java
  6. 3 1
      ruoyi-ent/src/main/java/com/ruoyi/enterprise/controller/TaskOutsourceController.java
  7. 226 0
      ruoyi-ent/src/main/java/com/ruoyi/enterprise/domain/Supply.java
  8. 61 0
      ruoyi-ent/src/main/java/com/ruoyi/enterprise/mapper/SupplyMapper.java
  9. 61 0
      ruoyi-ent/src/main/java/com/ruoyi/enterprise/service/ISupplyService.java
  10. 96 0
      ruoyi-ent/src/main/java/com/ruoyi/enterprise/service/impl/SupplyServiceImpl.java
  11. 158 0
      ruoyi-ent/src/main/resources/mapper/enterprise/SupplyMapper.xml
  12. 44 0
      ruoyi-ui/src/api/enterprise/supply.js
  13. 2 1
      ruoyi-ui/src/views/enterprise/checkItems/index.vue
  14. 1 1
      ruoyi-ui/src/views/enterprise/outsource/index.vue
  15. 5 4
      ruoyi-ui/src/views/enterprise/product/index.vue
  16. 11 6
      ruoyi-ui/src/views/enterprise/products/index.vue
  17. 5 4
      ruoyi-ui/src/views/enterprise/qualification/index.vue
  18. 56 4
      ruoyi-ui/src/views/enterprise/supplier/index.vue
  19. 327 0
      ruoyi-ui/src/views/enterprise/supply/index.vue
  20. 1 1
      ruoyi-ui/src/views/enterprise/tasks/index.vue
  21. 8 3
      ruoyi-ui/src/views/enterprise/tpl/index.vue
  22. 4 3
      ruoyi-ui/src/views/enterprise/type/index.vue

+ 1 - 1
ruoyi-admin/src/main/resources/application.yml

@@ -140,4 +140,4 @@ tablePrefix: t_
 
 
 prop:
-  filePath: E:/ruoyi_workspace/uploadFiles/
+  filePath: D:/ruoyi_workspace/uploadFiles/

+ 18 - 3
ruoyi-ent/src/main/java/com/ruoyi/enterprise/controller/EntQualificationController.java

@@ -44,13 +44,28 @@ public class EntQualificationController extends BaseController {
         startPage();
         List<EntQualification> list = entQualificationService.selectEntQualificationList(entQualification);
         EntQualification qualification;
+
+
+//        for (int i = 0; i < list.size(); i++) {
+//            qualification = list.get(i);
+//            Company company = companyService.selectCompanyByEntGuid(qualification.getEntGuid());
+//            if (company != null) {
+//                qualification.setEntGuid(company.getEntName());
+//                list.set(i, qualification);
+//            }
+//        }
+
+        List<EntQualification> result = new ArrayList<>();
         for (int i = 0; i < list.size(); i++) {
             qualification = list.get(i);
             Company company = companyService.selectCompanyByEntGuid(qualification.getEntGuid());
-            qualification.setEntGuid(company.getEntName());
-            list.set(i, qualification);
+            if (company != null) {
+                qualification.setEntGuid(company.getEntName());
+                result.add(qualification);
+            }
         }
-        return getDataTable(list);
+
+        return getDataTable(result);
     }
     /**
      * 导出【请填写功能名称】列表

+ 15 - 1
ruoyi-ent/src/main/java/com/ruoyi/enterprise/controller/FilesController.java

@@ -2,6 +2,7 @@ package com.ruoyi.enterprise.controller;
 
 import java.io.BufferedOutputStream;
 import java.io.File;
+import java.io.FileOutputStream;
 import java.io.IOException;
 import java.util.HashMap;
 import java.util.List;
@@ -113,12 +114,25 @@ public class FilesController extends BaseController
         String fileUUID = UUIDProvider.newUUID().toString();
         String newFileName = fileUUID + fileType;//文件名为uuid
         long size = file.getSize();//获取文件大小
-        String path = "e:/ruoyi_workspace/uploadFiles/";
+        String path = "d:/ruoyi_workspace/uploadFiles/";
+
+        // 检查目录是否存在,如果不存在则创建它
+        File dir = new File(path);
+        if (!dir.exists()) {
+            dir.mkdirs(); // 创建目录
+        }
+
+
         byte[] bytes = file.getBytes();
         String filename = path + newFileName;
 
         File file1 = new File(filename);
+        if (!file1.exists()) {
+            file1.createNewFile();
+        }
         BufferedOutputStream outputStream = new BufferedOutputStream(java.nio.file.Files.newOutputStream(file1.toPath()));
+
+
         outputStream.write(bytes);
         System.out.println("文件写入成功");
         outputStream.flush();

+ 9 - 6
ruoyi-ent/src/main/java/com/ruoyi/enterprise/controller/ProductController.java

@@ -162,13 +162,16 @@ public class ProductController extends BaseController {
     public List<Files> getFileList(@RequestBody Map fileForm) {
         List<Files> res = new ArrayList<>();
         String jsonStr = (String) fileForm.get("somefiles");
-        String[] split = jsonStr.split(",");
-        for (String fileguid : split) {
-            Files files = filesService.selectFilesByFileGuid(fileguid);
-            if (files != null)
-                res.add(files);
+        if(jsonStr != null) {
+            String[] split = jsonStr.split(",");
+            for (String fileguid : split) {
+                Files files = filesService.selectFilesByFileGuid(fileguid);
+                if (files != null)
+                    res.add(files);
+            }
+            return res;
         }
-        return res;
+        return null;
     }
     /**
      * 查询产品选择配件信息

+ 104 - 0
ruoyi-ent/src/main/java/com/ruoyi/enterprise/controller/SupplyController.java

@@ -0,0 +1,104 @@
+package com.ruoyi.enterprise.controller;
+
+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.enterprise.domain.Supply;
+import com.ruoyi.enterprise.service.ISupplyService;
+import com.ruoyi.common.utils.poi.ExcelUtil;
+import com.ruoyi.common.core.page.TableDataInfo;
+
+/**
+ * 供应商管理Controller
+ * 
+ * @author admin
+ * @date 2024-07-30
+ */
+@RestController
+@RequestMapping("/enterprise/supply")
+public class SupplyController extends BaseController
+{
+    @Autowired
+    private ISupplyService supplyService;
+
+    /**
+     * 查询供应商管理列表
+     */
+    @PreAuthorize("@ss.hasPermi('enterprise:supply:list')")
+    @GetMapping("/list")
+    public TableDataInfo list(Supply supply)
+    {
+        startPage();
+        List<Supply> list = supplyService.selectSupplyList(supply);
+        return getDataTable(list);
+    }
+
+    /**
+     * 导出供应商管理列表
+     */
+    @PreAuthorize("@ss.hasPermi('enterprise:supply:export')")
+    @Log(title = "供应商管理", businessType = BusinessType.EXPORT)
+    @PostMapping("/export")
+    public void export(HttpServletResponse response, Supply supply)
+    {
+        List<Supply> list = supplyService.selectSupplyList(supply);
+        ExcelUtil<Supply> util = new ExcelUtil<Supply>(Supply.class);
+        util.exportExcel(response, list, "供应商管理数据");
+    }
+
+    /**
+     * 获取供应商管理详细信息
+     */
+    @PreAuthorize("@ss.hasPermi('enterprise:supply:query')")
+    @RequestMapping(value = "/{sGuid}")
+    public AjaxResult getInfo(@PathVariable("sGuid") String sGuid)
+    {
+        return success(supplyService.selectSupplyBySGuid(sGuid));
+    }
+
+    /**
+     * 新增供应商管理
+     */
+    @PreAuthorize("@ss.hasPermi('enterprise:supply:add')")
+    @Log(title = "供应商管理", businessType = BusinessType.INSERT)
+    @PostMapping
+    public AjaxResult add(@RequestBody Supply supply)
+    {
+        return toAjax(supplyService.insertSupply(supply));
+    }
+
+    /**
+     * 修改供应商管理
+     */
+    @PreAuthorize("@ss.hasPermi('enterprise:supply:edit')")
+    @Log(title = "供应商管理", businessType = BusinessType.UPDATE)
+    @PutMapping
+    public AjaxResult edit(@RequestBody Supply supply)
+    {
+        return toAjax(supplyService.updateSupply(supply));
+    }
+
+    /**
+     * 删除供应商管理
+     */
+    @PreAuthorize("@ss.hasPermi('enterprise:supply:remove')")
+    @Log(title = "供应商管理", businessType = BusinessType.DELETE)
+	@DeleteMapping("/{sGuids}")
+    public AjaxResult remove(@PathVariable String[] sGuids)
+    {
+        return toAjax(supplyService.deleteSupplyBySGuids(sGuids));
+    }
+}

+ 3 - 1
ruoyi-ent/src/main/java/com/ruoyi/enterprise/controller/TaskOutsourceController.java

@@ -260,7 +260,7 @@ public class TaskOutsourceController extends BaseController {
         param.put("opt", "start");
 
         // 模拟构件实例调用平台接口
-        ComponentUtil.test001(param, "/outsource/outsource/component/"+taskOutsource.getEntguid());   // ---数据融合构件2
+//        ComponentUtil.test001(param, "/outsource/outsource/component/"+taskOutsource.getEntguid());   // ---数据融合构件2
 
         // 生成 GUIDz
         String taskout_guid = UUID.randomUUID().toString();
@@ -344,9 +344,11 @@ public class TaskOutsourceController extends BaseController {
         List<Map> stepList = new ArrayList<>();
         System.out.println(list);
         for (TaskOutsource outsource : list) {
+            // 外包厂家guid
             String entguid = outsource.getEntguid();
             if (entguid.isEmpty()) continue;
             String supplierName = companyService.selectCompanyByEntGuid(entguid).getEntName();
+            // 企业-产品guid
             String epguid = outsource.getEpguid();
             EntProducts entProducts = entProductsService.selectEntProductsByEpGuid(epguid);
             System.out.println("119+" + entProducts);

+ 226 - 0
ruoyi-ent/src/main/java/com/ruoyi/enterprise/domain/Supply.java

@@ -0,0 +1,226 @@
+package com.ruoyi.enterprise.domain;
+
+import java.util.Date;
+import com.fasterxml.jackson.annotation.JsonFormat;
+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_supply
+ * 
+ * @author admin
+ * @date 2024-07-30
+ */
+public class Supply extends BaseEntity
+{
+    private static final long serialVersionUID = 1L;
+
+    /** 主键 */
+    private String sGuid;
+
+    public String getSpName() {
+        return spName;
+    }
+
+    public void setSpName(String spName) {
+        this.spName = spName;
+    }
+
+    public String getEntName() {
+        return entName;
+    }
+
+    public void setEntName(String entName) {
+        this.entName = entName;
+    }
+
+    public String getProductName() {
+        return productName;
+    }
+
+    public void setProductName(String productName) {
+        this.productName = productName;
+    }
+
+    private String spName;
+    private String entName;
+    private String productName;
+
+    /** 企业唯一码 */
+    @Excel(name = "企业唯一码")
+    private String entGuid;
+
+    /** 企业产品唯一码,uuid类型 */
+    @Excel(name = "企业产品唯一码,uuid类型")
+    private String epGuid;
+
+    /** 供应商唯一码 */
+    @Excel(name = "供应商唯一码")
+    private String spGuid;
+
+    /** 租户id */
+    private String tenantId;
+
+    /** 删除时间 */
+    private Date deleteAt;
+
+    /** 更新时间 */
+    private Date updateAt;
+
+    /** 创建时间 */
+    private Date creatAt;
+
+    /** 创建后不变 */
+    private String rowId;
+
+    /** 每次更新变化 */
+    private String updId;
+
+    /** 删除人,uuid */
+    private String deleter;
+
+    /** 更新人,uuid */
+    private String updator;
+
+    /** 创建人,uuid */
+    private String creator;
+
+    public void setsGuid(String sGuid) 
+    {
+        this.sGuid = sGuid;
+    }
+
+    public String getsGuid() 
+    {
+        return sGuid;
+    }
+    public void setEntGuid(String entGuid) 
+    {
+        this.entGuid = entGuid;
+    }
+
+    public String getEntGuid() 
+    {
+        return entGuid;
+    }
+    public void setEpGuid(String epGuid) 
+    {
+        this.epGuid = epGuid;
+    }
+
+    public String getEpGuid() 
+    {
+        return epGuid;
+    }
+    public void setSpGuid(String spGuid) 
+    {
+        this.spGuid = spGuid;
+    }
+
+    public String getSpGuid() 
+    {
+        return spGuid;
+    }
+    public void setTenantId(String tenantId) 
+    {
+        this.tenantId = tenantId;
+    }
+
+    public String getTenantId() 
+    {
+        return tenantId;
+    }
+    public void setDeleteAt(Date deleteAt) 
+    {
+        this.deleteAt = deleteAt;
+    }
+
+    public Date getDeleteAt() 
+    {
+        return deleteAt;
+    }
+    public void setUpdateAt(Date updateAt) 
+    {
+        this.updateAt = updateAt;
+    }
+
+    public Date getUpdateAt() 
+    {
+        return updateAt;
+    }
+    public void setCreatAt(Date creatAt) 
+    {
+        this.creatAt = creatAt;
+    }
+
+    public Date getCreatAt() 
+    {
+        return creatAt;
+    }
+    public void setRowId(String rowId) 
+    {
+        this.rowId = rowId;
+    }
+
+    public String getRowId() 
+    {
+        return rowId;
+    }
+    public void setUpdId(String updId) 
+    {
+        this.updId = updId;
+    }
+
+    public String getUpdId() 
+    {
+        return updId;
+    }
+    public void setDeleter(String deleter) 
+    {
+        this.deleter = deleter;
+    }
+
+    public String getDeleter() 
+    {
+        return deleter;
+    }
+    public void setUpdator(String updator) 
+    {
+        this.updator = updator;
+    }
+
+    public String getUpdator() 
+    {
+        return updator;
+    }
+    public void setCreator(String creator) 
+    {
+        this.creator = creator;
+    }
+
+    public String getCreator() 
+    {
+        return creator;
+    }
+
+    @Override
+    public String toString() {
+        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
+            .append("sGuid", getsGuid())
+            .append("entGuid", getEntGuid())
+            .append("epGuid", getEpGuid())
+            .append("spGuid", getSpGuid())
+            .append("tenantId", getTenantId())
+            .append("deleteAt", getDeleteAt())
+            .append("updateAt", getUpdateAt())
+            .append("creatAt", getCreatAt())
+            .append("rowId", getRowId())
+            .append("updId", getUpdId())
+            .append("deleter", getDeleter())
+            .append("updator", getUpdator())
+            .append("creator", getCreator())
+            .toString();
+    }
+}

+ 61 - 0
ruoyi-ent/src/main/java/com/ruoyi/enterprise/mapper/SupplyMapper.java

@@ -0,0 +1,61 @@
+package com.ruoyi.enterprise.mapper;
+
+import java.util.List;
+import com.ruoyi.enterprise.domain.Supply;
+
+/**
+ * 供应商管理Mapper接口
+ * 
+ * @author admin
+ * @date 2024-07-30
+ */
+public interface SupplyMapper 
+{
+    /**
+     * 查询供应商管理
+     * 
+     * @param sGuid 供应商管理主键
+     * @return 供应商管理
+     */
+    public Supply selectSupplyBySGuid(String sGuid);
+
+    /**
+     * 查询供应商管理列表
+     * 
+     * @param supply 供应商管理
+     * @return 供应商管理集合
+     */
+    public List<Supply> selectSupplyList(Supply supply);
+
+    /**
+     * 新增供应商管理
+     * 
+     * @param supply 供应商管理
+     * @return 结果
+     */
+    public int insertSupply(Supply supply);
+
+    /**
+     * 修改供应商管理
+     * 
+     * @param supply 供应商管理
+     * @return 结果
+     */
+    public int updateSupply(Supply supply);
+
+    /**
+     * 删除供应商管理
+     * 
+     * @param sGuid 供应商管理主键
+     * @return 结果
+     */
+    public int deleteSupplyBySGuid(String sGuid);
+
+    /**
+     * 批量删除供应商管理
+     * 
+     * @param sGuids 需要删除的数据主键集合
+     * @return 结果
+     */
+    public int deleteSupplyBySGuids(String[] sGuids);
+}

+ 61 - 0
ruoyi-ent/src/main/java/com/ruoyi/enterprise/service/ISupplyService.java

@@ -0,0 +1,61 @@
+package com.ruoyi.enterprise.service;
+
+import java.util.List;
+import com.ruoyi.enterprise.domain.Supply;
+
+/**
+ * 供应商管理Service接口
+ * 
+ * @author admin
+ * @date 2024-07-30
+ */
+public interface ISupplyService 
+{
+    /**
+     * 查询供应商管理
+     * 
+     * @param sGuid 供应商管理主键
+     * @return 供应商管理
+     */
+    public Supply selectSupplyBySGuid(String sGuid);
+
+    /**
+     * 查询供应商管理列表
+     * 
+     * @param supply 供应商管理
+     * @return 供应商管理集合
+     */
+    public List<Supply> selectSupplyList(Supply supply);
+
+    /**
+     * 新增供应商管理
+     * 
+     * @param supply 供应商管理
+     * @return 结果
+     */
+    public int insertSupply(Supply supply);
+
+    /**
+     * 修改供应商管理
+     * 
+     * @param supply 供应商管理
+     * @return 结果
+     */
+    public int updateSupply(Supply supply);
+
+    /**
+     * 批量删除供应商管理
+     * 
+     * @param sGuids 需要删除的供应商管理主键集合
+     * @return 结果
+     */
+    public int deleteSupplyBySGuids(String[] sGuids);
+
+    /**
+     * 删除供应商管理信息
+     * 
+     * @param sGuid 供应商管理主键
+     * @return 结果
+     */
+    public int deleteSupplyBySGuid(String sGuid);
+}

+ 96 - 0
ruoyi-ent/src/main/java/com/ruoyi/enterprise/service/impl/SupplyServiceImpl.java

@@ -0,0 +1,96 @@
+package com.ruoyi.enterprise.service.impl;
+
+import java.util.List;
+
+import com.ruoyi.enterprise.utils.UUIDProvider;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+import com.ruoyi.enterprise.mapper.SupplyMapper;
+import com.ruoyi.enterprise.domain.Supply;
+import com.ruoyi.enterprise.service.ISupplyService;
+
+/**
+ * 供应商管理Service业务层处理
+ * 
+ * @author admin
+ * @date 2024-07-30
+ */
+@Service
+public class SupplyServiceImpl implements ISupplyService 
+{
+    @Autowired
+    private SupplyMapper supplyMapper;
+
+    /**
+     * 查询供应商管理
+     * 
+     * @param sGuid 供应商管理主键
+     * @return 供应商管理
+     */
+    @Override
+    public Supply selectSupplyBySGuid(String sGuid)
+    {
+        return supplyMapper.selectSupplyBySGuid(sGuid);
+    }
+
+    /**
+     * 查询供应商管理列表
+     * 
+     * @param supply 供应商管理
+     * @return 供应商管理
+     */
+    @Override
+    public List<Supply> selectSupplyList(Supply supply)
+    {
+        return supplyMapper.selectSupplyList(supply);
+    }
+
+    /**
+     * 新增供应商管理
+     * 
+     * @param supply 供应商管理
+     * @return 结果
+     */
+    @Override
+    public int insertSupply(Supply supply)
+    {
+        supply.setsGuid(UUIDProvider.newUUID().toString());
+        return supplyMapper.insertSupply(supply);
+    }
+
+    /**
+     * 修改供应商管理
+     * 
+     * @param supply 供应商管理
+     * @return 结果
+     */
+    @Override
+    public int updateSupply(Supply supply)
+    {
+        return supplyMapper.updateSupply(supply);
+    }
+
+    /**
+     * 批量删除供应商管理
+     * 
+     * @param sGuids 需要删除的供应商管理主键
+     * @return 结果
+     */
+    @Override
+    public int deleteSupplyBySGuids(String[] sGuids)
+    {
+        return supplyMapper.deleteSupplyBySGuids(sGuids);
+    }
+
+    /**
+     * 删除供应商管理信息
+     * 
+     * @param sGuid 供应商管理主键
+     * @return 结果
+     */
+    @Override
+    public int deleteSupplyBySGuid(String sGuid)
+    {
+        return supplyMapper.deleteSupplyBySGuid(sGuid);
+    }
+}

+ 158 - 0
ruoyi-ent/src/main/resources/mapper/enterprise/SupplyMapper.xml

@@ -0,0 +1,158 @@
+<?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.enterprise.mapper.SupplyMapper">
+    
+    <resultMap type="Supply" id="SupplyResult">
+        <result property="sGuid"    column="s_guid"    />
+        <result property="entGuid"    column="ent_guid"    />
+        <result property="epGuid"    column="ep_guid"    />
+        <result property="spGuid"    column="sp_guid"    />
+        <result property="tenantId"    column="tenantId"    />
+        <result property="deleteAt"    column="delete_at"    />
+        <result property="updateAt"    column="update_at"    />
+        <result property="creatAt"    column="creat_at"    />
+        <result property="rowId"    column="row_id"    />
+        <result property="updId"    column="upd_id"    />
+        <result property="deleter"    column="deleter"    />
+        <result property="updator"    column="updator"    />
+        <result property="creator"    column="creator"    />
+        <result property="spName"    column="sp_name"    />
+        <result property="entName"    column="ent_name"    />
+        <result property="productName"    column="product_name"    />
+    </resultMap>
+
+    <sql id="selectSupplyVo">
+        select s_guid, ent_guid, ep_guid, sp_guid, tenantId, delete_at, update_at, creat_at, row_id, upd_id, deleter, updator, creator from t_supply
+    </sql>
+
+    <sql id="XQuery">
+        SELECT ROW_NUMBER() OVER (ORDER BY t_supply.s_guid) AS id, t_supply.s_guid AS s_guid, t_supply.ep_guid AS ep_guid, t_company.ent_name AS sp_name
+        FROM t_company
+        INNER JOIN t_supply ON t_supply.sp_guid = t_company.ent_guid
+        <where>
+            <if test="spGuid != null">
+                AND t_supply.sp_guid = #{spGuid}
+            </if>
+        </where>
+    </sql>
+
+    <sql id="YQuery">
+        SELECT ROW_NUMBER() OVER (ORDER BY t_supply.s_guid) AS id, t_company.ent_name AS ent_name
+        FROM t_ent_products
+        INNER JOIN t_supply ON t_supply.ep_guid = t_ent_products.ep_guid
+        INNER JOIN t_company ON t_ent_products.entguid = t_company.ent_guid
+        <where>
+            <if test="spGuid != null">
+                AND t_supply.sp_guid = #{spGuid}
+            </if>
+        </where>
+    </sql>
+
+    <sql id="ZQuery">
+        SELECT ROW_NUMBER() OVER (ORDER BY t_supply.s_guid) AS id, t_product.product_name AS product_name
+        FROM t_ent_products
+        INNER JOIN t_supply ON t_supply.ep_guid = t_ent_products.ep_guid
+        INNER JOIN t_product ON t_ent_products.proguid = t_product.product_guid
+        <where>
+            <if test="spGuid != null">
+                AND t_supply.sp_guid = #{spGuid}
+            </if>
+        </where>
+    </sql>
+
+    <select id="selectSupplyList" parameterType="Supply" resultMap="SupplyResult">
+        WITH X AS (
+        <include refid="XQuery"/>
+            ),
+            Y AS (
+        <include refid="YQuery"/>
+            ),
+            Z AS (
+        <include refid="ZQuery"/>
+            )
+        SELECT X.sp_name, X.s_guid, X.ep_guid, Y.ent_name, Z.product_name
+        FROM X
+                 LEFT JOIN Y ON X.id = Y.id
+                 LEFT JOIN Z ON X.id = Z.id
+    </select>
+
+<!--    <select id="selectSupplyList" parameterType="Supply" resultMap="SupplyResult">-->
+<!--        <include refid="selectSupplyVo"/>-->
+<!--        <where>  -->
+<!--            <if test="entGuid != null  and entGuid != ''"> and ent_guid = #{entGuid}</if>-->
+<!--            <if test="epGuid != null  and epGuid != ''"> and ep_guid = #{epGuid}</if>-->
+<!--            <if test="spGuid != null  and spGuid != ''"> and sp_guid = #{spGuid}</if>-->
+<!--        </where>-->
+<!--    </select>-->
+    
+    <select id="selectSupplyBySGuid" parameterType="String" resultMap="SupplyResult">
+        <include refid="selectSupplyVo"/>
+        where s_guid = #{sGuid}
+    </select>
+        
+    <insert id="insertSupply" parameterType="Supply">
+        insert into t_supply
+        <trim prefix="(" suffix=")" suffixOverrides=",">
+            <if test="sGuid != null">s_guid,</if>
+            <if test="entGuid != null">ent_guid,</if>
+            <if test="epGuid != null">ep_guid,</if>
+            <if test="spGuid != null">sp_guid,</if>
+            <if test="tenantId != null">tenantId,</if>
+            <if test="deleteAt != null">delete_at,</if>
+            <if test="updateAt != null">update_at,</if>
+            <if test="creatAt != null">creat_at,</if>
+            <if test="rowId != null">row_id,</if>
+            <if test="updId != null">upd_id,</if>
+            <if test="deleter != null">deleter,</if>
+            <if test="updator != null">updator,</if>
+            <if test="creator != null">creator,</if>
+         </trim>
+        <trim prefix="values (" suffix=")" suffixOverrides=",">
+            <if test="sGuid != null">#{sGuid},</if>
+            <if test="entGuid != null">#{entGuid},</if>
+            <if test="epGuid != null">#{epGuid},</if>
+            <if test="spGuid != null">#{spGuid},</if>
+            <if test="tenantId != null">#{tenantId},</if>
+            <if test="deleteAt != null">#{deleteAt},</if>
+            <if test="updateAt != null">#{updateAt},</if>
+            <if test="creatAt != null">#{creatAt},</if>
+            <if test="rowId != null">#{rowId},</if>
+            <if test="updId != null">#{updId},</if>
+            <if test="deleter != null">#{deleter},</if>
+            <if test="updator != null">#{updator},</if>
+            <if test="creator != null">#{creator},</if>
+         </trim>
+    </insert>
+
+    <update id="updateSupply" parameterType="Supply">
+        update t_supply
+        <trim prefix="SET" suffixOverrides=",">
+            <if test="entGuid != null">ent_guid = #{entGuid},</if>
+            <if test="epGuid != null">ep_guid = #{epGuid},</if>
+            <if test="spGuid != null">sp_guid = #{spGuid},</if>
+            <if test="tenantId != null">tenantId = #{tenantId},</if>
+            <if test="deleteAt != null">delete_at = #{deleteAt},</if>
+            <if test="updateAt != null">update_at = #{updateAt},</if>
+            <if test="creatAt != null">creat_at = #{creatAt},</if>
+            <if test="rowId != null">row_id = #{rowId},</if>
+            <if test="updId != null">upd_id = #{updId},</if>
+            <if test="deleter != null">deleter = #{deleter},</if>
+            <if test="updator != null">updator = #{updator},</if>
+            <if test="creator != null">creator = #{creator},</if>
+        </trim>
+        where s_guid = #{sGuid}
+    </update>
+
+    <delete id="deleteSupplyBySGuid" parameterType="String">
+        delete from t_supply where s_guid = #{sGuid}
+    </delete>
+
+    <delete id="deleteSupplyBySGuids" parameterType="String">
+        delete from t_supply where s_guid in 
+        <foreach item="sGuid" collection="array" open="(" separator="," close=")">
+            #{sGuid}
+        </foreach>
+    </delete>
+</mapper>

+ 44 - 0
ruoyi-ui/src/api/enterprise/supply.js

@@ -0,0 +1,44 @@
+import request from '@/utils/request'
+
+// 查询供应商管理列表
+export function listSupply(query) {
+  return request({
+    url: '/enterprise/supply/list',
+    method: 'get',
+    params: query
+  })
+}
+
+// 查询供应商管理详细
+export function getSupply(sGuid) {
+  return request({
+    url: '/enterprise/supply/' + sGuid,
+    method: 'get'
+  })
+}
+
+// 新增供应商管理
+export function addSupply(data) {
+  return request({
+    url: '/enterprise/supply',
+    method: 'post',
+    data: data
+  })
+}
+
+// 修改供应商管理
+export function updateSupply(data) {
+  return request({
+    url: '/enterprise/supply',
+    method: 'put',
+    data: data
+  })
+}
+
+// 删除供应商管理
+export function delSupply(sGuid) {
+  return request({
+    url: '/enterprise/supply/' + sGuid,
+    method: 'delete'
+  })
+}

+ 2 - 1
ruoyi-ui/src/views/enterprise/checkItems/index.vue

@@ -81,8 +81,9 @@
       <el-table-column type="selection" width="55" align="center" />
 <!--      <el-table-column label="供方考查项目guid" align="center" prop="checkItemGuid" />-->
       <el-table-column label="供方评审项目" align="center" prop="inspectItemGuid" />
-      <el-table-column label="考查项目名称" align="center" prop="checkName" />
       <el-table-column label="序号" align="center" prop="innerOrder" />
+      <el-table-column label="考查项目名称" align="center" prop="checkName" />
+
       <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
         <template slot-scope="scope">
           <el-button

+ 1 - 1
ruoyi-ui/src/views/enterprise/outsource/index.vue

@@ -398,7 +398,7 @@ export default {
     /** 删除按钮操作 */
     handleDelete(row) {
       const taskoutGuids = row.taskoutGuid || this.ids;
-      this.$modal.confirm('是否确认删除【请填写功能名称】编号为"' + taskoutGuids + '"的数据项?').then(function () {
+      this.$modal.confirm('是否确认删除生产任务号为"' + taskoutGuids + '"的数据项?').then(function () {
         return delOutsource(taskoutGuids);
       }).then(() => {
         this.getList();

+ 5 - 4
ruoyi-ui/src/views/enterprise/product/index.vue

@@ -321,7 +321,7 @@ export default {
     },
     // 多选框选中数据
     handleSelectionChange(selection) {
-      this.ids = selection.map((item) => item.productGuid);
+      this.ids = selection.map((item) => item.productName);
       this.single = selection.length !== 1;
       this.multiple = !selection.length;
     },
@@ -407,9 +407,10 @@ export default {
     },
     /** 删除按钮操作 */
     handleDelete(row) {
-      const productGuids = row.productGuid || this.ids;
+      console.log(row)
+      const productGuids = row.productName || this.ids;
       this.$modal
-        .confirm('是否确认删除编号为"' + productGuids + '"的数据项?')
+        .confirm('是否确认删除产品名称为"' + productGuids + '"的数据项?')
         .then(function () {
           return delProduct(productGuids);
         })
@@ -452,7 +453,7 @@ export default {
     },
     /**删除文件 */
     handleDeleteFile(row) {
-      this.$modal.confirm('是否确认删除编号为"' + row.fileGuid + '"的数据项?').then(function () {
+      this.$modal.confirm('是否确认删除名为"' + row.originName + '"的文件?').then(function () {
         delFiles(row.fileGuid);
       }).then(() => {
         this.handleEditFiles(this.edit_row);

+ 11 - 6
ruoyi-ui/src/views/enterprise/products/index.vue

@@ -117,7 +117,7 @@
           <el-input v-model="form.proguid" placeholder="请输入产品代码" />
         </el-form-item> -->
         <el-form-item label="产品" prop="proguid">
-          <el-select v-model="form.proguid" class="m-2" placeholder="选择企业群" size="large" style="width: 360px;">
+          <el-select v-model="form.proguid" class="m-2" placeholder="选择产品" size="large" style="width: 360px;">
             <el-option v-for="item in productList" :key="item.productGuid" :label="item.productName"
               :value="item.productGuid" />
           </el-select>
@@ -260,6 +260,8 @@ export default {
   methods: {
     /** 查询【请填写功能名称】列表 */
     getList() {
+      console.log(111)
+      console.log(this.queryParams)
       this.loading = true;
       listProducts(this.queryParams).then((response) => {
         this.productsList = response.rows;
@@ -315,7 +317,7 @@ export default {
     },
     // 多选框选中数据
     handleSelectionChange(selection) {
-      this.ids = selection.map((item) => item.epGuid);
+      this.ids = selection.map((item) => item.proguid);
       this.single = selection.length !== 1;
       this.multiple = !selection.length;
     },
@@ -380,10 +382,11 @@ export default {
     },
     /** 删除按钮操作 */
     handleDelete(row) {
-      const epGuids = row.epGuid || this.ids;
+      console.log(row)
+      const epGuids = row.proguid || this.ids;
       this.$modal
         .confirm(
-          '是否确认删除【请填写功能名称】编号为"' + epGuids + '"的数据项?'
+          '是否确认删除产品名称为"' + epGuids + '"的数据项?'
         )
         .then(function () {
           return delProducts(epGuids);
@@ -396,10 +399,11 @@ export default {
     },
     /** 企业删除按钮操作 */
     handleCompanyDelete(row) {
+      console.log(row)
       const epeGuids = row.epeGuid || this.ids;
       this.$modal
         .confirm(
-          '是否确认删除【请填写功能名称】编号为"' + epeGuids + '"的数据项?'
+          '是否确认删除名称为"' + epeGuids + '"的数据项?'
         )
         .then(function () {
           return delEnt(epeGuids);
@@ -469,8 +473,9 @@ export default {
     },
     /**删除文件 */
     handleDeleteFile(row) {
+      console.log(row)
       this.$modal
-        .confirm('是否确认删除编号为"' + row.fileGuid + '"的数据项?')
+        .confirm('是否确认删除名称为"' + row.originName + '"的文件?')
         .then(function () {
           delFiles(row.fileGuid);
         })

+ 5 - 4
ruoyi-ui/src/views/enterprise/qualification/index.vue

@@ -108,7 +108,7 @@ export default {
     return {
       //文件上传组件测试
       uploadOpen: false,
-      //文件类型: 
+      //文件类型:
       fileType: ['doc', 'jpg', 'png'],
       //已经上传的文件信息列表
       uploadedFiles: [],
@@ -202,7 +202,7 @@ export default {
     },
     // 多选框选中数据
     handleSelectionChange(selection) {
-      this.ids = selection.map(item => item.qualGuid)
+      this.ids = selection.map(item => item.entGuid)
       this.single = selection.length !== 1
       this.multiple = !selection.length
     },
@@ -260,8 +260,9 @@ export default {
     },
     /** 删除按钮操作 */
     handleDelete(row) {
-      const qualGuids = row.qualGuid || this.ids;
-      this.$modal.confirm('是否确认删除编号为"' + qualGuids + '"的数据项?').then(function () {
+      console.log(row)
+      const qualGuids = row.entGuid || this.ids;
+      this.$modal.confirm('是否确认删除资质对应的企业为"' + qualGuids + '"的数据项?').then(function () {
         return delQualification(qualGuids);
       }).then(() => {
         this.getList();

+ 56 - 4
ruoyi-ui/src/views/enterprise/supplier/index.vue

@@ -1,5 +1,39 @@
 <template>
   <div class="app-container">
+    <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
+      <el-form-item label="企业名称" prop="entName">
+        <el-input v-model="queryParams.entName" placeholder="请输入企业名称" clearable @keyup.enter.native="handleQuery" />
+      </el-form-item>
+      <el-form-item label="产品名称" prop="taxNumber">
+        <el-input v-model="queryParams.taxNumber" placeholder="请输入企业税号" clearable @keyup.enter.native="handleQuery" />
+      </el-form-item>
+      <el-form-item label="供应商名称" prop="legalRepres" label-width="100px">
+        <el-input v-model="queryParams.legalRepres" placeholder="请输入法定代表人" clearable @keyup.enter.native="handleQuery" />
+      </el-form-item>
+      <el-form-item>
+        <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
+        <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
+      </el-form-item>
+    </el-form>
+    <el-row :gutter="10" class="mb8">
+      <el-col :span="1.5">
+        <el-button type="primary" plain icon="el-icon-plus" size="mini" @click="handleAdd"
+                   v-hasPermi="['enterprise:company:add']">新增</el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button type="success" plain icon="el-icon-edit" size="mini" :disabled="single" @click="handleUpdate"
+                   v-hasPermi="['enterprise:company:edit']">修改</el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button type="danger" plain icon="el-icon-delete" size="mini" :disabled="multiple" @click="handleDelete"
+                   v-hasPermi="['enterprise:company:remove']">删除</el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button type="warning" plain icon="el-icon-download" size="mini" @click="handleExport"
+                   v-hasPermi="['enterprise:company:export']">导出</el-button>
+      </el-col>
+      <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
+    </el-row>
     <el-table :data="supplierList" @selection-change="handleSelectionChange">
       <el-table-column type="selection" width="55" align="center" />
       <el-table-column label="企业名称" align="center" prop="entName" />
@@ -11,11 +45,14 @@
 
 <script>
 import { getSupplierdata } from "@/api/enterprise/outsource";
+import {listCompany} from "@/api/enterprise/company";
 
 export default {
   name: "Supplier",
   data() {
     return {
+      // 显示搜索条件
+      showSearch: true,
       supplierList: [],
       queryParams: {
         pageNum: 1,
@@ -41,13 +78,28 @@ export default {
     };
   },
   created() {
-    getSupplierdata(this.queryParams).then((res) => {
-      console.log(res);
-      this.supplierList = res.data.stepList;
-    });
+    // getSupplierdata(this.queryParams).then((res) => {
+    //   console.log(res);
+    //   this.supplierList = res.data.stepList;
+    // });
+    this.getList()
   },
   methods: {
     handleSelectionChange() { },
+    /** 查询数据 */
+    getList() {
+      this.loading = true;
+      getSupplierdata(this.queryParams).then((res) => {
+        console.log(res);
+        this.supplierList = res.data.stepList;
+        this.loading = false
+      });
+    },
+    /** 搜索按钮操作 */
+    handleQuery() {
+      this.queryParams.pageNum = 1;
+      this.getList();
+    },
   },
 };
 </script>

+ 327 - 0
ruoyi-ui/src/views/enterprise/supply/index.vue

@@ -0,0 +1,327 @@
+<template>
+  <div class="app-container">
+    <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
+<!--      <el-form-item label="企业" prop="entGuid">-->
+<!--        <el-input-->
+<!--          v-model="queryParams.entGuid"-->
+<!--          placeholder="请输入企业唯一码"-->
+<!--          clearable-->
+<!--          @keyup.enter.native="handleQuery"-->
+<!--        />-->
+<!--      </el-form-item>-->
+<!--      <el-form-item label="企业产品" prop="epGuid">-->
+<!--        <el-input-->
+<!--          v-model="queryParams.epGuid"-->
+<!--          placeholder="请输入企业产品唯一码,uuid类型"-->
+<!--          clearable-->
+<!--          @keyup.enter.native="handleQuery"-->
+<!--        />-->
+<!--      </el-form-item>-->
+<!--      <el-form-item label="供应商" prop="spGuid">-->
+<!--        <el-input-->
+<!--          v-model="queryParams.spGuid"-->
+<!--          placeholder="请输入供应商唯一码"-->
+<!--          clearable-->
+<!--          @keyup.enter.native="handleQuery"-->
+<!--        />-->
+<!--      </el-form-item>-->
+      <el-form-item label="供应商" prop="entGuid">
+        <el-select v-model="queryParams.spGuid" class="m-2" placeholder="选择供应商" size="large">
+          <el-option v-for="item in ents" :key="item.value" :label="item.label" :value="item.value" />
+        </el-select>
+      </el-form-item>
+      <el-form-item>
+        <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
+        <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
+      </el-form-item>
+    </el-form>
+
+    <el-row :gutter="10" class="mb8">
+      <el-col :span="1.5">
+        <el-button
+          type="primary"
+          plain
+          icon="el-icon-plus"
+          size="mini"
+          @click="handleAdd"
+          v-hasPermi="['enterprise:supply:add']"
+        >新增</el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="success"
+          plain
+          icon="el-icon-edit"
+          size="mini"
+          :disabled="single"
+          @click="handleUpdate"
+          v-hasPermi="['enterprise:supply:edit']"
+        >修改</el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="danger"
+          plain
+          icon="el-icon-delete"
+          size="mini"
+          :disabled="multiple"
+          @click="handleDelete"
+          v-hasPermi="['enterprise:supply:remove']"
+        >删除</el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="warning"
+          plain
+          icon="el-icon-download"
+          size="mini"
+          @click="handleExport"
+          v-hasPermi="['enterprise:supply:export']"
+        >导出</el-button>
+      </el-col>
+      <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
+    </el-row>
+
+    <el-table v-loading="loading" :data="supplyList" @selection-change="handleSelectionChange">
+      <el-table-column type="selection" width="55" align="center" />
+      <el-table-column label="企业" align="center" prop="entName" />
+      <el-table-column label="企业产品" align="center" prop="productName" />
+      <el-table-column label="供应商" align="center" prop="spName" />
+      <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
+        <template slot-scope="scope">
+          <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-edit"
+            @click="handleUpdate(scope.row)"
+            v-hasPermi="['enterprise:supply:edit']"
+          >修改</el-button>
+          <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-delete"
+            @click="handleDelete(scope.row)"
+            v-hasPermi="['enterprise:supply:remove']"
+          >删除</el-button>
+        </template>
+      </el-table-column>
+    </el-table>
+
+    <pagination
+      v-show="total>0"
+      :total="total"
+      :page.sync="queryParams.pageNum"
+      :limit.sync="queryParams.pageSize"
+      @pagination="getList"
+    />
+
+    <!-- 添加或修改供应商管理对话框 -->
+    <el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
+      <el-form ref="form" :model="form" :rules="rules" label-width="80px">
+        <el-form-item label="企业" prop="epGuid">
+          <el-select v-model="form.epGuid" class="m-2" placeholder="选择企业及产品" size="large" style="width: 360px;">
+            <el-option v-for="item in epList" :key="item.epGuid" :label="item.entguid+' : '+item.proguid" :value="item.epGuid" />
+          </el-select>
+        </el-form-item>
+<!--        <el-form-item label="企业产品" prop="epGuid">-->
+<!--          <el-input v-model="form.epGuid" placeholder="请输入企业产品唯一码,uuid类型" />-->
+<!--        </el-form-item>-->
+        <el-form-item label="供应商" prop="spGuid">
+          <el-select v-model="form.spGuid" class="m-2" placeholder="选择供应商" size="large" style="width: 360px;">
+            <el-option v-for="item in companyList" :key="item.entGuid" :label="item.entName" :value="item.entGuid" />
+          </el-select>
+        </el-form-item>
+      </el-form>
+      <div slot="footer" class="dialog-footer">
+        <el-button type="primary" @click="submitForm">确 定</el-button>
+        <el-button @click="cancel">取 消</el-button>
+      </div>
+    </el-dialog>
+  </div>
+</template>
+
+<script>
+import { listSupply, getSupply, delSupply, addSupply, updateSupply } from "@/api/enterprise/supply";
+import {listCompany} from "@/api/enterprise/company";
+import {listProducts} from "@/api/enterprise/products";
+import {getSelectList} from "@/api/enterprise/enterprise";
+
+export default {
+  name: "Supply",
+  data() {
+    return {
+      //供应商列表
+      companyList: [],
+      // 企业产品列表
+      epList: [],
+      //企业列表
+      ents: [],
+
+      // 遮罩层
+      loading: true,
+      // 选中数组
+      ids: [],
+      // 选中数组名称
+      idNames: [],
+      // 非单个禁用
+      single: true,
+      // 非多个禁用
+      multiple: true,
+      // 显示搜索条件
+      showSearch: true,
+      // 总条数
+      total: 0,
+      // 供应商管理表格数据
+      supplyList: [],
+      // 弹出层标题
+      title: "",
+      // 是否显示弹出层
+      open: false,
+      // 查询参数
+      queryParams: {
+        pageNum: 1,
+        pageSize: 10,
+        entGuid: null,
+        epGuid: null,
+        spGuid: null,
+      },
+      // 表单参数
+      form: {},
+      // 表单校验
+      rules: {
+      }
+    };
+  },
+  created() {
+    this.getList();
+  },
+  methods: {
+    /** 查询供应商管理列表 */
+    getList() {
+      this.loading = true;
+      listSupply(this.queryParams).then(response => {
+        console.log(response)
+        this.supplyList = response.rows;
+        this.total = response.total;
+        this.loading = false;
+      });
+
+      listCompany().then((response) => {
+        this.companyList = response.rows;
+      });
+
+      listProducts().then(res=>{
+        console.log(888)
+        console.log(res)
+        this.epList = res.rows;
+      })
+
+      getSelectList({}).then(res => {
+        this.groups = res.groups;
+        this.ents = res.ents
+      })
+
+
+    },
+    // 取消按钮
+    cancel() {
+      this.open = false;
+      this.reset();
+    },
+    // 表单重置
+    reset() {
+      this.form = {
+        sGuid: null,
+        entGuid: null,
+        epGuid: null,
+        spGuid: null,
+        tenantId: null,
+        deleteAt: null,
+        updateAt: null,
+        creatAt: null,
+        rowId: null,
+        updId: null,
+        deleter: null,
+        updator: null,
+        creator: null
+      };
+      this.resetForm("form");
+    },
+    /** 搜索按钮操作 */
+    handleQuery() {
+      this.queryParams.pageNum = 1;
+      this.getList();
+    },
+    /** 重置按钮操作 */
+    resetQuery() {
+      this.resetForm("queryForm");
+      this.handleQuery();
+    },
+    // 多选框选中数据
+    handleSelectionChange(selection) {
+      this.ids = selection.map(item => item.sGuid)
+      this.idNames = selection.map(item => item.spName)
+      this.single = selection.length!==1
+      this.multiple = !selection.length
+    },
+    /** 新增按钮操作 */
+    handleAdd() {
+      this.reset();
+      this.open = true;
+      this.title = "添加供应商管理";
+    },
+    /** 修改按钮操作 */
+    handleUpdate(row) {
+      this.reset();
+      const sGuid = row.sGuid
+      console.log(11234123111)
+      console.log(row)
+      getSupply(sGuid).then(response => {
+        console.log(response)
+        this.form = response.data;
+        console.log(this.form)
+        this.open = true;
+        this.title = "修改供应商管理";
+      });
+    },
+    /** 提交按钮 */
+    submitForm() {
+      this.$refs["form"].validate(valid => {
+        if (valid) {
+          if (this.form.sGuid != null) {
+            updateSupply(this.form).then(response => {
+              this.$modal.msgSuccess("修改成功");
+              this.open = false;
+              this.getList();
+            });
+          } else {
+            addSupply(this.form).then(response => {
+              this.$modal.msgSuccess("新增成功");
+              this.open = false;
+              this.getList();
+            });
+          }
+        }
+      });
+    },
+    /** 删除按钮操作 */
+    handleDelete(row) {
+      console.log(row)
+      const sGuids = row.sGuid || this.ids;
+      const sGuidName = row.spName || this.idNames
+      this.$modal.confirm('是否确认删除供应商为"' + sGuidName + '"的数据项?').then(function() {
+        return delSupply(sGuids);
+      }).then(() => {
+        this.getList();
+        this.$modal.msgSuccess("删除成功");
+      }).catch(() => {});
+    },
+    /** 导出按钮操作 */
+    handleExport() {
+      this.download('enterprise/supply/export', {
+        ...this.queryParams
+      }, `supply_${new Date().getTime()}.xlsx`)
+    }
+  }
+};
+</script>

+ 1 - 1
ruoyi-ui/src/views/enterprise/tasks/index.vue

@@ -314,7 +314,7 @@ export default {
     /** 删除按钮操作 */
     handleDelete(row) {
       const prodtaskGuids = row.prodtaskGuid || this.ids;
-      this.$modal.confirm('是否确认删除号为"' + prodtaskGuids + '"的数据项?').then(function () {
+      this.$modal.confirm('是否确认删除生产任务号为"' + prodtaskGuids + '"的数据项?').then(function () {
         return delTasks(prodtaskGuids);
       }).then(() => {
         this.getList();

+ 8 - 3
ruoyi-ui/src/views/enterprise/tpl/index.vue

@@ -117,6 +117,8 @@ export default {
       loading: true,
       // 选中数组
       ids: [],
+      // 选中步骤数组
+      steps: [],
       // 非单个禁用
       single: true,
       // 非多个禁用
@@ -223,7 +225,8 @@ export default {
     },
     // 多选框选中数据
     handleSelectionChange(selection) {
-      this.ids = selection.map(item => item.pqtGuid)
+      this.ids = selection.map(item => item.tplName)
+      this.steps = selection.map(item => item.stepName)
       this.single = selection.length !== 1
       this.multiple = !selection.length
     },
@@ -266,8 +269,10 @@ export default {
     },
     /** 删除按钮操作 */
     handleDelete(row) {
-      const pqtGuids = row.pqtGuid || this.ids;
-      this.$modal.confirm('是否确认删除编号为"' + pqtGuids + '"的数据项?').then(function () {
+      console.log(row)
+      const pqtGuids = row.tplName || this.ids;
+      const stps = row.stepName || this.steps;
+      this.$modal.confirm('是否确认删除模板名称为"' + pqtGuids + '",步骤相应为"' + stps + '"的数据项?').then(function () {
         return delTpl(pqtGuids);
       }).then(() => {
         this.getList();

+ 4 - 3
ruoyi-ui/src/views/enterprise/type/index.vue

@@ -166,7 +166,7 @@ export default {
     },
     // 多选框选中数据
     handleSelectionChange(selection) {
-      this.ids = selection.map(item => item.pcatalogGuid)
+      this.ids = selection.map(item => item.typeName)
       this.single = selection.length !== 1
       this.multiple = !selection.length
     },
@@ -215,8 +215,9 @@ export default {
     },
     /** 删除按钮操作 */
     handleDelete(row) {
-      const pcatalogGuids = row.pcatalogGuid || this.ids;
-      this.$modal.confirm('是否确认删除产品类别编号为"' + pcatalogGuids + '"的数据项?').then(function () {
+      console.log(row)
+      const pcatalogGuids = row.typeName || this.ids;
+      this.$modal.confirm('是否确认删除产品类别名称为"' + pcatalogGuids + '"的数据项?').then(function () {
         return delType(pcatalogGuids);
       }).then(() => {
         this.getList();