package com.njcn.system.timer.tasks;

import cn.hutool.core.date.DatePattern;
import cn.hutool.core.date.DateUtil;
import com.njcn.harmonic.api.PqTypicalSourceFeignClient;
import com.njcn.harmonic.pojo.param.UploadParam;
import com.njcn.system.timer.TimerTaskRunner;
import lombok.RequiredArgsConstructor;
import org.springframework.stereotype.Component;



/**
 * 典型源荷指标统计数据
 */
@Component
@RequiredArgsConstructor
public class PqTypicalSourceTaskRunner implements TimerTaskRunner {

    private final PqTypicalSourceFeignClient pqTypicalSourceFeignClient;



    @Override
    public void action(String date) {
        UploadParam param=new UploadParam();
        String dateDeal =DateUtil.yesterday().toString(DatePattern.NORM_DATE_PATTERN);
        param.setTime(dateDeal);
        pqTypicalSourceFeignClient.send(param).getCode();



    }
}
