From a9ab570520200d23f677e73dcb80142e0ebe1404 Mon Sep 17 00:00:00 2001 From: Zlimon Date: Fri, 1 Jan 2021 22:15:59 +0100 Subject: [PATCH 01/92] Collection refactor - Extended support for adding new collections to the API and hiscores --- app/Category.php | 24 +-- app/Collection.php | 19 ++- app/Helpers/Helper.php | 8 +- .../Api/AccountCollectionController.php | 6 +- .../Controllers/Api/AccountController.php | 22 ++- .../Controllers/Api/AccountLootController.php | 138 +++++++++--------- .../Controllers/Api/HiscoreController.php | 29 +++- app/Http/Controllers/PageController.php | 38 +++-- app/Http/Resources/AccountBossResource.php | 2 +- app/Http/Resources/AccountResource.php | 2 +- app/NewsCategory.php | 13 ++ app/NewsPost.php | 2 +- app/Notification.php | 38 +++-- app/NotificationCategory.php | 26 ---- ..._06_21_235134_create_collections_table.php | 65 ++++++++- ..._01_01_164127_create_categories_table.php} | 12 +- ...1_164136_create_news_categories_table.php} | 8 +- database/seeds/CollectionSeeder.php | 66 --------- database/seeds/DatabaseSeeder.php | 1 - public/images/boss/nightmare/eldritch_orb.png | Bin 1062 -> 0 bytes .../images/boss/nightmare/harmonised_orb.png | Bin 1027 -> 0 bytes .../boss/nightmare/inquisitors_great_helm.png | Bin 960 -> 0 bytes .../boss/nightmare/inquisitors_hauberk.png | Bin 979 -> 0 bytes .../boss/nightmare/inquisitors_mace.png | Bin 436 -> 0 bytes .../boss/nightmare/inquisitors_plateskirt.png | Bin 651 -> 0 bytes .../images/boss/nightmare/jar_of_dreams.png | Bin 861 -> 0 bytes .../boss/nightmare/little_nightmare.png | Bin 1151 -> 0 bytes .../images/boss/nightmare/nightmare_staff.png | Bin 497 -> 0 bytes public/images/boss/nightmare/volatile_orb.png | Bin 948 -> 0 bytes .../{tztok jad.png => the fight caves.png} | Bin .../boss/{tzkal zuk.png => the inferno.png} | Bin .../images/boss/tzkal_zuk/infernal_cape.png | Bin 833 -> 0 bytes public/images/boss/tzkal_zuk/jal-nib-rek.png | Bin 566 -> 0 bytes public/images/boss/tztok_jad/fire_cape.png | Bin 844 -> 0 bytes public/images/boss/tztok_jad/tzrek-jad.png | Bin 616 -> 0 bytes public/images/{boss => npc}/goblin.png | Bin public/images/{boss => npc}/goblin/beer.png | Bin public/images/{boss => npc}/goblin/bones.png | Bin public/images/{boss => npc}/goblin/coins.png | Bin .../{boss => npc}/goblin/goblin_mail.png | Bin public/images/{boss => npc}/goblin/hammer.png | Bin .../{boss => npc}/goblin/water_rune.png | Bin resources/js/app.js | 1 + resources/js/components/NpcHiscore.vue | 122 ++++++++++++++++ resources/views/hiscore.blade.php | 19 ++- routes/api.php | 6 +- 46 files changed, 427 insertions(+), 240 deletions(-) create mode 100644 app/NewsCategory.php delete mode 100644 app/NotificationCategory.php rename database/migrations/{2020_12_24_135237_create_notification_categories_table.php => 2021_01_01_164127_create_categories_table.php} (63%) rename database/migrations/{2020_08_16_094855_create_categories_table.php => 2021_01_01_164136_create_news_categories_table.php} (73%) delete mode 100644 database/seeds/CollectionSeeder.php delete mode 100644 public/images/boss/nightmare/eldritch_orb.png delete mode 100644 public/images/boss/nightmare/harmonised_orb.png delete mode 100644 public/images/boss/nightmare/inquisitors_great_helm.png delete mode 100644 public/images/boss/nightmare/inquisitors_hauberk.png delete mode 100644 public/images/boss/nightmare/inquisitors_mace.png delete mode 100644 public/images/boss/nightmare/inquisitors_plateskirt.png delete mode 100644 public/images/boss/nightmare/jar_of_dreams.png delete mode 100644 public/images/boss/nightmare/little_nightmare.png delete mode 100644 public/images/boss/nightmare/nightmare_staff.png delete mode 100644 public/images/boss/nightmare/volatile_orb.png rename public/images/boss/{tztok jad.png => the fight caves.png} (100%) rename public/images/boss/{tzkal zuk.png => the inferno.png} (100%) delete mode 100644 public/images/boss/tzkal_zuk/infernal_cape.png delete mode 100644 public/images/boss/tzkal_zuk/jal-nib-rek.png delete mode 100644 public/images/boss/tztok_jad/fire_cape.png delete mode 100644 public/images/boss/tztok_jad/tzrek-jad.png rename public/images/{boss => npc}/goblin.png (100%) rename public/images/{boss => npc}/goblin/beer.png (100%) rename public/images/{boss => npc}/goblin/bones.png (100%) rename public/images/{boss => npc}/goblin/coins.png (100%) rename public/images/{boss => npc}/goblin/goblin_mail.png (100%) rename public/images/{boss => npc}/goblin/hammer.png (100%) rename public/images/{boss => npc}/goblin/water_rune.png (100%) create mode 100644 resources/js/components/NpcHiscore.vue diff --git a/app/Category.php b/app/Category.php index 7e7d34ab..2a0c500e 100644 --- a/app/Category.php +++ b/app/Category.php @@ -4,23 +4,15 @@ use Illuminate\Database\Eloquent\Model; -/** - * App\Category - * - * @property int $id - * @property string $category - * @property-read \Illuminate\Database\Eloquent\Collection|\App\NewsPost[] $newsPost - * @property-read int|null $news_post_count - * @method static \Illuminate\Database\Eloquent\Builder|Category newModelQuery() - * @method static \Illuminate\Database\Eloquent\Builder|Category newQuery() - * @method static \Illuminate\Database\Eloquent\Builder|Category query() - * @method static \Illuminate\Database\Eloquent\Builder|Category whereCategory($value) - * @method static \Illuminate\Database\Eloquent\Builder|Category whereId($value) - * @mixin \Eloquent - */ class Category extends Model { - public function newsPost() { - return $this->hasMany(NewsPost::class); + public function collection() + { + return $this->hasMany(Collection::class); + } + + public function notification() + { + return $this->hasMany(Notification::class); } } diff --git a/app/Collection.php b/app/Collection.php index c917a3a4..1d5d0013 100644 --- a/app/Collection.php +++ b/app/Collection.php @@ -23,11 +23,18 @@ */ class Collection extends Model { - public static function findByName($name) { - return self::where('name', $name)->first(); - } + public static function findByNameAndCategory($name, $category_id) + { + return self::where([['name', $name], ['category_id', $category_id]])->firstOrFail(); + } - public function collection() { - return $this->morphTo(); - } + public function category() + { + return $this->hasOne(Category::class); + } + + public function collection() + { + return $this->morphTo(); + } } diff --git a/app/Helpers/Helper.php b/app/Helpers/Helper.php index baf437ac..e2bd4131 100644 --- a/app/Helpers/Helper.php +++ b/app/Helpers/Helper.php @@ -164,8 +164,12 @@ public static function listClueScrollTiers() public static function listBosses() { - return Collection::where('type', 'boss')->orWhere('type', 'raid')->pluck('name')->toArray(); -// return dd(["abyssal sire", "alchemical hydra", "barrows chests", "bryophyta", "callisto", "cerberus", "chambers of xeric", "chambers of xeric challenge mode", "chaos elemental", "chaos fanatic", "commander zilyana", "corporeal beast", "crazy archaeologist", "dagannoth kings", "dagannoth prime", "dagannoth rex", "dagannoth supreme", "deranged archaeologist", "general graardor", "giant mole","grotesque guardians", "hespori", "kalphite queen", "king black dragon", "kraken", "kreearra", "kril tsutsaroth", "mimic", "the nightmare", "obor", "sarachnis", "scorpia", "skotizo", "the gauntlet", "the corrupted gauntlet", "theatre of blood", "thermonuclear smoke devil", "tzkal zuk", "tztok jad", "venenatis", "vetion", "vorkath", "wintertodt", "zalcano", "zulrah"]); + return Collection::where('category_id', 2)->orWhere('category_id', 3)->pluck('name')->toArray(); + } + + public static function listNpcs() + { + return Collection::where('category_id', 4)->pluck('name')->toArray(); } public static function listAccountTypes() diff --git a/app/Http/Controllers/Api/AccountCollectionController.php b/app/Http/Controllers/Api/AccountCollectionController.php index 5e64175c..2d7ac695 100644 --- a/app/Http/Controllers/Api/AccountCollectionController.php +++ b/app/Http/Controllers/Api/AccountCollectionController.php @@ -38,7 +38,7 @@ public function index($accountUsername, $collectionType) $allCollectionLoot = []; foreach ($allCollections as $key => $collection) { - $findCollection = Collection::findByName($collection->name); + $findCollection = Collection::where('name', $collection->name)->firstOrFail(); $collectionLog = $findCollection->model::where('account_id', $account->id)->first(); @@ -64,7 +64,7 @@ public function show($accountUsername, $collectionName) $account = Account::where('username', $accountUsername)->first(); if ($account) { - $collection = Collection::findByName($collectionName); + $collection = Collection::where('name', $collectionName)->firstOrFail(); if ($collection) { $collectionLog = $collection->model::where('account_id', $account->id)->first(); @@ -87,7 +87,7 @@ public function update($accountUsername, $collectionName, Request $request) $account = Account::where('user_id', auth()->user()->id)->where('username', $accountUsername)->first(); if ($account) { - $collection = Collection::findByName($collectionName); + $collection = Collection::where('name', $collectionName)->firstOrFail(); if ($collection) { $collectionLog = $collection->model::where('account_id', $account->id)->first(); diff --git a/app/Http/Controllers/Api/AccountController.php b/app/Http/Controllers/Api/AccountController.php index 3e0445c6..7a6aa7e4 100644 --- a/app/Http/Controllers/Api/AccountController.php +++ b/app/Http/Controllers/Api/AccountController.php @@ -100,12 +100,12 @@ public function store(Request $request) array_splice($bosses, 13, 1); - $bossCounter = 0; + $bossIndex = 0; $dksKillCount = 0; for ($i = (count($skills) + $clueScrollAmount + 4); $i < (count($skills) + $clueScrollAmount + 4 + count($bosses)); $i++) { - $collection = Collection::findByName($bosses[$bossCounter]); + $collection = Collection::where('name', $bosses[$bossIndex])->firstOrFail(); $collectionLoot = new $collection->model; @@ -113,14 +113,14 @@ public function store(Request $request) $collectionLoot->kill_count = ($playerData[$i + 1][1] >= 0 ? $playerData[$i + 1][1] : 0); $collectionLoot->rank = ($playerData[$i + 1][0] >= 0 ? $playerData[$i + 1][0] : 0); - if (in_array($bosses[$bossCounter], + if (in_array($bosses[$bossIndex], ['dagannoth prime', 'dagannoth rex', 'dagannoth supreme'], true)) { $dksKillCount += ($playerData[$i + 1][1] >= 0 ? $playerData[$i + 1][1] : 0); } $collectionLoot->save(); - $bossCounter++; + $bossIndex++; } /** @@ -128,7 +128,7 @@ public function store(Request $request) * DKS' and we are going to retrieve loot for them from the * collection log, we have to manually create a table. * This might also happen with other bosses in the future - * that share collection log entry, but have seperate hiscores. + * that share collection log entry, but have separate hiscores. */ $dks = new \App\Boss\DagannothKings; @@ -137,6 +137,18 @@ public function store(Request $request) $dks->save(); + $npcs = Helper::listNpcs(); + + foreach ($npcs as $npc) { + $collection = Collection::findByNameAndCategory($npc, 4); + + $collectionLoot = new $collection->model; + + $collectionLoot->account_id = $account->id; + + $collectionLoot->save(); + } + $authStatus->status = "success"; $authStatus->save(); diff --git a/app/Http/Controllers/Api/AccountLootController.php b/app/Http/Controllers/Api/AccountLootController.php index e79b7e77..a1afcee8 100644 --- a/app/Http/Controllers/Api/AccountLootController.php +++ b/app/Http/Controllers/Api/AccountLootController.php @@ -19,105 +19,101 @@ public function update($accountUsername, $collectionName, Request $request) $account = Account::where('user_id', auth()->user()->id)->where('username', $accountUsername)->first(); if ($account) { - $collection = Collection::findByName($collectionName); + $collection = Collection::where('name', $collectionName)->firstOrFail(); - if ($collection) { - $collectionLog = $collection->model::where('account_id', $account->id)->first(); + $collectionLog = $collection->model::where('account_id', $account->id)->first(); - if ($collectionLog) { - $oldValues = $collectionLog->getAttributes(); // Get old data - //array_splice($oldValues, count($oldValues) - 2, 2); // Remove created_at and updated_at + if ($collectionLog) { + $oldValues = $collectionLog->getAttributes(); // Get old data + //array_splice($oldValues, count($oldValues) - 2, 2); // Remove created_at and updated_at - $newValues = $request->except([ - "id", - "account_id", - "kill_count", - "rank", - "obtained", - "created_at", - "updated_at" - ]); + $newValues = $request->except([ + "id", + "account_id", + "kill_count", + "rank", + "obtained", + "created_at", + "updated_at" + ]); - $sums = []; + $sums = []; - $sums["kill_count"] = $oldValues["kill_count"] + 1; + $sums["kill_count"] = $oldValues["kill_count"] + 1; - $uniques = $oldValues["obtained"]; + $uniques = $oldValues["obtained"]; - // Merge old data and new data and sum the total of common keys - foreach (array_keys($newValues + $oldValues) as $lootType) { - if (isset($newValues[$lootType]) && isset($oldValues[$lootType])) { - // If unique loot is detected, increase the total amount of uniques obtained by 1 - if ($oldValues[$lootType] == 0) { - $uniques++; + // Merge old data and new data and sum the total of common keys + foreach (array_keys($newValues + $oldValues) as $lootType) { + if (isset($newValues[$lootType]) && isset($oldValues[$lootType])) { + // If unique loot is detected, increase the total amount of uniques obtained by 1 + if ($oldValues[$lootType] == 0) { + $uniques++; - $dataJson = '{"collection":' . json_encode([$lootType => 0]) . ',"loot":' . json_encode($newValues) . '}'; + $dataJson = '{"collection":' . json_encode([$lootType => 0]) . ',"loot":' . json_encode($newValues) . '}'; - $data = json_decode($dataJson, true); + $data = json_decode($dataJson, true); - $notificationData = [ - "user_id" => auth()->user()->id, - "account_id" => $account->id, - "category_id" => 2, - "icon" => $collectionName, - "message" => $accountUsername . " unlocked a new unique!", - "data" => $data - ]; + $notificationData = [ + "user_id" => auth()->user()->id, + "account_id" => $account->id, + "category_id" => $collection->category_id, + "icon" => $collectionName, + "message" => $accountUsername . " unlocked a new unique!", + "data" => $data + ]; - $notification = Notification::create($notificationData); + $notification = Notification::create($notificationData); - All::dispatch($notification); + All::dispatch($notification); - AccountAll::dispatch($account, $notification); + AccountAll::dispatch($account, $notification); - AccountNewUnique::dispatch($account, $notification); - } - - $sums[$lootType] = (isset($newValues[$lootType]) ? $newValues[$lootType] : 0) + (isset($oldValues) ? $oldValues[$lootType] : 0); + AccountNewUnique::dispatch($account, $notification); } + + $sums[$lootType] = (isset($newValues[$lootType]) ? $newValues[$lootType] : 0) + (isset($oldValues) ? $oldValues[$lootType] : 0); } + } - $sums["obtained"] = $uniques; + $sums["obtained"] = $uniques; - $collectionLog->update($sums); + $collectionLog->update($sums); - $loot = array_diff_key($sums, [ - "id" => 0, - "account_id" => 0, - "kill_count" => 0, - "rank" => 0, - "obtained" => 0, - "created_at" => 0, - "updated_at" => 0 - ]); + $loot = array_diff_key($sums, [ + "id" => 0, + "account_id" => 0, + "kill_count" => 0, + "rank" => 0, + "obtained" => 0, + "created_at" => 0, + "updated_at" => 0 + ]); - $dataJson = '{"collection":' . json_encode($loot) . ',"loot":' . json_encode($newValues) . '}'; + $dataJson = '{"collection":' . json_encode($loot) . ',"loot":' . json_encode($newValues) . '}'; - $data = json_decode($dataJson, true); + $data = json_decode($dataJson, true); - $notificationData = [ - "user_id" => auth()->user()->id, - "account_id" => $account->id, - "category_id" => 2, - "icon" => $collectionName, - "message" => $accountUsername . " defeated " . $collection->alias . "!", - "data" => $data - ]; + $notificationData = [ + "user_id" => auth()->user()->id, + "account_id" => $account->id, + "category_id" => $collection->category_id, + "icon" => $collectionName, + "message" => $accountUsername . " defeated " . $collection->alias . "!", + "data" => $data + ]; - $notification = Notification::create($notificationData); + $notification = Notification::create($notificationData); - All::dispatch($notification); + All::dispatch($notification); - AccountAll::dispatch($account, $notification); + AccountAll::dispatch($account, $notification); - AccountKill::dispatch($account, $notification); + AccountKill::dispatch($account, $notification); - return response()->json($collectionLog, 200); - } else { - return response("This account does not have any registered loot for " . $collection->name, 404); - } + return response()->json($collectionLog, 200); } else { - return response("This collection could not be found", 404); + return response("This account does not have any registered loot for " . $collection->name, 404); } } else { return response("This account is not authenticated with " . auth()->user()->name, 401); diff --git a/app/Http/Controllers/Api/HiscoreController.php b/app/Http/Controllers/Api/HiscoreController.php index 814001e0..ecd91876 100644 --- a/app/Http/Controllers/Api/HiscoreController.php +++ b/app/Http/Controllers/Api/HiscoreController.php @@ -79,7 +79,7 @@ public function skill($skillName) public function boss($bossName) { if (Account::count() > 0) { - $collection = Collection::findByName($bossName); + $collection = Collection::where('name', $bossName)->firstOrFail(); $boss = $collection->model::with('account')->orderByDesc('kill_count')->get(); @@ -102,4 +102,31 @@ public function boss($bossName) return response()->json("There are no linked accounts", 404); } } + + public function npc($npcName) + { + if (Account::count() > 0) { + $collection = Collection::where('name', $npcName)->firstOrFail(); + + $npc = $collection->model::with('account')->orderByDesc('kill_count')->get(); + + $sumKills = $collection->model::selectRaw('SUM(kill_count) AS total_kill_count') + ->selectRaw('COUNT(*) AS total_kills') + ->first(); + + $averageTotalKills = $sumKills["total_kill_count"] / $sumKills["total_kills"]; + + return BossHiscoreResource::collection($npc) + ->additional([ + 'meta' => [ + 'npc' => str_replace(" ", "_", $npcName), + 'alias' => $collection->alias, + 'total_kills' => number_format($sumKills["total_kill_count"]), + 'average_total_kills' => round($averageTotalKills), + ] + ]); + } else { + return response()->json("There are no linked accounts", 404); + } + } } diff --git a/app/Http/Controllers/PageController.php b/app/Http/Controllers/PageController.php index 4e9c63f0..f64d3cee 100644 --- a/app/Http/Controllers/PageController.php +++ b/app/Http/Controllers/PageController.php @@ -16,7 +16,7 @@ public function index() } /** - * Show the latest account updates. + * Show the latest account updates * * @return */ @@ -28,27 +28,43 @@ public function updateLog() } /** - * Show the skill hiscores. + * Show the skill hiscores * * @return */ public function hiscore($hiscoreType, $hiscoreName) { - $hiscoreList = Helper::listSkills(); - - array_push($hiscoreList, "overall"); + switch ($hiscoreType) { + case "skill": + $hiscoreList = Helper::listSkills(); + array_push($hiscoreList, "overall"); + break; + case "boss": + $hiscoreList = Helper::listBosses(); + break; + case "npc": + $hiscoreList = Helper::listNpcs(); + break; + default: + return abort(404); + } - if ($hiscoreType == "boss") { - $hiscoreList = Helper::listBosses(); - $hiscoreList = array_values($hiscoreList); + if (!in_array($hiscoreName, $hiscoreList)) { + return abort(404); } - list($hiscoreListTop, $hiscoreListBottom) = array_chunk($hiscoreList, - ceil(count($hiscoreList) / 2)); // Split skills array into two arrays for a top and bottom skill bar + if (count($hiscoreList) > 1) { + list($hiscoreListTop, $hiscoreListBottom) = array_chunk($hiscoreList, + ceil(count($hiscoreList) / 2)); // Split skills array into two arrays for a top and bottom skill bar + } else { + $hiscoreListTop = $hiscoreList; + $hiscoreListBottom = $hiscoreList; + } $accountCount = Account::count(); return view('hiscore', - compact('hiscoreType', 'hiscoreName', 'hiscoreList', 'hiscoreListTop', 'hiscoreListBottom', 'accountCount')); + compact('hiscoreType', 'hiscoreName', 'hiscoreList', 'hiscoreListTop', 'hiscoreListBottom', + 'accountCount')); } } diff --git a/app/Http/Resources/AccountBossResource.php b/app/Http/Resources/AccountBossResource.php index a1267711..af2441ff 100644 --- a/app/Http/Resources/AccountBossResource.php +++ b/app/Http/Resources/AccountBossResource.php @@ -35,7 +35,7 @@ public function with($request) $bossHiscores = []; foreach ($bosses as $bossName) { - $collection = Collection::findByName($bossName); + $collection = Collection::where('name', $bossName)->firstOrFail(); $bossHiscores[$bossName] = $collection->model::where('account_id', $this->id)->first(); diff --git a/app/Http/Resources/AccountResource.php b/app/Http/Resources/AccountResource.php index a91b3b44..0b820b55 100644 --- a/app/Http/Resources/AccountResource.php +++ b/app/Http/Resources/AccountResource.php @@ -44,7 +44,7 @@ public function with($request) $bossHiscores = []; foreach ($bosses as $bossName) { - $collection = Collection::findByName($bossName); + $collection = Collection::where('name', $bossName)->firstOrFail(); $bossHiscores[$bossName] = $collection->model::first(); } diff --git a/app/NewsCategory.php b/app/NewsCategory.php new file mode 100644 index 00000000..bdddb62a --- /dev/null +++ b/app/NewsCategory.php @@ -0,0 +1,13 @@ +hasMany(NewsPost::class); + } +} diff --git a/app/NewsPost.php b/app/NewsPost.php index 75fb668b..85e06df7 100644 --- a/app/NewsPost.php +++ b/app/NewsPost.php @@ -44,7 +44,7 @@ public function user() { } public function category() { - return $this->belongsTo(Category::class); + return $this->belongsTo(NewsCategory::class); } public function image() { diff --git a/app/Notification.php b/app/Notification.php index 851663de..141d2710 100644 --- a/app/Notification.php +++ b/app/Notification.php @@ -35,23 +35,31 @@ */ class Notification extends Model { - protected $fillable = [ - 'user_id', 'account_id', 'category_id', 'icon', 'message', 'data' - ]; + protected $fillable = [ + 'user_id', + 'account_id', + 'category_id', + 'icon', + 'message', + 'data' + ]; - protected $casts = [ - 'data' => 'array' - ]; + protected $casts = [ + 'data' => 'array' + ]; - public function user() { - return $this->belongsTo(User::class); - } + public function user() + { + return $this->belongsTo(User::class); + } - public function account() { - return $this->belongsTo(Account::class); - } + public function account() + { + return $this->belongsTo(Account::class); + } - public function category() { - return $this->belongsTo(NotificationCategory::class); - } + public function category() + { + return $this->belongsTo(Category::class); + } } diff --git a/app/NotificationCategory.php b/app/NotificationCategory.php deleted file mode 100644 index 2831e640..00000000 --- a/app/NotificationCategory.php +++ /dev/null @@ -1,26 +0,0 @@ -hasMany(Notification::class); - } -} diff --git a/database/migrations/2020_06_21_235134_create_collections_table.php b/database/migrations/2020_06_21_235134_create_collections_table.php index 10cc36f4..5676d778 100644 --- a/database/migrations/2020_06_21_235134_create_collections_table.php +++ b/database/migrations/2020_06_21_235134_create_collections_table.php @@ -14,11 +14,74 @@ class CreateCollectionsTable extends Migration public function up() { Schema::create('collections', function (Blueprint $table) { + $table->integer('category_id')->unsigned(); $table->string('name')->unique(); $table->string('alias'); - $table->enum('type', ['boss', 'raid', 'npc', 'clue', 'minigame', 'other']); $table->string('model'); }); + + /** + * Categories: + * 1 - skill + * 2 - boss + * 3 - raid + * 4 - npc + * 5 - clue + * 6 - minigame + * 7 - other + * 8 - account + */ + + DB::table('collections')->insert([ + ["category_id" => 2, "name" => "abyssal sire", "alias" => "Abyssal Sire", "model" => "App\Boss\AbyssalSire"], + ["category_id" => 2, "name" => "alchemical hydra", "alias" => "Alchemical Hydra", "model" => "App\Boss\AlchemicalHydra"], + ["category_id" => 2, "name" => "barrows chests", "alias" => "Barrows Chests", "model" => "App\Boss\BarrowsChests"], + ["category_id" => 2, "name" => "bryophyta", "alias" => "Bryophyta", "model" => "App\Boss\Bryophyta"], + ["category_id" => 2, "name" => "callisto", "alias" => "Callisto", "model" => "App\Boss\Callisto"], + ["category_id" => 2, "name" => "cerberus", "alias" => "Cerberus", "model" => "App\Boss\Cerberus"], + ["category_id" => 2, "name" => "chaos elemental", "alias" => "Chaos Elemental", "model" => "App\Boss\ChaosElemental"], + ["category_id" => 2, "name" => "chaos fanatic", "alias" => "Chaos Fanatic", "model" => "App\Boss\ChaosFanatic"], + ["category_id" => 2, "name" => "commander zilyana", "alias" => "Commander Zilyana", "model" => "App\Boss\CommanderZilyana"], + ["category_id" => 2, "name" => "corporeal beast", "alias" => "Corporeal Beast", "model" => "App\Boss\CorporealBeast"], + ["category_id" => 2, "name" => "crazy archaeologist", "alias" => "Crazy Archaeologist", "model" => "App\Boss\CrazyArchaeologist"], + ["category_id" => 2, "name" => "dagannoth kings", "alias" => "Dagannoth Kings", "model" => "App\Boss\DagannothKings"], + ["category_id" => 2, "name" => "dagannoth prime", "alias" => "Dagannoth Prime", "model" => "App\Boss\DagannothPrime"], + ["category_id" => 2, "name" => "dagannoth rex", "alias" => "Dagannoth Rex", "model" => "App\Boss\DagannothRex"], + ["category_id" => 2, "name" => "dagannoth supreme", "alias" => "Dagannoth Surpeme", "model" => "App\Boss\DagannothSupreme"], + ["category_id" => 2, "name" => "deranged archaeologist", "alias" => "Deranged Archaeologist", "model" => "App\Boss\DerangedArchaeologist"], + ["category_id" => 2, "name" => "general graardor", "alias" => "General Graardor", "model" => "App\Boss\GeneralGraardor"], + ["category_id" => 2, "name" => "giant mole", "alias" => "Giant Mole", "model" => "App\Boss\GiantMole"], + ["category_id" => 2, "name" => "grotesque guardians", "alias" => "Grotesque Guardians", "model" => "App\Boss\GrotesqueGuardians"], + ["category_id" => 2, "name" => "hespori", "alias" => "Hespori", "model" => "App\Boss\Hespori"], + ["category_id" => 2, "name" => "kalphite queen", "alias" => "Kalphite Queen", "model" => "App\Boss\KalphiteQueen"], + ["category_id" => 2, "name" => "king black dragon", "alias" => "King Black Dragon", "model" => "App\Boss\KingBlackDragon"], + ["category_id" => 2, "name" => "kraken", "alias" => "Kraken", "model" => "App\Boss\Kraken"], + ["category_id" => 2, "name" => "kreearra", "alias" => "Kree'arra", "model" => "App\Boss\KreeArra"], + ["category_id" => 2, "name" => "kril tsutsaroth", "alias" => "K'ril Tsutsaroth", "model" => "App\Boss\KrilTsutsaroth"], + ["category_id" => 2, "name" => "mimic", "alias" => "Mimic", "model" => "App\Boss\Mimic"], + ["category_id" => 2, "name" => "obor", "alias" => "Obor", "model" => "App\Boss\Obor"], + ["category_id" => 2, "name" => "sarachnis", "alias" => "Sarachnis", "model" => "App\Boss\Sarachnis"], + ["category_id" => 2, "name" => "scorpia", "alias" => "Scorpia", "model" => "App\Boss\Scorpia"], + ["category_id" => 2, "name" => "skotizo", "alias" => "Skotizo", "model" => "App\Boss\Skotizo"], + ["category_id" => 2, "name" => "the corrupted gauntlet", "alias" => "The Corrupted Gauntlet", "model" => "App\Boss\TheCorruptedGauntlet"], + ["category_id" => 2, "name" => "the fight caves", "alias" => "The Fight Caves", "model" => "App\Boss\TheFightCaves"], + ["category_id" => 2, "name" => "the gauntlet", "alias" => "The Gauntlet", "model" => "App\Boss\TheGauntlet"], + ["category_id" => 2, "name" => "the inferno", "alias" => "The Inferno", "model" => "App\Boss\TheInferno"], + ["category_id" => 2, "name" => "the nightmare", "alias" => "The Nightmare", "model" => "App\Boss\TheNightmare"], + ["category_id" => 2, "name" => "thermonuclear smoke devil", "alias" => "Thermonuclear Smoke Devil", "model" => "App\Boss\ThermonuclearSmokeDevil"], + ["category_id" => 2, "name" => "venenatis", "alias" => "Venenatis", "model" => "App\Boss\Venenatis"], + ["category_id" => 2, "name" => "vetion", "alias" => "Vet'ion", "model" => "App\Boss\Vetion"], + ["category_id" => 2, "name" => "vorkath", "alias" => "Vorkath", "model" => "App\Boss\Vorkath"], + ["category_id" => 2, "name" => "wintertodt", "alias" => "Wintertodt", "model" => "App\Boss\Wintertodt"], + ["category_id" => 2, "name" => "zalcano", "alias" => "Zalcano", "model" => "App\Boss\Zalcano"], + ["category_id" => 2, "name" => "zulrah", "alias" => "Zulrah", "model" => "App\Boss\Zulrah"], + + ["category_id" => 3, "name" => "chambers of xeric", "alias" => "Chambers of Xeric", "model" => "App\Raid\ChambersOfXeric"], + ["category_id" => 3, "name" => "chambers of xeric challenge mode", "alias" => "COX: Challenge Mode", "model" => "App\Raid\ChambersOfXericChallengeMode"], + ["category_id" => 3, "name" => "theatre of blood", "alias" => "Theatre of Blood", "model" => "App\Raid\TheatreOfBlood"], + + ["category_id" => 4, "name" => "goblin", "alias" => "Goblin", "model" => "App\Npc\Goblin"], // TODO remove later + ]); } /** diff --git a/database/migrations/2020_12_24_135237_create_notification_categories_table.php b/database/migrations/2021_01_01_164127_create_categories_table.php similarity index 63% rename from database/migrations/2020_12_24_135237_create_notification_categories_table.php rename to database/migrations/2021_01_01_164127_create_categories_table.php index 9fb0eec9..1dff0dd6 100644 --- a/database/migrations/2020_12_24_135237_create_notification_categories_table.php +++ b/database/migrations/2021_01_01_164127_create_categories_table.php @@ -4,7 +4,7 @@ use Illuminate\Database\Schema\Blueprint; use Illuminate\Support\Facades\Schema; -class CreateNotificationCategoriesTable extends Migration +class CreateCategoriesTable extends Migration { /** * Run the migrations. @@ -13,16 +13,20 @@ class CreateNotificationCategoriesTable extends Migration */ public function up() { - Schema::create('notification_categories', function (Blueprint $table) { + Schema::create('categories', function (Blueprint $table) { $table->id(); $table->string('category'); }); - DB::table('notification_categories')->insert( + DB::table('categories')->insert( [ ["category" => "skill"], ["category" => "boss"], ["category" => "raid"], + ["category" => "npc"], + ["category" => 'clue'], + ["category" => 'minigame'], + ["category" => 'other'], ["category" => "account"], ] ); @@ -35,6 +39,6 @@ public function up() */ public function down() { - Schema::dropIfExists('notification_categories'); + Schema::dropIfExists('categories'); } } diff --git a/database/migrations/2020_08_16_094855_create_categories_table.php b/database/migrations/2021_01_01_164136_create_news_categories_table.php similarity index 73% rename from database/migrations/2020_08_16_094855_create_categories_table.php rename to database/migrations/2021_01_01_164136_create_news_categories_table.php index 7ace9919..103d4fd1 100644 --- a/database/migrations/2020_08_16_094855_create_categories_table.php +++ b/database/migrations/2021_01_01_164136_create_news_categories_table.php @@ -4,7 +4,7 @@ use Illuminate\Database\Schema\Blueprint; use Illuminate\Support\Facades\Schema; -class CreateCategoriesTable extends Migration +class CreateNewsCategoriesTable extends Migration { /** * Run the migrations. @@ -13,12 +13,12 @@ class CreateCategoriesTable extends Migration */ public function up() { - Schema::create('categories', function (Blueprint $table) { + Schema::create('news_categories', function (Blueprint $table) { $table->id(); $table->string('category'); }); - DB::table('categories')->insert( + DB::table('news_categories')->insert( [ ["category" => "News"], ["category" => "Event"], @@ -34,6 +34,6 @@ public function up() */ public function down() { - Schema::dropIfExists('categories'); + Schema::dropIfExists('news_categories'); } } diff --git a/database/seeds/CollectionSeeder.php b/database/seeds/CollectionSeeder.php deleted file mode 100644 index 39c68e2d..00000000 --- a/database/seeds/CollectionSeeder.php +++ /dev/null @@ -1,66 +0,0 @@ -insert([ - ["name" => "abyssal sire", "alias" => "Abyssal Sire", "type" => "boss", "model" => "App\Boss\AbyssalSire"], - ["name" => "alchemical hydra", "alias" => "Alchemical Hydra", "type" => "boss", "model" => "App\Boss\AlchemicalHydra"], - ["name" => "barrows chests", "alias" => "Barrows Chests", "type" => "boss", "model" => "App\Boss\BarrowsChests"], - ["name" => "bryophyta", "alias" => "Bryophyta", "type" => "boss", "model" => "App\Boss\Bryophyta"], - ["name" => "callisto", "alias" => "Callisto", "type" => "boss", "model" => "App\Boss\Callisto"], - ["name" => "cerberus", "alias" => "Cerberus", "type" => "boss", "model" => "App\Boss\Cerberus"], - ["name" => "chambers of xeric", "alias" => "Chambers of Xeric", "type" => "raid", "model" => "App\Raid\ChambersOfXeric"], - ["name" => "chambers of xeric challenge mode", "alias" => "COX: Challenge Mode", "type" => "raid", "model" => "App\Raid\ChambersOfXericChallengeMode"], - ["name" => "chaos elemental", "alias" => "Chaos Elemental", "type" => "boss", "model" => "App\Boss\ChaosElemental"], - ["name" => "chaos fanatic", "alias" => "Chaos Fanatic", "type" => "boss", "model" => "App\Boss\ChaosFanatic"], - ["name" => "commander zilyana", "alias" => "Commander Zilyana", "type" => "boss", "model" => "App\Boss\CommanderZilyana"], - ["name" => "corporeal beast", "alias" => "Corporeal Beast", "type" => "boss", "model" => "App\Boss\CorporealBeast"], - ["name" => "crazy archaeologist", "alias" => "Crazy Archaeologist", "type" => "boss", "model" => "App\Boss\CrazyArchaeologist"], - ["name" => "dagannoth prime", "alias" => "Dagannoth Prime", "type" => "boss", "model" => "App\Boss\DagannothPrime"], - ["name" => "dagannoth rex", "alias" => "Dagannoth Rex", "type" => "boss", "model" => "App\Boss\DagannothRex"], - ["name" => "dagannoth supreme", "alias" => "Dagannoth Surpeme", "type" => "boss", "model" => "App\Boss\DagannothSupreme"], - ["name" => "deranged archaeologist", "alias" => "Deranged Archaeologist", "type" => "boss", "model" => "App\Boss\DerangedArchaeologist"], - ["name" => "general graardor", "alias" => "General Graardor", "type" => "boss", "model" => "App\Boss\GeneralGraardor"], - ["name" => "giant mole", "alias" => "Giant Mole", "type" => "boss", "model" => "App\Boss\GiantMole"], - ["name" => "grotesque guardians", "alias" => "Grotesque Guardians", "type" => "boss", "model" => "App\Boss\GrotesqueGuardians"], - ["name" => "hespori", "alias" => "Hespori", "type" => "boss", "model" => "App\Boss\Hespori"], - ["name" => "kalphite queen", "alias" => "Kalphite Queen", "type" => "boss", "model" => "App\Boss\KalphiteQueen"], - ["name" => "king black dragon", "alias" => "King Black Dragon", "type" => "boss", "model" => "App\Boss\KingBlackDragon"], - ["name" => "kraken", "alias" => "Kraken", "type" => "boss", "model" => "App\Boss\Kraken"], - ["name" => "kreearra", "alias" => "Kree'arra", "type" => "boss", "model" => "App\Boss\KreeArra"], - ["name" => "kril tsutsaroth", "alias" => "K'ril Tsutsaroth", "type" => "boss", "model" => "App\Boss\KrilTsutsaroth"], - ["name" => "mimic", "alias" => "Mimic", "type" => "boss", "model" => "App\Boss\Mimic"], - // ["name" => "nightmare", "alias" => "Nightmare", "type" => "boss", "model" => "App\Boss\TheNightmare"], - ["name" => "obor", "alias" => "Obor", "type" => "boss", "model" => "App\Boss\Obor"], - ["name" => "sarachnis", "alias" => "Sarachnis", "type" => "boss", "model" => "App\Boss\Sarachnis"], - ["name" => "scorpia", "alias" => "Scorpia", "type" => "boss", "model" => "App\Boss\Scorpia"], - ["name" => "skotizo", "alias" => "Skotizo", "type" => "boss", "model" => "App\Boss\Skotizo"], - ["name" => "the gauntlet", "alias" => "The Gauntlet", "type" => "boss", "model" => "App\Boss\TheGauntlet"], - ["name" => "the corrupted gauntlet", "alias" => "The Corrupted Gauntlet", "type" => "boss", "model" => "App\Boss\TheCorruptedGauntlet"], - ["name" => "theatre of blood", "alias" => "Theatre of Blood", "type" => "raid", "model" => "App\Raid\TheatreOfBlood"], - ["name" => "thermonuclear smoke devil", "alias" => "Thermonuclear Smoke Devil", "type" => "boss", "model" => "App\Boss\ThermonuclearSmokeDevil"], - ["name" => "tzkal zuk", "alias" => "TzKal-Zuk", "type" => "boss", "model" => "App\Boss\TheInferno"], - ["name" => "tztok jad", "alias" => "TzTok-Jad", "type" => "boss", "model" => "App\Boss\TheFightCaves"], - ["name" => "venenatis", "alias" => "Venenatis", "type" => "boss", "model" => "App\Boss\Venenatis"], - ["name" => "vetion", "alias" => "Vetion", "type" => "boss", "model" => "App\Boss\Vetion"], - ["name" => "vorkath", "alias" => "Vorkath", "type" => "boss", "model" => "App\Boss\Vorkath"], - ["name" => "wintertodt", "alias" => "Wintertodt", "type" => "boss", "model" => "App\Boss\Wintertodt"], - ["name" => "zalcano", "alias" => "Zalcano", "type" => "boss", "model" => "App\Boss\Zalcano"], - ["name" => "zulrah", "alias" => "Zulrah", "type" => "boss", "model" => "App\Boss\Zulrah"], - ["name" => "dagannoth kings", "alias" => "Dagannoth Kings", "type" => "boss", "model" => "App\Boss\DagannothKings"], - // ["name" => "the fight caves", "alias" => "The Fight caves", "type" => "boss", "model" => "App\Boss\TheFightCaves"], - // ["name" => "the inferno", "alias" => "something", "type" => "boss", "model" => "App\Boss\TheInferno"], - ["name" => "the nightmare", "alias" => "The Nightmare", "type" => "boss", "model" => "App\Boss\TheNightmare"], - ["name" => "goblin", "alias" => "Goblin", "type" => "npc", "model" => "App\Npc\Goblin"], // TODO remove later - ]); - } -} diff --git a/database/seeds/DatabaseSeeder.php b/database/seeds/DatabaseSeeder.php index 3afb8f42..e7e6a4e9 100644 --- a/database/seeds/DatabaseSeeder.php +++ b/database/seeds/DatabaseSeeder.php @@ -12,6 +12,5 @@ class DatabaseSeeder extends Seeder public function run() { $this->call(UserSeeder::class); - $this->call(CollectionSeeder::class); } } diff --git a/public/images/boss/nightmare/eldritch_orb.png b/public/images/boss/nightmare/eldritch_orb.png deleted file mode 100644 index dcf38e0dc1d79fc4c4f919970b542da2e4c97a7e..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1062 zcmV+>1ljwEP)2~ox8*R@q(N6JA?sTq z5W9w*sXUyUEynduNd%VuNsziIb^mS5Gr|y5o|V-iQgFel3j6BJ6X;Aw|!J zK>PyYrLm+qSRaKfrvw`3ZqjVz&t^pCju4Q4+=9NDBAlEmz_ELJG~LpmDy%@wkQNmo z4Rm$Fg()S<_zSChZjjcQhHPglX*TdM%x$uNAnb&mdrH>!Of*G`&^KL#Q;!SKH7O&Y!C4D>9#5c1;AwSr&ANe%;^t(15&J zDM4{~(9gm)VjCa7ZHLt-hwpPeT5jc{@rD+4BiX3AqM@gwM1I3w)D7h=gK&mf8VXG# z`K0C_IA4eRvr*PV{~!ibs{vUY3f{1ZRO4_ys?Y0Cc{XjqSLz!Q~&?~07*qoM6N<$g3Ye#Pyhe` diff --git a/public/images/boss/nightmare/harmonised_orb.png b/public/images/boss/nightmare/harmonised_orb.png deleted file mode 100644 index ad6bc1ece5c1efd289eaae25e61fe46888c64b43..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1027 zcmV+e1pNDnP)#G5sJVhBr`h~enril04$S1RDbaZhQSBWTpfhm)`}D7?MTU2tjm;CEZz(#4to<) z;P40G3cg`bwwYyInD`D=!_&}qjY8q)l%@etY`E~Dky-wev} z@Mm1~FT&)TN4e(?l$UxSt8?R1T`i=tVo2l~>`#%bDWxFdkak+l0$vOJi1vjQX4lg< zXbSv}`l%(LKfjJ#jULhh1>z-HtZe&|(}e*# zQdEW`igPSj^VA~j_k#?m`|)cA)G`@>!#53c&uvt?dr)e3LuqzE>Fh*dy&I`H1&BGE zf#^e0VSuE{GExd3j#t?*^x`j;B?`p)Y3{`;(8d0{Ft!gs>uf`@r3o^F1vx4m%ThjB z1u^NFh)(69Hoo#7#o=7Hk3luguY>_z_CJAhY?c9;ItNkS+yRxA^A_ zEv^s>hKfU;sgb#1?gwVu>@pj7>sQao$SO@h#(A+A!Cdo#&9?$4rPgkiDqbqnklB4nwe=9W||OD&>wvAb1vWO zv#ZmwyEi@X<=owK?#|~vzs}ay_J3I5YGv=$TVv;1YJq$5xayYX=iTJ^xEmTA^qW1O znQ`S}G1{E@*{LbNmiyI8r4F#YZVEhbD+>!=K#Yxycqjm#PE5FsZ^*(ge6zY5c|u-6ye0DhG6yhWQ|JVa$M`HyF+R%YjTalX5NKz8-EFU}MI+kX z-1Go(ST++Fo&Xwe5GJ4i0&pOgYX%4l-21I94`B6aZ#M!23QrI&01#jR0Tu_c-f0Tx z!`p2yz^nih6r1BEWWnwNO5hzVa3A08+$liPb3E08*0#2$=qKIyunat1A!E+0k)J z0wQejIi%wT?*P-++nXHd&*i1}NPIKy|NM65fvB|jd^}tLrFwdj11Urb8R5fgzs}D+ z4EdxSB5dkOI*@_FO8^1dav%f*6-LP`nE|jzhZ>?nX1$XLh~%vYM5t_a2}b3v&fFsJ zV1a*A3&gbrqA3bUFbb8b%O-O|AT02kGy=pr9Thqzl;nI*sKj=Cd{oE$+mq0QkcMc1 z)O&1aCRE*BT^^>Zz1>y%)2^E7Zv|A~4#z8zmjp!bi37vp_mXsVHCudb(Y)Ox_D0Jd2zG?0@t7Wg%Jy ia+k$7x=-L0dBD^(xjjw){&> zpull*Yqg!7oaezT>3E)WeZR0)1;5lRnI9j^^k6I>;#hWvLp@y`Isz1G2!Y`!&?3kx zAUIMDRj?N@RES_JRI+j}r{g=M1nEfnzKlmf<~_G5ap+|}=(P2_L6AN>XMrtNVw zl&gL(gQ7b5&RlAi{CIlOf~Gphen)|@Hi^12P5SCl;4WUCLL@_9pL9YMfe;JnpX~4J zVWAckTB4FAKfgZ9-Q}g$4qzArMU3_7sIO2^3P1$FXF7r41bW(y$5mipxJ(y148AO~qYLq3~qt2*kaJiFn2Pu1N96EbXw9!$aLfw`+@{ zG=V;y?qxuzCjcRBgwdH4l!16qLUAUogyNh)7nCo-1<;pyA|Fp;xt@-4K&T-)FtBCG-e z3)=3kQjeD z#pQ6QK--=rqZuXOjK_H1ZZNPc*zGo+*0Bs>VymNj_%aXy_(`}thUOJbdQGToxES)1 zCUV#)G=!AbU8;Ji(`@QN-CwUHj6=ZuJGG&esI8X>#Nidk;hthp$-N|S2<8fMw_KLgwvyc9i z;=lj71a3AP84W}6S7n$qj%!Sz1dgA(Ze=jZY*Zc0F`D2p%??Q8m?RkCu)3-SCY<)M z_HEOcuN`*Wy)ciV193gF5zJh5B{hbjWlfiJx{e0@p84K6?e`KzR|mrwuJaSR*g|_T eq!O6A3iSawYis!*bv9`L0000B? zod^3sDZ0J7qL=6Aj4)joL9#5xqoDXR}NEtMZBQAiDQjujYmQB&OFQ0!25|p!)0D86E z(n*o?vX#4@F$-8n%ckhlyIcD3<~5D;yq1s&I+{$}g5F0(@gWS60EFLg4@8DYgR!hydB;LLPEeuS?wVt1Q4F=zXP(6QXPb*mcB7db{YCd z$_dEa_H7`107zK};nPPB#U@5h>&Sn|=Mb*eKo_gB0u}u}Ujt7kfcI%67j-ot34A__ zaQ!DhS=ids|zAW%&JcAYuLvSD7teOn+5{mI;x2tY_p=4M%Xbm*afSOX3_9WF`4 loD0G#ratNkH0OVc_zsXenU=F(4g~-J002ovPDHLkV1gc9AG!bl diff --git a/public/images/boss/nightmare/jar_of_dreams.png b/public/images/boss/nightmare/jar_of_dreams.png deleted file mode 100644 index db4d64b9a071c7241b7b8ceff6aa95b2a6edad27..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 861 zcmV-j1ETziP)>GX78fEhTGk%220FW}C#0uwN?>ke{86 zk{j3e)a|SJxS5+Pu=@aI;8tFq7lfynoa$l!k$?bQPzD11{k;IpDl05RMNttR-7Ud^ zz(8Fo8S?Pppdc>*Gt9%{VpQEL6`;ex!8mmApbjWQ9v&VVDuy)P3+BoFGSpO52vAr^ z2p+i7(l9zh9&R}rhT6(XF{H7A;q|kcYBas5!^_%QJbhe+Xp05b@NiU>mg)f_OjJY! zY>`$mB>;_iO^|mD4S3(wgy#BsG}b*wOjHz(SuLn8FV_PUNf@gYvC+{;h>5}5*RKSm zrLhsMZ<^88(t?iGRygg6NJ>a>_1FYT8_?(8UNMNb*06H}TeCne#y)3GCm!}XmV zj>H7%VXrozfsZ|ynVdvoYz&g(<6WkSVonG*kV^#QJ@ybvE6~)$1lHHqBmr|eDNd(| z-|^m$l@%;4F6sxO(a-gDNoO~p&CN}LX5aUP1${vM-Q5DTy1XogH2$@{?WK*44Y|+0 z#rb)?KwrnlvAne8PKf~9TU&pLKx?b3(zh@-rx$2)Y)r;zL%I}tf`R71A9UT}M9F#He^fV;^N2FxlAHD<{(qS3s{?Lx0fdLrUKFM%c?mVv>(PcjCco+)rVp7Puu zf{%}U(Fw#dWDFdeT5Kf+#pIZv#)UT5&VMeo*pw$2L3vN({&?4piQxwF1XIBKl#aQ~ n|Ly-k_yA_7%m6-t&{e+ye21&MI5di{00000NkvXXu0mjft2CEQ diff --git a/public/images/boss/nightmare/little_nightmare.png b/public/images/boss/nightmare/little_nightmare.png deleted file mode 100644 index e8736329264ae5894c0570065e3560a72a8a178f..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1151 zcmV-_1c3XAP)@;p;#+;2;;I{y z&aP{zYu&^lj%~2PJ`MJHe@#DJ%XMe>v-EVxOd|Wz2QJRZ!Sg&nulu^6=Ulk(W}Mrw z@Q?nNQ4C;Vc6JrFZcU@Vf8>?t_P5Sq6c%djOryCyDQb+y(a_R?nVDsbjpZ=>;cWry z?jAUAI13LSeuHSd*Ql*4BX9~eJ-vj9iP_h{;_>U1hO)5p+1Kbu528IeAX0~@D{V0W zqUPq-vADR2<&|x0Ym`=Q<)+uDPnrZm#w4gqp|e5iG~;c{OTfQgBFSX=ue-8m=@#V)rZ;tdLv+g&FBba*LW_6n8F!tU0dKqpc&>roJ07tdKAZwZpn|p6!y(ips zRr13evBMOICG&dgWpQ@e`ugWsS=q^leXLxUEIfFyCzH|*iXa3CU1>w$-9~|^4}?Vw zG+`KOpU?ld8x}S`WjMX_9y7Fb`h>v17{y%47y*lE;q^ad7a1Y={J6 z`LtwohfZa)cf|#T;(N>>OHUw$DH(_*Q+M|Fk8ynbi|I6GN;`|CV#rw<9vk}kQSI`; zS@X68yBNs6(tjA1Ikgq&`STMT9sO*8wAD4tEDOs^Ai7Er73WgNN(SPm1g}o_CDF5I z-{bJ`C-eQoQnA%3-m|Tl5tgjCcUZdZEvE}rHFdI=v5b6H_ysU9)ndDfbDl0fXpNIp*#bK`J%jkGcBI>Q!F08)_Cq(F8R!|1~QCi}{# z49k>Wm#ihtT=bKT9@fSN;EXv}o R5vKqE002ovPDHLkV1i2#K9m3e diff --git a/public/images/boss/nightmare/nightmare_staff.png b/public/images/boss/nightmare/nightmare_staff.png deleted file mode 100644 index 22313561c589aba73525a422c6e367cd7e7ee066..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 497 zcmV4qH5Qg0!&_fPF5CRe;1d$NL5F!ypsc2F0V6jl!gU~~J>Hj}Xoms~0rlnY#P4#SImt`K*x0{*)WQzP58}*W>d%A zu2v;EHzomH&x0@ss9Guz8@d1xuuIf78j~O(46YQmjA2xuMU>Eb&-JvbRR~zXVDx;S zU_K7daES6!G68uQYfxU>h0|mWZ;O4kP-=|)5K=FI(|Ql9IHTZySuh|dp0oMS^DWIQ z^B1>9HSkluyngdK!ZH-Lmk-d_*+aEJx&*ZXldE3B5fkIO8tQH|1cWMD$WR<@$GHZ2 z?)z>uB(;SIwVD^+DTm?e{3HRN@A6Jl{ib`bR$Z!;$wO0C#R|#$uNJ@DCV7bBcDJfZ z2xVRCtc9}Z-Hnn^`oY<_B-DBP2%90l4jPxN4qhV_KSTZ_`4X6VApu!)PWg9jn}ARk nPdOc1+Qw?+_Wxa0!Td#E3y@q_hg7vr00000NkvXXu0mjfJGR;W diff --git a/public/images/boss/nightmare/volatile_orb.png b/public/images/boss/nightmare/volatile_orb.png deleted file mode 100644 index f185af956e30219832efceab0a0987ccea77dc82..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 948 zcmV;l155mgP)d9cprL-JileI)6lB=2es(v^8yAX{30*L}zjwrjNWxrpI6VpAL!FcR z`xQ67Ty)`ewF~!4G&Jm1QOjaGkZr@3`8Fhtv0!w93DK$vL;IS!4SisiI>NHJ4BIHu2WF9O2MMZ7SEJM#F;(O{WnnhBrDPqt^BYTRZdoFCkJ|e zM#M!x%|)U^wEjg)#T9U98QZ$dFg~SG2_YQH5TFH)BwgUN|{ts#e zqDzn_(n8PjC_F6FaOYqouCtY|-w}>eo5OK>iyZ~5%xQ@NhW?*9y`6x_6xX98QT!XG zM@1`78>Sb!Bqt2{OJpofvLbtil>_Ne{-^(=L?Lyk=0cSN(YjNabs$=K0xHUu`Nru$ z1{S(i;vjJ_0nz8-R$(Nr?RDVFE(gx#MWAML1j^W!<;=9AdSiGS5W`@6CE*;q2FUsg zbr-L&vnkn;pJDF^5N}DS%Z>23d`$#ObL<`g+77uQaGptBHkI+n7jL^sbPn)>B1pCPNNeQydtO1k}>PLb@=mYB#y8%uBZG z;<=&|*Ac*cK2KAH0)6|?lOBxsMA7FBMR(iEAiYf`FeX!g(M{^@+qA?Apl@DrvCGGb ziVW5)m+8w2L%D9!FdAf>i|(*J-k~j4ncQSGJhsdmF4NajoBXDo)I@0ze@oGM-lfy= z+vM`qBdZK&fOdKNY&a*%;8;THSX9Vn0|0+pkw2HA$-X|>J};GMlaE&z>};?=J4wR` z1S=B&Ep!JUTe%$h4MkP9YM;0Lw>{+VDJn5+0#<1lZQMUm2C$?Az@EFx;_Y3z3RDm7%Gys<)!vYw!r_$brVll%Y+C9VL`x*tX zjvUxQzbp?9Y9&||fB^`W1%Q)IoK_($`gxp_8)A)D-$O3a00cKOY&_vf!Wx8qm@xl+ zkMx*ZSZ(Wo(weMh!dYAbfDqG3@pcT2!7mlTcl_R4)~ zkrjhQ21qQLbAq0V*{Wz*Vi|yN*FNVWc*gP2=saa>+)s6ez}h3zwUMYgh!CisfoAyX zKfO@&fE9Yfed8V5w9TtCrV2fkFbpCD`rgdZk5%2|=qXI!3O96XH?%H6t4wI1s}gSv zP^!hxJgu4%z!ZQG(O2Lwp_-XOlL^}uhA9-yPKeZC{uVa^;=hhxl~P6f%znV*00000 LNkvXXu0mjfp}2pb diff --git a/public/images/boss/tzkal_zuk/jal-nib-rek.png b/public/images/boss/tzkal_zuk/jal-nib-rek.png deleted file mode 100644 index beda691297c42d9a2a0b86341e883660a7f2a3cd..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 566 zcmV-60?GY}P)^UzlNGP=~0F-TE*3J70Zgd*kf5 zqU(?Bun)d?aCJWW-ppdPEZy%Cw1wbfOXKSK2|ZYV&KD=WVkJu|5uX1`F7pWF>#ZYyPpK_ZKbj?54ys9vea z0EA7wy|E$p69OFekd6t5LMl^+*_hpYULt_Wrqd1>I<=fgP%Ii%0cs%_bb(D&f*x8e zIzBw4qrE*jGIRt8fEWf4Mg|ne?9!A_f*#v#YE-L^l#4~RuRfz8Iw_ST3Z22|^e(xL zabncPX`Rk%HJO`cldjGhvO8b#Fx_2V%8me{M<1U#$}v#-#X>@WV%ST!OP%X$I>=b` zeBV)H8iwI8C>4v1f)XxwAmmsWgbj`j4cPnBlP8ScAKHgr{X7&Q& zXVl0b><{Pj!%p6^WN_+$0uIk02APYyh5ri}&!BiDq7X>&=eQ#{{=i^-eB_6L_~pxx z5iuwmgaD+YvdN?j-zB<)>lidBV{}C?`&3~e{VmQfP=1Npe{3&gJ`@ps)MIqTtbP<@ zoS;BJhYdnZ0MV;|5pyy9Y7=07Kb0~UnCW7E`8CD*2DTkIU-SFOS^xk507*qoM6N<$ Eg2$ZtbpQYW diff --git a/public/images/boss/tztok_jad/fire_cape.png b/public/images/boss/tztok_jad/fire_cape.png deleted file mode 100644 index be1bea79d43c00794f681dea5b9476476e5bcf84..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 844 zcmV-S1GD^zP)3Qgd(ORg zGJ_R`zBCIjJm%%A@60*po;%&z`oAg(x_rOUO2Yf$JucsG5R@|GAfESnn*yak%6UKJ zhmS&iK57A4eZG3V))FAI?T{bzLbccnWtN6wwiBw;XB{8i0ZV$<)%-=MKktWP{5TYo zC){%hOO=4TS;puER?<*^dP#P`M*ZatU-P|rO1A3nuS5OyZO7!10qNb=i;*y}&%-E@ zFjFl>uIY9tCj#(%7%t^Xkir&Olzn7CCXaxq&jirVBR$YSVP6R|zm6V+e6}0vZwI>M z^L*TIz(fKhU{3eAcnE;tx*QP%{jyNm$`dp7(!MKzqJwGQEe{p{&_g1JdkLl{OYjc9 z2dQLV2&)mLO7xEl12AfNoRTH%kvG-Zkc-A%4$RPfWes4DwaX&0qxsUvBMYWw-oU_~ zH^Kry0gPX{;z?zl1Q6^HGc5cgSLO}mv8UMs`LmX%S;N( z8?-izOc2&>_zh%&q!HLjn5<2AV4=0a0{k$yyn$~%4#-NAH(;g3BCfY&$INSfp;24l z$QC?=_uv^}26=P&;pxg_a=n=BgsVv`b_7H*P4#dAhrPElJIuPLoi|{Itbj=a3>I(6 z4l2=b6Gkpx-B%_AAQIN+6jQpLH((E}+F~4>L}G_Vw)jV@0~8G_V6L)Vjtb8fH#JPo zk%7@6Mh19D7Ka@?KER{~$`2#}YyT#bu*~S5H~1aEMPSEEvxlJI6C8kSkptlqXQGkD zTHEu6AO&CqcG{)Jrawe3j0ScQ*lMvu6Wa`$gV&YCn@?u|0000N{Eww zrEMJFm;cUoi{fvE^P;nd^H)_JbXipAgc4T(LMngTDS>E;+HZ@Mf~msyZ3}f#u6_bc z_k}=+s$-c-qbdO5iu>OL<-(gH0j@}{wQHTg6^WaA69v*eb-mf-K(QMrfk3eU!$7)s zEEGLQ4rKsQgCZfrXaVA;y$AJyVo=oJfXM>FTWNP#TspuC5W5ir;w?aHaX5b)Ru2J; z0gX9mfuN>XcRiH=<-*(Rp3zB`0SOeZx`cjm{_Sw^&-=aq{CMxI)Z+>uyp4FVa%y<31#DOVcBBCyerpHAaR2F38y{|;9a{1Sr8eQ3`NHYRu^Dmdk}t; z1T-E{7(av&sKm_@LA_(Q0v7+Ko1dStW3`+7zbT=gaHL?D#)L&X88l1+V0mNO%Pf!< z!(;(9VKRmi;XbYp>ffSuNIRJUgK%v_1z{m^42WS89CBTQt!P664BGs1OAtvI;`;?H>Q zzNAH9VKRXb{X=$+^j;KGLb>|E6D-lxb2i6+ER8R}*zb4su^UYQ0000 +
+
+

{{ meta.alias }}

+ + Total Kills: {{ meta.total_kills }} +
+ Average Kills: {{ meta.average_total_kills }} +
+ + + + + + + + + + + + + + + + + + + +
RankAccountKill CountHiscore RankCollection LogObtained
{{ index + 1 }}{{ hiscore.account.username }}{{ hiscore.kill_count }}{{ hiscore.rank }} + + Collection log item icon + + +
+ + {{ (hiscore.obtained !== null ? hiscore.obtained : 0) }} / {{ total }} + +
+
+ {{ hiscore.obtained }} / {{ total }} +
+
+ + {{ (hiscore.obtained !== null ? hiscore.obtained : 0) }} / {{ total }} + +
+
+
+ + + diff --git a/resources/views/hiscore.blade.php b/resources/views/hiscore.blade.php index 5b99be66..045e3274 100644 --- a/resources/views/hiscore.blade.php +++ b/resources/views/hiscore.blade.php @@ -9,7 +9,7 @@
- +
- +
Bosses
+ + @if (count(Helper::listNpcs()) > 0) + +
+ Monsters icon +
+ Monsters +
+
+ @endif
@@ -78,6 +91,8 @@ class="pixel icon" @elseif ($hiscoreType == "boss") + @elseif ($hiscoreType == "npc") + @endif @else
diff --git a/routes/api.php b/routes/api.php index 178832e2..60eb9944 100644 --- a/routes/api.php +++ b/routes/api.php @@ -1,6 +1,5 @@ group(function() { Route::get('/skill/{skill}', 'Api\HiscoreController@skill')->name('hiscore-skill-show'); - Route::get('/boss/{skill}', 'Api\HiscoreController@boss')->name('hiscore-boss-show'); + Route::get('/boss/{boss}', 'Api\HiscoreController@boss')->name('hiscore-boss-show'); + Route::get('/npc/{npc}', 'Api\HiscoreController@npc')->name('hiscore-npc-show'); }); Route::prefix('/collection')->group(function() { @@ -49,4 +49,4 @@ Route::prefix('/notification')->group(function() { Route::get('/all', 'Api\NotificationController@index')->name('notification-show-all'); Route::get('/account/{accountUsername}', 'Api\NotificationController@show')->name('notification-account-show'); -}); \ No newline at end of file +}); From 7da5829b80ef2981a073e59d4194a767bdf764d6 Mon Sep 17 00:00:00 2001 From: Zlimon Date: Fri, 1 Jan 2021 22:18:29 +0100 Subject: [PATCH 02/92] Typo fix --- resources/js/components/AccountHiscore.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/resources/js/components/AccountHiscore.vue b/resources/js/components/AccountHiscore.vue index 601de6ef..521b8891 100644 --- a/resources/js/components/AccountHiscore.vue +++ b/resources/js/components/AccountHiscore.vue @@ -7,7 +7,7 @@ src="/images/boss/boss.png" title="Click here to see the boss hiscores">
- Skills + Bosses
From fd1fe5bce8465df9f8fa68c530009345b8c2299b Mon Sep 17 00:00:00 2001 From: Zlimon Date: Fri, 1 Jan 2021 22:21:39 +0100 Subject: [PATCH 03/92] Link to account on profile page --- resources/views/home.blade.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/resources/views/home.blade.php b/resources/views/home.blade.php index ceae6e89..771d679c 100644 --- a/resources/views/home.blade.php +++ b/resources/views/home.blade.php @@ -53,7 +53,9 @@ class="pixel" alt="{{ Helper::formatAccountTypeName($account->account_type) }} icon" style="width: 1rem;"> @endif - {{ $account->username }} + + {{ $account->username }} +

From 215c4f5fb268a04d4a3232a3fe2b3a50bb5e8dcd Mon Sep 17 00:00:00 2001 From: Zlimon Date: Fri, 1 Jan 2021 22:24:14 +0100 Subject: [PATCH 04/92] Skill hiscores title fix --- resources/views/hiscore.blade.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/resources/views/hiscore.blade.php b/resources/views/hiscore.blade.php index 045e3274..28b474c2 100644 --- a/resources/views/hiscore.blade.php +++ b/resources/views/hiscore.blade.php @@ -1,7 +1,7 @@ @extends('layouts.layout') @section('title') - {{ ucfirst(Helper::collectionAttribute($hiscoreName, "alias")) }} + {{ ucfirst((Helper::collectionAttribute($hiscoreName, "alias") ?: $hiscoreName)) }} @endsection @section('content') From 2cf890ce5928d33164767e6017f841d3971744f3 Mon Sep 17 00:00:00 2001 From: Zlimon Date: Fri, 1 Jan 2021 22:32:21 +0100 Subject: [PATCH 05/92] Non-nullable image id & unique account usernames --- database/migrations/2014_10_12_000000_create_users_table.php | 2 +- database/migrations/2020_08_14_225042_create_skills_table.php | 3 +-- .../migrations/2020_08_14_225333_create_accounts_table.php | 2 +- 3 files changed, 3 insertions(+), 4 deletions(-) diff --git a/database/migrations/2014_10_12_000000_create_users_table.php b/database/migrations/2014_10_12_000000_create_users_table.php index dc49863b..468d81c1 100644 --- a/database/migrations/2014_10_12_000000_create_users_table.php +++ b/database/migrations/2014_10_12_000000_create_users_table.php @@ -21,7 +21,7 @@ public function up() $table->timestamp('email_verified_at')->nullable(); $table->string('password'); $table->rememberToken(); - $table->integer('icon_id')->nullable(); + $table->integer('icon_id'); $table->boolean('private')->default(false); $table->timestamps(); }); diff --git a/database/migrations/2020_08_14_225042_create_skills_table.php b/database/migrations/2020_08_14_225042_create_skills_table.php index e8006b56..2e9cb384 100644 --- a/database/migrations/2020_08_14_225042_create_skills_table.php +++ b/database/migrations/2020_08_14_225042_create_skills_table.php @@ -1,11 +1,10 @@ id(); $table->integer('user_id')->unsigned(); $table->enum('account_type', Helper::listAccountTypes()); - $table->string('username', 13); + $table->string('username', 13)->unique(); $table->integer('rank')->default(0); $table->integer('level')->default(32); // Minimum total level $table->bigInteger('xp')->default(0); From 58cae30cd3ec4908c615b111f160b255932f31eb Mon Sep 17 00:00:00 2001 From: Zlimon Date: Fri, 1 Jan 2021 22:33:09 +0100 Subject: [PATCH 06/92] Migration cleanup --- .../migrations/2020_08_14_225333_create_accounts_table.php | 3 +-- .../2020_09_01_093912_create_account_auth_statuses_table.php | 3 +-- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/database/migrations/2020_08_14_225333_create_accounts_table.php b/database/migrations/2020_08_14_225333_create_accounts_table.php index 1ba03b6f..2e190d9d 100644 --- a/database/migrations/2020_08_14_225333_create_accounts_table.php +++ b/database/migrations/2020_08_14_225333_create_accounts_table.php @@ -1,11 +1,10 @@ Date: Fri, 1 Jan 2021 23:13:19 +0100 Subject: [PATCH 07/92] Account auth status overview --- app/User.php | 3 ++- resources/views/home.blade.php | 41 ++++++++++++++++++++++++++++++++++ 2 files changed, 43 insertions(+), 1 deletion(-) diff --git a/app/User.php b/app/User.php index 5a721d44..92202e83 100644 --- a/app/User.php +++ b/app/User.php @@ -86,8 +86,9 @@ public function account() return $this->hasMany(Account::class); } + // TODO support multiple auth statuses? public function authStatus() { - return $this->hasOne(AccountAuthStatus::class); + return $this->hasMany(AccountAuthStatus::class)->where('status', '!=', 'success'); } } diff --git a/resources/views/home.blade.php b/resources/views/home.blade.php index 771d679c..594f0b5f 100644 --- a/resources/views/home.blade.php +++ b/resources/views/home.blade.php @@ -69,6 +69,47 @@ class="pixel"
@endforeach + @foreach ($user->authStatus as $account) + @if ($loop->first) +

Account Auth Status

+ +
+ @endif + +
+
+

+ @if ($account->account_type !== "normal") + {{ Helper::formatAccountTypeName($account->account_type) }} icon + @endif + + {{ $account->username }} + +

+
+ +
+ Status: +
+ {{ ucfirst($account->status) }} +
+ +
+
+ @csrf + @method('DELETE') + + +
+
+
+ +
+ @endforeach +
From b2ee5d1b7af3f0874e674977dfd71cc51c280025 Mon Sep 17 00:00:00 2001 From: Zlimon Date: Fri, 1 Jan 2021 23:32:16 +0100 Subject: [PATCH 08/92] News index page spacing fix --- resources/views/news/index.blade.php | 61 ++++++++++++++-------------- 1 file changed, 31 insertions(+), 30 deletions(-) diff --git a/resources/views/news/index.blade.php b/resources/views/news/index.blade.php index 68ebcd14..5cdba0de 100644 --- a/resources/views/news/index.blade.php +++ b/resources/views/news/index.blade.php @@ -5,38 +5,39 @@ @endsection @section('content') -
-
-

Latest news and updates

+
+

Latest news and updates

- @forelse ($newsPosts as $post) - @if ($loop->first) -
@endif -
- - '{{ $post->title }}' news post image - -
-
{{ $post->title }}
-

{{ $post->shortstory }}

-
- + @forelse ($newsPosts as $post) + @if ($loop->first) +
+ @endif +
+ + '{{ $post->title }}' news post image + +
+
{{ $post->title }}
+

{{ $post->shortstory }}

- @if ($loop->last)
@endif - @empty -
- Sad face -

Nothing interesting is happening

+ +
+ @if ($loop->last)
- @endforelse -
+ @endif + @empty +
+ Sad face +

Nothing interesting is happening

+
+ @endforelse
@endsection From 9701125ba70afe93c469a6bd0cef970b20751b99 Mon Sep 17 00:00:00 2001 From: Zlimon Date: Fri, 1 Jan 2021 23:32:28 +0100 Subject: [PATCH 09/92] Remove skill and boss name on mobile --- resources/js/components/AccountBossHiscore.vue | 2 +- resources/js/components/AccountSkillHiscore.vue | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/resources/js/components/AccountBossHiscore.vue b/resources/js/components/AccountBossHiscore.vue index 4c337436..ca54a056 100644 --- a/resources/js/components/AccountBossHiscore.vue +++ b/resources/js/components/AccountBossHiscore.vue @@ -27,7 +27,7 @@ :src="'/images/boss/' + name + '.png'" :title="'Click here to visit ' + hiscore.alias + ' hiscores'" class="pixel hiscore-icon"> - {{ hiscore.alias }} + {{ hiscore.alias }} {{ hiscore.kill_count }} diff --git a/resources/js/components/AccountSkillHiscore.vue b/resources/js/components/AccountSkillHiscore.vue index 61fb46f3..61b29d77 100644 --- a/resources/js/components/AccountSkillHiscore.vue +++ b/resources/js/components/AccountSkillHiscore.vue @@ -26,7 +26,7 @@ :src="'/images/skill/' + name + '.png'" :title="'Click here to visit ' + name + ' hiscores'" class="pixel hiscore-icon"> - {{ name | capitalize }} + {{ name | capitalize }} {{ hiscore.level }} From e72a0c7fadb569cfd8816957beb8ed7e5fa64a05 Mon Sep 17 00:00:00 2001 From: Zlimon Date: Sat, 2 Jan 2021 14:08:03 +0100 Subject: [PATCH 10/92] User and Account factory --- composer.json | 3 +- database/factories/UserFactory.php | 4 +- database/seeds/UserSeeder.php | 157 ++++++++++++++++++++++++++++- 3 files changed, 158 insertions(+), 6 deletions(-) diff --git a/composer.json b/composer.json index 5f3dff28..e975c3d4 100644 --- a/composer.json +++ b/composer.json @@ -17,7 +17,8 @@ "laravel/passport": "^9.3", "laravel/tinker": "^2.0", "laravel/ui": "^2.1", - "pusher/pusher-php-server": "^4.1" + "pusher/pusher-php-server": "^4.1", + "ext-curl": "*" }, "require-dev": { "barryvdh/laravel-ide-helper": "^2.8", diff --git a/database/factories/UserFactory.php b/database/factories/UserFactory.php index 741edead..1da14cf5 100644 --- a/database/factories/UserFactory.php +++ b/database/factories/UserFactory.php @@ -19,10 +19,12 @@ $factory->define(User::class, function (Faker $faker) { return [ + 'uuid' => 'd7d865c5-e37f-4228-a1c1-a5190f0f34cb', 'name' => $faker->name, 'email' => $faker->unique()->safeEmail, 'email_verified_at' => now(), - 'password' => '$2y$10$92IXUNpkjO0rOQ5byMi.Ye4oKoEa3Ro9llC/.og/at2.uheWG/igi', // password + 'password' => bcrypt('runemanager1234'), // password 'remember_token' => Str::random(10), + 'icon_id' => Helper::randomItemId(true), ]; }); diff --git a/database/seeds/UserSeeder.php b/database/seeds/UserSeeder.php index 08147b5d..0d767b38 100644 --- a/database/seeds/UserSeeder.php +++ b/database/seeds/UserSeeder.php @@ -1,5 +1,8 @@ insert([ - 'uuid' => 'd7d865c5-e37f-4228-a1c1-a5190f0f34cb', - 'name' => 'Simon', - 'email' => 'simon@runemanager.com', - 'password' => bcrypt('runemanager1234'), + 'uuid' => 'd7d865c5-e37f-4228-a1c1-a5190f0f34cb', + 'name' => 'Simon', + 'email' => 'simon@runemanager.com', + 'password' => bcrypt('runemanager1234'), 'icon_id' => Helper::randomItemId(true), ]); + + $accounts = [ + 'Arttu Mikael', + 'GamerButBad', + 'ImNotBobRoss', + 'Darth Morty', + 'Zezima', + 'Settled', + 'Eddapt', + 'SteelmanDave', + 'Mmorpg', + 'Hey Jase', + 'DarthPorg', + 'Slapen', + 'UIM Paperbag', + 'dids', + 'Doctor Nick', + 'Murder', + 'Carlton', + 'Fire 961', + 'Joltik', + 'Shiny Dragon', + 'Lumby', + 'Intrigued', + 'kulitz', + 'TwiztedLore', + 'Vitaliz', + 'Chasadelic', + 'allyallnoobs', + 'Cause Milk', + 'PACKMAN Boi', + 'Meth Mann', + 'AKA boef', + 'hgcdtyr6icto', + 'Rsn-Ihita22', + 'Sr Strong JR', + 'White Web', + 'kyleraw2', + 'Senpai Jayce', + 'Antione', + 'Jhhonnn', + 'Dan Kingdon', + 'BSM', + 'HH Loli', + 'TrumpYoDaddy', + 'LotteryPure', + 'Wargod Benny', + 'heaven_nova', + ]; + + shuffle($accounts); + + factory(App\User::class, 35)->create()->each(function ($u) use ($accounts) { + $randomId = rand(0, sizeof($accounts) - 1); + + if (App\Account::where('username', $accounts[$randomId])->first()) { + return null; + } + + $playerDataUrl = 'https://secure.runescape.com/m=hiscore_oldschool/index_lite.ws?player=' . str_replace(' ', + '%20', $accounts[$randomId]); + + /* Get the $playerDataUrl file content. */ + $playerData = Helper::getPlayerData($playerDataUrl); + + $account = Account::firstOrCreate([ + 'user_id' => rand(1, 10), + 'account_type' => Helper::listAccountTypes()[rand(0, 3)], + 'username' => $accounts[$randomId], + 'rank' => $playerData[0][0], + 'level' => $playerData[0][1], + 'xp' => $playerData[0][2] + ]); + + $skills = Helper::listSkills(); + + for ($i = 0; $i < count($skills); $i++) { + DB::table($skills[$i])->insert([ + 'account_id' => $account->id, + 'rank' => ($playerData[$i + 1][0] >= 1 ? $playerData[$i + 1][0] : 0), + 'level' => $playerData[$i + 1][1], + 'xp' => ($playerData[$i + 1][2] >= 0 ? $playerData[$i + 1][2] : 0), + 'created_at' => Carbon::now(), + 'updated_at' => Carbon::now() + ]); + } + + $clueScrollAmount = count(Helper::listClueScrollTiers()); + + $bosses = Helper::listBosses(); + + array_splice($bosses, 13, 1); + + $bossIndex = 0; + + $dksKillCount = 0; + + for ($i = (count($skills) + $clueScrollAmount + 4); $i < (count($skills) + $clueScrollAmount + 4 + count($bosses)); $i++) { + $collection = Collection::where('name', $bosses[$bossIndex])->firstOrFail(); + + $collectionLoot = new $collection->model; + + $collectionLoot->account_id = $account->id; + $collectionLoot->kill_count = ($playerData[$i + 1][1] >= 0 ? $playerData[$i + 1][1] : 0); + $collectionLoot->rank = ($playerData[$i + 1][0] >= 0 ? $playerData[$i + 1][0] : 0); + + if (in_array($bosses[$bossIndex], + ['dagannoth prime', 'dagannoth rex', 'dagannoth supreme'], true)) { + $dksKillCount += ($playerData[$i + 1][1] >= 0 ? $playerData[$i + 1][1] : 0); + } + + $collectionLoot->save(); + + $bossIndex++; + } + + /** + * Since there are no official total kill count hiscore for + * DKS' and we are going to retrieve loot for them from the + * collection log, we have to manually create a table. + * This might also happen with other bosses in the future + * that share collection log entry, but have separate hiscores. + */ + $dks = new \App\Boss\DagannothKings; + + $dks->account_id = $account->id; + $dks->kill_count = $dksKillCount; + + $dks->save(); + + $npcs = Helper::listNpcs(); + + foreach ($npcs as $npc) { + $collection = Collection::findByNameAndCategory($npc, 4); + + $collectionLoot = new $collection->model; + + $collectionLoot->account_id = $account->id; + + $collectionLoot->save(); + } + + print_r('Added ' . $accounts[$randomId]); + + return $account->toArray(); + }); } } From 796d48bc488fe9ffb1b4ae2544b9a6206d7b1a47 Mon Sep 17 00:00:00 2001 From: Zlimon Date: Sat, 2 Jan 2021 18:25:31 +0100 Subject: [PATCH 11/92] Advanced account search --- app/Http/Controllers/AccountController.php | 19 +- public/css/search.css | 687 +++++++++++++++++++++ public/images/settings.png | Bin 0 -> 218 bytes resources/views/account/index.blade.php | 133 +++- 4 files changed, 818 insertions(+), 21 deletions(-) create mode 100644 public/css/search.css create mode 100644 public/images/settings.png diff --git a/app/Http/Controllers/AccountController.php b/app/Http/Controllers/AccountController.php index e4110149..6c7315ac 100644 --- a/app/Http/Controllers/AccountController.php +++ b/app/Http/Controllers/AccountController.php @@ -4,7 +4,9 @@ use App\Account; use App\AccountAuthStatus; +use App\Helpers\Helper; use Illuminate\Support\Facades\Auth; +use Illuminate\Validation\Rule; class AccountController extends Controller { @@ -62,12 +64,25 @@ public function show($accountUsername) public function search() { request()->validate([ - 'search' => ['required', 'string', 'min:1', 'max:13'], + 'search' => ['nullable', 'string', 'max:13'], + 'account_type' => ['nullable', Rule::in(Helper::listAccountTypes())], + 'order_by' => [Rule::in(['level', 'xp', 'rank', 'account_type', 'user_id'])], + 'order_by_order' => [Rule::in(['asc', 'desc'])], + 'total_level_between_from' => ['integer'], + 'total_level_between_to' => ['integer'], ]); $query = request('search'); - $accounts = Account::with('user')->where('username', 'LIKE', '%' . $query . '%')->paginate(10); + $accounts = Account::with('user') + ->where('username', 'LIKE', '%' . $query . '%') + ->when(in_array(request('account_type'), + Helper::listAccountTypes()), function ($query, $accountType) { + return $query->where('account_type', request('account_type')); + }) + ->whereBetween('level', [request('total_level_between_from'), request('total_level_between_to')])// + ->orderBy(request('order_by'), request('order_by_order')) + ->get(); if (count($accounts) === 0) { return redirect(route('account'))->withErrors(['No search results for "' . $query . '"!']); diff --git a/public/css/search.css b/public/css/search.css new file mode 100644 index 00000000..4cf7f91b --- /dev/null +++ b/public/css/search.css @@ -0,0 +1,687 @@ +/*=============================== += Choices = +===============================*/ +.choices { + position: relative; + margin-bottom: 24px; + font-size: 16px; +} + +.choices:focus { + outline: none; +} + +.choices:last-child { + margin-bottom: 0; +} + +.choices.is-disabled .choices__inner, .choices.is-disabled .choices__input { + background-color: #EAEAEA; + cursor: not-allowed; + -webkit-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; +} + +.choices.is-disabled .choices__item { + cursor: not-allowed; +} + +.choices[data-type*="select-one"] { + cursor: pointer; +} + +.choices[data-type*="select-one"] .choices__inner { + padding-bottom: 7.5px; +} + +.choices[data-type*="select-one"] .choices__input { + display: block; + width: 100%; + padding: 10px; + border-bottom: 1px solid #DDDDDD; + background-color: #FFFFFF; + margin: 0; +} + +.choices[data-type*="select-one"] .choices__button { + background-image: url("../../icons/cross-inverse.svg"); + padding: 0; + background-size: 8px; + height: 100%; + position: absolute; + top: 50%; + right: 0; + margin-top: -10px; + margin-right: 25px; + height: 20px; + width: 20px; + border-radius: 10em; + opacity: .5; +} + +.choices[data-type*="select-one"] .choices__button:hover, .choices[data-type*="select-one"] .choices__button:focus { + opacity: 1; +} + +.choices[data-type*="select-one"] .choices__button:focus { + box-shadow: 0px 0px 0px 2px #00BCD4; +} + +.choices[data-type*="select-one"]:after { + content: ""; + height: 0; + width: 0; + border-style: solid; + border-color: #333333 transparent transparent transparent; + border-width: 5px; + position: absolute; + right: 11.5px; + top: 50%; + margin-top: -2.5px; + pointer-events: none; +} + +.choices[data-type*="select-one"].is-open:after { + border-color: transparent transparent #333333 transparent; + margin-top: -7.5px; +} + +.choices[data-type*="select-one"][dir="rtl"]:after { + left: 11.5px; + right: auto; +} + +.choices[data-type*="select-one"][dir="rtl"] .choices__button { + right: auto; + left: 0; + margin-left: 25px; + margin-right: 0; +} + +.choices[data-type*="select-multiple"] .choices__inner, .choices[data-type*="text"] .choices__inner { + cursor: text; +} + +.choices[data-type*="select-multiple"] .choices__button, .choices[data-type*="text"] .choices__button { + position: relative; + display: inline-block; + margin-top: 0; + margin-right: -4px; + margin-bottom: 0; + margin-left: 8px; + padding-left: 16px; + border-left: 1px solid #008fa1; + background-image: url("../../icons/cross.svg"); + background-size: 8px; + width: 8px; + line-height: 1; + opacity: .75; +} + +.choices[data-type*="select-multiple"] .choices__button:hover, .choices[data-type*="select-multiple"] .choices__button:focus, .choices[data-type*="text"] .choices__button:hover, .choices[data-type*="text"] .choices__button:focus { + opacity: 1; +} + +.choices__inner { + display: inline-block; + vertical-align: top; + width: 100%; + background-color: #f9f9f9; + padding: 7.5px 7.5px 3.75px; + border: 1px solid #DDDDDD; + border-radius: 2.5px; + font-size: 14px; + min-height: 44px; + overflow: hidden; +} + +.is-focused .choices__inner, .is-open .choices__inner { + border-color: #b7b7b7; +} + +.is-open .choices__inner { + border-radius: 2.5px 2.5px 0 0; +} + +.is-flipped.is-open .choices__inner { + border-radius: 0 0 2.5px 2.5px; +} + +.choices__list { + margin: 0; + padding-left: 0; + list-style: none; +} + +.choices__list--single { + display: inline-block; + padding: 4px 16px 4px 4px; + width: 100%; +} + +[dir="rtl"] .choices__list--single { + padding-right: 4px; + padding-left: 16px; +} + +.choices__list--single .choices__item { + width: 100%; +} + +.choices__list--multiple { + display: inline; +} + +.choices__list--multiple .choices__item { + display: inline-block; + vertical-align: middle; + border-radius: 20px; + padding: 4px 10px; + font-size: 12px; + font-weight: 500; + margin-right: 3.75px; + margin-bottom: 3.75px; + background-color: #00BCD4; + border: 1px solid #00a5bb; + color: #FFFFFF; + word-break: break-all; +} + +.choices__list--multiple .choices__item[data-deletable] { + padding-right: 5px; +} + +[dir="rtl"] .choices__list--multiple .choices__item { + margin-right: 0; + margin-left: 3.75px; +} + +.choices__list--multiple .choices__item.is-highlighted { + background-color: #00a5bb; + border: 1px solid #008fa1; +} + +.is-disabled .choices__list--multiple .choices__item { + background-color: #aaaaaa; + border: 1px solid #919191; +} + +.choices__list--dropdown { + display: none; + z-index: 1; + position: absolute; + width: 100%; + background-color: #FFFFFF; + border: 1px solid #DDDDDD; + top: 100%; + margin-top: -1px; + border-bottom-left-radius: 2.5px; + border-bottom-right-radius: 2.5px; + overflow: hidden; + word-break: break-all; +} + +.choices__list--dropdown.is-active { + display: block; +} + +.is-open .choices__list--dropdown { + border-color: #b7b7b7; +} + +.is-flipped .choices__list--dropdown { + top: auto; + bottom: 100%; + margin-top: 0; + margin-bottom: -1px; + border-radius: .25rem .25rem 0 0; +} + +.choices__list--dropdown .choices__list { + position: relative; + max-height: 300px; + overflow: auto; + -webkit-overflow-scrolling: touch; + will-change: scroll-position; +} + +.choices__list--dropdown .choices__item { + position: relative; + padding: 10px; + font-size: 14px; +} + +[dir="rtl"] .choices__list--dropdown .choices__item { + text-align: right; +} + +@media (min-width: 640px) { + .choices__list--dropdown .choices__item--selectable { + padding-right: 100px; + } + .choices__list--dropdown .choices__item--selectable:after { + content: attr(data-select-text); + font-size: 12px; + opacity: 0; + position: absolute; + right: 10px; + top: 50%; + transform: translateY(-50%); + } + [dir="rtl"] .choices__list--dropdown .choices__item--selectable { + text-align: right; + padding-left: 100px; + padding-right: 10px; + } + [dir="rtl"] .choices__list--dropdown .choices__item--selectable:after { + right: auto; + left: 10px; + } +} + +.choices__list--dropdown .choices__item--selectable.is-highlighted { + background-color: #f2f2f2; +} + +.choices__list--dropdown .choices__item--selectable.is-highlighted:after { + opacity: .5; +} + +.choices__item { + cursor: default; +} + +.choices__item--selectable { + cursor: pointer; +} + +.choices__item--disabled { + cursor: not-allowed; + -webkit-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; + opacity: .5; +} + +.choices__heading { + font-weight: 600; + font-size: 12px; + padding: 10px; + border-bottom: 1px solid #f7f7f7; + color: gray; +} + +.choices__button { + text-indent: -9999px; + -webkit-appearance: none; + -moz-appearance: none; + appearance: none; + border: 0; + background-color: transparent; + background-repeat: no-repeat; + background-position: center; + cursor: pointer; +} + +.choices__button:focus { + outline: none; +} + +.choices__input { + display: inline-block; + vertical-align: baseline; + background-color: #f9f9f9; + font-size: 14px; + margin-bottom: 5px; + border: 0; + border-radius: 0; + max-width: 100%; + padding: 4px 0 4px 2px; +} + +.choices__input:focus { + outline: 0; +} + +[dir="rtl"] .choices__input { + padding-right: 2px; + padding-left: 0; +} + +.choices__placeholder { + opacity: .5; +} + +/*===== End of Choices ======*/ +* { + box-sizing: border-box; +} + +.s009 { + display: -ms-flexbox; + display: flex; + -ms-flex-pack: center; + justify-content: center; + -ms-flex-align: center; + align-items: center; + font-family: 'Lato', sans-serif; +} + +.s009 form { + width: 100%; + max-width: 790px; + margin: 0; +} + +.s009 form .inner-form { + width: 100%; +} + +.s009 form .inner-form .input-group { + position: relative; +} + +.s009 form .inner-form .input-group input { + border: 0; + background: #fff; + display: block; + padding: 10px 32px 10px 70px; + font-size: 18px; + border-radius: 3px; + height: 60px; + color: #555; + font-family: 'Lato', sans-serif; +} + +.s009 form .inner-form .input-group input.placeholder { + color: #999; + font-size: 18px; + font-weight: 600; +} + +.s009 form .inner-form .input-group input:-moz-placeholder { + color: #999; + font-size: 18px; + font-weight: 600; +} + +.s009 form .inner-form .input-group input::-webkit-input-placeholder { + color: #999; + font-size: 18px; + font-weight: 600; +} + +.s009 form .inner-form .input-group input:hover, .s009 form .inner-form .input-group input:focus { + box-shadow: none; + outline: 0; +} + +.s009 form .inner-form .input-group .btn-search { + min-width: 100px; + height: 40px; + padding: 0 15px; + background: #00bbec; + white-space: nowrap; + border-radius: 0; + font-size: 14px; + color: #fff; + transition: all .2s ease-out, color .2s ease-out; + border: 0; + cursor: pointer; + font-weight: bold; + box-shadow: 0px 2px 5px 0px rgba(0, 0, 0, 0.15); +} + +.s009 form .inner-form .input-group .btn-search:hover, .s009 form .inner-form .input-group .btn-search:focus { + background: #00a7d3; +} + +.s009 form .inner-form .input-group .btn-delete { + min-width: 100px; + height: 40px; + padding: 0 15px; + background: transparent; + white-space: nowrap; + border-radius: 0; + font-size: 14px; + color: #666; + transition: all .2s ease-out, color .2s ease-out; + border: 0; + cursor: pointer; + font-weight: bold; +} + +.s009 form .inner-form .input-group .btn-delete:hover, .s009 form .inner-form .input-group .btn-delete:focus { + color: #000; + outline: 0; + box-shadow: none; +} + +.s009 form .inner-form .basic-search { +} + +.s009 form .inner-form .basic-search .input-group { + width: 100%; +} + +.s009 form .inner-form .basic-search .input-group input { + padding: 10px 80px 10px 40px; +} + +.s009 form .inner-form .basic-search .input-group .icon-wrap { + position: absolute; + top: 0; + right: 0; + display: -ms-flexbox; + display: flex; + -ms-flex-align: center; + align-items: center; + width: 60px; + height: 100%; +} + +.s009 form .inner-form .basic-search .input-group .icon-wrap svg { + width: 34px; + height: 34px; + fill: #ccc; +} + +.s009 form .inner-form .advance-search { + /*background: #fff;*/ + padding: 40px; + /*box-shadow: 0px 8px 20px 0px rgba(0, 0, 0, 0.15);*/ +} + +.s009 form .inner-form .advance-search .desc { + font-size: 14px; + color: #999; + display: block; + margin-bottom: 26px; + font-weight: bold; +} + +.s009 form .inner-form .advance-search .form-row { + display: -ms-flexbox; + display: flex; + -ms-flex-pack: justify; + justify-content: space-between; + -ms-flex-align: center; + align-items: center; + margin-bottom: 20px; +} + +.s009 form .inner-form .advance-search .form-row.second { + margin-bottom: 46px; +} + +.s009 form .inner-form .advance-search .form-row.third { + margin-bottom: 0; +} + +.s009 form .inner-form .advance-search .form-row.third .input-group { + width: 100%; + display: -ms-flexbox; + display: flex; + -ms-flex-pack: justify; + justify-content: space-between; + -ms-flex-align: center; + align-items: center; +} + +.s009 form .inner-form .advance-search .form-row.third .input-group .result-count { + display: -ms-flexbox; + display: flex; + -ms-flex-pack: start; + justify-content: flex-start; + -ms-flex-align: center; + align-items: center; + width: 110px; + color: #666; + font-size: 14px; +} + +.s009 form .inner-form .advance-search .form-row.third .input-group .result-count span { + color: #00bbec; + padding-right: 5px; +} + +.s009 form .inner-form .advance-search .input-group { + width: calc((100% - 40px) / 3); +} + +.s009 form .inner-form .advance-search .input-select { + height: 40px; +} + +.s009 form .inner-form .advance-search .choices__inner { + background: transparent; + border-radius: 0; + border: 0; + border: 1px solid rgba(0, 0, 0, 0.1); + height: 100%; + color: #fff; + display: -ms-flexbox; + display: flex; + -ms-flex-align: center; + align-items: center; + padding: 0; + padding-right: 30px; + font-size: 14px; + min-height: 40px; +} + +.s009 form .inner-form .advance-search .choices__inner .choices__list.choices__list--single { + display: -ms-flexbox; + display: flex; + padding: 5px 18px; + -ms-flex-align: center; + align-items: center; + height: 100%; +} + +.s009 form .inner-form .advance-search .choices__inner .choices__item.choices__item--selectable.choices__placeholder { + display: -ms-flexbox; + display: flex; + -ms-flex-align: center; + align-items: center; + height: 100%; + opacity: 1; + color: #666; + font-weight: bold; +} + +.s009 form .inner-form .advance-search .choices__inner .choices__list--single .choices__item { + display: -ms-flexbox; + display: flex; + -ms-flex-align: center; + align-items: center; + height: 100%; + color: #00bbec; + font-weight: bold; +} + +.s009 form .inner-form .advance-search .choices__list.choices__list--dropdown { + border: 0; + background: #fff; + padding: 10px 18px 20px 18px; + margin-top: 0; + border-radius: 0; + box-shadow: 0px 2px 5px 0px rgba(0, 0, 0, 0.15); +} + +.s009 form .inner-form .advance-search .choices__list.choices__list--dropdown .choices__item--selectable { + padding-right: 0; +} + +.s009 form .inner-form .advance-search .choices__list--dropdown .choices__item--selectable.is-highlighted { + background: transparent; + color: #00bbec; +} + +.s009 form .inner-form .advance-search .choices__list--dropdown .choices__item { + color: #666; + min-height: 20px; + padding: 8px 0; + font-weight: bold; +} + +.s009 form .inner-form .advance-search .choices[data-type*="select-one"]:after { + border: 0; + width: 32px; + height: 32px; + margin: 0; + transform: none; + opacity: 1; + right: 15px; + top: 6px; + background-size: 18px 18px; + background-position: right center; + background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg fill='%23999' xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24'%3e%3cpath d='M16.59 8.59L12 13.17 7.41 8.59 6 10l6 6 6-6z'/%3e%3c/svg%3e"); + background-repeat: no-repeat; +} + +.s009 form .inner-form .advance-search .choices[data-type*="select-one"].is-open { + box-shadow: 0px 1px 2px 0px rgba(0, 0, 0, 0.1); +} + +.s009 form .inner-form .advance-search .choices[data-type*="select-one"].is-open:after { + background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg fill='%23999' xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24'%3e%3cpath d='M12 8l-6 6 1.41 1.41L12 10.83l4.59 4.58L18 14z'/%3e%3c/svg%3e"); +} + +.s009 form .inner-form .advance-search .choices[data-type*="select-one"] .choices__button { + display: none; + -webkit-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; +} + +@media screen and (max-width: 767px) { + .s009 form .inner-form .basic-search .input-group input { + padding: 10px 80px 10px 15px; + } + .s009 form .inner-form .basic-search .input-group .icon-wrap { + width: 80px; + -ms-flex-pack: center; + justify-content: center; + } + .s009 form .inner-form .basic-search .input-group .icon-wrap svg { + width: 30px; + height: 30px; + } + .s009 form .inner-form .advance-search { + padding: 30px 15px; + } + .s009 form .inner-form .advance-search .form-row { + display: block; + } + .s009 form .inner-form .advance-search .input-group { + width: 100%; + margin-bottom: 20px; + } +} + +/*# sourceMappingURL=Searchs_009.css.map */ diff --git a/public/images/settings.png b/public/images/settings.png new file mode 100644 index 0000000000000000000000000000000000000000..67f0fc846d38c5f7e565ebc5af48d751bdb1889e GIT binary patch literal 218 zcmeAS@N?(olHy`uVBq!ia0vp^;vmez3?zkEPEH0=5&=FTu0VRr`ejQeEaktajUogAZLRCk8APkn~zvnOBoL` zvZx!BH9gv@dm=vm$gC$BdHvHr)OXxt^f*?k$UUV|RBQHDsm_E0U+*W~-Q2n~hj)(s zHA_vlBemdKI;Vst00$CH2LJ#7 literal 0 HcmV?d00001 diff --git a/resources/views/account/index.blade.php b/resources/views/account/index.blade.php index 13ad9573..b8e2dfb5 100644 --- a/resources/views/account/index.blade.php +++ b/resources/views/account/index.blade.php @@ -5,29 +5,125 @@ @endsection @section('content') + +
@if ($accounts->isNotEmpty())

Search for accounts

-
- @csrf - -
+
+ + @csrf -
- +
+ + +
+
+ + +
+
+ + +
+
- - +
+
+
+ {{ $accounts->count() }} results +
+
+ + +
+
+
+
+
+ +
@if ($query)

Search results for "{{ $query }}"

@@ -38,7 +134,7 @@ From 4efb347a9389552df528d19088d09c4ac04ce1b5 Mon Sep 17 00:00:00 2001 From: Zlimon Date: Fri, 8 Jan 2021 19:11:11 +0100 Subject: [PATCH 13/92] Remove uuid from User --- database/factories/UserFactory.php | 1 - database/migrations/2014_10_12_000000_create_users_table.php | 1 - database/seeds/UserSeeder.php | 1 - 3 files changed, 3 deletions(-) diff --git a/database/factories/UserFactory.php b/database/factories/UserFactory.php index 1da14cf5..f4cf79c9 100644 --- a/database/factories/UserFactory.php +++ b/database/factories/UserFactory.php @@ -19,7 +19,6 @@ $factory->define(User::class, function (Faker $faker) { return [ - 'uuid' => 'd7d865c5-e37f-4228-a1c1-a5190f0f34cb', 'name' => $faker->name, 'email' => $faker->unique()->safeEmail, 'email_verified_at' => now(), diff --git a/database/migrations/2014_10_12_000000_create_users_table.php b/database/migrations/2014_10_12_000000_create_users_table.php index 468d81c1..f69f9f32 100644 --- a/database/migrations/2014_10_12_000000_create_users_table.php +++ b/database/migrations/2014_10_12_000000_create_users_table.php @@ -15,7 +15,6 @@ public function up() { Schema::create('users', function (Blueprint $table) { $table->id(); - $table->uuid('uuid')->default('b5d1a339-af63-44d1-bd18-956083157134'); $table->string('name')->unique(); $table->string('email')->unique(); $table->timestamp('email_verified_at')->nullable(); diff --git a/database/seeds/UserSeeder.php b/database/seeds/UserSeeder.php index 0d767b38..ffcd89c4 100644 --- a/database/seeds/UserSeeder.php +++ b/database/seeds/UserSeeder.php @@ -15,7 +15,6 @@ class UserSeeder extends Seeder public function run() { DB::table('users')->insert([ - 'uuid' => 'd7d865c5-e37f-4228-a1c1-a5190f0f34cb', 'name' => 'Simon', 'email' => 'simon@runemanager.com', 'password' => bcrypt('runemanager1234'), From 8eff0aba9ccef8a586c98dc0b97daab05f0991c2 Mon Sep 17 00:00:00 2001 From: Zlimon Date: Sun, 10 Jan 2021 00:45:35 +0100 Subject: [PATCH 14/92] Log feature for notification replacement - Every API action should now be logged - Notifications will then be associated with respective log --- app/Events/AccountAll.php | 4 ++- app/Events/AccountKill.php | 4 ++- app/Events/AccountNewUnique.php | 4 ++- app/Events/All.php | 2 +- .../Controllers/Api/AccountLootController.php | 21 ++++++++--- .../Api/NotificationController.php | 10 ++++-- app/Log.php | 34 ++++++++++++++++++ app/Notification.php | 23 ++---------- ...1_04_105532_create_notifications_table.php | 5 +-- .../2021_01_02_190709_create_logs_table.php | 35 +++++++++++++++++++ .../js/components/AccountNotification.vue | 6 ++-- resources/js/components/Notification.vue | 8 ++--- 12 files changed, 114 insertions(+), 42 deletions(-) create mode 100644 app/Log.php create mode 100644 database/migrations/2021_01_02_190709_create_logs_table.php diff --git a/app/Events/AccountAll.php b/app/Events/AccountAll.php index e4e23fa1..6c73fbe6 100644 --- a/app/Events/AccountAll.php +++ b/app/Events/AccountAll.php @@ -23,7 +23,9 @@ class AccountAll implements ShouldBroadcast */ public function __construct(Account $account, Notification $notification) { - $this->notification = $notification::with('category')->where('account_id', $account->id)->orderByDesc('id')->first(); + $this->notification = $notification::with('log')->with('log.category')->whereHas('log', function ($query) use($account) { + return $query->where('account_id', '=', $account->id); + })->orderByDesc('id')->first(); } /** diff --git a/app/Events/AccountKill.php b/app/Events/AccountKill.php index 9d4afe04..75e4ae85 100644 --- a/app/Events/AccountKill.php +++ b/app/Events/AccountKill.php @@ -23,7 +23,9 @@ class AccountKill implements ShouldBroadcast */ public function __construct(Account $account, Notification $notification) { - $this->notification = $notification::with('category')->where('account_id', $account->id)->orderByDesc('id')->first(); + $this->notification = $notification::with('log')->with('log.category')->whereHas('log', function ($query) use($account) { + return $query->where('account_id', '=', $account->id); + })->orderByDesc('id')->first(); } /** diff --git a/app/Events/AccountNewUnique.php b/app/Events/AccountNewUnique.php index b7659a39..28d15588 100644 --- a/app/Events/AccountNewUnique.php +++ b/app/Events/AccountNewUnique.php @@ -23,7 +23,9 @@ class AccountNewUnique implements ShouldBroadcast */ public function __construct(Account $account, Notification $notification) { - $this->notification = $notification::with('category')->where('account_id', $account->id)->orderByDesc('id')->first(); + $this->notification = $notification::with('log')->with('log.category')->whereHas('log', function ($query) use($account) { + return $query->where('account_id', '=', $account->id); + })->orderByDesc('id')->first(); } /** diff --git a/app/Events/All.php b/app/Events/All.php index 2d555210..7ceefd6d 100644 --- a/app/Events/All.php +++ b/app/Events/All.php @@ -22,7 +22,7 @@ class All implements ShouldBroadcast */ public function __construct(Notification $notification) { - $this->notification = $notification::with('category')->orderByDesc('id')->first(); + $this->notification = $notification::with('log')->with('log.category')->orderByDesc('id')->first(); } /** diff --git a/app/Http/Controllers/Api/AccountLootController.php b/app/Http/Controllers/Api/AccountLootController.php index a1afcee8..0b645e2c 100644 --- a/app/Http/Controllers/Api/AccountLootController.php +++ b/app/Http/Controllers/Api/AccountLootController.php @@ -9,6 +9,7 @@ use App\Events\AccountNewUnique; use App\Events\All; use App\Http\Controllers\Controller; +use App\Log; use App\Notification; use Illuminate\Http\Request; @@ -54,13 +55,19 @@ public function update($accountUsername, $collectionName, Request $request) $data = json_decode($dataJson, true); - $notificationData = [ + $logData = [ "user_id" => auth()->user()->id, "account_id" => $account->id, "category_id" => $collection->category_id, + "data" => $data + ]; + + $log = Log::create($logData); + + $notificationData = [ + "log_id" => $log->id, "icon" => $collectionName, "message" => $accountUsername . " unlocked a new unique!", - "data" => $data ]; $notification = Notification::create($notificationData); @@ -94,13 +101,19 @@ public function update($accountUsername, $collectionName, Request $request) $data = json_decode($dataJson, true); - $notificationData = [ + $logData = [ "user_id" => auth()->user()->id, "account_id" => $account->id, "category_id" => $collection->category_id, + "data" => $data + ]; + + $log = Log::create($logData); + + $notificationData = [ + "log_id" => $log->id, "icon" => $collectionName, "message" => $accountUsername . " defeated " . $collection->alias . "!", - "data" => $data ]; $notification = Notification::create($notificationData); diff --git a/app/Http/Controllers/Api/NotificationController.php b/app/Http/Controllers/Api/NotificationController.php index 70efc5db..c592b4b0 100644 --- a/app/Http/Controllers/Api/NotificationController.php +++ b/app/Http/Controllers/Api/NotificationController.php @@ -10,7 +10,7 @@ class NotificationController extends Controller { public function index() { - $notifications = Notification::with('category')->orderByDesc('id')->limit(5)->get(); + $notifications = Notification::with('log')->with('log.category')->orderByDesc('id')->limit(5)->get(); return response()->json($notifications, 200); } @@ -19,8 +19,12 @@ public function show($accountUsername) { $account = Account::where('username', $accountUsername)->pluck('id')->first(); - $notifications = Notification::with('category')->where('account_id', $account)->orderByDesc('id')->paginate(10); + if ($account) { + $notifications = Notification::with('log')->with('log.category')->whereHas('log', function ($query) use($account) { + return $query->where('account_id', '=', $account); + })->orderByDesc('id')->paginate(10); - return response()->json($notifications, 200); + return response()->json($notifications, 200); + } } } diff --git a/app/Log.php b/app/Log.php new file mode 100644 index 00000000..2899e556 --- /dev/null +++ b/app/Log.php @@ -0,0 +1,34 @@ + 'array' + ]; + + public function user() + { + return $this->belongsTo(User::class); + } + + public function account() + { + return $this->belongsTo(Account::class); + } + + public function category() + { + return $this->belongsTo(Category::class); + } +} diff --git a/app/Notification.php b/app/Notification.php index 141d2710..2e0f8cf7 100644 --- a/app/Notification.php +++ b/app/Notification.php @@ -36,30 +36,13 @@ class Notification extends Model { protected $fillable = [ - 'user_id', - 'account_id', - 'category_id', + 'log_id', 'icon', 'message', - 'data' ]; - protected $casts = [ - 'data' => 'array' - ]; - - public function user() - { - return $this->belongsTo(User::class); - } - - public function account() - { - return $this->belongsTo(Account::class); - } - - public function category() + public function log() { - return $this->belongsTo(Category::class); + return $this->belongsTo(Log::class); } } diff --git a/database/migrations/2020_11_04_105532_create_notifications_table.php b/database/migrations/2020_11_04_105532_create_notifications_table.php index 35bafa4b..55733da4 100644 --- a/database/migrations/2020_11_04_105532_create_notifications_table.php +++ b/database/migrations/2020_11_04_105532_create_notifications_table.php @@ -15,12 +15,9 @@ public function up() { Schema::create('notifications', function (Blueprint $table) { $table->id(); - $table->integer('user_id')->unsigned(); - $table->integer('account_id')->unsigned(); - $table->integer('category_id')->unsigned(); + $table->integer('log_id')->unsigned(); $table->string('icon'); $table->string('message'); - $table->text('data')->nullable(); $table->timestamps(); }); } diff --git a/database/migrations/2021_01_02_190709_create_logs_table.php b/database/migrations/2021_01_02_190709_create_logs_table.php new file mode 100644 index 00000000..79397039 --- /dev/null +++ b/database/migrations/2021_01_02_190709_create_logs_table.php @@ -0,0 +1,35 @@ +id(); + $table->integer('user_id')->unsigned(); + $table->integer('account_id')->unsigned(); + $table->integer('category_id')->unsigned(); + $table->text('data')->nullable(); + $table->timestamps(); + }); + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('logs'); + } +} diff --git a/resources/js/components/AccountNotification.vue b/resources/js/components/AccountNotification.vue index a9b0dbbe..26443510 100644 --- a/resources/js/components/AccountNotification.vue +++ b/resources/js/components/AccountNotification.vue @@ -13,8 +13,8 @@ export default { }, methods: { - checkAccount(accountUsername) { - return this.account.id === accountUsername; + checkAccount(accountId) { + return this.account.id === accountId; }, }, @@ -40,7 +40,7 @@ export default { created() { window.Echo.channel('account-all') .listen('AccountAll', (e) => { - if (this.checkAccount(e.notification.account_id)) { + if (this.checkAccount(e.notification.log.account_id)) { this.notificationsData.unshift(e.notification); } }); diff --git a/resources/js/components/Notification.vue b/resources/js/components/Notification.vue index 2212faef..4161b4ed 100644 --- a/resources/js/components/Notification.vue +++ b/resources/js/components/Notification.vue @@ -6,7 +6,7 @@
@@ -15,14 +15,14 @@
-
+

Received loot:

-
From 6e411a7e9f643ffcd770eaba92f903fd29fa6efb Mon Sep 17 00:00:00 2001 From: Zlimon Date: Sun, 10 Jan 2021 00:47:24 +0100 Subject: [PATCH 15/92] Base AccountSeed on account list --- database/seeds/UserSeeder.php | 124 ++++++++++++++++++---------------- 1 file changed, 64 insertions(+), 60 deletions(-) diff --git a/database/seeds/UserSeeder.php b/database/seeds/UserSeeder.php index ffcd89c4..17e8c188 100644 --- a/database/seeds/UserSeeder.php +++ b/database/seeds/UserSeeder.php @@ -72,8 +72,8 @@ public function run() shuffle($accounts); - factory(App\User::class, 35)->create()->each(function ($u) use ($accounts) { - $randomId = rand(0, sizeof($accounts) - 1); + factory(App\User::class, sizeof($accounts))->create()->each(function ($u) use ($accounts) { + $randomId = rand(1, sizeof($accounts)); if (App\Account::where('username', $accounts[$randomId])->first()) { return null; @@ -85,86 +85,90 @@ public function run() /* Get the $playerDataUrl file content. */ $playerData = Helper::getPlayerData($playerDataUrl); - $account = Account::firstOrCreate([ - 'user_id' => rand(1, 10), - 'account_type' => Helper::listAccountTypes()[rand(0, 3)], - 'username' => $accounts[$randomId], - 'rank' => $playerData[0][0], - 'level' => $playerData[0][1], - 'xp' => $playerData[0][2] - ]); - - $skills = Helper::listSkills(); - - for ($i = 0; $i < count($skills); $i++) { - DB::table($skills[$i])->insert([ - 'account_id' => $account->id, - 'rank' => ($playerData[$i + 1][0] >= 1 ? $playerData[$i + 1][0] : 0), - 'level' => $playerData[$i + 1][1], - 'xp' => ($playerData[$i + 1][2] >= 0 ? $playerData[$i + 1][2] : 0), - 'created_at' => Carbon::now(), - 'updated_at' => Carbon::now() + if ($playerData) { + $account = Account::firstOrCreate([ + 'user_id' => rand(1, sizeof($accounts) - 1), + 'account_type' => Helper::listAccountTypes()[rand(0, 3)], + 'username' => $accounts[$randomId], + 'rank' => $playerData[0][0], + 'level' => $playerData[0][1], + 'xp' => $playerData[0][2] ]); - } - $clueScrollAmount = count(Helper::listClueScrollTiers()); + $skills = Helper::listSkills(); + + for ($i = 0; $i < count($skills); $i++) { + DB::table($skills[$i])->insert([ + 'account_id' => $account->id, + 'rank' => ($playerData[$i + 1][0] >= 1 ? $playerData[$i + 1][0] : 0), + 'level' => $playerData[$i + 1][1], + 'xp' => ($playerData[$i + 1][2] >= 0 ? $playerData[$i + 1][2] : 0), + 'created_at' => Carbon::now(), + 'updated_at' => Carbon::now() + ]); + } - $bosses = Helper::listBosses(); + $clueScrollAmount = count(Helper::listClueScrollTiers()); - array_splice($bosses, 13, 1); + $bosses = Helper::listBosses(); - $bossIndex = 0; + array_splice($bosses, 13, 1); - $dksKillCount = 0; + $bossIndex = 0; - for ($i = (count($skills) + $clueScrollAmount + 4); $i < (count($skills) + $clueScrollAmount + 4 + count($bosses)); $i++) { - $collection = Collection::where('name', $bosses[$bossIndex])->firstOrFail(); + $dksKillCount = 0; - $collectionLoot = new $collection->model; + for ($i = (count($skills) + $clueScrollAmount + 4); $i < (count($skills) + $clueScrollAmount + 4 + count($bosses)); $i++) { + $collection = Collection::where('name', $bosses[$bossIndex])->firstOrFail(); - $collectionLoot->account_id = $account->id; - $collectionLoot->kill_count = ($playerData[$i + 1][1] >= 0 ? $playerData[$i + 1][1] : 0); - $collectionLoot->rank = ($playerData[$i + 1][0] >= 0 ? $playerData[$i + 1][0] : 0); + $collectionLoot = new $collection->model; - if (in_array($bosses[$bossIndex], - ['dagannoth prime', 'dagannoth rex', 'dagannoth supreme'], true)) { - $dksKillCount += ($playerData[$i + 1][1] >= 0 ? $playerData[$i + 1][1] : 0); - } + $collectionLoot->account_id = $account->id; + $collectionLoot->kill_count = ($playerData[$i + 1][1] >= 0 ? $playerData[$i + 1][1] : 0); + $collectionLoot->rank = ($playerData[$i + 1][0] >= 0 ? $playerData[$i + 1][0] : 0); - $collectionLoot->save(); + if (in_array($bosses[$bossIndex], + ['dagannoth prime', 'dagannoth rex', 'dagannoth supreme'], true)) { + $dksKillCount += ($playerData[$i + 1][1] >= 0 ? $playerData[$i + 1][1] : 0); + } - $bossIndex++; - } + $collectionLoot->save(); + + $bossIndex++; + } - /** - * Since there are no official total kill count hiscore for - * DKS' and we are going to retrieve loot for them from the - * collection log, we have to manually create a table. - * This might also happen with other bosses in the future - * that share collection log entry, but have separate hiscores. - */ - $dks = new \App\Boss\DagannothKings; + /** + * Since there are no official total kill count hiscore for + * DKS' and we are going to retrieve loot for them from the + * collection log, we have to manually create a table. + * This might also happen with other bosses in the future + * that share collection log entry, but have separate hiscores. + */ + $dks = new \App\Boss\DagannothKings; - $dks->account_id = $account->id; - $dks->kill_count = $dksKillCount; + $dks->account_id = $account->id; + $dks->kill_count = $dksKillCount; - $dks->save(); + $dks->save(); - $npcs = Helper::listNpcs(); + $npcs = Helper::listNpcs(); - foreach ($npcs as $npc) { - $collection = Collection::findByNameAndCategory($npc, 4); + foreach ($npcs as $npc) { + $collection = Collection::findByNameAndCategory($npc, 4); - $collectionLoot = new $collection->model; + $collectionLoot = new $collection->model; - $collectionLoot->account_id = $account->id; + $collectionLoot->account_id = $account->id; - $collectionLoot->save(); - } + $collectionLoot->save(); + } - print_r('Added ' . $accounts[$randomId]); + print_r('Added ' . $accounts[$randomId]); - return $account->toArray(); + return $account->toArray(); + } else { + return null; + } }); } } From 794aba119ef58b3ef607bbadd08630ef55312561 Mon Sep 17 00:00:00 2001 From: Zlimon Date: Sun, 10 Jan 2021 02:08:24 +0100 Subject: [PATCH 16/92] Account online check --- .../Controllers/Api/AccountController.php | 96 ++++++++++++++++++- ...020_08_14_225333_create_accounts_table.php | 1 + routes/api.php | 3 + 3 files changed, 95 insertions(+), 5 deletions(-) diff --git a/app/Http/Controllers/Api/AccountController.php b/app/Http/Controllers/Api/AccountController.php index 7a6aa7e4..2a59ea44 100644 --- a/app/Http/Controllers/Api/AccountController.php +++ b/app/Http/Controllers/Api/AccountController.php @@ -5,11 +5,15 @@ use App\Account; use App\AccountAuthStatus; use App\Collection; +use App\Events\AccountAll; +use App\Events\All; use App\Helpers\Helper; use App\Http\Controllers\Controller; use App\Http\Resources\AccountBossResource; use App\Http\Resources\AccountResource; use App\Http\Resources\AccountSkillResource; +use App\Log; +use App\Notification; use Carbon\Carbon; use Illuminate\Http\Request; use Illuminate\Support\Facades\DB; @@ -59,14 +63,16 @@ public function store(Request $request) } } - $authStatus = AccountAuthStatus::where('username', request('username'))->where('status', 'pending')->first(); + $accountUsername = request('username'); + + $authStatus = AccountAuthStatus::where('username', $accountUsername)->where('status', 'pending')->first(); if ($authStatus) { if ($authStatus->user_id === auth()->user()->id) { if (request('account_type') === $authStatus->account_type) { if (request('code') === $authStatus->code) { $playerDataUrl = 'https://secure.runescape.com/m=hiscore_oldschool/index_lite.ws?player=' . str_replace(' ', - '%20', request('username')); + '%20', $accountUsername); /* Get the $playerDataUrl file content. */ $playerData = Helper::getPlayerData($playerDataUrl); @@ -75,7 +81,7 @@ public function store(Request $request) $account = Account::create([ 'user_id' => $authStatus->user_id, 'account_type' => request('account_type'), - 'username' => ucfirst(request('username')), + 'username' => ucfirst($accountUsername), 'rank' => $playerData[0][0], 'level' => $playerData[0][1], 'xp' => $playerData[0][2] @@ -165,10 +171,90 @@ public function store(Request $request) 202); } } else { - return response("This account is not linked to your user", 401); + return response($accountUsername . " is not linked to your user", 403); } } else { - return response("This account has no pending status", 202); + return response($accountUsername . " has no pending status"); + } + } + + public function login($accountUsername) + { + $account = Account::where('user_id', auth()->user()->id)->where('username', $accountUsername)->first(); + + if ($account) { + if ($account->online === 1) { + return response($accountUsername . " is already online"); + } + + $account->online = 1; + + $account->save(); + + $logData = [ + "user_id" => auth()->user()->id, + "account_id" => $account->id, + "category_id" => 8, +// "data" => $data + ]; + + $log = Log::create($logData); + + $notificationData = [ + "log_id" => $log->id, + "icon" => auth()->user()->icon_id, + "message" => $accountUsername . " has logged in!", + ]; + + $notification = Notification::create($notificationData); + + All::dispatch($notification); + + AccountAll::dispatch($account, $notification); + + return response($accountUsername . " has been logged in to RuneManager"); + } else { + return response("This account is not authenticated with " . auth()->user()->name, 403); + } + } + + public function logout($accountUsername) + { + $account = Account::where('user_id', auth()->user()->id)->where('username', $accountUsername)->first(); + + if ($account) { + if ($account->online === 0) { + return response($accountUsername . " is not online"); + } + + $account->online = 0; + + $account->save(); + + $logData = [ + "user_id" => auth()->user()->id, + "account_id" => $account->id, + "category_id" => 8, +// "data" => $data + ]; + + $log = Log::create($logData); + + $notificationData = [ + "log_id" => $log->id, + "icon" => auth()->user()->icon_id, + "message" => $accountUsername . " has logged out!", + ]; + + $notification = Notification::create($notificationData); + + All::dispatch($notification); + + AccountAll::dispatch($account, $notification); + + return response($accountUsername . " has been logged off RuneManager"); + } else { + return response("This account is not authenticated with " . auth()->user()->name, 403); } } } diff --git a/database/migrations/2020_08_14_225333_create_accounts_table.php b/database/migrations/2020_08_14_225333_create_accounts_table.php index 2e190d9d..2b8d3b80 100644 --- a/database/migrations/2020_08_14_225333_create_accounts_table.php +++ b/database/migrations/2020_08_14_225333_create_accounts_table.php @@ -22,6 +22,7 @@ public function up() $table->integer('rank')->default(0); $table->integer('level')->default(32); // Minimum total level $table->bigInteger('xp')->default(0); + $table->boolean('online')->default(false); $table->timestamps(); }); } diff --git a/routes/api.php b/routes/api.php index 60eb9944..e383ddc3 100644 --- a/routes/api.php +++ b/routes/api.php @@ -23,6 +23,9 @@ Route::post('/authenticate', 'Api\AccountController@store')->name('authenticate'); // Authenticate user Route::prefix('/account')->group(function() { + Route::put('/{accountUsername}/login', 'Api\AccountController@login')->name('account-login'); // Make account online + Route::put('/{accountUsername}/logout', 'Api\AccountController@logout')->name('account-logout'); // Make account offline + Route::put('/{accountUsername}/loot/{collection}', 'Api\AccountLootController@update')->name('account-loot-update'); // Put loot data - updates collection model Route::post('/{accountUsername}/collection/{collection}', 'Api\AccountCollectionController@update')->name('account-collection-update'); // Post collection data - replaces collection model Route::post('/{accountUsername}/skill/{skill}', 'Api\AccountSkillController@update')->name('account-skill-update'); From 751f8f2f11f75987f1298ab96ac009772c4a008f Mon Sep 17 00:00:00 2001 From: Zlimon Date: Sun, 10 Jan 2021 11:14:27 +0100 Subject: [PATCH 17/92] Soul Wars hiscore entry fix & AccountUpdate refactor --- app/Console/Commands/AccountUpdate.php | 113 +++++++++--------- .../Controllers/Api/AccountController.php | 2 +- 2 files changed, 56 insertions(+), 59 deletions(-) diff --git a/app/Console/Commands/AccountUpdate.php b/app/Console/Commands/AccountUpdate.php index 0c6d8835..020000d4 100644 --- a/app/Console/Commands/AccountUpdate.php +++ b/app/Console/Commands/AccountUpdate.php @@ -44,89 +44,86 @@ public function handle() $accounts = Account::get(); foreach ($accounts as $account) { - $playerDataUrl = 'https://secure.runescape.com/m=hiscore_oldschool/index_lite.ws?player=' . str_replace(' ', - '%20', $account->username); + if ($account->online === 0) { + $playerDataUrl = 'https://secure.runescape.com/m=hiscore_oldschool/index_lite.ws?player=' . str_replace(' ', + '%20', $account->username); - /* Get the $playerDataUrl file content. */ - $getPlayerData = file_get_contents($playerDataUrl); + /* Get the $playerDataUrl file content. */ + $playerData = Helper::getPlayerData($playerDataUrl); - /* Fetch the content from $playerDataUrl. */ - $playerStats = explode("\n", $getPlayerData); + if ($playerData) { + if ($account->xp != $playerData[0][2]) { + $this->info(sprintf("Found outdated data for %s!", $account->username)); - /* Convert the CSV file of player stats into an array */ - $playerData = []; - foreach ($playerStats as $playerStat) { - $playerData[] = str_getcsv($playerStat); - } - - if ($playerData[0][0]) { - if ($account->xp != $playerData[0][2]) { - $this->info(sprintf("Detected %s in database with outdated data! Updating...", $account->username)); + $account->rank = $playerData[0][0]; + $account->level = $playerData[0][1]; + $account->xp = $playerData[0][2]; - $account->rank = $playerData[0][0]; - $account->level = $playerData[0][1]; - $account->xp = $playerData[0][2]; + $account->update(); - $account->update(); + $skills = Helper::listSkills(); - $skills = Helper::listSkills(); + for ($i = 0; $i < count($skills); $i++) { + DB::table($skills[$i]) + ->where('account_id', $account->id) + ->update([ + 'rank' => ($playerData[$i + 1][0] >= 1 ? $playerData[$i + 1][0] : 0), + 'level' => $playerData[$i + 1][1], + 'xp' => ($playerData[$i + 1][2] >= 0 ? $playerData[$i + 1][2] : 0) + ]); + } - for ($i = 0; $i < count($skills); $i++) { - DB::table($skills[$i]) - ->where('account_id', $account->id) - ->update([ - 'rank' => ($playerData[$i + 1][0] >= 1 ? $playerData[$i + 1][0] : 0), - 'level' => $playerData[$i + 1][1], - 'xp' => ($playerData[$i + 1][2] >= 0 ? $playerData[$i + 1][2] : 0) - ]); - } + $clueScrollAmount = count(Helper::listClueScrollTiers()); - $clueScrollAmount = count(Helper::listClueScrollTiers()); + $bosses = Helper::listBosses(); - $bosses = Helper::listBosses(); + array_splice($bosses, 13, 1); - array_splice($bosses, 13, 1); + $bossIndex = 0; - $bossCounter = 0; + $dksKillCount = 0; - $dksKillCount = 0; + for ($i = (count($skills) + $clueScrollAmount + 5); $i < (count($skills) + $clueScrollAmount + 5 + count($bosses)); $i++) { + $collection = Collection::where('name', $bosses[$bossIndex])->firstOrFail(); - for ($i = (count($skills) + $clueScrollAmount + 4); $i < (count($skills) + $clueScrollAmount + 4 + count($bosses)); $i++) { - $collection = Collection::findByName($bosses[$bossCounter]); + $collectionLoot = $collection->model::where('account_id', $account->id)->firstOrFail(); - $collection = $collection->model::where('account_id', $account->id)->first(); + $collectionLoot->account_id = $account->id; + $collectionLoot->kill_count = ($playerData[$i + 1][1] >= 0 ? $playerData[$i + 1][1] : 0); + $collectionLoot->rank = ($playerData[$i + 1][0] >= 0 ? $playerData[$i + 1][0] : 0); - $collection->kill_count = ($playerData[$i + 1][1] >= 0 ? $playerData[$i + 1][1] : 0); - $collection->rank = ($playerData[$i + 1][0] >= 0 ? $playerData[$i + 1][0] : 0); + if (in_array($bosses[$bossIndex], + ['dagannoth prime', 'dagannoth rex', 'dagannoth supreme'], true)) { + $dksKillCount += ($playerData[$i + 1][1] >= 0 ? $playerData[$i + 1][1] : 0); + } - $collection->update(); + $collectionLoot->update(); - if (in_array($bosses[$bossCounter], ['dagannoth prime', 'dagannoth rex', 'dagannoth supreme'], - true)) { - $dksKillCount += ($playerData[$i + 1][1] >= 0 ? $playerData[$i + 1][1] : 0); + $bossIndex++; } - $bossCounter++; - } - - /** - * Since there are no official total kill count hiscore for - * DKS' and we are going to retrieve loot for them from the - * collection log, we have to manually create a table. - * This might also happen with other bosses in the future. - */ - $dks = \App\Boss\DagannothKings::where('account_id', $account->id)->first();; + /** + * Since there are no official total kill count hiscore for + * DKS' and we are going to retrieve loot for them from the + * collection log, we have to manually create a table. + * This might also happen with other bosses in the future + * that share collection log entry, but have separate hiscores. + */ + $dks = \App\Boss\DagannothKings::where('account_id', $account->id)->firstOrFail(); - $dks->kill_count = $dksKillCount; + $dks->kill_count = $dksKillCount; - $dks->update(); + $dks->update(); - $this->info(sprintf("Updated %s!", $account->username)); + $this->info(sprintf("Updated %s!", $account->username)); + } else { + $this->info(sprintf("No outdated data for %s! Not updating", $account->username)); + } } else { - $this->info(sprintf("No outdated data for %s! Not updating...", $account->username)); + $this->info(sprintf("Could not fetch player data for %s from hiscores! Not updating", $account->username)); } } else { - $this->info(sprintf("Could not fetch player data from hiscores")); + $this->info(sprintf("%s is logged in to the game! Not updating", $account->username)); } } } diff --git a/app/Http/Controllers/Api/AccountController.php b/app/Http/Controllers/Api/AccountController.php index 2a59ea44..ec381cbf 100644 --- a/app/Http/Controllers/Api/AccountController.php +++ b/app/Http/Controllers/Api/AccountController.php @@ -110,7 +110,7 @@ public function store(Request $request) $dksKillCount = 0; - for ($i = (count($skills) + $clueScrollAmount + 4); $i < (count($skills) + $clueScrollAmount + 4 + count($bosses)); $i++) { + for ($i = (count($skills) + $clueScrollAmount + 5); $i < (count($skills) + $clueScrollAmount + 5 + count($bosses)); $i++) { $collection = Collection::where('name', $bosses[$bossIndex])->firstOrFail(); $collectionLoot = new $collection->model; From caf70d0256801a5bba316fef51551ebe643dc9ad Mon Sep 17 00:00:00 2001 From: Zlimon Date: Sun, 10 Jan 2021 11:21:59 +0100 Subject: [PATCH 18/92] Notification styling improvements & moment.js install --- package-lock.json | 13 ++++++++++ package.json | 1 + public/css/style.css | 1 - resources/js/app.js | 1 + resources/js/components/Notification.vue | 32 ++++++++++++++++-------- 5 files changed, 37 insertions(+), 11 deletions(-) diff --git a/package-lock.json b/package-lock.json index 78e5931d..f6159972 100644 --- a/package-lock.json +++ b/package-lock.json @@ -5728,6 +5728,11 @@ "minimist": "^1.2.5" } }, + "moment": { + "version": "2.29.1", + "resolved": "https://registry.npmjs.org/moment/-/moment-2.29.1.tgz", + "integrity": "sha512-kHmoybcPV8Sqy59DwNDY3Jefr64lK/by/da0ViFcuA4DH0vQg5Q6Ze5VimxkfQNSC+Mls/Kx53s7TjP1RhFEDQ==" + }, "move-concurrently": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/move-concurrently/-/move-concurrently-1.0.1.tgz", @@ -9154,6 +9159,14 @@ "vue-style-loader": "^4.1.0" } }, + "vue-moment": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/vue-moment/-/vue-moment-4.1.0.tgz", + "integrity": "sha512-Gzisqpg82ItlrUyiD9d0Kfru+JorW2o4mQOH06lEDZNgxci0tv/fua1Hl0bo4DozDV2JK1r52Atn/8QVCu8qQw==", + "requires": { + "moment": "^2.19.2" + } + }, "vue-style-loader": { "version": "4.1.2", "resolved": "https://registry.npmjs.org/vue-style-loader/-/vue-style-loader-4.1.2.tgz", diff --git a/package.json b/package.json index cb1b9f89..70dcecd5 100644 --- a/package.json +++ b/package.json @@ -26,6 +26,7 @@ "vue-template-compiler": "^2.6.10" }, "dependencies": { + "vue-moment": "^4.1.0", "vue-unique-id": "^3.1.4" } } diff --git a/public/css/style.css b/public/css/style.css index f5631394..ef82c0f1 100644 --- a/public/css/style.css +++ b/public/css/style.css @@ -329,7 +329,6 @@ table th width: 60px; height: 60px; object-fit: contain; - border-right: solid 2px; } .hiscore-icon { diff --git a/resources/js/app.js b/resources/js/app.js index 37552005..709fc907 100644 --- a/resources/js/app.js +++ b/resources/js/app.js @@ -22,6 +22,7 @@ window.Vue = require('vue'); import UniqueId from 'vue-unique-id'; Vue.use(UniqueId); +Vue.use(require('vue-moment')); Vue.component('skillhiscore', require('./components/SkillHiscore.vue').default); Vue.component('bosshiscore', require('./components/BossHiscore.vue').default); diff --git a/resources/js/components/Notification.vue b/resources/js/components/Notification.vue index 4161b4ed..f2023d22 100644 --- a/resources/js/components/Notification.vue +++ b/resources/js/components/Notification.vue @@ -2,31 +2,43 @@
-
-
-
- +
+
+
+
+ +
+
+ +
-
+
{{ notification.message }}
-
+

Received loot:

-
+
+ +
+ {{ notification.log.created_at | moment("from") }} +
From 24ff1aa67e3fdbf9c6b1412095f3b1e50a2fb4d7 Mon Sep 17 00:00:00 2001 From: Zlimon Date: Sun, 10 Jan 2021 17:59:59 +0100 Subject: [PATCH 19/92] Create NPC command --- app/Collection.php | 4 ++ app/Console/Commands/NpcCreate.php | 102 +++++++++++++++++++++++++++++ composer.json | 1 + composer.lock | 59 ++++++++++++++++- 4 files changed, 164 insertions(+), 2 deletions(-) create mode 100644 app/Console/Commands/NpcCreate.php diff --git a/app/Collection.php b/app/Collection.php index 1d5d0013..b211f269 100644 --- a/app/Collection.php +++ b/app/Collection.php @@ -23,6 +23,10 @@ */ class Collection extends Model { + protected $fillable = ['category_id', 'name', 'alias', 'model']; + + public $timestamps = false; + public static function findByNameAndCategory($name, $category_id) { return self::where([['name', $name], ['category_id', $category_id]])->firstOrFail(); diff --git a/app/Console/Commands/NpcCreate.php b/app/Console/Commands/NpcCreate.php new file mode 100644 index 00000000..7cd20428 --- /dev/null +++ b/app/Console/Commands/NpcCreate.php @@ -0,0 +1,102 @@ +argument('npc')))); + + $uniques = implode( + ' ', + array_map( + function($unique) { + return(str_replace("-","_", Str::snake($unique)) . ':integer:default(0):unsigned,'); + }, + $this->argument('unique') + ) + ); + + $command = 'make:migration:schema create_' . Str::snake(Str::singular($this->argument('npc'))) . '_table --schema="account_id:integer:unsigned:unique, kill_count:integer:default(0):unsigned, obtained:integer:default(0):unsigned, ' .substr($uniques, 0, -1) . '"'; + + $execute = Artisan::call($command); + +// $oldPath = 'app/' . ucfirst($this->argument('npc') . '.php'); + $model = 'app/npc/' . $modelName . '.php'; + +// $move = \File::move($oldPath, $newPath); + + $modelFile = fopen($model, + 'w') or die ('Unable to open or create model file! You have to manually edit this for this hiscore to work!'); + + fwrite($modelFile, "argument('npc'))) . '\';' . "\r\n"); + fwrite($modelFile, "\r\n"); + fwrite($modelFile, ' protected $fillable = [' . "\r\n"); + fwrite($modelFile, " 'obtained',\r\n"); + fwrite($modelFile, " 'kill_count',\r\n"); + foreach ($this->argument('unique') as $unique) fwrite($modelFile, " '" . str_replace("-","_", Str::snake($unique)) . "',\r\n"); + fwrite($modelFile, " ];\r\n"); + fwrite($modelFile, "\r\n"); + fwrite($modelFile, ' protected $hidden = [\'user_id\'];' . "\r\n"); + fwrite($modelFile, "\r\n"); + fwrite($modelFile, " public function account()\r\n"); + fwrite($modelFile, " {\r\n"); + fwrite($modelFile, ' return $this->belongsTo(\App\Account::class);' . "\r\n"); + fwrite($modelFile, " }\r\n"); + fwrite($modelFile, "}\r\n"); + + fclose($modelFile); + + Artisan::call('migrate'); + + Collection::create([ + 'category_id' => 4, + 'name' => str_replace("_"," ", Str::snake(Str::singular($this->argument('npc')))), + 'alias' => ucfirst(str_replace("_"," ", Str::snake(Str::singular($this->argument('npc'))))), + 'model' => "App\Npc\\" . $modelName, + ]); + } +} diff --git a/composer.json b/composer.json index e975c3d4..4a6307c8 100644 --- a/composer.json +++ b/composer.json @@ -24,6 +24,7 @@ "barryvdh/laravel-ide-helper": "^2.8", "facade/ignition": "^2.0", "fzaninotto/faker": "^1.9.1", + "laracasts/generators": "^2.0", "laravel/homestead": "^11.0", "mockery/mockery": "^1.3.1", "nunomaduro/collision": "^4.1", diff --git a/composer.lock b/composer.lock index 68bd5e61..833fe5f1 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "0e3b3db7d58bf17b9f5fff75ca6088e5", + "content-hash": "0acd475adeb3256c06d6d939213d4d01", "packages": [ { "name": "asm89/stack-cors", @@ -6857,6 +6857,60 @@ ], "time": "2020-05-27T16:41:55+00:00" }, + { + "name": "laracasts/generators", + "version": "2.0.0", + "source": { + "type": "git", + "url": "https://github.com/laracasts/Laravel-5-Generators-Extended.git", + "reference": "0b8b3d300cc948217f7547502b6de5db6fbafa70" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/laracasts/Laravel-5-Generators-Extended/zipball/0b8b3d300cc948217f7547502b6de5db6fbafa70", + "reference": "0b8b3d300cc948217f7547502b6de5db6fbafa70", + "shasum": "" + }, + "require": { + "illuminate/support": "~6.0|~7.0|~8.0" + }, + "require-dev": { + "phpspec/phpspec": "~6.0" + }, + "type": "library", + "extra": { + "laravel": { + "providers": [ + "Laracasts\\Generators\\GeneratorsServiceProvider" + ] + } + }, + "autoload": { + "psr-4": { + "Laracasts\\Generators\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Jeffrey Way", + "email": "jeffrey@laracasts.com" + }, + { + "name": "Cristian Tabacitu", + "email": "hello@tabaciu.ro" + } + ], + "description": "Advanced Laravel generators, that include schema information.", + "keywords": [ + "generators", + "laravel" + ], + "time": "2020-09-10T13:49:13+00:00" + }, { "name": "laravel/homestead", "version": "v11.2.4", @@ -8708,7 +8762,8 @@ "prefer-stable": true, "prefer-lowest": false, "platform": { - "php": "^7.2.5" + "php": "^7.2.5", + "ext-curl": "*" }, "platform-dev": [] } From 1990cb378cc3d3e888c7a787a87d737f70390698 Mon Sep 17 00:00:00 2001 From: Zlimon Date: Sun, 10 Jan 2021 18:58:29 +0100 Subject: [PATCH 20/92] Loading animation for Vue components & hiscore category check --- .../Controllers/Api/HiscoreController.php | 75 ++++--- .../{abyssal sire.png => abyssal_sire.png} | Bin ...hemical hydra.png => alchemical_hydra.png} | Bin ...{barrows chests.png => barrows_chests.png} | Bin ...ers of xeric.png => chambers_of_xeric.png} | Bin ...g => chambers_of_xeric_challenge_mode.png} | Bin ...haos elemental.png => chaos_elemental.png} | Bin .../{chaos fanatic.png => chaos_fanatic.png} | Bin ...nder zilyana.png => commander_zilyana.png} | Bin ...orporeal beast.png => corporeal_beast.png} | Bin ...haeologist.png => crazy_archaeologist.png} | Bin ...agannoth kings.png => dagannoth_kings.png} | Bin ...agannoth prime.png => dagannoth_prime.png} | Bin .../{dagannoth rex.png => dagannoth_rex.png} | Bin ...noth supreme.png => dagannoth_supreme.png} | Bin ...ologist.png => deranged_archaeologist.png} | Bin ...eral graardor.png => general_graardor.png} | Bin .../boss/{giant mole.png => giant_mole.png} | Bin ... guardians.png => grotesque_guardians.png} | Bin ...{kalphite queen.png => kalphite_queen.png} | Bin ...black dragon.png => king_black_dragon.png} | Bin ...ril tsutsaroth.png => kril_tsutsaroth.png} | Bin ...auntlet.png => the_corrupted_gauntlet.png} | Bin ...he fight caves.png => the_fight_caves.png} | Bin .../{the gauntlet.png => the_gauntlet.png} | Bin .../boss/{the inferno.png => the_inferno.png} | Bin .../{the nightmare.png => the_nightmare.png} | Bin ...atre of blood.png => theatre_of_blood.png} | Bin ...evil.png => thermonuclear_smoke_devil.png} | Bin .../js/components/AccountBossHiscore.vue | 192 ++++++++++-------- .../js/components/AccountSkillHiscore.vue | 98 ++++++--- resources/js/components/BossHiscore.vue | 170 +++++++++------- resources/js/components/Notification.vue | 2 +- resources/js/components/NpcHiscore.vue | 169 ++++++++------- resources/js/components/SkillHiscore.vue | 82 +++++--- resources/views/hiscore.blade.php | 13 +- 36 files changed, 482 insertions(+), 319 deletions(-) rename public/images/boss/{abyssal sire.png => abyssal_sire.png} (100%) rename public/images/boss/{alchemical hydra.png => alchemical_hydra.png} (100%) rename public/images/boss/{barrows chests.png => barrows_chests.png} (100%) rename public/images/boss/{chambers of xeric.png => chambers_of_xeric.png} (100%) rename public/images/boss/{chambers of xeric challenge mode.png => chambers_of_xeric_challenge_mode.png} (100%) rename public/images/boss/{chaos elemental.png => chaos_elemental.png} (100%) rename public/images/boss/{chaos fanatic.png => chaos_fanatic.png} (100%) rename public/images/boss/{commander zilyana.png => commander_zilyana.png} (100%) rename public/images/boss/{corporeal beast.png => corporeal_beast.png} (100%) rename public/images/boss/{crazy archaeologist.png => crazy_archaeologist.png} (100%) rename public/images/boss/{dagannoth kings.png => dagannoth_kings.png} (100%) rename public/images/boss/{dagannoth prime.png => dagannoth_prime.png} (100%) rename public/images/boss/{dagannoth rex.png => dagannoth_rex.png} (100%) rename public/images/boss/{dagannoth supreme.png => dagannoth_supreme.png} (100%) rename public/images/boss/{deranged archaeologist.png => deranged_archaeologist.png} (100%) rename public/images/boss/{general graardor.png => general_graardor.png} (100%) rename public/images/boss/{giant mole.png => giant_mole.png} (100%) rename public/images/boss/{grotesque guardians.png => grotesque_guardians.png} (100%) rename public/images/boss/{kalphite queen.png => kalphite_queen.png} (100%) rename public/images/boss/{king black dragon.png => king_black_dragon.png} (100%) rename public/images/boss/{kril tsutsaroth.png => kril_tsutsaroth.png} (100%) rename public/images/boss/{the corrupted gauntlet.png => the_corrupted_gauntlet.png} (100%) rename public/images/boss/{the fight caves.png => the_fight_caves.png} (100%) rename public/images/boss/{the gauntlet.png => the_gauntlet.png} (100%) rename public/images/boss/{the inferno.png => the_inferno.png} (100%) rename public/images/boss/{the nightmare.png => the_nightmare.png} (100%) rename public/images/boss/{theatre of blood.png => theatre_of_blood.png} (100%) rename public/images/boss/{thermonuclear smoke devil.png => thermonuclear_smoke_devil.png} (100%) diff --git a/app/Http/Controllers/Api/HiscoreController.php b/app/Http/Controllers/Api/HiscoreController.php index ecd91876..2e324a3f 100644 --- a/app/Http/Controllers/Api/HiscoreController.php +++ b/app/Http/Controllers/Api/HiscoreController.php @@ -79,25 +79,32 @@ public function skill($skillName) public function boss($bossName) { if (Account::count() > 0) { - $collection = Collection::where('name', $bossName)->firstOrFail(); + $collection = Collection::where('name', $bossName)->where(function ($query) { + $query->where('category_id', 2) + ->orWhere('category_id', 3); + })->firstOrFail(); - $boss = $collection->model::with('account')->orderByDesc('kill_count')->get(); + $bossHiscore = $collection->model::with('account')->orderByDesc('kill_count')->get(); - $sumKills = $collection->model::selectRaw('SUM(kill_count) AS total_kill_count') - ->selectRaw('COUNT(*) AS total_kills') - ->first(); - - $averageTotalKills = $sumKills["total_kill_count"] / $sumKills["total_kills"]; + if (sizeof($bossHiscore) > 0) { + $sumKills = $collection->model::selectRaw('SUM(kill_count) AS total_kill_count') + ->selectRaw('COUNT(*) AS total_kills') + ->first(); - return BossHiscoreResource::collection($boss) - ->additional([ - 'meta' => [ - 'boss' => str_replace(" ", "_", $bossName), - 'alias' => $collection->alias, - 'total_kills' => number_format($sumKills["total_kill_count"]), - 'average_total_kills' => round($averageTotalKills), - ] - ]); + $averageTotalKills = $sumKills["total_kill_count"] / $sumKills["total_kills"]; + + return BossHiscoreResource::collection($bossHiscore) + ->additional([ + 'meta' => [ + 'boss' => str_replace(" ", "_", $bossName), + 'alias' => $collection->alias, + 'total_kills' => number_format($sumKills["total_kill_count"]), + 'average_total_kills' => round($averageTotalKills), + ] + ]); + } else { + return response()->json("There are no registered collections for " . $bossName, 404); + } } else { return response()->json("There are no linked accounts", 404); } @@ -106,25 +113,29 @@ public function boss($bossName) public function npc($npcName) { if (Account::count() > 0) { - $collection = Collection::where('name', $npcName)->firstOrFail(); + $collection = Collection::where('name', $npcName)->where('category_id', 4)->firstOrFail(); - $npc = $collection->model::with('account')->orderByDesc('kill_count')->get(); + $npcHiscore = $collection->model::with('account')->orderByDesc('kill_count')->get(); - $sumKills = $collection->model::selectRaw('SUM(kill_count) AS total_kill_count') - ->selectRaw('COUNT(*) AS total_kills') - ->first(); - - $averageTotalKills = $sumKills["total_kill_count"] / $sumKills["total_kills"]; + if (sizeof($npcHiscore) > 0) { + $sumKills = $collection->model::selectRaw('SUM(kill_count) AS total_kill_count') + ->selectRaw('COUNT(*) AS total_kills') + ->first(); - return BossHiscoreResource::collection($npc) - ->additional([ - 'meta' => [ - 'npc' => str_replace(" ", "_", $npcName), - 'alias' => $collection->alias, - 'total_kills' => number_format($sumKills["total_kill_count"]), - 'average_total_kills' => round($averageTotalKills), - ] - ]); + $averageTotalKills = $sumKills["total_kill_count"] / $sumKills["total_kills"]; + + return BossHiscoreResource::collection($npcHiscore) + ->additional([ + 'meta' => [ + 'npc' => str_replace(" ", "_", $npcName), + 'alias' => $collection->alias, + 'total_kills' => number_format($sumKills["total_kill_count"]), + 'average_total_kills' => round($averageTotalKills), + ] + ]); + } else { + return response()->json("There are no registered collections for " . $npcName, 404); + } } else { return response()->json("There are no linked accounts", 404); } diff --git a/public/images/boss/abyssal sire.png b/public/images/boss/abyssal_sire.png similarity index 100% rename from public/images/boss/abyssal sire.png rename to public/images/boss/abyssal_sire.png diff --git a/public/images/boss/alchemical hydra.png b/public/images/boss/alchemical_hydra.png similarity index 100% rename from public/images/boss/alchemical hydra.png rename to public/images/boss/alchemical_hydra.png diff --git a/public/images/boss/barrows chests.png b/public/images/boss/barrows_chests.png similarity index 100% rename from public/images/boss/barrows chests.png rename to public/images/boss/barrows_chests.png diff --git a/public/images/boss/chambers of xeric.png b/public/images/boss/chambers_of_xeric.png similarity index 100% rename from public/images/boss/chambers of xeric.png rename to public/images/boss/chambers_of_xeric.png diff --git a/public/images/boss/chambers of xeric challenge mode.png b/public/images/boss/chambers_of_xeric_challenge_mode.png similarity index 100% rename from public/images/boss/chambers of xeric challenge mode.png rename to public/images/boss/chambers_of_xeric_challenge_mode.png diff --git a/public/images/boss/chaos elemental.png b/public/images/boss/chaos_elemental.png similarity index 100% rename from public/images/boss/chaos elemental.png rename to public/images/boss/chaos_elemental.png diff --git a/public/images/boss/chaos fanatic.png b/public/images/boss/chaos_fanatic.png similarity index 100% rename from public/images/boss/chaos fanatic.png rename to public/images/boss/chaos_fanatic.png diff --git a/public/images/boss/commander zilyana.png b/public/images/boss/commander_zilyana.png similarity index 100% rename from public/images/boss/commander zilyana.png rename to public/images/boss/commander_zilyana.png diff --git a/public/images/boss/corporeal beast.png b/public/images/boss/corporeal_beast.png similarity index 100% rename from public/images/boss/corporeal beast.png rename to public/images/boss/corporeal_beast.png diff --git a/public/images/boss/crazy archaeologist.png b/public/images/boss/crazy_archaeologist.png similarity index 100% rename from public/images/boss/crazy archaeologist.png rename to public/images/boss/crazy_archaeologist.png diff --git a/public/images/boss/dagannoth kings.png b/public/images/boss/dagannoth_kings.png similarity index 100% rename from public/images/boss/dagannoth kings.png rename to public/images/boss/dagannoth_kings.png diff --git a/public/images/boss/dagannoth prime.png b/public/images/boss/dagannoth_prime.png similarity index 100% rename from public/images/boss/dagannoth prime.png rename to public/images/boss/dagannoth_prime.png diff --git a/public/images/boss/dagannoth rex.png b/public/images/boss/dagannoth_rex.png similarity index 100% rename from public/images/boss/dagannoth rex.png rename to public/images/boss/dagannoth_rex.png diff --git a/public/images/boss/dagannoth supreme.png b/public/images/boss/dagannoth_supreme.png similarity index 100% rename from public/images/boss/dagannoth supreme.png rename to public/images/boss/dagannoth_supreme.png diff --git a/public/images/boss/deranged archaeologist.png b/public/images/boss/deranged_archaeologist.png similarity index 100% rename from public/images/boss/deranged archaeologist.png rename to public/images/boss/deranged_archaeologist.png diff --git a/public/images/boss/general graardor.png b/public/images/boss/general_graardor.png similarity index 100% rename from public/images/boss/general graardor.png rename to public/images/boss/general_graardor.png diff --git a/public/images/boss/giant mole.png b/public/images/boss/giant_mole.png similarity index 100% rename from public/images/boss/giant mole.png rename to public/images/boss/giant_mole.png diff --git a/public/images/boss/grotesque guardians.png b/public/images/boss/grotesque_guardians.png similarity index 100% rename from public/images/boss/grotesque guardians.png rename to public/images/boss/grotesque_guardians.png diff --git a/public/images/boss/kalphite queen.png b/public/images/boss/kalphite_queen.png similarity index 100% rename from public/images/boss/kalphite queen.png rename to public/images/boss/kalphite_queen.png diff --git a/public/images/boss/king black dragon.png b/public/images/boss/king_black_dragon.png similarity index 100% rename from public/images/boss/king black dragon.png rename to public/images/boss/king_black_dragon.png diff --git a/public/images/boss/kril tsutsaroth.png b/public/images/boss/kril_tsutsaroth.png similarity index 100% rename from public/images/boss/kril tsutsaroth.png rename to public/images/boss/kril_tsutsaroth.png diff --git a/public/images/boss/the corrupted gauntlet.png b/public/images/boss/the_corrupted_gauntlet.png similarity index 100% rename from public/images/boss/the corrupted gauntlet.png rename to public/images/boss/the_corrupted_gauntlet.png diff --git a/public/images/boss/the fight caves.png b/public/images/boss/the_fight_caves.png similarity index 100% rename from public/images/boss/the fight caves.png rename to public/images/boss/the_fight_caves.png diff --git a/public/images/boss/the gauntlet.png b/public/images/boss/the_gauntlet.png similarity index 100% rename from public/images/boss/the gauntlet.png rename to public/images/boss/the_gauntlet.png diff --git a/public/images/boss/the inferno.png b/public/images/boss/the_inferno.png similarity index 100% rename from public/images/boss/the inferno.png rename to public/images/boss/the_inferno.png diff --git a/public/images/boss/the nightmare.png b/public/images/boss/the_nightmare.png similarity index 100% rename from public/images/boss/the nightmare.png rename to public/images/boss/the_nightmare.png diff --git a/public/images/boss/theatre of blood.png b/public/images/boss/theatre_of_blood.png similarity index 100% rename from public/images/boss/theatre of blood.png rename to public/images/boss/theatre_of_blood.png diff --git a/public/images/boss/thermonuclear smoke devil.png b/public/images/boss/thermonuclear_smoke_devil.png similarity index 100% rename from public/images/boss/thermonuclear smoke devil.png rename to public/images/boss/thermonuclear_smoke_devil.png diff --git a/resources/js/components/AccountBossHiscore.vue b/resources/js/components/AccountBossHiscore.vue index ca54a056..e76098a6 100644 --- a/resources/js/components/AccountBossHiscore.vue +++ b/resources/js/components/AccountBossHiscore.vue @@ -1,99 +1,125 @@ @@ -105,6 +131,8 @@ export default { data() { return { + loading: true, + errored: false, data: {}, meta: {} } @@ -117,7 +145,11 @@ export default { this.data = response.data.data; this.meta = response.data.meta; }) - .catch(error => (console.log(error))) + .catch(error => { + console.log(error) + this.errored = true + }) + .finally(() => this.loading = false) }, filters: { diff --git a/resources/js/components/AccountSkillHiscore.vue b/resources/js/components/AccountSkillHiscore.vue index 61b29d77..5acaba7f 100644 --- a/resources/js/components/AccountSkillHiscore.vue +++ b/resources/js/components/AccountSkillHiscore.vue @@ -1,39 +1,65 @@ @@ -45,6 +71,8 @@ export default { data() { return { + loading: true, + errored: false, data: {}, hiscores: {} } @@ -57,7 +85,11 @@ export default { this.data = response.data.data; this.hiscores = response.data.meta.skillHiscores; }) - .catch(error => (console.log(error))) + .catch(error => { + console.log(error) + this.errored = true + }) + .finally(() => this.loading = false) }, filters: { diff --git a/resources/js/components/BossHiscore.vue b/resources/js/components/BossHiscore.vue index d51a91e2..23f7a3e4 100644 --- a/resources/js/components/BossHiscore.vue +++ b/resources/js/components/BossHiscore.vue @@ -1,88 +1,114 @@ @@ -94,6 +120,8 @@ export default { data() { return { + loading: true, + errored: false, hiscores: {}, meta: {}, total: 0 @@ -108,7 +136,11 @@ export default { this.meta = response.data.meta; this.total = Object.keys(response.data.data[0].log).length }) - .catch(error => (console.log(error))) + .catch(error => { + console.log(error) + this.errored = true + }) + .finally(() => this.loading = false) }, filters: { diff --git a/resources/js/components/Notification.vue b/resources/js/components/Notification.vue index f2023d22..6c681089 100644 --- a/resources/js/components/Notification.vue +++ b/resources/js/components/Notification.vue @@ -7,7 +7,7 @@
diff --git a/resources/js/components/NpcHiscore.vue b/resources/js/components/NpcHiscore.vue index b9972662..b580ff29 100644 --- a/resources/js/components/NpcHiscore.vue +++ b/resources/js/components/NpcHiscore.vue @@ -1,88 +1,113 @@ @@ -94,6 +119,8 @@ export default { data() { return { + loading: true, + errored: false, hiscores: {}, meta: {}, total: 0 @@ -108,7 +135,11 @@ export default { this.meta = response.data.meta; this.total = Object.keys(response.data.data[0].log).length }) - .catch(error => (console.log(error))) + .catch(error => { + console.log(error) + this.errored = true + }) + .finally(() => this.loading = false) }, filters: { diff --git a/resources/js/components/SkillHiscore.vue b/resources/js/components/SkillHiscore.vue index 6159ac93..b17dc814 100644 --- a/resources/js/components/SkillHiscore.vue +++ b/resources/js/components/SkillHiscore.vue @@ -1,31 +1,57 @@ @@ -37,6 +63,8 @@ export default { data() { return { + loading: true, + errored: false, hiscores: {}, meta: {} } @@ -49,7 +77,11 @@ export default { this.hiscores = response.data.data; this.meta = response.data.meta; }) - .catch(error => (console.log(error))) + .catch(error => { + console.log(error) + this.errored = true + }) + .finally(() => this.loading = false) }, } diff --git a/resources/views/hiscore.blade.php b/resources/views/hiscore.blade.php index 28b474c2..53b96b7b 100644 --- a/resources/views/hiscore.blade.php +++ b/resources/views/hiscore.blade.php @@ -50,7 +50,7 @@ class="pixel icon" @foreach ($hiscoreListTop as $hiscore) - {{ ucfirst($hiscore) }} {{ $hiscoreType }} icon @@ -59,7 +59,7 @@ class="icon" @if ($accountCount > 0) -
- {{ ucfirst($hiscoreName) }} {{ $hiscoreType }} icon -
- @if ($hiscoreType == "skill") @elseif ($hiscoreType == "boss") From 9bf6ef240fa5cc3bf07f9a3da96d688fb9bc5f21 Mon Sep 17 00:00:00 2001 From: Zlimon Date: Sun, 10 Jan 2021 19:12:26 +0100 Subject: [PATCH 21/92] Create collection entry when null --- app/Http/Controllers/Api/AccountLootController.php | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/app/Http/Controllers/Api/AccountLootController.php b/app/Http/Controllers/Api/AccountLootController.php index 0b645e2c..8bdad770 100644 --- a/app/Http/Controllers/Api/AccountLootController.php +++ b/app/Http/Controllers/Api/AccountLootController.php @@ -24,6 +24,15 @@ public function update($accountUsername, $collectionName, Request $request) $collectionLog = $collection->model::where('account_id', $account->id)->first(); + // If account has no collection entry, create it + if (is_null($collectionLog)) { + $collectionLog = new $collection->model; + + $collectionLog->account_id = $account->id; + + $collectionLog->save(); + } + if ($collectionLog) { $oldValues = $collectionLog->getAttributes(); // Get old data //array_splice($oldValues, count($oldValues) - 2, 2); // Remove created_at and updated_at From 2cf35f621de9c56ea8d87ff57254aadca1ccbf50 Mon Sep 17 00:00:00 2001 From: Zlimon Date: Tue, 12 Jan 2021 23:30:15 +0100 Subject: [PATCH 22/92] Fetch npc loot and hiscore icons --- app/Console/Commands/NpcCreate.php | 59 +++++++++++++++++++++++++----- 1 file changed, 50 insertions(+), 9 deletions(-) diff --git a/app/Console/Commands/NpcCreate.php b/app/Console/Commands/NpcCreate.php index 7cd20428..01a0b225 100644 --- a/app/Console/Commands/NpcCreate.php +++ b/app/Console/Commands/NpcCreate.php @@ -5,6 +5,7 @@ use App\Collection; use Artisan; use Illuminate\Console\Command; +use Illuminate\Support\Facades\File; use Illuminate\Support\Str; class NpcCreate extends Command @@ -42,17 +43,24 @@ public function handle() { $modelName = Str::studly(Str::singular(class_basename($this->argument('npc')))); + Collection::create([ + 'category_id' => 4, + 'name' => str_replace("_", " ", Str::snake(Str::singular($this->argument('npc')))), + 'alias' => ucfirst(str_replace("_", " ", Str::snake(Str::singular($this->argument('npc'))))), + 'model' => "App\Npc\\" . $modelName, + ]); + $uniques = implode( ' ', array_map( - function($unique) { - return(str_replace("-","_", Str::snake($unique)) . ':integer:default(0):unsigned,'); + function ($unique) { + return (str_replace("-", "_", Str::snake($unique)) . ':integer:default(0):unsigned,'); }, $this->argument('unique') ) ); - $command = 'make:migration:schema create_' . Str::snake(Str::singular($this->argument('npc'))) . '_table --schema="account_id:integer:unsigned:unique, kill_count:integer:default(0):unsigned, obtained:integer:default(0):unsigned, ' .substr($uniques, 0, -1) . '"'; + $command = 'make:migration:schema create_' . Str::snake(Str::singular($this->argument('npc'))) . '_table --schema="account_id:integer:unsigned:unique, kill_count:integer:default(0):unsigned, obtained:integer:default(0):unsigned, ' . substr($uniques, 0, -1) . '"'; $execute = Artisan::call($command); @@ -92,11 +100,44 @@ function($unique) { Artisan::call('migrate'); - Collection::create([ - 'category_id' => 4, - 'name' => str_replace("_"," ", Str::snake(Str::singular($this->argument('npc')))), - 'alias' => ucfirst(str_replace("_"," ", Str::snake(Str::singular($this->argument('npc'))))), - 'model' => "App\Npc\\" . $modelName, - ]); + $i = 0; + foreach ($this->argument('unique') as $key => $unique) { + $handle = curl_init("https://api.osrsbox.com/items?where=" . urlencode('{"name":"' . ucfirst(str_replace("_", " ", Str::snake($unique))) . '","duplicate":false}')); + curl_setopt($handle, CURLOPT_RETURNTRANSFER, true); + + /* Get the content of $url. */ + $response = curl_exec($handle); + + /* Check for errors (content not found). */ + $httpCode = curl_getinfo($handle, CURLINFO_HTTP_CODE); + curl_close($handle); + + /* If the document has loaded successfully without any redirection or error */ + if ($httpCode >= 200 && $httpCode < 300) { + $json = json_decode($response, true); + + print_r($json["_items"][0]["id"]); + + $url = 'https://www.osrsbox.com/osrsbox-db/items-icons/' . (int)$json["_items"][0]["id"] . '.png'; // 4151 + + $dir = public_path() . '/images/npc/' . lcfirst(Str::snake(Str::singular($this->argument('npc')))) . '/'; // /images/npc/abyssal_demon/ + $imgName = lcfirst(str_replace(" ", "_", Str::snake($unique))) . '.png'; // abyssal_whip.png + + if (!File::exists($dir)) { + File::makeDirectory($dir, 0777, true); + } + + $img = $dir . $imgName; + + file_put_contents($img, file_get_contents($url)); + + // If first iteration, make an icon for boss. This will be the first item in uniques + if ($i === 0) { + File::copy($img, public_path() . '/images/npc/' . lcfirst(Str::snake(Str::singular($this->argument('npc')))) . '.png'); + } + + $i++; + } + } } } From 24e031268409bc6f81d398ceff8d1417ed45cdda Mon Sep 17 00:00:00 2001 From: Zlimon Date: Tue, 12 Jan 2021 23:31:11 +0100 Subject: [PATCH 23/92] Fill fillables on collection creation --- app/Http/Controllers/Api/AccountLootController.php | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/app/Http/Controllers/Api/AccountLootController.php b/app/Http/Controllers/Api/AccountLootController.php index 8bdad770..95a06764 100644 --- a/app/Http/Controllers/Api/AccountLootController.php +++ b/app/Http/Controllers/Api/AccountLootController.php @@ -28,6 +28,12 @@ public function update($accountUsername, $collectionName, Request $request) if (is_null($collectionLog)) { $collectionLog = new $collection->model; + $collectionLog->getAttributes(); + + foreach ($collectionLog->getFillable() as $fillable) { + $collectionLog->$fillable = 0; + } + $collectionLog->account_id = $account->id; $collectionLog->save(); @@ -49,9 +55,9 @@ public function update($accountUsername, $collectionName, Request $request) $sums = []; - $sums["kill_count"] = $oldValues["kill_count"] + 1; + @$sums["kill_count"] = $oldValues["kill_count"] + 1; - $uniques = $oldValues["obtained"]; + $uniques = @$oldValues["obtained"] ?: 0; // Merge old data and new data and sum the total of common keys foreach (array_keys($newValues + $oldValues) as $lootType) { From 0e24cd47387c56ce4c1fcc1b7f67d17b87c5b5de Mon Sep 17 00:00:00 2001 From: Zlimon Date: Tue, 12 Jan 2021 23:41:24 +0100 Subject: [PATCH 24/92] Missing user icon added back --- resources/js/components/AccountBossHiscore.vue | 2 +- resources/js/components/AccountSkillHiscore.vue | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/resources/js/components/AccountBossHiscore.vue b/resources/js/components/AccountBossHiscore.vue index e76098a6..ba837335 100644 --- a/resources/js/components/AccountBossHiscore.vue +++ b/resources/js/components/AccountBossHiscore.vue @@ -18,7 +18,7 @@
- Profile icon diff --git a/resources/js/components/AccountSkillHiscore.vue b/resources/js/components/AccountSkillHiscore.vue index 5acaba7f..955160a2 100644 --- a/resources/js/components/AccountSkillHiscore.vue +++ b/resources/js/components/AccountSkillHiscore.vue @@ -18,7 +18,7 @@
- Profile icon From e1b10eb85540fb8c273786cd41164c7b275a9327 Mon Sep 17 00:00:00 2001 From: Zlimon Date: Tue, 12 Jan 2021 23:47:35 +0100 Subject: [PATCH 25/92] Hiscore button hover texture --- public/css/hiscore.css | 20 +++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) diff --git a/public/css/hiscore.css b/public/css/hiscore.css index cf44d536..099ac323 100644 --- a/public/css/hiscore.css +++ b/public/css/hiscore.css @@ -26,7 +26,25 @@ #highscore_top .highscore_selection a.active, #highscore_top .highscore_selection a:hover { - background: #2d2d2b; + color: #cbcbcb; + background: url('/resource-packs/pack-osrs-dark/button/world_map_metal_corner_top_left.png') no-repeat, /* top left */ + url('/resource-packs/pack-osrs-dark/button/world_map_metal_corner_top_right.png') no-repeat, /* top right */ + url('/resource-packs/pack-osrs-dark/button/world_map_metal_corner_bottom_left.png') no-repeat, /* bottom left */ + url('/resource-packs/pack-osrs-dark/button/world_map_metal_corner_bottom_right.png') no-repeat, /* bottom right */ + url('/resource-packs/pack-osrs-dark/button/world_map_edge_top.png') repeat-x, /* top */ + url('/resource-packs/pack-osrs-dark/button/world_map_edge_left.png') repeat-y, /* left */ + url('/resource-packs/pack-osrs-dark/button/world_map_edge_right.png') repeat-y, /* right */ + url('/resource-packs/pack-osrs-dark/button/world_map_edge_bottom.png') repeat-x, /* bottom */ + url('/resource-packs/pack-osrs-dark/dialog/background.png'); /* body */ + background-position: top left, + top right, + bottom left, + bottom right, + top 0 left, + left 0 top 10px, + right, + bottom, + center; } a.selection-top, From d28b419f79c1c31047926bb8a1630a109eb377e3 Mon Sep 17 00:00:00 2001 From: Zlimon Date: Wed, 13 Jan 2021 00:10:56 +0100 Subject: [PATCH 26/92] Soul Wars hiscore entry fix for user seeder --- database/seeds/UserSeeder.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/database/seeds/UserSeeder.php b/database/seeds/UserSeeder.php index 17e8c188..923e4bca 100644 --- a/database/seeds/UserSeeder.php +++ b/database/seeds/UserSeeder.php @@ -118,7 +118,7 @@ public function run() $dksKillCount = 0; - for ($i = (count($skills) + $clueScrollAmount + 4); $i < (count($skills) + $clueScrollAmount + 4 + count($bosses)); $i++) { + for ($i = (count($skills) + $clueScrollAmount + 5); $i < (count($skills) + $clueScrollAmount + 5 + count($bosses)); $i++) { $collection = Collection::where('name', $bosses[$bossIndex])->firstOrFail(); $collectionLoot = new $collection->model; From 0155e4428762b68c51a170397dcd8115900aa6aa Mon Sep 17 00:00:00 2001 From: Zlimon Date: Thu, 14 Jan 2021 15:54:45 +0100 Subject: [PATCH 27/92] Create collection entry if null (account updater) --- app/Console/Commands/AccountUpdate.php | 38 +++++++++++++++++++++----- 1 file changed, 31 insertions(+), 7 deletions(-) diff --git a/app/Console/Commands/AccountUpdate.php b/app/Console/Commands/AccountUpdate.php index 020000d4..6c111fd0 100644 --- a/app/Console/Commands/AccountUpdate.php +++ b/app/Console/Commands/AccountUpdate.php @@ -88,17 +88,32 @@ public function handle() $collectionLoot = $collection->model::where('account_id', $account->id)->firstOrFail(); - $collectionLoot->account_id = $account->id; - $collectionLoot->kill_count = ($playerData[$i + 1][1] >= 0 ? $playerData[$i + 1][1] : 0); - $collectionLoot->rank = ($playerData[$i + 1][0] >= 0 ? $playerData[$i + 1][0] : 0); + // If account has no collection entry, create it + if (is_null($collectionLoot)) { + $collectionLoot = new $collection->model; + + $collectionLoot->getAttributes(); + + foreach ($collectionLoot->getFillable() as $fillable) { + $collectionLoot->$fillable = 0; + } + + $collectionLoot->account_id = $account->id; + + $collectionLoot->save(); + } else { + $collectionLoot->account_id = $account->id; + $collectionLoot->kill_count = ($playerData[$i + 1][1] >= 0 ? $playerData[$i + 1][1] : 0); + $collectionLoot->rank = ($playerData[$i + 1][0] >= 0 ? $playerData[$i + 1][0] : 0); + + $collectionLoot->update(); + } if (in_array($bosses[$bossIndex], ['dagannoth prime', 'dagannoth rex', 'dagannoth supreme'], true)) { $dksKillCount += ($playerData[$i + 1][1] >= 0 ? $playerData[$i + 1][1] : 0); } - $collectionLoot->update(); - $bossIndex++; } @@ -111,9 +126,18 @@ public function handle() */ $dks = \App\Boss\DagannothKings::where('account_id', $account->id)->firstOrFail(); - $dks->kill_count = $dksKillCount; + if (is_null($dks)) { + $dks = new \App\Boss\DagannothKings; + + $dks->account_id = $account->id; + $dks->kill_count = $dksKillCount; - $dks->update(); + $dks->save(); + } else { + $dks->kill_count = $dksKillCount; + + $dks->update(); + } $this->info(sprintf("Updated %s!", $account->username)); } else { From 5c3fdb2e41afce1938e944377bfabece03f2348f Mon Sep 17 00:00:00 2001 From: Zlimon Date: Thu, 14 Jan 2021 16:05:46 +0100 Subject: [PATCH 28/92] firstOrFail -> first --- app/Console/Commands/AccountUpdate.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/Console/Commands/AccountUpdate.php b/app/Console/Commands/AccountUpdate.php index 6c111fd0..9bd8dcae 100644 --- a/app/Console/Commands/AccountUpdate.php +++ b/app/Console/Commands/AccountUpdate.php @@ -86,7 +86,7 @@ public function handle() for ($i = (count($skills) + $clueScrollAmount + 5); $i < (count($skills) + $clueScrollAmount + 5 + count($bosses)); $i++) { $collection = Collection::where('name', $bosses[$bossIndex])->firstOrFail(); - $collectionLoot = $collection->model::where('account_id', $account->id)->firstOrFail(); + $collectionLoot = $collection->model::where('account_id', $account->id)->first(); // If account has no collection entry, create it if (is_null($collectionLoot)) { @@ -124,7 +124,7 @@ public function handle() * This might also happen with other bosses in the future * that share collection log entry, but have separate hiscores. */ - $dks = \App\Boss\DagannothKings::where('account_id', $account->id)->firstOrFail(); + $dks = \App\Boss\DagannothKings::where('account_id', $account->id)->first(); if (is_null($dks)) { $dks = new \App\Boss\DagannothKings; From f95c7ea542fe1b9d76edfecbb429a3d1edfef8ca Mon Sep 17 00:00:00 2001 From: Zlimon Date: Thu, 14 Jan 2021 16:18:27 +0100 Subject: [PATCH 29/92] Scythe of vitur typo fix --- app/Raid/TheatreOfBlood.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/Raid/TheatreOfBlood.php b/app/Raid/TheatreOfBlood.php index d5de442d..e14e35b4 100644 --- a/app/Raid/TheatreOfBlood.php +++ b/app/Raid/TheatreOfBlood.php @@ -63,7 +63,7 @@ class TheatreOfBlood extends Model 'obtained', 'kill_count', 'lil_zik', - 'scythhe_of_vitour_(uncharged)', + 'scythe_of_vitur_(uncharged)', 'ghrazi_rapier', 'sanguinesti_staff_(uncharged)', 'justiciar_faceguard', From b00a7609bfacd218b477c5afad00c50b6cac4f5e Mon Sep 17 00:00:00 2001 From: Zlimon Date: Thu, 14 Jan 2021 17:41:56 +0100 Subject: [PATCH 30/92] Upgrade to Laravel 8 --- composer.json | 20 +- composer.lock | 2084 +++++++++++++++++++++++++++---------------------- 2 files changed, 1177 insertions(+), 927 deletions(-) diff --git a/composer.json b/composer.json index 4a6307c8..ca35eebb 100644 --- a/composer.json +++ b/composer.json @@ -8,27 +8,27 @@ ], "license": "MIT", "require": { - "php": "^7.2.5", + "php": "^7.3.26", + "ext-curl": "*", "beyondcode/laravel-websockets": "^1.9", "fideloper/proxy": "^4.2", "fruitcake/laravel-cors": "^2.0", - "guzzlehttp/guzzle": "^6.3", - "laravel/framework": "^7.0", - "laravel/passport": "^9.3", + "guzzlehttp/guzzle": "^7.0.1", + "laravel/framework": "^8.0", + "laravel/passport": "^10.0", "laravel/tinker": "^2.0", - "laravel/ui": "^2.1", - "pusher/pusher-php-server": "^4.1", - "ext-curl": "*" + "laravel/ui": "^3.0", + "pusher/pusher-php-server": "^4.1" }, "require-dev": { "barryvdh/laravel-ide-helper": "^2.8", - "facade/ignition": "^2.0", + "facade/ignition": "^2.3.6", "fzaninotto/faker": "^1.9.1", "laracasts/generators": "^2.0", "laravel/homestead": "^11.0", "mockery/mockery": "^1.3.1", - "nunomaduro/collision": "^4.1", - "phpunit/phpunit": "^8.5" + "nunomaduro/collision": "^5.0", + "phpunit/phpunit": "^9.0" }, "config": { "optimize-autoloader": true, diff --git a/composer.lock b/composer.lock index 833fe5f1..22ae7181 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "0acd475adeb3256c06d6d939213d4d01", + "content-hash": "0293bb4912327bf9eff07d74c2345747", "packages": [ { "name": "asm89/stack-cors", @@ -476,30 +476,32 @@ }, { "name": "dragonmantank/cron-expression", - "version": "v2.3.1", + "version": "v3.1.0", "source": { "type": "git", "url": "https://github.com/dragonmantank/cron-expression.git", - "reference": "65b2d8ee1f10915efb3b55597da3404f096acba2" + "reference": "7a8c6e56ab3ffcc538d05e8155bb42269abf1a0c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/dragonmantank/cron-expression/zipball/65b2d8ee1f10915efb3b55597da3404f096acba2", - "reference": "65b2d8ee1f10915efb3b55597da3404f096acba2", + "url": "https://api.github.com/repos/dragonmantank/cron-expression/zipball/7a8c6e56ab3ffcc538d05e8155bb42269abf1a0c", + "reference": "7a8c6e56ab3ffcc538d05e8155bb42269abf1a0c", "shasum": "" }, "require": { - "php": "^7.0|^8.0" + "php": "^7.2|^8.0", + "webmozart/assert": "^1.7.0" + }, + "replace": { + "mtdowling/cron-expression": "^1.0" }, "require-dev": { - "phpunit/phpunit": "^6.4|^7.0|^8.0|^9.0" + "phpstan/extension-installer": "^1.0", + "phpstan/phpstan": "^0.12", + "phpstan/phpstan-webmozart-assert": "^0.12.7", + "phpunit/phpunit": "^7.0|^8.0|^9.0" }, "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.3-dev" - } - }, "autoload": { "psr-4": { "Cron\\": "src/Cron/" @@ -510,11 +512,6 @@ "MIT" ], "authors": [ - { - "name": "Michael Dowling", - "email": "mtdowling@gmail.com", - "homepage": "https://github.com/mtdowling" - }, { "name": "Chris Tankersley", "email": "chris@ctankersley.com", @@ -526,20 +523,20 @@ "cron", "schedule" ], - "time": "2020-10-13T00:52:37+00:00" + "time": "2020-11-24T19:55:57+00:00" }, { "name": "egulias/email-validator", - "version": "2.1.23", + "version": "2.1.25", "source": { "type": "git", "url": "https://github.com/egulias/EmailValidator.git", - "reference": "5fa792ad1853ae2bc60528dd3e5cbf4542d3c1df" + "reference": "0dbf5d78455d4d6a41d186da50adc1122ec066f4" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/egulias/EmailValidator/zipball/5fa792ad1853ae2bc60528dd3e5cbf4542d3c1df", - "reference": "5fa792ad1853ae2bc60528dd3e5cbf4542d3c1df", + "url": "https://api.github.com/repos/egulias/EmailValidator/zipball/0dbf5d78455d4d6a41d186da50adc1122ec066f4", + "reference": "0dbf5d78455d4d6a41d186da50adc1122ec066f4", "shasum": "" }, "require": { @@ -584,7 +581,7 @@ "validation", "validator" ], - "time": "2020-10-31T20:37:35+00:00" + "time": "2020-12-29T14:50:06+00:00" }, { "name": "evenement/evenement", @@ -631,25 +628,25 @@ }, { "name": "facade/ignition-contracts", - "version": "1.0.1", + "version": "1.0.2", "source": { "type": "git", "url": "https://github.com/facade/ignition-contracts.git", - "reference": "aeab1ce8b68b188a43e81758e750151ad7da796b" + "reference": "3c921a1cdba35b68a7f0ccffc6dffc1995b18267" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/facade/ignition-contracts/zipball/aeab1ce8b68b188a43e81758e750151ad7da796b", - "reference": "aeab1ce8b68b188a43e81758e750151ad7da796b", + "url": "https://api.github.com/repos/facade/ignition-contracts/zipball/3c921a1cdba35b68a7f0ccffc6dffc1995b18267", + "reference": "3c921a1cdba35b68a7f0ccffc6dffc1995b18267", "shasum": "" }, "require": { - "php": "^7.1" + "php": "^7.3|^8.0" }, "require-dev": { - "friendsofphp/php-cs-fixer": "^2.14", - "phpunit/phpunit": "^7.5|^8.0", - "vimeo/psalm": "^3.12" + "friendsofphp/php-cs-fixer": "^v2.15.8", + "phpunit/phpunit": "^9.3.11", + "vimeo/psalm": "^3.17.1" }, "type": "library", "autoload": { @@ -676,7 +673,7 @@ "flare", "ignition" ], - "time": "2020-07-14T10:10:28+00:00" + "time": "2020-10-16T08:27:54+00:00" }, { "name": "fideloper/proxy", @@ -849,39 +846,97 @@ ], "time": "2020-10-22T13:57:20+00:00" }, + { + "name": "graham-campbell/result-type", + "version": "v1.0.1", + "source": { + "type": "git", + "url": "https://github.com/GrahamCampbell/Result-Type.git", + "reference": "7e279d2cd5d7fbb156ce46daada972355cea27bb" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/GrahamCampbell/Result-Type/zipball/7e279d2cd5d7fbb156ce46daada972355cea27bb", + "reference": "7e279d2cd5d7fbb156ce46daada972355cea27bb", + "shasum": "" + }, + "require": { + "php": "^7.0|^8.0", + "phpoption/phpoption": "^1.7.3" + }, + "require-dev": { + "phpunit/phpunit": "^6.5|^7.5|^8.5|^9.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0-dev" + } + }, + "autoload": { + "psr-4": { + "GrahamCampbell\\ResultType\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Graham Campbell", + "email": "graham@alt-three.com" + } + ], + "description": "An Implementation Of The Result Type", + "keywords": [ + "Graham Campbell", + "GrahamCampbell", + "Result Type", + "Result-Type", + "result" + ], + "time": "2020-04-13T13:17:36+00:00" + }, { "name": "guzzlehttp/guzzle", - "version": "6.5.5", + "version": "7.2.0", "source": { "type": "git", "url": "https://github.com/guzzle/guzzle.git", - "reference": "9d4290de1cfd701f38099ef7e183b64b4b7b0c5e" + "reference": "0aa74dfb41ae110835923ef10a9d803a22d50e79" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/guzzle/guzzle/zipball/9d4290de1cfd701f38099ef7e183b64b4b7b0c5e", - "reference": "9d4290de1cfd701f38099ef7e183b64b4b7b0c5e", + "url": "https://api.github.com/repos/guzzle/guzzle/zipball/0aa74dfb41ae110835923ef10a9d803a22d50e79", + "reference": "0aa74dfb41ae110835923ef10a9d803a22d50e79", "shasum": "" }, "require": { "ext-json": "*", - "guzzlehttp/promises": "^1.0", - "guzzlehttp/psr7": "^1.6.1", - "php": ">=5.5", - "symfony/polyfill-intl-idn": "^1.17.0" + "guzzlehttp/promises": "^1.4", + "guzzlehttp/psr7": "^1.7", + "php": "^7.2.5 || ^8.0", + "psr/http-client": "^1.0" + }, + "provide": { + "psr/http-client-implementation": "1.0" }, "require-dev": { "ext-curl": "*", - "phpunit/phpunit": "^4.8.35 || ^5.7 || ^6.4 || ^7.0", + "php-http/client-integration-tests": "^3.0", + "phpunit/phpunit": "^8.5.5 || ^9.3.5", "psr/log": "^1.1" }, "suggest": { + "ext-curl": "Required for CURL handler support", + "ext-intl": "Required for Internationalized Domain Name (IDN) support", "psr/log": "Required for using the Log middleware" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "6.5-dev" + "dev-master": "7.1-dev" } }, "autoload": { @@ -901,6 +956,11 @@ "name": "Michael Dowling", "email": "mtdowling@gmail.com", "homepage": "https://github.com/mtdowling" + }, + { + "name": "Márk Sági-Kazár", + "email": "mark.sagikazar@gmail.com", + "homepage": "https://sagikazarmark.hu" } ], "description": "Guzzle is a PHP HTTP client library", @@ -911,10 +971,12 @@ "framework", "http", "http client", + "psr-18", + "psr-7", "rest", "web service" ], - "time": "2020-06-16T21:01:06+00:00" + "time": "2020-10-10T11:47:56+00:00" }, { "name": "guzzlehttp/promises", @@ -1038,156 +1100,23 @@ ], "time": "2020-09-30T07:37:11+00:00" }, - { - "name": "laminas/laminas-diactoros", - "version": "2.4.1", - "source": { - "type": "git", - "url": "https://github.com/laminas/laminas-diactoros.git", - "reference": "36ef09b73e884135d2059cc498c938e90821bb57" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-diactoros/zipball/36ef09b73e884135d2059cc498c938e90821bb57", - "reference": "36ef09b73e884135d2059cc498c938e90821bb57", - "shasum": "" - }, - "require": { - "laminas/laminas-zendframework-bridge": "^1.0", - "php": "^7.1", - "psr/http-factory": "^1.0", - "psr/http-message": "^1.0" - }, - "conflict": { - "phpspec/prophecy": "<1.9.0" - }, - "provide": { - "psr/http-factory-implementation": "1.0", - "psr/http-message-implementation": "1.0" - }, - "replace": { - "zendframework/zend-diactoros": "^2.2.1" - }, - "require-dev": { - "ext-curl": "*", - "ext-dom": "*", - "ext-gd": "*", - "ext-libxml": "*", - "http-interop/http-factory-tests": "^0.5.0", - "laminas/laminas-coding-standard": "~1.0.0", - "php-http/psr7-integration-tests": "^1.0", - "phpunit/phpunit": "^7.5.18" - }, - "type": "library", - "extra": { - "laminas": { - "config-provider": "Laminas\\Diactoros\\ConfigProvider", - "module": "Laminas\\Diactoros" - } - }, - "autoload": { - "files": [ - "src/functions/create_uploaded_file.php", - "src/functions/marshal_headers_from_sapi.php", - "src/functions/marshal_method_from_sapi.php", - "src/functions/marshal_protocol_version_from_sapi.php", - "src/functions/marshal_uri_from_sapi.php", - "src/functions/normalize_server.php", - "src/functions/normalize_uploaded_files.php", - "src/functions/parse_cookie_header.php", - "src/functions/create_uploaded_file.legacy.php", - "src/functions/marshal_headers_from_sapi.legacy.php", - "src/functions/marshal_method_from_sapi.legacy.php", - "src/functions/marshal_protocol_version_from_sapi.legacy.php", - "src/functions/marshal_uri_from_sapi.legacy.php", - "src/functions/normalize_server.legacy.php", - "src/functions/normalize_uploaded_files.legacy.php", - "src/functions/parse_cookie_header.legacy.php" - ], - "psr-4": { - "Laminas\\Diactoros\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "description": "PSR HTTP Message implementations", - "homepage": "https://laminas.dev", - "keywords": [ - "http", - "laminas", - "psr", - "psr-17", - "psr-7" - ], - "time": "2020-09-03T14:29:41+00:00" - }, - { - "name": "laminas/laminas-zendframework-bridge", - "version": "1.1.1", - "source": { - "type": "git", - "url": "https://github.com/laminas/laminas-zendframework-bridge.git", - "reference": "6ede70583e101030bcace4dcddd648f760ddf642" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-zendframework-bridge/zipball/6ede70583e101030bcace4dcddd648f760ddf642", - "reference": "6ede70583e101030bcace4dcddd648f760ddf642", - "shasum": "" - }, - "require": { - "php": "^5.6 || ^7.0 || ^8.0" - }, - "require-dev": { - "phpunit/phpunit": "^5.7 || ^6.5 || ^7.5 || ^8.1 || ^9.3", - "squizlabs/php_codesniffer": "^3.5" - }, - "type": "library", - "extra": { - "laminas": { - "module": "Laminas\\ZendFrameworkBridge" - } - }, - "autoload": { - "files": [ - "src/autoload.php" - ], - "psr-4": { - "Laminas\\ZendFrameworkBridge\\": "src//" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "description": "Alias legacy ZF class names to Laminas Project equivalents.", - "keywords": [ - "ZendFramework", - "autoloading", - "laminas", - "zf" - ], - "time": "2020-09-14T14:23:00+00:00" - }, { "name": "laravel/framework", - "version": "v7.29.3", + "version": "v8.22.1", "source": { "type": "git", "url": "https://github.com/laravel/framework.git", - "reference": "93f6d565a07045baa0e4b941ae1f733cd5984d65" + "reference": "5c70991b96c5722afed541a996479b5112654c8b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laravel/framework/zipball/93f6d565a07045baa0e4b941ae1f733cd5984d65", - "reference": "93f6d565a07045baa0e4b941ae1f733cd5984d65", + "url": "https://api.github.com/repos/laravel/framework/zipball/5c70991b96c5722afed541a996479b5112654c8b", + "reference": "5c70991b96c5722afed541a996479b5112654c8b", "shasum": "" }, "require": { "doctrine/inflector": "^1.4|^2.0", - "dragonmantank/cron-expression": "^2.3.1", + "dragonmantank/cron-expression": "^3.0.2", "egulias/email-validator": "^2.1.10", "ext-json": "*", "ext-mbstring": "*", @@ -1197,23 +1126,22 @@ "monolog/monolog": "^2.0", "nesbot/carbon": "^2.31", "opis/closure": "^3.6", - "php": "^7.2.5|^8.0", + "php": "^7.3|^8.0", "psr/container": "^1.0", "psr/simple-cache": "^1.0", - "ramsey/uuid": "^3.7|^4.0", + "ramsey/uuid": "^4.0", "swiftmailer/swiftmailer": "^6.0", - "symfony/console": "^5.0", - "symfony/error-handler": "^5.0", - "symfony/finder": "^5.0", - "symfony/http-foundation": "^5.0", - "symfony/http-kernel": "^5.0", - "symfony/mime": "^5.0", - "symfony/polyfill-php73": "^1.17", - "symfony/process": "^5.0", - "symfony/routing": "^5.0", - "symfony/var-dumper": "^5.0", + "symfony/console": "^5.1.4", + "symfony/error-handler": "^5.1.4", + "symfony/finder": "^5.1.4", + "symfony/http-foundation": "^5.1.4", + "symfony/http-kernel": "^5.1.4", + "symfony/mime": "^5.1.4", + "symfony/process": "^5.1.4", + "symfony/routing": "^5.1.4", + "symfony/var-dumper": "^5.1.4", "tijsverkoyen/css-to-inline-styles": "^2.2.2", - "vlucas/phpdotenv": "^4.0", + "vlucas/phpdotenv": "^5.2", "voku/portable-ascii": "^1.4.8" }, "conflict": { @@ -1227,6 +1155,7 @@ "illuminate/broadcasting": "self.version", "illuminate/bus": "self.version", "illuminate/cache": "self.version", + "illuminate/collections": "self.version", "illuminate/config": "self.version", "illuminate/console": "self.version", "illuminate/container": "self.version", @@ -1239,6 +1168,7 @@ "illuminate/hashing": "self.version", "illuminate/http": "self.version", "illuminate/log": "self.version", + "illuminate/macroable": "self.version", "illuminate/mail": "self.version", "illuminate/notifications": "self.version", "illuminate/pagination": "self.version", @@ -1254,22 +1184,21 @@ "illuminate/view": "self.version" }, "require-dev": { - "aws/aws-sdk-php": "^3.0", - "doctrine/dbal": "^2.6", + "aws/aws-sdk-php": "^3.155", + "doctrine/dbal": "^2.6|^3.0", "filp/whoops": "^2.8", - "guzzlehttp/guzzle": "^6.3.1|^7.0.1", + "guzzlehttp/guzzle": "^6.5.5|^7.0.1", "league/flysystem-cached-adapter": "^1.0", - "mockery/mockery": "~1.3.3|^1.4.2", - "moontoast/math": "^1.1", - "orchestra/testbench-core": "^5.8", + "mockery/mockery": "^1.4.2", + "orchestra/testbench-core": "^6.8", "pda/pheanstalk": "^4.0", - "phpunit/phpunit": "^8.4|^9.3.3", + "phpunit/phpunit": "^8.5.8|^9.3.3", "predis/predis": "^1.1.1", - "symfony/cache": "^5.0" + "symfony/cache": "^5.1.4" }, "suggest": { - "aws/aws-sdk-php": "Required to use the SQS queue driver, DynamoDb failed job storage and SES mail driver (^3.0).", - "doctrine/dbal": "Required to rename columns and drop SQLite columns (^2.6).", + "aws/aws-sdk-php": "Required to use the SQS queue driver, DynamoDb failed job storage and SES mail driver (^3.155).", + "doctrine/dbal": "Required to rename columns and drop SQLite columns (^2.6|^3.0).", "ext-ftp": "Required to use the Flysystem FTP driver.", "ext-gd": "Required to use Illuminate\\Http\\Testing\\FileFactory::image().", "ext-memcached": "Required to use the memcache cache driver.", @@ -1278,37 +1207,42 @@ "ext-redis": "Required to use the Redis cache and queue drivers (^4.0|^5.0).", "fakerphp/faker": "Required to use the eloquent factory builder (^1.9.1).", "filp/whoops": "Required for friendly error pages in development (^2.8).", - "guzzlehttp/guzzle": "Required to use the HTTP Client, Mailgun mail driver and the ping methods on schedules (^6.3.1|^7.0.1).", + "guzzlehttp/guzzle": "Required to use the HTTP Client, Mailgun mail driver and the ping methods on schedules (^6.5.5|^7.0.1).", "laravel/tinker": "Required to use the tinker console command (^2.0).", "league/flysystem-aws-s3-v3": "Required to use the Flysystem S3 driver (^1.0).", "league/flysystem-cached-adapter": "Required to use the Flysystem cache (^1.0).", "league/flysystem-sftp": "Required to use the Flysystem SFTP driver (^1.0).", - "mockery/mockery": "Required to use mocking (~1.3.3|^1.4.2).", - "moontoast/math": "Required to use ordered UUIDs (^1.1).", + "mockery/mockery": "Required to use mocking (^1.4.2).", "nyholm/psr7": "Required to use PSR-7 bridging features (^1.2).", "pda/pheanstalk": "Required to use the beanstalk queue driver (^4.0).", - "phpunit/phpunit": "Required to use assertions and run tests (^8.4|^9.3.3).", + "phpunit/phpunit": "Required to use assertions and run tests (^8.5.8|^9.3.3).", "predis/predis": "Required to use the predis connector (^1.1.2).", "psr/http-message": "Required to allow Storage::put to accept a StreamInterface (^1.0).", "pusher/pusher-php-server": "Required to use the Pusher broadcast driver (^4.0).", - "symfony/cache": "Required to PSR-6 cache bridge (^5.0).", - "symfony/filesystem": "Required to create relative storage directory symbolic links (^5.0).", + "symfony/cache": "Required to PSR-6 cache bridge (^5.1.4).", + "symfony/filesystem": "Required to enable support for relative symbolic links (^5.1.4).", "symfony/psr-http-message-bridge": "Required to use PSR-7 bridging features (^2.0).", "wildbit/swiftmailer-postmark": "Required to use Postmark mail driver (^3.0)." }, "type": "library", "extra": { "branch-alias": { - "dev-master": "7.x-dev" + "dev-master": "8.x-dev" } }, "autoload": { "files": [ + "src/Illuminate/Collections/helpers.php", + "src/Illuminate/Events/functions.php", "src/Illuminate/Foundation/helpers.php", "src/Illuminate/Support/helpers.php" ], "psr-4": { - "Illuminate\\": "src/Illuminate/" + "Illuminate\\": "src/Illuminate/", + "Illuminate\\Support\\": [ + "src/Illuminate/Macroable/", + "src/Illuminate/Collections/" + ] } }, "notification-url": "https://packagist.org/downloads/", @@ -1327,51 +1261,50 @@ "framework", "laravel" ], - "time": "2020-11-03T14:12:58+00:00" + "time": "2021-01-13T13:37:56+00:00" }, { "name": "laravel/passport", - "version": "v9.3.2", + "version": "v10.1.0", "source": { "type": "git", "url": "https://github.com/laravel/passport.git", - "reference": "192fe387c1c173c12f82784e2a1b51be8bd1bf45" + "reference": "c2b93a7d8d93cf303bb1eefbfa5610f084f9bdd4" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laravel/passport/zipball/192fe387c1c173c12f82784e2a1b51be8bd1bf45", - "reference": "192fe387c1c173c12f82784e2a1b51be8bd1bf45", + "url": "https://api.github.com/repos/laravel/passport/zipball/c2b93a7d8d93cf303bb1eefbfa5610f084f9bdd4", + "reference": "c2b93a7d8d93cf303bb1eefbfa5610f084f9bdd4", "shasum": "" }, "require": { "ext-json": "*", "firebase/php-jwt": "^5.0", - "guzzlehttp/guzzle": "^6.0|^7.0", - "illuminate/auth": "^6.18.31|^7.22.4", - "illuminate/console": "^6.18.31|^7.22.4", - "illuminate/container": "^6.18.31|^7.22.4", - "illuminate/contracts": "^6.18.31|^7.22.4", - "illuminate/cookie": "^6.18.31|^7.22.4", - "illuminate/database": "^6.18.31|^7.22.4", - "illuminate/encryption": "^6.18.31|^7.22.4", - "illuminate/http": "^6.18.31|^7.22.4", - "illuminate/support": "^6.18.31|^7.22.4", - "laminas/laminas-diactoros": "^2.2", - "league/oauth2-server": "^8.1", - "nyholm/psr7": "^1.0", - "php": "^7.2", + "illuminate/auth": "^8.2", + "illuminate/console": "^8.2", + "illuminate/container": "^8.2", + "illuminate/contracts": "^8.2", + "illuminate/cookie": "^8.2", + "illuminate/database": "^8.2", + "illuminate/encryption": "^8.2", + "illuminate/http": "^8.2", + "illuminate/support": "^8.2", + "lcobucci/jwt": "^3.4|^4.0", + "league/oauth2-server": "^8.2", + "nyholm/psr7": "^1.3", + "php": "^7.3|^8.0", "phpseclib/phpseclib": "^2.0", "symfony/psr-http-message-bridge": "^2.0" }, "require-dev": { "mockery/mockery": "^1.0", - "orchestra/testbench": "^4.4|^5.0", - "phpunit/phpunit": "^8.0" + "orchestra/testbench": "^6.0", + "phpunit/phpunit": "^9.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "9.x-dev" + "dev-master": "10.x-dev" }, "laravel": { "providers": [ @@ -1381,7 +1314,8 @@ }, "autoload": { "psr-4": { - "Laravel\\Passport\\": "src/" + "Laravel\\Passport\\": "src/", + "Laravel\\Passport\\Database\\Factories\\": "database/factories/" } }, "notification-url": "https://packagist.org/downloads/", @@ -1400,7 +1334,7 @@ "oauth", "passport" ], - "time": "2020-07-27T18:34:39+00:00" + "time": "2020-11-26T07:57:30+00:00" }, { "name": "laravel/tinker", @@ -1468,26 +1402,29 @@ }, { "name": "laravel/ui", - "version": "v2.5.0", + "version": "v3.2.0", "source": { "type": "git", "url": "https://github.com/laravel/ui.git", - "reference": "d01a705763c243b07be795e9d1bb47f89260f73d" + "reference": "a1f82c6283c8373ea1958b8a27c3d5c98cade351" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laravel/ui/zipball/d01a705763c243b07be795e9d1bb47f89260f73d", - "reference": "d01a705763c243b07be795e9d1bb47f89260f73d", + "url": "https://api.github.com/repos/laravel/ui/zipball/a1f82c6283c8373ea1958b8a27c3d5c98cade351", + "reference": "a1f82c6283c8373ea1958b8a27c3d5c98cade351", "shasum": "" }, "require": { - "illuminate/console": "^7.0", - "illuminate/filesystem": "^7.0", - "illuminate/support": "^7.0", - "php": "^7.2.5|^8.0" + "illuminate/console": "^8.0", + "illuminate/filesystem": "^8.0", + "illuminate/support": "^8.0", + "php": "^7.3|^8.0" }, "type": "library", "extra": { + "branch-alias": { + "dev-master": "3.x-dev" + }, "laravel": { "providers": [ "Laravel\\Ui\\UiServiceProvider" @@ -1515,38 +1452,92 @@ "laravel", "ui" ], - "time": "2020-11-03T19:45:19+00:00" + "time": "2021-01-06T19:20:22+00:00" + }, + { + "name": "lcobucci/clock", + "version": "2.0.0", + "source": { + "type": "git", + "url": "https://github.com/lcobucci/clock.git", + "reference": "353d83fe2e6ae95745b16b3d911813df6a05bfb3" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/lcobucci/clock/zipball/353d83fe2e6ae95745b16b3d911813df6a05bfb3", + "reference": "353d83fe2e6ae95745b16b3d911813df6a05bfb3", + "shasum": "" + }, + "require": { + "php": "^7.4 || ^8.0" + }, + "require-dev": { + "infection/infection": "^0.17", + "lcobucci/coding-standard": "^6.0", + "phpstan/extension-installer": "^1.0", + "phpstan/phpstan": "^0.12", + "phpstan/phpstan-deprecation-rules": "^0.12", + "phpstan/phpstan-phpunit": "^0.12", + "phpstan/phpstan-strict-rules": "^0.12", + "phpunit/php-code-coverage": "9.1.4", + "phpunit/phpunit": "9.3.7" + }, + "type": "library", + "autoload": { + "psr-4": { + "Lcobucci\\Clock\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Luís Cobucci", + "email": "lcobucci@gmail.com" + } + ], + "description": "Yet another clock abstraction", + "time": "2020-08-27T18:56:02+00:00" }, { "name": "lcobucci/jwt", - "version": "3.3.3", + "version": "4.0.0", "source": { "type": "git", "url": "https://github.com/lcobucci/jwt.git", - "reference": "c1123697f6a2ec29162b82f170dd4a491f524773" + "reference": "6d8665ccd924dc076a9b65d1ea8abe21d68f6958" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/lcobucci/jwt/zipball/c1123697f6a2ec29162b82f170dd4a491f524773", - "reference": "c1123697f6a2ec29162b82f170dd4a491f524773", + "url": "https://api.github.com/repos/lcobucci/jwt/zipball/6d8665ccd924dc076a9b65d1ea8abe21d68f6958", + "reference": "6d8665ccd924dc076a9b65d1ea8abe21d68f6958", "shasum": "" }, "require": { "ext-mbstring": "*", "ext-openssl": "*", - "php": "^5.6 || ^7.0" + "lcobucci/clock": "^2.0", + "php": "^7.4 || ^8.0" }, "require-dev": { - "mikey179/vfsstream": "~1.5", - "phpmd/phpmd": "~2.2", - "phpunit/php-invoker": "~1.1", - "phpunit/phpunit": "^5.7 || ^7.3", - "squizlabs/php_codesniffer": "~2.3" + "infection/infection": "^0.20", + "lcobucci/coding-standard": "^6.0", + "mikey179/vfsstream": "^1.6", + "phpbench/phpbench": "^0.17", + "phpstan/extension-installer": "^1.0", + "phpstan/phpstan": "^0.12", + "phpstan/phpstan-deprecation-rules": "^0.12", + "phpstan/phpstan-phpunit": "^0.12", + "phpstan/phpstan-strict-rules": "^0.12", + "phpunit/php-invoker": "^3.1", + "phpunit/phpunit": "^9.4" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.1-dev" + "dev-master": "4.0-dev" } }, "autoload": { @@ -1560,7 +1551,7 @@ ], "authors": [ { - "name": "Luís Otávio Cobucci Oblonczyk", + "name": "Luís Cobucci", "email": "lcobucci@gmail.com", "role": "Developer" } @@ -1570,7 +1561,7 @@ "JWS", "jwt" ], - "time": "2020-08-20T13:22:28+00:00" + "time": "2020-11-25T02:06:12+00:00" }, { "name": "league/commonmark", @@ -1819,25 +1810,25 @@ }, { "name": "league/oauth2-server", - "version": "8.1.1", + "version": "8.2.4", "source": { "type": "git", "url": "https://github.com/thephpleague/oauth2-server.git", - "reference": "09f22e8121fa1832962dba18213b80d4267ef8a3" + "reference": "622eaa1f28eb4a2dea0cfc7e4f5280fac794e83c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/thephpleague/oauth2-server/zipball/09f22e8121fa1832962dba18213b80d4267ef8a3", - "reference": "09f22e8121fa1832962dba18213b80d4267ef8a3", + "url": "https://api.github.com/repos/thephpleague/oauth2-server/zipball/622eaa1f28eb4a2dea0cfc7e4f5280fac794e83c", + "reference": "622eaa1f28eb4a2dea0cfc7e4f5280fac794e83c", "shasum": "" }, "require": { "defuse/php-encryption": "^2.2.1", "ext-json": "*", "ext-openssl": "*", - "lcobucci/jwt": "^3.3.1", + "lcobucci/jwt": "^3.4 || ^4.0", "league/event": "^2.2", - "php": ">=7.2.0", + "php": "^7.2 || ^8.0", "psr/http-message": "^1.0.1" }, "replace": { @@ -1845,10 +1836,10 @@ "lncd/oauth2": "*" }, "require-dev": { - "laminas/laminas-diactoros": "^2.3.0", - "phpstan/phpstan": "^0.11.19", - "phpstan/phpstan-phpunit": "^0.11.2", - "phpunit/phpunit": "^8.5.4 || ^9.1.3", + "laminas/laminas-diactoros": "^2.4.1", + "phpstan/phpstan": "^0.12.57", + "phpstan/phpstan-phpunit": "^0.12.16", + "phpunit/phpunit": "^8.5.13", "roave/security-advisories": "dev-master" }, "type": "library", @@ -1892,20 +1883,20 @@ "secure", "server" ], - "time": "2020-07-01T11:33:50+00:00" + "time": "2020-12-10T11:35:44+00:00" }, { "name": "monolog/monolog", - "version": "2.1.1", + "version": "2.2.0", "source": { "type": "git", "url": "https://github.com/Seldaek/monolog.git", - "reference": "f9eee5cec93dfb313a38b6b288741e84e53f02d5" + "reference": "1cb1cde8e8dd0f70cc0fe51354a59acad9302084" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/Seldaek/monolog/zipball/f9eee5cec93dfb313a38b6b288741e84e53f02d5", - "reference": "f9eee5cec93dfb313a38b6b288741e84e53f02d5", + "url": "https://api.github.com/repos/Seldaek/monolog/zipball/1cb1cde8e8dd0f70cc0fe51354a59acad9302084", + "reference": "1cb1cde8e8dd0f70cc0fe51354a59acad9302084", "shasum": "" }, "require": { @@ -1918,16 +1909,17 @@ "require-dev": { "aws/aws-sdk-php": "^2.4.9 || ^3.0", "doctrine/couchdb": "~1.0@dev", - "elasticsearch/elasticsearch": "^6.0", + "elasticsearch/elasticsearch": "^7", "graylog2/gelf-php": "^1.4.2", + "mongodb/mongodb": "^1.8", "php-amqplib/php-amqplib": "~2.4", "php-console/php-console": "^3.1.3", - "php-parallel-lint/php-parallel-lint": "^1.0", "phpspec/prophecy": "^1.6.1", + "phpstan/phpstan": "^0.12.59", "phpunit/phpunit": "^8.5", "predis/predis": "^1.1", "rollbar/rollbar": "^1.3", - "ruflin/elastica": ">=0.90 <3.0", + "ruflin/elastica": ">=0.90 <7.0.1", "swiftmailer/swiftmailer": "^5.3|^6.0" }, "suggest": { @@ -1947,7 +1939,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "2.x-dev" + "dev-main": "2.x-dev" } }, "autoload": { @@ -1963,30 +1955,30 @@ { "name": "Jordi Boggiano", "email": "j.boggiano@seld.be", - "homepage": "http://seld.be" + "homepage": "https://seld.be" } ], "description": "Sends your logs to files, sockets, inboxes, databases and various web services", - "homepage": "http://github.com/Seldaek/monolog", + "homepage": "https://github.com/Seldaek/monolog", "keywords": [ "log", "logging", "psr-3" ], - "time": "2020-07-23T08:41:23+00:00" + "time": "2020-12-14T13:15:25+00:00" }, { "name": "nesbot/carbon", - "version": "2.41.5", + "version": "2.43.0", "source": { "type": "git", "url": "https://github.com/briannesbitt/Carbon.git", - "reference": "c4a9caf97cfc53adfc219043bcecf42bc663acee" + "reference": "d32c57d8389113742f4a88725a170236470012e2" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/briannesbitt/Carbon/zipball/c4a9caf97cfc53adfc219043bcecf42bc663acee", - "reference": "c4a9caf97cfc53adfc219043bcecf42bc663acee", + "url": "https://api.github.com/repos/briannesbitt/Carbon/zipball/d32c57d8389113742f4a88725a170236470012e2", + "reference": "d32c57d8389113742f4a88725a170236470012e2", "shasum": "" }, "require": { @@ -2001,7 +1993,7 @@ "kylekatarnls/multi-tester": "^2.0", "phpmd/phpmd": "^2.9", "phpstan/extension-installer": "^1.0", - "phpstan/phpstan": "^0.12.35", + "phpstan/phpstan": "^0.12.54", "phpunit/phpunit": "^7.5 || ^8.0", "squizlabs/php_codesniffer": "^3.4" }, @@ -2052,20 +2044,20 @@ "datetime", "time" ], - "time": "2020-10-23T06:02:30+00:00" + "time": "2020-12-17T20:55:32+00:00" }, { "name": "nikic/php-parser", - "version": "v4.10.2", + "version": "v4.10.4", "source": { "type": "git", "url": "https://github.com/nikic/PHP-Parser.git", - "reference": "658f1be311a230e0907f5dfe0213742aff0596de" + "reference": "c6d052fc58cb876152f89f532b95a8d7907e7f0e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/658f1be311a230e0907f5dfe0213742aff0596de", - "reference": "658f1be311a230e0907f5dfe0213742aff0596de", + "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/c6d052fc58cb876152f89f532b95a8d7907e7f0e", + "reference": "c6d052fc58cb876152f89f532b95a8d7907e7f0e", "shasum": "" }, "require": { @@ -2104,20 +2096,20 @@ "parser", "php" ], - "time": "2020-09-26T10:30:38+00:00" + "time": "2020-12-20T10:01:03+00:00" }, { "name": "nyholm/psr7", - "version": "1.3.1", + "version": "1.3.2", "source": { "type": "git", "url": "https://github.com/Nyholm/psr7.git", - "reference": "21b71a31eab5c0c2caf967b9c0fd97020254ed75" + "reference": "a272953743c454ac4af9626634daaf5ab3ce1173" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/Nyholm/psr7/zipball/21b71a31eab5c0c2caf967b9c0fd97020254ed75", - "reference": "21b71a31eab5c0c2caf967b9c0fd97020254ed75", + "url": "https://api.github.com/repos/Nyholm/psr7/zipball/a272953743c454ac4af9626634daaf5ab3ce1173", + "reference": "a272953743c454ac4af9626634daaf5ab3ce1173", "shasum": "" }, "require": { @@ -2131,9 +2123,9 @@ "psr/http-message-implementation": "1.0" }, "require-dev": { - "http-interop/http-factory-tests": "dev-master", + "http-interop/http-factory-tests": "^0.8", "php-http/psr7-integration-tests": "^1.0", - "phpunit/phpunit": "^7.5", + "phpunit/phpunit": "^7.5 || 8.5 || 9.4", "symfony/error-handler": "^4.4" }, "type": "library", @@ -2162,25 +2154,25 @@ } ], "description": "A fast PHP7 implementation of PSR-7", - "homepage": "http://tnyholm.se", + "homepage": "https://tnyholm.se", "keywords": [ "psr-17", "psr-7" ], - "time": "2020-06-13T15:59:10+00:00" + "time": "2020-11-14T17:35:34+00:00" }, { "name": "opis/closure", - "version": "3.6.0", + "version": "3.6.1", "source": { "type": "git", "url": "https://github.com/opis/closure.git", - "reference": "c547f8262a5fa9ff507bd06cc394067b83a75085" + "reference": "943b5d70cc5ae7483f6aff6ff43d7e34592ca0f5" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/opis/closure/zipball/c547f8262a5fa9ff507bd06cc394067b83a75085", - "reference": "c547f8262a5fa9ff507bd06cc394067b83a75085", + "url": "https://api.github.com/repos/opis/closure/zipball/943b5d70cc5ae7483f6aff6ff43d7e34592ca0f5", + "reference": "943b5d70cc5ae7483f6aff6ff43d7e34592ca0f5", "shasum": "" }, "require": { @@ -2228,7 +2220,7 @@ "serialization", "serialize" ], - "time": "2020-10-11T21:42:15+00:00" + "time": "2020-11-07T02:01:34+00:00" }, { "name": "paragonie/random_compat", @@ -2277,16 +2269,16 @@ }, { "name": "paragonie/sodium_compat", - "version": "v1.13.0", + "version": "v1.14.0", "source": { "type": "git", "url": "https://github.com/paragonie/sodium_compat.git", - "reference": "bbade402cbe84c69b718120911506a3aa2bae653" + "reference": "a1cfe0b21faf9c0b61ac0c6188c4af7fd6fd0db3" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/paragonie/sodium_compat/zipball/bbade402cbe84c69b718120911506a3aa2bae653", - "reference": "bbade402cbe84c69b718120911506a3aa2bae653", + "url": "https://api.github.com/repos/paragonie/sodium_compat/zipball/a1cfe0b21faf9c0b61ac0c6188c4af7fd6fd0db3", + "reference": "a1cfe0b21faf9c0b61ac0c6188c4af7fd6fd0db3", "shasum": "" }, "require": { @@ -2294,7 +2286,7 @@ "php": "^5.2.4|^5.3|^5.4|^5.5|^5.6|^7|^8" }, "require-dev": { - "phpunit/phpunit": "^3|^4|^5|^6|^7" + "phpunit/phpunit": "^3|^4|^5|^6|^7|^8|^9" }, "suggest": { "ext-libsodium": "PHP < 7.0: Better performance, password hashing (Argon2i), secure memory management (memzero), and better security.", @@ -2355,7 +2347,7 @@ "secret-key cryptography", "side-channel resistant" ], - "time": "2020-03-20T21:48:09+00:00" + "time": "2020-12-03T16:26:19+00:00" }, { "name": "php-http/message-factory", @@ -2464,16 +2456,16 @@ }, { "name": "phpseclib/phpseclib", - "version": "2.0.29", + "version": "2.0.30", "source": { "type": "git", "url": "https://github.com/phpseclib/phpseclib.git", - "reference": "497856a8d997f640b4a516062f84228a772a48a8" + "reference": "136b9ca7eebef78be14abf90d65c5e57b6bc5d36" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpseclib/phpseclib/zipball/497856a8d997f640b4a516062f84228a772a48a8", - "reference": "497856a8d997f640b4a516062f84228a772a48a8", + "url": "https://api.github.com/repos/phpseclib/phpseclib/zipball/136b9ca7eebef78be14abf90d65c5e57b6bc5d36", + "reference": "136b9ca7eebef78be14abf90d65c5e57b6bc5d36", "shasum": "" }, "require": { @@ -2481,7 +2473,7 @@ }, "require-dev": { "phing/phing": "~2.7", - "phpunit/phpunit": "^4.8.35|^5.7|^6.0", + "phpunit/phpunit": "^4.8.35|^5.7|^6.0|^9.4", "squizlabs/php_codesniffer": "~2.0" }, "suggest": { @@ -2551,7 +2543,7 @@ "x.509", "x509" ], - "time": "2020-09-08T04:24:43+00:00" + "time": "2020-12-17T05:42:04+00:00" }, { "name": "psr/container", @@ -2648,6 +2640,55 @@ ], "time": "2019-01-08T18:20:26+00:00" }, + { + "name": "psr/http-client", + "version": "1.0.1", + "source": { + "type": "git", + "url": "https://github.com/php-fig/http-client.git", + "reference": "2dfb5f6c5eff0e91e20e913f8c5452ed95b86621" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/php-fig/http-client/zipball/2dfb5f6c5eff0e91e20e913f8c5452ed95b86621", + "reference": "2dfb5f6c5eff0e91e20e913f8c5452ed95b86621", + "shasum": "" + }, + "require": { + "php": "^7.0 || ^8.0", + "psr/http-message": "^1.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0.x-dev" + } + }, + "autoload": { + "psr-4": { + "Psr\\Http\\Client\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "PHP-FIG", + "homepage": "http://www.php-fig.org/" + } + ], + "description": "Common interface for HTTP clients", + "homepage": "https://github.com/php-fig/http-client", + "keywords": [ + "http", + "http-client", + "psr", + "psr-18" + ], + "time": "2020-06-29T06:28:15+00:00" + }, { "name": "psr/http-factory", "version": "1.0.1", @@ -2847,16 +2888,16 @@ }, { "name": "psy/psysh", - "version": "v0.10.4", + "version": "v0.10.5", "source": { "type": "git", "url": "https://github.com/bobthecow/psysh.git", - "reference": "a8aec1b2981ab66882a01cce36a49b6317dc3560" + "reference": "7c710551d4a2653afa259c544508dc18a9098956" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/bobthecow/psysh/zipball/a8aec1b2981ab66882a01cce36a49b6317dc3560", - "reference": "a8aec1b2981ab66882a01cce36a49b6317dc3560", + "url": "https://api.github.com/repos/bobthecow/psysh/zipball/7c710551d4a2653afa259c544508dc18a9098956", + "reference": "7c710551d4a2653afa259c544508dc18a9098956", "shasum": "" }, "require": { @@ -2915,30 +2956,30 @@ "interactive", "shell" ], - "time": "2020-05-03T19:32:03+00:00" + "time": "2020-12-04T02:51:30+00:00" }, { "name": "pusher/pusher-php-server", - "version": "v4.1.4", + "version": "v4.1.5", "source": { "type": "git", "url": "https://github.com/pusher/pusher-http-php.git", - "reference": "e75e5715e3b651ec20dee5844095aadefab81acb" + "reference": "251f22602320c1b1aff84798fe74f3f7ee0504a9" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/pusher/pusher-http-php/zipball/e75e5715e3b651ec20dee5844095aadefab81acb", - "reference": "e75e5715e3b651ec20dee5844095aadefab81acb", + "url": "https://api.github.com/repos/pusher/pusher-http-php/zipball/251f22602320c1b1aff84798fe74f3f7ee0504a9", + "reference": "251f22602320c1b1aff84798fe74f3f7ee0504a9", "shasum": "" }, "require": { "ext-curl": "*", "paragonie/sodium_compat": "^1.6", - "php": "^7.1", + "php": "^7.1|^8.0", "psr/log": "^1.0" }, "require-dev": { - "phpunit/phpunit": "^7.2" + "phpunit/phpunit": "^7.2|^8.5|^9.3" }, "type": "library", "extra": { @@ -2969,7 +3010,7 @@ "rest", "trigger" ], - "time": "2020-04-14T15:20:04+00:00" + "time": "2020-12-09T09:38:19+00:00" }, { "name": "ralouphie/getallheaders", @@ -3379,16 +3420,16 @@ }, { "name": "react/http", - "version": "v1.1.0", + "version": "v1.2.0", "source": { "type": "git", "url": "https://github.com/reactphp/http.git", - "reference": "754b0c18545d258922ffa907f3b18598280fdecd" + "reference": "badb0a87890e14b9cdfa3aec3ba1aafd900401ac" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/reactphp/http/zipball/754b0c18545d258922ffa907f3b18598280fdecd", - "reference": "754b0c18545d258922ffa907f3b18598280fdecd", + "url": "https://api.github.com/repos/reactphp/http/zipball/badb0a87890e14b9cdfa3aec3ba1aafd900401ac", + "reference": "badb0a87890e14b9cdfa3aec3ba1aafd900401ac", "shasum": "" }, "require": { @@ -3455,7 +3496,7 @@ "server", "streaming" ], - "time": "2020-09-11T11:01:51+00:00" + "time": "2020-12-04T12:57:33+00:00" }, { "name": "react/promise", @@ -3788,32 +3829,31 @@ }, { "name": "swiftmailer/swiftmailer", - "version": "v6.2.3", + "version": "v6.2.5", "source": { "type": "git", "url": "https://github.com/swiftmailer/swiftmailer.git", - "reference": "149cfdf118b169f7840bbe3ef0d4bc795d1780c9" + "reference": "698a6a9f54d7eb321274de3ad19863802c879fb7" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/swiftmailer/swiftmailer/zipball/149cfdf118b169f7840bbe3ef0d4bc795d1780c9", - "reference": "149cfdf118b169f7840bbe3ef0d4bc795d1780c9", + "url": "https://api.github.com/repos/swiftmailer/swiftmailer/zipball/698a6a9f54d7eb321274de3ad19863802c879fb7", + "reference": "698a6a9f54d7eb321274de3ad19863802c879fb7", "shasum": "" }, "require": { - "egulias/email-validator": "~2.0", + "egulias/email-validator": "^2.0", "php": ">=7.0.0", "symfony/polyfill-iconv": "^1.0", "symfony/polyfill-intl-idn": "^1.10", "symfony/polyfill-mbstring": "^1.0" }, "require-dev": { - "mockery/mockery": "~0.9.1", - "symfony/phpunit-bridge": "^3.4.19|^4.1.8" + "mockery/mockery": "^1.0", + "symfony/phpunit-bridge": "^4.4|^5.0" }, "suggest": { - "ext-intl": "Needed to support internationalized email addresses", - "true/punycode": "Needed to support internationalized email addresses, if ext-intl is not installed" + "ext-intl": "Needed to support internationalized email addresses" }, "type": "library", "extra": { @@ -3846,20 +3886,20 @@ "mail", "mailer" ], - "time": "2019-11-12T09:31:26+00:00" + "time": "2021-01-12T09:35:59+00:00" }, { "name": "symfony/console", - "version": "v5.1.8", + "version": "v5.2.1", "source": { "type": "git", "url": "https://github.com/symfony/console.git", - "reference": "e0b2c29c0fa6a69089209bbe8fcff4df2a313d0e" + "reference": "47c02526c532fb381374dab26df05e7313978976" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/console/zipball/e0b2c29c0fa6a69089209bbe8fcff4df2a313d0e", - "reference": "e0b2c29c0fa6a69089209bbe8fcff4df2a313d0e", + "url": "https://api.github.com/repos/symfony/console/zipball/47c02526c532fb381374dab26df05e7313978976", + "reference": "47c02526c532fb381374dab26df05e7313978976", "shasum": "" }, "require": { @@ -3920,20 +3960,26 @@ ], "description": "Symfony Console Component", "homepage": "https://symfony.com", - "time": "2020-10-24T12:01:57+00:00" + "keywords": [ + "cli", + "command line", + "console", + "terminal" + ], + "time": "2020-12-18T08:03:05+00:00" }, { "name": "symfony/css-selector", - "version": "v5.1.8", + "version": "v5.2.1", "source": { "type": "git", "url": "https://github.com/symfony/css-selector.git", - "reference": "6cbebda22ffc0d4bb8fea0c1311c2ca54c4c8fa0" + "reference": "f789e7ead4c79e04ca9a6d6162fc629c89bd8054" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/css-selector/zipball/6cbebda22ffc0d4bb8fea0c1311c2ca54c4c8fa0", - "reference": "6cbebda22ffc0d4bb8fea0c1311c2ca54c4c8fa0", + "url": "https://api.github.com/repos/symfony/css-selector/zipball/f789e7ead4c79e04ca9a6d6162fc629c89bd8054", + "reference": "f789e7ead4c79e04ca9a6d6162fc629c89bd8054", "shasum": "" }, "require": { @@ -3968,7 +4014,7 @@ ], "description": "Symfony CssSelector Component", "homepage": "https://symfony.com", - "time": "2020-10-24T12:01:57+00:00" + "time": "2020-12-08T17:02:38+00:00" }, { "name": "symfony/deprecation-contracts", @@ -4022,16 +4068,16 @@ }, { "name": "symfony/error-handler", - "version": "v5.1.8", + "version": "v5.2.1", "source": { "type": "git", "url": "https://github.com/symfony/error-handler.git", - "reference": "a154f2b12fd1ec708559ba73ed58bd1304e55718" + "reference": "59b190ce16ddf32771a22087b60f6dafd3407147" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/error-handler/zipball/a154f2b12fd1ec708559ba73ed58bd1304e55718", - "reference": "a154f2b12fd1ec708559ba73ed58bd1304e55718", + "url": "https://api.github.com/repos/symfony/error-handler/zipball/59b190ce16ddf32771a22087b60f6dafd3407147", + "reference": "59b190ce16ddf32771a22087b60f6dafd3407147", "shasum": "" }, "require": { @@ -4070,20 +4116,20 @@ ], "description": "Symfony ErrorHandler Component", "homepage": "https://symfony.com", - "time": "2020-10-24T12:01:57+00:00" + "time": "2020-12-09T18:54:12+00:00" }, { "name": "symfony/event-dispatcher", - "version": "v5.1.8", + "version": "v5.2.1", "source": { "type": "git", "url": "https://github.com/symfony/event-dispatcher.git", - "reference": "26f4edae48c913fc183a3da0553fe63bdfbd361a" + "reference": "1c93f7a1dff592c252574c79a8635a8a80856042" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/26f4edae48c913fc183a3da0553fe63bdfbd361a", - "reference": "26f4edae48c913fc183a3da0553fe63bdfbd361a", + "url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/1c93f7a1dff592c252574c79a8635a8a80856042", + "reference": "1c93f7a1dff592c252574c79a8635a8a80856042", "shasum": "" }, "require": { @@ -4138,7 +4184,7 @@ ], "description": "Symfony EventDispatcher Component", "homepage": "https://symfony.com", - "time": "2020-10-24T12:01:57+00:00" + "time": "2020-12-18T08:03:05+00:00" }, { "name": "symfony/event-dispatcher-contracts", @@ -4204,16 +4250,16 @@ }, { "name": "symfony/finder", - "version": "v5.1.8", + "version": "v5.2.1", "source": { "type": "git", "url": "https://github.com/symfony/finder.git", - "reference": "e70eb5a69c2ff61ea135a13d2266e8914a67b3a0" + "reference": "0b9231a5922fd7287ba5b411893c0ecd2733e5ba" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/finder/zipball/e70eb5a69c2ff61ea135a13d2266e8914a67b3a0", - "reference": "e70eb5a69c2ff61ea135a13d2266e8914a67b3a0", + "url": "https://api.github.com/repos/symfony/finder/zipball/0b9231a5922fd7287ba5b411893c0ecd2733e5ba", + "reference": "0b9231a5922fd7287ba5b411893c0ecd2733e5ba", "shasum": "" }, "require": { @@ -4244,7 +4290,7 @@ ], "description": "Symfony Finder Component", "homepage": "https://symfony.com", - "time": "2020-10-24T12:01:57+00:00" + "time": "2020-12-08T17:02:38+00:00" }, { "name": "symfony/http-client-contracts", @@ -4310,16 +4356,16 @@ }, { "name": "symfony/http-foundation", - "version": "v5.1.8", + "version": "v5.2.1", "source": { "type": "git", "url": "https://github.com/symfony/http-foundation.git", - "reference": "a2860ec970404b0233ab1e59e0568d3277d32b6f" + "reference": "a1f6218b29897ab52acba58cfa905b83625bef8d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/http-foundation/zipball/a2860ec970404b0233ab1e59e0568d3277d32b6f", - "reference": "a2860ec970404b0233ab1e59e0568d3277d32b6f", + "url": "https://api.github.com/repos/symfony/http-foundation/zipball/a1f6218b29897ab52acba58cfa905b83625bef8d", + "reference": "a1f6218b29897ab52acba58cfa905b83625bef8d", "shasum": "" }, "require": { @@ -4362,20 +4408,20 @@ ], "description": "Symfony HttpFoundation Component", "homepage": "https://symfony.com", - "time": "2020-10-24T12:01:57+00:00" + "time": "2020-12-18T10:00:10+00:00" }, { "name": "symfony/http-kernel", - "version": "v5.1.8", + "version": "v5.2.1", "source": { "type": "git", "url": "https://github.com/symfony/http-kernel.git", - "reference": "a13b3c4d994a4fd051f4c6800c5e33c9508091dd" + "reference": "1feb619286d819180f7b8bc0dc44f516d9c62647" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/http-kernel/zipball/a13b3c4d994a4fd051f4c6800c5e33c9508091dd", - "reference": "a13b3c4d994a4fd051f4c6800c5e33c9508091dd", + "url": "https://api.github.com/repos/symfony/http-kernel/zipball/1feb619286d819180f7b8bc0dc44f516d9c62647", + "reference": "1feb619286d819180f7b8bc0dc44f516d9c62647", "shasum": "" }, "require": { @@ -4395,7 +4441,7 @@ "symfony/cache": "<5.0", "symfony/config": "<5.0", "symfony/console": "<4.4", - "symfony/dependency-injection": "<4.4", + "symfony/dependency-injection": "<5.1.8", "symfony/doctrine-bridge": "<5.0", "symfony/form": "<5.0", "symfony/http-client": "<5.0", @@ -4415,7 +4461,7 @@ "symfony/config": "^5.0", "symfony/console": "^4.4|^5.0", "symfony/css-selector": "^4.4|^5.0", - "symfony/dependency-injection": "^4.4|^5.0", + "symfony/dependency-injection": "^5.1.8", "symfony/dom-crawler": "^4.4|^5.0", "symfony/expression-language": "^4.4|^5.0", "symfony/finder": "^4.4|^5.0", @@ -4457,24 +4503,25 @@ ], "description": "Symfony HttpKernel Component", "homepage": "https://symfony.com", - "time": "2020-10-28T05:55:23+00:00" + "time": "2020-12-18T13:49:39+00:00" }, { "name": "symfony/mime", - "version": "v5.1.8", + "version": "v5.2.1", "source": { "type": "git", "url": "https://github.com/symfony/mime.git", - "reference": "f5485a92c24d4bcfc2f3fc648744fb398482ff1b" + "reference": "de97005aef7426ba008c46ba840fc301df577ada" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/mime/zipball/f5485a92c24d4bcfc2f3fc648744fb398482ff1b", - "reference": "f5485a92c24d4bcfc2f3fc648744fb398482ff1b", + "url": "https://api.github.com/repos/symfony/mime/zipball/de97005aef7426ba008c46ba840fc301df577ada", + "reference": "de97005aef7426ba008c46ba840fc301df577ada", "shasum": "" }, "require": { "php": ">=7.2.5", + "symfony/deprecation-contracts": "^2.1", "symfony/polyfill-intl-idn": "^1.10", "symfony/polyfill-mbstring": "^1.0", "symfony/polyfill-php80": "^1.15" @@ -4484,7 +4531,11 @@ }, "require-dev": { "egulias/email-validator": "^2.1.10", - "symfony/dependency-injection": "^4.4|^5.0" + "phpdocumentor/reflection-docblock": "^3.0|^4.0|^5.0", + "symfony/dependency-injection": "^4.4|^5.0", + "symfony/property-access": "^4.4|^5.1", + "symfony/property-info": "^4.4|^5.1", + "symfony/serializer": "^5.2" }, "type": "library", "autoload": { @@ -4515,20 +4566,20 @@ "mime", "mime-type" ], - "time": "2020-10-24T12:01:57+00:00" + "time": "2020-12-09T18:54:12+00:00" }, { "name": "symfony/polyfill-ctype", - "version": "v1.20.0", + "version": "v1.22.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-ctype.git", - "reference": "f4ba089a5b6366e453971d3aad5fe8e897b37f41" + "reference": "c6c942b1ac76c82448322025e084cadc56048b4e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/f4ba089a5b6366e453971d3aad5fe8e897b37f41", - "reference": "f4ba089a5b6366e453971d3aad5fe8e897b37f41", + "url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/c6c942b1ac76c82448322025e084cadc56048b4e", + "reference": "c6c942b1ac76c82448322025e084cadc56048b4e", "shasum": "" }, "require": { @@ -4540,7 +4591,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "1.20-dev" + "dev-main": "1.22-dev" }, "thanks": { "name": "symfony/polyfill", @@ -4577,20 +4628,20 @@ "polyfill", "portable" ], - "time": "2020-10-23T14:02:19+00:00" + "time": "2021-01-07T16:49:33+00:00" }, { "name": "symfony/polyfill-iconv", - "version": "v1.20.0", + "version": "v1.22.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-iconv.git", - "reference": "c536646fdb4f29104dd26effc2fdcb9a5b085024" + "reference": "b34bfb8c4c22650ac080d2662ae3502e5f2f4ae6" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-iconv/zipball/c536646fdb4f29104dd26effc2fdcb9a5b085024", - "reference": "c536646fdb4f29104dd26effc2fdcb9a5b085024", + "url": "https://api.github.com/repos/symfony/polyfill-iconv/zipball/b34bfb8c4c22650ac080d2662ae3502e5f2f4ae6", + "reference": "b34bfb8c4c22650ac080d2662ae3502e5f2f4ae6", "shasum": "" }, "require": { @@ -4602,7 +4653,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "1.20-dev" + "dev-main": "1.22-dev" }, "thanks": { "name": "symfony/polyfill", @@ -4640,20 +4691,20 @@ "portable", "shim" ], - "time": "2020-10-23T14:02:19+00:00" + "time": "2021-01-07T16:49:33+00:00" }, { "name": "symfony/polyfill-intl-grapheme", - "version": "v1.20.0", + "version": "v1.22.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-intl-grapheme.git", - "reference": "c7cf3f858ec7d70b89559d6e6eb1f7c2517d479c" + "reference": "267a9adeb8ecb8071040a740930e077cdfb987af" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-intl-grapheme/zipball/c7cf3f858ec7d70b89559d6e6eb1f7c2517d479c", - "reference": "c7cf3f858ec7d70b89559d6e6eb1f7c2517d479c", + "url": "https://api.github.com/repos/symfony/polyfill-intl-grapheme/zipball/267a9adeb8ecb8071040a740930e077cdfb987af", + "reference": "267a9adeb8ecb8071040a740930e077cdfb987af", "shasum": "" }, "require": { @@ -4665,7 +4716,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "1.20-dev" + "dev-main": "1.22-dev" }, "thanks": { "name": "symfony/polyfill", @@ -4704,20 +4755,20 @@ "portable", "shim" ], - "time": "2020-10-23T14:02:19+00:00" + "time": "2021-01-07T16:49:33+00:00" }, { "name": "symfony/polyfill-intl-idn", - "version": "v1.20.0", + "version": "v1.22.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-intl-idn.git", - "reference": "3b75acd829741c768bc8b1f84eb33265e7cc5117" + "reference": "0eb8293dbbcd6ef6bf81404c9ce7d95bcdf34f44" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-intl-idn/zipball/3b75acd829741c768bc8b1f84eb33265e7cc5117", - "reference": "3b75acd829741c768bc8b1f84eb33265e7cc5117", + "url": "https://api.github.com/repos/symfony/polyfill-intl-idn/zipball/0eb8293dbbcd6ef6bf81404c9ce7d95bcdf34f44", + "reference": "0eb8293dbbcd6ef6bf81404c9ce7d95bcdf34f44", "shasum": "" }, "require": { @@ -4731,7 +4782,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "1.20-dev" + "dev-main": "1.22-dev" }, "thanks": { "name": "symfony/polyfill", @@ -4774,20 +4825,20 @@ "portable", "shim" ], - "time": "2020-10-23T14:02:19+00:00" + "time": "2021-01-07T16:49:33+00:00" }, { "name": "symfony/polyfill-intl-normalizer", - "version": "v1.20.0", + "version": "v1.22.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-intl-normalizer.git", - "reference": "727d1096295d807c309fb01a851577302394c897" + "reference": "6e971c891537eb617a00bb07a43d182a6915faba" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-intl-normalizer/zipball/727d1096295d807c309fb01a851577302394c897", - "reference": "727d1096295d807c309fb01a851577302394c897", + "url": "https://api.github.com/repos/symfony/polyfill-intl-normalizer/zipball/6e971c891537eb617a00bb07a43d182a6915faba", + "reference": "6e971c891537eb617a00bb07a43d182a6915faba", "shasum": "" }, "require": { @@ -4799,7 +4850,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "1.20-dev" + "dev-main": "1.22-dev" }, "thanks": { "name": "symfony/polyfill", @@ -4841,20 +4892,20 @@ "portable", "shim" ], - "time": "2020-10-23T14:02:19+00:00" + "time": "2021-01-07T17:09:11+00:00" }, { "name": "symfony/polyfill-mbstring", - "version": "v1.20.0", + "version": "v1.22.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-mbstring.git", - "reference": "39d483bdf39be819deabf04ec872eb0b2410b531" + "reference": "f377a3dd1fde44d37b9831d68dc8dea3ffd28e13" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/39d483bdf39be819deabf04ec872eb0b2410b531", - "reference": "39d483bdf39be819deabf04ec872eb0b2410b531", + "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/f377a3dd1fde44d37b9831d68dc8dea3ffd28e13", + "reference": "f377a3dd1fde44d37b9831d68dc8dea3ffd28e13", "shasum": "" }, "require": { @@ -4866,7 +4917,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "1.20-dev" + "dev-main": "1.22-dev" }, "thanks": { "name": "symfony/polyfill", @@ -4904,20 +4955,20 @@ "portable", "shim" ], - "time": "2020-10-23T14:02:19+00:00" + "time": "2021-01-07T16:49:33+00:00" }, { "name": "symfony/polyfill-php72", - "version": "v1.20.0", + "version": "v1.22.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-php72.git", - "reference": "cede45fcdfabdd6043b3592e83678e42ec69e930" + "reference": "cc6e6f9b39fe8075b3dabfbaf5b5f645ae1340c9" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-php72/zipball/cede45fcdfabdd6043b3592e83678e42ec69e930", - "reference": "cede45fcdfabdd6043b3592e83678e42ec69e930", + "url": "https://api.github.com/repos/symfony/polyfill-php72/zipball/cc6e6f9b39fe8075b3dabfbaf5b5f645ae1340c9", + "reference": "cc6e6f9b39fe8075b3dabfbaf5b5f645ae1340c9", "shasum": "" }, "require": { @@ -4926,7 +4977,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "1.20-dev" + "dev-main": "1.22-dev" }, "thanks": { "name": "symfony/polyfill", @@ -4963,20 +5014,20 @@ "portable", "shim" ], - "time": "2020-10-23T14:02:19+00:00" + "time": "2021-01-07T16:49:33+00:00" }, { "name": "symfony/polyfill-php73", - "version": "v1.20.0", + "version": "v1.22.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-php73.git", - "reference": "8ff431c517be11c78c48a39a66d37431e26a6bed" + "reference": "a678b42e92f86eca04b7fa4c0f6f19d097fb69e2" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-php73/zipball/8ff431c517be11c78c48a39a66d37431e26a6bed", - "reference": "8ff431c517be11c78c48a39a66d37431e26a6bed", + "url": "https://api.github.com/repos/symfony/polyfill-php73/zipball/a678b42e92f86eca04b7fa4c0f6f19d097fb69e2", + "reference": "a678b42e92f86eca04b7fa4c0f6f19d097fb69e2", "shasum": "" }, "require": { @@ -4985,7 +5036,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "1.20-dev" + "dev-main": "1.22-dev" }, "thanks": { "name": "symfony/polyfill", @@ -5025,20 +5076,20 @@ "portable", "shim" ], - "time": "2020-10-23T14:02:19+00:00" + "time": "2021-01-07T16:49:33+00:00" }, { "name": "symfony/polyfill-php80", - "version": "v1.20.0", + "version": "v1.22.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-php80.git", - "reference": "e70aa8b064c5b72d3df2abd5ab1e90464ad009de" + "reference": "dc3063ba22c2a1fd2f45ed856374d79114998f91" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-php80/zipball/e70aa8b064c5b72d3df2abd5ab1e90464ad009de", - "reference": "e70aa8b064c5b72d3df2abd5ab1e90464ad009de", + "url": "https://api.github.com/repos/symfony/polyfill-php80/zipball/dc3063ba22c2a1fd2f45ed856374d79114998f91", + "reference": "dc3063ba22c2a1fd2f45ed856374d79114998f91", "shasum": "" }, "require": { @@ -5047,7 +5098,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "1.20-dev" + "dev-main": "1.22-dev" }, "thanks": { "name": "symfony/polyfill", @@ -5091,20 +5142,20 @@ "portable", "shim" ], - "time": "2020-10-23T14:02:19+00:00" + "time": "2021-01-07T16:49:33+00:00" }, { "name": "symfony/process", - "version": "v5.1.8", + "version": "v5.2.1", "source": { "type": "git", "url": "https://github.com/symfony/process.git", - "reference": "f00872c3f6804150d6a0f73b4151daab96248101" + "reference": "bd8815b8b6705298beaa384f04fabd459c10bedd" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/process/zipball/f00872c3f6804150d6a0f73b4151daab96248101", - "reference": "f00872c3f6804150d6a0f73b4151daab96248101", + "url": "https://api.github.com/repos/symfony/process/zipball/bd8815b8b6705298beaa384f04fabd459c10bedd", + "reference": "bd8815b8b6705298beaa384f04fabd459c10bedd", "shasum": "" }, "require": { @@ -5136,7 +5187,7 @@ ], "description": "Symfony Process Component", "homepage": "https://symfony.com", - "time": "2020-10-24T12:01:57+00:00" + "time": "2020-12-08T17:03:37+00:00" }, { "name": "symfony/psr-http-message-bridge", @@ -5204,16 +5255,16 @@ }, { "name": "symfony/routing", - "version": "v5.1.8", + "version": "v5.2.1", "source": { "type": "git", "url": "https://github.com/symfony/routing.git", - "reference": "d6ceee2a37b61b41079005207bf37746d1bfe71f" + "reference": "934ac2720dcc878a47a45c986b483a7ee7193620" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/routing/zipball/d6ceee2a37b61b41079005207bf37746d1bfe71f", - "reference": "d6ceee2a37b61b41079005207bf37746d1bfe71f", + "url": "https://api.github.com/repos/symfony/routing/zipball/934ac2720dcc878a47a45c986b483a7ee7193620", + "reference": "934ac2720dcc878a47a45c986b483a7ee7193620", "shasum": "" }, "require": { @@ -5227,7 +5278,7 @@ "symfony/yaml": "<4.4" }, "require-dev": { - "doctrine/annotations": "~1.2", + "doctrine/annotations": "^1.7", "psr/log": "~1.0", "symfony/config": "^5.0", "symfony/dependency-injection": "^4.4|^5.0", @@ -5273,7 +5324,7 @@ "uri", "url" ], - "time": "2020-10-24T12:01:57+00:00" + "time": "2020-12-08T17:03:37+00:00" }, { "name": "symfony/service-contracts", @@ -5339,16 +5390,16 @@ }, { "name": "symfony/string", - "version": "v5.1.8", + "version": "v5.2.1", "source": { "type": "git", "url": "https://github.com/symfony/string.git", - "reference": "a97573e960303db71be0dd8fda9be3bca5e0feea" + "reference": "5bd67751d2e3f7d6f770c9154b8fbcb2aa05f7ed" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/string/zipball/a97573e960303db71be0dd8fda9be3bca5e0feea", - "reference": "a97573e960303db71be0dd8fda9be3bca5e0feea", + "url": "https://api.github.com/repos/symfony/string/zipball/5bd67751d2e3f7d6f770c9154b8fbcb2aa05f7ed", + "reference": "5bd67751d2e3f7d6f770c9154b8fbcb2aa05f7ed", "shasum": "" }, "require": { @@ -5401,27 +5452,27 @@ "utf-8", "utf8" ], - "time": "2020-10-24T12:01:57+00:00" + "time": "2020-12-05T07:33:16+00:00" }, { "name": "symfony/translation", - "version": "v5.1.8", + "version": "v5.2.1", "source": { "type": "git", "url": "https://github.com/symfony/translation.git", - "reference": "27980838fd261e04379fa91e94e81e662fe5a1b6" + "reference": "a04209ba0d1391c828e5b2373181dac63c52ee70" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/translation/zipball/27980838fd261e04379fa91e94e81e662fe5a1b6", - "reference": "27980838fd261e04379fa91e94e81e662fe5a1b6", + "url": "https://api.github.com/repos/symfony/translation/zipball/a04209ba0d1391c828e5b2373181dac63c52ee70", + "reference": "a04209ba0d1391c828e5b2373181dac63c52ee70", "shasum": "" }, "require": { "php": ">=7.2.5", "symfony/polyfill-mbstring": "~1.0", "symfony/polyfill-php80": "^1.15", - "symfony/translation-contracts": "^2" + "symfony/translation-contracts": "^2.3" }, "conflict": { "symfony/config": "<4.4", @@ -5451,6 +5502,9 @@ }, "type": "library", "autoload": { + "files": [ + "Resources/functions.php" + ], "psr-4": { "Symfony\\Component\\Translation\\": "" }, @@ -5474,7 +5528,7 @@ ], "description": "Symfony Translation Component", "homepage": "https://symfony.com", - "time": "2020-10-24T12:01:57+00:00" + "time": "2020-12-08T17:03:37+00:00" }, { "name": "symfony/translation-contracts", @@ -5539,16 +5593,16 @@ }, { "name": "symfony/var-dumper", - "version": "v5.1.8", + "version": "v5.2.1", "source": { "type": "git", "url": "https://github.com/symfony/var-dumper.git", - "reference": "4e13f3fcefb1fcaaa5efb5403581406f4e840b9a" + "reference": "13e7e882eaa55863faa7c4ad7c60f12f1a8b5089" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/var-dumper/zipball/4e13f3fcefb1fcaaa5efb5403581406f4e840b9a", - "reference": "4e13f3fcefb1fcaaa5efb5403581406f4e840b9a", + "url": "https://api.github.com/repos/symfony/var-dumper/zipball/13e7e882eaa55863faa7c4ad7c60f12f1a8b5089", + "reference": "13e7e882eaa55863faa7c4ad7c60f12f1a8b5089", "shasum": "" }, "require": { @@ -5606,7 +5660,7 @@ "debug", "dump" ], - "time": "2020-10-27T10:11:13+00:00" + "time": "2020-12-16T17:02:19+00:00" }, { "name": "tijsverkoyen/css-to-inline-styles", @@ -5659,37 +5713,39 @@ }, { "name": "vlucas/phpdotenv", - "version": "v4.1.8", + "version": "v5.2.0", "source": { "type": "git", "url": "https://github.com/vlucas/phpdotenv.git", - "reference": "572af79d913627a9d70374d27a6f5d689a35de32" + "reference": "fba64139db67123c7a57072e5f8d3db10d160b66" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/vlucas/phpdotenv/zipball/572af79d913627a9d70374d27a6f5d689a35de32", - "reference": "572af79d913627a9d70374d27a6f5d689a35de32", + "url": "https://api.github.com/repos/vlucas/phpdotenv/zipball/fba64139db67123c7a57072e5f8d3db10d160b66", + "reference": "fba64139db67123c7a57072e5f8d3db10d160b66", "shasum": "" }, "require": { - "php": "^5.5.9 || ^7.0 || ^8.0", - "phpoption/phpoption": "^1.7.3", - "symfony/polyfill-ctype": "^1.17" + "ext-pcre": "*", + "graham-campbell/result-type": "^1.0.1", + "php": "^7.1.3 || ^8.0", + "phpoption/phpoption": "^1.7.4", + "symfony/polyfill-ctype": "^1.17", + "symfony/polyfill-mbstring": "^1.17", + "symfony/polyfill-php80": "^1.17" }, "require-dev": { "bamarni/composer-bin-plugin": "^1.4.1", "ext-filter": "*", - "ext-pcre": "*", - "phpunit/phpunit": "^4.8.35 || ^5.7.27 || ^6.5.6 || ^7.0" + "phpunit/phpunit": "^7.5.20 || ^8.5.2 || ^9.0" }, "suggest": { - "ext-filter": "Required to use the boolean validator.", - "ext-pcre": "Required to use most of the library." + "ext-filter": "Required to use the boolean validator." }, "type": "library", "extra": { "branch-alias": { - "dev-master": "4.1-dev" + "dev-master": "5.2-dev" } }, "autoload": { @@ -5719,27 +5775,27 @@ "env", "environment" ], - "time": "2020-07-14T19:22:52+00:00" + "time": "2020-09-14T15:57:31+00:00" }, { "name": "voku/portable-ascii", - "version": "1.5.3", + "version": "1.5.6", "source": { "type": "git", "url": "https://github.com/voku/portable-ascii.git", - "reference": "25bcbf01678930251fd572891447d9e318a6e2b8" + "reference": "80953678b19901e5165c56752d087fc11526017c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/voku/portable-ascii/zipball/25bcbf01678930251fd572891447d9e318a6e2b8", - "reference": "25bcbf01678930251fd572891447d9e318a6e2b8", + "url": "https://api.github.com/repos/voku/portable-ascii/zipball/80953678b19901e5165c56752d087fc11526017c", + "reference": "80953678b19901e5165c56752d087fc11526017c", "shasum": "" }, "require": { "php": ">=7.0.0" }, "require-dev": { - "phpunit/phpunit": "~6.0 || ~7.0" + "phpunit/phpunit": "~6.0 || ~7.0 || ~9.0" }, "suggest": { "ext-intl": "Use Intl for transliterator_transliterate() support" @@ -5767,50 +5823,99 @@ "clean", "php" ], - "time": "2020-07-22T23:32:04+00:00" + "time": "2020-11-12T00:07:28+00:00" + }, + { + "name": "webmozart/assert", + "version": "1.9.1", + "source": { + "type": "git", + "url": "https://github.com/webmozart/assert.git", + "reference": "bafc69caeb4d49c39fd0779086c03a3738cbb389" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/webmozart/assert/zipball/bafc69caeb4d49c39fd0779086c03a3738cbb389", + "reference": "bafc69caeb4d49c39fd0779086c03a3738cbb389", + "shasum": "" + }, + "require": { + "php": "^5.3.3 || ^7.0 || ^8.0", + "symfony/polyfill-ctype": "^1.8" + }, + "conflict": { + "phpstan/phpstan": "<0.12.20", + "vimeo/psalm": "<3.9.1" + }, + "require-dev": { + "phpunit/phpunit": "^4.8.36 || ^7.5.13" + }, + "type": "library", + "autoload": { + "psr-4": { + "Webmozart\\Assert\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Bernhard Schussek", + "email": "bschussek@gmail.com" + } + ], + "description": "Assertions to validate method input/output with nice error messages.", + "keywords": [ + "assert", + "check", + "validate" + ], + "time": "2020-07-08T17:02:28+00:00" } ], "packages-dev": [ { "name": "barryvdh/laravel-ide-helper", - "version": "v2.8.2", + "version": "v2.9.0", "source": { "type": "git", "url": "https://github.com/barryvdh/laravel-ide-helper.git", - "reference": "5515cabea39b9cf55f98980d0f269dc9d85cfcca" + "reference": "64a6b902583802c162cdccf7e76dc8619368bf1a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/barryvdh/laravel-ide-helper/zipball/5515cabea39b9cf55f98980d0f269dc9d85cfcca", - "reference": "5515cabea39b9cf55f98980d0f269dc9d85cfcca", + "url": "https://api.github.com/repos/barryvdh/laravel-ide-helper/zipball/64a6b902583802c162cdccf7e76dc8619368bf1a", + "reference": "64a6b902583802c162cdccf7e76dc8619368bf1a", "shasum": "" }, "require": { "barryvdh/reflection-docblock": "^2.0.6", "composer/composer": "^1.6 || ^2", - "doctrine/dbal": "~2.3", + "doctrine/dbal": "^2.6 || ^3", "ext-json": "*", - "illuminate/console": "^6 || ^7 || ^8", - "illuminate/filesystem": "^6 || ^7 || ^8", - "illuminate/support": "^6 || ^7 || ^8", - "php": ">=7.2", + "illuminate/console": "^8", + "illuminate/filesystem": "^8", + "illuminate/support": "^8", + "php": "^7.3 || ^8.0", "phpdocumentor/type-resolver": "^1.1.0" }, "require-dev": { "ext-pdo_sqlite": "*", "friendsofphp/php-cs-fixer": "^2", - "illuminate/config": "^6 || ^7 || ^8", - "illuminate/view": "^6 || ^7 || ^8", - "mockery/mockery": "^1.3.3", - "orchestra/testbench": "^4 || ^5 || ^6", + "illuminate/config": "^8", + "illuminate/view": "^8", + "mockery/mockery": "^1.4", + "orchestra/testbench": "^6", "phpunit/phpunit": "^8.5 || ^9", - "spatie/phpunit-snapshot-assertions": "^1.4 || ^2.2 || ^3 || ^4", + "spatie/phpunit-snapshot-assertions": "^3 || ^4", "vimeo/psalm": "^3.12" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "2.8-dev" + "dev-master": "2.9-dev" }, "laravel": { "providers": [ @@ -5845,7 +5950,7 @@ "phpstorm", "sublime" ], - "time": "2020-12-06T08:55:05+00:00" + "time": "2020-12-29T10:11:05+00:00" }, { "name": "barryvdh/reflection-docblock", @@ -5898,16 +6003,16 @@ }, { "name": "composer/ca-bundle", - "version": "1.2.8", + "version": "1.2.9", "source": { "type": "git", "url": "https://github.com/composer/ca-bundle.git", - "reference": "8a7ecad675253e4654ea05505233285377405215" + "reference": "78a0e288fdcebf92aa2318a8d3656168da6ac1a5" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/composer/ca-bundle/zipball/8a7ecad675253e4654ea05505233285377405215", - "reference": "8a7ecad675253e4654ea05505233285377405215", + "url": "https://api.github.com/repos/composer/ca-bundle/zipball/78a0e288fdcebf92aa2318a8d3656168da6ac1a5", + "reference": "78a0e288fdcebf92aa2318a8d3656168da6ac1a5", "shasum": "" }, "require": { @@ -5916,14 +6021,15 @@ "php": "^5.3.2 || ^7.0 || ^8.0" }, "require-dev": { - "phpunit/phpunit": "^4.8.35 || ^5.7 || 6.5 - 8", + "phpstan/phpstan": "^0.12.55", "psr/log": "^1.0", + "symfony/phpunit-bridge": "^4.2 || ^5", "symfony/process": "^2.5 || ^3.0 || ^4.0 || ^5.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.x-dev" + "dev-main": "1.x-dev" } }, "autoload": { @@ -5950,7 +6056,7 @@ "ssl", "tls" ], - "time": "2020-08-23T12:54:47+00:00" + "time": "2021-01-12T12:10:35+00:00" }, { "name": "composer/composer", @@ -6030,6 +6136,61 @@ ], "time": "2020-12-03T16:20:39+00:00" }, + { + "name": "composer/package-versions-deprecated", + "version": "1.11.99.1", + "source": { + "type": "git", + "url": "https://github.com/composer/package-versions-deprecated.git", + "reference": "7413f0b55a051e89485c5cb9f765fe24bb02a7b6" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/composer/package-versions-deprecated/zipball/7413f0b55a051e89485c5cb9f765fe24bb02a7b6", + "reference": "7413f0b55a051e89485c5cb9f765fe24bb02a7b6", + "shasum": "" + }, + "require": { + "composer-plugin-api": "^1.1.0 || ^2.0", + "php": "^7 || ^8" + }, + "replace": { + "ocramius/package-versions": "1.11.99" + }, + "require-dev": { + "composer/composer": "^1.9.3 || ^2.0@dev", + "ext-zip": "^1.13", + "phpunit/phpunit": "^6.5 || ^7" + }, + "type": "composer-plugin", + "extra": { + "class": "PackageVersions\\Installer", + "branch-alias": { + "dev-master": "1.x-dev" + } + }, + "autoload": { + "psr-4": { + "PackageVersions\\": "src/PackageVersions" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Marco Pivetta", + "email": "ocramius@gmail.com" + }, + { + "name": "Jordi Boggiano", + "email": "j.boggiano@seld.be" + } + ], + "description": "Composer plugin that provides efficient querying for installed package versions (no runtime IO)", + "time": "2020-11-11T10:22:58+00:00" + }, { "name": "composer/semver", "version": "3.2.4", @@ -6280,33 +6441,33 @@ }, { "name": "doctrine/dbal", - "version": "2.10.4", + "version": "3.0.0", "source": { "type": "git", "url": "https://github.com/doctrine/dbal.git", - "reference": "47433196b6390d14409a33885ee42b6208160643" + "reference": "ee6d1260d5cc20ec506455a585945d7bdb98662c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/dbal/zipball/47433196b6390d14409a33885ee42b6208160643", - "reference": "47433196b6390d14409a33885ee42b6208160643", + "url": "https://api.github.com/repos/doctrine/dbal/zipball/ee6d1260d5cc20ec506455a585945d7bdb98662c", + "reference": "ee6d1260d5cc20ec506455a585945d7bdb98662c", "shasum": "" }, "require": { + "composer/package-versions-deprecated": "^1.11.99", "doctrine/cache": "^1.0", "doctrine/event-manager": "^1.0", - "ext-pdo": "*", - "php": "^7.2" + "php": "^7.3 || ^8.0" }, "require-dev": { "doctrine/coding-standard": "^8.1", "jetbrains/phpstorm-stubs": "^2019.1", - "nikic/php-parser": "^4.4", "phpstan/phpstan": "^0.12.40", - "phpunit/phpunit": "^8.5.5", + "phpstan/phpstan-strict-rules": "^0.12.2", + "phpunit/phpunit": "^9.4", "psalm/plugin-phpunit": "^0.10.0", "symfony/console": "^2.0.5|^3.0|^4.0|^5.0", - "vimeo/psalm": "^3.14.2" + "vimeo/psalm": "^3.17.2" }, "suggest": { "symfony/console": "For helpful console commands such as SQL execution and import of files." @@ -6317,13 +6478,12 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "2.10.x-dev", - "dev-develop": "3.0.x-dev" + "dev-master": "4.0.x-dev" } }, "autoload": { "psr-4": { - "Doctrine\\DBAL\\": "lib/Doctrine/DBAL" + "Doctrine\\DBAL\\": "src" } }, "notification-url": "https://packagist.org/downloads/", @@ -6366,12 +6526,11 @@ "queryobject", "sasql", "sql", - "sqlanywhere", "sqlite", "sqlserver", "sqlsrv" ], - "time": "2020-09-12T21:20:41+00:00" + "time": "2020-11-15T18:20:41+00:00" }, { "name": "doctrine/event-manager", @@ -6451,36 +6610,31 @@ }, { "name": "doctrine/instantiator", - "version": "1.3.1", + "version": "1.4.0", "source": { "type": "git", "url": "https://github.com/doctrine/instantiator.git", - "reference": "f350df0268e904597e3bd9c4685c53e0e333feea" + "reference": "d56bf6102915de5702778fe20f2de3b2fe570b5b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/instantiator/zipball/f350df0268e904597e3bd9c4685c53e0e333feea", - "reference": "f350df0268e904597e3bd9c4685c53e0e333feea", + "url": "https://api.github.com/repos/doctrine/instantiator/zipball/d56bf6102915de5702778fe20f2de3b2fe570b5b", + "reference": "d56bf6102915de5702778fe20f2de3b2fe570b5b", "shasum": "" }, "require": { "php": "^7.1 || ^8.0" }, "require-dev": { - "doctrine/coding-standard": "^6.0", + "doctrine/coding-standard": "^8.0", "ext-pdo": "*", "ext-phar": "*", - "phpbench/phpbench": "^0.13", - "phpstan/phpstan-phpunit": "^0.11", - "phpstan/phpstan-shim": "^0.11", - "phpunit/phpunit": "^7.0" + "phpbench/phpbench": "^0.13 || 1.0.0-alpha2", + "phpstan/phpstan": "^0.12", + "phpstan/phpstan-phpunit": "^0.12", + "phpunit/phpunit": "^7.0 || ^8.0 || ^9.0" }, "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.2.x-dev" - } - }, "autoload": { "psr-4": { "Doctrine\\Instantiator\\": "src/Doctrine/Instantiator/" @@ -6494,7 +6648,7 @@ { "name": "Marco Pivetta", "email": "ocramius@gmail.com", - "homepage": "http://ocramius.github.com/" + "homepage": "https://ocramius.github.io/" } ], "description": "A small, lightweight utility to instantiate objects in PHP without invoking their constructors", @@ -6503,7 +6657,7 @@ "constructor", "instantiate" ], - "time": "2020-05-29T17:27:14+00:00" + "time": "2020-11-10T18:47:58+00:00" }, { "name": "facade/flare-client-php", @@ -6562,28 +6716,27 @@ }, { "name": "facade/ignition", - "version": "2.4.1", + "version": "2.5.8", "source": { "type": "git", "url": "https://github.com/facade/ignition.git", - "reference": "9fc6c3d3de5271a1b94cff19dce2c9295abf0ffa" + "reference": "8e907d81244649c5ea746e2ec30c32c5f59df472" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/facade/ignition/zipball/9fc6c3d3de5271a1b94cff19dce2c9295abf0ffa", - "reference": "9fc6c3d3de5271a1b94cff19dce2c9295abf0ffa", + "url": "https://api.github.com/repos/facade/ignition/zipball/8e907d81244649c5ea746e2ec30c32c5f59df472", + "reference": "8e907d81244649c5ea746e2ec30c32c5f59df472", "shasum": "" }, "require": { "ext-json": "*", "ext-mbstring": "*", - "facade/flare-client-php": "^1.0", - "facade/ignition-contracts": "^1.0", + "facade/flare-client-php": "^1.3.7", + "facade/ignition-contracts": "^1.0.2", "filp/whoops": "^2.4", "illuminate/support": "^7.0|^8.0", "monolog/monolog": "^2.0", - "php": "^7.2.5", - "scrivo/highlight.php": "^9.15", + "php": "^7.2.5|^8.0", "symfony/console": "^5.0", "symfony/var-dumper": "^5.0" }, @@ -6630,7 +6783,7 @@ "laravel", "page" ], - "time": "2020-10-14T08:59:59+00:00" + "time": "2020-12-29T09:12:55+00:00" }, { "name": "filp/whoops", @@ -6695,16 +6848,16 @@ }, { "name": "fzaninotto/faker", - "version": "v1.9.1", + "version": "v1.9.2", "source": { "type": "git", "url": "https://github.com/fzaninotto/Faker.git", - "reference": "fc10d778e4b84d5bd315dad194661e091d307c6f" + "reference": "848d8125239d7dbf8ab25cb7f054f1a630e68c2e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/fzaninotto/Faker/zipball/fc10d778e4b84d5bd315dad194661e091d307c6f", - "reference": "fc10d778e4b84d5bd315dad194661e091d307c6f", + "url": "https://api.github.com/repos/fzaninotto/Faker/zipball/848d8125239d7dbf8ab25cb7f054f1a630e68c2e", + "reference": "848d8125239d7dbf8ab25cb7f054f1a630e68c2e", "shasum": "" }, "require": { @@ -6742,7 +6895,7 @@ "fixtures" ], "abandoned": true, - "time": "2019-12-12T13:22:17+00:00" + "time": "2020-12-11T09:56:16+00:00" }, { "name": "hamcrest/hamcrest-php", @@ -6913,26 +7066,27 @@ }, { "name": "laravel/homestead", - "version": "v11.2.4", + "version": "v11.4.0", "source": { "type": "git", "url": "https://github.com/laravel/homestead.git", - "reference": "e20bb5c6edcec632b4776665647a3f6805bb8657" + "reference": "41a628deed9b601ee80689cf3ae0815195b5040f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laravel/homestead/zipball/e20bb5c6edcec632b4776665647a3f6805bb8657", - "reference": "e20bb5c6edcec632b4776665647a3f6805bb8657", + "url": "https://api.github.com/repos/laravel/homestead/zipball/41a628deed9b601ee80689cf3ae0815195b5040f", + "reference": "41a628deed9b601ee80689cf3ae0815195b5040f", "shasum": "" }, "require": { - "php": "^7.1", - "symfony/console": "~3.0||~4.0||~5.0", - "symfony/process": "~3.0||~4.0||~5.0", - "symfony/yaml": "~3.0||~4.0||~5.0" + "php": "^7.4 || ^8.0", + "symfony/console": "~5.1", + "symfony/process": "~5.1", + "symfony/yaml": "~5.1" }, "require-dev": { - "phpunit/phpunit": "^6.0" + "dms/phpunit-arraysubset-asserts": "^0.2.0", + "phpunit/phpunit": "^9" }, "bin": [ "bin/homestead" @@ -6954,34 +7108,37 @@ } ], "description": "A virtual machine for web artisans.", - "time": "2020-10-10T19:45:05+00:00" + "time": "2020-11-24T17:59:52+00:00" }, { "name": "mockery/mockery", - "version": "1.3.3", + "version": "1.4.2", "source": { "type": "git", "url": "https://github.com/mockery/mockery.git", - "reference": "60fa2f67f6e4d3634bb4a45ff3171fa52215800d" + "reference": "20cab678faed06fac225193be281ea0fddb43b93" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/mockery/mockery/zipball/60fa2f67f6e4d3634bb4a45ff3171fa52215800d", - "reference": "60fa2f67f6e4d3634bb4a45ff3171fa52215800d", + "url": "https://api.github.com/repos/mockery/mockery/zipball/20cab678faed06fac225193be281ea0fddb43b93", + "reference": "20cab678faed06fac225193be281ea0fddb43b93", "shasum": "" }, "require": { "hamcrest/hamcrest-php": "^2.0.1", "lib-pcre": ">=7.0", - "php": ">=5.6.0" + "php": "^7.3 || ^8.0" + }, + "conflict": { + "phpunit/phpunit": "<8.0" }, "require-dev": { - "phpunit/phpunit": "^5.7.10|^6.5|^7.5|^8.5|^9.3" + "phpunit/phpunit": "^8.5 || ^9.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.3.x-dev" + "dev-master": "1.4.x-dev" } }, "autoload": { @@ -7019,20 +7176,20 @@ "test double", "testing" ], - "time": "2020-08-11T18:10:21+00:00" + "time": "2020-08-11T18:10:13+00:00" }, { "name": "myclabs/deep-copy", - "version": "1.10.1", + "version": "1.10.2", "source": { "type": "git", "url": "https://github.com/myclabs/DeepCopy.git", - "reference": "969b211f9a51aa1f6c01d1d2aef56d3bd91598e5" + "reference": "776f831124e9c62e1a2c601ecc52e776d8bb7220" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/myclabs/DeepCopy/zipball/969b211f9a51aa1f6c01d1d2aef56d3bd91598e5", - "reference": "969b211f9a51aa1f6c01d1d2aef56d3bd91598e5", + "url": "https://api.github.com/repos/myclabs/DeepCopy/zipball/776f831124e9c62e1a2c601ecc52e776d8bb7220", + "reference": "776f831124e9c62e1a2c601ecc52e776d8bb7220", "shasum": "" }, "require": { @@ -7067,39 +7224,39 @@ "object", "object graph" ], - "time": "2020-06-29T13:22:24+00:00" + "time": "2020-11-13T09:40:50+00:00" }, { "name": "nunomaduro/collision", - "version": "v4.3.0", + "version": "v5.2.0", "source": { "type": "git", "url": "https://github.com/nunomaduro/collision.git", - "reference": "7c125dc2463f3e144ddc7e05e63077109508c94e" + "reference": "aca954fd03414ba0dd85d7d8e42ba9b251893d1f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/nunomaduro/collision/zipball/7c125dc2463f3e144ddc7e05e63077109508c94e", - "reference": "7c125dc2463f3e144ddc7e05e63077109508c94e", + "url": "https://api.github.com/repos/nunomaduro/collision/zipball/aca954fd03414ba0dd85d7d8e42ba9b251893d1f", + "reference": "aca954fd03414ba0dd85d7d8e42ba9b251893d1f", "shasum": "" }, "require": { "facade/ignition-contracts": "^1.0", - "filp/whoops": "^2.4", - "php": "^7.2.5 || ^8.0", + "filp/whoops": "^2.7.2", + "php": "^7.3 || ^8.0", "symfony/console": "^5.0" }, "require-dev": { - "facade/ignition": "^2.0", - "fideloper/proxy": "^4.2", - "friendsofphp/php-cs-fixer": "^2.16", - "fruitcake/laravel-cors": "^1.0", - "laravel/framework": "^7.0", - "laravel/tinker": "^2.0", - "nunomaduro/larastan": "^0.6", - "orchestra/testbench": "^5.0", - "phpstan/phpstan": "^0.12.3", - "phpunit/phpunit": "^8.5.1 || ^9.0" + "brianium/paratest": "^6.1", + "fideloper/proxy": "^4.4.1", + "friendsofphp/php-cs-fixer": "^2.17.3", + "fruitcake/laravel-cors": "^2.0.3", + "laravel/framework": "^9.0", + "nunomaduro/larastan": "^0.6.2", + "nunomaduro/mock-final-classes": "^1.0", + "orchestra/testbench": "^7.0", + "phpstan/phpstan": "^0.12.64", + "phpunit/phpunit": "^9.5.0" }, "type": "library", "extra": { @@ -7137,32 +7294,33 @@ "php", "symfony" ], - "time": "2020-10-29T15:12:23+00:00" + "time": "2021-01-13T10:00:08+00:00" }, { "name": "phar-io/manifest", - "version": "1.0.3", + "version": "2.0.1", "source": { "type": "git", "url": "https://github.com/phar-io/manifest.git", - "reference": "7761fcacf03b4d4f16e7ccb606d4879ca431fcf4" + "reference": "85265efd3af7ba3ca4b2a2c34dbfc5788dd29133" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phar-io/manifest/zipball/7761fcacf03b4d4f16e7ccb606d4879ca431fcf4", - "reference": "7761fcacf03b4d4f16e7ccb606d4879ca431fcf4", + "url": "https://api.github.com/repos/phar-io/manifest/zipball/85265efd3af7ba3ca4b2a2c34dbfc5788dd29133", + "reference": "85265efd3af7ba3ca4b2a2c34dbfc5788dd29133", "shasum": "" }, "require": { "ext-dom": "*", "ext-phar": "*", - "phar-io/version": "^2.0", - "php": "^5.6 || ^7.0" + "ext-xmlwriter": "*", + "phar-io/version": "^3.0.1", + "php": "^7.2 || ^8.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0.x-dev" + "dev-master": "2.0.x-dev" } }, "autoload": { @@ -7192,24 +7350,24 @@ } ], "description": "Component for reading phar.io manifest information from a PHP Archive (PHAR)", - "time": "2018-07-08T19:23:20+00:00" + "time": "2020-06-27T14:33:11+00:00" }, { "name": "phar-io/version", - "version": "2.0.1", + "version": "3.0.4", "source": { "type": "git", "url": "https://github.com/phar-io/version.git", - "reference": "45a2ec53a73c70ce41d55cedef9063630abaf1b6" + "reference": "e4782611070e50613683d2b9a57730e9a3ba5451" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phar-io/version/zipball/45a2ec53a73c70ce41d55cedef9063630abaf1b6", - "reference": "45a2ec53a73c70ce41d55cedef9063630abaf1b6", + "url": "https://api.github.com/repos/phar-io/version/zipball/e4782611070e50613683d2b9a57730e9a3ba5451", + "reference": "e4782611070e50613683d2b9a57730e9a3ba5451", "shasum": "" }, "require": { - "php": "^5.6 || ^7.0" + "php": "^7.2 || ^8.0" }, "type": "library", "autoload": { @@ -7239,7 +7397,7 @@ } ], "description": "Library for handling version information and constraints", - "time": "2018-07-08T19:19:57+00:00" + "time": "2020-12-13T23:18:30+00:00" }, { "name": "phpdocumentor/reflection-common", @@ -7389,16 +7547,16 @@ }, { "name": "phpspec/prophecy", - "version": "1.12.1", + "version": "1.12.2", "source": { "type": "git", "url": "https://github.com/phpspec/prophecy.git", - "reference": "8ce87516be71aae9b956f81906aaf0338e0d8a2d" + "reference": "245710e971a030f42e08f4912863805570f23d39" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpspec/prophecy/zipball/8ce87516be71aae9b956f81906aaf0338e0d8a2d", - "reference": "8ce87516be71aae9b956f81906aaf0338e0d8a2d", + "url": "https://api.github.com/repos/phpspec/prophecy/zipball/245710e971a030f42e08f4912863805570f23d39", + "reference": "245710e971a030f42e08f4912863805570f23d39", "shasum": "" }, "require": { @@ -7410,7 +7568,7 @@ }, "require-dev": { "phpspec/phpspec": "^6.0", - "phpunit/phpunit": "^8.0 || ^9.0 <9.3" + "phpunit/phpunit": "^8.0 || ^9.0" }, "type": "library", "extra": { @@ -7448,44 +7606,48 @@ "spy", "stub" ], - "time": "2020-09-29T09:10:42+00:00" + "time": "2020-12-19T10:15:11+00:00" }, { "name": "phpunit/php-code-coverage", - "version": "7.0.10", + "version": "9.2.5", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-code-coverage.git", - "reference": "f1884187926fbb755a9aaf0b3836ad3165b478bf" + "reference": "f3e026641cc91909d421802dd3ac7827ebfd97e1" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/f1884187926fbb755a9aaf0b3836ad3165b478bf", - "reference": "f1884187926fbb755a9aaf0b3836ad3165b478bf", + "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/f3e026641cc91909d421802dd3ac7827ebfd97e1", + "reference": "f3e026641cc91909d421802dd3ac7827ebfd97e1", "shasum": "" }, "require": { "ext-dom": "*", + "ext-libxml": "*", "ext-xmlwriter": "*", - "php": "^7.2", - "phpunit/php-file-iterator": "^2.0.2", - "phpunit/php-text-template": "^1.2.1", - "phpunit/php-token-stream": "^3.1.1", - "sebastian/code-unit-reverse-lookup": "^1.0.1", - "sebastian/environment": "^4.2.2", - "sebastian/version": "^2.0.1", - "theseer/tokenizer": "^1.1.3" + "nikic/php-parser": "^4.10.2", + "php": ">=7.3", + "phpunit/php-file-iterator": "^3.0.3", + "phpunit/php-text-template": "^2.0.2", + "sebastian/code-unit-reverse-lookup": "^2.0.2", + "sebastian/complexity": "^2.0", + "sebastian/environment": "^5.1.2", + "sebastian/lines-of-code": "^1.0.3", + "sebastian/version": "^3.0.1", + "theseer/tokenizer": "^1.2.0" }, "require-dev": { - "phpunit/phpunit": "^8.2.2" + "phpunit/phpunit": "^9.3" }, "suggest": { - "ext-xdebug": "^2.7.2" + "ext-pcov": "*", + "ext-xdebug": "*" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "7.0-dev" + "dev-master": "9.2-dev" } }, "autoload": { @@ -7511,32 +7673,32 @@ "testing", "xunit" ], - "time": "2019-11-20T13:55:58+00:00" + "time": "2020-11-28T06:44:49+00:00" }, { "name": "phpunit/php-file-iterator", - "version": "2.0.2", + "version": "3.0.5", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-file-iterator.git", - "reference": "050bedf145a257b1ff02746c31894800e5122946" + "reference": "aa4be8575f26070b100fccb67faabb28f21f66f8" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/050bedf145a257b1ff02746c31894800e5122946", - "reference": "050bedf145a257b1ff02746c31894800e5122946", + "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/aa4be8575f26070b100fccb67faabb28f21f66f8", + "reference": "aa4be8575f26070b100fccb67faabb28f21f66f8", "shasum": "" }, "require": { - "php": "^7.1" + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^7.1" + "phpunit/phpunit": "^9.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "2.0.x-dev" + "dev-master": "3.0-dev" } }, "autoload": { @@ -7561,26 +7723,38 @@ "filesystem", "iterator" ], - "time": "2018-09-13T20:33:42+00:00" + "time": "2020-09-28T05:57:25+00:00" }, { - "name": "phpunit/php-text-template", - "version": "1.2.1", + "name": "phpunit/php-invoker", + "version": "3.1.1", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/php-text-template.git", - "reference": "31f8b717e51d9a2afca6c9f046f5d69fc27c8686" + "url": "https://github.com/sebastianbergmann/php-invoker.git", + "reference": "5a10147d0aaf65b58940a0b72f71c9ac0423cc67" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-text-template/zipball/31f8b717e51d9a2afca6c9f046f5d69fc27c8686", - "reference": "31f8b717e51d9a2afca6c9f046f5d69fc27c8686", + "url": "https://api.github.com/repos/sebastianbergmann/php-invoker/zipball/5a10147d0aaf65b58940a0b72f71c9ac0423cc67", + "reference": "5a10147d0aaf65b58940a0b72f71c9ac0423cc67", "shasum": "" }, "require": { - "php": ">=5.3.3" + "php": ">=7.3" + }, + "require-dev": { + "ext-pcntl": "*", + "phpunit/phpunit": "^9.3" + }, + "suggest": { + "ext-pcntl": "*" }, "type": "library", + "extra": { + "branch-alias": { + "dev-master": "3.1-dev" + } + }, "autoload": { "classmap": [ "src/" @@ -7597,37 +7771,37 @@ "role": "lead" } ], - "description": "Simple template engine.", - "homepage": "https://github.com/sebastianbergmann/php-text-template/", + "description": "Invoke callables with a timeout", + "homepage": "https://github.com/sebastianbergmann/php-invoker/", "keywords": [ - "template" + "process" ], - "time": "2015-06-21T13:50:34+00:00" + "time": "2020-09-28T05:58:55+00:00" }, { - "name": "phpunit/php-timer", - "version": "2.1.2", + "name": "phpunit/php-text-template", + "version": "2.0.4", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/php-timer.git", - "reference": "1038454804406b0b5f5f520358e78c1c2f71501e" + "url": "https://github.com/sebastianbergmann/php-text-template.git", + "reference": "5da5f67fc95621df9ff4c4e5a84d6a8a2acf7c28" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-timer/zipball/1038454804406b0b5f5f520358e78c1c2f71501e", - "reference": "1038454804406b0b5f5f520358e78c1c2f71501e", + "url": "https://api.github.com/repos/sebastianbergmann/php-text-template/zipball/5da5f67fc95621df9ff4c4e5a84d6a8a2acf7c28", + "reference": "5da5f67fc95621df9ff4c4e5a84d6a8a2acf7c28", "shasum": "" }, "require": { - "php": "^7.1" + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^7.0" + "phpunit/phpunit": "^9.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "2.1-dev" + "dev-master": "2.0-dev" } }, "autoload": { @@ -7646,38 +7820,37 @@ "role": "lead" } ], - "description": "Utility class for timing", - "homepage": "https://github.com/sebastianbergmann/php-timer/", + "description": "Simple template engine.", + "homepage": "https://github.com/sebastianbergmann/php-text-template/", "keywords": [ - "timer" + "template" ], - "time": "2019-06-07T04:22:29+00:00" + "time": "2020-10-26T05:33:50+00:00" }, { - "name": "phpunit/php-token-stream", - "version": "3.1.1", + "name": "phpunit/php-timer", + "version": "5.0.3", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/php-token-stream.git", - "reference": "995192df77f63a59e47f025390d2d1fdf8f425ff" + "url": "https://github.com/sebastianbergmann/php-timer.git", + "reference": "5a63ce20ed1b5bf577850e2c4e87f4aa902afbd2" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-token-stream/zipball/995192df77f63a59e47f025390d2d1fdf8f425ff", - "reference": "995192df77f63a59e47f025390d2d1fdf8f425ff", + "url": "https://api.github.com/repos/sebastianbergmann/php-timer/zipball/5a63ce20ed1b5bf577850e2c4e87f4aa902afbd2", + "reference": "5a63ce20ed1b5bf577850e2c4e87f4aa902afbd2", "shasum": "" }, "require": { - "ext-tokenizer": "*", - "php": "^7.1" + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^7.0" + "phpunit/phpunit": "^9.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.1-dev" + "dev-master": "5.0-dev" } }, "autoload": { @@ -7692,65 +7865,68 @@ "authors": [ { "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" + "email": "sebastian@phpunit.de", + "role": "lead" } ], - "description": "Wrapper around PHP's tokenizer extension.", - "homepage": "https://github.com/sebastianbergmann/php-token-stream/", + "description": "Utility class for timing", + "homepage": "https://github.com/sebastianbergmann/php-timer/", "keywords": [ - "tokenizer" + "timer" ], - "abandoned": true, - "time": "2019-09-17T06:23:10+00:00" + "time": "2020-10-26T13:16:10+00:00" }, { "name": "phpunit/phpunit", - "version": "8.5.8", + "version": "9.5.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "34c18baa6a44f1d1fbf0338907139e9dce95b997" + "reference": "8e16c225d57c3d6808014df6b1dd7598d0a5bbbe" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/34c18baa6a44f1d1fbf0338907139e9dce95b997", - "reference": "34c18baa6a44f1d1fbf0338907139e9dce95b997", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/8e16c225d57c3d6808014df6b1dd7598d0a5bbbe", + "reference": "8e16c225d57c3d6808014df6b1dd7598d0a5bbbe", "shasum": "" }, "require": { - "doctrine/instantiator": "^1.2.0", + "doctrine/instantiator": "^1.3.1", "ext-dom": "*", "ext-json": "*", "ext-libxml": "*", "ext-mbstring": "*", "ext-xml": "*", "ext-xmlwriter": "*", - "myclabs/deep-copy": "^1.9.1", - "phar-io/manifest": "^1.0.3", - "phar-io/version": "^2.0.1", - "php": "^7.2", - "phpspec/prophecy": "^1.8.1", - "phpunit/php-code-coverage": "^7.0.7", - "phpunit/php-file-iterator": "^2.0.2", - "phpunit/php-text-template": "^1.2.1", - "phpunit/php-timer": "^2.1.2", - "sebastian/comparator": "^3.0.2", - "sebastian/diff": "^3.0.2", - "sebastian/environment": "^4.2.2", - "sebastian/exporter": "^3.1.1", - "sebastian/global-state": "^3.0.0", - "sebastian/object-enumerator": "^3.0.3", - "sebastian/resource-operations": "^2.0.1", - "sebastian/type": "^1.1.3", - "sebastian/version": "^2.0.1" + "myclabs/deep-copy": "^1.10.1", + "phar-io/manifest": "^2.0.1", + "phar-io/version": "^3.0.2", + "php": ">=7.3", + "phpspec/prophecy": "^1.12.1", + "phpunit/php-code-coverage": "^9.2.3", + "phpunit/php-file-iterator": "^3.0.5", + "phpunit/php-invoker": "^3.1.1", + "phpunit/php-text-template": "^2.0.3", + "phpunit/php-timer": "^5.0.2", + "sebastian/cli-parser": "^1.0.1", + "sebastian/code-unit": "^1.0.6", + "sebastian/comparator": "^4.0.5", + "sebastian/diff": "^4.0.3", + "sebastian/environment": "^5.1.3", + "sebastian/exporter": "^4.0.3", + "sebastian/global-state": "^5.0.1", + "sebastian/object-enumerator": "^4.0.3", + "sebastian/resource-operations": "^3.0.3", + "sebastian/type": "^2.3", + "sebastian/version": "^3.0.2" }, "require-dev": { - "ext-pdo": "*" + "ext-pdo": "*", + "phpspec/prophecy-phpunit": "^2.0.1" }, "suggest": { "ext-soap": "*", - "ext-xdebug": "*", - "phpunit/php-invoker": "^2.0.0" + "ext-xdebug": "*" }, "bin": [ "phpunit" @@ -7758,12 +7934,15 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "8.5-dev" + "dev-master": "9.5-dev" } }, "autoload": { "classmap": [ "src/" + ], + "files": [ + "src/Framework/Assert/Functions.php" ] }, "notification-url": "https://packagist.org/downloads/", @@ -7784,44 +7963,37 @@ "testing", "xunit" ], - "time": "2020-06-22T07:06:58+00:00" + "time": "2020-12-04T05:05:53+00:00" }, { - "name": "scrivo/highlight.php", - "version": "v9.18.1.4", + "name": "sebastian/cli-parser", + "version": "1.0.1", "source": { "type": "git", - "url": "https://github.com/scrivo/highlight.php.git", - "reference": "ee8007a215a27cb9c078e0328fb5de901d74ef9b" + "url": "https://github.com/sebastianbergmann/cli-parser.git", + "reference": "442e7c7e687e42adc03470c7b668bc4b2402c0b2" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/scrivo/highlight.php/zipball/ee8007a215a27cb9c078e0328fb5de901d74ef9b", - "reference": "ee8007a215a27cb9c078e0328fb5de901d74ef9b", + "url": "https://api.github.com/repos/sebastianbergmann/cli-parser/zipball/442e7c7e687e42adc03470c7b668bc4b2402c0b2", + "reference": "442e7c7e687e42adc03470c7b668bc4b2402c0b2", "shasum": "" }, "require": { - "ext-json": "*", - "ext-mbstring": "*", - "php": ">=5.4" + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^4.8|^5.7", - "sabberworm/php-css-parser": "^8.3", - "symfony/finder": "^2.8|^3.4", - "symfony/var-dumper": "^2.8|^3.4" - }, - "suggest": { - "ext-dom": "Needed to make use of the features in the utilities namespace" + "phpunit/phpunit": "^9.3" }, "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0-dev" + } + }, "autoload": { - "psr-0": { - "Highlight\\": "", - "HighlightUtilities\\": "" - }, - "files": [ - "HighlightUtilities/functions.php" + "classmap": [ + "src/" ] }, "notification-url": "https://packagist.org/downloads/", @@ -7830,55 +8002,85 @@ ], "authors": [ { - "name": "Geert Bergman", - "homepage": "http://www.scrivo.org/", - "role": "Project Author" - }, - { - "name": "Vladimir Jimenez", - "homepage": "https://allejo.io", - "role": "Maintainer" - }, - { - "name": "Martin Folkers", - "homepage": "https://twobrain.io", - "role": "Contributor" + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" } ], - "description": "Server side syntax highlighter that supports 185 languages. It's a PHP port of highlight.js", - "keywords": [ - "code", - "highlight", - "highlight.js", - "highlight.php", - "syntax" + "description": "Library for parsing CLI options", + "homepage": "https://github.com/sebastianbergmann/cli-parser", + "time": "2020-09-28T06:08:49+00:00" + }, + { + "name": "sebastian/code-unit", + "version": "1.0.8", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/code-unit.git", + "reference": "1fc9f64c0927627ef78ba436c9b17d967e68e120" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/code-unit/zipball/1fc9f64c0927627ef78ba436c9b17d967e68e120", + "reference": "1fc9f64c0927627ef78ba436c9b17d967e68e120", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" ], - "time": "2020-11-01T04:06:53+00:00" + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Collection of value objects that represent the PHP code units", + "homepage": "https://github.com/sebastianbergmann/code-unit", + "time": "2020-10-26T13:08:54+00:00" }, { "name": "sebastian/code-unit-reverse-lookup", - "version": "1.0.1", + "version": "2.0.3", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/code-unit-reverse-lookup.git", - "reference": "4419fcdb5eabb9caa61a27c7a1db532a6b55dd18" + "reference": "ac91f01ccec49fb77bdc6fd1e548bc70f7faa3e5" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/code-unit-reverse-lookup/zipball/4419fcdb5eabb9caa61a27c7a1db532a6b55dd18", - "reference": "4419fcdb5eabb9caa61a27c7a1db532a6b55dd18", + "url": "https://api.github.com/repos/sebastianbergmann/code-unit-reverse-lookup/zipball/ac91f01ccec49fb77bdc6fd1e548bc70f7faa3e5", + "reference": "ac91f01ccec49fb77bdc6fd1e548bc70f7faa3e5", "shasum": "" }, "require": { - "php": "^5.6 || ^7.0" + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^5.7 || ^6.0" + "phpunit/phpunit": "^9.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0.x-dev" + "dev-master": "2.0-dev" } }, "autoload": { @@ -7898,34 +8100,34 @@ ], "description": "Looks up which function or method a line of code belongs to", "homepage": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/", - "time": "2017-03-04T06:30:41+00:00" + "time": "2020-09-28T05:30:19+00:00" }, { "name": "sebastian/comparator", - "version": "3.0.2", + "version": "4.0.6", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/comparator.git", - "reference": "5de4fc177adf9bce8df98d8d141a7559d7ccf6da" + "reference": "55f4261989e546dc112258c7a75935a81a7ce382" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/5de4fc177adf9bce8df98d8d141a7559d7ccf6da", - "reference": "5de4fc177adf9bce8df98d8d141a7559d7ccf6da", + "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/55f4261989e546dc112258c7a75935a81a7ce382", + "reference": "55f4261989e546dc112258c7a75935a81a7ce382", "shasum": "" }, "require": { - "php": "^7.1", - "sebastian/diff": "^3.0", - "sebastian/exporter": "^3.1" + "php": ">=7.3", + "sebastian/diff": "^4.0", + "sebastian/exporter": "^4.0" }, "require-dev": { - "phpunit/phpunit": "^7.1" + "phpunit/phpunit": "^9.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.0-dev" + "dev-master": "4.0-dev" } }, "autoload": { @@ -7938,6 +8140,10 @@ "BSD-3-Clause" ], "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de" + }, { "name": "Jeff Welch", "email": "whatthejeff@gmail.com" @@ -7949,10 +8155,6 @@ { "name": "Bernhard Schussek", "email": "bschussek@2bepublished.at" - }, - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" } ], "description": "Provides the functionality to compare PHP values for equality", @@ -7962,33 +8164,80 @@ "compare", "equality" ], - "time": "2018-07-12T15:12:46+00:00" + "time": "2020-10-26T15:49:45+00:00" + }, + { + "name": "sebastian/complexity", + "version": "2.0.2", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/complexity.git", + "reference": "739b35e53379900cc9ac327b2147867b8b6efd88" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/complexity/zipball/739b35e53379900cc9ac327b2147867b8b6efd88", + "reference": "739b35e53379900cc9ac327b2147867b8b6efd88", + "shasum": "" + }, + "require": { + "nikic/php-parser": "^4.7", + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Library for calculating the complexity of PHP code units", + "homepage": "https://github.com/sebastianbergmann/complexity", + "time": "2020-10-26T15:52:27+00:00" }, { "name": "sebastian/diff", - "version": "3.0.2", + "version": "4.0.4", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/diff.git", - "reference": "720fcc7e9b5cf384ea68d9d930d480907a0c1a29" + "reference": "3461e3fccc7cfdfc2720be910d3bd73c69be590d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/720fcc7e9b5cf384ea68d9d930d480907a0c1a29", - "reference": "720fcc7e9b5cf384ea68d9d930d480907a0c1a29", + "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/3461e3fccc7cfdfc2720be910d3bd73c69be590d", + "reference": "3461e3fccc7cfdfc2720be910d3bd73c69be590d", "shasum": "" }, "require": { - "php": "^7.1" + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^7.5 || ^8.0", - "symfony/process": "^2 || ^3.3 || ^4" + "phpunit/phpunit": "^9.3", + "symfony/process": "^4.2 || ^5" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.0-dev" + "dev-master": "4.0-dev" } }, "autoload": { @@ -8001,13 +8250,13 @@ "BSD-3-Clause" ], "authors": [ - { - "name": "Kore Nordmann", - "email": "mail@kore-nordmann.de" - }, { "name": "Sebastian Bergmann", "email": "sebastian@phpunit.de" + }, + { + "name": "Kore Nordmann", + "email": "mail@kore-nordmann.de" } ], "description": "Diff implementation", @@ -8018,27 +8267,27 @@ "unidiff", "unified diff" ], - "time": "2019-02-04T06:01:07+00:00" + "time": "2020-10-26T13:10:38+00:00" }, { "name": "sebastian/environment", - "version": "4.2.3", + "version": "5.1.3", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/environment.git", - "reference": "464c90d7bdf5ad4e8a6aea15c091fec0603d4368" + "reference": "388b6ced16caa751030f6a69e588299fa09200ac" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/464c90d7bdf5ad4e8a6aea15c091fec0603d4368", - "reference": "464c90d7bdf5ad4e8a6aea15c091fec0603d4368", + "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/388b6ced16caa751030f6a69e588299fa09200ac", + "reference": "388b6ced16caa751030f6a69e588299fa09200ac", "shasum": "" }, "require": { - "php": "^7.1" + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^7.5" + "phpunit/phpunit": "^9.3" }, "suggest": { "ext-posix": "*" @@ -8046,7 +8295,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "4.2-dev" + "dev-master": "5.1-dev" } }, "autoload": { @@ -8071,34 +8320,34 @@ "environment", "hhvm" ], - "time": "2019-11-20T08:46:58+00:00" + "time": "2020-09-28T05:52:38+00:00" }, { "name": "sebastian/exporter", - "version": "3.1.2", + "version": "4.0.3", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/exporter.git", - "reference": "68609e1261d215ea5b21b7987539cbfbe156ec3e" + "reference": "d89cc98761b8cb5a1a235a6b703ae50d34080e65" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/68609e1261d215ea5b21b7987539cbfbe156ec3e", - "reference": "68609e1261d215ea5b21b7987539cbfbe156ec3e", + "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/d89cc98761b8cb5a1a235a6b703ae50d34080e65", + "reference": "d89cc98761b8cb5a1a235a6b703ae50d34080e65", "shasum": "" }, "require": { - "php": "^7.0", - "sebastian/recursion-context": "^3.0" + "php": ">=7.3", + "sebastian/recursion-context": "^4.0" }, "require-dev": { "ext-mbstring": "*", - "phpunit/phpunit": "^6.0" + "phpunit/phpunit": "^9.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.1.x-dev" + "dev-master": "4.0-dev" } }, "autoload": { @@ -8138,30 +8387,30 @@ "export", "exporter" ], - "time": "2019-09-14T09:02:43+00:00" + "time": "2020-09-28T05:24:23+00:00" }, { "name": "sebastian/global-state", - "version": "3.0.0", + "version": "5.0.2", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/global-state.git", - "reference": "edf8a461cf1d4005f19fb0b6b8b95a9f7fa0adc4" + "reference": "a90ccbddffa067b51f574dea6eb25d5680839455" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/edf8a461cf1d4005f19fb0b6b8b95a9f7fa0adc4", - "reference": "edf8a461cf1d4005f19fb0b6b8b95a9f7fa0adc4", + "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/a90ccbddffa067b51f574dea6eb25d5680839455", + "reference": "a90ccbddffa067b51f574dea6eb25d5680839455", "shasum": "" }, "require": { - "php": "^7.2", - "sebastian/object-reflector": "^1.1.1", - "sebastian/recursion-context": "^3.0" + "php": ">=7.3", + "sebastian/object-reflector": "^2.0", + "sebastian/recursion-context": "^4.0" }, "require-dev": { "ext-dom": "*", - "phpunit/phpunit": "^8.0" + "phpunit/phpunit": "^9.3" }, "suggest": { "ext-uopz": "*" @@ -8169,7 +8418,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "3.0-dev" + "dev-master": "5.0-dev" } }, "autoload": { @@ -8192,34 +8441,81 @@ "keywords": [ "global state" ], - "time": "2019-02-01T05:30:01+00:00" + "time": "2020-10-26T15:55:19+00:00" + }, + { + "name": "sebastian/lines-of-code", + "version": "1.0.3", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/lines-of-code.git", + "reference": "c1c2e997aa3146983ed888ad08b15470a2e22ecc" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/lines-of-code/zipball/c1c2e997aa3146983ed888ad08b15470a2e22ecc", + "reference": "c1c2e997aa3146983ed888ad08b15470a2e22ecc", + "shasum": "" + }, + "require": { + "nikic/php-parser": "^4.6", + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Library for counting the lines of code in PHP source code", + "homepage": "https://github.com/sebastianbergmann/lines-of-code", + "time": "2020-11-28T06:42:11+00:00" }, { "name": "sebastian/object-enumerator", - "version": "3.0.3", + "version": "4.0.4", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/object-enumerator.git", - "reference": "7cfd9e65d11ffb5af41198476395774d4c8a84c5" + "reference": "5c9eeac41b290a3712d88851518825ad78f45c71" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/object-enumerator/zipball/7cfd9e65d11ffb5af41198476395774d4c8a84c5", - "reference": "7cfd9e65d11ffb5af41198476395774d4c8a84c5", + "url": "https://api.github.com/repos/sebastianbergmann/object-enumerator/zipball/5c9eeac41b290a3712d88851518825ad78f45c71", + "reference": "5c9eeac41b290a3712d88851518825ad78f45c71", "shasum": "" }, "require": { - "php": "^7.0", - "sebastian/object-reflector": "^1.1.1", - "sebastian/recursion-context": "^3.0" + "php": ">=7.3", + "sebastian/object-reflector": "^2.0", + "sebastian/recursion-context": "^4.0" }, "require-dev": { - "phpunit/phpunit": "^6.0" + "phpunit/phpunit": "^9.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.0.x-dev" + "dev-master": "4.0-dev" } }, "autoload": { @@ -8239,32 +8535,32 @@ ], "description": "Traverses array structures and object graphs to enumerate all referenced objects", "homepage": "https://github.com/sebastianbergmann/object-enumerator/", - "time": "2017-08-03T12:35:26+00:00" + "time": "2020-10-26T13:12:34+00:00" }, { "name": "sebastian/object-reflector", - "version": "1.1.1", + "version": "2.0.4", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/object-reflector.git", - "reference": "773f97c67f28de00d397be301821b06708fca0be" + "reference": "b4f479ebdbf63ac605d183ece17d8d7fe49c15c7" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/object-reflector/zipball/773f97c67f28de00d397be301821b06708fca0be", - "reference": "773f97c67f28de00d397be301821b06708fca0be", + "url": "https://api.github.com/repos/sebastianbergmann/object-reflector/zipball/b4f479ebdbf63ac605d183ece17d8d7fe49c15c7", + "reference": "b4f479ebdbf63ac605d183ece17d8d7fe49c15c7", "shasum": "" }, "require": { - "php": "^7.0" + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^6.0" + "phpunit/phpunit": "^9.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.1-dev" + "dev-master": "2.0-dev" } }, "autoload": { @@ -8284,32 +8580,32 @@ ], "description": "Allows reflection of object attributes, including inherited and non-public ones", "homepage": "https://github.com/sebastianbergmann/object-reflector/", - "time": "2017-03-29T09:07:27+00:00" + "time": "2020-10-26T13:14:26+00:00" }, { "name": "sebastian/recursion-context", - "version": "3.0.0", + "version": "4.0.4", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/recursion-context.git", - "reference": "5b0cd723502bac3b006cbf3dbf7a1e3fcefe4fa8" + "reference": "cd9d8cf3c5804de4341c283ed787f099f5506172" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/recursion-context/zipball/5b0cd723502bac3b006cbf3dbf7a1e3fcefe4fa8", - "reference": "5b0cd723502bac3b006cbf3dbf7a1e3fcefe4fa8", + "url": "https://api.github.com/repos/sebastianbergmann/recursion-context/zipball/cd9d8cf3c5804de4341c283ed787f099f5506172", + "reference": "cd9d8cf3c5804de4341c283ed787f099f5506172", "shasum": "" }, "require": { - "php": "^7.0" + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^6.0" + "phpunit/phpunit": "^9.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.0.x-dev" + "dev-master": "4.0-dev" } }, "autoload": { @@ -8322,14 +8618,14 @@ "BSD-3-Clause" ], "authors": [ - { - "name": "Jeff Welch", - "email": "whatthejeff@gmail.com" - }, { "name": "Sebastian Bergmann", "email": "sebastian@phpunit.de" }, + { + "name": "Jeff Welch", + "email": "whatthejeff@gmail.com" + }, { "name": "Adam Harvey", "email": "aharvey@php.net" @@ -8337,29 +8633,32 @@ ], "description": "Provides functionality to recursively process PHP variables", "homepage": "http://www.github.com/sebastianbergmann/recursion-context", - "time": "2017-03-03T06:23:57+00:00" + "time": "2020-10-26T13:17:30+00:00" }, { "name": "sebastian/resource-operations", - "version": "2.0.1", + "version": "3.0.3", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/resource-operations.git", - "reference": "4d7a795d35b889bf80a0cc04e08d77cedfa917a9" + "reference": "0f4443cb3a1d92ce809899753bc0d5d5a8dd19a8" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/resource-operations/zipball/4d7a795d35b889bf80a0cc04e08d77cedfa917a9", - "reference": "4d7a795d35b889bf80a0cc04e08d77cedfa917a9", + "url": "https://api.github.com/repos/sebastianbergmann/resource-operations/zipball/0f4443cb3a1d92ce809899753bc0d5d5a8dd19a8", + "reference": "0f4443cb3a1d92ce809899753bc0d5d5a8dd19a8", "shasum": "" }, "require": { - "php": "^7.1" + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "2.0-dev" + "dev-master": "3.0-dev" } }, "autoload": { @@ -8379,32 +8678,32 @@ ], "description": "Provides a list of PHP built-in functions that operate on resources", "homepage": "https://www.github.com/sebastianbergmann/resource-operations", - "time": "2018-10-04T04:07:39+00:00" + "time": "2020-09-28T06:45:17+00:00" }, { "name": "sebastian/type", - "version": "1.1.3", + "version": "2.3.1", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/type.git", - "reference": "3aaaa15fa71d27650d62a948be022fe3b48541a3" + "reference": "81cd61ab7bbf2de744aba0ea61fae32f721df3d2" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/type/zipball/3aaaa15fa71d27650d62a948be022fe3b48541a3", - "reference": "3aaaa15fa71d27650d62a948be022fe3b48541a3", + "url": "https://api.github.com/repos/sebastianbergmann/type/zipball/81cd61ab7bbf2de744aba0ea61fae32f721df3d2", + "reference": "81cd61ab7bbf2de744aba0ea61fae32f721df3d2", "shasum": "" }, "require": { - "php": "^7.2" + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^8.2" + "phpunit/phpunit": "^9.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.1-dev" + "dev-master": "2.3-dev" } }, "autoload": { @@ -8425,29 +8724,29 @@ ], "description": "Collection of value objects that represent the types of the PHP type system", "homepage": "https://github.com/sebastianbergmann/type", - "time": "2019-07-02T08:10:15+00:00" + "time": "2020-10-26T13:18:59+00:00" }, { "name": "sebastian/version", - "version": "2.0.1", + "version": "3.0.2", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/version.git", - "reference": "99732be0ddb3361e16ad77b68ba41efc8e979019" + "reference": "c6c1022351a901512170118436c764e473f6de8c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/version/zipball/99732be0ddb3361e16ad77b68ba41efc8e979019", - "reference": "99732be0ddb3361e16ad77b68ba41efc8e979019", + "url": "https://api.github.com/repos/sebastianbergmann/version/zipball/c6c1022351a901512170118436c764e473f6de8c", + "reference": "c6c1022351a901512170118436c764e473f6de8c", "shasum": "" }, "require": { - "php": ">=5.6" + "php": ">=7.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "2.0.x-dev" + "dev-master": "3.0-dev" } }, "autoload": { @@ -8468,7 +8767,7 @@ ], "description": "Library that helps with managing the version number of Git-hosted PHP projects", "homepage": "https://github.com/sebastianbergmann/version", - "time": "2016-10-03T07:35:21+00:00" + "time": "2020-09-28T06:39:44+00:00" }, { "name": "seld/jsonlint", @@ -8610,16 +8909,16 @@ }, { "name": "symfony/yaml", - "version": "v5.1.8", + "version": "v5.2.1", "source": { "type": "git", "url": "https://github.com/symfony/yaml.git", - "reference": "f284e032c3cefefb9943792132251b79a6127ca6" + "reference": "290ea5e03b8cf9b42c783163123f54441fb06939" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/yaml/zipball/f284e032c3cefefb9943792132251b79a6127ca6", - "reference": "f284e032c3cefefb9943792132251b79a6127ca6", + "url": "https://api.github.com/repos/symfony/yaml/zipball/290ea5e03b8cf9b42c783163123f54441fb06939", + "reference": "290ea5e03b8cf9b42c783163123f54441fb06939", "shasum": "" }, "require": { @@ -8664,7 +8963,7 @@ ], "description": "Symfony Yaml Component", "homepage": "https://symfony.com", - "time": "2020-10-24T12:03:25+00:00" + "time": "2020-12-08T17:02:38+00:00" }, { "name": "theseer/tokenizer", @@ -8705,55 +9004,6 @@ ], "description": "A small library for converting tokenized PHP source code into XML and potentially other formats", "time": "2020-07-12T23:59:07+00:00" - }, - { - "name": "webmozart/assert", - "version": "1.9.1", - "source": { - "type": "git", - "url": "https://github.com/webmozart/assert.git", - "reference": "bafc69caeb4d49c39fd0779086c03a3738cbb389" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/webmozart/assert/zipball/bafc69caeb4d49c39fd0779086c03a3738cbb389", - "reference": "bafc69caeb4d49c39fd0779086c03a3738cbb389", - "shasum": "" - }, - "require": { - "php": "^5.3.3 || ^7.0 || ^8.0", - "symfony/polyfill-ctype": "^1.8" - }, - "conflict": { - "phpstan/phpstan": "<0.12.20", - "vimeo/psalm": "<3.9.1" - }, - "require-dev": { - "phpunit/phpunit": "^4.8.36 || ^7.5.13" - }, - "type": "library", - "autoload": { - "psr-4": { - "Webmozart\\Assert\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Bernhard Schussek", - "email": "bschussek@gmail.com" - } - ], - "description": "Assertions to validate method input/output with nice error messages.", - "keywords": [ - "assert", - "check", - "validate" - ], - "time": "2020-07-08T17:02:28+00:00" } ], "aliases": [], @@ -8762,7 +9012,7 @@ "prefer-stable": true, "prefer-lowest": false, "platform": { - "php": "^7.2.5", + "php": "^7.3.26", "ext-curl": "*" }, "platform-dev": [] From 843eb694cbb2539c799acd6ae72a6c16be78ce9b Mon Sep 17 00:00:00 2001 From: Zlimon Date: Thu, 14 Jan 2021 17:57:14 +0100 Subject: [PATCH 31/92] Insert skill if no entry was found --- app/Console/Commands/AccountUpdate.php | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/app/Console/Commands/AccountUpdate.php b/app/Console/Commands/AccountUpdate.php index 9bd8dcae..9e2dfc81 100644 --- a/app/Console/Commands/AccountUpdate.php +++ b/app/Console/Commands/AccountUpdate.php @@ -5,6 +5,7 @@ use App\Account; use App\Collection; use App\Helpers\Helper; +use Carbon\Carbon; use Illuminate\Console\Command; use Illuminate\Support\Facades\DB; @@ -65,12 +66,15 @@ public function handle() for ($i = 0; $i < count($skills); $i++) { DB::table($skills[$i]) - ->where('account_id', $account->id) - ->update([ - 'rank' => ($playerData[$i + 1][0] >= 1 ? $playerData[$i + 1][0] : 0), - 'level' => $playerData[$i + 1][1], - 'xp' => ($playerData[$i + 1][2] >= 0 ? $playerData[$i + 1][2] : 0) - ]); + ->updateOrInsert( + ['account_id' => $account->id], + [ + 'rank' => ($playerData[$i + 1][0] >= 1 ? $playerData[$i + 1][0] : 0), + 'level' => $playerData[$i + 1][1], + 'xp' => ($playerData[$i + 1][2] >= 0 ? $playerData[$i + 1][2] : 0), + 'created_at' => Carbon::now(), + 'updated_at' => Carbon::now() + ]); } $clueScrollAmount = count(Helper::listClueScrollTiers()); From d5b4a862d3341479c70da9200b3360875b54f3bb Mon Sep 17 00:00:00 2001 From: Zlimon Date: Thu, 14 Jan 2021 18:14:10 +0100 Subject: [PATCH 32/92] Lower case skill name --- app/Http/Controllers/Api/HiscoreController.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/Http/Controllers/Api/HiscoreController.php b/app/Http/Controllers/Api/HiscoreController.php index 2e324a3f..72b26b5f 100644 --- a/app/Http/Controllers/Api/HiscoreController.php +++ b/app/Http/Controllers/Api/HiscoreController.php @@ -65,7 +65,7 @@ public function skill($skillName) return HiscoreResource::collection($hiscores) ->additional([ 'meta' => [ - 'skill' => ucfirst($skillName), + 'skill' => $skillName, 'total_xp' => number_format($sumTotalXp), 'average_total_level' => round($averageTotalLevel), 'total_max_level' => $totalMaxLevel, From 4405432e60a76b62f9f13bf13aef59b3db6ecc13 Mon Sep 17 00:00:00 2001 From: Zlimon Date: Thu, 14 Jan 2021 18:19:23 +0100 Subject: [PATCH 33/92] Insert npc if no entry was found --- app/Collection.php | 2 +- app/Console/Commands/AccountUpdate.php | 14 ++++++++++++++ 2 files changed, 15 insertions(+), 1 deletion(-) diff --git a/app/Collection.php b/app/Collection.php index b211f269..21f6a240 100644 --- a/app/Collection.php +++ b/app/Collection.php @@ -29,7 +29,7 @@ class Collection extends Model public static function findByNameAndCategory($name, $category_id) { - return self::where([['name', $name], ['category_id', $category_id]])->firstOrFail(); + return self::where([['name', $name], ['category_id', $category_id]])->first(); } public function category() diff --git a/app/Console/Commands/AccountUpdate.php b/app/Console/Commands/AccountUpdate.php index 9e2dfc81..ed20d55c 100644 --- a/app/Console/Commands/AccountUpdate.php +++ b/app/Console/Commands/AccountUpdate.php @@ -143,6 +143,20 @@ public function handle() $dks->update(); } + $npcs = Helper::listNpcs(); + + foreach ($npcs as $npc) { + $collection = Collection::findByNameAndCategory($npc, 4); + + if (is_null($collection)) { + $collectionLoot = new $collection->model; + + $collectionLoot->account_id = $account->id; + + $collectionLoot->save(); + } + } + $this->info(sprintf("Updated %s!", $account->username)); } else { $this->info(sprintf("No outdated data for %s! Not updating", $account->username)); From 7e314302c6a4bcd548c8a02d7db66d0b9b1f42c1 Mon Sep 17 00:00:00 2001 From: Zlimon Date: Thu, 14 Jan 2021 18:35:47 +0100 Subject: [PATCH 34/92] Account level up notification and log --- app/Events/AccountLevelUp.php | 4 +++- app/Http/Controllers/Api/AccountSkillController.php | 11 +++++++++-- 2 files changed, 12 insertions(+), 3 deletions(-) diff --git a/app/Events/AccountLevelUp.php b/app/Events/AccountLevelUp.php index cac0bca3..7d85ec39 100644 --- a/app/Events/AccountLevelUp.php +++ b/app/Events/AccountLevelUp.php @@ -23,7 +23,9 @@ class AccountLevelUp implements ShouldBroadcast */ public function __construct(Account $account, Notification $notification) { - $this->notification = $notification::with('category')->where('account_id', $account->id)->orderByDesc('id')->first(); + $this->notification = $notification::with('log')->with('log.category')->whereHas('log', function ($query) use($account) { + return $query->where('account_id', '=', $account->id); + })->orderByDesc('id')->first(); } /** diff --git a/app/Http/Controllers/Api/AccountSkillController.php b/app/Http/Controllers/Api/AccountSkillController.php index 7d322349..2b8cefd7 100644 --- a/app/Http/Controllers/Api/AccountSkillController.php +++ b/app/Http/Controllers/Api/AccountSkillController.php @@ -7,6 +7,7 @@ use App\Events\AccountLevelUp; use App\Events\All; use App\Http\Controllers\Controller; +use App\Log; use App\Notification; use Illuminate\Http\Request; use Illuminate\Support\Facades\DB; @@ -22,13 +23,19 @@ public function update($accountUsername, $skillName, Request $request) $skill = DB::table($skillName)->where('account_id', $account->id)->first(); - $notificationData = [ + $logData = [ "user_id" => auth()->user()->id, "account_id" => $account->id, "category_id" => 1, + "data" => null + ]; + + $log = Log::create($logData); + + $notificationData = [ + "log_id" => $log->id, "icon" => $skillName, "message" => $accountUsername . " just achieved level " . $skill->level . " " . ucfirst($skillName) . "!" . ($skill->level === 92 ? " Half way there!" : ""), - "data" => null ]; $notification = Notification::create($notificationData); From 13b54f37a702a2d951726c6df79f8c47f077e081 Mon Sep 17 00:00:00 2001 From: Zlimon Date: Sat, 16 Jan 2021 00:40:43 +0100 Subject: [PATCH 35/92] Rename $collectionLoot to $collectionLog --- app/Console/Commands/AccountUpdate.php | 30 +++++++++---------- .../Controllers/Api/AccountController.php | 16 +++++----- database/seeds/UserSeeder.php | 16 +++++----- 3 files changed, 31 insertions(+), 31 deletions(-) diff --git a/app/Console/Commands/AccountUpdate.php b/app/Console/Commands/AccountUpdate.php index ed20d55c..01c387ba 100644 --- a/app/Console/Commands/AccountUpdate.php +++ b/app/Console/Commands/AccountUpdate.php @@ -90,27 +90,27 @@ public function handle() for ($i = (count($skills) + $clueScrollAmount + 5); $i < (count($skills) + $clueScrollAmount + 5 + count($bosses)); $i++) { $collection = Collection::where('name', $bosses[$bossIndex])->firstOrFail(); - $collectionLoot = $collection->model::where('account_id', $account->id)->first(); + $collectionLog = $collection->model::where('account_id', $account->id)->first(); // If account has no collection entry, create it - if (is_null($collectionLoot)) { - $collectionLoot = new $collection->model; + if (is_null($collectionLog)) { + $collectionLog = new $collection->model; - $collectionLoot->getAttributes(); + $collectionLog->getAttributes(); - foreach ($collectionLoot->getFillable() as $fillable) { - $collectionLoot->$fillable = 0; + foreach ($collectionLog->getFillable() as $fillable) { + $collectionLog->$fillable = 0; } - $collectionLoot->account_id = $account->id; + $collectionLog->account_id = $account->id; - $collectionLoot->save(); + $collectionLog->save(); } else { - $collectionLoot->account_id = $account->id; - $collectionLoot->kill_count = ($playerData[$i + 1][1] >= 0 ? $playerData[$i + 1][1] : 0); - $collectionLoot->rank = ($playerData[$i + 1][0] >= 0 ? $playerData[$i + 1][0] : 0); + $collectionLog->account_id = $account->id; + $collectionLog->kill_count = ($playerData[$i + 1][1] >= 0 ? $playerData[$i + 1][1] : 0); + $collectionLog->rank = ($playerData[$i + 1][0] >= 0 ? $playerData[$i + 1][0] : 0); - $collectionLoot->update(); + $collectionLog->update(); } if (in_array($bosses[$bossIndex], @@ -149,11 +149,11 @@ public function handle() $collection = Collection::findByNameAndCategory($npc, 4); if (is_null($collection)) { - $collectionLoot = new $collection->model; + $collectionLog = new $collection->model; - $collectionLoot->account_id = $account->id; + $collectionLog->account_id = $account->id; - $collectionLoot->save(); + $collectionLog->save(); } } diff --git a/app/Http/Controllers/Api/AccountController.php b/app/Http/Controllers/Api/AccountController.php index ec381cbf..cdc5a7cc 100644 --- a/app/Http/Controllers/Api/AccountController.php +++ b/app/Http/Controllers/Api/AccountController.php @@ -113,18 +113,18 @@ public function store(Request $request) for ($i = (count($skills) + $clueScrollAmount + 5); $i < (count($skills) + $clueScrollAmount + 5 + count($bosses)); $i++) { $collection = Collection::where('name', $bosses[$bossIndex])->firstOrFail(); - $collectionLoot = new $collection->model; + $collectionLog = new $collection->model; - $collectionLoot->account_id = $account->id; - $collectionLoot->kill_count = ($playerData[$i + 1][1] >= 0 ? $playerData[$i + 1][1] : 0); - $collectionLoot->rank = ($playerData[$i + 1][0] >= 0 ? $playerData[$i + 1][0] : 0); + $collectionLog->account_id = $account->id; + $collectionLog->kill_count = ($playerData[$i + 1][1] >= 0 ? $playerData[$i + 1][1] : 0); + $collectionLog->rank = ($playerData[$i + 1][0] >= 0 ? $playerData[$i + 1][0] : 0); if (in_array($bosses[$bossIndex], ['dagannoth prime', 'dagannoth rex', 'dagannoth supreme'], true)) { $dksKillCount += ($playerData[$i + 1][1] >= 0 ? $playerData[$i + 1][1] : 0); } - $collectionLoot->save(); + $collectionLog->save(); $bossIndex++; } @@ -148,11 +148,11 @@ public function store(Request $request) foreach ($npcs as $npc) { $collection = Collection::findByNameAndCategory($npc, 4); - $collectionLoot = new $collection->model; + $collectionLog = new $collection->model; - $collectionLoot->account_id = $account->id; + $collectionLog->account_id = $account->id; - $collectionLoot->save(); + $collectionLog->save(); } $authStatus->status = "success"; diff --git a/database/seeds/UserSeeder.php b/database/seeds/UserSeeder.php index 923e4bca..1be330b7 100644 --- a/database/seeds/UserSeeder.php +++ b/database/seeds/UserSeeder.php @@ -121,18 +121,18 @@ public function run() for ($i = (count($skills) + $clueScrollAmount + 5); $i < (count($skills) + $clueScrollAmount + 5 + count($bosses)); $i++) { $collection = Collection::where('name', $bosses[$bossIndex])->firstOrFail(); - $collectionLoot = new $collection->model; + $collectionLog = new $collection->model; - $collectionLoot->account_id = $account->id; - $collectionLoot->kill_count = ($playerData[$i + 1][1] >= 0 ? $playerData[$i + 1][1] : 0); - $collectionLoot->rank = ($playerData[$i + 1][0] >= 0 ? $playerData[$i + 1][0] : 0); + $collectionLog->account_id = $account->id; + $collectionLog->kill_count = ($playerData[$i + 1][1] >= 0 ? $playerData[$i + 1][1] : 0); + $collectionLog->rank = ($playerData[$i + 1][0] >= 0 ? $playerData[$i + 1][0] : 0); if (in_array($bosses[$bossIndex], ['dagannoth prime', 'dagannoth rex', 'dagannoth supreme'], true)) { $dksKillCount += ($playerData[$i + 1][1] >= 0 ? $playerData[$i + 1][1] : 0); } - $collectionLoot->save(); + $collectionLog->save(); $bossIndex++; } @@ -156,11 +156,11 @@ public function run() foreach ($npcs as $npc) { $collection = Collection::findByNameAndCategory($npc, 4); - $collectionLoot = new $collection->model; + $collectionLog = new $collection->model; - $collectionLoot->account_id = $account->id; + $collectionLog->account_id = $account->id; - $collectionLoot->save(); + $collectionLog->save(); } print_r('Added ' . $accounts[$randomId]); From 155fcaf0aec6ec1f4e393ec20c46f47f153ff1ce Mon Sep 17 00:00:00 2001 From: Zlimon Date: Sat, 16 Jan 2021 00:40:53 +0100 Subject: [PATCH 36/92] Lower case notification icons --- app/Http/Controllers/Api/AccountLootController.php | 4 ++-- app/Http/Controllers/Api/AccountSkillController.php | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/app/Http/Controllers/Api/AccountLootController.php b/app/Http/Controllers/Api/AccountLootController.php index 95a06764..7ae01720 100644 --- a/app/Http/Controllers/Api/AccountLootController.php +++ b/app/Http/Controllers/Api/AccountLootController.php @@ -81,7 +81,7 @@ public function update($accountUsername, $collectionName, Request $request) $notificationData = [ "log_id" => $log->id, - "icon" => $collectionName, + "icon" => strtolower($collectionName), "message" => $accountUsername . " unlocked a new unique!", ]; @@ -127,7 +127,7 @@ public function update($accountUsername, $collectionName, Request $request) $notificationData = [ "log_id" => $log->id, - "icon" => $collectionName, + "icon" => strtolower($collectionName), "message" => $accountUsername . " defeated " . $collection->alias . "!", ]; diff --git a/app/Http/Controllers/Api/AccountSkillController.php b/app/Http/Controllers/Api/AccountSkillController.php index 2b8cefd7..9d76ba86 100644 --- a/app/Http/Controllers/Api/AccountSkillController.php +++ b/app/Http/Controllers/Api/AccountSkillController.php @@ -34,7 +34,7 @@ public function update($accountUsername, $skillName, Request $request) $notificationData = [ "log_id" => $log->id, - "icon" => $skillName, + "icon" => strtolower($skillName), "message" => $accountUsername . " just achieved level " . $skill->level . " " . ucfirst($skillName) . "!" . ($skill->level === 92 ? " Half way there!" : ""), ]; From 40f0d4c084ec9a6dc05522bc2b68400a3935dcca Mon Sep 17 00:00:00 2001 From: Zlimon Date: Sat, 16 Jan 2021 00:44:49 +0100 Subject: [PATCH 37/92] Players with 4,6b total xp updates regardless --- app/Console/Commands/AccountUpdate.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/Console/Commands/AccountUpdate.php b/app/Console/Commands/AccountUpdate.php index 01c387ba..6fb33a7d 100644 --- a/app/Console/Commands/AccountUpdate.php +++ b/app/Console/Commands/AccountUpdate.php @@ -53,7 +53,7 @@ public function handle() $playerData = Helper::getPlayerData($playerDataUrl); if ($playerData) { - if ($account->xp != $playerData[0][2]) { + if ($account->xp != $playerData[0][2] || $account->xp == 4600000000) { $this->info(sprintf("Found outdated data for %s!", $account->username)); $account->rank = $playerData[0][0]; From fb52cb45f473463d2fc202455a789a97c6a0b3a7 Mon Sep 17 00:00:00 2001 From: Zlimon Date: Sat, 16 Jan 2021 01:35:42 +0100 Subject: [PATCH 38/92] Database seeder and factories Laravel 8 compatibility --- app/User.php | 3 +- composer.json | 10 ++-- config/app.php | 2 +- database/factories/UserFactory.php | 50 +++++++++++-------- .../{seeds => seeders}/DatabaseSeeder.php | 4 +- database/{seeds => seeders}/UserSeeder.php | 17 ++++--- 6 files changed, 49 insertions(+), 37 deletions(-) rename database/{seeds => seeders}/DatabaseSeeder.php (74%) rename database/{seeds => seeders}/UserSeeder.php (92%) diff --git a/app/User.php b/app/User.php index 92202e83..154c9fa0 100644 --- a/app/User.php +++ b/app/User.php @@ -2,6 +2,7 @@ namespace App; +use Illuminate\Database\Eloquent\Factories\HasFactory; use Illuminate\Foundation\Auth\User as Authenticatable; use Illuminate\Notifications\Notifiable; use Laravel\Passport\HasApiTokens; @@ -47,7 +48,7 @@ */ class User extends Authenticatable { - use HasApiTokens, Notifiable; + use HasApiTokens, HasFactory, Notifiable; /** * The attributes that are mass assignable. diff --git a/composer.json b/composer.json index ca35eebb..390572e2 100644 --- a/composer.json +++ b/composer.json @@ -42,12 +42,10 @@ }, "autoload": { "psr-4": { - "App\\": "app/" - }, - "classmap": [ - "database/seeds", - "database/factories" - ] + "App\\": "app/", + "Database\\Factories\\": "database/factories/", + "Database\\Seeders\\": "database/seeders/" + } }, "autoload-dev": { "psr-4": { diff --git a/config/app.php b/config/app.php index 773fc450..070c5458 100644 --- a/config/app.php +++ b/config/app.php @@ -101,7 +101,7 @@ |-------------------------------------------------------------------------- | | This locale will be used by the Faker PHP library when generating fake - | data for your database seeds. For example, this will be used to get + | data for your database seeders. For example, this will be used to get | localized telephone numbers, street address information and more. | */ diff --git a/database/factories/UserFactory.php b/database/factories/UserFactory.php index f4cf79c9..f6fc91d3 100644 --- a/database/factories/UserFactory.php +++ b/database/factories/UserFactory.php @@ -1,29 +1,35 @@ define(User::class, function (Faker $faker) { - return [ - 'name' => $faker->name, - 'email' => $faker->unique()->safeEmail, - 'email_verified_at' => now(), - 'password' => bcrypt('runemanager1234'), // password - 'remember_token' => Str::random(10), - 'icon_id' => Helper::randomItemId(true), - ]; -}); + /** + * Define the model's default state. + * + * @return array + */ + public function definition() + { + return [ + 'name' => $this->faker->name, + 'email' => $this->faker->unique()->safeEmail, + 'email_verified_at' => now(), + 'password' => bcrypt('runemanager1234'), + 'remember_token' => Str::random(10), + 'icon_id' => Helper::randomItemId(true), + ]; + } +} diff --git a/database/seeds/DatabaseSeeder.php b/database/seeders/DatabaseSeeder.php similarity index 74% rename from database/seeds/DatabaseSeeder.php rename to database/seeders/DatabaseSeeder.php index e7e6a4e9..cd7d925a 100644 --- a/database/seeds/DatabaseSeeder.php +++ b/database/seeders/DatabaseSeeder.php @@ -1,5 +1,7 @@ call(UserSeeder::class); + $this->call(UserSeeder::class); } } diff --git a/database/seeds/UserSeeder.php b/database/seeders/UserSeeder.php similarity index 92% rename from database/seeds/UserSeeder.php rename to database/seeders/UserSeeder.php index 1be330b7..4090a015 100644 --- a/database/seeds/UserSeeder.php +++ b/database/seeders/UserSeeder.php @@ -1,20 +1,25 @@ insert([ + User::create([ 'name' => 'Simon', 'email' => 'simon@runemanager.com', 'password' => bcrypt('runemanager1234'), @@ -72,15 +77,15 @@ public function run() shuffle($accounts); - factory(App\User::class, sizeof($accounts))->create()->each(function ($u) use ($accounts) { - $randomId = rand(1, sizeof($accounts)); + User::factory()->count(sizeof($accounts) - 1)->create()->each(function ($u) use ($accounts) { + $randomId = rand(1, sizeof($accounts) - 1); - if (App\Account::where('username', $accounts[$randomId])->first()) { + if (Account::where('username', $accounts[$randomId - 1])->first()) { return null; } $playerDataUrl = 'https://secure.runescape.com/m=hiscore_oldschool/index_lite.ws?player=' . str_replace(' ', - '%20', $accounts[$randomId]); + '%20', $accounts[$randomId - 1]); /* Get the $playerDataUrl file content. */ $playerData = Helper::getPlayerData($playerDataUrl); From 5a7c031797847841d53213da877aea4d29232034 Mon Sep 17 00:00:00 2001 From: Zlimon Date: Sat, 16 Jan 2021 01:38:04 +0100 Subject: [PATCH 39/92] Create Npc entry for every account --- app/Console/Commands/NpcCreate.php | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/app/Console/Commands/NpcCreate.php b/app/Console/Commands/NpcCreate.php index 01a0b225..e7c5cdeb 100644 --- a/app/Console/Commands/NpcCreate.php +++ b/app/Console/Commands/NpcCreate.php @@ -2,6 +2,7 @@ namespace App\Console\Commands; +use App\Account; use App\Collection; use Artisan; use Illuminate\Console\Command; @@ -100,6 +101,18 @@ function ($unique) { Artisan::call('migrate'); + $accounts = Account::get(); + + foreach ($accounts as $account) { + $collection = Collection::findByNameAndCategory(ucfirst(str_replace("_", " ", Str::snake(Str::singular($this->argument('npc'))))), 4); + + $collectionLog = new $collection->model; + + $collectionLog->account_id = $account->id; + + $collectionLog->save(); + } + $i = 0; foreach ($this->argument('unique') as $key => $unique) { $handle = curl_init("https://api.osrsbox.com/items?where=" . urlencode('{"name":"' . ucfirst(str_replace("_", " ", Str::snake($unique))) . '","duplicate":false}')); From ca4030813af7974161dcad30a361f58a0e965bcf Mon Sep 17 00:00:00 2001 From: Zlimon Date: Sat, 16 Jan 2021 12:16:52 +0100 Subject: [PATCH 40/92] Snake case icons --- app/Http/Controllers/Api/AccountLootController.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/app/Http/Controllers/Api/AccountLootController.php b/app/Http/Controllers/Api/AccountLootController.php index 7ae01720..dc72ed03 100644 --- a/app/Http/Controllers/Api/AccountLootController.php +++ b/app/Http/Controllers/Api/AccountLootController.php @@ -12,6 +12,7 @@ use App\Log; use App\Notification; use Illuminate\Http\Request; +use Illuminate\Support\Str; class AccountLootController extends Controller { @@ -81,7 +82,7 @@ public function update($accountUsername, $collectionName, Request $request) $notificationData = [ "log_id" => $log->id, - "icon" => strtolower($collectionName), + "icon" => strtolower(Str::snake($collectionName)), "message" => $accountUsername . " unlocked a new unique!", ]; @@ -127,7 +128,7 @@ public function update($accountUsername, $collectionName, Request $request) $notificationData = [ "log_id" => $log->id, - "icon" => strtolower($collectionName), + "icon" => strtolower(Str::snake($collectionName)), "message" => $accountUsername . " defeated " . $collection->alias . "!", ]; From a12115a2bd81c03cb8465c3138c3e6f25a566b11 Mon Sep 17 00:00:00 2001 From: Zlimon Date: Sat, 16 Jan 2021 17:17:21 +0100 Subject: [PATCH 41/92] Account profile page redesign - Inspired by Adventurer's log from 2010 --- public/css/button.css | 9 +- public/css/style.css | 12 ++ .../js/components/AccountBossHiscore.vue | 182 +++++++++--------- resources/js/components/AccountHiscore.vue | 99 +++++++--- .../js/components/AccountSkillHiscore.vue | 54 ++---- resources/views/account/show.blade.php | 10 +- resources/views/index.blade.php | 4 +- 7 files changed, 209 insertions(+), 161 deletions(-) diff --git a/public/css/button.css b/public/css/button.css index 490fca25..68a85ee6 100644 --- a/public/css/button.css +++ b/public/css/button.css @@ -23,9 +23,7 @@ .button-combat-style-narrow { font-family: 'runescape', sans-serif; - font-size: 1.5em; font-weight: bold; - line-height: 4rem; transition: all .2s ease-in; @@ -94,3 +92,10 @@ width: 12.5rem; height: 5rem; } + +.button-small { + width: 66px; + height: 30px; + padding: 2px; + margin: 2px; +} diff --git a/public/css/style.css b/public/css/style.css index ef82c0f1..bc11768a 100644 --- a/public/css/style.css +++ b/public/css/style.css @@ -325,6 +325,12 @@ table th object-fit: contain; } +.icon-small { + width: 36px; + height: 32px; + object-fit: contain; +} + .notification-icon { width: 60px; height: 60px; @@ -337,6 +343,12 @@ table th object-fit: contain; } +.hiscore-icon-small { + width: 25px; + height: 25px; + object-fit: contain; +} + .icon-radio [type=radio] { position: absolute; diff --git a/resources/js/components/AccountBossHiscore.vue b/resources/js/components/AccountBossHiscore.vue index ba837335..5a5f4e47 100644 --- a/resources/js/components/AccountBossHiscore.vue +++ b/resources/js/components/AccountBossHiscore.vue @@ -17,98 +17,82 @@
-
- Profile icon - -
-

{{ data.username }}

- - Rank: {{ data.rank }} -
- Total XP: {{ data.xp }} -
- Total Level: {{ data.level }} -
- Joined: {{ data.joined }} -
-
- - - - - - - - - - - - - - - - -
Kill CountHiscore RankCollection LogObtained
- - - {{ hiscore.alias }} - - {{ hiscore.kill_count }}{{ hiscore.rank }} - - Collection log item icon - - -
- - {{ (hiscore.obtained !== null ? hiscore.obtained : 0) }} / {{ hiscore.total }} - -
-
- {{ hiscore.obtained }} / {{ hiscore.total }} +
+
+
+ +
- - {{ (hiscore.obtained !== null ? hiscore.obtained : 0) }} / {{ hiscore.total }} - -
-
+
+
+ Collection log item icon +
+
@@ -134,7 +125,14 @@ export default { loading: true, errored: false, data: {}, - meta: {} + meta: {}, + showCollectionLog: false + } + }, + + methods: { + toggle() { + this.showCollectionLog = this.showCollectionLog === false; } }, diff --git a/resources/js/components/AccountHiscore.vue b/resources/js/components/AccountHiscore.vue index 521b8891..beaba423 100644 --- a/resources/js/components/AccountHiscore.vue +++ b/resources/js/components/AccountHiscore.vue @@ -1,30 +1,78 @@ @@ -38,6 +86,11 @@ export default { }, methods: { + onLoadAccount(account) { + this.accountData = account; + this.loading = false; + }, + toggle() { if (this.component === AccountSkillHiscore) { this.component = AccountBossHiscore; @@ -56,6 +109,8 @@ export default { data() { return { + loading: true, + accountData: {}, skills: true, component: AccountSkillHiscore, } diff --git a/resources/js/components/AccountSkillHiscore.vue b/resources/js/components/AccountSkillHiscore.vue index 955160a2..d5b75cb8 100644 --- a/resources/js/components/AccountSkillHiscore.vue +++ b/resources/js/components/AccountSkillHiscore.vue @@ -17,47 +17,28 @@
-
- Profile icon - -
-

{{ data.username }}

- - Rank: {{ data.rank }} -
- Total XP: {{ data.xp }} -
- Total Level: {{ data.level }} -
- Joined: {{ data.joined }} -
-
- - - - - - - - - - - - - - -
LevelXPHiscore Rank
+ {{ hiscore.level }}{{ hiscore.xp }}{{ hiscore.rank }}
+
+
+ +
@@ -84,6 +65,7 @@ export default { .then((response) => { this.data = response.data.data; this.hiscores = response.data.meta.skillHiscores; + this.$emit('load', response.data.data) }) .catch(error => { console.log(error) diff --git a/resources/views/account/show.blade.php b/resources/views/account/show.blade.php index 436b8d29..3f11334c 100644 --- a/resources/views/account/show.blade.php +++ b/resources/views/account/show.blade.php @@ -7,14 +7,10 @@ @section('content')
@if ($account->user->private === 0 || (Auth::check() && $account->user->id == Auth::user()->id)) -
-
- -
+ -
- -
+
+
@else
diff --git a/resources/views/index.blade.php b/resources/views/index.blade.php index 8b9bbddd..ad4dd806 100644 --- a/resources/views/index.blade.php +++ b/resources/views/index.blade.php @@ -20,13 +20,13 @@ @guest
-
+
Log in
-
+
Register
From d4e33d27f9b2b7ced29db2db77bc2a30002daf35 Mon Sep 17 00:00:00 2001 From: Zlimon Date: Sat, 16 Jan 2021 19:03:24 +0100 Subject: [PATCH 42/92] Don't dispatch login & logout event on account page --- app/Http/Controllers/Api/AccountController.php | 4 ---- 1 file changed, 4 deletions(-) diff --git a/app/Http/Controllers/Api/AccountController.php b/app/Http/Controllers/Api/AccountController.php index cdc5a7cc..5c1fdd04 100644 --- a/app/Http/Controllers/Api/AccountController.php +++ b/app/Http/Controllers/Api/AccountController.php @@ -210,8 +210,6 @@ public function login($accountUsername) All::dispatch($notification); - AccountAll::dispatch($account, $notification); - return response($accountUsername . " has been logged in to RuneManager"); } else { return response("This account is not authenticated with " . auth()->user()->name, 403); @@ -250,8 +248,6 @@ public function logout($accountUsername) All::dispatch($notification); - AccountAll::dispatch($account, $notification); - return response($accountUsername . " has been logged off RuneManager"); } else { return response("This account is not authenticated with " . auth()->user()->name, 403); From 7b533baaf579571e83215ba73bfa732f81743d83 Mon Sep 17 00:00:00 2001 From: Zlimon Date: Sun, 17 Jan 2021 14:38:47 +0100 Subject: [PATCH 43/92] Account Equipment sync --- app/Account.php | 4 + app/Equipment.php | 28 ++++ app/Events/AccountEquipment.php | 41 ++++++ .../Api/AccountEquipmentController.php | 60 ++++++++ composer.json | 3 +- ...21_01_17_001156_create_equipment_table.php | 33 +++++ public/images/equipment_slots.png | Bin 0 -> 4913 bytes resources/js/app.js | 1 + resources/js/components/Equipment.vue | 134 ++++++++++++++++++ resources/views/account/show.blade.php | 10 +- routes/api.php | 3 + 11 files changed, 314 insertions(+), 3 deletions(-) create mode 100644 app/Equipment.php create mode 100644 app/Events/AccountEquipment.php create mode 100644 app/Http/Controllers/Api/AccountEquipmentController.php create mode 100644 database/migrations/2021_01_17_001156_create_equipment_table.php create mode 100644 public/images/equipment_slots.png create mode 100644 resources/js/components/Equipment.vue diff --git a/app/Account.php b/app/Account.php index ec401b20..a660ce56 100644 --- a/app/Account.php +++ b/app/Account.php @@ -51,4 +51,8 @@ public function user() { public function notification() { return $this->hasMany(Notification::class); } + + public function equipment() { + return $this->hasOne(Equipment::class); + } } diff --git a/app/Equipment.php b/app/Equipment.php new file mode 100644 index 00000000..ba383320 --- /dev/null +++ b/app/Equipment.php @@ -0,0 +1,28 @@ + 'array' + ]; + + public function account() { + return $this->belongsTo(Account::class); + } +} diff --git a/app/Events/AccountEquipment.php b/app/Events/AccountEquipment.php new file mode 100644 index 00000000..a2fbed0d --- /dev/null +++ b/app/Events/AccountEquipment.php @@ -0,0 +1,41 @@ +equipment = $equipment; + } + + /** + * Get the channels the event should broadcast on. + * + * @return \Illuminate\Broadcasting\Channel|array + */ + public function broadcastOn() + { + return new Channel('account-equipment'); + } +} diff --git a/app/Http/Controllers/Api/AccountEquipmentController.php b/app/Http/Controllers/Api/AccountEquipmentController.php new file mode 100644 index 00000000..a026d0de --- /dev/null +++ b/app/Http/Controllers/Api/AccountEquipmentController.php @@ -0,0 +1,60 @@ +pluck('id')->first(); + + if ($account) { + $equipment = Equipment::where('account_id', $account)->first(); + + if ($equipment) { + return response()->json($equipment, 200); + } else { + return response()->json("No equipment for " . $accountUsername . " were found!", 404); + } + } + } + + public function update($accountUsername, Request $request) + { + $account = Account::where('user_id', auth()->user()->id)->where('username', $accountUsername)->first(); + + if ($account) { + Equipment::updateOrInsert( + ['account_id' => $account->id], + [ + 'data' => json_encode($request->all()), + 'created_at' => Carbon::now(), // TODO make better logic to not update this + 'updated_at' => Carbon::now(), + ] + ); + + $equipment = Equipment::where('account_id', $account->id)->first(); + + $logData = [ + "user_id" => auth()->user()->id, + "account_id" => $account->id, + "category_id" => 8, + "data" => $request->all() + ]; + + $log = Log::create($logData); + + AccountEquipment::dispatch($equipment); + + return response()->json("Updated equipment for " . $accountUsername, 200); + } + } +} diff --git a/composer.json b/composer.json index 390572e2..97a58a39 100644 --- a/composer.json +++ b/composer.json @@ -18,7 +18,8 @@ "laravel/passport": "^10.0", "laravel/tinker": "^2.0", "laravel/ui": "^3.0", - "pusher/pusher-php-server": "^4.1" + "pusher/pusher-php-server": "^4.1", + "ext-json": "*" }, "require-dev": { "barryvdh/laravel-ide-helper": "^2.8", diff --git a/database/migrations/2021_01_17_001156_create_equipment_table.php b/database/migrations/2021_01_17_001156_create_equipment_table.php new file mode 100644 index 00000000..089b3ba0 --- /dev/null +++ b/database/migrations/2021_01_17_001156_create_equipment_table.php @@ -0,0 +1,33 @@ +id(); + $table->integer('account_id')->unsigned(); + $table->text('data')->nullable(); + $table->timestamps(); + }); + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('equipment'); + } +} diff --git a/public/images/equipment_slots.png b/public/images/equipment_slots.png new file mode 100644 index 0000000000000000000000000000000000000000..67d554d1e16597cc3c52db6f041e14beefb0cd27 GIT binary patch literal 4913 zcmZWtcRX9)8@5`TB53WJvDFr#sE83OcI{oWRfL#TG&PFUo-r#%DbXrvqxPs#)vD1_ zS`8YT8a00D_ut?B+;iT0&VA2&-uF4rJ@5J46bmybGXoC;1qB7Ok)b}EEOW@EhmM+D z7pU+ukp*Qa9I8jrG|sn1ZqWGZn(9(ev}7`#x?du>gPF!r*3B z7yo}zn41&X$nWXz89IbgP_Xp=E0lwGv0fAu>@G(7y4H~{8zu7|KVGpwitot0-&Aft zzvwD^sbicYX6zGKTZT$B^L$VFSeAmOj$b_fEE@lYWNh0B*`zw?6fvhd*xj8w1MQ=J zR0w9o4*p(?RA)k2#jBUNY|(!nD>wY`JAgH>x8?VvJvNKMb9E--twq*a>WWVO>5X#3 zNg=GOfl1)mP7EkKb`itUyAx@Cd5hxUaMAe-x{094pV{|2QrInaa9*j7FT8q4QI%jBPSj1bau znKQ)LuA*3+%FDe4stB@oQ_C1Ze?x`Cd4T*93p+#kGPH}1cTm1#+RIc}V6_p87BI-> z%u0tXJzM2xj^|q?;{nqGt$TPPAS%Kqm);_bdeOp)GPTl|1zh`KtxQ6Q0;PDfxI^iT zGF|2oiLZ=0)j5HFZ?Qtcfaq?R@0ICy46u->6}&?Cq=A2j=d#tX1j?26mGuNg|K&^9 zb*v9(<&}Y5_Ny`}6MkiZbTjq()p6N|e~`BJ0MPYlIL2c+!dHj}0MA1xSbDcqL@@xl z!TCS3m00hzBp(l^`YOV`%qhbowIZh38x)MZ1aGB-5LJ{}Po~NENpSHHd6+3I0-cUV zjAdZl<;3bt0~LydZ-5Uo4Oi;u03R~C%*^M0vPnqsTp7_A(@Oqa@NF^Fzy1eWN;Zmq zm@btc$iL+9w~j+6>NfDVq6xo^7jiJ0so8vem3qQ1mcsLVXXafLF%P#j-m_jty?$^2 zyXC=#Fo^?kNaS$~JRh&lNR1lt#M97j(hAO|aF30A4Pi59o4Br?1hL{~-C0KGOw*Js z(X=g%5>|W+BN9@Xf=BoZHmP4qJFIba(0+1SSh(q;eG(JW3}*T?AANW{m~ayLH)?IS z|1F#{H^Ado>(i$}vmYTrSlcUAhtcdr^1Xzs0_J43f9Ucmogo;Nw z9e#oB>xC4z2HVQCQbBYi#6i07Y1n@9vVixuMtd*jdWFdcOPd)I5in`-&caqg!n{l3 zt{FRrY)*!j5m-gGaJ9n&g{mG}8B2vomBUVk^f5CxhHp0(t};T(c=XUcZ=G9)c&yzk zYt~+~DYWR`R-DXFl|aaD>N^5Ddh0#V#?`<G24LkBe=JA!j1O^!3I zQTGW<8ONopCv5%f;%N%OLMG=R9CA4w+L!BrRsrs&FT1f7srfLg5yfyPm2uLkzoPBX zbGxeEx~G!wl0DG3PadW`OI+>tCtZ7}Lj;um2PN&nu5gS+)xG9P{O` zY!HxVrEjX)$HqH{GqyBx7S^zW{~Tb0Z)3z{?dwZA(3mnm_Dg#wdeNKs%E!f(SG9ty ztGSta1N$O}>~35+fZWg&^k!yQ&8ucE{p_B#%luJqAio>`B|pi)C1lRI0oy z27_aB7P0=h0w?R&z*oEViO1cEcOyke1__pQe@qS!c3;*E@n}oN?PFXY@No853(Fg! z?}_!3VseZtXgT;5BA5K^#BWbP#lsaQ1-I@R)B{JJazglg`wue@4_^w)Oa1C(_@~W) zb*sFV@Kcbf85VYz!a)4wY~x3op?5!a&Io--Dr^-l5QpGPIrKi=5N=K{1mN~8r_0$n zOtG@JxI+t9g@&NwC#HpfLi>!SZ0jLwBZwtk%o85-ud3c4DIa20qpq0vTnzIdj){^3 zc}0|0$hP?-2hPJ>`im!*ZBf1O;z%mlu1UY}OT!xuqCYR&UP?`rKBvxko7pgIXIl*v z){8O8l)>9TmXci3ubwdW3kO)Fq^QP@dj>w}8%Q_Yp;SB`NqyZm@yLTFb%0O@R0j07 z!DU)6UphsnJj<)p%Q!1a5#V&VupF%cy3&Y`DCqQ z<5ZUP%7nhcRPZwrP#{iI%%hLY4Hc{g2eUv?+3%@TvYDDVYvmjJet@@x$^ru?AXi;= z<|_|K>tV&H^X@FoBvR(lH4ZJQ)=n`<4Ef%Wtjvf0(*krxBs1p6)(ef4XhS}%Whejh zNRlhnWdq1lM<(~}lT{iwMdQbN$3t8q_ga&3ja1;%()}hQoepIF0n}D-RM#VF@9xSP zEC=DGVPUp!%pBCDxf~K1#EYDc%YO}|KYI6^?H6`GB_;S-WAVQ);u1&D@)t$lN}RAu zpqFM&IL-sj30$MgQA%fY$GxWrU7&)fwF6`>^?(fezvoW`TgtT3tO&KaJ@-_dbx?S= z_qTiy$nsZaCy}&m zy8CD6d?#dx`!KZ}?%yuD_E}V#tX^+uJ97mmHI zJ$REfJdXOiHMazI7c!e$NsFvDMORWq@)nQHFm~dIx!tCHh;DKGi=z3RZX3-&gUf$= zFrGDr$JPSrtv{fp%O(&xVE>rrG)uPVu$-%X2OgmKinNBQ9Zn{m&fY)rZdqre=o)edZii3oQ|#!9a%f+4aHn`C-2BWy~Tn z4gZ;1O0SOI7a8pnrK6`u`n?K;WBJ~w)I^w8h z+JXVEbocc4Z2l3B_8=)<(mjO}MvFi;k7?Z zbQPB+HfValOJaX=9IKJiJm(O-G*L9TSi+$etIPt*#tV;pwo$ygqSF?8JIY7m$cwu@ z0Y{!?b9)d}aB7O+>OB1YvJ)n*|l{^^RK)fQmz zcx6ZFJ%FkvtnRJVbU(|%@x_5neqX@3e#-1xh^gpv8i!(z`Xp zkA8h$^r^h{3!xLjoUT5xK@mRhw}zTY5g$%=7FK^9#to~nWNS(L-Xk87jD5W*r+a%w zOzJUfdhOJ^h3@vXlrLr`7bV{?#zogA`BOsbpK_9qA2#HTf{x)~(R*IUen&HtF86Ro zO{ar)s_-9do9%~(6V1FcOZ8oxSl-NgU9oTDV_A-udEp1`W{W}4*DWV+=&i>V89u4S zm7p0yO69=!A&=7WJ2^MT^~gnNWY+0En9Zl*cgyj?z<7%(si&Pqse$ zMm?hV6zYr0YhT-W_fxKKH(nI`Yu^+My7P4kC#z^r!p+`n^^0~pnPdD$G?#W%Pw9pA zLkbGej^Go$Ifl0#VlZ%2R9+q{cS-plvcm?*uLgS@m7UC)1kU zMe2X;*MIhksYA6(4q;%&&jX%+_3F>1k{4d>F=;zZzklR%bdSJwuGO$<^m&oN`uBLY zp1edShl-G(oHBdC(P3k!MCLc70o42yucGodKx}t)laFW0ZYKg-L7l`5xPTR&!aYi{ zf6(z0_0b<~S2twc(&0g3ngTkNw)tf8w z{i`T4pL-P1oqqpGysP27;uJw>A~Gzh^TF~bk(IW=D*2z2n&woB#7Sm2btWMTwFQ<( zh7sNVJ=b?>>c~d!_n~-I+RI|L4J|g-sw^i9Wh9Df-ky@?pcNcgQ-Rp)nG48Ptf)Y# zVQFQR5=TnD3_reWpeSm4Jal=IGTGj0le1}im5eR@#u#pU^_=t}PX{?aFI)F-Y|t1k zwy0ODrNZ(tf&n{Nk7W5_dwjXa}z=JGU{iH#jiS|exz1-9DpU8b_ z#6v}k6xKuJZkKvyTtAD2n=nFOxs}cuArd&%w7oQge&C^&?Sp?FN-{`wZ)`hWgt>o- zrBc1t6(yj>J6b&!OytunFNks@-umS&z;(Slh&VY}V_~(48X+{glVOm9W!zt$qLn7XN<%!@)56pJn%@>oCh?k6AMOFt0X;1U2N^R~g zJ#!zZdJnwAt@g>M_9ml33G!C51@dlyGn+)5-R({tR;Q3*gpCd|&%5tzZZ9cm-pT<{N37EXw-sLm zkMti$FupB;67j@+?EBkwP148YEKr*Jq%NZ8e#In9ruJbi%Chl%(#!(4x4PiH8oA&+ z`?HsbVDiI>Jjss_5NmK58qHYBC(dN^m&=V;(Xwm6J~K^oMJwW_gfF5PX1@fZpz;W8 zwqjn16<>h(t^ZP3H!44L1(d}~^v2O=AXe|x(r;dk%ZFm-oy$DsPov4n>q?AzET-{( z4RtnO$Tx!LhP5ezfGbW6Asah4&}=%IaPGcCi%nsbnDBG!)3V!MnlJBRvDtuA8PX!& z%)EH@g+O9`pG0M-2Rm=0&S4}g>@c!9JnOpG%51Eu{L%yrDv*i~@V?%Ux#|9qwkE0c zKz)v~z62WKgfB2n7z0Oq_jODRfHJ&DyID~wE19X-7mP<{oWID8XN})!pjnbvo46*p z`FhPsquJ+!S0Hm!srY(|o<5htFJ}Sk3Sde?zwMlYe;^>~;7j?lVT<^{ovy(QC zCq4XP_^UA}XxBCr6V82QzMga!DZpQ9b$Sr&>+u?{8Xz*C{M1U6G^*Jkg?}A@p#Lno z7fM1CMp4B#qX7@9B$EQS(zu8-ID%FE1{j2xrRh)~WC6PQYV%nqJ#MSt$a})K8UAZH zqfD*I%WJzBaUv3-q^ZNH4Ne%2_gLj6jugfR&KAtTFwhyw^<^jISDEsekTY81q#9|O zIGMa+mZj((kv76&d80l0yT%{=OFIcWVJBIx1ao`KvkT +
+

Equipment

+ +
+
+
+ Loading... +
+
+
+ +
+
+
+ Helmet +
+ +
+ Cape + Amulet + Ammunition +
+ +
+ Weapon + Platebody + Shield +
+ +
+ Platelegs +
+ +
+ Gloves + Footwear + Ring +
+
+
+
+ + + + + diff --git a/resources/views/account/show.blade.php b/resources/views/account/show.blade.php index 3f11334c..220b9673 100644 --- a/resources/views/account/show.blade.php +++ b/resources/views/account/show.blade.php @@ -9,8 +9,14 @@ @if ($account->user->private === 0 || (Auth::check() && $account->user->id == Auth::user()->id)) -
- +
+
+ +
+ +
+ +
@else
diff --git a/routes/api.php b/routes/api.php index e383ddc3..bdb9702c 100644 --- a/routes/api.php +++ b/routes/api.php @@ -29,6 +29,8 @@ Route::put('/{accountUsername}/loot/{collection}', 'Api\AccountLootController@update')->name('account-loot-update'); // Put loot data - updates collection model Route::post('/{accountUsername}/collection/{collection}', 'Api\AccountCollectionController@update')->name('account-collection-update'); // Post collection data - replaces collection model Route::post('/{accountUsername}/skill/{skill}', 'Api\AccountSkillController@update')->name('account-skill-update'); + + Route::post('/{accountUsername}/equipment', 'Api\AccountEquipmentController@update')->name('account-equipment-update'); }); }); @@ -37,6 +39,7 @@ Route::get('/{account}/skill', 'Api\AccountController@skill')->name('account-show-skill'); Route::get('/{account}/boss', 'Api\AccountController@boss')->name('account-show-boss'); Route::get('/{accountUsername}/collection/{collectionName}', 'Api\AccountCollectionController@show')->name('account-collection-show'); + Route::get('/{accountUsername}/equipment', 'Api\AccountEquipmentController@show')->name('account-equipment-show'); }); Route::prefix('/hiscore')->group(function() { From 802f1ff40e16d8f7e152021ef88aa8163d514da5 Mon Sep 17 00:00:00 2001 From: Zlimon Date: Sun, 17 Jan 2021 14:43:09 +0100 Subject: [PATCH 44/92] Header outside Vue components --- resources/js/components/Equipment.vue | 2 -- resources/views/account/show.blade.php | 8 ++++++-- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/resources/js/components/Equipment.vue b/resources/js/components/Equipment.vue index 9cb642d1..a5b5bb2d 100644 --- a/resources/js/components/Equipment.vue +++ b/resources/js/components/Equipment.vue @@ -1,7 +1,5 @@