<?php


namespace crmeb\jobs;
use app\models\store\StoreGp;
use crmeb\interfaces\JobInterface;
use think\queue\Job;

class GpJob implements JobInterface
{
    public function fire(Job $job, $data): void
    {
        if($this->doorder($data))
            $job->delete();
        else {
            $job->delete();
        }
    }

    public function doorder($data)
    {
        StoreGp::createGp($data);
        return true;
    }

}