the browser-facing portion of osu!
at master 926 B view raw
1<?php 2 3// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the GNU Affero General Public License v3.0. 4// See the LICENCE file in the repository root for full licence text. 5 6namespace App\Models; 7 8/** 9 * @property Beatmapset $beatmapset 10 * @property int $beatmapset_id 11 * @property int $fulfilled 12 * @property BeatmapMirror $mirror 13 * @property int $mirror_id 14 * @property int $timestamp 15 * @property User $user 16 * @property int $user_id 17 */ 18class BeatmapDownload extends Model 19{ 20 protected $table = 'osu_downloads'; 21 protected $primaryKey = 'user_id'; 22 23 public $timestamps = false; 24 25 public function beatmapset() 26 { 27 return $this->belongsTo(Beatmapset::class, 'beatmapset_id'); 28 } 29 30 public function mirror() 31 { 32 return $this->belongsTo(BeatmapMirror::class, 'mirror_id'); 33 } 34 35 public function user() 36 { 37 return $this->belongsTo(User::class, 'user_id'); 38 } 39}