From 8cd4e3664cc33705b9c68ac278f40e40cf258ecb Mon Sep 17 00:00:00 2001
From: zhanghl <253316343@qq.com>
Date: 星期一, 19 五月 2025 18:01:55 +0800
Subject: [PATCH] Merge remote-tracking branch 'origin/dev' into dev

---
 aps-modules/aps-core/src/main/java/com/aps/core/controller/mainPlan/ApsGasPipelinePredictionController.java          |  127 ++++++
 aps-modules/aps-core/src/main/java/com/aps/core/mapper/ApsMaterialProductGroupManagementMapper.java                  |   65 +++
 aps-modules/aps-core/src/main/java/com/aps/core/domain/ApsGasPipelinePrediction.java                                 |   52 ++
 aps-modules/aps-core/src/main/java/com/aps/core/service/impl/ApsGasPipelinePredictionServiceImpl.java                |  152 +++++++
 aps-modules/aps-core/src/main/java/com/aps/core/domain/ApsMaterialProductGroupManagement.java                        |  130 ++++++
 aps-modules/aps-core/src/main/java/com/aps/core/controller/mainPlan/ApsMaterialProductGroupManagementController.java |  119 +++++
 aps-modules/aps-core/src/main/java/com/aps/core/service/impl/ApsGasPipelineMoServiceImpl.java                        |    6 
 aps-modules/aps-core/src/main/java/com/aps/core/service/IApsMaterialProductGroupManagementService.java               |   65 +++
 aps-modules/aps-core/src/main/resources/mapper/core/ApsGasPipelinePredictionMapper.xml                               |   91 ++++
 aps-modules/aps-core/src/main/java/com/aps/core/service/impl/ApsMaterialProductGroupManagementServiceImpl.java       |  156 +++++++
 aps-modules/aps-core/src/main/java/com/aps/core/service/IApsGasPipelinePredictionService.java                        |   64 +++
 aps-modules/aps-core/src/main/resources/mapper/core/ApsMaterialProductGroupManagementMapper.xml                      |   96 ++++
 aps-modules/aps-core/src/main/java/com/aps/core/mapper/ApsGasPipelinePredictionMapper.java                           |   65 +++
 13 files changed, 1,186 insertions(+), 2 deletions(-)

