添加建设内容

This commit is contained in:
2022-07-29 10:45:13 +08:00
parent d0e816ec6e
commit 4f31bd50c3
17 changed files with 446 additions and 23 deletions

View File

@ -6,6 +6,8 @@ use Illuminate\Database\Eloquent\Model;
class Programs extends Model
{
protected $fillable = ["name", "difficulty", "desc"];
protected $dateFormat = 'U';
public function appends(): \Illuminate\Database\Eloquent\Relations\HasMany
{
return $this->hasMany(ProgramAppends::class, "program_id", "id")->orderByDesc("is_original");