package cn.iocoder.yudao.module.system.api.bpm;

import cn.iocoder.yudao.framework.common.pojo.PageResult;
import cn.iocoder.yudao.module.system.api.bpm.vo.*;

import java.time.LocalDate;
import java.util.List;

/**
 * @Author: jinyd
 * @CreateTime: 2024/8/7  10:00
 * @Description: Bpm事件 API 接口
 * @Version: 4.0
 */
public interface BpmElderlyChangeApi {

    Long addElderlyBedChangeRecord(ElderlyChangeRecordReqVO bedChangeRecordReqVO);

    /**
     * 获得床位变更申请记录分页
     *
     * @param pageReqVO 分页查询
     * @return 床位变更申请记录分页
     */
    PageResult<BedChangeRecordRespVO> getBedChangeRecordPage(BedChangeRecordPageReqApiVO pageReqVO);

    void updateCurrentFlag(Long id);

    ElderlyInfoReqVO getElderlyInfoByChangeId(Long businessId);

    void generateBill(Long businessId, Integer identification, Long startTenantId);

    Boolean checkRepeat(Long elderlyId, LocalDate changeDate, Integer changeType, Long tenantId);

    PageResult<NurseChangeRecordRespVO> getNurseChangeRecordPage(ChangeRecordPageReqApiVO apiVO);

    PageResult<CateringChangeRecordRespVO> getCateringChangeRecordPage(ChangeRecordPageReqApiVO apiVO);

    PageResult<PriceChangeRecordRespVO> getPriceChangeRecordPage(ChangeRecordPageReqApiVO apiVO);

    void convertBed(Long businessId);

    void generatePriceChangeBill(Long businessId);
    void generatePriceChangeBillV2(Long businessId);

    void batchInsertOrUpdatePriceChange(List<PriceChangeRecordReqVO> priceChangeList, Long id, Long tenantId);

    void delectPriceChange(Long changeId, Long tenantId);


    PageResult<TransferChangeRecordRespVO> getTransferChangeRecordPage(ChangeRecordPageReqApiVO apiVO);

    void updateTransferChange(Long businessId);

    Long getMyCopyCount(Long userId);


    ElderlyRetreatRecordRespVO getRetreatRecord(Long businessId);

    ElderlyChangeRecordReqVO getChangeRecord(Long businessId);

}
