package com.erp.warehouse.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.erp.warehouse.entity.StockAlertConfig;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

/**
 * 库存预警配置Mapper
 */
@Mapper
public interface StockAlertConfigMapper extends BaseMapper<StockAlertConfig> {

    @Select("SELECT * FROM stock_alert_config WHERE tenant_id = #{tenantId} LIMIT 1")
    StockAlertConfig findByTenantId(@Param("tenantId") Long tenantId);
}
