‘linchangsheng’ 2 weeks ago
parent
commit
52a89bc69f
1 changed files with 12 additions and 3 deletions
  1. 12 3
      src/main/java/com/gree/mall/manager/logic/goods/GoodsApplyLogic.java

+ 12 - 3
src/main/java/com/gree/mall/manager/logic/goods/GoodsApplyLogic.java

@@ -207,12 +207,21 @@ public class GoodsApplyLogic {
             }
         }
 
-        if (ifStatus)
+        if (ifStatus) {
             goodsApplyAddUp.setStatus(ExamineStatusEnum.OK.getKey());
-        else
+        }else {
             goodsApplyAddUp.setStatus(ExamineStatusEnum.WAIT.getKey());
+            goodsApplyAddUp.updateById();
+
+            goodsApplyService.lambdaUpdate()
+                    .set(GoodsApply::getApproveName,null)
+                    .set(GoodsApply::getApproveRemark,null)
+                    .set(GoodsApply::getApproveTime,null)
+                    .eq(GoodsApply::getGoodsApplyId,goodsApplyAddUp.getGoodsApplyId())
+                    .update();
+        }
+
 
-        goodsApplyAddUp.updateById();
         goodsApplyItemService.saveBatch(goodsApplyItemList);
     }