DeployBuild.php 600 字节
<?php

namespace App\Models\Project;

use App\Helper\Arr;
use App\Models\Base;
use Illuminate\Support\Facades\Cache;

class DeployBuild extends Base
{
    //设置关联表名
    protected $table = 'gl_project_deploy_build';


    public function setPlanAttribute($value){
        $this->attributes['plan'] = Arr::arrToSet($value, 'trim');
    }

    public function getPlanAttribute($value){
        return Arr::setToArr($value, 'trim');
    }

    public static function clearCache($row){
        $cache_key = 'project_' . $row->original['test_domain'];
        Cache::forget($cache_key);
    }
}