Browse Source

生产计划投产提示,产品检查标准倒序排列

wangxin 10 months ago
parent
commit
105c095b83

+ 3 - 0
src/main/java/cn/ezhizao/project/business/controller/BizProductionPlanDetailSubDetailController.java

@@ -330,6 +330,9 @@ public class BizProductionPlanDetailSubDetailController extends BaseController {
          */
         // 20240703 生产批次工艺版本变更 当前工艺版本需要查询最新的工艺版本保存。
         BizTechnologicalProcess bizTechnologicalProcess = bizTechnologicalProcessService.query().eq("product_id", bizProductionPlanDetailSubDetail.getProductId()).eq("technology_version", bizProductionPlanDetailSubDetail.getTechnologyVersion()).eq("is_history", 0).one();
+        if(bizTechnologicalProcess==null){
+            return error("该产品下没有工序信息,请同步产品信息或检查产品数据");
+        }
         bizProductionPlanDetailSubDetail.setTechnologicalProcessId(bizTechnologicalProcess.getId());
 
         /* 获取生成计划明细 */

+ 1 - 0
src/main/resources/mybatis/business/BizInspectionStandardsMapper.xml

@@ -21,6 +21,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
 
             <if test="standard != null  and standard != ''"> AND standard = #{standard}</if>
         </trim>
+        ORDER BY create_time DESC
     </select>
     <select id="getCheckStandardList" resultType="cn.ezhizao.project.business.domain.BizInspectionStandardsCheck">
             select * from biz_inspection_standards_check where standards_id = #{id} and deleted = 0