Added Hellcase Battle job
All checks were successful
Push image to registry / build-image (push) Successful in 5m59s

Still need testing and making proper notifications
This commit is contained in:
2025-03-18 19:40:55 +01:00
parent cfbae6ddbf
commit e8b9517664
9 changed files with 266 additions and 6 deletions

View File

@ -0,0 +1,17 @@
<?php
namespace App\Models;
use Illuminate\Database\Eloquent\Model;
class HellcaseBattle extends Model
{
protected $fillable = [
"battle_id",
"value",
];
public function getUrl() {
return "https://hellcase.com/casebattle/{$this->battle_id}";
}
}

View File

@ -21,6 +21,16 @@ class Job extends Model
return $this->hasMany(JobInfo::class)->with("jobInfoType")->orderBy("created_at");
}
/**
* Get an associative collection of the job infos with their values
* @return \Illuminate\Database\Eloquent\Collection<string, string>>
*/
public function jobInfosTable() {
return $this->jobInfos->mapWithKeys(function ($jobInfo) {
return [$jobInfo->key => $jobInfo->value];
});
}
public function jobRuns()
{
return $this->hasMany(JobRun::class)->orderBy("created_at");