package com.yuchen.saas.park.service.service.property.impl;

import com.yuchen.saas.park.api.entity.property.PropertyBillPayDetail;
import com.yuchen.saas.park.service.mapper.property.PropertyBillPayDetailMapper;
import com.yuchen.saas.park.service.service.property.IPropertyBillPayDetailService;
import org.nest.springwrap.core.mp.base.BaseServiceImpl;
import org.springframework.stereotype.Service;

import java.util.List;
import java.util.stream.Collectors;

/**
 * @Author 蔡文强
 * @Date 2024-01-04 10:56
 * @Description 账单缴费记录明细 服务实现类
 */
@Service
public class PropertyBillPayDetailServiceImpl extends BaseServiceImpl<PropertyBillPayDetailMapper, PropertyBillPayDetail> implements IPropertyBillPayDetailService {

    @Override
    public List<Long> listBillIds(long billPayId) {
        List<PropertyBillPayDetail> list = this.lambdaQuery().eq(PropertyBillPayDetail::getBillPayId,billPayId).list();
        return list.stream().map(PropertyBillPayDetail::getBillId).collect(Collectors.toList());
    }

}
