/*
 * Copyright ©2023 CJB-CNIT Team. All rights reserved
 */
package com.openhis.web.pharmacymanage.mapper;

import com.openhis.web.pharmacymanage.dto.FromSearchParam;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.toolkit.Constants;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.openhis.web.pharmacymanage.dto.MedicineSummaryDto;
import com.openhis.web.pharmacymanage.dto.MedicineSummarySearchParam;

@Repository
public interface SummaryDispenseMedicineMapper {

    /**
     * 汇总药品信息列表查询
     *
     * @param page 分页
     * @param queryWrapper 查询条件
     * @return 汇总药品信息
     */
    Page<MedicineSummaryDto> selectMedicationSummaryInfo(@Param("page") Page<MedicineSummaryDto> page,
        @Param(Constants.WRAPPER) QueryWrapper<MedicineSummarySearchParam> queryWrapper);

    /**
     * 汇总药品信息列表查询
     *
     * @param page 分页
     * @param queryWrapper 查询条件
     * @return 汇总药品信息
     */
    Page<MedicineSummaryDto> selectOrderInfo(@Param("page") Page<MedicineSummaryDto> page,
        @Param(Constants.WRAPPER) QueryWrapper<FromSearchParam> queryWrapper);
}
