From 30e060eee08cc99b6edf038f55785c9cf6b57225 Mon Sep 17 00:00:00 2001 From: liuxiaoxu <1793812695@qq.com> Date: Tue, 28 May 2024 10:45:08 +0800 Subject: [PATCH] =?UTF-8?q?[feat]=E5=93=81=E8=B4=A8=E7=AE=A1=E7=90=86:=20?= =?UTF-8?q?=E9=80=80=E6=8D=A2=E8=B4=A7=E8=AF=A6=E6=83=85=20=E6=96=B0?= =?UTF-8?q?=E5=A2=9E=E5=85=A5=E5=BA=93=E5=90=8E=E9=80=80=E6=8D=A2=E8=B4=A7?= =?UTF-8?q?=E8=AF=A6=E6=83=85=E5=93=81=E8=B4=A8=E6=8A=A5=E5=91=8A=E4=B8=8D?= =?UTF-8?q?=E5=90=88=E6=A0=BC=E6=95=B0=E9=A1=B5=E9=9D=A2afterQualityReport?= =?UTF-8?q?Detail.html=20=E6=96=B0=E5=A2=9E=E5=85=A5=E5=BA=93=E5=90=8E?= =?UTF-8?q?=E9=80=80=E6=8D=A2=E8=B4=A7=E8=AF=A6=E6=83=85=E8=B4=A8=E6=8A=A5?= =?UTF-8?q?=E5=91=8A=E4=B8=8D=E5=90=88=E6=A0=BC=E6=95=B0=E6=8C=89=E9=92=AE?= =?UTF-8?q?=20=E6=96=B0=E5=A2=9E=E5=85=A5=E5=BA=93=E5=90=8E=E9=80=80?= =?UTF-8?q?=E6=8D=A2=E8=B4=A7=E8=AF=A6=E6=83=85=E8=B4=A8=E6=8A=A5=E5=91=8A?= =?UTF-8?q?=E4=B8=8D=E5=90=88=E6=A0=BC=E6=95=B0=E6=8E=A5=E5=8F=A3=20?= =?UTF-8?q?=E6=96=B0=E5=A2=9E=E9=80=9A=E8=BF=87=E7=89=A9=E6=96=99=E5=8F=B7?= =?UTF-8?q?=E5=92=8C=E9=80=80=E8=B4=A7=E5=8D=95=E5=8F=B7=E6=9F=A5=E8=AF=A2?= =?UTF-8?q?=E9=80=80=E6=8D=A2=E8=B4=A7=E8=AF=A6=E6=83=85=E4=BF=A1=E6=81=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../QualityRefundsExchangesController.java | 49 ++++++ .../QualityRefundsExchangesDetailMapper.java | 5 + ...lityRefundsExchangesUnqualifiedMapper.java | 7 + ...IQualityRefundsExchangesDetailService.java | 9 ++ ...ityRefundsExchangesUnqualifiedService.java | 5 + ...lityRefundsExchangesDetailServiceImpl.java | 15 ++ ...efundsExchangesUnqualifiedServiceImpl.java | 10 ++ .../QualityRefundsExchangesDetailMapper.xml | 6 + ...alityRefundsExchangesUnqualifiedMapper.xml | 6 + .../afterQualityReportDetail.html | 139 ++++++++++++++++++ .../returnAfterStorageDetail.html | 15 +- 11 files changed, 259 insertions(+), 7 deletions(-) create mode 100644 ruoyi-admin/src/main/resources/templates/quality/refundsExchanges/afterQualityReportDetail.html diff --git a/ruoyi-admin/src/main/java/com/ruoyi/quality/controller/QualityRefundsExchangesController.java b/ruoyi-admin/src/main/java/com/ruoyi/quality/controller/QualityRefundsExchangesController.java index a1fc5c66..6116a10e 100644 --- a/ruoyi-admin/src/main/java/com/ruoyi/quality/controller/QualityRefundsExchangesController.java +++ b/ruoyi-admin/src/main/java/com/ruoyi/quality/controller/QualityRefundsExchangesController.java @@ -280,4 +280,53 @@ public class QualityRefundsExchangesController extends BaseController } + + /** + * 入库后品质报告不合格数详情页面 + */ + @GetMapping("/afterQualityReportDetail") + public String afterQualityReportDetail( @RequestParam("materialNo") String materialNo, + @RequestParam("refundsExchangesCode") String refundsExchangesCode, ModelMap mmap) + { + if (StringUtils.isEmpty(materialNo)){ + log.warn("物料号为空:{}",materialNo); + } + if (StringUtils.isEmpty(refundsExchangesCode)){ + log.warn("退换货号为空:{}",refundsExchangesCode); + } + QualityRefundsExchangesDetail refundsExchangesDetail = new QualityRefundsExchangesDetail(); + refundsExchangesDetail.setRefundsExchangesCode(refundsExchangesCode); + refundsExchangesDetail.setMaterialNo(materialNo); + QualityRefundsExchangesDetail qualityRefundsExchangesDetail = refundsExchangesDetailService.selectQualityRefundsExchangesDetailByCodeAndNo(refundsExchangesDetail); + + mmap.put("materialNo",materialNo); + mmap.put("refundsExchangesCode",refundsExchangesCode); + mmap.put("qualityRefundsExchangesDetail",qualityRefundsExchangesDetail); + + return prefix + "/afterQualityReportDetail"; + } + + /** + * 保存入库后品质单报告不合格数详情页 + */ + @Log(title = "品质管理品质单", businessType = BusinessType.INSERT) + @PostMapping("/afterQualityReportDetail") + @ResponseBody + public AjaxResult afterQualityReportDetailSave(QualityRefundsExchangesDetail refundsExchangesDetail) + { + return toAjax(refundsExchangesDetailService.saveAfterQualityRefundsExchangesDetail(refundsExchangesDetail)); + } + + /** + * 入库后品质报告不合格数信息列表 + * */ + @ResponseBody + @PostMapping("/getAfterQualityReportDetail") + public TableDataInfo getAfterQualityReportDetail(QualityRefundsExchangesDetail qualityRefundsExchangesDetail){ + startPage(); + List list = refundsExchangesUnqualifiedService.selectRefundsExchangesUnqualifiedListByCodeAndNo(qualityRefundsExchangesDetail); + return getDataTable(list); + } + + } diff --git a/ruoyi-admin/src/main/java/com/ruoyi/quality/mapper/QualityRefundsExchangesDetailMapper.java b/ruoyi-admin/src/main/java/com/ruoyi/quality/mapper/QualityRefundsExchangesDetailMapper.java index 2402ca44..0f8e2319 100644 --- a/ruoyi-admin/src/main/java/com/ruoyi/quality/mapper/QualityRefundsExchangesDetailMapper.java +++ b/ruoyi-admin/src/main/java/com/ruoyi/quality/mapper/QualityRefundsExchangesDetailMapper.java @@ -82,4 +82,9 @@ public interface QualityRefundsExchangesDetailMapper * @return 品质管理退换货单详情集合 */ List selectRefundsExchangesDetailListByCode(String refundsExchangesCode); + + /* + * 通过物料号和退货单号查询退换货详情信息 + * */ + QualityRefundsExchangesDetail selectQualityRefundsExchangesDetailByCodeAndNo(QualityRefundsExchangesDetail refundsExchangesDetail); } diff --git a/ruoyi-admin/src/main/java/com/ruoyi/quality/mapper/QualityRefundsExchangesUnqualifiedMapper.java b/ruoyi-admin/src/main/java/com/ruoyi/quality/mapper/QualityRefundsExchangesUnqualifiedMapper.java index 17f2de56..da964bb4 100644 --- a/ruoyi-admin/src/main/java/com/ruoyi/quality/mapper/QualityRefundsExchangesUnqualifiedMapper.java +++ b/ruoyi-admin/src/main/java/com/ruoyi/quality/mapper/QualityRefundsExchangesUnqualifiedMapper.java @@ -1,6 +1,8 @@ package com.ruoyi.quality.mapper; import java.util.List; + +import com.ruoyi.quality.domain.QualityRefundsExchangesDetail; import com.ruoyi.quality.domain.QualityRefundsExchangesUnqualified; /** @@ -82,4 +84,9 @@ public interface QualityRefundsExchangesUnqualifiedMapper * @return 品质管理退换货不合格分类 */ QualityRefundsExchangesUnqualified selectRefundsExchangesUnqualifiedByNoAndCode(QualityRefundsExchangesUnqualified refundsExchangesUnqualified); + + /* + * 通过物料号和退货单号查询退换货不合格分类集合 + * */ + List selectRefundsExchangesUnqualifiedListByCodeAndNo(QualityRefundsExchangesDetail qualityRefundsExchangesDetail); } diff --git a/ruoyi-admin/src/main/java/com/ruoyi/quality/service/IQualityRefundsExchangesDetailService.java b/ruoyi-admin/src/main/java/com/ruoyi/quality/service/IQualityRefundsExchangesDetailService.java index aa603d7f..40023f9f 100644 --- a/ruoyi-admin/src/main/java/com/ruoyi/quality/service/IQualityRefundsExchangesDetailService.java +++ b/ruoyi-admin/src/main/java/com/ruoyi/quality/service/IQualityRefundsExchangesDetailService.java @@ -2,6 +2,7 @@ package com.ruoyi.quality.service; import java.util.List; import com.ruoyi.quality.domain.QualityRefundsExchangesDetail; +import com.ruoyi.quality.domain.QualityRefundsExchangesUnqualified; /** * 品质管理退换货单详情Service接口 @@ -82,4 +83,12 @@ public interface IQualityRefundsExchangesDetailService */ int restoreQualityRefundsExchangesDetailById(Long refundsExchangesDetailId); + /*通过物料号和退货单号查询退换货详情信息*/ + QualityRefundsExchangesDetail selectQualityRefundsExchangesDetailByCodeAndNo(QualityRefundsExchangesDetail refundsExchangesDetail); + + /* + * 保存入库后退货详情品质报告 + * */ + int saveAfterQualityRefundsExchangesDetail(QualityRefundsExchangesDetail refundsExchangesDetail); + } diff --git a/ruoyi-admin/src/main/java/com/ruoyi/quality/service/IQualityRefundsExchangesUnqualifiedService.java b/ruoyi-admin/src/main/java/com/ruoyi/quality/service/IQualityRefundsExchangesUnqualifiedService.java index 799f11e5..ac84332f 100644 --- a/ruoyi-admin/src/main/java/com/ruoyi/quality/service/IQualityRefundsExchangesUnqualifiedService.java +++ b/ruoyi-admin/src/main/java/com/ruoyi/quality/service/IQualityRefundsExchangesUnqualifiedService.java @@ -1,6 +1,8 @@ package com.ruoyi.quality.service; import java.util.List; + +import com.ruoyi.quality.domain.QualityRefundsExchangesDetail; import com.ruoyi.quality.domain.QualityRefundsExchangesUnqualified; /** @@ -86,4 +88,7 @@ public interface IQualityRefundsExchangesUnqualifiedService * 新增保存品质单报告不良分类 */ int addRefundsExchangesUnqualified(QualityRefundsExchangesUnqualified refundsExchangesUnqualified); + + /*通过物料号和退货单号查询退换货不合格分类集合*/ + List selectRefundsExchangesUnqualifiedListByCodeAndNo(QualityRefundsExchangesDetail qualityRefundsExchangesDetail); } diff --git a/ruoyi-admin/src/main/java/com/ruoyi/quality/service/impl/QualityRefundsExchangesDetailServiceImpl.java b/ruoyi-admin/src/main/java/com/ruoyi/quality/service/impl/QualityRefundsExchangesDetailServiceImpl.java index d14cba8f..1bb023d9 100644 --- a/ruoyi-admin/src/main/java/com/ruoyi/quality/service/impl/QualityRefundsExchangesDetailServiceImpl.java +++ b/ruoyi-admin/src/main/java/com/ruoyi/quality/service/impl/QualityRefundsExchangesDetailServiceImpl.java @@ -161,4 +161,19 @@ public class QualityRefundsExchangesDetailServiceImpl implements IQualityRefunds { return qualityRefundsExchangesDetailMapper.restoreQualityRefundsExchangesDetailById(refundsExchangesDetailId); } + + /* + * 通过物料号和退货单号查询退换货详情信息 + * */ + @Override + public QualityRefundsExchangesDetail selectQualityRefundsExchangesDetailByCodeAndNo(QualityRefundsExchangesDetail refundsExchangesDetail) { + + return qualityRefundsExchangesDetailMapper.selectQualityRefundsExchangesDetailByCodeAndNo(refundsExchangesDetail); + } + + @Override + public int saveAfterQualityRefundsExchangesDetail(QualityRefundsExchangesDetail refundsExchangesDetail) { + + return 1; + } } diff --git a/ruoyi-admin/src/main/java/com/ruoyi/quality/service/impl/QualityRefundsExchangesUnqualifiedServiceImpl.java b/ruoyi-admin/src/main/java/com/ruoyi/quality/service/impl/QualityRefundsExchangesUnqualifiedServiceImpl.java index 8c54e285..4f67ab1a 100644 --- a/ruoyi-admin/src/main/java/com/ruoyi/quality/service/impl/QualityRefundsExchangesUnqualifiedServiceImpl.java +++ b/ruoyi-admin/src/main/java/com/ruoyi/quality/service/impl/QualityRefundsExchangesUnqualifiedServiceImpl.java @@ -3,6 +3,7 @@ package com.ruoyi.quality.service.impl; import java.util.List; import com.ruoyi.common.utils.DateUtils; import com.ruoyi.common.utils.ShiroUtils; +import com.ruoyi.quality.domain.QualityRefundsExchangesDetail; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; import com.ruoyi.quality.mapper.QualityRefundsExchangesUnqualifiedMapper; @@ -148,4 +149,13 @@ public class QualityRefundsExchangesUnqualifiedServiceImpl implements IQualityRe refundsExchangesUnqualified.setUpdateTime(DateUtils.getNowDate()); return qualityRefundsExchangesUnqualifiedMapper.insertQualityRefundsExchangesUnqualified(refundsExchangesUnqualified); } + + /* + * 通过物料号和退货单号查询退换货不合格分类集合 + * */ + @Override + public List selectRefundsExchangesUnqualifiedListByCodeAndNo(QualityRefundsExchangesDetail qualityRefundsExchangesDetail) { + + return qualityRefundsExchangesUnqualifiedMapper.selectRefundsExchangesUnqualifiedListByCodeAndNo(qualityRefundsExchangesDetail); + } } diff --git a/ruoyi-admin/src/main/resources/mapper/quality/QualityRefundsExchangesDetailMapper.xml b/ruoyi-admin/src/main/resources/mapper/quality/QualityRefundsExchangesDetailMapper.xml index 9b38a313..2ab29598 100644 --- a/ruoyi-admin/src/main/resources/mapper/quality/QualityRefundsExchangesDetailMapper.xml +++ b/ruoyi-admin/src/main/resources/mapper/quality/QualityRefundsExchangesDetailMapper.xml @@ -60,6 +60,12 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" where refunds_exchanges_code = #{refundsExchangesCode} + + insert into quality_refunds_exchanges_detail diff --git a/ruoyi-admin/src/main/resources/mapper/quality/QualityRefundsExchangesUnqualifiedMapper.xml b/ruoyi-admin/src/main/resources/mapper/quality/QualityRefundsExchangesUnqualifiedMapper.xml index bed5552f..d1490b8c 100644 --- a/ruoyi-admin/src/main/resources/mapper/quality/QualityRefundsExchangesUnqualifiedMapper.xml +++ b/ruoyi-admin/src/main/resources/mapper/quality/QualityRefundsExchangesUnqualifiedMapper.xml @@ -44,6 +44,12 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" + + insert into quality_refunds_exchanges_unqualified diff --git a/ruoyi-admin/src/main/resources/templates/quality/refundsExchanges/afterQualityReportDetail.html b/ruoyi-admin/src/main/resources/templates/quality/refundsExchanges/afterQualityReportDetail.html new file mode 100644 index 00000000..19d46a0f --- /dev/null +++ b/ruoyi-admin/src/main/resources/templates/quality/refundsExchanges/afterQualityReportDetail.html @@ -0,0 +1,139 @@ + + + + + + + +
+
+ +
+ +
+
+
+ 不合格数 +
+
+
+
+
+
+
+
+ +
+ + +
+ +
+
+ + +
+
+
+
+ +
+ +
+
+
+
+ + + + + + \ No newline at end of file diff --git a/ruoyi-admin/src/main/resources/templates/quality/refundsExchanges/returnAfterStorageDetail.html b/ruoyi-admin/src/main/resources/templates/quality/refundsExchanges/returnAfterStorageDetail.html index 0181c90c..f8125ea6 100644 --- a/ruoyi-admin/src/main/resources/templates/quality/refundsExchanges/returnAfterStorageDetail.html +++ b/ruoyi-admin/src/main/resources/templates/quality/refundsExchanges/returnAfterStorageDetail.html @@ -11,14 +11,14 @@
- +
- +
@@ -26,7 +26,7 @@
- +
@@ -163,7 +163,7 @@ formatter: function(value, row, index) { // 这里直接使用row对象获取refundsExchangesCode,假设它是存在的 var actions = []; - actions.push('报告 '); + actions.push('报告 '); return actions.join(''); } }, @@ -214,9 +214,10 @@ var queryParams = new URLSearchParams(); queryParams.append('materialNo', materialNo); queryParams.append('refundsExchangesCode', encodeURIComponent(refundsExchangesCode)); - - var url = ctx + 'quality/refundsExchanges/qualityReport?' + queryParams.toString(); - $.modal.open("品质报告", url); + console.log("materialNo:"+materialNo); + console.log("refundsExchangesCode:"+refundsExchangesCode); + var url = ctx + 'quality/refundsExchanges/afterQualityReportDetail?' + queryParams.toString(); + $.modal.open("品质报告详情", url); }