From e31a75558bd7b8ac200194d11d181d0c6e319aa9 Mon Sep 17 00:00:00 2001
From: puzhibing <393733352@qq.com>
Date: 星期五, 13 十月 2023 11:44:21 +0800
Subject: [PATCH] 对接第三方分账接口

---
 ruoyi-modules/ruoyi-order/src/main/java/com/ruoyi/order/service/impl/account/ProfitSharingServiceImpl.java |   19 +++++++++++++++++--
 1 files changed, 17 insertions(+), 2 deletions(-)

diff --git a/ruoyi-modules/ruoyi-order/src/main/java/com/ruoyi/order/service/impl/account/ProfitSharingServiceImpl.java b/ruoyi-modules/ruoyi-order/src/main/java/com/ruoyi/order/service/impl/account/ProfitSharingServiceImpl.java
index 799915d..84ec6f5 100644
--- a/ruoyi-modules/ruoyi-order/src/main/java/com/ruoyi/order/service/impl/account/ProfitSharingServiceImpl.java
+++ b/ruoyi-modules/ruoyi-order/src/main/java/com/ruoyi/order/service/impl/account/ProfitSharingServiceImpl.java
@@ -1,11 +1,11 @@
 package com.ruoyi.order.service.impl.account;
 
+import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
+import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
 import com.github.binarywang.wxpay.bean.ecommerce.ProfitSharingResult;
-import com.ruoyi.common.core.utils.uuid.IdUtils;
 import com.ruoyi.order.domain.pojo.account.ProfitSharing;
 import com.ruoyi.order.mapper.account.ProfitSharingMapper;
 import com.ruoyi.order.service.account.ProfitSharingService;
-import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
 import org.springframework.stereotype.Service;
 
 import java.math.BigDecimal;
@@ -51,4 +51,19 @@
 
         this.saveOrUpdate(profitSharing);
     }
+
+    /**
+     * @description  通过订单id获取
+     * @author  jqs
+     * @date    2023/9/8 10:34
+     * @param orderId
+     * @return  ProfitSharing
+     */
+    @Override
+    public ProfitSharing getByOrderId(String orderId){
+        LambdaQueryWrapper<ProfitSharing> queryWrapper = new LambdaQueryWrapper<>();
+        queryWrapper.eq(ProfitSharing::getDelFlag,0);
+        queryWrapper.eq(ProfitSharing::getOrderId,orderId);
+        return this.getOne(queryWrapper,false);
+    }
 }

--
Gitblit v1.7.1