package com.njcn.serviceimpl.excelreport;

import com.njcn.mapper.excelreport.GetVoltageDataMapper;
import com.njcn.pojo.excelreport.ConditionData;
import com.njcn.pojo.excelreport.ReportValueData;
import com.njcn.service.excelreport.GetVoltageData;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class GetVoltageDataImpl implements GetVoltageData {
    @Autowired
    private GetVoltageDataMapper getVoltageDataMapper;

    @Override
    public List<ReportValueData> getVoltageData(ConditionData conditionData) {
        List<ReportValueData> list = getVoltageDataMapper.getVoltageData(conditionData);
        Regroup.regroupData(list, true);

        return list;
    }
}
