package com.reptileclient.jlifeapp.dao.jz;

import cn.hutool.core.date.DateTime;
import com.reptileclient.jlifeapp.entity.hm.HmBookOrder;
import com.reptileclient.jlifeapp.entity.jz.JzBookOrder;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface JzBookOrderMapper {
    int deleteByPrimaryKey(Long id);

    int insert(JzBookOrder record);

    int insertSelective(JzBookOrder record);

    JzBookOrder selectByPrimaryKey(Long id);

    int updateByPrimaryKeySelective(JzBookOrder record);

    int updateByPrimaryKey(JzBookOrder record);

    int insertByBatch(List<JzBookOrder> JzBookOrders);

    int insertHmByBatch(List<HmBookOrder> JzBookOrders);


    JzBookOrder selectNewOne(@Param("shopName") String shopName);

    int deleteByCreateTime(@Param("createTime") String createTime, @Param("shopName") String shopName);

    long selectCountByPhone(String phone);

    int deleteByPhone(String phone);

    int deleteDistinctData(@Param("dateTime") DateTime dateTime);

    int insertClientByBatch(@Param("createTime") String createTime);

    JzBookOrder selectByPaymentNo(String paymentNo);

    int deleteByBetWeenTime(@Param("startTime") DateTime startTime, @Param("endTime") DateTime endTime);

    List<JzBookOrder> selectListByPaymentNo();

    int updateCustomerIdIsNull();

    int deleteByBookOrderNo(@Param("bookOrderNo") String bookOrderNo);
}