package com.sw.mes.store.mapper;


import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.sw.mes.store.entity.WarehouseModel;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;

/**
 * @Author wupeng
 * @Description 针对表【warehouse_model(仓库库位)】的数据库操作Mapper
 * @Date 11:15 2023/7/24
 * @Param
 * @return
 **/
@Repository
public interface WarehouseModelMapper extends BaseMapper<WarehouseModel> {
    List<WarehouseModel> findByParentId(@Param("id") Long parentId);

    WarehouseModel findByName(@Param("name") String name);

    WarehouseModel findById(@Param("id") Long id);

    List<WarehouseModel> findByUserId(@Param("userId") Integer userId);

    WarehouseModel findByCode(@Param("code") String code);

    Page<WarehouseModel> listByPage(IPage page, @Param("userId") Integer userId, @Param("type") String type);
}




