package com.dxhy.core.thread;

import com.dxhy.common.utils.SpringContextUtils;
import com.dxhy.core.entity.TDxRecordInvoice;
import com.dxhy.core.job.entity.TAcOrg;
import com.dxhy.core.job.service.CheckOneService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

@Component
@Slf4j
public class CheckOneThread {
    public TDxRecordInvoice recordInvoiceInfo;
    public TAcOrg taxOrg;
    @Autowired
    private CheckOneService checkOneService;


    public CheckOneThread(TDxRecordInvoice recordInvoiceInfo, TAcOrg taxOrg) {
        this.recordInvoiceInfo = recordInvoiceInfo;
        this.taxOrg = taxOrg;
    }


    public CheckOneThread() {
    }

    public void start() {
        checkOneService = (CheckOneService) SpringContextUtils.getBean("checkOneService");
        checkOneService.reqCheck(recordInvoiceInfo,taxOrg);
    }
}
