Helius
2021-07-20 56968f6f02f691397eac17d8fb8f8b34f440ab90
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
package com.xzx.gc.order.service;
 
import com.xzx.gc.entity.OrderDetailInfo;
import com.xzx.gc.order.mapper.OrderDetailMapper;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
 
import java.util.List;
 
@Slf4j
@Service
@Transactional
public class OrderDetailService {
 
    @Autowired
    private OrderDetailMapper orderDetailMapper;
 
    public List<OrderDetailInfo> findByReceiver(String receiver){
        return  orderDetailMapper.findByReceiver(receiver);
    }
 
    public void update(OrderDetailInfo orderDetailInfo){
        orderDetailMapper.updateByPrimaryKeySelective(orderDetailInfo);
    }
 
    public void updateAllById(OrderDetailInfo orderDetailInfo){
        orderDetailMapper.updateByPrimaryKey(orderDetailInfo);
    }
 
    public OrderDetailInfo findById(String orderId){
        return orderDetailMapper.selectByPrimaryKey(orderId);
    }
}