<?php

namespace App\Admin\Repositories;

use App\Models\DistAppearanceTemplateLog as Model;
use Dcat\Admin\Repositories\EloquentRepository;

class DistAppearanceTemplateLog extends EloquentRepository
{
    /**
     * Model.
     *
     * @var string
     */
    protected $eloquentClass = Model::class;

    /*
     *  添加模版修改日志
     */
    public static function insertLog($appearanceId,$distId,$templateCode,$content)
    {
        $model = new Model();
        $model->dist_id = $distId;
        $model->appearance_id = $appearanceId;
        $model->template_code = $templateCode;
        $model->content = $content;
        $model->version = generateVersionNumber();
        $model->save();

    }

}
