package beilv.competition.task;

import beilv.competition.domain.Competition;
import beilv.competition.mapper.CompetitionMapper;
import beilv.stadium.domain.Stadium;

import java.util.Date;
import java.util.TimerTask;

public class CloseReg extends TimerTask {

    private CompetitionMapper competitionMapper;

    private Integer id;

    public CloseReg(CompetitionMapper competitionMapper, Integer id) {
        this.competitionMapper = competitionMapper;
        this.id = id;
    }

    @Override
    public void run() {
        /*Competition competition = new Competition();
        competition.setId(id);
        competition.setCompetitionState("competiton_state_3");
        this.competitionMapper.updateCompetition(competition);

        //核验当前赛事下已支付的订单
        Stadium stadium = new Stadium();
        stadium.setCompetitionId(String.valueOf(id));
        stadium.setPaymentStatus("payment_status_verification");
        stadium.setVerificationTime(new Date());
        this.competitionMapper.updateBookARace(stadium);*/
    }
}