diff --git a/aps-modules/aps-core/src/main/java/com/aps/core/controller/mainPlan/ApsGasPipelinePredictionController.java b/aps-modules/aps-core/src/main/java/com/aps/core/controller/mainPlan/ApsGasPipelinePredictionController.java
new file mode 100644
index 0000000..c76009c
--- /dev/null
+++ b/aps-modules/aps-core/src/main/java/com/aps/core/controller/mainPlan/ApsGasPipelinePredictionController.java
@@ -0,0 +1,127 @@
+package com.aps.core.controller.mainPlan;
+
+import java.util.List;
+
+import com.aps.common.core.web.page.TableDataInfo;
+import com.aps.core.domain.ApsGasPipelineMo;
+import com.aps.core.domain.ApsGasPipelinePrediction;
+import com.aps.core.service.IApsGasPipelinePredictionService;
+import io.swagger.v3.oas.annotations.Operation;
+import io.swagger.v3.oas.annotations.tags.Tag;
+import jakarta.servlet.http.HttpServletResponse;
+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.aps.common.log.annotation.Log;
+import com.aps.common.log.enums.BusinessType;
+import com.aps.common.security.annotation.RequiresPermissions;
+import com.aps.common.core.web.controller.BaseController;
+import com.aps.common.core.web.domain.AjaxResult;
+import com.aps.common.core.utils.poi.ExcelUtil;
+import org.springframework.web.multipart.MultipartFile;
+
+/**
+ * 绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁Controller
+ * 
+ * @author ruoyi
+ * @date 2025-05-19
+ */
+
+@Tag(name = "绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁", description = "绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁鎺ュ彛")
+@RestController
+@RequestMapping("/gasPipelinePrediction")
+public class ApsGasPipelinePredictionController extends BaseController
+{
+    @Autowired
+    private IApsGasPipelinePredictionService apsGasPipelinePredictionService;
+
+    /**
+     * 鏌ヨ绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁鍒楄〃
+     */
+    @Operation(summary = "鏌ヨ绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁鍒楄〃", description = "鍒嗛〉鏌ヨ")
+    @RequiresPermissions("gasPipeline:prediction:list")
+    @GetMapping("/list")
+    public TableDataInfo list(ApsGasPipelinePrediction apsGasPipelineMo)
+    {
+        startPage();
+        List<ApsGasPipelinePrediction> list = apsGasPipelinePredictionService.selectApsGasPipelinePredictionList(apsGasPipelineMo);
+        return getDataTable(list);
+    }
+
+
+    @Operation(summary = "瀵煎叆鎵嬪伐姘斾綋棰勬祴鏁版嵁", description = "鎵归噺瀵煎叆")
+    @Log(title = "瀵煎叆鎵嬪伐姘斾綋棰勬祴鏁版嵁", businessType = BusinessType.IMPORT)
+    @RequiresPermissions("gasPipeline:mo:import")
+    @PostMapping("/importData")
+    public AjaxResult importData(MultipartFile file) throws Exception {
+
+        int i = apsGasPipelinePredictionService.batchInsertApsGasPipelinePrediction(file);
+        return  toAjax(i);
+    }
+    /**
+     * 瀵煎嚭绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁鍒楄〃
+     */
+    @Operation(summary = "瀵煎嚭绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁鍒楄〃", description = "瀵煎嚭")
+    @RequiresPermissions("gasPipeline:prediction:export")
+    @Log(title = "绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁", businessType = BusinessType.EXPORT)
+    @PostMapping("/export")
+    public void export(HttpServletResponse response, ApsGasPipelinePrediction apsGasPipelinePrediction)
+    {
+        List<ApsGasPipelinePrediction> list = apsGasPipelinePredictionService.selectApsGasPipelinePredictionList(apsGasPipelinePrediction);
+        ExcelUtil<ApsGasPipelinePrediction> util = new ExcelUtil<ApsGasPipelinePrediction>(ApsGasPipelinePrediction.class);
+        util.exportExcel(response, list, "绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁鏁版嵁");
+    }
+
+    /**
+     * 鑾峰彇绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁璇︾粏淇℃伅
+     */
+    @Operation(summary = "鑾峰彇绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁璇︾粏淇℃伅", description = "鏍规嵁id鑾峰彇")
+    @RequiresPermissions("gasPipeline:prediction:query")
+    @GetMapping(value = "/{id}")
+    public AjaxResult getInfo(@PathVariable("id") Long id)
+    {
+        return success(apsGasPipelinePredictionService.selectApsGasPipelinePredictionById(id));
+    }
+
+    /**
+     * 鏂板绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁
+     */
+    @Operation(summary = "鏂板绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁", description = "鍗曚釜鏂板")
+    @RequiresPermissions("gasPipeline:prediction:add")
+    @Log(title = "绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁", businessType = BusinessType.INSERT)
+    @PostMapping
+    public AjaxResult add(@RequestBody ApsGasPipelinePrediction apsGasPipelinePrediction)
+    {
+        return toAjax(apsGasPipelinePredictionService.insertApsGasPipelinePrediction(apsGasPipelinePrediction));
+    }
+
+    /**
+     * 淇敼绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁
+     */
+    @Operation(summary = "淇敼绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁", description = "鍗曚釜淇敼")
+    @RequiresPermissions("gasPipeline:prediction:edit")
+    @Log(title = "绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁", businessType = BusinessType.UPDATE)
+    @PutMapping
+    public AjaxResult edit(@RequestBody ApsGasPipelinePrediction apsGasPipelinePrediction)
+    {
+        return toAjax(apsGasPipelinePredictionService.updateApsGasPipelinePrediction(apsGasPipelinePrediction));
+    }
+
+    /**
+     * 鍒犻櫎绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁
+     */
+    @Operation(summary = "鍒犻櫎绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁", description = "鎵归噺鍒犻櫎")
+    @RequiresPermissions("gasPipeline:prediction:remove")
+    @Log(title = "绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁", businessType = BusinessType.DELETE)
+	@DeleteMapping("/{ids}")
+    public AjaxResult remove(@PathVariable Long[] ids)
+    {
+        return toAjax(apsGasPipelinePredictionService.deleteApsGasPipelinePredictionByIds(ids));
+    }
+}
diff --git a/aps-modules/aps-core/src/main/java/com/aps/core/controller/mainPlan/ApsMaterialProductGroupManagementController.java b/aps-modules/aps-core/src/main/java/com/aps/core/controller/mainPlan/ApsMaterialProductGroupManagementController.java
new file mode 100644
index 0000000..7e703c2
--- /dev/null
+++ b/aps-modules/aps-core/src/main/java/com/aps/core/controller/mainPlan/ApsMaterialProductGroupManagementController.java
@@ -0,0 +1,119 @@
+package com.aps.core.controller.mainPlan;
+
+import com.aps.common.core.utils.poi.ExcelUtil;
+import com.aps.common.core.web.controller.BaseController;
+import com.aps.common.core.web.domain.AjaxResult;
+import com.aps.common.core.web.page.TableDataInfo;
+import com.aps.common.log.annotation.Log;
+import com.aps.common.log.enums.BusinessType;
+import com.aps.common.security.annotation.RequiresPermissions;
+import com.aps.core.domain.ApsMaterialProductGroupManagement;
+import com.aps.core.service.IApsMaterialProductGroupManagementService;
+import io.swagger.v3.oas.annotations.Operation;
+import io.swagger.v3.oas.annotations.tags.Tag;
+import jakarta.servlet.http.HttpServletResponse;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.*;
+import org.springframework.web.multipart.MultipartFile;
+
+import java.util.List;
+
+/**
+ * 鐗╂枡浜у搧缁勬暟鎹鐞咰ontroller
+ * 
+ * @author ruoyi
+ * @date 2025-05-19
+ */
+
+@Tag(name = "鐗╂枡浜у搧缁勬暟鎹鐞�", description = "鐗╂枡浜у搧缁勬暟鎹鐞嗘帴鍙�")
+@RestController
+@RequestMapping("/materialProductGroupManagement")
+public class ApsMaterialProductGroupManagementController extends BaseController
+{
+    @Autowired
+    private IApsMaterialProductGroupManagementService apsMaterialProductGroupManagementService;
+
+    /**
+     * 鏌ヨ鐗╂枡浜у搧缁勬暟鎹鐞嗗垪琛�
+     */
+    @Operation(summary = "鏌ヨ鐗╂枡浜у搧缁勬暟鎹鐞嗗垪琛�", description = "鍒嗛〉鏌ヨ")
+//    @RequiresPermissions("materialProductGroup:management:list")
+    @GetMapping("/list")
+    public TableDataInfo list(ApsMaterialProductGroupManagement apsGasPipelineMo)
+    {
+        startPage();
+        List<ApsMaterialProductGroupManagement> list = apsMaterialProductGroupManagementService.selectApsMaterialProductGroupManagementList(apsGasPipelineMo);
+        return getDataTable(list);
+    }
+
+
+    @Operation(summary = "瀵煎叆鎵嬪伐姘斾綋棰勬祴鏁版嵁", description = "鎵归噺瀵煎叆")
+    @Log(title = "瀵煎叆鎵嬪伐姘斾綋棰勬祴鏁版嵁", businessType = BusinessType.IMPORT)
+//    @RequiresPermissions("materialProductGroup:mo:import")
+    @PostMapping("/importData")
+    public AjaxResult importData(MultipartFile file) throws Exception {
+
+        int i = apsMaterialProductGroupManagementService.batchInsertApsMaterialProductGroupManagement(file);
+        return  toAjax(i);
+    }
+    /**
+     * 瀵煎嚭鐗╂枡浜у搧缁勬暟鎹鐞嗗垪琛�
+     */
+    @Operation(summary = "瀵煎嚭鐗╂枡浜у搧缁勬暟鎹鐞嗗垪琛�", description = "瀵煎嚭")
+//    @RequiresPermissions("materialProductGroup:management:export")
+    @Log(title = "鐗╂枡浜у搧缁勬暟鎹鐞�", businessType = BusinessType.EXPORT)
+    @PostMapping("/export")
+    public void export(HttpServletResponse response, ApsMaterialProductGroupManagement apsMaterialProductGroupManagement)
+    {
+        List<ApsMaterialProductGroupManagement> list = apsMaterialProductGroupManagementService.selectApsMaterialProductGroupManagementList(apsMaterialProductGroupManagement);
+        ExcelUtil<ApsMaterialProductGroupManagement> util = new ExcelUtil<ApsMaterialProductGroupManagement>(ApsMaterialProductGroupManagement.class);
+        util.exportExcel(response, list, "鐗╂枡浜у搧缁勬暟鎹鐞嗘暟鎹�");
+    }
+
+    /**
+     * 鑾峰彇鐗╂枡浜у搧缁勬暟鎹鐞嗚缁嗕俊鎭�
+     */
+    @Operation(summary = "鑾峰彇鐗╂枡浜у搧缁勬暟鎹鐞嗚缁嗕俊鎭�", description = "鏍规嵁id鑾峰彇")
+    @RequiresPermissions("materialProductGroup:management:query")
+    @GetMapping(value = "/{id}")
+    public AjaxResult getInfo(@PathVariable("id") Long id)
+    {
+        return success(apsMaterialProductGroupManagementService.selectApsMaterialProductGroupManagementById(id));
+    }
+
+    /**
+     * 鏂板鐗╂枡浜у搧缁勬暟鎹鐞�
+     */
+    @Operation(summary = "鏂板鐗╂枡浜у搧缁勬暟鎹鐞�", description = "鍗曚釜鏂板")
+//    @RequiresPermissions("materialProductGroup:management:add")
+    @Log(title = "鐗╂枡浜у搧缁勬暟鎹鐞�", businessType = BusinessType.INSERT)
+    @PostMapping
+    public AjaxResult add(@RequestBody ApsMaterialProductGroupManagement apsMaterialProductGroupManagement)
+    {
+        return toAjax(apsMaterialProductGroupManagementService.insertApsMaterialProductGroupManagement(apsMaterialProductGroupManagement));
+    }
+
+    /**
+     * 淇敼鐗╂枡浜у搧缁勬暟鎹鐞�
+     */
+    @Operation(summary = "淇敼鐗╂枡浜у搧缁勬暟鎹鐞�", description = "鍗曚釜淇敼")
+//    @RequiresPermissions("materialProductGroup:management:edit")
+    @Log(title = "鐗╂枡浜у搧缁勬暟鎹鐞�", businessType = BusinessType.UPDATE)
+    @PutMapping
+    public AjaxResult edit(@RequestBody ApsMaterialProductGroupManagement apsMaterialProductGroupManagement)
+    {
+        return toAjax(apsMaterialProductGroupManagementService.updateApsMaterialProductGroupManagement(apsMaterialProductGroupManagement));
+    }
+
+    /**
+     * 鍒犻櫎鐗╂枡浜у搧缁勬暟鎹鐞�
+     */
+    @Operation(summary = "鍒犻櫎鐗╂枡浜у搧缁勬暟鎹鐞�", description = "鎵归噺鍒犻櫎")
+//    @RequiresPermissions("materialProductGroup:management:remove")
+    @Log(title = "鐗╂枡浜у搧缁勬暟鎹鐞�", businessType = BusinessType.DELETE)
+	@DeleteMapping("/{ids}")
+    public AjaxResult remove(@PathVariable Long[] ids)
+    {
+        return toAjax(apsMaterialProductGroupManagementService.deleteApsMaterialProductGroupManagementByIds(ids));
+    }
+}
diff --git a/aps-modules/aps-core/src/main/java/com/aps/core/domain/ApsGasPipelinePrediction.java b/aps-modules/aps-core/src/main/java/com/aps/core/domain/ApsGasPipelinePrediction.java
new file mode 100644
index 0000000..294c62e
--- /dev/null
+++ b/aps-modules/aps-core/src/main/java/com/aps/core/domain/ApsGasPipelinePrediction.java
@@ -0,0 +1,52 @@
+package com.aps.core.domain;
+
+import com.aps.common.core.annotation.Excel;
+import com.aps.common.core.web.domain.BaseEntity;
+import com.fasterxml.jackson.annotation.JsonFormat;
+import io.swagger.v3.oas.annotations.media.Schema;
+import lombok.Data;
+import org.springframework.data.annotation.Id;
+
+import java.math.BigDecimal;
+import java.sql.Timestamp;
+
+/**
+ * 绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁瀵硅薄 aps_gas_pipeline_prediction
+ * 
+ * @author ruoyi
+ * @date 2025-05-19
+ */
+@Data
+@Schema(description = "绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁瀹炰綋绫�")
+public class ApsGasPipelinePrediction extends BaseEntity
+{
+    private static final long serialVersionUID = 1L;
+
+    @Id
+    @JsonFormat(shape = JsonFormat.Shape.STRING)
+    /** ID */
+    @Schema(description = "ID")
+    private Long id;
+
+    /** 鐢熶骇鍩哄湴 */
+    @Excel(name = "鐢熶骇鍩哄湴")
+    @Schema(description = "鐢熶骇鍩哄湴")
+    private String factory;
+
+    /** 鏂欏彿 */
+    @Excel(name = "鏂欏彿")
+    @Schema(description = "鏂欏彿")
+    private String materialCode;
+
+    /** 棰勬祴鏃ユ湡 */
+    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
+    @Excel(name = "棰勬祴鏃ユ湡", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
+    @Schema(description = "棰勬祴鏃ユ湡")
+    private Timestamp predictDate;
+
+    /** 鏁伴噺 */
+    @Excel(name = "鏁伴噺")
+    @Schema(description = "鏁伴噺")
+    private BigDecimal predictQuantity;
+
+}
diff --git a/aps-modules/aps-core/src/main/java/com/aps/core/domain/ApsMaterialProductGroupManagement.java b/aps-modules/aps-core/src/main/java/com/aps/core/domain/ApsMaterialProductGroupManagement.java
new file mode 100644
index 0000000..da7a861
--- /dev/null
+++ b/aps-modules/aps-core/src/main/java/com/aps/core/domain/ApsMaterialProductGroupManagement.java
@@ -0,0 +1,130 @@
+package com.aps.core.domain;
+
+import com.aps.common.core.web.domain.BaseEntity;
+import com.fasterxml.jackson.annotation.JsonFormat;
+import io.swagger.v3.oas.annotations.media.Schema;
+import lombok.Data;
+import org.apache.commons.lang3.builder.ToStringBuilder;
+import org.apache.commons.lang3.builder.ToStringStyle;
+import com.aps.common.core.annotation.Excel;
+import org.springframework.data.annotation.Id;
+
+/**
+ * 鐗╂枡浜у搧缁勬暟鎹鐞嗗璞� aps_material_product_group_management
+ * 
+ * @author ruoyi
+ * @date 2025-05-19
+ */
+@Schema(description = "鐗╂枡浜у搧缁勬暟鎹鐞嗗疄浣撶被")
+@Data
+public class ApsMaterialProductGroupManagement extends BaseEntity
+{
+    private static final long serialVersionUID = 1L;
+
+    @Id
+    @JsonFormat(shape = JsonFormat.Shape.STRING)
+    /** ID */
+    @Schema(description = "ID")
+    private Long id;
+
+    /** 閫傜敤宸ュ巶  鍙傝�� aps_factory */
+    @Excel(name = "閫傜敤宸ュ巶  鍙傝�� aps_factory")
+    @Schema(description = "閫傜敤宸ュ巶  鍙傝�� aps_factory")
+    private String factory;
+
+    /** 鏂欏彿 */
+    @Excel(name = "鏂欏彿")
+    @Schema(description = "鏂欏彿")
+    private String materialCode;
+
+    /** 涓撲笟 鍙傝��	aps_domain */
+    @Excel(name = "涓撲笟 鍙傝��	aps_domain")
+    @Schema(description = "涓撲笟 鍙傝��	aps_domain")
+    private String domain;
+
+    /** 鏄惁涓轰富闃� 鏄�/鍚� */
+    @Excel(name = "鏄惁涓轰富闃� 鏄�/鍚�")
+    @Schema(description = "鏄惁涓轰富闃� 鏄�/鍚�")
+    private String isMain;
+
+    /** 鏂欏彿绫诲埆 鍒堕�犱欢/閲囪喘浠� */
+    @Excel(name = "鏂欏彿绫诲埆 鍒堕�犱欢/閲囪喘浠�")
+    @Schema(description = "鏂欏彿绫诲埆 鍒堕�犱欢/閲囪喘浠�")
+    private String materialType;
+
+    public void setId(Long id) 
+    {
+        this.id = id;
+    }
+
+    public Long getId() 
+    {
+        return id;
+    }
+
+    public void setFactory(String factory) 
+    {
+        this.factory = factory;
+    }
+
+    public String getFactory() 
+    {
+        return factory;
+    }
+
+    public void setMaterialCode(String materialCode) 
+    {
+        this.materialCode = materialCode;
+    }
+
+    public String getMaterialCode() 
+    {
+        return materialCode;
+    }
+
+    public void setDomain(String domain) 
+    {
+        this.domain = domain;
+    }
+
+    public String getDomain() 
+    {
+        return domain;
+    }
+
+    public void setIsMain(String isMain) 
+    {
+        this.isMain = isMain;
+    }
+
+    public String getIsMain() 
+    {
+        return isMain;
+    }
+
+    public void setMaterialType(String materialType) 
+    {
+        this.materialType = materialType;
+    }
+
+    public String getMaterialType() 
+    {
+        return materialType;
+    }
+
+    @Override
+    public String toString() {
+        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
+            .append("id", getId())
+            .append("factory", getFactory())
+            .append("materialCode", getMaterialCode())
+            .append("domain", getDomain())
+            .append("createBy", getCreateBy())
+            .append("createTime", getCreateTime())
+            .append("updateBy", getUpdateBy())
+            .append("updateTime", getUpdateTime())
+            .append("isMain", getIsMain())
+            .append("materialType", getMaterialType())
+            .toString();
+    }
+}
diff --git a/aps-modules/aps-core/src/main/java/com/aps/core/mapper/ApsGasPipelinePredictionMapper.java b/aps-modules/aps-core/src/main/java/com/aps/core/mapper/ApsGasPipelinePredictionMapper.java
new file mode 100644
index 0000000..c653463
--- /dev/null
+++ b/aps-modules/aps-core/src/main/java/com/aps/core/mapper/ApsGasPipelinePredictionMapper.java
@@ -0,0 +1,65 @@
+package com.aps.core.mapper;
+
+import com.aps.core.domain.ApsGasPipelinePrediction;
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+
+import java.util.List;
+
+/**
+ * 绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁Mapper鎺ュ彛
+ * 
+ * @author ruoyi
+ * @date 2025-05-19
+ */
+public interface ApsGasPipelinePredictionMapper extends BaseMapper<ApsGasPipelinePrediction> 
+{
+    /**
+     * 鏌ヨ绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁
+     * 
+     * @param id 绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁涓婚敭
+     * @return 绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁
+     */
+    public ApsGasPipelinePrediction selectApsGasPipelinePredictionById(Long id);
+
+    /**
+     * 鏌ヨ绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁鍒楄〃
+     * 
+     * @param apsGasPipelinePrediction 绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁
+     * @return 绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁闆嗗悎
+     */
+    public List<ApsGasPipelinePrediction> selectApsGasPipelinePredictionList(ApsGasPipelinePrediction apsGasPipelinePrediction);
+
+    /**
+     * 鏂板绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁
+     * 
+     * @param apsGasPipelinePrediction 绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁
+     * @return 缁撴灉
+     */
+    public int insertApsGasPipelinePrediction(ApsGasPipelinePrediction apsGasPipelinePrediction);
+
+    /**
+     * 淇敼绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁
+     * 
+     * @param apsGasPipelinePrediction 绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁
+     * @return 缁撴灉
+     */
+    public int updateApsGasPipelinePrediction(ApsGasPipelinePrediction apsGasPipelinePrediction);
+
+    /**
+     * 鍒犻櫎绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁
+     * 
+     * @param id 绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁涓婚敭
+     * @return 缁撴灉
+     */
+    public int deleteApsGasPipelinePredictionById(Long id);
+
+    /**
+     * 鎵归噺鍒犻櫎绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁
+     * 
+     * @param ids 闇�瑕佸垹闄ょ殑鏁版嵁涓婚敭闆嗗悎
+     * @return 缁撴灉
+     */
+    public int deleteApsGasPipelinePredictionByIds(Long[] ids);
+
+    void deleteAll();
+}
diff --git a/aps-modules/aps-core/src/main/java/com/aps/core/mapper/ApsMaterialProductGroupManagementMapper.java b/aps-modules/aps-core/src/main/java/com/aps/core/mapper/ApsMaterialProductGroupManagementMapper.java
new file mode 100644
index 0000000..44a8536
--- /dev/null
+++ b/aps-modules/aps-core/src/main/java/com/aps/core/mapper/ApsMaterialProductGroupManagementMapper.java
@@ -0,0 +1,65 @@
+package com.aps.core.mapper;
+
+import com.aps.core.domain.ApsMaterialProductGroupManagement;
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+
+import java.util.List;
+
+/**
+ * 鐗╂枡浜у搧缁勬暟鎹鐞哅apper鎺ュ彛
+ * 
+ * @author ruoyi
+ * @date 2025-05-19
+ */
+public interface ApsMaterialProductGroupManagementMapper extends BaseMapper<ApsMaterialProductGroupManagement>
+{
+    /**
+     * 鏌ヨ鐗╂枡浜у搧缁勬暟鎹鐞�
+     * 
+     * @param id 鐗╂枡浜у搧缁勬暟鎹鐞嗕富閿�
+     * @return 鐗╂枡浜у搧缁勬暟鎹鐞�
+     */
+    public ApsMaterialProductGroupManagement selectApsMaterialProductGroupManagementById(Long id);
+
+    /**
+     * 鏌ヨ鐗╂枡浜у搧缁勬暟鎹鐞嗗垪琛�
+     * 
+     * @param apsMaterialProductGroupManagement 鐗╂枡浜у搧缁勬暟鎹鐞�
+     * @return 鐗╂枡浜у搧缁勬暟鎹鐞嗛泦鍚�
+     */
+    public List<ApsMaterialProductGroupManagement> selectApsMaterialProductGroupManagementList(ApsMaterialProductGroupManagement apsMaterialProductGroupManagement);
+
+    /**
+     * 鏂板鐗╂枡浜у搧缁勬暟鎹鐞�
+     * 
+     * @param apsMaterialProductGroupManagement 鐗╂枡浜у搧缁勬暟鎹鐞�
+     * @return 缁撴灉
+     */
+    public int insertApsMaterialProductGroupManagement(ApsMaterialProductGroupManagement apsMaterialProductGroupManagement);
+
+    /**
+     * 淇敼鐗╂枡浜у搧缁勬暟鎹鐞�
+     * 
+     * @param apsMaterialProductGroupManagement 鐗╂枡浜у搧缁勬暟鎹鐞�
+     * @return 缁撴灉
+     */
+    public int updateApsMaterialProductGroupManagement(ApsMaterialProductGroupManagement apsMaterialProductGroupManagement);
+
+    /**
+     * 鍒犻櫎鐗╂枡浜у搧缁勬暟鎹鐞�
+     * 
+     * @param id 鐗╂枡浜у搧缁勬暟鎹鐞嗕富閿�
+     * @return 缁撴灉
+     */
+    public int deleteApsMaterialProductGroupManagementById(Long id);
+
+    /**
+     * 鎵归噺鍒犻櫎鐗╂枡浜у搧缁勬暟鎹鐞�
+     * 
+     * @param ids 闇�瑕佸垹闄ょ殑鏁版嵁涓婚敭闆嗗悎
+     * @return 缁撴灉
+     */
+    public int deleteApsMaterialProductGroupManagementByIds(Long[] ids);
+
+    void deleteAll();
+}
diff --git a/aps-modules/aps-core/src/main/java/com/aps/core/service/IApsGasPipelinePredictionService.java b/aps-modules/aps-core/src/main/java/com/aps/core/service/IApsGasPipelinePredictionService.java
new file mode 100644
index 0000000..06b1023
--- /dev/null
+++ b/aps-modules/aps-core/src/main/java/com/aps/core/service/IApsGasPipelinePredictionService.java
@@ -0,0 +1,64 @@
+package com.aps.core.service;
+
+import java.util.List;
+import com.aps.core.domain.ApsGasPipelinePrediction;
+import org.springframework.web.multipart.MultipartFile;
+
+/**
+ * 绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁Service鎺ュ彛
+ * 
+ * @author ruoyi
+ * @date 2025-05-19
+ */
+public interface IApsGasPipelinePredictionService 
+{
+    /**
+     * 鏌ヨ绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁
+     * 
+     * @param id 绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁涓婚敭
+     * @return 绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁
+     */
+    public ApsGasPipelinePrediction selectApsGasPipelinePredictionById(Long id);
+
+    /**
+     * 鏌ヨ绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁鍒楄〃
+     * 
+     * @param apsGasPipelinePrediction 绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁
+     * @return 绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁闆嗗悎
+     */
+    public List<ApsGasPipelinePrediction> selectApsGasPipelinePredictionList(ApsGasPipelinePrediction apsGasPipelinePrediction);
+
+    /**
+     * 鏂板绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁
+     * 
+     * @param apsGasPipelinePrediction 绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁
+     * @return 缁撴灉
+     */
+    public int insertApsGasPipelinePrediction(ApsGasPipelinePrediction apsGasPipelinePrediction);
+
+    /**
+     * 淇敼绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁
+     * 
+     * @param apsGasPipelinePrediction 绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁
+     * @return 缁撴灉
+     */
+    public int updateApsGasPipelinePrediction(ApsGasPipelinePrediction apsGasPipelinePrediction);
+
+    /**
+     * 鎵归噺鍒犻櫎绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁
+     * 
+     * @param ids 闇�瑕佸垹闄ょ殑绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁涓婚敭闆嗗悎
+     * @return 缁撴灉
+     */
+    public int deleteApsGasPipelinePredictionByIds(Long[] ids);
+
+    /**
+     * 鍒犻櫎绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁淇℃伅
+     * 
+     * @param id 绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁涓婚敭
+     * @return 缁撴灉
+     */
+    public int deleteApsGasPipelinePredictionById(Long id);
+
+    int batchInsertApsGasPipelinePrediction(MultipartFile file);
+}
diff --git a/aps-modules/aps-core/src/main/java/com/aps/core/service/IApsMaterialProductGroupManagementService.java b/aps-modules/aps-core/src/main/java/com/aps/core/service/IApsMaterialProductGroupManagementService.java
new file mode 100644
index 0000000..adbca15
--- /dev/null
+++ b/aps-modules/aps-core/src/main/java/com/aps/core/service/IApsMaterialProductGroupManagementService.java
@@ -0,0 +1,65 @@
+package com.aps.core.service;
+
+import com.aps.core.domain.ApsMaterialProductGroupManagement;
+import org.springframework.web.multipart.MultipartFile;
+
+import java.util.List;
+
+/**
+ * 鐗╂枡浜у搧缁勬暟鎹鐞哠ervice鎺ュ彛
+ * 
+ * @author ruoyi
+ * @date 2025-05-19
+ */
+public interface IApsMaterialProductGroupManagementService 
+{
+    /**
+     * 鏌ヨ鐗╂枡浜у搧缁勬暟鎹鐞�
+     * 
+     * @param id 鐗╂枡浜у搧缁勬暟鎹鐞嗕富閿�
+     * @return 鐗╂枡浜у搧缁勬暟鎹鐞�
+     */
+    public ApsMaterialProductGroupManagement selectApsMaterialProductGroupManagementById(Long id);
+
+    /**
+     * 鏌ヨ鐗╂枡浜у搧缁勬暟鎹鐞嗗垪琛�
+     * 
+     * @param apsMaterialProductGroupManagement 鐗╂枡浜у搧缁勬暟鎹鐞�
+     * @return 鐗╂枡浜у搧缁勬暟鎹鐞嗛泦鍚�
+     */
+    public List<ApsMaterialProductGroupManagement> selectApsMaterialProductGroupManagementList(ApsMaterialProductGroupManagement apsMaterialProductGroupManagement);
+
+    /**
+     * 鏂板鐗╂枡浜у搧缁勬暟鎹鐞�
+     * 
+     * @param apsMaterialProductGroupManagement 鐗╂枡浜у搧缁勬暟鎹鐞�
+     * @return 缁撴灉
+     */
+    public int insertApsMaterialProductGroupManagement(ApsMaterialProductGroupManagement apsMaterialProductGroupManagement);
+
+    /**
+     * 淇敼鐗╂枡浜у搧缁勬暟鎹鐞�
+     * 
+     * @param apsMaterialProductGroupManagement 鐗╂枡浜у搧缁勬暟鎹鐞�
+     * @return 缁撴灉
+     */
+    public int updateApsMaterialProductGroupManagement(ApsMaterialProductGroupManagement apsMaterialProductGroupManagement);
+
+    /**
+     * 鎵归噺鍒犻櫎鐗╂枡浜у搧缁勬暟鎹鐞�
+     * 
+     * @param ids 闇�瑕佸垹闄ょ殑鐗╂枡浜у搧缁勬暟鎹鐞嗕富閿泦鍚�
+     * @return 缁撴灉
+     */
+    public int deleteApsMaterialProductGroupManagementByIds(Long[] ids);
+
+    /**
+     * 鍒犻櫎鐗╂枡浜у搧缁勬暟鎹鐞嗕俊鎭�
+     * 
+     * @param id 鐗╂枡浜у搧缁勬暟鎹鐞嗕富閿�
+     * @return 缁撴灉
+     */
+    public int deleteApsMaterialProductGroupManagementById(Long id);
+
+    int batchInsertApsMaterialProductGroupManagement(MultipartFile file);
+}
diff --git a/aps-modules/aps-core/src/main/java/com/aps/core/service/impl/ApsGasPipelineMoServiceImpl.java b/aps-modules/aps-core/src/main/java/com/aps/core/service/impl/ApsGasPipelineMoServiceImpl.java
index d6f9650..c392f97 100644
--- a/aps-modules/aps-core/src/main/java/com/aps/core/service/impl/ApsGasPipelineMoServiceImpl.java
+++ b/aps-modules/aps-core/src/main/java/com/aps/core/service/impl/ApsGasPipelineMoServiceImpl.java
@@ -119,12 +119,14 @@
             for (int i = 1; i <= rows; i++) {
                 Row row = sheet.getRow(i);
                 String mo = row.getCell(0).getStringCellValue();
+                if (StringUtils.isEmpty(mo)){
+                    continue;
+                }
                 String factory = row.getCell(1).getStringCellValue();
                 String materialNum = row.getCell(2).getStringCellValue();
                 double quantity = row.getCell(3).getNumericCellValue();
                 Date planEnd = row.getCell(4).getDateCellValue();
-                if (StringUtils.isNotBlank(mo) &&
-                    StringUtils.isNotBlank(factory) &&
+                if (StringUtils.isNotBlank(factory) &&
                     StringUtils.isNotBlank(materialNum) &&
                     planEnd != null) {
                     ApsGasPipelineMo apsGasPipelineMo = new ApsGasPipelineMo();
diff --git a/aps-modules/aps-core/src/main/java/com/aps/core/service/impl/ApsGasPipelinePredictionServiceImpl.java b/aps-modules/aps-core/src/main/java/com/aps/core/service/impl/ApsGasPipelinePredictionServiceImpl.java
new file mode 100644
index 0000000..7a85b16
--- /dev/null
+++ b/aps-modules/aps-core/src/main/java/com/aps/core/service/impl/ApsGasPipelinePredictionServiceImpl.java
@@ -0,0 +1,152 @@
+package com.aps.core.service.impl;
+
+import cn.hutool.core.util.IdUtil;
+import com.aps.common.core.utils.DateUtils;
+import com.aps.common.security.utils.SecurityUtils;
+import com.aps.core.domain.ApsGasPipelinePrediction;
+import com.aps.core.mapper.ApsGasPipelinePredictionMapper;
+import com.aps.core.service.IApsGasPipelinePredictionService;
+import io.micrometer.common.util.StringUtils;
+import lombok.SneakyThrows;
+import org.apache.poi.ss.usermodel.Row;
+import org.apache.poi.ss.usermodel.Sheet;
+import org.apache.poi.ss.usermodel.Workbook;
+import org.apache.poi.ss.usermodel.WorkbookFactory;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+import org.springframework.web.multipart.MultipartFile;
+
+import java.math.BigDecimal;
+import java.sql.Timestamp;
+import java.util.ArrayList;
+import java.util.Date;
+import java.util.List;
+
+/**
+ * 绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁Service涓氬姟灞傚鐞�
+ * 
+ * @author ruoyi
+ * @date 2025-05-19
+ */
+@Service
+public class ApsGasPipelinePredictionServiceImpl implements IApsGasPipelinePredictionService
+{
+    @Autowired
+    private ApsGasPipelinePredictionMapper apsGasPipelinePredictionMapper;
+
+    /**
+     * 鏌ヨ绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁
+     * 
+     * @param id 绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁涓婚敭
+     * @return 绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁
+     */
+    @Override
+    public ApsGasPipelinePrediction selectApsGasPipelinePredictionById(Long id)
+    {
+        return apsGasPipelinePredictionMapper.selectApsGasPipelinePredictionById(id);
+    }
+
+    /**
+     * 鏌ヨ绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁鍒楄〃
+     * 
+     * @param apsGasPipelinePrediction 绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁
+     * @return 绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁
+     */
+    @Override
+    public List<ApsGasPipelinePrediction> selectApsGasPipelinePredictionList(ApsGasPipelinePrediction apsGasPipelinePrediction)
+    {
+        return apsGasPipelinePredictionMapper.selectApsGasPipelinePredictionList(apsGasPipelinePrediction);
+    }
+
+    /**
+     * 鏂板绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁
+     * 
+     * @param apsGasPipelinePrediction 绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁
+     * @return 缁撴灉
+     */
+    @Override
+    public int insertApsGasPipelinePrediction(ApsGasPipelinePrediction apsGasPipelinePrediction)
+    {
+        apsGasPipelinePrediction.setCreateTime(DateUtils.getNowDate());
+        return apsGasPipelinePredictionMapper.insertApsGasPipelinePrediction(apsGasPipelinePrediction);
+    }
+
+    /**
+     * 淇敼绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁
+     * 
+     * @param apsGasPipelinePrediction 绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁
+     * @return 缁撴灉
+     */
+    @Override
+    public int updateApsGasPipelinePrediction(ApsGasPipelinePrediction apsGasPipelinePrediction)
+    {
+        apsGasPipelinePrediction.setUpdateTime(DateUtils.getNowDate());
+        return apsGasPipelinePredictionMapper.updateApsGasPipelinePrediction(apsGasPipelinePrediction);
+    }
+
+    /**
+     * 鎵归噺鍒犻櫎绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁
+     * 
+     * @param ids 闇�瑕佸垹闄ょ殑绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁涓婚敭
+     * @return 缁撴灉
+     */
+    @Override
+    public int deleteApsGasPipelinePredictionByIds(Long[] ids)
+    {
+        return apsGasPipelinePredictionMapper.deleteApsGasPipelinePredictionByIds(ids);
+    }
+
+    /**
+     * 鍒犻櫎绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁淇℃伅
+     * 
+     * @param id 绠¤矾鎵嬪伐姘斾綋棰勬祴鏁版嵁涓婚敭
+     * @return 缁撴灉
+     */
+    @Override
+    public int deleteApsGasPipelinePredictionById(Long id)
+    {
+        return apsGasPipelinePredictionMapper.deleteApsGasPipelinePredictionById(id);
+    }
+
+    @SneakyThrows
+    @Override
+    public int batchInsertApsGasPipelinePrediction(MultipartFile file) {
+        Workbook workbook = WorkbookFactory.create(file.getInputStream());
+
+        Sheet sheet = workbook.getSheetAt(0);
+        int rows = sheet.getLastRowNum();
+        if (rows > 0) {
+            List<ApsGasPipelinePrediction> list = new ArrayList<>();
+
+            /*鏁版嵁鍒椾粠1寮�濮�*/
+            for (int i = 1; i <= rows; i++) {
+                Row row = sheet.getRow(i);
+                String materialCode = row.getCell(0).getStringCellValue();
+                if (StringUtils.isEmpty(materialCode)){
+                    continue;
+                }
+                String factory = row.getCell(1).getStringCellValue();
+                double quantity = row.getCell(2).getNumericCellValue();
+                Date date = row.getCell(3).getDateCellValue();
+                if (StringUtils.isNotBlank(factory) &&
+                    date != null) {
+                    ApsGasPipelinePrediction item = new ApsGasPipelinePrediction();
+                    item.setId(IdUtil.getSnowflakeNextId());
+                    item.setFactory(factory);
+                    item.setMaterialCode(materialCode);
+                    item.setCreateBy(SecurityUtils.getUsername());
+                    item.setCreateTime(DateUtils.getNowDate());
+                    item.setPredictQuantity(new BigDecimal(quantity));
+                    item.setPredictDate(new Timestamp(date.getTime()));
+                    list.add(item);
+                }
+            }
+            if (!list.isEmpty()) {
+                apsGasPipelinePredictionMapper.deleteAll();
+                apsGasPipelinePredictionMapper.insert(list);
+            }
+            return list.size();
+        }
+        return 0;
+    }
+}
diff --git a/aps-modules/aps-core/src/main/java/com/aps/core/service/impl/ApsMaterialProductGroupManagementServiceImpl.java b/aps-modules/aps-core/src/main/java/com/aps/core/service/impl/ApsMaterialProductGroupManagementServiceImpl.java
new file mode 100644
index 0000000..18cb143
--- /dev/null
+++ b/aps-modules/aps-core/src/main/java/com/aps/core/service/impl/ApsMaterialProductGroupManagementServiceImpl.java
@@ -0,0 +1,156 @@
+package com.aps.core.service.impl;
+
+import java.math.BigDecimal;
+import java.sql.Timestamp;
+import java.util.ArrayList;
+import java.util.Date;
+import java.util.List;
+
+import cn.hutool.core.util.IdUtil;
+import com.aps.common.core.utils.DateUtils;
+import com.aps.common.security.utils.SecurityUtils;
+import com.aps.core.domain.ApsGasPipelinePrediction;
+import com.aps.core.domain.ApsMaterialProductGroupManagement;
+import com.aps.core.mapper.ApsMaterialProductGroupManagementMapper;
+import com.aps.core.service.IApsMaterialProductGroupManagementService;
+import io.micrometer.common.util.StringUtils;
+import lombok.SneakyThrows;
+import org.apache.poi.ss.usermodel.Row;
+import org.apache.poi.ss.usermodel.Sheet;
+import org.apache.poi.ss.usermodel.Workbook;
+import org.apache.poi.ss.usermodel.WorkbookFactory;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+import org.springframework.web.multipart.MultipartFile;
+
+/**
+ * 鐗╂枡浜у搧缁勬暟鎹鐞哠ervice涓氬姟灞傚鐞�
+ * 
+ * @author ruoyi
+ * @date 2025-05-19
+ */
+@Service
+public class ApsMaterialProductGroupManagementServiceImpl implements IApsMaterialProductGroupManagementService
+{
+    @Autowired
+    private ApsMaterialProductGroupManagementMapper apsMaterialProductGroupManagementMapper;
+
+    /**
+     * 鏌ヨ鐗╂枡浜у搧缁勬暟鎹鐞�
+     * 
+     * @param id 鐗╂枡浜у搧缁勬暟鎹鐞嗕富閿�
+     * @return 鐗╂枡浜у搧缁勬暟鎹鐞�
+     */
+    @Override
+    public ApsMaterialProductGroupManagement selectApsMaterialProductGroupManagementById(Long id)
+    {
+        return apsMaterialProductGroupManagementMapper.selectApsMaterialProductGroupManagementById(id);
+    }
+
+    /**
+     * 鏌ヨ鐗╂枡浜у搧缁勬暟鎹鐞嗗垪琛�
+     * 
+     * @param apsMaterialProductGroupManagement 鐗╂枡浜у搧缁勬暟鎹鐞�
+     * @return 鐗╂枡浜у搧缁勬暟鎹鐞�
+     */
+    @Override
+    public List<ApsMaterialProductGroupManagement> selectApsMaterialProductGroupManagementList(ApsMaterialProductGroupManagement apsMaterialProductGroupManagement)
+    {
+        return apsMaterialProductGroupManagementMapper.selectApsMaterialProductGroupManagementList(apsMaterialProductGroupManagement);
+    }
+
+    /**
+     * 鏂板鐗╂枡浜у搧缁勬暟鎹鐞�
+     * 
+     * @param apsMaterialProductGroupManagement 鐗╂枡浜у搧缁勬暟鎹鐞�
+     * @return 缁撴灉
+     */
+    @Override
+    public int insertApsMaterialProductGroupManagement(ApsMaterialProductGroupManagement apsMaterialProductGroupManagement)
+    {
+        apsMaterialProductGroupManagement.setCreateTime(DateUtils.getNowDate());
+        return apsMaterialProductGroupManagementMapper.insertApsMaterialProductGroupManagement(apsMaterialProductGroupManagement);
+    }
+
+    /**
+     * 淇敼鐗╂枡浜у搧缁勬暟鎹鐞�
+     * 
+     * @param apsMaterialProductGroupManagement 鐗╂枡浜у搧缁勬暟鎹鐞�
+     * @return 缁撴灉
+     */
+    @Override
+    public int updateApsMaterialProductGroupManagement(ApsMaterialProductGroupManagement apsMaterialProductGroupManagement)
+    {
+        apsMaterialProductGroupManagement.setUpdateTime(DateUtils.getNowDate());
+        return apsMaterialProductGroupManagementMapper.updateApsMaterialProductGroupManagement(apsMaterialProductGroupManagement);
+    }
+
+    /**
+     * 鎵归噺鍒犻櫎鐗╂枡浜у搧缁勬暟鎹鐞�
+     * 
+     * @param ids 闇�瑕佸垹闄ょ殑鐗╂枡浜у搧缁勬暟鎹鐞嗕富閿�
+     * @return 缁撴灉
+     */
+    @Override
+    public int deleteApsMaterialProductGroupManagementByIds(Long[] ids)
+    {
+        return apsMaterialProductGroupManagementMapper.deleteApsMaterialProductGroupManagementByIds(ids);
+    }
+
+    /**
+     * 鍒犻櫎鐗╂枡浜у搧缁勬暟鎹鐞嗕俊鎭�
+     * 
+     * @param id 鐗╂枡浜у搧缁勬暟鎹鐞嗕富閿�
+     * @return 缁撴灉
+     */
+    @Override
+    public int deleteApsMaterialProductGroupManagementById(Long id)
+    {
+        return apsMaterialProductGroupManagementMapper.deleteApsMaterialProductGroupManagementById(id);
+    }
+
+    @SneakyThrows
+    @Override
+    public int batchInsertApsMaterialProductGroupManagement(MultipartFile file) {
+        Workbook workbook = WorkbookFactory.create(file.getInputStream());
+
+        Sheet sheet = workbook.getSheetAt(0);
+        int rows = sheet.getLastRowNum();
+        if (rows > 0) {
+            List<ApsMaterialProductGroupManagement> list = new ArrayList<>();
+
+            /*鏁版嵁鍒椾粠1寮�濮�*/
+            for (int i = 1; i <= rows; i++) {
+                Row row = sheet.getRow(i);
+                String materialCode = row.getCell(0).getStringCellValue();
+                if (StringUtils.isEmpty(materialCode)){
+                    continue;
+                }
+                String materialType = row.getCell(1).getStringCellValue();
+                String domain = row.getCell(2).getStringCellValue();
+                String isMain = row.getCell(3).getStringCellValue();
+                String factory = row.getCell(4).getStringCellValue();
+                if (StringUtils.isNotBlank(materialType) &&
+                    StringUtils.isNotBlank(domain) &&
+                    StringUtils.isNotBlank(isMain) &&
+                    StringUtils.isNotBlank(factory)) {
+                    ApsMaterialProductGroupManagement item = new ApsMaterialProductGroupManagement();
+                    item.setId(IdUtil.getSnowflakeNextId());
+                    item.setFactory(factory);
+                    item.setDomain(domain);
+                    item.setMaterialType(materialType);
+                    item.setMaterialCode(materialCode);
+                    item.setIsMain(isMain);
+                    item.setCreateBy(SecurityUtils.getUsername());
+                    item.setCreateTime(DateUtils.getNowDate());
+                    list.add(item);
+                }
+            }
+            if (!list.isEmpty()) {
+                apsMaterialProductGroupManagementMapper.insert(list);
+            }
+            return list.size();
+        }
+        return 0;
+    }
+}
diff --git a/aps-modules/aps-core/src/main/resources/mapper/core/ApsGasPipelinePredictionMapper.xml b/aps-modules/aps-core/src/main/resources/mapper/core/ApsGasPipelinePredictionMapper.xml
new file mode 100644
index 0000000..b8c149a
--- /dev/null
+++ b/aps-modules/aps-core/src/main/resources/mapper/core/ApsGasPipelinePredictionMapper.xml
@@ -0,0 +1,91 @@
+<?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.aps.core.mapper.ApsGasPipelinePredictionMapper">
+    
+    <resultMap type="com.aps.core.domain.ApsGasPipelinePrediction" id="ApsGasPipelinePredictionResult">
+        <result property="id"    column="id"    />
+        <result property="factory"    column="factory"    />
+        <result property="materialCode"    column="material_code"    />
+        <result property="predictDate"    column="predict_date"    />
+        <result property="createBy"    column="create_by"    />
+        <result property="createTime"    column="create_time"    />
+        <result property="updateBy"    column="update_by"    />
+        <result property="updateTime"    column="update_time"    />
+        <result property="predictQuantity"    column="predict_quantity"    />
+    </resultMap>
+
+    <sql id="selectApsGasPipelinePredictionVo">
+        select id, factory, material_code, predict_date, create_by, create_time, update_by, update_time, predict_quantity from aps_gas_pipeline_prediction
+    </sql>
+
+    <select id="selectApsGasPipelinePredictionList" parameterType="ApsGasPipelinePrediction" resultMap="ApsGasPipelinePredictionResult">
+        <include refid="selectApsGasPipelinePredictionVo"/>
+        <where>  
+            <if test="factory != null  and factory != ''"> and factory = #{factory}</if>
+            <if test="materialCode != null  and materialCode != ''"> and material_code = #{materialCode}</if>
+            <if test="predictDate != null  and predictDate != ''"> and predict_date = #{predictDate}</if>
+            <if test="predictQuantity != null  and predictQuantity != ''"> and predict_quantity = #{predictQuantity}</if>
+        </where>
+    </select>
+    
+    <select id="selectApsGasPipelinePredictionById" parameterType="Long" resultMap="ApsGasPipelinePredictionResult">
+    </select>
+
+    <insert id="insertApsGasPipelinePrediction" parameterType="ApsGasPipelinePrediction">
+        insert into aps_gas_pipeline_prediction
+        <trim prefix="(" suffix=")" suffixOverrides=",">
+            <if test="id != null">id,</if>
+            <if test="factory != null">factory,</if>
+            <if test="materialCode != null">material_code,</if>
+            <if test="predictDate != null">predict_date,</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>
+            <if test="predictQuantity != null">predict_quantity,</if>
+         </trim>
+        <trim prefix="values (" suffix=")" suffixOverrides=",">
+            <if test="id != null">#{id},</if>
+            <if test="factory != null">#{factory},</if>
+            <if test="materialCode != null">#{materialCode},</if>
+            <if test="predictDate != null">#{predictDate},</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>
+            <if test="predictQuantity != null">#{predictQuantity},</if>
+         </trim>
+    </insert>
+
+    <update id="updateApsGasPipelinePrediction" parameterType="ApsGasPipelinePrediction">
+        update aps_gas_pipeline_prediction
+        <trim prefix="SET" suffixOverrides=",">
+            <if test="factory != null">factory = #{factory},</if>
+            <if test="materialCode != null">material_code = #{materialCode},</if>
+            <if test="predictDate != null">predict_date = #{predictDate},</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>
+            <if test="predictQuantity != null">predict_quantity = #{predictQuantity},</if>
+        </trim>
+        where id = #{id}
+    </update>
+
+    <delete id="deleteApsGasPipelinePredictionById" parameterType="Long">
+        delete from aps_gas_pipeline_prediction where id = #{id}
+    </delete>
+
+    <delete id="deleteApsGasPipelinePredictionByIds" parameterType="String">
+        delete from aps_gas_pipeline_prediction where id in 
+        <foreach item="id" collection="array" open="(" separator="," close=")">
+            #{id}
+        </foreach>
+    </delete>
+
+    <delete id="deleteAll" >
+        delete from aps_gas_pipeline_prediction
+    </delete>
+</mapper>
\ No newline at end of file
diff --git a/aps-modules/aps-core/src/main/resources/mapper/core/ApsMaterialProductGroupManagementMapper.xml b/aps-modules/aps-core/src/main/resources/mapper/core/ApsMaterialProductGroupManagementMapper.xml
new file mode 100644
index 0000000..37b7ace
--- /dev/null
+++ b/aps-modules/aps-core/src/main/resources/mapper/core/ApsMaterialProductGroupManagementMapper.xml
@@ -0,0 +1,96 @@
+<?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.aps.core.mapper.ApsMaterialProductGroupManagementMapper">
+    
+    <resultMap type="com.aps.core.domain.ApsMaterialProductGroupManagement" id="ApsMaterialProductGroupManagementResult">
+        <result property="id"    column="id"    />
+        <result property="factory"    column="factory"    />
+        <result property="materialCode"    column="material_code"    />
+        <result property="domain"    column="domain"    />
+        <result property="createBy"    column="create_by"    />
+        <result property="createTime"    column="create_time"    />
+        <result property="updateBy"    column="update_by"    />
+        <result property="updateTime"    column="update_time"    />
+        <result property="isMain"    column="is_main"    />
+        <result property="materialType"    column="material_type"    />
+    </resultMap>
+
+    <sql id="selectApsMaterialProductGroupManagementVo">
+        select id, factory, material_code, domain, create_by, create_time, update_by, update_time, is_main, material_type from aps_material_product_group_management
+    </sql>
+
+    <select id="selectApsMaterialProductGroupManagementList" parameterType="ApsMaterialProductGroupManagement" resultMap="ApsMaterialProductGroupManagementResult">
+        <include refid="selectApsMaterialProductGroupManagementVo"/>
+        <where>  
+            <if test="factory != null  and factory != ''"> and factory = #{factory}</if>
+            <if test="materialCode != null  and materialCode != ''"> and material_code = #{materialCode}</if>
+            <if test="domain != null  and domain != ''"> and domain = #{domain}</if>
+            <if test="isMain != null  and isMain != ''"> and is_main = #{isMain}</if>
+            <if test="materialType != null  and materialType != ''"> and material_type = #{materialType}</if>
+        </where>
+    </select>
+    
+    <select id="selectApsMaterialProductGroupManagementById" parameterType="Long" resultMap="ApsMaterialProductGroupManagementResult">
+    </select>
+
+    <insert id="insertApsMaterialProductGroupManagement" parameterType="ApsMaterialProductGroupManagement">
+        insert into aps_material_product_group_management
+        <trim prefix="(" suffix=")" suffixOverrides=",">
+            <if test="id != null">id,</if>
+            <if test="factory != null">factory,</if>
+            <if test="materialCode != null">material_code,</if>
+            <if test="domain != null">domain,</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>
+            <if test="isMain != null">is_main,</if>
+            <if test="materialType != null">material_type,</if>
+         </trim>
+        <trim prefix="values (" suffix=")" suffixOverrides=",">
+            <if test="id != null">#{id},</if>
+            <if test="factory != null">#{factory},</if>
+            <if test="materialCode != null">#{materialCode},</if>
+            <if test="domain != null">#{domain},</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>
+            <if test="isMain != null">#{isMain},</if>
+            <if test="materialType != null">#{materialType},</if>
+         </trim>
+    </insert>
+
+    <update id="updateApsMaterialProductGroupManagement" parameterType="ApsMaterialProductGroupManagement">
+        update aps_material_product_group_management
+        <trim prefix="SET" suffixOverrides=",">
+            <if test="factory != null">factory = #{factory},</if>
+            <if test="materialCode != null">material_code = #{materialCode},</if>
+            <if test="domain != null">domain = #{domain},</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>
+            <if test="isMain != null">is_main = #{isMain},</if>
+            <if test="materialType != null">material_type = #{materialType},</if>
+        </trim>
+        where id = #{id}
+    </update>
+
+    <delete id="deleteApsMaterialProductGroupManagementById" parameterType="Long">
+        delete from aps_material_product_group_management where id = #{id}
+    </delete>
+
+    <delete id="deleteApsMaterialProductGroupManagementByIds" parameterType="String">
+        delete from aps_material_product_group_management where id in 
+        <foreach item="id" collection="array" open="(" separator="," close=")">
+            #{id}
+        </foreach>
+    </delete>
+
+    <delete id="deleteAll" parameterType="String">
+        delete from aps_material_product_group_management
+    </delete>
+</mapper>
\ No newline at end of file

--
Gitblit v1.9.3