package com.iamberry.wechat.service.mapper;


import com.iamberry.wechat.core.entity.receive.ChargerReceive;

import java.util.List;

public interface ChargerReceiveMapper {

    int insert(ChargerReceive record);

    int insertSelective(ChargerReceive record);

    ChargerReceive selectByPrimaryKey(Integer receiveId);

    ChargerReceive selectByOrderId(String orderId);

    int updateByPrimaryKeySelective(ChargerReceive record);

    int updateByOrderId(ChargerReceive record);

    /**
     * 发货
     * @param record
     * @return
     */
    int ship(ChargerReceive record);

    /*获取列表 -- 前台专用*/
    List<ChargerReceive> listChargerReceive(ChargerReceive chargerReceive);

    /*后台专用*/
    List<ChargerReceive> listAdminChargerReceive(ChargerReceive chargerReceive);

    /**
     * 获取用户所拥有的机器的数量
     * @param openId
     * @return
     */
    Integer getApparatusNumber(String openId);
}