package com.ruoyi.web.stock.mapper;

import com.ruoyi.web.stock.domain.WarehouseStockAdjust;
import com.ruoyi.web.stock.domain.WarehouseStockAdjustGoods;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * 仓库调整 Mapper。
 */
public interface WarehouseStockAdjustMapper {

    WarehouseStockAdjust selectById(Long id);

    List<WarehouseStockAdjust> selectList(WarehouseStockAdjust query);

    int insert(WarehouseStockAdjust entity);

    int updateTotalAmount(@Param("id") Long id, @Param("totalAmount") java.math.BigDecimal totalAmount, @Param("updateBy") String updateBy);

    int deleteById(@Param("id") Long id, @Param("updateBy") String updateBy);

    List<WarehouseStockAdjustGoods> selectGoodsByAdjustId(Long adjustId);

    int insertGoodsBatch(@Param("list") List<WarehouseStockAdjustGoods> list);

    int deleteGoodsByAdjustId(@Param("adjustId") Long adjustId, @Param("updateBy") String updateBy);

    Integer selectTodayMaxSeq(@Param("orgId") String orgId, @Param("dateText") String dateText);
}
