package com.yonge.cooleshow.mbg.mapper;

import com.yonge.cooleshow.mbg.model.UserOrderPayment;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface UserOrderPaymentMapper {


    int insert(UserOrderPayment record);


    UserOrderPayment selectByTranNo(String transNo);

    int updateByPrimaryKeySelective(UserOrderPayment userOrderPayment);


    List<UserOrderPayment> selectByOrderNo(@Param("orderSn") String orderSn);

    UserOrderPayment selectByOrderNoAndStatus(@Param("orderSn") String orderSn, @Param(
            "payChannel") String payChannel, @Param("payStatus") String payStatus);

    UserOrderPayment selectByOrderNoAndStatusPaying(@Param("orderSn") String orderSn);

    UserOrderPayment selectByOrderNoAndStatusSucceeded(@Param("orderSn") String orderSn);

    /**
     * 查询支付信息
     *
     * @param paymentNo 回调支付订单号
     * @return
     */
    UserOrderPayment selectByAdapayNo(String paymentNo);
}