diff --git a/.gitignore b/.gitignore index d1df871e..62123aa5 100644 --- a/.gitignore +++ b/.gitignore @@ -10,4 +10,5 @@ Homestead.json Homestead.yaml npm-debug.log yarn-error.log -.vagrant \ No newline at end of file +.vagrant +/ssl/BaltimoreCyberTrustRoot.crt.pem \ No newline at end of file diff --git a/.htaccess b/.htaccess new file mode 100644 index 00000000..947a03a9 --- /dev/null +++ b/.htaccess @@ -0,0 +1,5 @@ + + RewriteEngine on + + RewriteRule ^(.*)$ /public/$1 [NC,L,QSA] + \ No newline at end of file diff --git a/app/Account.php b/app/Account.php new file mode 100644 index 00000000..9f4ab359 --- /dev/null +++ b/app/Account.php @@ -0,0 +1,21 @@ +belongsTo(User::class); + } +} diff --git a/app/AccountAuthStatus.php b/app/AccountAuthStatus.php new file mode 100644 index 00000000..8d06900e --- /dev/null +++ b/app/AccountAuthStatus.php @@ -0,0 +1,10 @@ +belongsTo(\App\Account::class); + } } diff --git a/app/Boss/AlchemicalHydra.php b/app/Boss/AlchemicalHydra.php index 24b03b0c..e9123c7d 100644 --- a/app/Boss/AlchemicalHydra.php +++ b/app/Boss/AlchemicalHydra.php @@ -25,4 +25,8 @@ class AlchemicalHydra extends Model ]; protected $hidden = ['user_id']; + + public function account() { + return $this->belongsTo(\App\Account::class); + } } diff --git a/app/Boss/BarrowsChests.php b/app/Boss/BarrowsChests.php index 95bc1374..30053c9a 100644 --- a/app/Boss/BarrowsChests.php +++ b/app/Boss/BarrowsChests.php @@ -39,4 +39,8 @@ class BarrowsChests extends Model ]; protected $hidden = ['user_id']; + + public function account() { + return $this->belongsTo(\App\Account::class); + } } diff --git a/app/Boss/Bryophyta.php b/app/Boss/Bryophyta.php index f784ef8b..ffda1062 100644 --- a/app/Boss/Bryophyta.php +++ b/app/Boss/Bryophyta.php @@ -15,4 +15,8 @@ class Bryophyta extends Model ]; protected $hidden = ['user_id']; + + public function account() { + return $this->belongsTo(\App\Account::class); + } } diff --git a/app/Boss/Callisto.php b/app/Boss/Callisto.php index 566bf483..c19ecd40 100644 --- a/app/Boss/Callisto.php +++ b/app/Boss/Callisto.php @@ -18,4 +18,8 @@ class Callisto extends Model ]; protected $hidden = ['user_id']; + + public function account() { + return $this->belongsTo(\App\Account::class); + } } diff --git a/app/Boss/Cerberus.php b/app/Boss/Cerberus.php index f7af12b9..dabb3971 100644 --- a/app/Boss/Cerberus.php +++ b/app/Boss/Cerberus.php @@ -21,4 +21,8 @@ class Cerberus extends Model ]; protected $hidden = ['user_id']; + + public function account() { + return $this->belongsTo(\App\Account::class); + } } diff --git a/app/Boss/ChaosElemental.php b/app/Boss/ChaosElemental.php index c6502d2a..f09d7c56 100644 --- a/app/Boss/ChaosElemental.php +++ b/app/Boss/ChaosElemental.php @@ -17,4 +17,8 @@ class ChaosElemental extends Model ]; protected $hidden = ['user_id']; + + public function account() { + return $this->belongsTo(\App\Account::class); + } } diff --git a/app/Boss/ChaosFanatic.php b/app/Boss/ChaosFanatic.php index ea86a0c3..11c3f41a 100644 --- a/app/Boss/ChaosFanatic.php +++ b/app/Boss/ChaosFanatic.php @@ -17,4 +17,8 @@ class ChaosFanatic extends Model ]; protected $hidden = ['user_id']; + + public function account() { + return $this->belongsTo(\App\Account::class); + } } diff --git a/app/Boss/CommanderZilyana.php b/app/Boss/CommanderZilyana.php index d216e0e2..590af13b 100644 --- a/app/Boss/CommanderZilyana.php +++ b/app/Boss/CommanderZilyana.php @@ -22,4 +22,8 @@ class CommanderZilyana extends Model ]; protected $hidden = ['user_id']; + + public function account() { + return $this->belongsTo(\App\Account::class); + } } diff --git a/app/Boss/CorporealBeast.php b/app/Boss/CorporealBeast.php index 023a1dc7..79dca211 100644 --- a/app/Boss/CorporealBeast.php +++ b/app/Boss/CorporealBeast.php @@ -20,4 +20,8 @@ class CorporealBeast extends Model ]; protected $hidden = ['user_id']; + + public function account() { + return $this->belongsTo(\App\Account::class); + } } diff --git a/app/Boss/CrazyArchaeologist.php b/app/Boss/CrazyArchaeologist.php index 572e77e0..50fa730c 100644 --- a/app/Boss/CrazyArchaeologist.php +++ b/app/Boss/CrazyArchaeologist.php @@ -17,4 +17,8 @@ class CrazyArchaeologist extends Model ]; protected $hidden = ['user_id']; + + public function account() { + return $this->belongsTo(\App\Account::class); + } } diff --git a/app/Boss/DagannothKings.php b/app/Boss/DagannothKings.php index 9f84090f..b8aacd63 100644 --- a/app/Boss/DagannothKings.php +++ b/app/Boss/DagannothKings.php @@ -24,4 +24,8 @@ class DagannothKings extends Model ]; protected $hidden = ['user_id']; + + public function account() { + return $this->belongsTo(\App\Account::class); + } } diff --git a/app/Boss/DagannothPrime.php b/app/Boss/DagannothPrime.php new file mode 100644 index 00000000..4aa00e8a --- /dev/null +++ b/app/Boss/DagannothPrime.php @@ -0,0 +1,20 @@ +belongsTo(\App\Account::class); + } +} diff --git a/app/Boss/DagannothRex.php b/app/Boss/DagannothRex.php new file mode 100644 index 00000000..0451a5fe --- /dev/null +++ b/app/Boss/DagannothRex.php @@ -0,0 +1,20 @@ +belongsTo(\App\Account::class); + } +} diff --git a/app/Boss/DagannothSupreme.php b/app/Boss/DagannothSupreme.php new file mode 100644 index 00000000..38606d94 --- /dev/null +++ b/app/Boss/DagannothSupreme.php @@ -0,0 +1,20 @@ +belongsTo(\App\Account::class); + } +} diff --git a/app/Boss/DerangedArchaeologist.php b/app/Boss/DerangedArchaeologist.php new file mode 100644 index 00000000..216c2929 --- /dev/null +++ b/app/Boss/DerangedArchaeologist.php @@ -0,0 +1,20 @@ +belongsTo(\App\Account::class); + } +} diff --git a/app/Boss/GeneralGraardor.php b/app/Boss/GeneralGraardor.php index 049497c4..23216a3c 100644 --- a/app/Boss/GeneralGraardor.php +++ b/app/Boss/GeneralGraardor.php @@ -22,4 +22,8 @@ class GeneralGraardor extends Model ]; protected $hidden = ['user_id']; + + public function account() { + return $this->belongsTo(\App\Account::class); + } } diff --git a/app/Boss/GiantMole.php b/app/Boss/GiantMole.php index 0cf5fb3c..e8ab7213 100644 --- a/app/Boss/GiantMole.php +++ b/app/Boss/GiantMole.php @@ -17,4 +17,8 @@ class GiantMole extends Model ]; protected $hidden = ['user_id']; + + public function account() { + return $this->belongsTo(\App\Account::class); + } } diff --git a/app/Boss/Goblin.php b/app/Boss/Goblin.php index 0b02266b..74da9a09 100644 --- a/app/Boss/Goblin.php +++ b/app/Boss/Goblin.php @@ -20,4 +20,8 @@ class Goblin extends Model ]; protected $hidden = ['user_id']; + + public function account() { + return $this->belongsTo(\App\Account::class); + } } diff --git a/app/Boss/GrotesqueGuardians.php b/app/Boss/GrotesqueGuardians.php index d9cb28aa..2d7c68e0 100644 --- a/app/Boss/GrotesqueGuardians.php +++ b/app/Boss/GrotesqueGuardians.php @@ -21,4 +21,8 @@ class GrotesqueGuardians extends Model ]; protected $hidden = ['user_id']; + + public function account() { + return $this->belongsTo(\App\Account::class); + } } diff --git a/app/Boss/Hespori.php b/app/Boss/Hespori.php index 4272a359..93e8808d 100644 --- a/app/Boss/Hespori.php +++ b/app/Boss/Hespori.php @@ -18,4 +18,8 @@ class Hespori extends Model ]; protected $hidden = ['user_id']; + + public function account() { + return $this->belongsTo(\App\Account::class); + } } diff --git a/app/Boss/KalphiteQueen.php b/app/Boss/KalphiteQueen.php index 017170f0..95f02398 100644 --- a/app/Boss/KalphiteQueen.php +++ b/app/Boss/KalphiteQueen.php @@ -19,4 +19,8 @@ class KalphiteQueen extends Model ]; protected $hidden = ['user_id']; + + public function account() { + return $this->belongsTo(\App\Account::class); + } } diff --git a/app/Boss/KingBlackDragon.php b/app/Boss/KingBlackDragon.php index 678157b3..0d6e10a2 100644 --- a/app/Boss/KingBlackDragon.php +++ b/app/Boss/KingBlackDragon.php @@ -18,4 +18,8 @@ class KingBlackDragon extends Model ]; protected $hidden = ['user_id']; + + public function account() { + return $this->belongsTo(\App\Account::class); + } } diff --git a/app/Boss/Kraken.php b/app/Boss/Kraken.php index de77504d..c66b5b87 100644 --- a/app/Boss/Kraken.php +++ b/app/Boss/Kraken.php @@ -18,4 +18,8 @@ class Kraken extends Model ]; protected $hidden = ['user_id']; + + public function account() { + return $this->belongsTo(\App\Account::class); + } } diff --git a/app/Boss/KreeArra.php b/app/Boss/KreeArra.php index 4f68428a..3b3f7177 100644 --- a/app/Boss/KreeArra.php +++ b/app/Boss/KreeArra.php @@ -22,4 +22,8 @@ class Kreearra extends Model ]; protected $hidden = ['user_id']; + + public function account() { + return $this->belongsTo(\App\Account::class); + } } diff --git a/app/Boss/KrilTsutsaroth.php b/app/Boss/KrilTsutsaroth.php index cc845156..107e01bc 100644 --- a/app/Boss/KrilTsutsaroth.php +++ b/app/Boss/KrilTsutsaroth.php @@ -22,4 +22,8 @@ class KrilTsutsaroth extends Model ]; protected $hidden = ['user_id']; + + public function account() { + return $this->belongsTo(\App\Account::class); + } } diff --git a/app/Boss/Mimic.php b/app/Boss/Mimic.php new file mode 100644 index 00000000..2342dc2d --- /dev/null +++ b/app/Boss/Mimic.php @@ -0,0 +1,20 @@ +belongsTo(\App\Account::class); + } +} diff --git a/app/Boss/Obor.php b/app/Boss/Obor.php index 4639e978..370d694a 100644 --- a/app/Boss/Obor.php +++ b/app/Boss/Obor.php @@ -15,4 +15,8 @@ class Obor extends Model ]; protected $hidden = ['user_id']; + + public function account() { + return $this->belongsTo(\App\Account::class); + } } diff --git a/app/Boss/Sarachnis.php b/app/Boss/Sarachnis.php index b115f007..dfddb603 100644 --- a/app/Boss/Sarachnis.php +++ b/app/Boss/Sarachnis.php @@ -18,4 +18,8 @@ class Sarachnis extends Model ]; protected $hidden = ['user_id']; + + public function account() { + return $this->belongsTo(\App\Account::class); + } } diff --git a/app/Boss/Scorpia.php b/app/Boss/Scorpia.php index 5c93decc..f5be37e0 100644 --- a/app/Boss/Scorpia.php +++ b/app/Boss/Scorpia.php @@ -17,4 +17,8 @@ class Scorpia extends Model ]; protected $hidden = ['user_id']; + + public function account() { + return $this->belongsTo(\App\Account::class); + } } diff --git a/app/Boss/Skotizo.php b/app/Boss/Skotizo.php index 22170b86..2a563570 100644 --- a/app/Boss/Skotizo.php +++ b/app/Boss/Skotizo.php @@ -20,4 +20,8 @@ class Skotizo extends Model ]; protected $hidden = ['user_id']; + + public function account() { + return $this->belongsTo(\App\Account::class); + } } diff --git a/app/Boss/TheCorruptedGauntlet.php b/app/Boss/TheCorruptedGauntlet.php new file mode 100644 index 00000000..36eae32c --- /dev/null +++ b/app/Boss/TheCorruptedGauntlet.php @@ -0,0 +1,20 @@ +belongsTo(\App\Account::class); + } +} diff --git a/app/Boss/TheFightCaves.php b/app/Boss/TheFightCaves.php index c53a61a1..ffc66346 100644 --- a/app/Boss/TheFightCaves.php +++ b/app/Boss/TheFightCaves.php @@ -16,4 +16,8 @@ class TheFightCaves extends Model ]; protected $hidden = ['user_id']; + + public function account() { + return $this->belongsTo(\App\Account::class); + } } diff --git a/app/Boss/TheGauntlet.php b/app/Boss/TheGauntlet.php index b8c66f18..fee09191 100644 --- a/app/Boss/TheGauntlet.php +++ b/app/Boss/TheGauntlet.php @@ -19,4 +19,8 @@ class TheGauntlet extends Model ]; protected $hidden = ['user_id']; + + public function account() { + return $this->belongsTo(\App\Account::class); + } } diff --git a/app/Boss/TheInferno.php b/app/Boss/TheInferno.php index 84a90041..caf4c676 100644 --- a/app/Boss/TheInferno.php +++ b/app/Boss/TheInferno.php @@ -16,4 +16,8 @@ class TheInferno extends Model ]; protected $hidden = ['user_id']; + + public function account() { + return $this->belongsTo(\App\Account::class); + } } diff --git a/app/Boss/TheNightmare.php b/app/Boss/TheNightmare.php index 27afb1d7..15427389 100644 --- a/app/Boss/TheNightmare.php +++ b/app/Boss/TheNightmare.php @@ -24,4 +24,8 @@ class TheNightmare extends Model ]; protected $hidden = ['user_id']; + + public function account() { + return $this->belongsTo(\App\Account::class); + } } diff --git a/app/Boss/ThermonuclearSmokeDevil.php b/app/Boss/ThermonuclearSmokeDevil.php index cc468342..36499db4 100644 --- a/app/Boss/ThermonuclearSmokeDevil.php +++ b/app/Boss/ThermonuclearSmokeDevil.php @@ -18,4 +18,8 @@ class ThermonuclearSmokeDevil extends Model ]; protected $hidden = ['user_id']; + + public function account() { + return $this->belongsTo(\App\Account::class); + } } diff --git a/app/Boss/Venenatis.php b/app/Boss/Venenatis.php index 90226817..0e0deeaf 100644 --- a/app/Boss/Venenatis.php +++ b/app/Boss/Venenatis.php @@ -18,4 +18,8 @@ class Venenatis extends Model ]; protected $hidden = ['user_id']; + + public function account() { + return $this->belongsTo(\App\Account::class); + } } diff --git a/app/Boss/Vetion.php b/app/Boss/Vetion.php index 0949cf81..9d4910cc 100644 --- a/app/Boss/Vetion.php +++ b/app/Boss/Vetion.php @@ -18,4 +18,8 @@ class Vetion extends Model ]; protected $hidden = ['user_id']; + + public function account() { + return $this->belongsTo(\App\Account::class); + } } diff --git a/app/Boss/Vorkath.php b/app/Boss/Vorkath.php index c6d2ac0a..d3023115 100644 --- a/app/Boss/Vorkath.php +++ b/app/Boss/Vorkath.php @@ -20,4 +20,8 @@ class Vorkath extends Model ]; protected $hidden = ['user_id']; + + public function account() { + return $this->belongsTo(\App\Account::class); + } } diff --git a/app/Boss/Wintertodt.php b/app/Boss/Wintertodt.php index 3706483e..c7705bf5 100644 --- a/app/Boss/Wintertodt.php +++ b/app/Boss/Wintertodt.php @@ -24,4 +24,8 @@ class Wintertodt extends Model ]; protected $hidden = ['user_id']; + + public function account() { + return $this->belongsTo(\App\Account::class); + } } diff --git a/app/Boss/Zalcano.php b/app/Boss/Zalcano.php index 307db6b0..98da6718 100644 --- a/app/Boss/Zalcano.php +++ b/app/Boss/Zalcano.php @@ -18,4 +18,8 @@ class Zalcano extends Model ]; protected $hidden = ['user_id']; + + public function account() { + return $this->belongsTo(\App\Account::class); + } } diff --git a/app/Boss/Zulrah.php b/app/Boss/Zulrah.php index 889357a9..1845579d 100644 --- a/app/Boss/Zulrah.php +++ b/app/Boss/Zulrah.php @@ -24,4 +24,8 @@ class Zulrah extends Model ]; protected $hidden = ['user_id']; + + public function account() { + return $this->belongsTo(\App\Account::class); + } } diff --git a/app/Category.php b/app/Category.php new file mode 100644 index 00000000..6970ebab --- /dev/null +++ b/app/Category.php @@ -0,0 +1,12 @@ +hasMany(NewsPost::class); + } +} diff --git a/app/Helpers/Helper.php b/app/Helpers/Helper.php new file mode 100644 index 00000000..6f0cf55c --- /dev/null +++ b/app/Helpers/Helper.php @@ -0,0 +1,176 @@ +format('H'))+1) % 24 . ":00"; + + return $nextHour; + } + + /** + * Generates a valid random item ID. + * + * @return + */ + public static function randomItemId() { + $randomItemId = rand(0,15000); + + if (self::verifyItem($randomItemId)) { + return $randomItemId; + } else { + return self::randomItemId(); + } + } + + /** + * Verifies wheter the URL exists or not. + * + * @return + */ + public static function verifyUrl($url) { + $handle = curl_init($url); + 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) { + return true; + } else { + return false; + } + } + + /** + * Verifies wheter the item exists or not. + * + * @return + */ + public static function verifyItem($itemId) { + $itemData = 'https://www.osrsbox.com/osrsbox-db/items-json/'.$itemId.'.json'; + + if (self::verifyUrl($itemData)) { + $itemData = file_get_contents($itemData); + $itemData = json_decode($itemData, true); + + if (!$itemData['noted']) { + return true; + } else { + return false; + } + } else { + return false; + } + } + + /** + * Grabs data about item and return data based on attribute. + * + * @param integer $itemId, string $attribute + * @return + */ + public static function itemData($itemId, $attribute) { + $itemData = []; + + array_push($itemData, json_decode(file_get_contents('https://www.osrsbox.com/osrsbox-db/items-json/'.$itemId.'.json'), true)); + + return $itemData[0][$attribute]; + } + + /** + * Returns the account ID for currently logged in user. + * + * @return + */ + public static function sessionAccountId() { + return Auth::user()->member->first()->user_id; + } + + public static function listSkills() { + return ["attack","defence","strength","hitpoints","ranged","prayer","magic","cooking","woodcutting","fletching","fishing","firemaking","crafting","smithing","mining","herblore","agility","thieving","slayer","farming","runecrafting","hunter","construction"]; + } + + public static function listClueScrollTiers() { + return ["all", "beginner", "easy", "medium", "hard", "elite", "master"]; + } + + public static function listBosses() { + return ["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 prime", "dagannoth rex", "dagannoth supreme", "deranged archaeologist", "general graardor", "giant mole","grotesque guardians", "hespori", "kalphite queen", "king black dragon", "kraken", "kreearra", "kril tsutsaroth", "mimic", "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"]; + } + + public static function registerAccount($accountName) { + $playerDataUrl = 'https://secure.runescape.com/m=hiscore_oldschool/index_lite.ws?player='.$accountName; + + if (self::verifyUrl($playerDataUrl)) { + // Get the $playerDataUrl file content. + $getPlayerData = file_get_contents($playerDataUrl); + + // Fetch the content from $playerDataUrl. + $playerStats = explode("\n", $getPlayerData); + + // Convert the CSV file of player stats into an array. + $playerData = []; + foreach ($playerStats as $playerStat) { + $playerData[] = str_getcsv($playerStat); + } + + $account = Account::create([ + 'username' => request('username'), + 'rank' => $playerData[0][0], + 'level' => $playerData[0][1], + 'xp' => $playerData[0][2] + ]); + + $skills = self::listSkills(); + + foreach ($skills as $key => $skill) { + DB::table($skills[$key])->insert([ + 'account_id' => $account->id, + 'rank' => $playerData[$key+1][0], + 'level' => $playerData[$key+1][1], + 'xp' => $playerData[$key+1][2], + 'created_at' => Carbon::now(), + 'updated_at' => Carbon::now() + ]); + } + + return $account; + } else { + return false; + } + } + + public static function accountStats($accountId) { + $accountSkills = []; + + $skills = self::listSkills(); + + foreach ($skills as $skillName) { + array_push($accountSkills, DB::table($skillName)->where('account_id', $accountId)->get()); + } + + return $accountSkills; + } +} diff --git a/app/Http/Controllers/AccountController.php b/app/Http/Controllers/AccountController.php new file mode 100644 index 00000000..d21ce469 --- /dev/null +++ b/app/Http/Controllers/AccountController.php @@ -0,0 +1,128 @@ +get(); + + $query = null; + + return view('account.index', compact('accounts', 'query')); + } + + /** + * Show the account creation page. + * + * @return + */ + public function create() { + if (Auth::check()) { + if (Auth::user()->account->first()) { + return view('account.create'); + // TODO limit amount of account links setting + //return redirect(route('home'))->withErrors('This profile has already been linked to a Old School RuneScape account!'); + } else { + return view('account.create'); + } + } else { + return redirect(route('login'))->withErrors(['You have to log in before linking a Old School RuneScape account!']); + } + } + + /** + * Verifies incoming account registration request. + * + * @return + */ + public function createAccountAuthStatus() { + if (Auth::check()) { + request()->validate([ + 'username' => ['required', 'string', 'min:1', 'max:13'], + ]); + + if (AccountAuthStatus::where('username', request('username'))->count() == 0) { + if (Account::where('username', request('username'))->first()) { + if (Account::where('user_id', Auth::user()->id)->first()) { + return redirect()->back()->withErrors('You have already linked this account to your profile!'); + } + + return redirect()->back()->withErrors('This account has already been linked to another profile!'); + } else { + $playerDataUrl = 'https://secure.runescape.com/m=hiscore_oldschool/index_lite.ws?player='.str_replace(' ', '%20', request('username')); + + if (Helper::verifyUrl($playerDataUrl)) { + $authStatus = new AccountAuthStatus; + + $authStatus->user_id = Auth::user()->id; + $authStatus->username = request('username'); + $authStatus->code = substr(md5(uniqid(mt_rand(), true)), 0, 8); + $authStatus->status = "pending"; + + $authStatus->save(); + + return view('account.auth', compact('authStatus')); + } else { + return redirect()->back()->withErrors('Could not find this Old School RuneScape account!'); + } + } + } else { + return redirect()->back()->withErrors('This account already has a pending status!'); + } + } else { + return redirect(route('login'))->withErrors(['You have to log in before linking a Old School RuneScape account!']); + } + } + + /** + * Show a specific account and skills data from a URL request. + * + * @param string $username + * @return + */ + public function show($account) { + $account = Account::findOrFail($account); + + return view('account.show', compact('account')); + } + + /** + * Returns search results from query. + * + * @return + */ + public function search() { + request()->validate([ + 'search' => ['required', 'string', 'min:1', 'max:13'], + ]); + + $query = request('search'); + + $accounts = Account::with('user')->where('username', 'LIKE', '%' . $query . '%')->paginate(10); + + if (count($accounts) === 0) { + return redirect(route('account'))->withErrors(['No search results for "'.$query.'"!']); + } else { + return view('account.index', compact('accounts', 'query')); + } + } +} diff --git a/app/Http/Controllers/Api/AccountCollectionController.php b/app/Http/Controllers/Api/AccountCollectionController.php new file mode 100644 index 00000000..2b6569a0 --- /dev/null +++ b/app/Http/Controllers/Api/AccountCollectionController.php @@ -0,0 +1,131 @@ +first(); + + if ($account) { + if (in_array($collectionType, ['all', 'boss', 'raid', 'clue', 'minigame', 'other'], true)) { + if ($collectionType === "all") { + $allCollections = Collection::select('name')->where('type', $collectionType)->get(); + } + $allCollections = Collection::select('name')->where('type', $collectionType)->get(); + + // TODO create function + // This method create a migration file for each collection model in the collections table + // $listOfS = []; + // foreach ($allCollections as $key => $collection) { + // $collectionName = $collection->name; + // if ($collectionName[strlen($collectionName) - 1] == "s") { + // $listOfS[$key] = $collectionName; + // $command = "make:migration create_".str_replace(" ", "_", $collectionName)."_table"; + // } else { + // $command = "make:migration create_".str_replace(" ", "_", $collectionName)."s_table"; + // } + + // $execute = Artisan::call($command); + // } + + $allCollectionLoot = []; + foreach ($allCollections as $key => $collection) { + $findCollection = Collection::findByName($collection->name); + + $collectionLog = $findCollection->model::where('account_id', $account->id)->first(); + + if (!$collectionLog) { + return response()->json("This account does not have any registered loot for " . $collection->name, 404); + } + + $allCollectionLoot[$key] = $collectionLog; + } + + return response()->json($allCollectionLoot, 200); + } else { + return response()->json("This collection type could not be found", 404); + } + } else { + return response()->json("This account could not be found", 404); + } + } + + public function show($accountUsername, $collectionName) { + $account = Account::where('username', $accountUsername)->first(); + + if ($account) { + $collection = Collection::findByName($collectionName); + + if ($collection) { + $collectionLog = $collection->model::where('account_id', $account->id)->first(); + + if ($collectionLog) { + return response()->json($collectionLog, 200); + } else { + return response()->json("This account does not have any registered loot for " . $collection->name, 404); + } + } else { + return response()->json("This collection could not be found", 404); + } + } else { + return response()->json("This account could not be found", 404); + } + } + + public function update($accountUsername, $collectionName, Request $request) { + $account = Account::where('username', $accountUsername)->first(); + + if ($account) { + $collection = Collection::findByName($collectionName); + + if ($collection) { + $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 + + $newValues = $request->all(); + + $sums = []; + + $sums["kill_count"] = $oldValues["kill_count"] + 1; + + $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++; + } + + $sums[$lootType] = (isset($newValues[$lootType]) ? $newValues[$lootType] : 0) + (isset($oldValues) ? $oldValues[$lootType] : 0); + } + } + + $sums["obtained"] = $uniques; + + $collectionLog->update($sums); + + return response()->json($collectionLog, 201); + } else { + return response()->json("This account does not have any registered loot for " . $collection->name, 404); + } + } else { + return response()->json("This collection could not be found", 404); + } + } else { + return response()->json("This account could not be found", 404); + } + } +} diff --git a/app/Http/Controllers/Api/AccountController.php b/app/Http/Controllers/Api/AccountController.php new file mode 100644 index 00000000..d5ff8739 --- /dev/null +++ b/app/Http/Controllers/Api/AccountController.php @@ -0,0 +1,136 @@ +firstOrFail()); + } + + /** + * Create a new account instance after a valid registration. + * + * @param string $authCode + * @return + */ + public function store($accountUsername) { + $accountAuthStatus = AccountAuthStatus::where([ + ['username', $accountUsername], + ['status', 'pending'] + ])->first(); + + if ($accountAuthStatus) { + if (in_array(request('type'), ['NORMAL', 'IRONMAN', 'HARDCORE', 'ULTIMATE'], true)) { + if (request('code') === $accountAuthStatus->code) { + $playerDataUrl = 'https://secure.runescape.com/m=hiscore_oldschool/index_lite.ws?player='.str_replace(' ', '%20', $accountUsername); + + /* Get the $playerDataUrl file content. */ + $getPlayerData = file_get_contents($playerDataUrl); + + /* Fetch the content from $playerDataUrl. */ + $playerStats = explode("\n", $getPlayerData); + + /* Convert the CSV file of player stats into an array */ + $playerData = []; + foreach ($playerStats as $playerStat) { + $playerData[] = str_getcsv($playerStat); + } + + $account = Account::create([ + 'user_id' => $accountAuthStatus->user_id, + 'type' => strtolower(request('type')), + 'username' => $accountUsername, + '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(); + + $bossCounter = 0; + + $dksKillCount = 0; + + for ($i = (count($skills) + $clueScrollAmount + 4); $i < (count($skills) + $clueScrollAmount + 4 + count($bosses)); $i++) { + $collection = Collection::findByName($bosses[$bossCounter]); + + $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[$bossCounter], ['dagannoth prime', 'dagannoth rex', 'dagannoth supreme'], true)) { + $dksKillCount += ($playerData[$i+1][1] >= 0 ? $playerData[$i+1][1] : 0); + } + + $collectionLoot->save(); + + $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. + */ + $collectionLoot = new \App\Boss\DagannothKings; + + $collectionLoot->account_id = $account->id; + $collectionLoot->kill_count = $dksKillCount; + + $collectionLoot->save(); + + $accountAuthStatus->status = "success"; + + $accountAuthStatus->save(); + + return response()->json("Success", 200); + // return redirect(route('home'))->with('message', 'Old School RuneScape account "'.request('username').'" linked!'); + } else { + return response()->json("Invalid code", 401); + } + } else { + return response()->json("Not a supported account type", 202); + } + } else { + return response()->json("This account has no pending status", 202); + } + } +} diff --git a/app/Http/Controllers/Api/HiscoreController.php b/app/Http/Controllers/Api/HiscoreController.php new file mode 100644 index 00000000..15014e4c --- /dev/null +++ b/app/Http/Controllers/Api/HiscoreController.php @@ -0,0 +1,91 @@ + 0) { + if ($skillName == "overall") { + $hiscores = Account::orderByRaw('CASE WHEN rank > 0 THEN 1 ELSE 2 END')->orderBy('rank', 'ASC')->orderBy('level', 'DESC')->orderBy('xp', 'DESC')->get(); + + $sumTotalXp = Account::sum('xp'); + + $averageTotalLevel = Account::sum('level') / Account::count(); + + $skills = Helper::listSkills(); + + $totalMaxLevel = Account::where('level', (99 * count($skills)))->count(); + } else { + $sumTotalXp = DB::table($skillName) + ->selectRaw('SUM(xp) AS total_xp') + ->first(); + + $sumTotalXp = $sumTotalXp->total_xp; + + $sumTotalLevel = DB::table($skillName) + ->selectRaw('SUM(level) AS total_level') + ->selectRaw('COUNT(*) AS total_hiscores') + ->first(); + + $averageTotalLevel = $sumTotalLevel->total_level / $sumTotalLevel->total_hiscores; + + $totalMaxLevel = DB::table($skillName) + ->selectRaw('COUNT(*) AS amount_99') + ->where('level', 99) + ->first(); + + $totalMaxLevel = $totalMaxLevel->amount_99; + + $hiscores = DB::table($skillName) + ->select($skillName.'.account_id', $skillName.'.level', $skillName.'.xp', $skillName.'.rank', 'username') + ->join('accounts', $skillName.'.account_id', '=', 'accounts.id') + ->orderByRaw('CASE WHEN '.$skillName.'.rank > 0 THEN 1 ELSE 2 END') + ->orderBy('rank', 'ASC') + ->orderBy('level', 'DESC') + ->orderBy('xp', 'DESC') + ->get(); + } + + return HiscoreResource::collection($hiscores) + ->additional(['meta' => [ + 'skill' => ucfirst($skillName), + 'total_xp' => number_format($sumTotalXp), + 'average_total_level' => round($averageTotalLevel), + 'total_max_level' => $totalMaxLevel, + ]]); + } else { + return response()->json("There are no linked accounts", 404); + } + } + + public function boss($bossName) { + if (Account::count() > 0) { + $collection = Collection::findByName($bossName); + + $boss = $collection->model::with('account')->orderBy('kill_count', 'DESC')->get(); + + $bosses = Helper::listBosses(); + + return BossHiscoreResource::collection($boss); + } else { + return response()->json("There are no linked accounts", 404); + } + } +} diff --git a/app/Http/Controllers/BossController.php b/app/Http/Controllers/BossController.php deleted file mode 100644 index a60ae285..00000000 --- a/app/Http/Controllers/BossController.php +++ /dev/null @@ -1,68 +0,0 @@ -getUser($request->header('uuid')); - - if ($user) { - $boss = Collection::findByName($bossName); - - if ($boss) { - $bossLog = $this->getUserBossLog($boss->collection_type, $user->id); - - if ($bossLog) { - $oldValues = $bossLog->getAttributes(); // Get old data - //array_splice($oldValues, count($oldValues) - 2, 2); // Remove created_at and updated_at - - $newValues = $request->all(); - - $sums = []; - - $sums["kill_count"] = $oldValues["kill_count"] + 1; - - $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++; - } - - $sums[$lootType] = (isset($newValues[$lootType]) ? $newValues[$lootType] : 0) + (isset($oldValues) ? $oldValues[$lootType] : 0); - } - } - - $sums["obtained"] = $uniques; - - $bossLog->update($sums); - - return response()->json($bossLog, 201); - } else { - return response()->json("This user does not have any registered loot for this boss", 404); - } - } else { - return response()->json("This boss does not exist", 404); - } - } else { - return response()->json("This user could not be found", 404); - } - } - - private function getUser($uuid) { - return User::where('uuid', $uuid)->first(); - } - - private function getUserBossLog($boss, $userId) { - return $boss::where('user_id', $userId)->first(); - } -} diff --git a/app/Http/Controllers/CollectionController.php b/app/Http/Controllers/CollectionController.php index 25ae0da6..723d68e2 100644 --- a/app/Http/Controllers/CollectionController.php +++ b/app/Http/Controllers/CollectionController.php @@ -16,98 +16,51 @@ class CollectionController extends Controller { - public function bossList(Request $request) { - $allCollections = Collection::select('name')->get(); - return response()->json($allCollections, 200); - } + public function list($collectionType) { + if (in_array($collectionType, ['all', 'boss', 'raid', 'clue', 'minigame', 'other'], true)) { + if ($collectionType === "all") { + $collectionList = Collection::select('name')->get(); - public function index(Request $request) { - $user = $this->getUser($request->header('uuid')); - - if ($user) { - $allCollections = Collection::get(); - - // TODO create function - // This method create a migration file for each collection model in the collections table - // $listOfS = []; - // foreach ($allCollections as $key => $collection) { - // $collectionName = $collection->name; - // if ($collectionName[strlen($collectionName) - 1] == "s") { - // $listOfS[$key] = $collectionName; - // $command = "make:migration create_".str_replace(" ", "_", $collectionName)."_table"; - // } else { - // $command = "make:migration create_".str_replace(" ", "_", $collectionName)."s_table"; - // } - - // $execute = Artisan::call($command); - // } - - $allCollectionsLoot = []; - foreach ($allCollections as $key => $collection) { - $findCollection = Collection::findByName($collection->name); - - $collectionLog = $this->getUserCollectionLog($findCollection->collection_type, $user->id); - - if (!$collectionLog) { - $collectionLog = $this->store($collection->name, $user->id); - } - - $allCollectionLoot[$key] = $collectionLog; + return response()->json($collectionList, 200); } - return response()->json($allCollectionLoot, 200); + $collectionList = Collection::select('name')->where('type', $collectionType)->get(); + + return response()->json($collectionList, 200); } else { - return response()->json("This user could not be found", 404); + return response()->json("This collection type could not be found", 404); } } - public function show($collectionName, Request $request) { - $user = $this->getUser($request->header('uuid')); - - if ($user) { - $collection = Collection::findByName($collectionName); + public function show($collectionName) { + // $collection = Collection::findByName($collectionName); - if ($collection) { - $collectionLog = $this->getUserCollectionLog($collection->collection_type, $user->id); + // if ($collection) { + // $collectionLog = $collection->model::get(); - if ($collectionLog) { - return response()->json($collectionLog, 200); - } else { - // return response()->json("This user does not have any registered loot for this collection", 404); - - $test = $this->store($collectionName, $user->id); - - return response()->json($test, 201); - } - } else { - return response()->json("This collection does not exist", 404); - } - } else { - return response()->json("This user could not be found", 404); - } + // if ($collectionLog) { + // return response()->json($collectionLog, 200); + // } else { + // return response()->json("This account does not have any registered loot for " . $collection->name, 404); + // } + // } else { + // return response()->json("This collection could not be found", 404); + // } } private function store($collectionName, $userId) { - $collection = Collection::findByName($collectionName); + // $collection = Collection::findByName($collectionName); - $collectionLoot = new $collection->collection_type; + // $collectionLoot = new $collection->collection_type; - $collectionLoot->user_id = $userId; + // $collectionLoot->user_id = $userId; - $collectionLoot->save(); + // $collectionLoot->save(); - return $collectionLoot; + // return $collectionLoot; } public function update($collectionName, Request $request) { // TODO collection log updater } - - private function getUser($uuid) { - return User::where('uuid', $uuid)->first(); - } - - private function getUserCollectionLog($collectionType, $userId) { - return $collectionType::where('user_id', $userId)->first(); - } } diff --git a/app/Http/Controllers/HomeController.php b/app/Http/Controllers/HomeController.php index 7cbc2c3f..ff62f699 100644 --- a/app/Http/Controllers/HomeController.php +++ b/app/Http/Controllers/HomeController.php @@ -3,6 +3,7 @@ namespace App\Http\Controllers; use Illuminate\Http\Request; +use Illuminate\Support\Facades\Auth; class HomeController extends Controller { @@ -23,6 +24,12 @@ public function __construct() */ public function index() { - return view('home'); + $user = Auth::user(); + + if ($user->account == null || count($user->account) <= 0) { + return redirect(route('create-account'))->withErrors(['You must link an Old School RuneScape account to access this feature!']); + } else { + return view('home', compact('user')); + } } } diff --git a/app/Http/Controllers/NewsController.php b/app/Http/Controllers/NewsController.php new file mode 100644 index 00000000..8734e065 --- /dev/null +++ b/app/Http/Controllers/NewsController.php @@ -0,0 +1,22 @@ +limit(5)->get(); + $recentPosts = NewsPost::with('user')->with('category')->with('image')->limit(5)->orderBy('created_at', 'DESC')->get(); + + return view('index', compact('recentPosts')); + } + + /** + * Show the latest account updates. + * + * @return + */ + public function updateLog() { + $updates = Account::orderBy('updated_at', 'DESC')->whereColumn('updated_at', '>', 'created_at')->get(); + + return view('update-log', compact('updates')); + } + + /** + * Show the skill hiscores. + * + * @return + */ + public function hiscore($hiscoreType, $hiscore) { + $hiscoreList = Helper::listSkills(); + + array_push($hiscoreList, "overall"); + + if ($hiscoreType == "boss") { + $hiscoreList = Helper::listBosses(); + } + + list($hiscoreListTop, $hiscoreListBottom) = array_chunk($hiscoreList, ceil(count($hiscoreList) / 2)); // Split skills array into two arrays for a top and bottom skill bar + + $accountCount = Account::count(); + + return view('hiscore', compact('hiscoreType', 'hiscore', 'hiscoreList', 'hiscoreListTop', 'hiscoreListBottom', 'accountCount')); + } +} diff --git a/app/Http/Controllers/UserController.php b/app/Http/Controllers/UserController.php new file mode 100644 index 00000000..179526f2 --- /dev/null +++ b/app/Http/Controllers/UserController.php @@ -0,0 +1,64 @@ +middleware('auth'); + } + + /** + * Show the user edit page. + * + * @param User $user + * @return + */ + public function edit(User $user) { + $user = Auth::user(); + + $randomIcons = []; + + for ($i=0; count($randomIcons) < 10; $i++) { + if ($icon_id = Helper::randomItemId()) { + array_push($randomIcons, $icon_id); + } + } + + return view('user.edit', compact('user', 'randomIcons')); + } + + /** + * Updates user after a valid request. + * + * @param User $user + * @return + */ + public function update(User $user) { + if (request('icon_id') == null || request('icon_id') == 0 || Helper::verifyItem(request('icon_id'))) { + Auth::user()->update(request()->validate([ + 'name' => ['required', 'string', 'max:255'], + 'email' => ['required', 'string', 'email', 'max:255', + Rule::unique('users')->ignore(Auth::user()->id), + ], + 'private' => ['boolean'], + 'icon_id' => ['nullable', 'integer'] + ])); + + return redirect(route('home'))->with('message', 'Profile updated!'); + } + } +} diff --git a/app/Http/Resources/AccountResource.php b/app/Http/Resources/AccountResource.php new file mode 100644 index 00000000..3b1e917f --- /dev/null +++ b/app/Http/Resources/AccountResource.php @@ -0,0 +1,48 @@ + $this->id, + 'user_id' => $this->user_id, + 'username' => $this->username, + 'rank' => (number_format($this->rank) >= 1 ? number_format($this->rank) : "Unranked"), + 'level' => $this->level, + 'xp' => (number_format($this->xp) >= 1 ? number_format($this->xp) : "Unranked"), + 'joined' => date_format($this->created_at, "d. M Y"), + 'user' => new UserResource($this->user), + ]; + } + + public function with($request) + { + $skills = Helper::listSkills(); + + $stats = []; + + foreach ($skills as $skillName) { + $stats[$skillName] = DB::table($skillName)->where('account_id', $this->id)->first(); + } + + return [ + 'meta' => [ + 'hiscores' => SkillResource::collection(collect($stats)), + ] + ]; + } +} diff --git a/app/Http/Resources/BossHiscoreResource.php b/app/Http/Resources/BossHiscoreResource.php new file mode 100644 index 00000000..169fb900 --- /dev/null +++ b/app/Http/Resources/BossHiscoreResource.php @@ -0,0 +1,23 @@ + $this->kill_count, + 'rank' => (number_format($this->rank) >= 1 ? number_format($this->rank) : "Unranked"), + 'account' => new AccountResource($this->account), + ]; + } +} diff --git a/app/Http/Resources/HiscoreResource.php b/app/Http/Resources/HiscoreResource.php new file mode 100644 index 00000000..99b9abac --- /dev/null +++ b/app/Http/Resources/HiscoreResource.php @@ -0,0 +1,25 @@ + ($request->getRequestUri() === "/api/hiscore/overall" ? $this->id : $this->account_id), + 'username' => $this->username, + 'rank' => (number_format($this->rank) >= 1 ? number_format($this->rank) : "Unranked"), + 'level' => $this->level, + 'xp' => (number_format($this->xp) >= 1 ? number_format($this->xp) : "Unranked"), + ]; + } +} diff --git a/app/Http/Resources/SkillResource.php b/app/Http/Resources/SkillResource.php new file mode 100644 index 00000000..521ba467 --- /dev/null +++ b/app/Http/Resources/SkillResource.php @@ -0,0 +1,23 @@ + (number_format($this->rank) >= 1 ? number_format($this->rank) : "Unranked"), + 'level' => $this->level, + 'xp' => (number_format($this->xp) >= 1 ? number_format($this->xp) : "Unranked"), + ]; + } +} diff --git a/app/Http/Resources/UserResource.php b/app/Http/Resources/UserResource.php new file mode 100644 index 00000000..b9cb4b84 --- /dev/null +++ b/app/Http/Resources/UserResource.php @@ -0,0 +1,22 @@ + $this->id, + 'icon_id' => $this->icon_id, + ]; + } +} diff --git a/app/Image.php b/app/Image.php new file mode 100644 index 00000000..2741f551 --- /dev/null +++ b/app/Image.php @@ -0,0 +1,16 @@ +hasMany(NewsPost::class); + } +} diff --git a/app/NewsPost.php b/app/NewsPost.php new file mode 100644 index 00000000..a6bfddc5 --- /dev/null +++ b/app/NewsPost.php @@ -0,0 +1,24 @@ +belongsTo(User::class); + } + + public function category() { + return $this->belongsTo(Category::class); + } + + public function image() { + return $this->belongsTo(Image::class); + } +} diff --git a/app/Providers/HelperServiceProvider.php b/app/Providers/HelperServiceProvider.php new file mode 100644 index 00000000..22e04e0b --- /dev/null +++ b/app/Providers/HelperServiceProvider.php @@ -0,0 +1,20 @@ +belongsTo(\App\Account::class); + } +} diff --git a/app/Raid/ChambersOfXericChallengeMode.php b/app/Raid/ChambersOfXericChallengeMode.php new file mode 100644 index 00000000..cea87a56 --- /dev/null +++ b/app/Raid/ChambersOfXericChallengeMode.php @@ -0,0 +1,20 @@ +belongsTo(\App\Account::class); + } +} diff --git a/app/Raid/TheatreOfBlood.php b/app/Raid/TheatreOfBlood.php new file mode 100644 index 00000000..6a55194a --- /dev/null +++ b/app/Raid/TheatreOfBlood.php @@ -0,0 +1,35 @@ +belongsTo(\App\Account::class); + } +} diff --git a/app/User.php b/app/User.php index e79dab7f..49021cc7 100644 --- a/app/User.php +++ b/app/User.php @@ -16,7 +16,7 @@ class User extends Authenticatable * @var array */ protected $fillable = [ - 'name', 'email', 'password', + 'name', 'email', 'password', 'private', 'icon_id', ]; /** @@ -36,4 +36,8 @@ class User extends Authenticatable protected $casts = [ 'email_verified_at' => 'datetime', ]; + + public function account() { + return $this->hasMany(Account::class); + } } diff --git a/composer.json b/composer.json index 4c63028f..97dc66bf 100644 --- a/composer.json +++ b/composer.json @@ -14,7 +14,7 @@ "guzzlehttp/guzzle": "^6.3", "laravel/framework": "^7.0", "laravel/tinker": "^2.0", - "laravel/ui": "^2.0" + "laravel/ui": "^2.1" }, "require-dev": { "facade/ignition": "^2.0", diff --git a/composer.lock b/composer.lock index 40dd1ae4..215a2822 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": "bd8320171484a9faab0c0543bcd46c97", + "content-hash": "628a3b2c934e6dcc88b76a77a0caf696", "packages": [ { "name": "asm89/stack-cors", @@ -102,12 +102,6 @@ "brick", "math" ], - "funding": [ - { - "url": "https://tidelift.com/funding/github/packagist/brick/math", - "type": "tidelift" - } - ], "time": "2020-04-15T15:59:35+00:00" }, { @@ -218,20 +212,6 @@ "uppercase", "words" ], - "funding": [ - { - "url": "https://www.doctrine-project.org/sponsorship.html", - "type": "custom" - }, - { - "url": "https://www.patreon.com/phpdoctrine", - "type": "patreon" - }, - { - "url": "https://tidelift.com/funding/github/packagist/doctrine%2Finflector", - "type": "tidelift" - } - ], "time": "2020-05-29T15:13:26+00:00" }, { @@ -294,20 +274,6 @@ "parser", "php" ], - "funding": [ - { - "url": "https://www.doctrine-project.org/sponsorship.html", - "type": "custom" - }, - { - "url": "https://www.patreon.com/phpdoctrine", - "type": "patreon" - }, - { - "url": "https://tidelift.com/funding/github/packagist/doctrine%2Flexer", - "type": "tidelift" - } - ], "time": "2020-05-25T17:44:05+00:00" }, { @@ -542,12 +508,6 @@ "crossdomain", "laravel" ], - "funding": [ - { - "url": "https://github.com/barryvdh", - "type": "github" - } - ], "time": "2020-04-28T08:47:37+00:00" }, { @@ -962,16 +922,16 @@ }, { "name": "laravel/ui", - "version": "v2.0.3", + "version": "v2.1.0", "source": { "type": "git", "url": "https://github.com/laravel/ui.git", - "reference": "15368c5328efb7ce94f35ca750acde9b496ab1b1" + "reference": "da9350533d0da60d5dc42fb7de9c561c72129bba" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laravel/ui/zipball/15368c5328efb7ce94f35ca750acde9b496ab1b1", - "reference": "15368c5328efb7ce94f35ca750acde9b496ab1b1", + "url": "https://api.github.com/repos/laravel/ui/zipball/da9350533d0da60d5dc42fb7de9c561c72129bba", + "reference": "da9350533d0da60d5dc42fb7de9c561c72129bba", "shasum": "" }, "require": { @@ -1013,7 +973,7 @@ "laravel", "ui" ], - "time": "2020-04-29T15:06:45+00:00" + "time": "2020-06-30T20:56:33+00:00" }, { "name": "league/commonmark", @@ -1082,32 +1042,6 @@ "md", "parser" ], - "funding": [ - { - "url": "https://enjoy.gitstore.app/repositories/thephpleague/commonmark", - "type": "custom" - }, - { - "url": "https://www.colinodell.com/sponsor", - "type": "custom" - }, - { - "url": "https://www.paypal.me/colinpodell/10.00", - "type": "custom" - }, - { - "url": "https://github.com/colinodell", - "type": "github" - }, - { - "url": "https://www.patreon.com/colinodell", - "type": "patreon" - }, - { - "url": "https://tidelift.com/funding/github/packagist/league/commonmark", - "type": "tidelift" - } - ], "time": "2020-06-21T20:50:13+00:00" }, { @@ -1192,12 +1126,6 @@ "sftp", "storage" ], - "funding": [ - { - "url": "https://offset.earth/frankdejonge", - "type": "other" - } - ], "time": "2020-05-18T15:13:39+00:00" }, { @@ -1279,16 +1207,6 @@ "logging", "psr-3" ], - "funding": [ - { - "url": "https://github.com/Seldaek", - "type": "github" - }, - { - "url": "https://tidelift.com/funding/github/packagist/monolog/monolog", - "type": "tidelift" - } - ], "time": "2020-05-22T08:12:19+00:00" }, { @@ -1362,16 +1280,6 @@ "datetime", "time" ], - "funding": [ - { - "url": "https://opencollective.com/Carbon", - "type": "open_collective" - }, - { - "url": "https://tidelift.com/funding/github/packagist/nesbot/carbon", - "type": "tidelift" - } - ], "time": "2020-05-24T18:27:52+00:00" }, { @@ -1540,16 +1448,6 @@ "php", "type" ], - "funding": [ - { - "url": "https://github.com/GrahamCampbell", - "type": "github" - }, - { - "url": "https://tidelift.com/funding/github/packagist/phpoption/phpoption", - "type": "tidelift" - } - ], "time": "2020-06-07T10:40:07+00:00" }, { @@ -2044,12 +1942,6 @@ "identifier", "uuid" ], - "funding": [ - { - "url": "https://github.com/ramsey", - "type": "github" - } - ], "time": "2020-03-29T20:13:32+00:00" }, { @@ -2191,20 +2083,6 @@ ], "description": "Symfony Console Component", "homepage": "https://symfony.com", - "funding": [ - { - "url": "https://symfony.com/sponsor", - "type": "custom" - }, - { - "url": "https://github.com/fabpot", - "type": "github" - }, - { - "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", - "type": "tidelift" - } - ], "time": "2020-06-15T12:59:21+00:00" }, { @@ -2258,34 +2136,20 @@ ], "description": "Symfony CssSelector Component", "homepage": "https://symfony.com", - "funding": [ - { - "url": "https://symfony.com/sponsor", - "type": "custom" - }, - { - "url": "https://github.com/fabpot", - "type": "github" - }, - { - "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", - "type": "tidelift" - } - ], "time": "2020-05-20T17:43:50+00:00" }, { "name": "symfony/deprecation-contracts", - "version": "v2.1.2", + "version": "v2.1.3", "source": { "type": "git", "url": "https://github.com/symfony/deprecation-contracts.git", - "reference": "dd99cb3a0aff6cadd2a8d7d7ed72c2161e218337" + "reference": "5e20b83385a77593259c9f8beb2c43cd03b2ac14" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/deprecation-contracts/zipball/dd99cb3a0aff6cadd2a8d7d7ed72c2161e218337", - "reference": "dd99cb3a0aff6cadd2a8d7d7ed72c2161e218337", + "url": "https://api.github.com/repos/symfony/deprecation-contracts/zipball/5e20b83385a77593259c9f8beb2c43cd03b2ac14", + "reference": "5e20b83385a77593259c9f8beb2c43cd03b2ac14", "shasum": "" }, "require": { @@ -2295,6 +2159,10 @@ "extra": { "branch-alias": { "dev-master": "2.1-dev" + }, + "thanks": { + "name": "symfony/contracts", + "url": "https://github.com/symfony/contracts" } }, "autoload": { @@ -2336,16 +2204,16 @@ }, { "name": "symfony/error-handler", - "version": "v5.1.2", + "version": "v5.1.5", "source": { "type": "git", "url": "https://github.com/symfony/error-handler.git", - "reference": "7d0b927b9d3dc41d7d46cda38cbfcd20cdcbb896" + "reference": "525636d4b84e06c6ca72d96b6856b5b169416e6a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/error-handler/zipball/7d0b927b9d3dc41d7d46cda38cbfcd20cdcbb896", - "reference": "7d0b927b9d3dc41d7d46cda38cbfcd20cdcbb896", + "url": "https://api.github.com/repos/symfony/error-handler/zipball/525636d4b84e06c6ca72d96b6856b5b169416e6a", + "reference": "525636d4b84e06c6ca72d96b6856b5b169416e6a", "shasum": "" }, "require": { @@ -2407,16 +2275,16 @@ }, { "name": "symfony/event-dispatcher", - "version": "v5.1.2", + "version": "v5.1.5", "source": { "type": "git", "url": "https://github.com/symfony/event-dispatcher.git", - "reference": "cc0d059e2e997e79ca34125a52f3e33de4424ac7" + "reference": "94871fc0a69c3c5da57764187724cdce0755899c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/cc0d059e2e997e79ca34125a52f3e33de4424ac7", - "reference": "cc0d059e2e997e79ca34125a52f3e33de4424ac7", + "url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/94871fc0a69c3c5da57764187724cdce0755899c", + "reference": "94871fc0a69c3c5da57764187724cdce0755899c", "shasum": "" }, "require": { @@ -2493,16 +2361,16 @@ }, { "name": "symfony/event-dispatcher-contracts", - "version": "v2.1.2", + "version": "v2.1.3", "source": { "type": "git", "url": "https://github.com/symfony/event-dispatcher-contracts.git", - "reference": "405952c4e90941a17e52ef7489a2bd94870bb290" + "reference": "f6f613d74cfc5a623fc36294d3451eb7fa5a042b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/event-dispatcher-contracts/zipball/405952c4e90941a17e52ef7489a2bd94870bb290", - "reference": "405952c4e90941a17e52ef7489a2bd94870bb290", + "url": "https://api.github.com/repos/symfony/event-dispatcher-contracts/zipball/f6f613d74cfc5a623fc36294d3451eb7fa5a042b", + "reference": "f6f613d74cfc5a623fc36294d3451eb7fa5a042b", "shasum": "" }, "require": { @@ -2516,6 +2384,10 @@ "extra": { "branch-alias": { "dev-master": "2.1-dev" + }, + "thanks": { + "name": "symfony/contracts", + "url": "https://github.com/symfony/contracts" } }, "autoload": { @@ -2610,34 +2482,20 @@ ], "description": "Symfony Finder Component", "homepage": "https://symfony.com", - "funding": [ - { - "url": "https://symfony.com/sponsor", - "type": "custom" - }, - { - "url": "https://github.com/fabpot", - "type": "github" - }, - { - "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", - "type": "tidelift" - } - ], "time": "2020-05-20T17:43:50+00:00" }, { "name": "symfony/http-foundation", - "version": "v5.1.2", + "version": "v5.1.5", "source": { "type": "git", "url": "https://github.com/symfony/http-foundation.git", - "reference": "f93055171b847915225bd5b0a5792888419d8d75" + "reference": "41a4647f12870e9d41d9a7d72ff0614a27208558" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/http-foundation/zipball/f93055171b847915225bd5b0a5792888419d8d75", - "reference": "f93055171b847915225bd5b0a5792888419d8d75", + "url": "https://api.github.com/repos/symfony/http-foundation/zipball/41a4647f12870e9d41d9a7d72ff0614a27208558", + "reference": "41a4647f12870e9d41d9a7d72ff0614a27208558", "shasum": "" }, "require": { @@ -2703,16 +2561,16 @@ }, { "name": "symfony/http-kernel", - "version": "v5.1.2", + "version": "v5.1.5", "source": { "type": "git", "url": "https://github.com/symfony/http-kernel.git", - "reference": "a18c27ace1ef344ffcb129a5b089bad7643b387a" + "reference": "3e32676e6cb5d2081c91a56783471ff8a7f7110b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/http-kernel/zipball/a18c27ace1ef344ffcb129a5b089bad7643b387a", - "reference": "a18c27ace1ef344ffcb129a5b089bad7643b387a", + "url": "https://api.github.com/repos/symfony/http-kernel/zipball/3e32676e6cb5d2081c91a56783471ff8a7f7110b", + "reference": "3e32676e6cb5d2081c91a56783471ff8a7f7110b", "shasum": "" }, "require": { @@ -2875,34 +2733,20 @@ "mime", "mime-type" ], - "funding": [ - { - "url": "https://symfony.com/sponsor", - "type": "custom" - }, - { - "url": "https://github.com/fabpot", - "type": "github" - }, - { - "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", - "type": "tidelift" - } - ], "time": "2020-06-09T15:07:35+00:00" }, { "name": "symfony/polyfill-ctype", - "version": "v1.17.0", + "version": "v1.18.1", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-ctype.git", - "reference": "e94c8b1bbe2bc77507a1056cdb06451c75b427f9" + "reference": "1c302646f6efc070cd46856e600e5e0684d6b454" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/e94c8b1bbe2bc77507a1056cdb06451c75b427f9", - "reference": "e94c8b1bbe2bc77507a1056cdb06451c75b427f9", + "url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/1c302646f6efc070cd46856e600e5e0684d6b454", + "reference": "1c302646f6efc070cd46856e600e5e0684d6b454", "shasum": "" }, "require": { @@ -2914,7 +2758,11 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "1.17-dev" + "dev-master": "1.18-dev" + }, + "thanks": { + "name": "symfony/polyfill", + "url": "https://github.com/symfony/polyfill" } }, "autoload": { @@ -3020,20 +2868,6 @@ "portable", "shim" ], - "funding": [ - { - "url": "https://symfony.com/sponsor", - "type": "custom" - }, - { - "url": "https://github.com/fabpot", - "type": "github" - }, - { - "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", - "type": "tidelift" - } - ], "time": "2020-05-12T16:47:27+00:00" }, { @@ -3094,20 +2928,6 @@ "portable", "shim" ], - "funding": [ - { - "url": "https://symfony.com/sponsor", - "type": "custom" - }, - { - "url": "https://github.com/fabpot", - "type": "github" - }, - { - "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", - "type": "tidelift" - } - ], "time": "2020-05-12T16:47:27+00:00" }, { @@ -3170,20 +2990,6 @@ "portable", "shim" ], - "funding": [ - { - "url": "https://symfony.com/sponsor", - "type": "custom" - }, - { - "url": "https://github.com/fabpot", - "type": "github" - }, - { - "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", - "type": "tidelift" - } - ], "time": "2020-05-12T16:47:27+00:00" }, { @@ -3247,34 +3053,20 @@ "portable", "shim" ], - "funding": [ - { - "url": "https://symfony.com/sponsor", - "type": "custom" - }, - { - "url": "https://github.com/fabpot", - "type": "github" - }, - { - "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", - "type": "tidelift" - } - ], "time": "2020-05-12T16:14:59+00:00" }, { "name": "symfony/polyfill-mbstring", - "version": "v1.17.0", + "version": "v1.18.1", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-mbstring.git", - "reference": "fa79b11539418b02fc5e1897267673ba2c19419c" + "reference": "a6977d63bf9a0ad4c65cd352709e230876f9904a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/fa79b11539418b02fc5e1897267673ba2c19419c", - "reference": "fa79b11539418b02fc5e1897267673ba2c19419c", + "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/a6977d63bf9a0ad4c65cd352709e230876f9904a", + "reference": "a6977d63bf9a0ad4c65cd352709e230876f9904a", "shasum": "" }, "require": { @@ -3286,7 +3078,11 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "1.17-dev" + "dev-master": "1.18-dev" + }, + "thanks": { + "name": "symfony/polyfill", + "url": "https://github.com/symfony/polyfill" } }, "autoload": { @@ -3389,34 +3185,20 @@ "portable", "shim" ], - "funding": [ - { - "url": "https://symfony.com/sponsor", - "type": "custom" - }, - { - "url": "https://github.com/fabpot", - "type": "github" - }, - { - "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", - "type": "tidelift" - } - ], "time": "2020-05-12T16:47:27+00:00" }, { "name": "symfony/polyfill-php73", - "version": "v1.17.0", + "version": "v1.18.1", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-php73.git", - "reference": "a760d8964ff79ab9bf057613a5808284ec852ccc" + "reference": "fffa1a52a023e782cdcc221d781fe1ec8f87fcca" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-php73/zipball/a760d8964ff79ab9bf057613a5808284ec852ccc", - "reference": "a760d8964ff79ab9bf057613a5808284ec852ccc", + "url": "https://api.github.com/repos/symfony/polyfill-php73/zipball/fffa1a52a023e782cdcc221d781fe1ec8f87fcca", + "reference": "fffa1a52a023e782cdcc221d781fe1ec8f87fcca", "shasum": "" }, "require": { @@ -3425,7 +3207,11 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "1.17-dev" + "dev-master": "1.18-dev" + }, + "thanks": { + "name": "symfony/polyfill", + "url": "https://github.com/symfony/polyfill" } }, "autoload": { @@ -3479,16 +3265,16 @@ }, { "name": "symfony/polyfill-php80", - "version": "v1.17.0", + "version": "v1.18.1", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-php80.git", - "reference": "5e30b2799bc1ad68f7feb62b60a73743589438dd" + "reference": "d87d5766cbf48d72388a9f6b85f280c8ad51f981" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-php80/zipball/5e30b2799bc1ad68f7feb62b60a73743589438dd", - "reference": "5e30b2799bc1ad68f7feb62b60a73743589438dd", + "url": "https://api.github.com/repos/symfony/polyfill-php80/zipball/d87d5766cbf48d72388a9f6b85f280c8ad51f981", + "reference": "d87d5766cbf48d72388a9f6b85f280c8ad51f981", "shasum": "" }, "require": { @@ -3497,7 +3283,11 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "1.17-dev" + "dev-master": "1.18-dev" + }, + "thanks": { + "name": "symfony/polyfill", + "url": "https://github.com/symfony/polyfill" } }, "autoload": { @@ -3601,20 +3391,6 @@ ], "description": "Symfony Process Component", "homepage": "https://symfony.com", - "funding": [ - { - "url": "https://symfony.com/sponsor", - "type": "custom" - }, - { - "url": "https://github.com/fabpot", - "type": "github" - }, - { - "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", - "type": "tidelift" - } - ], "time": "2020-05-30T20:35:19+00:00" }, { @@ -3693,20 +3469,6 @@ "uri", "url" ], - "funding": [ - { - "url": "https://symfony.com/sponsor", - "type": "custom" - }, - { - "url": "https://github.com/fabpot", - "type": "github" - }, - { - "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", - "type": "tidelift" - } - ], "time": "2020-06-10T11:49:58+00:00" }, { @@ -3765,20 +3527,6 @@ "interoperability", "standards" ], - "funding": [ - { - "url": "https://symfony.com/sponsor", - "type": "custom" - }, - { - "url": "https://github.com/fabpot", - "type": "github" - }, - { - "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", - "type": "tidelift" - } - ], "time": "2020-05-20T17:43:50+00:00" }, { @@ -3850,20 +3598,6 @@ "utf-8", "utf8" ], - "funding": [ - { - "url": "https://symfony.com/sponsor", - "type": "custom" - }, - { - "url": "https://github.com/fabpot", - "type": "github" - }, - { - "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", - "type": "tidelift" - } - ], "time": "2020-06-11T12:16:36+00:00" }, { @@ -3942,20 +3676,6 @@ ], "description": "Symfony Translation Component", "homepage": "https://symfony.com", - "funding": [ - { - "url": "https://symfony.com/sponsor", - "type": "custom" - }, - { - "url": "https://github.com/fabpot", - "type": "github" - }, - { - "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", - "type": "tidelift" - } - ], "time": "2020-05-30T20:35:19+00:00" }, { @@ -4013,34 +3733,20 @@ "interoperability", "standards" ], - "funding": [ - { - "url": "https://symfony.com/sponsor", - "type": "custom" - }, - { - "url": "https://github.com/fabpot", - "type": "github" - }, - { - "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", - "type": "tidelift" - } - ], "time": "2020-05-20T17:43:50+00:00" }, { "name": "symfony/var-dumper", - "version": "v5.1.2", + "version": "v5.1.5", "source": { "type": "git", "url": "https://github.com/symfony/var-dumper.git", - "reference": "46a942903059b0b05e601f00eb64179e05578c0f" + "reference": "b43a3905262bcf97b2510f0621f859ca4f5287be" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/var-dumper/zipball/46a942903059b0b05e601f00eb64179e05578c0f", - "reference": "46a942903059b0b05e601f00eb64179e05578c0f", + "url": "https://api.github.com/repos/symfony/var-dumper/zipball/b43a3905262bcf97b2510f0621f859ca4f5287be", + "reference": "b43a3905262bcf97b2510f0621f859ca4f5287be", "shasum": "" }, "require": { @@ -4230,16 +3936,6 @@ "env", "environment" ], - "funding": [ - { - "url": "https://github.com/GrahamCampbell", - "type": "github" - }, - { - "url": "https://tidelift.com/funding/github/packagist/vlucas/phpdotenv", - "type": "tidelift" - } - ], "time": "2020-06-07T18:25:35+00:00" }, { @@ -4288,24 +3984,6 @@ "clean", "php" ], - "funding": [ - { - "url": "https://www.paypal.me/moelleken", - "type": "custom" - }, - { - "url": "https://github.com/voku", - "type": "github" - }, - { - "url": "https://www.patreon.com/voku", - "type": "patreon" - }, - { - "url": "https://tidelift.com/funding/github/packagist/voku/portable-ascii", - "type": "tidelift" - } - ], "time": "2020-06-15T23:49:30+00:00" } ], @@ -4364,20 +4042,6 @@ "constructor", "instantiate" ], - "funding": [ - { - "url": "https://www.doctrine-project.org/sponsorship.html", - "type": "custom" - }, - { - "url": "https://www.patreon.com/phpdoctrine", - "type": "patreon" - }, - { - "url": "https://tidelift.com/funding/github/packagist/doctrine%2Finstantiator", - "type": "tidelift" - } - ], "time": "2020-05-29T17:27:14+00:00" }, { @@ -4432,12 +4096,6 @@ "flare", "reporting" ], - "funding": [ - { - "url": "https://www.patreon.com/spatie", - "type": "patreon" - } - ], "time": "2020-03-02T15:52:04+00:00" }, { @@ -4940,20 +4598,6 @@ "php", "symfony" ], - "funding": [ - { - "url": "https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=66BYDWAT92N6L", - "type": "custom" - }, - { - "url": "https://github.com/nunomaduro", - "type": "github" - }, - { - "url": "https://www.patreon.com/nunomaduro", - "type": "patreon" - } - ], "time": "2020-04-04T19:56:08+00:00" }, { @@ -5519,7 +5163,6 @@ "keywords": [ "tokenizer" ], - "abandoned": true, "time": "2019-09-17T06:23:10+00:00" }, { @@ -5603,16 +5246,6 @@ "testing", "xunit" ], - "funding": [ - { - "url": "https://phpunit.de/donate.html", - "type": "custom" - }, - { - "url": "https://github.com/sebastianbergmann", - "type": "github" - } - ], "time": "2020-06-21T06:32:54+00:00" }, { @@ -5682,12 +5315,6 @@ "highlight.php", "syntax" ], - "funding": [ - { - "url": "https://github.com/allejo", - "type": "github" - } - ], "time": "2020-03-02T05:59:21+00:00" }, { @@ -6366,20 +5993,6 @@ ], "description": "Symfony Yaml Component", "homepage": "https://symfony.com", - "funding": [ - { - "url": "https://symfony.com/sponsor", - "type": "custom" - }, - { - "url": "https://github.com/fabpot", - "type": "github" - }, - { - "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", - "type": "tidelift" - } - ], "time": "2020-05-20T17:43:50+00:00" }, { @@ -6480,6 +6093,5 @@ "platform": { "php": "^7.2.5" }, - "platform-dev": [], - "plugin-api-version": "1.1.0" + "platform-dev": [] } diff --git a/config/app.php b/config/app.php index 8409e00e..ac08d12f 100644 --- a/config/app.php +++ b/config/app.php @@ -171,10 +171,12 @@ */ App\Providers\AppServiceProvider::class, App\Providers\AuthServiceProvider::class, - // App\Providers\BroadcastServiceProvider::class, + App\Providers\BroadcastServiceProvider::class, App\Providers\EventServiceProvider::class, App\Providers\RouteServiceProvider::class, + App\Providers\HelperServiceProvider::class, + ], /* @@ -226,6 +228,7 @@ 'URL' => Illuminate\Support\Facades\URL::class, 'Validator' => Illuminate\Support\Facades\Validator::class, 'View' => Illuminate\Support\Facades\View::class, + 'Helper' => App\Helpers\Helper::class, ], diff --git a/config/database.php b/config/database.php index b42d9b30..d307bdb1 100644 --- a/config/database.php +++ b/config/database.php @@ -58,9 +58,10 @@ 'prefix_indexes' => true, 'strict' => true, 'engine' => null, - 'options' => extension_loaded('pdo_mysql') ? array_filter([ - PDO::MYSQL_ATTR_SSL_CA => env('MYSQL_ATTR_SSL_CA'), - ]) : [], + 'sslmode' => env('DB_SSLMODE', 'prefer'), + 'options' => (env('MYSQL_SSL') && extension_loaded('pdo_mysql')) ? [ + PDO::MYSQL_ATTR_SSL_KEY => '\\ssl\\BaltimoreCyberTrustRoot.crt.pem', // Change to /ssl/BaltimoreCyberTrustRoot.crt.pem if Linux/macOS + ] : [], ], 'pgsql' => [ 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 885a3bef..4fdc4dd9 100644 --- a/database/migrations/2014_10_12_000000_create_users_table.php +++ b/database/migrations/2014_10_12_000000_create_users_table.php @@ -21,6 +21,8 @@ public function up() $table->timestamp('email_verified_at')->nullable(); $table->string('password'); $table->rememberToken(); + $table->integer('icon_id')->nullable(); + $table->boolean('private')->default(false); $table->timestamps(); }); } 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 00b2bb7f..3e8bf079 100644 --- a/database/migrations/2020_06_21_235134_create_collections_table.php +++ b/database/migrations/2020_06_21_235134_create_collections_table.php @@ -15,7 +15,8 @@ public function up() { Schema::create('collections', function (Blueprint $table) { $table->string('name')->unique(); - $table->string('collection_type'); + $table->enum('type', ['boss', 'raid', 'clue', 'minigame', 'other']); + $table->string('model'); }); } diff --git a/database/migrations/2020_08_03_230720_create_abyssal_sire_table.php b/database/migrations/2020_08_03_230720_create_abyssal_sire_table.php index d3ee1577..fdfb5c53 100644 --- a/database/migrations/2020_08_03_230720_create_abyssal_sire_table.php +++ b/database/migrations/2020_08_03_230720_create_abyssal_sire_table.php @@ -15,9 +15,10 @@ public function up() { Schema::create('abyssal_sire', function (Blueprint $table) { $table->id(); - $table->integer('user_id')->unsigned()->unique(); - $table->integer('obtained')->default(0)->unsigned(); + $table->integer('account_id')->unsigned()->unique(); $table->integer('kill_count')->default(0)->unsigned(); + $table->integer('rank')->default(0)->unsigned(); + $table->integer('obtained')->default(0)->unsigned(); $table->integer('abyssal_orphan')->default(0)->unsigned(); $table->integer('unsired')->default(0)->unsigned(); $table->integer('abyssal_head')->default(0)->unsigned(); diff --git a/database/migrations/2020_08_03_230721_create_alchemical_hydra_table.php b/database/migrations/2020_08_03_230721_create_alchemical_hydra_table.php index c01e1804..9a4f6a15 100644 --- a/database/migrations/2020_08_03_230721_create_alchemical_hydra_table.php +++ b/database/migrations/2020_08_03_230721_create_alchemical_hydra_table.php @@ -15,9 +15,10 @@ public function up() { Schema::create('alchemical_hydra', function (Blueprint $table) { $table->id(); - $table->integer('user_id')->unsigned()->unique(); - $table->integer('obtained')->default(0)->unsigned(); + $table->integer('account_id')->unsigned()->unique(); $table->integer('kill_count')->default(0)->unsigned(); + $table->integer('rank')->default(0)->unsigned(); + $table->integer('obtained')->default(0)->unsigned(); $table->integer('ikkle_hydra')->default(0)->unsigned(); $table->integer('hydras_claw')->default(0)->unsigned(); $table->integer('hydra_tail')->default(0)->unsigned(); diff --git a/database/migrations/2020_08_03_230721_create_barrows_chests_table.php b/database/migrations/2020_08_03_230721_create_barrows_chests_table.php index 53cc29ec..498c69a6 100644 --- a/database/migrations/2020_08_03_230721_create_barrows_chests_table.php +++ b/database/migrations/2020_08_03_230721_create_barrows_chests_table.php @@ -15,9 +15,10 @@ public function up() { Schema::create('barrows_chests', function (Blueprint $table) { $table->id(); - $table->integer('user_id')->unsigned()->unique(); - $table->integer('obtained')->default(0)->unsigned(); + $table->integer('account_id')->unsigned()->unique(); $table->integer('kill_count')->default(0)->unsigned(); + $table->integer('rank')->default(0)->unsigned(); + $table->integer('obtained')->default(0)->unsigned(); $table->integer('karils_coif')->default(0)->unsigned(); $table->integer('ahrims_hood')->default(0)->unsigned(); $table->integer('dharoks_helm')->default(0)->unsigned(); diff --git a/database/migrations/2020_08_03_230721_create_bryophyta_table.php b/database/migrations/2020_08_03_230721_create_bryophyta_table.php index e7f3b988..4471996a 100644 --- a/database/migrations/2020_08_03_230721_create_bryophyta_table.php +++ b/database/migrations/2020_08_03_230721_create_bryophyta_table.php @@ -15,9 +15,10 @@ public function up() { Schema::create('bryophyta', function (Blueprint $table) { $table->id(); - $table->integer('user_id')->unsigned()->unique(); - $table->integer('obtained')->default(0)->unsigned(); + $table->integer('account_id')->unsigned()->unique(); $table->integer('kill_count')->default(0)->unsigned(); + $table->integer('rank')->default(0)->unsigned(); + $table->integer('obtained')->default(0)->unsigned(); $table->integer('bryophytas_essence')->default(0)->unsigned(); $table->timestamps(); }); diff --git a/database/migrations/2020_08_03_230721_create_callisto_table.php b/database/migrations/2020_08_03_230721_create_callisto_table.php index e35b5191..d3c164c8 100644 --- a/database/migrations/2020_08_03_230721_create_callisto_table.php +++ b/database/migrations/2020_08_03_230721_create_callisto_table.php @@ -15,9 +15,10 @@ public function up() { Schema::create('callisto', function (Blueprint $table) { $table->id(); - $table->integer('user_id')->unsigned()->unique(); - $table->integer('obtained')->default(0)->unsigned(); + $table->integer('account_id')->unsigned()->unique(); $table->integer('kill_count')->default(0)->unsigned(); + $table->integer('rank')->default(0)->unsigned(); + $table->integer('obtained')->default(0)->unsigned(); $table->integer('callisto_cub')->default(0)->unsigned(); $table->integer('tyrannical_ring')->default(0)->unsigned(); $table->integer('dragon_pickaxe')->default(0)->unsigned(); diff --git a/database/migrations/2020_08_03_230721_create_cerberus_table.php b/database/migrations/2020_08_03_230721_create_cerberus_table.php index c262d220..7d01e479 100644 --- a/database/migrations/2020_08_03_230721_create_cerberus_table.php +++ b/database/migrations/2020_08_03_230721_create_cerberus_table.php @@ -15,9 +15,10 @@ public function up() { Schema::create('cerberus', function (Blueprint $table) { $table->id(); - $table->integer('user_id')->unsigned()->unique(); - $table->integer('obtained')->default(0)->unsigned(); + $table->integer('account_id')->unsigned()->unique(); $table->integer('kill_count')->default(0)->unsigned(); + $table->integer('rank')->default(0)->unsigned(); + $table->integer('obtained')->default(0)->unsigned(); $table->integer('hellpuppy')->default(0)->unsigned(); $table->integer('eternal_crystal')->default(0)->unsigned(); $table->integer('pegasian_crystal')->default(0)->unsigned(); diff --git a/database/migrations/2020_08_03_230722_create_chaos_elemental_table.php b/database/migrations/2020_08_03_230722_create_chaos_elemental_table.php index 694b11e6..90748f50 100644 --- a/database/migrations/2020_08_03_230722_create_chaos_elemental_table.php +++ b/database/migrations/2020_08_03_230722_create_chaos_elemental_table.php @@ -15,9 +15,10 @@ public function up() { Schema::create('chaos_elemental', function (Blueprint $table) { $table->id(); - $table->integer('user_id')->unsigned()->unique(); - $table->integer('obtained')->default(0)->unsigned(); + $table->integer('account_id')->unsigned()->unique(); $table->integer('kill_count')->default(0)->unsigned(); + $table->integer('rank')->default(0)->unsigned(); + $table->integer('obtained')->default(0)->unsigned(); $table->integer('pet_chaos_elemental')->default(0)->unsigned(); $table->integer('dragon_pickaxe')->default(0)->unsigned(); $table->integer('dragon_2h_sword')->default(0)->unsigned(); diff --git a/database/migrations/2020_08_03_230722_create_chaos_fanatic_table.php b/database/migrations/2020_08_03_230722_create_chaos_fanatic_table.php index a7c6ed59..eed2fbd2 100644 --- a/database/migrations/2020_08_03_230722_create_chaos_fanatic_table.php +++ b/database/migrations/2020_08_03_230722_create_chaos_fanatic_table.php @@ -15,9 +15,10 @@ public function up() { Schema::create('chaos_fanatic', function (Blueprint $table) { $table->id(); - $table->integer('user_id')->unsigned()->unique(); - $table->integer('obtained')->default(0)->unsigned(); + $table->integer('account_id')->unsigned()->unique(); $table->integer('kill_count')->default(0)->unsigned(); + $table->integer('rank')->default(0)->unsigned(); + $table->integer('obtained')->default(0)->unsigned(); $table->integer('pet_chaos_elemental')->default(0)->unsigned(); $table->integer('odium_shard_1')->default(0)->unsigned(); $table->integer('malediction_shard_1')->default(0)->unsigned(); diff --git a/database/migrations/2020_08_03_230722_create_commander_zilyana_table.php b/database/migrations/2020_08_03_230722_create_commander_zilyana_table.php index e90cf774..d64757d1 100644 --- a/database/migrations/2020_08_03_230722_create_commander_zilyana_table.php +++ b/database/migrations/2020_08_03_230722_create_commander_zilyana_table.php @@ -15,9 +15,10 @@ public function up() { Schema::create('commander_zilyana', function (Blueprint $table) { $table->id(); - $table->integer('user_id')->unsigned()->unique(); - $table->integer('obtained')->default(0)->unsigned(); + $table->integer('account_id')->unsigned()->unique(); $table->integer('kill_count')->default(0)->unsigned(); + $table->integer('rank')->default(0)->unsigned(); + $table->integer('obtained')->default(0)->unsigned(); $table->integer('pet_zilyana')->default(0)->unsigned(); $table->integer('armadyl_crossbow')->default(0)->unsigned(); $table->integer('saradomin_hilt')->default(0)->unsigned(); diff --git a/database/migrations/2020_08_03_230722_create_corporeal_beast_table.php b/database/migrations/2020_08_03_230722_create_corporeal_beast_table.php index e93143dd..8cc45f14 100644 --- a/database/migrations/2020_08_03_230722_create_corporeal_beast_table.php +++ b/database/migrations/2020_08_03_230722_create_corporeal_beast_table.php @@ -15,9 +15,10 @@ public function up() { Schema::create('corporeal_beast', function (Blueprint $table) { $table->id(); - $table->integer('user_id')->unsigned()->unique(); - $table->integer('obtained')->default(0)->unsigned(); + $table->integer('account_id')->unsigned()->unique(); $table->integer('kill_count')->default(0)->unsigned(); + $table->integer('rank')->default(0)->unsigned(); + $table->integer('obtained')->default(0)->unsigned(); $table->integer('pet_dark_core')->default(0)->unsigned(); $table->integer('elysian_sigil')->default(0)->unsigned(); $table->integer('spectral_sigil')->default(0)->unsigned(); diff --git a/database/migrations/2020_08_03_230722_create_crazy_archaeologist_table.php b/database/migrations/2020_08_03_230722_create_crazy_archaeologist_table.php index a7c0a8b9..2ec69fb3 100644 --- a/database/migrations/2020_08_03_230722_create_crazy_archaeologist_table.php +++ b/database/migrations/2020_08_03_230722_create_crazy_archaeologist_table.php @@ -15,9 +15,10 @@ public function up() { Schema::create('crazy_archaeologist', function (Blueprint $table) { $table->id(); - $table->integer('user_id')->unsigned()->unique(); - $table->integer('obtained')->default(0)->unsigned(); + $table->integer('account_id')->unsigned()->unique(); $table->integer('kill_count')->default(0)->unsigned(); + $table->integer('rank')->default(0)->unsigned(); + $table->integer('obtained')->default(0)->unsigned(); $table->integer('odium_shard_2')->default(0)->unsigned(); $table->integer('malediction_shard_2')->default(0)->unsigned(); $table->integer('fedora')->default(0)->unsigned(); diff --git a/database/migrations/2020_08_03_230723_create_dagannoth_kings_table.php b/database/migrations/2020_08_03_230723_create_dagannoth_kings_table.php index aa0bcb43..93f1e762 100644 --- a/database/migrations/2020_08_03_230723_create_dagannoth_kings_table.php +++ b/database/migrations/2020_08_03_230723_create_dagannoth_kings_table.php @@ -15,9 +15,9 @@ public function up() { Schema::create('dagannoth_kings', function (Blueprint $table) { $table->id(); - $table->integer('user_id')->unsigned()->unique(); - $table->integer('obtained')->default(0)->unsigned(); + $table->integer('account_id')->unsigned()->unique(); $table->integer('kill_count')->default(0)->unsigned(); + $table->integer('obtained')->default(0)->unsigned(); $table->integer('pet_dagannoth_prime')->default(0)->unsigned(); $table->integer('pet_dagannoth_supreme')->default(0)->unsigned(); $table->integer('pet_dagannoth_rex')->default(0)->unsigned(); diff --git a/database/migrations/2020_08_03_230723_create_general_graardor_table.php b/database/migrations/2020_08_03_230723_create_general_graardor_table.php index 730ec37d..e14f87cb 100644 --- a/database/migrations/2020_08_03_230723_create_general_graardor_table.php +++ b/database/migrations/2020_08_03_230723_create_general_graardor_table.php @@ -15,9 +15,10 @@ public function up() { Schema::create('general_graardor', function (Blueprint $table) { $table->id(); - $table->integer('user_id')->unsigned()->unique(); - $table->integer('obtained')->default(0)->unsigned(); + $table->integer('account_id')->unsigned()->unique(); $table->integer('kill_count')->default(0)->unsigned(); + $table->integer('rank')->default(0)->unsigned(); + $table->integer('obtained')->default(0)->unsigned(); $table->integer('pet_general_graardor')->default(0)->unsigned(); $table->integer('bandos_chestplate')->default(0)->unsigned(); $table->integer('bandos_tassets')->default(0)->unsigned(); diff --git a/database/migrations/2020_08_03_230723_create_giant_mole_table.php b/database/migrations/2020_08_03_230723_create_giant_mole_table.php index 2efb93ba..57aba5cd 100644 --- a/database/migrations/2020_08_03_230723_create_giant_mole_table.php +++ b/database/migrations/2020_08_03_230723_create_giant_mole_table.php @@ -15,9 +15,10 @@ public function up() { Schema::create('giant_mole', function (Blueprint $table) { $table->id(); - $table->integer('user_id')->unsigned()->unique(); - $table->integer('obtained')->default(0)->unsigned(); + $table->integer('account_id')->unsigned()->unique(); $table->integer('kill_count')->default(0)->unsigned(); + $table->integer('rank')->default(0)->unsigned(); + $table->integer('obtained')->default(0)->unsigned(); $table->integer('baby_mole')->default(0)->unsigned(); $table->integer('mole_skin')->default(0)->unsigned(); $table->integer('mole_claw')->default(0)->unsigned(); diff --git a/database/migrations/2020_08_03_230723_create_grotesque_guardians_table.php b/database/migrations/2020_08_03_230723_create_grotesque_guardians_table.php index fb6a366e..c265728b 100644 --- a/database/migrations/2020_08_03_230723_create_grotesque_guardians_table.php +++ b/database/migrations/2020_08_03_230723_create_grotesque_guardians_table.php @@ -15,9 +15,10 @@ public function up() { Schema::create('grotesque_guardians', function (Blueprint $table) { $table->id(); - $table->integer('user_id')->unsigned()->unique(); - $table->integer('obtained')->default(0)->unsigned(); + $table->integer('account_id')->unsigned()->unique(); $table->integer('kill_count')->default(0)->unsigned(); + $table->integer('rank')->default(0)->unsigned(); + $table->integer('obtained')->default(0)->unsigned(); $table->integer('noon')->default(0)->unsigned(); $table->integer('black_tourmaline_core')->default(0)->unsigned(); $table->integer('granite_gloves')->default(0)->unsigned(); diff --git a/database/migrations/2020_08_03_230724_create_hespori_table.php b/database/migrations/2020_08_03_230724_create_hespori_table.php index 0623f432..1c9aff1c 100644 --- a/database/migrations/2020_08_03_230724_create_hespori_table.php +++ b/database/migrations/2020_08_03_230724_create_hespori_table.php @@ -15,9 +15,10 @@ public function up() { Schema::create('hespori', function (Blueprint $table) { $table->id(); - $table->integer('user_id')->unsigned()->unique(); - $table->integer('obtained')->default(0)->unsigned(); + $table->integer('account_id')->unsigned()->unique(); $table->integer('kill_count')->default(0)->unsigned(); + $table->integer('rank')->default(0)->unsigned(); + $table->integer('obtained')->default(0)->unsigned(); $table->integer('bottomless_compost_bucket')->default(0)->unsigned(); $table->integer('iasor_seed')->default(0)->unsigned(); $table->integer('kronos_seed')->default(0)->unsigned(); diff --git a/database/migrations/2020_08_03_230724_create_kalphite_queen_table.php b/database/migrations/2020_08_03_230724_create_kalphite_queen_table.php index 2513b9d5..0a68b923 100644 --- a/database/migrations/2020_08_03_230724_create_kalphite_queen_table.php +++ b/database/migrations/2020_08_03_230724_create_kalphite_queen_table.php @@ -15,9 +15,10 @@ public function up() { Schema::create('kalphite_queen', function (Blueprint $table) { $table->id(); - $table->integer('user_id')->unsigned()->unique(); - $table->integer('obtained')->default(0)->unsigned(); + $table->integer('account_id')->unsigned()->unique(); $table->integer('kill_count')->default(0)->unsigned(); + $table->integer('rank')->default(0)->unsigned(); + $table->integer('obtained')->default(0)->unsigned(); $table->integer('kalphite_princess')->default(0)->unsigned(); $table->integer('kq_head')->default(0)->unsigned(); $table->integer('jar_of_sand')->default(0)->unsigned(); diff --git a/database/migrations/2020_08_03_230724_create_king_black_dragon_table.php b/database/migrations/2020_08_03_230724_create_king_black_dragon_table.php index 2db65b1c..5368a95a 100644 --- a/database/migrations/2020_08_03_230724_create_king_black_dragon_table.php +++ b/database/migrations/2020_08_03_230724_create_king_black_dragon_table.php @@ -15,9 +15,10 @@ public function up() { Schema::create('king_black_dragon', function (Blueprint $table) { $table->id(); - $table->integer('user_id')->unsigned()->unique(); - $table->integer('obtained')->default(0)->unsigned(); + $table->integer('account_id')->unsigned()->unique(); $table->integer('kill_count')->default(0)->unsigned(); + $table->integer('rank')->default(0)->unsigned(); + $table->integer('obtained')->default(0)->unsigned(); $table->integer('prince_black_dragon')->default(0)->unsigned(); $table->integer('kbd_heads')->default(0)->unsigned(); $table->integer('dragon_pickaxe')->default(0)->unsigned(); diff --git a/database/migrations/2020_08_03_230724_create_kraken_table.php b/database/migrations/2020_08_03_230724_create_kraken_table.php index c2108932..9a00f616 100644 --- a/database/migrations/2020_08_03_230724_create_kraken_table.php +++ b/database/migrations/2020_08_03_230724_create_kraken_table.php @@ -15,9 +15,10 @@ public function up() { Schema::create('kraken', function (Blueprint $table) { $table->id(); - $table->integer('user_id')->unsigned()->unique(); - $table->integer('obtained')->default(0)->unsigned(); + $table->integer('account_id')->unsigned()->unique(); $table->integer('kill_count')->default(0)->unsigned(); + $table->integer('rank')->default(0)->unsigned(); + $table->integer('obtained')->default(0)->unsigned(); $table->integer('pet_kraken')->default(0)->unsigned(); $table->integer('kraken_tentacle')->default(0)->unsigned(); $table->integer('trident_of_the_seas_(full)')->default(0)->unsigned(); diff --git a/database/migrations/2020_08_03_230724_create_kreearra_table.php b/database/migrations/2020_08_03_230724_create_kreearra_table.php index 9dc4d3f7..54890ea4 100644 --- a/database/migrations/2020_08_03_230724_create_kreearra_table.php +++ b/database/migrations/2020_08_03_230724_create_kreearra_table.php @@ -15,9 +15,10 @@ public function up() { Schema::create('kreearra', function (Blueprint $table) { $table->id(); - $table->integer('user_id')->unsigned()->unique(); - $table->integer('obtained')->default(0)->unsigned(); + $table->integer('account_id')->unsigned()->unique(); $table->integer('kill_count')->default(0)->unsigned(); + $table->integer('rank')->default(0)->unsigned(); + $table->integer('obtained')->default(0)->unsigned(); $table->integer('pet_kreearra')->default(0)->unsigned(); $table->integer('armadyl_helmet')->default(0)->unsigned(); $table->integer('armadyl_chestplate')->default(0)->unsigned(); diff --git a/database/migrations/2020_08_03_230725_create_kril_tsutsaroth_table.php b/database/migrations/2020_08_03_230725_create_kril_tsutsaroth_table.php index f01bf008..b75a188f 100644 --- a/database/migrations/2020_08_03_230725_create_kril_tsutsaroth_table.php +++ b/database/migrations/2020_08_03_230725_create_kril_tsutsaroth_table.php @@ -15,9 +15,10 @@ public function up() { Schema::create('kril_tsutsaroth', function (Blueprint $table) { $table->id(); - $table->integer('user_id')->unsigned()->unique(); - $table->integer('obtained')->default(0)->unsigned(); + $table->integer('account_id')->unsigned()->unique(); $table->integer('kill_count')->default(0)->unsigned(); + $table->integer('rank')->default(0)->unsigned(); + $table->integer('obtained')->default(0)->unsigned(); $table->integer('pet_kril_tsutsaroth')->default(0)->unsigned(); $table->integer('staff_of_the_dead')->default(0)->unsigned(); $table->integer('zamorakian_spear')->default(0)->unsigned(); diff --git a/database/migrations/2020_08_03_230725_create_obor_table.php b/database/migrations/2020_08_03_230725_create_obor_table.php index 2cda47fd..d0c420cd 100644 --- a/database/migrations/2020_08_03_230725_create_obor_table.php +++ b/database/migrations/2020_08_03_230725_create_obor_table.php @@ -15,9 +15,10 @@ public function up() { Schema::create('obor', function (Blueprint $table) { $table->id(); - $table->integer('user_id')->unsigned()->unique(); - $table->integer('obtained')->default(0)->unsigned(); + $table->integer('account_id')->unsigned()->unique(); $table->integer('kill_count')->default(0)->unsigned(); + $table->integer('rank')->default(0)->unsigned(); + $table->integer('obtained')->default(0)->unsigned(); $table->integer('hill_giant_club')->default(0)->unsigned(); $table->timestamps(); }); diff --git a/database/migrations/2020_08_03_230725_create_sarachnis_table.php b/database/migrations/2020_08_03_230725_create_sarachnis_table.php index 596c6a2d..afdaa4f6 100644 --- a/database/migrations/2020_08_03_230725_create_sarachnis_table.php +++ b/database/migrations/2020_08_03_230725_create_sarachnis_table.php @@ -15,9 +15,10 @@ public function up() { Schema::create('sarachnis', function (Blueprint $table) { $table->id(); - $table->integer('user_id')->unsigned()->unique(); - $table->integer('obtained')->default(0)->unsigned(); + $table->integer('account_id')->unsigned()->unique(); $table->integer('kill_count')->default(0)->unsigned(); + $table->integer('rank')->default(0)->unsigned(); + $table->integer('obtained')->default(0)->unsigned(); $table->integer('sraracha')->default(0)->unsigned(); $table->integer('jar_of_eyes')->default(0)->unsigned(); $table->integer('giant_egg_sac(full)')->default(0)->unsigned(); diff --git a/database/migrations/2020_08_03_230725_create_scorpia_table.php b/database/migrations/2020_08_03_230725_create_scorpia_table.php index 65090ba0..1fb7c9d5 100644 --- a/database/migrations/2020_08_03_230725_create_scorpia_table.php +++ b/database/migrations/2020_08_03_230725_create_scorpia_table.php @@ -15,9 +15,10 @@ public function up() { Schema::create('scorpia', function (Blueprint $table) { $table->id(); - $table->integer('user_id')->unsigned()->unique(); - $table->integer('obtained')->default(0)->unsigned(); + $table->integer('account_id')->unsigned()->unique(); $table->integer('kill_count')->default(0)->unsigned(); + $table->integer('rank')->default(0)->unsigned(); + $table->integer('obtained')->default(0)->unsigned(); $table->integer('scorpias_offspring')->default(0)->unsigned(); $table->integer('odium_shard_3')->default(0)->unsigned(); $table->integer('malediction_shard_3')->default(0)->unsigned(); diff --git a/database/migrations/2020_08_03_230726_create_skotizo_table.php b/database/migrations/2020_08_03_230726_create_skotizo_table.php index 59b4a53c..6f186eba 100644 --- a/database/migrations/2020_08_03_230726_create_skotizo_table.php +++ b/database/migrations/2020_08_03_230726_create_skotizo_table.php @@ -15,9 +15,10 @@ public function up() { Schema::create('skotizo', function (Blueprint $table) { $table->id(); - $table->integer('user_id')->unsigned()->unique(); - $table->integer('obtained')->default(0)->unsigned(); + $table->integer('account_id')->unsigned()->unique(); $table->integer('kill_count')->default(0)->unsigned(); + $table->integer('rank')->default(0)->unsigned(); + $table->integer('obtained')->default(0)->unsigned(); $table->integer('skotos')->default(0)->unsigned(); $table->integer('jar_of_darkness')->default(0)->unsigned(); $table->integer('dark_claw')->default(0)->unsigned(); diff --git a/database/migrations/2020_08_03_230726_create_the_fight_caves_table.php b/database/migrations/2020_08_03_230726_create_the_fight_caves_table.php index 1909b902..41348ca7 100644 --- a/database/migrations/2020_08_03_230726_create_the_fight_caves_table.php +++ b/database/migrations/2020_08_03_230726_create_the_fight_caves_table.php @@ -15,9 +15,10 @@ public function up() { Schema::create('the_fight_caves', function (Blueprint $table) { $table->id(); - $table->integer('user_id')->unsigned()->unique(); - $table->integer('obtained')->default(0)->unsigned(); + $table->integer('account_id')->unsigned()->unique(); $table->integer('kill_count')->default(0)->unsigned(); + $table->integer('rank')->default(0)->unsigned(); + $table->integer('obtained')->default(0)->unsigned(); $table->integer('tzrek-jad')->default(0)->unsigned(); $table->integer('fire_cape')->default(0)->unsigned(); $table->timestamps(); diff --git a/database/migrations/2020_08_03_230726_create_the_gauntlet_table.php b/database/migrations/2020_08_03_230726_create_the_gauntlet_table.php index 39163bf3..fa46abab 100644 --- a/database/migrations/2020_08_03_230726_create_the_gauntlet_table.php +++ b/database/migrations/2020_08_03_230726_create_the_gauntlet_table.php @@ -15,9 +15,10 @@ public function up() { Schema::create('the_gauntlet', function (Blueprint $table) { $table->id(); - $table->integer('user_id')->unsigned()->unique(); - $table->integer('obtained')->default(0)->unsigned(); + $table->integer('account_id')->unsigned()->unique(); $table->integer('kill_count')->default(0)->unsigned(); + $table->integer('rank')->default(0)->unsigned(); + $table->integer('obtained')->default(0)->unsigned(); $table->integer('youngllef')->default(0)->unsigned(); $table->integer('crystal_armour_seed')->default(0)->unsigned(); $table->integer('crystal_weapon_seed')->default(0)->unsigned(); diff --git a/database/migrations/2020_08_03_230726_create_the_inferno_table.php b/database/migrations/2020_08_03_230726_create_the_inferno_table.php index 333913ab..0323dcf8 100644 --- a/database/migrations/2020_08_03_230726_create_the_inferno_table.php +++ b/database/migrations/2020_08_03_230726_create_the_inferno_table.php @@ -15,9 +15,10 @@ public function up() { Schema::create('the_inferno', function (Blueprint $table) { $table->id(); - $table->integer('user_id')->unsigned()->unique(); - $table->integer('obtained')->default(0)->unsigned(); + $table->integer('account_id')->unsigned()->unique(); $table->integer('kill_count')->default(0)->unsigned(); + $table->integer('rank')->default(0)->unsigned(); + $table->integer('obtained')->default(0)->unsigned(); $table->integer('jal-nib-rek')->default(0)->unsigned(); $table->integer('infernal_cape')->default(0)->unsigned(); $table->timestamps(); diff --git a/database/migrations/2020_08_03_230726_create_the_nightmare_table.php b/database/migrations/2020_08_03_230726_create_the_nightmare_table.php index 1c7b14e9..c7c0c157 100644 --- a/database/migrations/2020_08_03_230726_create_the_nightmare_table.php +++ b/database/migrations/2020_08_03_230726_create_the_nightmare_table.php @@ -15,9 +15,10 @@ public function up() { Schema::create('the_nightmare', function (Blueprint $table) { $table->id(); - $table->integer('user_id')->unsigned()->unique(); - $table->integer('obtained')->default(0)->unsigned(); + $table->integer('account_id')->unsigned()->unique(); $table->integer('kill_count')->default(0)->unsigned(); + $table->integer('rank')->default(0)->unsigned(); + $table->integer('obtained')->default(0)->unsigned(); $table->integer('little_nightmare')->default(0)->unsigned(); $table->integer('inquisitors_mace')->default(0)->unsigned(); $table->integer('inquisitors_great_helm')->default(0)->unsigned(); diff --git a/database/migrations/2020_08_03_230727_create_thermonuclear_smoke_devil_table.php b/database/migrations/2020_08_03_230727_create_thermonuclear_smoke_devil_table.php index 30fda9db..a10b9052 100644 --- a/database/migrations/2020_08_03_230727_create_thermonuclear_smoke_devil_table.php +++ b/database/migrations/2020_08_03_230727_create_thermonuclear_smoke_devil_table.php @@ -15,9 +15,10 @@ public function up() { Schema::create('thermonuclear_smoke_devil', function (Blueprint $table) { $table->id(); - $table->integer('user_id')->unsigned()->unique(); - $table->integer('obtained')->default(0)->unsigned(); + $table->integer('account_id')->unsigned()->unique(); $table->integer('kill_count')->default(0)->unsigned(); + $table->integer('rank')->default(0)->unsigned(); + $table->integer('obtained')->default(0)->unsigned(); $table->integer('pet_smoke_devil')->default(0)->unsigned(); $table->integer('occult_necklace')->default(0)->unsigned(); $table->integer('smoke_battlestaff')->default(0)->unsigned(); diff --git a/database/migrations/2020_08_03_230727_create_venenatis_table.php b/database/migrations/2020_08_03_230727_create_venenatis_table.php index eaecdba6..b109aa58 100644 --- a/database/migrations/2020_08_03_230727_create_venenatis_table.php +++ b/database/migrations/2020_08_03_230727_create_venenatis_table.php @@ -15,9 +15,10 @@ public function up() { Schema::create('venenatis', function (Blueprint $table) { $table->id(); - $table->integer('user_id')->unsigned()->unique(); - $table->integer('obtained')->default(0)->unsigned(); + $table->integer('account_id')->unsigned()->unique(); $table->integer('kill_count')->default(0)->unsigned(); + $table->integer('rank')->default(0)->unsigned(); + $table->integer('obtained')->default(0)->unsigned(); $table->integer('venenatis_spiderling')->default(0)->unsigned(); $table->integer('treasonous_ring')->default(0)->unsigned(); $table->integer('dragon_pickaxe')->default(0)->unsigned(); diff --git a/database/migrations/2020_08_03_230727_create_vetion_table.php b/database/migrations/2020_08_03_230727_create_vetion_table.php index 88faa81b..f3ae5091 100644 --- a/database/migrations/2020_08_03_230727_create_vetion_table.php +++ b/database/migrations/2020_08_03_230727_create_vetion_table.php @@ -15,9 +15,10 @@ public function up() { Schema::create('vetion', function (Blueprint $table) { $table->id(); - $table->integer('user_id')->unsigned()->unique(); - $table->integer('obtained')->default(0)->unsigned(); + $table->integer('account_id')->unsigned()->unique(); $table->integer('kill_count')->default(0)->unsigned(); + $table->integer('rank')->default(0)->unsigned(); + $table->integer('obtained')->default(0)->unsigned(); $table->integer('vetion_jr')->default(0)->unsigned(); $table->integer('ring_of_the_gods')->default(0)->unsigned(); $table->integer('dragon_pickaxe')->default(0)->unsigned(); diff --git a/database/migrations/2020_08_03_230727_create_vorkath_table.php b/database/migrations/2020_08_03_230727_create_vorkath_table.php index db5031de..367097aa 100644 --- a/database/migrations/2020_08_03_230727_create_vorkath_table.php +++ b/database/migrations/2020_08_03_230727_create_vorkath_table.php @@ -15,9 +15,10 @@ public function up() { Schema::create('vorkath', function (Blueprint $table) { $table->id(); - $table->integer('user_id')->unsigned()->unique(); - $table->integer('obtained')->default(0)->unsigned(); + $table->integer('account_id')->unsigned()->unique(); $table->integer('kill_count')->default(0)->unsigned(); + $table->integer('rank')->default(0)->unsigned(); + $table->integer('obtained')->default(0)->unsigned(); $table->integer('vorki')->default(0)->unsigned(); $table->integer('vorkaths_head')->default(0)->unsigned(); $table->integer('draconic_visage')->default(0)->unsigned(); diff --git a/database/migrations/2020_08_03_230727_create_wintertodt_table.php b/database/migrations/2020_08_03_230727_create_wintertodt_table.php index 6ea87287..b2ce7e42 100644 --- a/database/migrations/2020_08_03_230727_create_wintertodt_table.php +++ b/database/migrations/2020_08_03_230727_create_wintertodt_table.php @@ -15,9 +15,10 @@ public function up() { Schema::create('wintertodt', function (Blueprint $table) { $table->id(); - $table->integer('user_id')->unsigned()->unique(); - $table->integer('obtained')->default(0)->unsigned(); + $table->integer('account_id')->unsigned()->unique(); $table->integer('kill_count')->default(0)->unsigned(); + $table->integer('rank')->default(0)->unsigned(); + $table->integer('obtained')->default(0)->unsigned(); $table->integer('phoenix')->default(0)->unsigned(); $table->integer('tome_of_fire_(empty)')->default(0)->unsigned(); $table->integer('burnt_page')->default(0)->unsigned(); diff --git a/database/migrations/2020_08_03_230728_create_zalcano_table.php b/database/migrations/2020_08_03_230728_create_zalcano_table.php index d197a973..3b7c73a8 100644 --- a/database/migrations/2020_08_03_230728_create_zalcano_table.php +++ b/database/migrations/2020_08_03_230728_create_zalcano_table.php @@ -15,9 +15,10 @@ public function up() { Schema::create('zalcano', function (Blueprint $table) { $table->id(); - $table->integer('user_id')->unsigned()->unique(); - $table->integer('obtained')->default(0)->unsigned(); + $table->integer('account_id')->unsigned()->unique(); $table->integer('kill_count')->default(0)->unsigned(); + $table->integer('rank')->default(0)->unsigned(); + $table->integer('obtained')->default(0)->unsigned(); $table->integer('smolcano')->default(0)->unsigned(); $table->integer('crystal_tool_seed')->default(0)->unsigned(); $table->integer('zalcano_shard')->default(0)->unsigned(); diff --git a/database/migrations/2020_08_03_230728_create_zulrah_table.php b/database/migrations/2020_08_03_230728_create_zulrah_table.php index 8bba0b94..a2fce6c1 100644 --- a/database/migrations/2020_08_03_230728_create_zulrah_table.php +++ b/database/migrations/2020_08_03_230728_create_zulrah_table.php @@ -15,9 +15,10 @@ public function up() { Schema::create('zulrah', function (Blueprint $table) { $table->id(); - $table->integer('user_id')->unsigned()->unique(); - $table->integer('obtained')->default(0)->unsigned(); + $table->integer('account_id')->unsigned()->unique(); $table->integer('kill_count')->default(0)->unsigned(); + $table->integer('rank')->default(0)->unsigned(); + $table->integer('obtained')->default(0)->unsigned(); $table->integer('pet_snakeling')->default(0)->unsigned(); $table->integer('tanzanite_mutagen')->default(0)->unsigned(); $table->integer('magma_mutagen')->default(0)->unsigned(); diff --git a/database/migrations/2020_08_05_225546_create_goblin_table.php b/database/migrations/2020_08_05_225546_create_goblin_table.php index 092567f2..07d5b1b3 100644 --- a/database/migrations/2020_08_05_225546_create_goblin_table.php +++ b/database/migrations/2020_08_05_225546_create_goblin_table.php @@ -15,9 +15,10 @@ public function up() { Schema::create('goblin', function (Blueprint $table) { $table->id(); - $table->integer('user_id')->unsigned()->unique(); - $table->integer('obtained')->default(0)->unsigned(); + $table->integer('account_id')->unsigned()->unique(); $table->integer('kill_count')->default(0)->unsigned(); + $table->integer('rank')->default(0)->unsigned(); + $table->integer('obtained')->default(0)->unsigned(); $table->integer('bones')->default(0)->unsigned(); $table->integer('water_rune')->default(0)->unsigned(); $table->integer('coins')->default(0)->unsigned(); diff --git a/database/migrations/2020_08_14_225042_create_skills_table.php b/database/migrations/2020_08_14_225042_create_skills_table.php new file mode 100644 index 00000000..e8006b56 --- /dev/null +++ b/database/migrations/2020_08_14_225042_create_skills_table.php @@ -0,0 +1,39 @@ +id(); + $table->integer('account_id')->unsigned()->unique(); + $table->integer('rank')->default(0); + $table->integer('level')->default(1); + $table->bigInteger('xp')->default(0); + $table->timestamps(); + }); + } + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('skills'); + } +} diff --git a/database/migrations/2020_08_14_225333_create_accounts_table.php b/database/migrations/2020_08_14_225333_create_accounts_table.php new file mode 100644 index 00000000..bd857f9d --- /dev/null +++ b/database/migrations/2020_08_14_225333_create_accounts_table.php @@ -0,0 +1,37 @@ +id(); + $table->integer('user_id')->unsigned(); + $table->enum('type', ['normal', 'ironman', 'hardcore', 'ultimate']); + $table->string('username', 13); + $table->integer('rank')->default(0); + $table->integer('level')->default(32); // Minimum total level + $table->bigInteger('xp')->default(0); + $table->timestamps(); + }); + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('accounts'); + } +} diff --git a/database/migrations/2020_08_16_094532_create_news_posts_table.php b/database/migrations/2020_08_16_094532_create_news_posts_table.php new file mode 100644 index 00000000..adb801ca --- /dev/null +++ b/database/migrations/2020_08_16_094532_create_news_posts_table.php @@ -0,0 +1,37 @@ +id(); + $table->integer('user_id')->unsigned(); + $table->integer('category_id')->unsigned(); + $table->integer('image_id')->unsigned()->default('1'); + $table->string('title'); + $table->string('shortstory'); + $table->longText('longstory'); + $table->timestamps(); + }); + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('news_posts'); + } +} diff --git a/database/migrations/2020_08_16_094855_create_categories_table.php b/database/migrations/2020_08_16_094855_create_categories_table.php new file mode 100644 index 00000000..7ace9919 --- /dev/null +++ b/database/migrations/2020_08_16_094855_create_categories_table.php @@ -0,0 +1,39 @@ +id(); + $table->string('category'); + }); + + DB::table('categories')->insert( + [ + ["category" => "News"], + ["category" => "Event"], + ["category" => "Update"] + ] + ); + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('categories'); + } +} diff --git a/database/migrations/2020_08_16_094900_create_images_table.php b/database/migrations/2020_08_16_094900_create_images_table.php new file mode 100644 index 00000000..52abcaaf --- /dev/null +++ b/database/migrations/2020_08_16_094900_create_images_table.php @@ -0,0 +1,45 @@ +id(); + $table->string('image_file_name'); + $table->string('image_file_extension'); + $table->string('image_file_type'); + $table->integer('image_file_size'); + $table->timestamps(); + }); + + DB::table('images')->insert( + [ + 'id' => 1, + 'image_file_name' => 'default', + 'image_file_extension' => 'png', + 'image_file_type' => 'image/png', + 'image_file_size' => 2231364 + ] + ); + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('images'); + } +} diff --git a/database/migrations/2020_08_21_163454_create_mimic_table.php b/database/migrations/2020_08_21_163454_create_mimic_table.php new file mode 100644 index 00000000..c55ef68a --- /dev/null +++ b/database/migrations/2020_08_21_163454_create_mimic_table.php @@ -0,0 +1,34 @@ +id(); + $table->integer('account_id')->unsigned()->unique(); + $table->integer('kill_count')->default(0)->unsigned(); + $table->integer('rank')->default(0)->unsigned(); + $table->timestamps(); + }); + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('mimic'); + } +} diff --git a/database/migrations/2020_08_21_164442_create_chambers_of_xeric_table.php b/database/migrations/2020_08_21_164442_create_chambers_of_xeric_table.php new file mode 100644 index 00000000..ebaa054a --- /dev/null +++ b/database/migrations/2020_08_21_164442_create_chambers_of_xeric_table.php @@ -0,0 +1,58 @@ +id(); + $table->integer('account_id')->unsigned()->unique(); + $table->integer('kill_count')->default(0)->unsigned(); + $table->integer('rank')->default(0)->unsigned(); + $table->integer('obtained')->default(0)->unsigned(); + $table->integer('olmlet')->default(0)->unsigned(); + $table->integer('metamorphic_dust')->default(0)->unsigned(); + $table->integer('twisted_bow')->default(0)->unsigned(); + $table->integer('elder_maul')->default(0)->unsigned(); + $table->integer('kodai_insignia')->default(0)->unsigned(); + $table->integer('dragon_claws')->default(0)->unsigned(); + $table->integer('ancestral_hat')->default(0)->unsigned(); + $table->integer('ancestral_robe_top')->default(0)->unsigned(); + $table->integer('ancestral_robe_bottom')->default(0)->unsigned(); + $table->integer('dinhs_bulwark')->default(0)->unsigned(); + $table->integer('dexterous_prayer_scroll')->default(0)->unsigned(); + $table->integer('arcane_prayer_scroll')->default(0)->unsigned(); + $table->integer('dragon_hunter_crossbow')->default(0)->unsigned(); + $table->integer('twisted_buckler')->default(0)->unsigned(); + $table->integer('torn_prayer_scroll')->default(0)->unsigned(); + $table->integer('dark_relic')->default(0)->unsigned(); + $table->integer('onyx')->default(0)->unsigned(); + $table->integer('twisted_ancestral_colour_kit')->default(0)->unsigned(); + $table->integer('xerics_guard')->default(0)->unsigned(); + $table->integer('xerics_warrior')->default(0)->unsigned(); + $table->integer('xerics_sentinel')->default(0)->unsigned(); + $table->integer('xerics_general')->default(0)->unsigned(); + $table->integer('xerics_champion')->default(0)->unsigned(); + $table->timestamps(); + }); + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('chambers_of_xeric'); + } +} diff --git a/database/migrations/2020_08_21_164453_create_theatre_of_blood_table.php b/database/migrations/2020_08_21_164453_create_theatre_of_blood_table.php new file mode 100644 index 00000000..cd3c2231 --- /dev/null +++ b/database/migrations/2020_08_21_164453_create_theatre_of_blood_table.php @@ -0,0 +1,49 @@ +id(); + $table->integer('account_id')->unsigned()->unique(); + $table->integer('kill_count')->default(0)->unsigned(); + $table->integer('rank')->default(0)->unsigned(); + $table->integer('obtained')->default(0)->unsigned(); + $table->integer('lil_zik')->default(0)->unsigned(); + $table->integer('scythhe_of_vitour_(uncharged)')->default(0)->unsigned(); + $table->integer('ghrazi_rapier')->default(0)->unsigned(); + $table->integer('sanguinesti_staff_(uncharged)')->default(0)->unsigned(); + $table->integer('justiciar_faceguard')->default(0)->unsigned(); + $table->integer('justiciar_chestguard')->default(0)->unsigned(); + $table->integer('justiciar_legguards')->default(0)->unsigned(); + $table->integer('avernic_defender_hilt')->default(0)->unsigned(); + $table->integer('vial_of_blood')->default(0)->unsigned(); + $table->integer('sinhaza_shroud_tier_1')->default(0)->unsigned(); + $table->integer('sinhaza_shroud_tier_2')->default(0)->unsigned(); + $table->integer('sinhaza_shroud_tier_3')->default(0)->unsigned(); + $table->integer('sinhaza_shroud_tier_4')->default(0)->unsigned(); + $table->integer('sinhaza_shroud_tier_5')->default(0)->unsigned(); + $table->timestamps(); + }); + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('theatre_of_blood'); + } +} diff --git a/database/migrations/2020_08_21_220215_create_dagannoth_prime_table.php b/database/migrations/2020_08_21_220215_create_dagannoth_prime_table.php new file mode 100644 index 00000000..e106757e --- /dev/null +++ b/database/migrations/2020_08_21_220215_create_dagannoth_prime_table.php @@ -0,0 +1,34 @@ +id(); + $table->integer('account_id')->unsigned()->unique(); + $table->integer('kill_count')->default(0)->unsigned(); + $table->integer('rank')->default(0)->unsigned(); + $table->timestamps(); + }); + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('dagannoth_prime'); + } +} diff --git a/database/migrations/2020_08_21_220224_create_dagannoth_rex_table.php b/database/migrations/2020_08_21_220224_create_dagannoth_rex_table.php new file mode 100644 index 00000000..8dafb30b --- /dev/null +++ b/database/migrations/2020_08_21_220224_create_dagannoth_rex_table.php @@ -0,0 +1,34 @@ +id(); + $table->integer('account_id')->unsigned()->unique(); + $table->integer('kill_count')->default(0)->unsigned(); + $table->integer('rank')->default(0)->unsigned(); + $table->timestamps(); + }); + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('dagannoth_rex'); + } +} diff --git a/database/migrations/2020_08_21_220231_create_dagannoth_supreme_table.php b/database/migrations/2020_08_21_220231_create_dagannoth_supreme_table.php new file mode 100644 index 00000000..89b74244 --- /dev/null +++ b/database/migrations/2020_08_21_220231_create_dagannoth_supreme_table.php @@ -0,0 +1,34 @@ +id(); + $table->integer('account_id')->unsigned()->unique(); + $table->integer('kill_count')->default(0)->unsigned(); + $table->integer('rank')->default(0)->unsigned(); + $table->timestamps(); + }); + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('dagannoth_supreme'); + } +} diff --git a/database/migrations/2020_08_21_221523_create_deranged_archaeologist_table.php b/database/migrations/2020_08_21_221523_create_deranged_archaeologist_table.php new file mode 100644 index 00000000..cf341eac --- /dev/null +++ b/database/migrations/2020_08_21_221523_create_deranged_archaeologist_table.php @@ -0,0 +1,34 @@ +id(); + $table->integer('account_id')->unsigned()->unique(); + $table->integer('kill_count')->default(0)->unsigned(); + $table->integer('rank')->default(0)->unsigned(); + $table->timestamps(); + }); + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('deranged_archaeologist'); + } +} diff --git a/database/migrations/2020_08_21_222717_create_chambers_of_xeric_challenge_mode_table.php b/database/migrations/2020_08_21_222717_create_chambers_of_xeric_challenge_mode_table.php new file mode 100644 index 00000000..5a360b03 --- /dev/null +++ b/database/migrations/2020_08_21_222717_create_chambers_of_xeric_challenge_mode_table.php @@ -0,0 +1,34 @@ +id(); + $table->integer('account_id')->unsigned()->unique(); + $table->integer('kill_count')->default(0)->unsigned(); + $table->integer('rank')->default(0)->unsigned(); + $table->timestamps(); + }); + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('chambers_of_xeric_challenge_mode'); + } +} diff --git a/database/migrations/2020_08_21_222733_create_the_corrupted_gauntlet_table.php b/database/migrations/2020_08_21_222733_create_the_corrupted_gauntlet_table.php new file mode 100644 index 00000000..eb8d2859 --- /dev/null +++ b/database/migrations/2020_08_21_222733_create_the_corrupted_gauntlet_table.php @@ -0,0 +1,34 @@ +id(); + $table->integer('account_id')->unsigned()->unique(); + $table->integer('kill_count')->default(0)->unsigned(); + $table->integer('rank')->default(0)->unsigned(); + $table->timestamps(); + }); + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('the_corrupted_gauntlet'); + } +} diff --git a/database/migrations/2020_09_01_093912_create_account_auth_statuses_table.php b/database/migrations/2020_09_01_093912_create_account_auth_statuses_table.php new file mode 100644 index 00000000..6f5e4598 --- /dev/null +++ b/database/migrations/2020_09_01_093912_create_account_auth_statuses_table.php @@ -0,0 +1,35 @@ +id(); + $table->integer('user_id')->unsigned(); + $table->string('username', 13); + $table->string('code', 8); + $table->enum('status', ['pending', 'success', 'failed', 'expired']); + $table->timestamps(); + }); + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('account_auth_statuses'); + } +} diff --git a/database/seeds/CollectionSeeder.php b/database/seeds/CollectionSeeder.php index 9f1695b3..1af63143 100644 --- a/database/seeds/CollectionSeeder.php +++ b/database/seeds/CollectionSeeder.php @@ -12,43 +12,57 @@ class CollectionSeeder extends Seeder public function run() { DB::table('collections')->insert([ - ["name" => "abyssal sire", "collection_type" => "App\Boss\AbyssalSire"], - ["name" => "alchemical hydra", "collection_type" => "App\Boss\AlchemicalHydra"], - ["name" => "barrows chests", "collection_type" => "App\Boss\BarrowsChests"], - ["name" => "bryophyta", "collection_type" => "App\Boss\Bryophyta"], - ["name" => "callisto", "collection_type" => "App\Boss\Callisto"], - ["name" => "cerberus", "collection_type" => "App\Boss\Cerberus"], - ["name" => "chaos elemental", "collection_type" => "App\Boss\ChaosElemental"], - ["name" => "chaos fanatic", "collection_type" => "App\Boss\ChaosFanatic"], - ["name" => "commander zilyana", "collection_type" => "App\Boss\CommanderZilyana"], - ["name" => "corporeal beast", "collection_type" => "App\Boss\CorporealBeast"], - ["name" => "crazy archaeologist", "collection_type" => "App\Boss\CrazyArchaeologist"], - ["name" => "dagannoth kings", "collection_type" => "App\Boss\DagannothKings"], - ["name" => "the fight caves", "collection_type" => "App\Boss\TheFightCaves"], - ["name" => "the gauntlet", "collection_type" => "App\Boss\TheGauntlet"], - ["name" => "general graardor", "collection_type" => "App\Boss\GeneralGraardor"], - ["name" => "giant mole", "collection_type" => "App\Boss\GiantMole"], - ["name" => "grotesque guardians", "collection_type" => "App\Boss\GrotesqueGuardians"], - ["name" => "hespori", "collection_type" => "App\Boss\Hespori"], - ["name" => "the inferno", "collection_type" => "App\Boss\TheInferno"], - ["name" => "kalphite queen", "collection_type" => "App\Boss\KalphiteQueen"], - ["name" => "king black dragon", "collection_type" => "App\Boss\KingBlackDragon"], - ["name" => "kraken", "collection_type" => "App\Boss\Kraken"], - ["name" => "kreearra", "collection_type" => "App\Boss\KreeArra"], - ["name" => "kril tsutsaroth", "collection_type" => "App\Boss\KrilTsutsaroth"], - ["name" => "the nightmare", "collection_type" => "App\Boss\TheNightmare"], - ["name" => "obor", "collection_type" => "App\Boss\Obor"], - ["name" => "sarachnis", "collection_type" => "App\Boss\Sarachnis"], - ["name" => "scorpia", "collection_type" => "App\Boss\Scorpia"], - ["name" => "skotizo", "collection_type" => "App\Boss\Skotizo"], - ["name" => "thermonuclear smoke devil", "collection_type" => "App\Boss\ThermonuclearSmokeDevil"], - ["name" => "venenatis", "collection_type" => "App\Boss\Venenatis"], - ["name" => "vetion", "collection_type" => "App\Boss\Vetion"], - ["name" => "vorkath", "collection_type" => "App\Boss\Vorkath"], - ["name" => "wintertodt", "collection_type" => "App\Boss\Wintertodt"], - ["name" => "zalcano", "collection_type" => "App\Boss\Zalcano"], - ["name" => "zulrah", "collection_type" => "App\Boss\Zulrah"], - ["name" => "goblin", "collection_type" => "App\Boss\Goblin"], // TODO remove later + ["name" => "abyssal sire", "type" => "boss", "model" => "App\Boss\AbyssalSire"], + ["name" => "alchemical hydra", "type" => "boss", "model" => "App\Boss\AlchemicalHydra"], + ["name" => "barrows chests", "type" => "boss", "model" => "App\Boss\BarrowsChests"], + ["name" => "bryophyta", "type" => "boss", "model" => "App\Boss\Bryophyta"], + ["name" => "callisto", "type" => "boss", "model" => "App\Boss\Callisto"], + ["name" => "cerberus", "type" => "boss", "model" => "App\Boss\Cerberus"], + ["name" => "chambers of xeric", "type" => "raid", "model" => "App\Raid\ChambersOfXeric"], + ["name" => "chambers of xeric challenge mode", "type" => "raid", "model" => "App\Raid\ChambersOfXericChallengeMode"], + ["name" => "chaos elemental", "type" => "boss", "model" => "App\Boss\ChaosElemental"], + ["name" => "chaos fanatic", "type" => "boss", "model" => "App\Boss\ChaosFanatic"], + ["name" => "commander zilyana", "type" => "boss", "model" => "App\Boss\CommanderZilyana"], + ["name" => "corporeal beast", "type" => "boss", "model" => "App\Boss\CorporealBeast"], + ["name" => "crazy archaeologist", "type" => "boss", "model" => "App\Boss\CrazyArchaeologist"], + ["name" => "dagannoth prime", "type" => "boss", "model" => "App\Boss\DagannothPrime"], + ["name" => "dagannoth rex", "type" => "boss", "model" => "App\Boss\DagannothRex"], + ["name" => "dagannoth supreme", "type" => "boss", "model" => "App\Boss\DagannothSupreme"], + ["name" => "deranged archaeologist", "type" => "boss", "model" => "App\Boss\DerangedArchaeologist"], + ["name" => "general graardor", "type" => "boss", "model" => "App\Boss\GeneralGraardor"], + ["name" => "giant mole", "type" => "boss", "model" => "App\Boss\GiantMole"], + ["name" => "grotesque guardians", "type" => "boss", "model" => "App\Boss\GrotesqueGuardians"], + ["name" => "hespori", "type" => "boss", "model" => "App\Boss\Hespori"], + ["name" => "kalphite queen", "type" => "boss", "model" => "App\Boss\KalphiteQueen"], + ["name" => "king black dragon", "type" => "boss", "model" => "App\Boss\KingBlackDragon"], + ["name" => "kraken", "type" => "boss", "model" => "App\Boss\Kraken"], + ["name" => "kreearra", "type" => "boss", "model" => "App\Boss\KreeArra"], + ["name" => "kril tsutsaroth", "type" => "boss", "model" => "App\Boss\KrilTsutsaroth"], + ["name" => "mimic", "type" => "boss", "model" => "App\Boss\Mimic"], + ["name" => "nightmare", "type" => "boss", "model" => "App\Boss\TheNightmare"], + ["name" => "obor", "type" => "boss", "model" => "App\Boss\Obor"], + ["name" => "sarachnis", "type" => "boss", "model" => "App\Boss\Sarachnis"], + ["name" => "scorpia", "type" => "boss", "model" => "App\Boss\Scorpia"], + ["name" => "skotizo", "type" => "boss", "model" => "App\Boss\Skotizo"], + ["name" => "the gauntlet", "type" => "boss", "model" => "App\Boss\TheGauntlet"], + ["name" => "the corrupted gauntlet", "type" => "boss", "model" => "App\Boss\TheCorruptedGauntlet"], + ["name" => "theatre of blood", "type" => "raid", "model" => "App\Raid\TheatreOfBlood"], + ["name" => "thermonuclear smoke devil", "type" => "boss", "model" => "App\Boss\ThermonuclearSmokeDevil"], + ["name" => "tzkal zuk", "type" => "boss", "model" => "App\Boss\TheInferno"], + ["name" => "tztok jad", "type" => "boss", "model" => "App\Boss\TheFightCaves"], + ["name" => "venenatis", "type" => "boss", "model" => "App\Boss\Venenatis"], + ["name" => "vetion", "type" => "boss", "model" => "App\Boss\Vetion"], + ["name" => "vorkath", "type" => "boss", "model" => "App\Boss\Vorkath"], + ["name" => "wintertodt", "type" => "boss", "model" => "App\Boss\Wintertodt"], + ["name" => "zalcano", "type" => "boss", "model" => "App\Boss\Zalcano"], + ["name" => "zulrah", "type" => "boss", "model" => "App\Boss\Zulrah"], + + ["name" => "dagannoth kings", "type" => "boss", "model" => "App\Boss\DagannothKings"], + ["name" => "the fight caves", "type" => "boss", "model" => "App\Boss\TheFightCaves"], + ["name" => "the inferno", "type" => "boss", "model" => "App\Boss\TheInferno"], + ["name" => "the nightmare", "type" => "boss", "model" => "App\Boss\TheNightmare"], + + ["name" => "goblin", "type" => "boss", "model" => "App\Boss\Goblin"], // TODO remove later ]); } } diff --git a/public/css/admin.css b/public/css/admin.css new file mode 100644 index 00000000..921fe660 --- /dev/null +++ b/public/css/admin.css @@ -0,0 +1,207 @@ +@import "https://fonts.googleapis.com/css?family=Poppins:300,400,500,600,700"; +body { + font-family: 'Poppins', sans-serif; + background: #34424D; + color: white; +} + +table { + border-collapse: collapse; + color: white; + width: 100%; +} + +table td, table th { + border: 1px solid #ddd; + text-align: left; + padding: 8px; +} + +table tr:nth-child(even){background-color: #47535F;} + +table tr:hover {background-color: #637383;} + +table th { + padding-top: 12px; + padding-bottom: 12px; + text-align: left; + background: #EEEEEE; + color: black; +} + +table input { + width: 100%; +} + +a, +a:hover, +a:focus { + color: inherit; + text-decoration: none; + transition: all 0.3s; +} + +.navbar { + padding: 15px 10px; + background: #fff; + border: none; + border-radius: 0; + margin: 0 -40px 10px -40px; + box-shadow: 1px 1px 3px rgba(0, 0, 0, 0.1); +} + +.navbar-btn { + box-shadow: none; + outline: none !important; + border: none; +} + +.line { + width: 100%; + height: 1px; + border-bottom: 1px dashed #ddd; + margin: 40px 0; +} + +/* --------------------------------------------------- + SIDEBAR STYLE +----------------------------------------------------- */ + +.wrapper { + display: flex; + width: 100%; +} + +#sidebar { + width: 250px; + position: fixed; + top: 0; + left: 0; + height: 100vh; + z-index: 999; + background: #47535F; + color: #fff; + transition: all 0.3s; +} + +#sidebar.active { + margin-left: -250px; +} + +#sidebar .sidebar-header { + padding: 20px 20px 11px 20px; + background: #6d7fcc; +} + +#sidebar ul.components { + padding: 20px 0; + border-bottom: 1px solid #47748b; +} + +#sidebar ul p { + color: #fff; + padding: 10px; +} + +#sidebar ul li a { + padding: 10px; + font-size: 1.1em; + display: block; +} + +#sidebar ul li a:hover { + color: #7386D5; + background: #fff; +} + +#sidebar ul li.active>a, +a[aria-expanded="true"] { + color: #fff; + background: #6d7fcc; +} + +a[data-toggle="collapse"] { + position: relative; +} + +.dropdown-toggle::after { + display: block; + position: absolute; + top: 50%; + right: 20px; + transform: translateY(-50%); +} + +ul ul a { + font-size: 0.9em !important; + padding-left: 30px !important; + background: #6d7fcc; +} + +ul.CTAs { + padding: 20px; +} + +ul.CTAs a { + text-align: center; + font-size: 0.9em !important; + display: block; + border-radius: 5px; + margin-bottom: 5px; +} + +a.download { + background: #fff; + color: #7386D5; +} + +a.article, +a.article:hover { + background: #6d7fcc !important; + color: #fff !important; +} + +/* --------------------------------------------------- + CONTENT STYLE +----------------------------------------------------- */ + +#content { + width: calc(100% - 250px); + padding: 0 40px 0 40px; + min-height: 100vh; + transition: all 0.3s; + position: absolute; + top: 0; + right: 0; +} + +#content.active { + width: 100%; +} + +.content-body { + width: 65%; + margin: 0 auto; +} + +/* --------------------------------------------------- + MEDIAQUERIES +----------------------------------------------------- */ + +@media (max-width: 768px) { + #sidebar { + margin-left: -250px; + } + #sidebar.active { + margin-left: 0; + } + #content { + width: 100%; + } + #content.active { + width: calc(100% - 250px); + } + #sidebarCollapse span { + display: none; + } +} \ No newline at end of file diff --git a/public/css/fonts/runescape/runescape.eot b/public/css/fonts/runescape/runescape.eot new file mode 100644 index 00000000..3dd8f9f1 Binary files /dev/null and b/public/css/fonts/runescape/runescape.eot differ diff --git a/public/css/fonts/runescape/runescape.svg b/public/css/fonts/runescape/runescape.svg new file mode 100644 index 00000000..bf2e336b --- /dev/null +++ b/public/css/fonts/runescape/runescape.svg @@ -0,0 +1,225 @@ + + + + +Created by FontForge 20110222 at Mon Mar 7 13:04:51 2011 + By www-data +Copyright Bucket 2009 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/public/css/fonts/runescape/runescape.ttf b/public/css/fonts/runescape/runescape.ttf new file mode 100644 index 00000000..f58dbbd0 Binary files /dev/null and b/public/css/fonts/runescape/runescape.ttf differ diff --git a/public/css/fonts/runescape/runescape.woff b/public/css/fonts/runescape/runescape.woff new file mode 100644 index 00000000..5acf2d0b Binary files /dev/null and b/public/css/fonts/runescape/runescape.woff differ diff --git a/public/css/style.css b/public/css/style.css new file mode 100644 index 00000000..cc6c477a --- /dev/null +++ b/public/css/style.css @@ -0,0 +1,326 @@ +@font-face { + font-family: 'runescape'; + src: url('fonts/runescape/runescape.eot'); + src: url('fonts/runescape/runescape.eot?#iefix') format('embedded-opentype'), + url('fonts/runescape/runescape.woff') format('woff'), + url('fonts/runescape/runescape.ttf') format('truetype'), + url('fonts/runescape/runescape.svg') format('svg'); +} + +body, html { + font-family: sans-serif; + background: url('/images/background_2.png') no-repeat; + background-position: center center; + background-attachment: fixed; +} + +h1, h2, h3 { + font-family: "runescape", sans-serif; + text-align: center; + font-weight: bold; + color: #343a40; +} + +h2, h3 { + text-align: left; +} + +table { + border-collapse: collapse; + width: 100%; +} + +table td, table th { + padding: 3px 5px; + border-bottom: 1px solid black; + min-width: 3rem; + height: 55px; +} + +table th { + padding-top: 12px; + padding-bottom: 12px; + text-align: left; +} + +a:link {color: #1e6dae;} +a:visited {color: #1e6dae;} +a:hover {color: black;} +a:active {color: black;} + +a:link {text-decoration: none;} +a:visited {text-decoration: none;} +a:hover {text-decoration: underline;} +a:active {text-decoration: none;} + +@media (min-width: 1200px) { + .container { + max-width: 1250px; + } +} + +.pixel { + image-rendering: pixelated; +} + +.middle-icon { + display: inline-block; + max-width: 100%; + margin: -2px; + padding: -2px; +} + +img.middle-img-icon { + width: 50px; + height: 50px; + object-fit: contain; +} + +/* MAIN */ +.main-page:before, .main-page:after { + background: url('/images/scroll_top.gif') no-repeat center top; + content: ''; + height: 50px; + left: 0; + position: absolute; + top: -11px; + width: 100%; +} + +.main-page:after { + background: url('/images/scroll_bottom.gif') no-repeat center bottom; + bottom: -11px; + top: auto; +} + +.main-page { + background: url('/images/scroll_middle.gif') repeat-y top center; + position: relative; + margin: 0 auto; + padding: 75px; +} + +/* NEWS */ +.latest-news { + border-bottom: solid black 1px; + padding: 20px 0px 20px 0px; + transition: all .2s ease-in; + height: 175px; +} + +.latest-news:hover { + background: rgba(0, 0, 0, 0.2); +} + +.latest-news .content a:link {color: black;} +.latest-news .content a:visited {color: black;} +.latest-news .content a:hover {color: black;} +.latest-news .content a:active {color: black;} + +.latest-news .content a:link {text-decoration: none;} +.latest-news .content a:visited {text-decoration: none;} +.latest-news .content a:hover {text-decoration: none;} +.latest-news .content a:active {text-decoration: none;} + +.latest-news .image { + text-align: center; +} + +.latest-news .image img { + max-height: 175px; + max-width: 175px; +} + +.latest-news .title { + font-family: 'runescape', sans-serif; + font-weight: bold; + font-size: 2em; + margin-top: -10px; +} + +.latest-news .title:hover { + color: #666666; +} + +.latest-news .meta { + padding-bottom: 5px; +} + +.latest-news .title, .latest-news .meta, .latest-news .shortstory { + margin-left: -15px; +} + +.latest-news .date { + text-align: center; + margin-top: -10px; + margin-left: -15px; +} + +.latest-news .month { + font-family: 'runescape', sans-serif; + font-weight: bold; + font-size: 2em; +} + +.latest-news .day { + font-family: 'runescape', sans-serif; + font-weight: bold; + font-size: 2em; +} + +/* ACCOUNT */ +.account-body { + padding: 0; + margin: 0; + list-style: none; + display: flex; + flex-flow: row wrap; + justify-content: space-around; +} + +.account-box { + background: url('/images/button.gif') no-repeat; + background-position: center; + padding: 10px 5px 0px 5px; + width: 152px; + height: 126px; + margin-top: 10px; + color: white; + font-size: 1.5em; + font-weight: bold; + text-align: center; + transition: width .5s, height .5s, padding .5s; +} + +.account-box:hover { + width: 172px; + height: 146px; + padding: 20px 5px 0px 5px; +} + +/* PROFILE */ +.profile-icon { + background: #99855D; + border: solid #755B41 3px; + border-radius: 5px; + padding: 5px 5px 5px 15px; + text-align: center; + float: left; +} + +.profile-icon span { + padding-right: 10px; +} + +/* EDIT USER */ +.icon-radio [type=radio] { + position: absolute; + opacity: 0; + width: 0; + height: 0; +} + +.icon-radio [type=radio] + img { + cursor: pointer; + padding: 8px 8px 8px 8px; +} + +.icon-radio [type=radio] + img:hover { + background: #99855D; + border-radius: 5px; +} + +.icon-radio [type=radio]:checked + img { + background: #99855D; + border: solid #755B41 3px; + border-radius: 5px; + padding: 5px 5px 5px 5px; +} + +/* TASK */ +.task-progress-body { + display: flex; + flex-flow: row; + justify-content: space-between; +} + +.task-box { + background: #99855D; + border-width: 3px; +} + +/* HISCORE */ +#highscore_top .highscore_selection { + margin-top: 1.7em; + text-align: center; +} + +#highscore_top .highscore_selection a { + display: inline-block; + padding: 5px 7px; + position: relative; +} + +#highscore_top .highscore_selection a img { + vertical-align: middle; + height: 30px; + width: 30px; +} + +#highscore_top .highscore_selection a.active, +#highscore_top .highscore_selection a:hover { + background: #2D2D2B; +} + +a.selection-top, a.selection-bottom { + background: #373530; +} + +#highscore_top .highscore_selection .selection-top a.active:after, +#highscore_top .highscore_selection .selection-top a:hover:after { + border-left: solid transparent 14px; + border-right: solid transparent 14px; + border-top: solid #2D2D2B 14px; + bottom: -14px; + content: ""; + height: 0; + left: 50%; + margin-left: -14px; + position: absolute; + width: 0; + z-index: 10; +} + +#highscore_top .highscore_selection .selection-bot a.active:after, +#highscore_top .highscore_selection .selection-bot a:hover:after { + border-left: solid transparent 14px; + border-right: solid transparent 14px; + border-bottom: solid #2D2D2B 14px; + top: -14px; + content: ""; + height: 0; + left: 50%; + margin-left: -14px; + position: absolute; + width: 0; + z-index: 10; +} + +#highscore_top .highscore_selection .mid-part > span { + display: none; + padding: 20px 40px; + text-align: center; + font-size: 1.7em; + font-weight: 300; + + border-radius: 15px; +} + +#highscore_top .highscore_selection .mid-part > span img { + vertical-align: middle; + padding-right: 10px; +} + +#highscore_top .highscore_selection .mid-part > span.active { + display: inline-block; +} \ No newline at end of file diff --git a/public/images/background.png b/public/images/background.png new file mode 100644 index 00000000..b6412b78 Binary files /dev/null and b/public/images/background.png differ diff --git a/public/images/background_2.png b/public/images/background_2.png new file mode 100644 index 00000000..ca2f6be9 Binary files /dev/null and b/public/images/background_2.png differ diff --git a/public/images/boss/abyssal sire.png b/public/images/boss/abyssal sire.png new file mode 100644 index 00000000..371f6573 Binary files /dev/null and b/public/images/boss/abyssal sire.png differ diff --git a/public/images/boss/alchemical hydra.png b/public/images/boss/alchemical hydra.png new file mode 100644 index 00000000..d3c1697a Binary files /dev/null and b/public/images/boss/alchemical hydra.png differ diff --git a/public/images/boss/barrows chests.png b/public/images/boss/barrows chests.png new file mode 100644 index 00000000..167eb912 Binary files /dev/null and b/public/images/boss/barrows chests.png differ diff --git a/public/images/boss/boss.png b/public/images/boss/boss.png new file mode 100644 index 00000000..56998d65 Binary files /dev/null and b/public/images/boss/boss.png differ diff --git a/public/images/boss/bryophyta.png b/public/images/boss/bryophyta.png new file mode 100644 index 00000000..11996d0c Binary files /dev/null and b/public/images/boss/bryophyta.png differ diff --git a/public/images/boss/callisto.png b/public/images/boss/callisto.png new file mode 100644 index 00000000..a1fd8cbe Binary files /dev/null and b/public/images/boss/callisto.png differ diff --git a/public/images/boss/cerberus.png b/public/images/boss/cerberus.png new file mode 100644 index 00000000..3af95dec Binary files /dev/null and b/public/images/boss/cerberus.png differ diff --git a/public/images/boss/chambers of xeric challenge mode.png b/public/images/boss/chambers of xeric challenge mode.png new file mode 100644 index 00000000..167eb912 Binary files /dev/null and b/public/images/boss/chambers of xeric challenge mode.png differ diff --git a/public/images/boss/chambers of xeric.png b/public/images/boss/chambers of xeric.png new file mode 100644 index 00000000..4648486b Binary files /dev/null and b/public/images/boss/chambers of xeric.png differ diff --git a/public/images/boss/chaos elemental.png b/public/images/boss/chaos elemental.png new file mode 100644 index 00000000..76525815 Binary files /dev/null and b/public/images/boss/chaos elemental.png differ diff --git a/public/images/boss/chaos fanatic.png b/public/images/boss/chaos fanatic.png new file mode 100644 index 00000000..a7b87592 Binary files /dev/null and b/public/images/boss/chaos fanatic.png differ diff --git a/public/images/boss/commander zilyana.png b/public/images/boss/commander zilyana.png new file mode 100644 index 00000000..7389e579 Binary files /dev/null and b/public/images/boss/commander zilyana.png differ diff --git a/public/images/boss/corporeal beast.png b/public/images/boss/corporeal beast.png new file mode 100644 index 00000000..f8fc2a39 Binary files /dev/null and b/public/images/boss/corporeal beast.png differ diff --git a/public/images/boss/crazy archaeologist.png b/public/images/boss/crazy archaeologist.png new file mode 100644 index 00000000..4eeec11e Binary files /dev/null and b/public/images/boss/crazy archaeologist.png differ diff --git a/public/images/boss/dagannoth prime.png b/public/images/boss/dagannoth prime.png new file mode 100644 index 00000000..d07913a6 Binary files /dev/null and b/public/images/boss/dagannoth prime.png differ diff --git a/public/images/boss/dagannoth rex.png b/public/images/boss/dagannoth rex.png new file mode 100644 index 00000000..3f76c490 Binary files /dev/null and b/public/images/boss/dagannoth rex.png differ diff --git a/public/images/boss/dagannoth supreme.png b/public/images/boss/dagannoth supreme.png new file mode 100644 index 00000000..dd7002e0 Binary files /dev/null and b/public/images/boss/dagannoth supreme.png differ diff --git a/public/images/boss/deranged archaeologist.png b/public/images/boss/deranged archaeologist.png new file mode 100644 index 00000000..8abb62a8 Binary files /dev/null and b/public/images/boss/deranged archaeologist.png differ diff --git a/public/images/boss/general graardor.png b/public/images/boss/general graardor.png new file mode 100644 index 00000000..14ca35eb Binary files /dev/null and b/public/images/boss/general graardor.png differ diff --git a/public/images/boss/giant mole.png b/public/images/boss/giant mole.png new file mode 100644 index 00000000..3de73c61 Binary files /dev/null and b/public/images/boss/giant mole.png differ diff --git a/public/images/boss/grotesque guardians.png b/public/images/boss/grotesque guardians.png new file mode 100644 index 00000000..86d5c0f8 Binary files /dev/null and b/public/images/boss/grotesque guardians.png differ diff --git a/public/images/boss/hespori.png b/public/images/boss/hespori.png new file mode 100644 index 00000000..7c42c004 Binary files /dev/null and b/public/images/boss/hespori.png differ diff --git a/public/images/boss/kalphite queen.png b/public/images/boss/kalphite queen.png new file mode 100644 index 00000000..84d0b442 Binary files /dev/null and b/public/images/boss/kalphite queen.png differ diff --git a/public/images/boss/king black dragon.png b/public/images/boss/king black dragon.png new file mode 100644 index 00000000..947b9034 Binary files /dev/null and b/public/images/boss/king black dragon.png differ diff --git a/public/images/boss/kraken.png b/public/images/boss/kraken.png new file mode 100644 index 00000000..d2ed5243 Binary files /dev/null and b/public/images/boss/kraken.png differ diff --git a/public/images/boss/kreearra.png b/public/images/boss/kreearra.png new file mode 100644 index 00000000..f8ae3c29 Binary files /dev/null and b/public/images/boss/kreearra.png differ diff --git a/public/images/boss/kril tsutsaroth.png b/public/images/boss/kril tsutsaroth.png new file mode 100644 index 00000000..f5400491 Binary files /dev/null and b/public/images/boss/kril tsutsaroth.png differ diff --git a/public/images/boss/mimic.png b/public/images/boss/mimic.png new file mode 100644 index 00000000..7c87ca3d Binary files /dev/null and b/public/images/boss/mimic.png differ diff --git a/public/images/boss/nightmare.png b/public/images/boss/nightmare.png new file mode 100644 index 00000000..e8736329 Binary files /dev/null and b/public/images/boss/nightmare.png differ diff --git a/public/images/boss/obor.png b/public/images/boss/obor.png new file mode 100644 index 00000000..8520428f Binary files /dev/null and b/public/images/boss/obor.png differ diff --git a/public/images/boss/sarachnis.png b/public/images/boss/sarachnis.png new file mode 100644 index 00000000..b7b624fe Binary files /dev/null and b/public/images/boss/sarachnis.png differ diff --git a/public/images/boss/scorpia.png b/public/images/boss/scorpia.png new file mode 100644 index 00000000..e7e4bdad Binary files /dev/null and b/public/images/boss/scorpia.png differ diff --git a/public/images/boss/skotizo.png b/public/images/boss/skotizo.png new file mode 100644 index 00000000..07a6087e Binary files /dev/null and b/public/images/boss/skotizo.png differ diff --git a/public/images/boss/the corrupted gauntlet.png b/public/images/boss/the corrupted gauntlet.png new file mode 100644 index 00000000..32166fa0 Binary files /dev/null and b/public/images/boss/the corrupted gauntlet.png differ diff --git a/public/images/boss/the gauntlet.png b/public/images/boss/the gauntlet.png new file mode 100644 index 00000000..cabc1425 Binary files /dev/null and b/public/images/boss/the gauntlet.png differ diff --git a/public/images/boss/theatre of blood.png b/public/images/boss/theatre of blood.png new file mode 100644 index 00000000..10339bd0 Binary files /dev/null and b/public/images/boss/theatre of blood.png differ diff --git a/public/images/boss/thermonuclear smoke devil.png b/public/images/boss/thermonuclear smoke devil.png new file mode 100644 index 00000000..350a7a29 Binary files /dev/null and b/public/images/boss/thermonuclear smoke devil.png differ diff --git a/public/images/boss/tzkal zuk.png b/public/images/boss/tzkal zuk.png new file mode 100644 index 00000000..704ebfa7 Binary files /dev/null and b/public/images/boss/tzkal zuk.png differ diff --git a/public/images/boss/tztok jad.png b/public/images/boss/tztok jad.png new file mode 100644 index 00000000..be1bea79 Binary files /dev/null and b/public/images/boss/tztok jad.png differ diff --git a/public/images/boss/venenatis.png b/public/images/boss/venenatis.png new file mode 100644 index 00000000..53124862 Binary files /dev/null and b/public/images/boss/venenatis.png differ diff --git a/public/images/boss/vetion.png b/public/images/boss/vetion.png new file mode 100644 index 00000000..ee1a4a97 Binary files /dev/null and b/public/images/boss/vetion.png differ diff --git a/public/images/boss/vorkath.png b/public/images/boss/vorkath.png new file mode 100644 index 00000000..8e09eb9d Binary files /dev/null and b/public/images/boss/vorkath.png differ diff --git a/public/images/boss/wintertodt.png b/public/images/boss/wintertodt.png new file mode 100644 index 00000000..607eed00 Binary files /dev/null and b/public/images/boss/wintertodt.png differ diff --git a/public/images/boss/zalcano.png b/public/images/boss/zalcano.png new file mode 100644 index 00000000..14d0c1d9 Binary files /dev/null and b/public/images/boss/zalcano.png differ diff --git a/public/images/boss/zulrah.png b/public/images/boss/zulrah.png new file mode 100644 index 00000000..00622020 Binary files /dev/null and b/public/images/boss/zulrah.png differ diff --git a/public/images/button.gif b/public/images/button.gif new file mode 100644 index 00000000..65e3a6b6 Binary files /dev/null and b/public/images/button.gif differ diff --git a/public/images/friend.png b/public/images/friend.png new file mode 100644 index 00000000..7574b89f Binary files /dev/null and b/public/images/friend.png differ diff --git a/public/images/group.png b/public/images/group.png new file mode 100644 index 00000000..509a903e Binary files /dev/null and b/public/images/group.png differ diff --git a/public/images/hardcore.png b/public/images/hardcore.png new file mode 100644 index 00000000..3ed29b1e Binary files /dev/null and b/public/images/hardcore.png differ diff --git a/public/images/ignore.png b/public/images/ignore.png new file mode 100644 index 00000000..d95aabdd Binary files /dev/null and b/public/images/ignore.png differ diff --git a/public/images/ironman.png b/public/images/ironman.png new file mode 100644 index 00000000..6c5bd1ba Binary files /dev/null and b/public/images/ironman.png differ diff --git a/public/images/scroll_bottom.gif b/public/images/scroll_bottom.gif new file mode 100644 index 00000000..5b413d91 Binary files /dev/null and b/public/images/scroll_bottom.gif differ diff --git a/public/images/scroll_middle.gif b/public/images/scroll_middle.gif new file mode 100644 index 00000000..f5b71cc0 Binary files /dev/null and b/public/images/scroll_middle.gif differ diff --git a/public/images/scroll_top.gif b/public/images/scroll_top.gif new file mode 100644 index 00000000..689db4b9 Binary files /dev/null and b/public/images/scroll_top.gif differ diff --git a/public/images/skill/Agility.png b/public/images/skill/Agility.png new file mode 100644 index 00000000..c3bcdc41 Binary files /dev/null and b/public/images/skill/Agility.png differ diff --git a/public/images/skill/Attack.png b/public/images/skill/Attack.png new file mode 100644 index 00000000..21fa3425 Binary files /dev/null and b/public/images/skill/Attack.png differ diff --git a/public/images/skill/Construction.png b/public/images/skill/Construction.png new file mode 100644 index 00000000..d079075e Binary files /dev/null and b/public/images/skill/Construction.png differ diff --git a/public/images/skill/Cooking.png b/public/images/skill/Cooking.png new file mode 100644 index 00000000..d33208c2 Binary files /dev/null and b/public/images/skill/Cooking.png differ diff --git a/public/images/skill/Crafting.png b/public/images/skill/Crafting.png new file mode 100644 index 00000000..3b2a6969 Binary files /dev/null and b/public/images/skill/Crafting.png differ diff --git a/public/images/skill/Defence.png b/public/images/skill/Defence.png new file mode 100644 index 00000000..6876b1aa Binary files /dev/null and b/public/images/skill/Defence.png differ diff --git a/public/images/skill/Farming.png b/public/images/skill/Farming.png new file mode 100644 index 00000000..83a36b4c Binary files /dev/null and b/public/images/skill/Farming.png differ diff --git a/public/images/skill/Firemaking.png b/public/images/skill/Firemaking.png new file mode 100644 index 00000000..7d3a9947 Binary files /dev/null and b/public/images/skill/Firemaking.png differ diff --git a/public/images/skill/Fishing.png b/public/images/skill/Fishing.png new file mode 100644 index 00000000..023efbe8 Binary files /dev/null and b/public/images/skill/Fishing.png differ diff --git a/public/images/skill/Fletching.png b/public/images/skill/Fletching.png new file mode 100644 index 00000000..6a584255 Binary files /dev/null and b/public/images/skill/Fletching.png differ diff --git a/public/images/skill/Herblore.png b/public/images/skill/Herblore.png new file mode 100644 index 00000000..61e7979c Binary files /dev/null and b/public/images/skill/Herblore.png differ diff --git a/public/images/skill/Hitpoints.png b/public/images/skill/Hitpoints.png new file mode 100644 index 00000000..b5ce6622 Binary files /dev/null and b/public/images/skill/Hitpoints.png differ diff --git a/public/images/skill/Hunter.png b/public/images/skill/Hunter.png new file mode 100644 index 00000000..33d88401 Binary files /dev/null and b/public/images/skill/Hunter.png differ diff --git a/public/images/skill/Magic.png b/public/images/skill/Magic.png new file mode 100644 index 00000000..261702cb Binary files /dev/null and b/public/images/skill/Magic.png differ diff --git a/public/images/skill/Mining.png b/public/images/skill/Mining.png new file mode 100644 index 00000000..c0799913 Binary files /dev/null and b/public/images/skill/Mining.png differ diff --git a/public/images/skill/Overall.png b/public/images/skill/Overall.png new file mode 100644 index 00000000..1c946476 Binary files /dev/null and b/public/images/skill/Overall.png differ diff --git a/public/images/skill/Prayer.png b/public/images/skill/Prayer.png new file mode 100644 index 00000000..ea458dae Binary files /dev/null and b/public/images/skill/Prayer.png differ diff --git a/public/images/skill/Ranged.png b/public/images/skill/Ranged.png new file mode 100644 index 00000000..a6ee9162 Binary files /dev/null and b/public/images/skill/Ranged.png differ diff --git a/public/images/skill/Runecrafting.png b/public/images/skill/Runecrafting.png new file mode 100644 index 00000000..17e31200 Binary files /dev/null and b/public/images/skill/Runecrafting.png differ diff --git a/public/images/skill/Sailing.png b/public/images/skill/Sailing.png new file mode 100644 index 00000000..abb5c310 Binary files /dev/null and b/public/images/skill/Sailing.png differ diff --git a/public/images/skill/Slayer.png b/public/images/skill/Slayer.png new file mode 100644 index 00000000..c7a64f9a Binary files /dev/null and b/public/images/skill/Slayer.png differ diff --git a/public/images/skill/Smithing.png b/public/images/skill/Smithing.png new file mode 100644 index 00000000..4d950ee0 Binary files /dev/null and b/public/images/skill/Smithing.png differ diff --git a/public/images/skill/Strength.png b/public/images/skill/Strength.png new file mode 100644 index 00000000..308faf6a Binary files /dev/null and b/public/images/skill/Strength.png differ diff --git a/public/images/skill/Thieving.png b/public/images/skill/Thieving.png new file mode 100644 index 00000000..621c7948 Binary files /dev/null and b/public/images/skill/Thieving.png differ diff --git a/public/images/skill/Woodcutting.png b/public/images/skill/Woodcutting.png new file mode 100644 index 00000000..16ae50e1 Binary files /dev/null and b/public/images/skill/Woodcutting.png differ diff --git a/public/images/ultimate.png b/public/images/ultimate.png new file mode 100644 index 00000000..3ac53aaa Binary files /dev/null and b/public/images/ultimate.png differ diff --git a/public/js/app.js b/public/js/app.js index 6689a794..f8364a22 100644 --- a/public/js/app.js +++ b/public/js/app.js @@ -1899,10 +1899,10 @@ module.exports = { /***/ }), -/***/ "./node_modules/babel-loader/lib/index.js?!./node_modules/vue-loader/lib/index.js?!./resources/js/components/ExampleComponent.vue?vue&type=script&lang=js&": -/*!***************************************************************************************************************************************************************************!*\ - !*** ./node_modules/babel-loader/lib??ref--4-0!./node_modules/vue-loader/lib??vue-loader-options!./resources/js/components/ExampleComponent.vue?vue&type=script&lang=js& ***! - \***************************************************************************************************************************************************************************/ +/***/ "./node_modules/babel-loader/lib/index.js?!./node_modules/vue-loader/lib/index.js?!./resources/js/components/Account.vue?vue&type=script&lang=js&": +/*!******************************************************************************************************************************************************************!*\ + !*** ./node_modules/babel-loader/lib??ref--4-0!./node_modules/vue-loader/lib??vue-loader-options!./resources/js/components/Account.vue?vue&type=script&lang=js& ***! + \******************************************************************************************************************************************************************/ /*! exports provided: default */ /***/ (function(module, __webpack_exports__, __webpack_require__) { @@ -1924,9 +1924,175 @@ __webpack_require__.r(__webpack_exports__); // // // +// +// +// +// +// +// +// +// +// +// +// +// +// +// +// +// +// +// +// +// +/* harmony default export */ __webpack_exports__["default"] = ({ + props: { + accountId: { + type: Number, + required: true + } + }, + data: function data() { + return { + account: {}, + hiscores: {} + }; + }, + mounted: function mounted() { + var _this = this; + + axios.get('/api/account/' + this.accountId).then(function (response) { + _this.account = response.data.data; + _this.hiscores = response.data.meta.hiscores; + })["catch"](function (error) { + return console.log(error); + }); + }, + filters: { + capitalize: function capitalize(value) { + if (!value) return ''; + value = value.toString(); + return value.charAt(0).toUpperCase() + value.slice(1); + } + } +}); + +/***/ }), + +/***/ "./node_modules/babel-loader/lib/index.js?!./node_modules/vue-loader/lib/index.js?!./resources/js/components/BossHiscore.vue?vue&type=script&lang=js&": +/*!**********************************************************************************************************************************************************************!*\ + !*** ./node_modules/babel-loader/lib??ref--4-0!./node_modules/vue-loader/lib??vue-loader-options!./resources/js/components/BossHiscore.vue?vue&type=script&lang=js& ***! + \**********************************************************************************************************************************************************************/ +/*! exports provided: default */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { + +"use strict"; +__webpack_require__.r(__webpack_exports__); +// +// +// +// +// +// +// +// +// +// +// +// +// +// +// +// +// +// +// +/* harmony default export */ __webpack_exports__["default"] = ({ + props: { + boss: { + type: String, + required: true + } + }, + data: function data() { + return { + hiscores: {} + }; + }, + mounted: function mounted() { + var _this = this; + + axios.get('/api/hiscore/boss/' + this.boss).then(function (response) { + _this.hiscores = response.data.data; + })["catch"](function (error) { + return console.log(error); + }); + } +}); + +/***/ }), + +/***/ "./node_modules/babel-loader/lib/index.js?!./node_modules/vue-loader/lib/index.js?!./resources/js/components/SkillHiscore.vue?vue&type=script&lang=js&": +/*!***********************************************************************************************************************************************************************!*\ + !*** ./node_modules/babel-loader/lib??ref--4-0!./node_modules/vue-loader/lib??vue-loader-options!./resources/js/components/SkillHiscore.vue?vue&type=script&lang=js& ***! + \***********************************************************************************************************************************************************************/ +/*! exports provided: default */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { + +"use strict"; +__webpack_require__.r(__webpack_exports__); +// +// +// +// +// +// +// +// +// +// +// +// +// +// +// +// +// +// +// +// +// +// +// +// +// +// +// +// +// +// +// /* harmony default export */ __webpack_exports__["default"] = ({ + props: { + skill: { + type: String, + required: true + } + }, + data: function data() { + return { + hiscores: {}, + meta: {} + }; + }, mounted: function mounted() { - console.log('Component mounted.'); + var _this = this; + + axios.get('/api/hiscore/skill/' + this.skill).then(function (response) { + _this.hiscores = response.data.data; + _this.meta = response.data.meta; + })["catch"](function (error) { + return console.log(error); + }); } }); @@ -17267,7 +17433,7 @@ return jQuery; var undefined; /** Used as the semantic version number. */ - var VERSION = '4.17.15'; + var VERSION = '4.17.19'; /** Used as the size to enable large array optimizations. */ var LARGE_ARRAY_SIZE = 200; @@ -20974,8 +21140,21 @@ return jQuery; * @returns {Array} Returns the new sorted array. */ function baseOrderBy(collection, iteratees, orders) { + if (iteratees.length) { + iteratees = arrayMap(iteratees, function(iteratee) { + if (isArray(iteratee)) { + return function(value) { + return baseGet(value, iteratee.length === 1 ? iteratee[0] : iteratee); + } + } + return iteratee; + }); + } else { + iteratees = [identity]; + } + var index = -1; - iteratees = arrayMap(iteratees.length ? iteratees : [identity], baseUnary(getIteratee())); + iteratees = arrayMap(iteratees, baseUnary(getIteratee())); var result = baseMap(collection, function(value, key, collection) { var criteria = arrayMap(iteratees, function(iteratee) { @@ -21232,6 +21411,10 @@ return jQuery; var key = toKey(path[index]), newValue = value; + if (key === '__proto__' || key === 'constructor' || key === 'prototype') { + return object; + } + if (index != lastIndex) { var objValue = nested[key]; newValue = customizer ? customizer(objValue, key, nested) : undefined; @@ -21384,11 +21567,14 @@ return jQuery; * into `array`. */ function baseSortedIndexBy(array, value, iteratee, retHighest) { - value = iteratee(value); - var low = 0, - high = array == null ? 0 : array.length, - valIsNaN = value !== value, + high = array == null ? 0 : array.length; + if (high === 0) { + return 0; + } + + value = iteratee(value); + var valIsNaN = value !== value, valIsNull = value === null, valIsSymbol = isSymbol(value), valIsUndefined = value === undefined; @@ -22873,10 +23059,11 @@ return jQuery; if (arrLength != othLength && !(isPartial && othLength > arrLength)) { return false; } - // Assume cyclic values are equal. - var stacked = stack.get(array); - if (stacked && stack.get(other)) { - return stacked == other; + // Check that cyclic values are equal. + var arrStacked = stack.get(array); + var othStacked = stack.get(other); + if (arrStacked && othStacked) { + return arrStacked == other && othStacked == array; } var index = -1, result = true, @@ -23038,10 +23225,11 @@ return jQuery; return false; } } - // Assume cyclic values are equal. - var stacked = stack.get(object); - if (stacked && stack.get(other)) { - return stacked == other; + // Check that cyclic values are equal. + var objStacked = stack.get(object); + var othStacked = stack.get(other); + if (objStacked && othStacked) { + return objStacked == other && othStacked == object; } var result = true; stack.set(object, other); @@ -26422,6 +26610,10 @@ return jQuery; * // The `_.property` iteratee shorthand. * _.filter(users, 'active'); * // => objects for ['barney'] + * + * // Combining several predicates using `_.overEvery` or `_.overSome`. + * _.filter(users, _.overSome([{ 'age': 36 }, ['age', 40]])); + * // => objects for ['fred', 'barney'] */ function filter(collection, predicate) { var func = isArray(collection) ? arrayFilter : baseFilter; @@ -27171,15 +27363,15 @@ return jQuery; * var users = [ * { 'user': 'fred', 'age': 48 }, * { 'user': 'barney', 'age': 36 }, - * { 'user': 'fred', 'age': 40 }, + * { 'user': 'fred', 'age': 30 }, * { 'user': 'barney', 'age': 34 } * ]; * * _.sortBy(users, [function(o) { return o.user; }]); - * // => objects for [['barney', 36], ['barney', 34], ['fred', 48], ['fred', 40]] + * // => objects for [['barney', 36], ['barney', 34], ['fred', 48], ['fred', 30]] * * _.sortBy(users, ['user', 'age']); - * // => objects for [['barney', 34], ['barney', 36], ['fred', 40], ['fred', 48]] + * // => objects for [['barney', 34], ['barney', 36], ['fred', 30], ['fred', 48]] */ var sortBy = baseRest(function(collection, iteratees) { if (collection == null) { @@ -32054,11 +32246,11 @@ return jQuery; // Use a sourceURL for easier debugging. // The sourceURL gets injected into the source that's eval-ed, so be careful - // with lookup (in case of e.g. prototype pollution), and strip newlines if any. - // A newline wouldn't be a valid sourceURL anyway, and it'd enable code injection. + // to normalize all kinds of whitespace, so e.g. newlines (and unicode versions of it) can't sneak in + // and escape the comment, thus injecting code that gets evaled. var sourceURL = '//# sourceURL=' + (hasOwnProperty.call(options, 'sourceURL') - ? (options.sourceURL + '').replace(/[\r\n]/g, ' ') + ? (options.sourceURL + '').replace(/\s/g, ' ') : ('lodash.templateSources[' + (++templateCounter) + ']') ) + '\n'; @@ -32091,8 +32283,6 @@ return jQuery; // If `variable` is not specified wrap a with-statement around the generated // code to add the data object to the top of the scope chain. - // Like with sourceURL, we take care to not check the option's prototype, - // as this configuration is a code injection vector. var variable = hasOwnProperty.call(options, 'variable') && options.variable; if (!variable) { source = 'with (obj) {\n' + source + '\n}\n'; @@ -32799,6 +32989,9 @@ return jQuery; * values against any array or object value, respectively. See `_.isEqual` * for a list of supported value comparisons. * + * **Note:** Multiple values can be checked by combining several matchers + * using `_.overSome` + * * @static * @memberOf _ * @since 3.0.0 @@ -32814,6 +33007,10 @@ return jQuery; * * _.filter(objects, _.matches({ 'a': 4, 'c': 6 })); * // => [{ 'a': 4, 'b': 5, 'c': 6 }] + * + * // Checking for several possible values + * _.filter(users, _.overSome([_.matches({ 'a': 1 }), _.matches({ 'a': 4 })])); + * // => [{ 'a': 1, 'b': 2, 'c': 3 }, { 'a': 4, 'b': 5, 'c': 6 }] */ function matches(source) { return baseMatches(baseClone(source, CLONE_DEEP_FLAG)); @@ -32828,6 +33025,9 @@ return jQuery; * `srcValue` values against any array or object value, respectively. See * `_.isEqual` for a list of supported value comparisons. * + * **Note:** Multiple values can be checked by combining several matchers + * using `_.overSome` + * * @static * @memberOf _ * @since 3.2.0 @@ -32844,6 +33044,10 @@ return jQuery; * * _.find(objects, _.matchesProperty('a', 4)); * // => { 'a': 4, 'b': 5, 'c': 6 } + * + * // Checking for several possible values + * _.filter(users, _.overSome([_.matchesProperty('a', 1), _.matchesProperty('a', 4)])); + * // => [{ 'a': 1, 'b': 2, 'c': 3 }, { 'a': 4, 'b': 5, 'c': 6 }] */ function matchesProperty(path, srcValue) { return baseMatchesProperty(path, baseClone(srcValue, CLONE_DEEP_FLAG)); @@ -33067,6 +33271,10 @@ return jQuery; * Creates a function that checks if **all** of the `predicates` return * truthy when invoked with the arguments it receives. * + * Following shorthands are possible for providing predicates. + * Pass an `Object` and it will be used as an parameter for `_.matches` to create the predicate. + * Pass an `Array` of parameters for `_.matchesProperty` and the predicate will be created using them. + * * @static * @memberOf _ * @since 4.0.0 @@ -33093,6 +33301,10 @@ return jQuery; * Creates a function that checks if **any** of the `predicates` return * truthy when invoked with the arguments it receives. * + * Following shorthands are possible for providing predicates. + * Pass an `Object` and it will be used as an parameter for `_.matches` to create the predicate. + * Pass an `Array` of parameters for `_.matchesProperty` and the predicate will be created using them. + * * @static * @memberOf _ * @since 4.0.0 @@ -33112,6 +33324,9 @@ return jQuery; * * func(NaN); * // => false + * + * var matchesFunc = _.overSome([{ 'a': 1 }, { 'a': 2 }]) + * var matchesPropertyFunc = _.overSome([['a', 1], ['a', 2]]) */ var overSome = createOver(arraySome); @@ -37460,10 +37675,10 @@ exports.clearImmediate = (typeof self !== "undefined" && self.clearImmediate) || /***/ }), -/***/ "./node_modules/vue-loader/lib/loaders/templateLoader.js?!./node_modules/vue-loader/lib/index.js?!./resources/js/components/ExampleComponent.vue?vue&type=template&id=299e239e&": -/*!*******************************************************************************************************************************************************************************************************************!*\ - !*** ./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/vue-loader/lib??vue-loader-options!./resources/js/components/ExampleComponent.vue?vue&type=template&id=299e239e& ***! - \*******************************************************************************************************************************************************************************************************************/ +/***/ "./node_modules/vue-loader/lib/loaders/templateLoader.js?!./node_modules/vue-loader/lib/index.js?!./resources/js/components/Account.vue?vue&type=template&id=0b1dd512&": +/*!**********************************************************************************************************************************************************************************************************!*\ + !*** ./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/vue-loader/lib??vue-loader-options!./resources/js/components/Account.vue?vue&type=template&id=0b1dd512& ***! + \**********************************************************************************************************************************************************************************************************/ /*! exports provided: render, staticRenderFns */ /***/ (function(module, __webpack_exports__, __webpack_require__) { @@ -37475,29 +37690,242 @@ var render = function() { var _vm = this var _h = _vm.$createElement var _c = _vm._self._c || _h - return _vm._m(0) + return _c("div", [ + _c("div", { staticClass: "float-left ml-3" }, [ + _c("h1", { staticClass: "text-left" }, [ + _vm._v(_vm._s(_vm.account.username)) + ]), + _vm._v(" "), + _c("span", [ + _vm._v("Rank: "), + _c("strong", [_vm._v(_vm._s(_vm.account.rank))]) + ]), + _vm._v(" "), + _c("br"), + _vm._v(" "), + _c("span", [ + _vm._v("Total XP: "), + _c("strong", [_vm._v(_vm._s(_vm.account.xp))]) + ]), + _vm._v(" "), + _c("br"), + _vm._v(" "), + _c("span", [ + _vm._v("Total Level: "), + _c("strong", [_vm._v(_vm._s(_vm.account.level))]) + ]), + _vm._v(" "), + _c("br"), + _vm._v(" "), + _c("span", [ + _vm._v("Joined: "), + _c("strong", [_vm._v(_vm._s(_vm.account.joined))]) + ]) + ]), + _vm._v(" "), + _c( + "table", + [ + _vm._m(0), + _vm._v(" "), + _vm._l(_vm.hiscores, function(hiscore, key) { + return _c("tr", [ + _c("td", [ + _c("a", { attrs: { href: "/hiscore/" + key } }, [ + _c("img", { + staticClass: "align", + attrs: { + src: "/images/skill/" + key + ".png", + width: "35px", + alt: key + " skill icon" + } + }), + _vm._v( + "\n\t\t\t\t\t" + + _vm._s(_vm._f("capitalize")(key)) + + "\n\t\t\t\t" + ) + ]) + ]), + _vm._v(" "), + _c("td", [_vm._v(_vm._s(hiscore.level))]), + _vm._v(" "), + _c("td", [_vm._v(_vm._s(hiscore.xp))]), + _vm._v(" "), + _c("td", [_vm._v(_vm._s(hiscore.rank))]) + ]) + }) + ], + 2 + ) + ]) } var staticRenderFns = [ function() { var _vm = this var _h = _vm.$createElement var _c = _vm._self._c || _h - return _c("div", { staticClass: "container" }, [ - _c("div", { staticClass: "row justify-content-center" }, [ - _c("div", { staticClass: "col-md-8" }, [ - _c("div", { staticClass: "card" }, [ - _c("div", { staticClass: "card-header" }, [ - _vm._v("Example Component") + return _c("tr", [ + _c("th"), + _vm._v(" "), + _c("th", [_vm._v("Level")]), + _vm._v(" "), + _c("th", [_vm._v("XP")]), + _vm._v(" "), + _c("th", [_vm._v("Rank")]) + ]) + } +] +render._withStripped = true + + + +/***/ }), + +/***/ "./node_modules/vue-loader/lib/loaders/templateLoader.js?!./node_modules/vue-loader/lib/index.js?!./resources/js/components/BossHiscore.vue?vue&type=template&id=6ac49ae9&": +/*!**************************************************************************************************************************************************************************************************************!*\ + !*** ./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/vue-loader/lib??vue-loader-options!./resources/js/components/BossHiscore.vue?vue&type=template&id=6ac49ae9& ***! + \**************************************************************************************************************************************************************************************************************/ +/*! exports provided: render, staticRenderFns */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { + +"use strict"; +__webpack_require__.r(__webpack_exports__); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "render", function() { return render; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "staticRenderFns", function() { return staticRenderFns; }); +var render = function() { + var _vm = this + var _h = _vm.$createElement + var _c = _vm._self._c || _h + return _c("div", [ + _c( + "table", + [ + _vm._m(0), + _vm._v(" "), + _vm._l(_vm.hiscores, function(hiscore, index) { + return _c("tr", [ + _c("td", [_vm._v(_vm._s(index + 1))]), + _vm._v(" "), + _c("td", [ + _c("a", { attrs: { href: "/account/" + hiscore.account.id } }, [ + _vm._v(_vm._s(hiscore.account.username)) + ]) ]), _vm._v(" "), - _c("div", { staticClass: "card-body" }, [ - _vm._v( - "\n I'm an example component.\n " - ) - ]) + _c("td", [_vm._v(_vm._s(hiscore.kill_count))]), + _vm._v(" "), + _c("td", [_vm._v(_vm._s(hiscore.rank))]) ]) - ]) + }) + ], + 2 + ) + ]) +} +var staticRenderFns = [ + function() { + var _vm = this + var _h = _vm.$createElement + var _c = _vm._self._c || _h + return _c("tr", [ + _c("th", [_vm._v("Rank")]), + _vm._v(" "), + _c("th", [_vm._v("Account")]), + _vm._v(" "), + _c("th", [_vm._v("Kill count")]), + _vm._v(" "), + _c("th", [_vm._v("Hiscore Rank")]) + ]) + } +] +render._withStripped = true + + + +/***/ }), + +/***/ "./node_modules/vue-loader/lib/loaders/templateLoader.js?!./node_modules/vue-loader/lib/index.js?!./resources/js/components/SkillHiscore.vue?vue&type=template&id=618f0e8b&": +/*!***************************************************************************************************************************************************************************************************************!*\ + !*** ./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/vue-loader/lib??vue-loader-options!./resources/js/components/SkillHiscore.vue?vue&type=template&id=618f0e8b& ***! + \***************************************************************************************************************************************************************************************************************/ +/*! exports provided: render, staticRenderFns */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { + +"use strict"; +__webpack_require__.r(__webpack_exports__); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "render", function() { return render; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "staticRenderFns", function() { return staticRenderFns; }); +var render = function() { + var _vm = this + var _h = _vm.$createElement + var _c = _vm._self._c || _h + return _c("div", [ + _c("div", { staticClass: "float-left mt-3 ml-3" }, [ + _c("h1", { staticClass: "text-left" }, [_vm._v(_vm._s(_vm.meta.skill))]), + _vm._v(" "), + _c("span", [ + _vm._v("Total XP: "), + _c("strong", [_vm._v(_vm._s(_vm.meta.total_xp))]) + ]), + _vm._v(" "), + _c("br"), + _vm._v(" "), + _c("span", [ + _vm._v("Average Level: "), + _c("strong", [_vm._v(_vm._s(_vm.meta.average_total_level))]) + ]), + _vm._v(" "), + _c("br"), + _vm._v(" "), + _c("span", [ + _vm._v("Maxed: "), + _c("strong", [_vm._v(_vm._s(_vm.meta.total_max_level))]) ]) + ]), + _vm._v(" "), + _c( + "table", + [ + _vm._m(0), + _vm._v(" "), + _vm._l(_vm.hiscores, function(hiscore, index) { + return _c("tr", [ + _c("td", [_vm._v(_vm._s(index + 1))]), + _vm._v(" "), + _c("td", [ + _c("a", { attrs: { href: "/account/" + hiscore.id } }, [ + _vm._v(_vm._s(hiscore.username)) + ]) + ]), + _vm._v(" "), + _c("td", [_vm._v(_vm._s(hiscore.level))]), + _vm._v(" "), + _c("td", [_vm._v(_vm._s(hiscore.xp))]), + _vm._v(" "), + _c("td", [_vm._v(_vm._s(hiscore.rank))]) + ]) + }) + ], + 2 + ) + ]) +} +var staticRenderFns = [ + function() { + var _vm = this + var _h = _vm.$createElement + var _c = _vm._self._c || _h + return _c("tr", [ + _c("th", [_vm._v("Rank")]), + _vm._v(" "), + _c("th", [_vm._v("Account")]), + _vm._v(" "), + _c("th", [_vm._v("Total Level")]), + _vm._v(" "), + _c("th", [_vm._v("Total XP")]), + _vm._v(" "), + _c("th", [_vm._v("Hiscore Rank")]) ]) } ] @@ -49694,7 +50122,9 @@ window.Vue = __webpack_require__(/*! vue */ "./node_modules/vue/dist/vue.common. // const files = require.context('./', true, /\.vue$/i) // files.keys().map(key => Vue.component(key.split('/').pop().split('.')[0], files(key).default)) -Vue.component('example-component', __webpack_require__(/*! ./components/ExampleComponent.vue */ "./resources/js/components/ExampleComponent.vue")["default"]); +Vue.component('skillhiscore', __webpack_require__(/*! ./components/SkillHiscore.vue */ "./resources/js/components/SkillHiscore.vue")["default"]); +Vue.component('bosshiscore', __webpack_require__(/*! ./components/BossHiscore.vue */ "./resources/js/components/BossHiscore.vue")["default"]); +Vue.component('account', __webpack_require__(/*! ./components/Account.vue */ "./resources/js/components/Account.vue")["default"]); /** * Next, we will create a fresh Vue application instance and attach it to * the page. Then, you may begin adding components to this application @@ -49752,17 +50182,155 @@ window.axios.defaults.headers.common['X-Requested-With'] = 'XMLHttpRequest'; /***/ }), -/***/ "./resources/js/components/ExampleComponent.vue": -/*!******************************************************!*\ - !*** ./resources/js/components/ExampleComponent.vue ***! - \******************************************************/ +/***/ "./resources/js/components/Account.vue": +/*!*********************************************!*\ + !*** ./resources/js/components/Account.vue ***! + \*********************************************/ +/*! exports provided: default */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { + +"use strict"; +__webpack_require__.r(__webpack_exports__); +/* harmony import */ var _Account_vue_vue_type_template_id_0b1dd512___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./Account.vue?vue&type=template&id=0b1dd512& */ "./resources/js/components/Account.vue?vue&type=template&id=0b1dd512&"); +/* harmony import */ var _Account_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./Account.vue?vue&type=script&lang=js& */ "./resources/js/components/Account.vue?vue&type=script&lang=js&"); +/* empty/unused harmony star reexport *//* harmony import */ var _node_modules_vue_loader_lib_runtime_componentNormalizer_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../../node_modules/vue-loader/lib/runtime/componentNormalizer.js */ "./node_modules/vue-loader/lib/runtime/componentNormalizer.js"); + + + + + +/* normalize component */ + +var component = Object(_node_modules_vue_loader_lib_runtime_componentNormalizer_js__WEBPACK_IMPORTED_MODULE_2__["default"])( + _Account_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_1__["default"], + _Account_vue_vue_type_template_id_0b1dd512___WEBPACK_IMPORTED_MODULE_0__["render"], + _Account_vue_vue_type_template_id_0b1dd512___WEBPACK_IMPORTED_MODULE_0__["staticRenderFns"], + false, + null, + null, + null + +) + +/* hot reload */ +if (false) { var api; } +component.options.__file = "resources/js/components/Account.vue" +/* harmony default export */ __webpack_exports__["default"] = (component.exports); + +/***/ }), + +/***/ "./resources/js/components/Account.vue?vue&type=script&lang=js&": +/*!**********************************************************************!*\ + !*** ./resources/js/components/Account.vue?vue&type=script&lang=js& ***! + \**********************************************************************/ +/*! exports provided: default */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { + +"use strict"; +__webpack_require__.r(__webpack_exports__); +/* harmony import */ var _node_modules_babel_loader_lib_index_js_ref_4_0_node_modules_vue_loader_lib_index_js_vue_loader_options_Account_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! -!../../../node_modules/babel-loader/lib??ref--4-0!../../../node_modules/vue-loader/lib??vue-loader-options!./Account.vue?vue&type=script&lang=js& */ "./node_modules/babel-loader/lib/index.js?!./node_modules/vue-loader/lib/index.js?!./resources/js/components/Account.vue?vue&type=script&lang=js&"); +/* empty/unused harmony star reexport */ /* harmony default export */ __webpack_exports__["default"] = (_node_modules_babel_loader_lib_index_js_ref_4_0_node_modules_vue_loader_lib_index_js_vue_loader_options_Account_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_0__["default"]); + +/***/ }), + +/***/ "./resources/js/components/Account.vue?vue&type=template&id=0b1dd512&": +/*!****************************************************************************!*\ + !*** ./resources/js/components/Account.vue?vue&type=template&id=0b1dd512& ***! + \****************************************************************************/ +/*! exports provided: render, staticRenderFns */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { + +"use strict"; +__webpack_require__.r(__webpack_exports__); +/* harmony import */ var _node_modules_vue_loader_lib_loaders_templateLoader_js_vue_loader_options_node_modules_vue_loader_lib_index_js_vue_loader_options_Account_vue_vue_type_template_id_0b1dd512___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! -!../../../node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!../../../node_modules/vue-loader/lib??vue-loader-options!./Account.vue?vue&type=template&id=0b1dd512& */ "./node_modules/vue-loader/lib/loaders/templateLoader.js?!./node_modules/vue-loader/lib/index.js?!./resources/js/components/Account.vue?vue&type=template&id=0b1dd512&"); +/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "render", function() { return _node_modules_vue_loader_lib_loaders_templateLoader_js_vue_loader_options_node_modules_vue_loader_lib_index_js_vue_loader_options_Account_vue_vue_type_template_id_0b1dd512___WEBPACK_IMPORTED_MODULE_0__["render"]; }); + +/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "staticRenderFns", function() { return _node_modules_vue_loader_lib_loaders_templateLoader_js_vue_loader_options_node_modules_vue_loader_lib_index_js_vue_loader_options_Account_vue_vue_type_template_id_0b1dd512___WEBPACK_IMPORTED_MODULE_0__["staticRenderFns"]; }); + + + +/***/ }), + +/***/ "./resources/js/components/BossHiscore.vue": +/*!*************************************************!*\ + !*** ./resources/js/components/BossHiscore.vue ***! + \*************************************************/ +/*! exports provided: default */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { + +"use strict"; +__webpack_require__.r(__webpack_exports__); +/* harmony import */ var _BossHiscore_vue_vue_type_template_id_6ac49ae9___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./BossHiscore.vue?vue&type=template&id=6ac49ae9& */ "./resources/js/components/BossHiscore.vue?vue&type=template&id=6ac49ae9&"); +/* harmony import */ var _BossHiscore_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./BossHiscore.vue?vue&type=script&lang=js& */ "./resources/js/components/BossHiscore.vue?vue&type=script&lang=js&"); +/* empty/unused harmony star reexport *//* harmony import */ var _node_modules_vue_loader_lib_runtime_componentNormalizer_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../../node_modules/vue-loader/lib/runtime/componentNormalizer.js */ "./node_modules/vue-loader/lib/runtime/componentNormalizer.js"); + + + + + +/* normalize component */ + +var component = Object(_node_modules_vue_loader_lib_runtime_componentNormalizer_js__WEBPACK_IMPORTED_MODULE_2__["default"])( + _BossHiscore_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_1__["default"], + _BossHiscore_vue_vue_type_template_id_6ac49ae9___WEBPACK_IMPORTED_MODULE_0__["render"], + _BossHiscore_vue_vue_type_template_id_6ac49ae9___WEBPACK_IMPORTED_MODULE_0__["staticRenderFns"], + false, + null, + null, + null + +) + +/* hot reload */ +if (false) { var api; } +component.options.__file = "resources/js/components/BossHiscore.vue" +/* harmony default export */ __webpack_exports__["default"] = (component.exports); + +/***/ }), + +/***/ "./resources/js/components/BossHiscore.vue?vue&type=script&lang=js&": +/*!**************************************************************************!*\ + !*** ./resources/js/components/BossHiscore.vue?vue&type=script&lang=js& ***! + \**************************************************************************/ +/*! exports provided: default */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { + +"use strict"; +__webpack_require__.r(__webpack_exports__); +/* harmony import */ var _node_modules_babel_loader_lib_index_js_ref_4_0_node_modules_vue_loader_lib_index_js_vue_loader_options_BossHiscore_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! -!../../../node_modules/babel-loader/lib??ref--4-0!../../../node_modules/vue-loader/lib??vue-loader-options!./BossHiscore.vue?vue&type=script&lang=js& */ "./node_modules/babel-loader/lib/index.js?!./node_modules/vue-loader/lib/index.js?!./resources/js/components/BossHiscore.vue?vue&type=script&lang=js&"); +/* empty/unused harmony star reexport */ /* harmony default export */ __webpack_exports__["default"] = (_node_modules_babel_loader_lib_index_js_ref_4_0_node_modules_vue_loader_lib_index_js_vue_loader_options_BossHiscore_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_0__["default"]); + +/***/ }), + +/***/ "./resources/js/components/BossHiscore.vue?vue&type=template&id=6ac49ae9&": +/*!********************************************************************************!*\ + !*** ./resources/js/components/BossHiscore.vue?vue&type=template&id=6ac49ae9& ***! + \********************************************************************************/ +/*! exports provided: render, staticRenderFns */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { + +"use strict"; +__webpack_require__.r(__webpack_exports__); +/* harmony import */ var _node_modules_vue_loader_lib_loaders_templateLoader_js_vue_loader_options_node_modules_vue_loader_lib_index_js_vue_loader_options_BossHiscore_vue_vue_type_template_id_6ac49ae9___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! -!../../../node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!../../../node_modules/vue-loader/lib??vue-loader-options!./BossHiscore.vue?vue&type=template&id=6ac49ae9& */ "./node_modules/vue-loader/lib/loaders/templateLoader.js?!./node_modules/vue-loader/lib/index.js?!./resources/js/components/BossHiscore.vue?vue&type=template&id=6ac49ae9&"); +/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "render", function() { return _node_modules_vue_loader_lib_loaders_templateLoader_js_vue_loader_options_node_modules_vue_loader_lib_index_js_vue_loader_options_BossHiscore_vue_vue_type_template_id_6ac49ae9___WEBPACK_IMPORTED_MODULE_0__["render"]; }); + +/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "staticRenderFns", function() { return _node_modules_vue_loader_lib_loaders_templateLoader_js_vue_loader_options_node_modules_vue_loader_lib_index_js_vue_loader_options_BossHiscore_vue_vue_type_template_id_6ac49ae9___WEBPACK_IMPORTED_MODULE_0__["staticRenderFns"]; }); + + + +/***/ }), + +/***/ "./resources/js/components/SkillHiscore.vue": +/*!**************************************************!*\ + !*** ./resources/js/components/SkillHiscore.vue ***! + \**************************************************/ /*! exports provided: default */ /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; __webpack_require__.r(__webpack_exports__); -/* harmony import */ var _ExampleComponent_vue_vue_type_template_id_299e239e___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./ExampleComponent.vue?vue&type=template&id=299e239e& */ "./resources/js/components/ExampleComponent.vue?vue&type=template&id=299e239e&"); -/* harmony import */ var _ExampleComponent_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./ExampleComponent.vue?vue&type=script&lang=js& */ "./resources/js/components/ExampleComponent.vue?vue&type=script&lang=js&"); +/* harmony import */ var _SkillHiscore_vue_vue_type_template_id_618f0e8b___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./SkillHiscore.vue?vue&type=template&id=618f0e8b& */ "./resources/js/components/SkillHiscore.vue?vue&type=template&id=618f0e8b&"); +/* harmony import */ var _SkillHiscore_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./SkillHiscore.vue?vue&type=script&lang=js& */ "./resources/js/components/SkillHiscore.vue?vue&type=script&lang=js&"); /* empty/unused harmony star reexport *//* harmony import */ var _node_modules_vue_loader_lib_runtime_componentNormalizer_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../../node_modules/vue-loader/lib/runtime/componentNormalizer.js */ "./node_modules/vue-loader/lib/runtime/componentNormalizer.js"); @@ -49772,9 +50340,9 @@ __webpack_require__.r(__webpack_exports__); /* normalize component */ var component = Object(_node_modules_vue_loader_lib_runtime_componentNormalizer_js__WEBPACK_IMPORTED_MODULE_2__["default"])( - _ExampleComponent_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_1__["default"], - _ExampleComponent_vue_vue_type_template_id_299e239e___WEBPACK_IMPORTED_MODULE_0__["render"], - _ExampleComponent_vue_vue_type_template_id_299e239e___WEBPACK_IMPORTED_MODULE_0__["staticRenderFns"], + _SkillHiscore_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_1__["default"], + _SkillHiscore_vue_vue_type_template_id_618f0e8b___WEBPACK_IMPORTED_MODULE_0__["render"], + _SkillHiscore_vue_vue_type_template_id_618f0e8b___WEBPACK_IMPORTED_MODULE_0__["staticRenderFns"], false, null, null, @@ -49784,38 +50352,38 @@ var component = Object(_node_modules_vue_loader_lib_runtime_componentNormalizer_ /* hot reload */ if (false) { var api; } -component.options.__file = "resources/js/components/ExampleComponent.vue" +component.options.__file = "resources/js/components/SkillHiscore.vue" /* harmony default export */ __webpack_exports__["default"] = (component.exports); /***/ }), -/***/ "./resources/js/components/ExampleComponent.vue?vue&type=script&lang=js&": -/*!*******************************************************************************!*\ - !*** ./resources/js/components/ExampleComponent.vue?vue&type=script&lang=js& ***! - \*******************************************************************************/ +/***/ "./resources/js/components/SkillHiscore.vue?vue&type=script&lang=js&": +/*!***************************************************************************!*\ + !*** ./resources/js/components/SkillHiscore.vue?vue&type=script&lang=js& ***! + \***************************************************************************/ /*! exports provided: default */ /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; __webpack_require__.r(__webpack_exports__); -/* harmony import */ var _node_modules_babel_loader_lib_index_js_ref_4_0_node_modules_vue_loader_lib_index_js_vue_loader_options_ExampleComponent_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! -!../../../node_modules/babel-loader/lib??ref--4-0!../../../node_modules/vue-loader/lib??vue-loader-options!./ExampleComponent.vue?vue&type=script&lang=js& */ "./node_modules/babel-loader/lib/index.js?!./node_modules/vue-loader/lib/index.js?!./resources/js/components/ExampleComponent.vue?vue&type=script&lang=js&"); -/* empty/unused harmony star reexport */ /* harmony default export */ __webpack_exports__["default"] = (_node_modules_babel_loader_lib_index_js_ref_4_0_node_modules_vue_loader_lib_index_js_vue_loader_options_ExampleComponent_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_0__["default"]); +/* harmony import */ var _node_modules_babel_loader_lib_index_js_ref_4_0_node_modules_vue_loader_lib_index_js_vue_loader_options_SkillHiscore_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! -!../../../node_modules/babel-loader/lib??ref--4-0!../../../node_modules/vue-loader/lib??vue-loader-options!./SkillHiscore.vue?vue&type=script&lang=js& */ "./node_modules/babel-loader/lib/index.js?!./node_modules/vue-loader/lib/index.js?!./resources/js/components/SkillHiscore.vue?vue&type=script&lang=js&"); +/* empty/unused harmony star reexport */ /* harmony default export */ __webpack_exports__["default"] = (_node_modules_babel_loader_lib_index_js_ref_4_0_node_modules_vue_loader_lib_index_js_vue_loader_options_SkillHiscore_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_0__["default"]); /***/ }), -/***/ "./resources/js/components/ExampleComponent.vue?vue&type=template&id=299e239e&": -/*!*************************************************************************************!*\ - !*** ./resources/js/components/ExampleComponent.vue?vue&type=template&id=299e239e& ***! - \*************************************************************************************/ +/***/ "./resources/js/components/SkillHiscore.vue?vue&type=template&id=618f0e8b&": +/*!*********************************************************************************!*\ + !*** ./resources/js/components/SkillHiscore.vue?vue&type=template&id=618f0e8b& ***! + \*********************************************************************************/ /*! exports provided: render, staticRenderFns */ /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; __webpack_require__.r(__webpack_exports__); -/* harmony import */ var _node_modules_vue_loader_lib_loaders_templateLoader_js_vue_loader_options_node_modules_vue_loader_lib_index_js_vue_loader_options_ExampleComponent_vue_vue_type_template_id_299e239e___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! -!../../../node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!../../../node_modules/vue-loader/lib??vue-loader-options!./ExampleComponent.vue?vue&type=template&id=299e239e& */ "./node_modules/vue-loader/lib/loaders/templateLoader.js?!./node_modules/vue-loader/lib/index.js?!./resources/js/components/ExampleComponent.vue?vue&type=template&id=299e239e&"); -/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "render", function() { return _node_modules_vue_loader_lib_loaders_templateLoader_js_vue_loader_options_node_modules_vue_loader_lib_index_js_vue_loader_options_ExampleComponent_vue_vue_type_template_id_299e239e___WEBPACK_IMPORTED_MODULE_0__["render"]; }); +/* harmony import */ var _node_modules_vue_loader_lib_loaders_templateLoader_js_vue_loader_options_node_modules_vue_loader_lib_index_js_vue_loader_options_SkillHiscore_vue_vue_type_template_id_618f0e8b___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! -!../../../node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!../../../node_modules/vue-loader/lib??vue-loader-options!./SkillHiscore.vue?vue&type=template&id=618f0e8b& */ "./node_modules/vue-loader/lib/loaders/templateLoader.js?!./node_modules/vue-loader/lib/index.js?!./resources/js/components/SkillHiscore.vue?vue&type=template&id=618f0e8b&"); +/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "render", function() { return _node_modules_vue_loader_lib_loaders_templateLoader_js_vue_loader_options_node_modules_vue_loader_lib_index_js_vue_loader_options_SkillHiscore_vue_vue_type_template_id_618f0e8b___WEBPACK_IMPORTED_MODULE_0__["render"]; }); -/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "staticRenderFns", function() { return _node_modules_vue_loader_lib_loaders_templateLoader_js_vue_loader_options_node_modules_vue_loader_lib_index_js_vue_loader_options_ExampleComponent_vue_vue_type_template_id_299e239e___WEBPACK_IMPORTED_MODULE_0__["staticRenderFns"]; }); +/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "staticRenderFns", function() { return _node_modules_vue_loader_lib_loaders_templateLoader_js_vue_loader_options_node_modules_vue_loader_lib_index_js_vue_loader_options_SkillHiscore_vue_vue_type_template_id_618f0e8b___WEBPACK_IMPORTED_MODULE_0__["staticRenderFns"]; }); diff --git a/resources/js/app.js b/resources/js/app.js index aa19e31a..ab5d76ab 100644 --- a/resources/js/app.js +++ b/resources/js/app.js @@ -19,7 +19,9 @@ window.Vue = require('vue'); // const files = require.context('./', true, /\.vue$/i) // files.keys().map(key => Vue.component(key.split('/').pop().split('.')[0], files(key).default)) -Vue.component('example-component', require('./components/ExampleComponent.vue').default); +Vue.component('skillhiscore', require('./components/SkillHiscore.vue').default); +Vue.component('bosshiscore', require('./components/BossHiscore.vue').default); +Vue.component('account', require('./components/Account.vue').default); /** * Next, we will create a fresh Vue application instance and attach it to diff --git a/resources/js/components/Account.vue b/resources/js/components/Account.vue new file mode 100644 index 00000000..74a0051b --- /dev/null +++ b/resources/js/components/Account.vue @@ -0,0 +1,68 @@ + + + \ No newline at end of file diff --git a/resources/js/components/BossHiscore.vue b/resources/js/components/BossHiscore.vue new file mode 100644 index 00000000..c0368da1 --- /dev/null +++ b/resources/js/components/BossHiscore.vue @@ -0,0 +1,41 @@ + + + \ No newline at end of file diff --git a/resources/js/components/SkillHiscore.vue b/resources/js/components/SkillHiscore.vue new file mode 100644 index 00000000..ce8e9be7 --- /dev/null +++ b/resources/js/components/SkillHiscore.vue @@ -0,0 +1,55 @@ + + + \ No newline at end of file diff --git a/resources/views/account/auth.blade.php b/resources/views/account/auth.blade.php new file mode 100644 index 00000000..fdfc3d9b --- /dev/null +++ b/resources/views/account/auth.blade.php @@ -0,0 +1,21 @@ +@extends('layouts.layout') + +@section('title') + {{ __('title.create-member') }} +@endsection + +@section('content') +

Status pending...

+ +

Code: {{ $authStatus->code }}

+ +
+ @csrf + +
+
+ +
+
+
+@endsection \ No newline at end of file diff --git a/resources/views/account/create.blade.php b/resources/views/account/create.blade.php new file mode 100644 index 00000000..3288f08f --- /dev/null +++ b/resources/views/account/create.blade.php @@ -0,0 +1,84 @@ +@extends('layouts.layout') + +@section('title') + {{ __('title.create-member') }} +@endsection + +@section('content') +

{{ __('title.create-member') }}

+ +
+ @csrf + +
+ + +
+ + + @error('username') + + {{ $message }} + + @enderror +
+
+ +
+ + +
+
+ +
+ +
+ +
+ +
+ +
+ +
+ +
+ +
+ +
+ + @error('mode') + + {{ $message }} + + @enderror +
+
+ +
+
+ +
+
+
+@endsection \ No newline at end of file diff --git a/resources/views/account/index.blade.php b/resources/views/account/index.blade.php new file mode 100644 index 00000000..0e15e501 --- /dev/null +++ b/resources/views/account/index.blade.php @@ -0,0 +1,67 @@ +@extends('layouts.layout') + +@section('title') + {{ __('title.account') }} +@endsection + +@section('content') + @if (count($accounts) > 0) +

Search for accounts

+ +
+ @csrf + +
+ +
+ + + @error('search') + + {{ $message }} + + @enderror +
+ + +
+ + @if ($query) +

Search results for "{{ $query }}"

+ +
+ @foreach($accounts as $result) + + + + @endforeach +
+ @else +

{{ __('title.account') }}

+ +
+ @foreach($accounts as $account) + + + + @endforeach +
+ @endif + @else +
+ Sad face +

There are no linked accounts...

+

Link an account here!

+
+ @endif +@endsection \ No newline at end of file diff --git a/resources/views/account/show.blade.php b/resources/views/account/show.blade.php new file mode 100644 index 00000000..f4881804 --- /dev/null +++ b/resources/views/account/show.blade.php @@ -0,0 +1,27 @@ +@extends('layouts.layout') + +@section('title') + {{ $account->username }} +@endsection + +@section('content') + @if ($account->user->private === 0 || (Auth::check() && $account->user->id == Auth::user()->id)) + @if ($account->user->icon_id != null) +
+ Profile icon +
+ @elseif ((Auth::check() && $account->user->id == Auth::user()->id) && $account->user->icon_id == null) +
+ Profile icon +

Get your own profile icon here!

+
+ @endif + + + @else +
+ Sad face +

This user is private

+
+ @endif +@endsection \ No newline at end of file diff --git a/resources/views/admin/index.blade.php b/resources/views/admin/index.blade.php new file mode 100644 index 00000000..2c55188d --- /dev/null +++ b/resources/views/admin/index.blade.php @@ -0,0 +1,67 @@ +@extends('layouts.admin') + +@section('title') + TITLE +@endsection + +@section('content') +
+
+
+
+
+
Total users
+

{{ $users }}

+
+
+ +
+
+
+
Lorem ipsum
+

dolor sit amet

+
+
+ +
+
+
+
Lorem ipsum
+

dolor sit amet

+
+
+ +
+
+
+
Lorem ipsum
+

dolor sit amet

+
+
+
+ +
+ @for ($i = 0; $i < 2; $i++) +
+
Tittel
+
+
Lorem ipsum
+

dolor sit amet

+
+
+ @endfor +
+ +
+ @for ($i = 0; $i < 2; $i++) +
+
Tittel
+
+
Lorem ipsum
+

dolor sit amet

+
+
+ @endfor +
+
+@endsection \ No newline at end of file diff --git a/resources/views/admin/member/create.blade.php b/resources/views/admin/member/create.blade.php new file mode 100644 index 00000000..12a84b9b --- /dev/null +++ b/resources/views/admin/member/create.blade.php @@ -0,0 +1,29 @@ +@extends('layouts.admin') + +@section('title') + TITLE +@endsection + +@section('content') +

Register an OSRS account

+

If you want to preregister an OSRS account for future use / reference, you can do it here.

+

This means this account will not be able to be linked for a new user, but have to be linked manually.

+ +
+ @csrf + + + + + + @error('username') + + {{ $message }} + + @enderror + +
+ +
+
+@endsection \ No newline at end of file diff --git a/resources/views/admin/member/index.blade.php b/resources/views/admin/member/index.blade.php new file mode 100644 index 00000000..e32d19e2 --- /dev/null +++ b/resources/views/admin/member/index.blade.php @@ -0,0 +1,61 @@ +@extends('layouts.admin') + +@section('title') + TITLE +@endsection + +@section('content') + @section('navigation') + Register account + @endsection + +
+
+

Search for OSRS accounts

+
+ +
+ @csrf + +
+ +
+ + + @error('search') + + {{ $message }} + + @enderror +
+ + +
+
+ + @if ($query)

Search results for "{{ $query }}"

@endif + + + + + + + + + + + + @foreach ($members as $member) + + + + + + + + + + + @endforeach +
Account IDUsernameRankLevelXPLinked userRegisteredActions
{{ $member->id }}{{ $member->username }}{{ number_format($member->rank) }}{{ $member->level }}{{ number_format($member->xp) }}@if ($member->user_id)@if ($member->user->icon_id)Profile icon@endif{{ $member->user_id }} - {{ $member->user->name }}@endif{{ \Carbon\Carbon::parse($member->created_at)->format('d. M Y H:i') }}Show
+@endsection \ No newline at end of file diff --git a/resources/views/admin/member/show.blade.php b/resources/views/admin/member/show.blade.php new file mode 100644 index 00000000..21ddc4d1 --- /dev/null +++ b/resources/views/admin/member/show.blade.php @@ -0,0 +1,70 @@ +@extends('layouts.admin') + +@section('title') + TITLE +@endsection + +@section('content') +
+
+

{{ $member->username }}

+ + Rank: {{ number_format($member->rank) }} +
+ Total XP: {{ number_format($member->xp) }} +
+ Total Level: {{ $member->level }} +
+ Joined: {{ \Carbon\Carbon::parse($member->created_at)->format('d. M Y') }} +
+ +
+
Transfer ownership of this account:
+ +
+ @method('PATCH') + @csrf + + @if ($member->user_id) + + @else + + @endif + + + + @error('user_id') + + {{ $message }} + + @enderror + + +
+
+
+ + + + + + + + + + @foreach (Helper::accountStats($member->id) as $skillId => $skill) + + + + + + + + @endforeach +
SkillLevelXPRankLast trained
+ + {{ ucfirst(Helper::listSkills()[$skillId]) }} skill icon + {{ ucfirst(Helper::listSkills()[$skillId]) }} + + {{ $skill[0]->level }}{{ number_format($skill[0]->xp) }}{{ number_format($skill[0]->rank) }}{{ \Carbon\Carbon::parse($skill[0]->updated_at)->format('d. M Y H:i') }}
+@endsection \ No newline at end of file diff --git a/resources/views/admin/news/create.blade.php b/resources/views/admin/news/create.blade.php new file mode 100644 index 00000000..e8dbcc79 --- /dev/null +++ b/resources/views/admin/news/create.blade.php @@ -0,0 +1,84 @@ +@extends('layouts.admin') + +@section('title') + TITLE +@endsection + +@section('content') +

{{ __('title.create-newspost') }}

+ +
+ @csrf + +
+ + +
+ +
+
+ +
+ + +
+ + + @error('title') + + {{ $message }} + + @enderror +
+
+ +
+ + +
+ + + @error('category_id') + + {{ $message }} + + @enderror +
+
+ +
+ + +
+ + + @error('shortstory') + + {{ $message }} + + @enderror +
+
+ + + + @error('longstory') + + {{ $message }} + + @enderror + +
+ +
+
+ + + +@endsection \ No newline at end of file diff --git a/resources/views/admin/news/edit.blade.php b/resources/views/admin/news/edit.blade.php new file mode 100644 index 00000000..0a338edf --- /dev/null +++ b/resources/views/admin/news/edit.blade.php @@ -0,0 +1,126 @@ +@extends('layouts.admin') + +@section('title') + TITLE +@endsection + +@section('content') + @section('navigation') +
+ @method('DELETE') + @csrf + + +
+ @endsection + +

Update newspost "{{ $post->title }}"

+ +
+
+ '{{ $post->title }}' news post image +
+ +
+
+ @method('PATCH') + @csrf + +
+ + +
+ + + @error('user_id') + + {{ $message }} + + @enderror +
+
+ +
+ + +
+
+ + Current image ID: {{ $post->image_id }} +
+ +
+ + + +
+
+
+ +
+ + +
+ + + @error('title') + + {{ $message }} + + @enderror +
+
+ +
+ + +
+ + + @error('category_id') + + {{ $message }} + + @enderror +
+
+ +
+ + +
+ + + @error('shortstory') + + {{ $message }} + + @enderror +
+
+ + + + @error('longstory') + + {{ $message }} + + @enderror + +
+ +
+
+
+ + + +
+@endsection \ No newline at end of file diff --git a/resources/views/admin/news/index.blade.php b/resources/views/admin/news/index.blade.php new file mode 100644 index 00000000..febf92f6 --- /dev/null +++ b/resources/views/admin/news/index.blade.php @@ -0,0 +1,42 @@ +@extends('layouts.admin') + +@section('title') + TITLE +@endsection + +@section('content') +

News

+ + + + + + + + + + + + + @foreach ($newsPosts as $news) + + + + + + + + + + @endforeach +
News IDTitleShortstoryCategoryAuthorPostedActions
{{ $news->id }}{{ $news->title }}{{ $news->shortstory }}{{ $news->category->category }}{{ $news->user->name }}{{ \Carbon\Carbon::parse($news->created_at)->format('d. M Y H:i') }} + Show + Edit +
+ @method('DELETE') + @csrf + + +
+
+@endsection \ No newline at end of file diff --git a/resources/views/admin/news/show.blade.php b/resources/views/admin/news/show.blade.php new file mode 100644 index 00000000..cd83b7c9 --- /dev/null +++ b/resources/views/admin/news/show.blade.php @@ -0,0 +1,25 @@ +@extends('layouts.admin') + +@section('title') + TITLE +@endsection + +@section('content') + @section('navigation') +
+ @method('DELETE') + @csrf + + +
+ @endsection + +
+
+ '{{ $post->title }}' news post image +
+

{{ $post->title }}

+

{{ $post->shortstory }}

+ {!! $post->longstory !!} +
+@endsection \ No newline at end of file diff --git a/resources/views/admin/rank/index.blade.php b/resources/views/admin/rank/index.blade.php new file mode 100644 index 00000000..aa6d9f9e --- /dev/null +++ b/resources/views/admin/rank/index.blade.php @@ -0,0 +1,24 @@ +@extends('layouts.admin') + +@section('title') + TITLE +@endsection + +@section('content') +

Ranks and permissions

+ + + + + + + + @foreach ($roles as $role) + + + + + @endforeach +
IDRankPermissions
{{ $role->id }}{{ $role->name}}{{ $role->}} +
+@endsection \ No newline at end of file diff --git a/resources/views/admin/user/edit.blade.php b/resources/views/admin/user/edit.blade.php new file mode 100644 index 00000000..549db6c0 --- /dev/null +++ b/resources/views/admin/user/edit.blade.php @@ -0,0 +1,115 @@ +@extends('layouts.admin') + +@section('title') + TITLE +@endsection + +@section('content') + @section('navigation') + + @endsection + +
+
+ @if ($user->icon_id)Profile icon@endif +

{{ $user->name }}

+

@role('admin') [Admin] @endrole

+
+ +
+ @method('PATCH') + @csrf + +
+ + +
+ + + @error('name') + + {{ $message }} + + @enderror +
+
+ +
+ + +
+ + + @error('email') + + {{ $message }} + + @enderror +
+
+ +
+ + +
+ + + @error('private') + + {{ $message }} + + @enderror +
+
+ +
+ + +
+ + Type in the ID of an icon you wish to display as the profile icon. Search icons here + + @error('email') + + {{ $message }} + + @enderror +
+
+ + @if (count($user->member) > 0) +
Transfer ownership of OSRS accounts:
+ + @foreach ($user->member as $accountNumber => $account) +
+ + +
+ + + + + @error('account[{{ $account->id }}]') + + {{ $message }} + + @enderror +
+
+ + @php $accountNumber++ @endphp + @endforeach + @endif + +
+ +
+
+
+@endsection \ No newline at end of file diff --git a/resources/views/admin/user/index.blade.php b/resources/views/admin/user/index.blade.php new file mode 100644 index 00000000..e543f113 --- /dev/null +++ b/resources/views/admin/user/index.blade.php @@ -0,0 +1,63 @@ +@extends('layouts.admin') + +@section('title') + TITLE +@endsection + +@section('content') +
+
+

Search for users

+
+ +
+ @csrf + +
+ +
+ + + @error('search') + + {{ $message }} + + @enderror +
+ + +
+
+ + @if ($query)

Search results for "{{ $query }}"

@endif + + + + + + + + + + + @foreach ($users as $user) + + + + + + + + + + @endforeach +
User IDUsernameEmailPrivateLinked OSRS accountRegisteredActions
{{ $user->id }}@if ($user->icon_id)Profile icon@endif {{ $user->name }}{{ $user->email }}{{ ($user->private === 0 ? 'False' : 'True') }} + @foreach ($user->member as $member) + @if (count($user->member) > 1) +

{{ $member->id }} - {{ $member->username }}

+ @else + {{ $member->id }} - {{ $member->username }} + @endif + @endforeach +
{{ \Carbon\Carbon::parse($user->created_at)->format('d. M Y H:i') }}ShowEditBan?
+@endsection \ No newline at end of file diff --git a/resources/views/admin/user/show.blade.php b/resources/views/admin/user/show.blade.php new file mode 100644 index 00000000..edafc75a --- /dev/null +++ b/resources/views/admin/user/show.blade.php @@ -0,0 +1,70 @@ +@extends('layouts.admin') + +@section('title') + TITLE +@endsection + +@section('content') + @section('navigation') + Edit + + + @endsection + +
+
+
+ @if ($user->icon_id) +
+ Profile icon +
+ @endif +

{{ $user->name }}

+

rank

+ +

About

+

Email: {{ $user->email }}

+

Icon ID: {{ (is_null($user->icon_id)) ? 'None' : $user->icon_id }}

+

Private: {{ ($user->private === 0 ? 'False' : 'True') }}

+

User ID: {{ $user->id }}

+

Joined: {{ \Carbon\Carbon::parse($user->created_at)->format('d. M Y H:i') }}

+

Last updated: {{ \Carbon\Carbon::parse($user->updated_at)->format('d. M Y H:i') }}

+
+
+ +
+
+

OSRS accounts

+ + @foreach ($accounts as $amount => $account) +
+
+
+

@if (count($user->member) > 1) {{ ++$amount }} - @endif{{ $account->username }}

+

+ Rank: {{ number_format($account->rank) }} | + Level: {{ $account->level }} | + Total XP: {{ number_format($account->xp) }} +

+
+
+ +
+
+ @foreach (Helper::accountStats($account->id) as $skillId => $skill) + + {{ ucfirst(Helper::listSkills()[$skillId]) }} skill icon + + {{ json_decode($skill[0]->level, true) }} + + @endforeach +
+
+
+ @endforeach +
+
+
+@endsection \ No newline at end of file diff --git a/resources/views/auth/login.blade.php b/resources/views/auth/login.blade.php index c12b97e5..995e0d53 100644 --- a/resources/views/auth/login.blade.php +++ b/resources/views/auth/login.blade.php @@ -1,73 +1,67 @@ -@extends('layouts.app') +@extends('layouts.layout') + +@section('title') + {{ __('title.login') }} +@endsection @section('content') -
-
-
-
-
{{ __('Login') }}
+

{{ __('title.login') }}

-
-
- @csrf + + @csrf -
- +
+ -
- +
+ - @error('email') - - {{ $message }} - - @enderror -
-
+ @error('email') + + {{ $message }} + + @enderror +
+
-
- +
+ -
- +
+ - @error('password') - - {{ $message }} - - @enderror -
-
+ @error('password') + + {{ $message }} + + @enderror +
+
-
-
-
- +
+
+
+ - -
-
-
+ +
+
+
-
-
- +
+
+ - @if (Route::has('password.request')) - - {{ __('Forgot Your Password?') }} - - @endif -
-
- -
+ @if (Route::has('password.request')) + + {{ __('Forgot Your Password?') }} + + @endif
-
-
-@endsection + +@endsection \ No newline at end of file diff --git a/resources/views/auth/register.blade.php b/resources/views/auth/register.blade.php index d236a48e..7060a555 100644 --- a/resources/views/auth/register.blade.php +++ b/resources/views/auth/register.blade.php @@ -1,77 +1,71 @@ -@extends('layouts.app') +@extends('layouts.layout') + +@section('title') + {{ __('title.register') }} +@endsection @section('content') -
-
-
-
-
{{ __('Register') }}
+

{{ __('title.register') }}

-
-
- @csrf + + @csrf -
- +
+ -
- +
+ - @error('name') - - {{ $message }} - - @enderror -
-
+ @error('name') + + {{ $message }} + + @enderror +
+
-
- +
+ -
- +
+ - @error('email') - - {{ $message }} - - @enderror -
-
+ @error('email') + + {{ $message }} + + @enderror +
+
-
- +
+ -
- +
+ - @error('password') - - {{ $message }} - - @enderror -
-
+ @error('password') + + {{ $message }} + + @enderror +
+
-
- +
+ -
- -
-
+
+ +
+
-
-
- -
-
-
-
+
+
+
-
-
-@endsection + +@endsection \ No newline at end of file diff --git a/resources/views/hiscore.blade.php b/resources/views/hiscore.blade.php new file mode 100644 index 00000000..0be21364 --- /dev/null +++ b/resources/views/hiscore.blade.php @@ -0,0 +1,64 @@ +@extends('layouts.layout') + +@section('title') + {{ ucfirst($hiscore) }} {{ __('title.hiscore') }} +@endsection + +@section('content') + + +
+
+ + @foreach ($hiscoreListTop as $skill) + {{ ucfirst($skill) }} skill icon + @endforeach + +
+ {{ ucfirst($hiscore) }} skill icon

{{ ucfirst($hiscore) }}

+ @foreach ($hiscoreList as $skill) + {{ ucfirst($skill) }} skill icon

{{ ucfirst($skill) }}

+ @endforeach +
+ + @foreach ($hiscoreListBottom as $skill) + {{ ucfirst($skill) }} skill icon + @endforeach + +
+
+ + @if ($accountCount > 0) +
+ + {{ ucfirst($hiscore) }} skill icon + +
+ + @if ($hiscoreType == "skill") + + @elseif ($hiscoreType == "boss") + + @endif + @else +
+ Sad face +

No accounts, no hiscores...

+

Link an account here!

+
+ @endif +@endsection \ No newline at end of file diff --git a/resources/views/home.blade.php b/resources/views/home.blade.php index 05dfca92..ab8feb03 100644 --- a/resources/views/home.blade.php +++ b/resources/views/home.blade.php @@ -1,23 +1,49 @@ -@extends('layouts.app') +@extends('layouts.layout') + +@section('title') + {{ Auth::user()->name }} +@endsection @section('content') -
-
-
-
-
Dashboard
+
+
+
+ @if ($user->icon_id) + Profile icon +
+ Edit profile + @else + Profile icon +
+ Get your own profile icon here! + @endif +
+
-
- @if (session('status')) - - @endif +
+

Welcome, {{ Auth::user()->name }}

- You are logged in! -
-
-
-
-
-@endsection +

RuneScape account: {{ $user->account[0]->username }}

+

Joined: {{ \Carbon\Carbon::parse($user->created_at)->format('d. M Y') }}

+
+ +
+ @if ($user->private === 0) + Current status: +
+ Friend icon + Not private + @else + Current status: +
+ Ignore icon + Private + @endif +
+
+ + @foreach ($user->account as $account) +
+ + @endforeach +@endsection \ No newline at end of file diff --git a/resources/views/index.blade.php b/resources/views/index.blade.php new file mode 100644 index 00000000..dee9c650 --- /dev/null +++ b/resources/views/index.blade.php @@ -0,0 +1,56 @@ +@extends('layouts.layout') + +@section('title') + {{ __('title.update-log') }} +@endsection + +@section('content') +

Latest news and updates

+ + @foreach ($recentPosts as $post) +
+ +
+
+
+ + '{{ $post->title }}' news post image + +
+
+
+ +
+ {{ $post->user->name }} | {{ $post->category->category }} +
+
+

{{ $post->shortstory }}

+

Read more

+
+
+
+
+ {{ \Carbon\Carbon::parse($post->created_at)->format('M') }} + {{ \Carbon\Carbon::parse($post->created_at)->format('d') }} +
+
+
+
+ @endforeach + +
+
+ +
+
+

Welcome to {{ config('app.name', 'RuneManager') }}

+

"Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.

+
+ + +
+@endsection \ No newline at end of file diff --git a/resources/views/layouts/admin.blade.php b/resources/views/layouts/admin.blade.php new file mode 100644 index 00000000..eb504e6c --- /dev/null +++ b/resources/views/layouts/admin.blade.php @@ -0,0 +1,160 @@ + + + + + + + + + + {{ config('app.name', 'RuneManager') }} | @yield('title') + + + + + + + + + + + +
+
+ + +
+ + +
+ @if ($errors->any()) +
+ @foreach ($errors->all() as $errorMessage) + Error! {{ $errorMessage }}
+ @endforeach +
+ @endif + + @if (Session::has('message')) +
+ Success! {{ Session::get('message') }}
+
+ @endif + + @yield('content') +
+
+
+
+ + + + + + + + \ No newline at end of file diff --git a/resources/views/layouts/app.blade.php b/resources/views/layouts/layout.blade.php similarity index 50% rename from resources/views/layouts/app.blade.php rename to resources/views/layouts/layout.blade.php index 7bcfd316..a13f8982 100644 --- a/resources/views/layouts/app.blade.php +++ b/resources/views/layouts/layout.blade.php @@ -1,4 +1,4 @@ - + @@ -7,24 +7,20 @@ - {{ config('app.name', 'Laravel') }} - - - - - - - + {{ config('app.name', 'RuneManager') }} | @yield('title') + + + + + + - + \ No newline at end of file diff --git a/resources/views/news/index.blade.php b/resources/views/news/index.blade.php new file mode 100644 index 00000000..bccc3858 --- /dev/null +++ b/resources/views/news/index.blade.php @@ -0,0 +1,31 @@ +@extends('layouts.layout') + +@section('title') + {{ __('title.news') }} +@endsection + +@section('content') +

{{ __('title.news') }}

+ + @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

+
+ @endforelse +@endsection \ No newline at end of file diff --git a/resources/views/news/show.blade.php b/resources/views/news/show.blade.php new file mode 100644 index 00000000..985b0c3f --- /dev/null +++ b/resources/views/news/show.blade.php @@ -0,0 +1,14 @@ +@extends('layouts.layout') + +@section('title') + "{{ $post->title }}" +@endsection + +@section('content') +
+ '{{ $post->title }}' news post image +
+

{{ $post->title }}

+

{{ $post->shortstory }}

+ {!! $post->longstory !!} +@endsection \ No newline at end of file diff --git a/resources/views/task.blade.php b/resources/views/task.blade.php new file mode 100644 index 00000000..e5049885 --- /dev/null +++ b/resources/views/task.blade.php @@ -0,0 +1,128 @@ +@extends('layouts.layout') + +@section('title') + {{ __('title.task') }} +@endsection + +@section('content') +

{{ __('title.task') }}

+ +
+

Easy ({{ $easyProgress }}%)

+

Medium ({{ $mediumProgress }}%)

+

Hard ({{ $hardProgress }}%)

+

Elite ({{ $eliteProgress }}%)

+
+ +
+
+
+
+
+
+
+
+
+
+
+
+
+
+ +

Current tasks

+ + @if (count($currentAccountTasks) > 0) +
+ @foreach ($currentAccountTasks as $task) + @switch($task->task->difficulty) + @case('easy') +
+ @break + @case('medium') +
+ @break + @case('hard') +
+ @break + @case('elite') +
+ @break + @default +
+ @endswitch +
+ Task '{{ $task->task->task }}' icon +
{{ $task->task->task }}
+

{{ Helper::itemData($task->task->icon, 'examine') }}

+ +
+ @method('PATCH') + @csrf + + + + +
+
+ +
+ @endforeach +
+ @else +
+

Currently no tasks to do!

+ Sad face +
+ @endif + + @if (count($currentAccountTasks) >= 3) + + @else +
+
+ @csrf + + +
+
+ @endif + + @if (count($completedAccountTasks) > 0) +

Completed tasks

+ + + + + + + + + @foreach ($completedAccountTasks as $task) + + @switch($task->task->difficulty) + @case('easy') + + + + + + @endforeach +
TaskRewardCompleted
+ @break + @case('medium') + + @break + @case('hard') + + @break + @case('elite') + + @break + @default + + @endswitch + Task '{{ $task->task->task }}' icon{{ $task->task->task }}{{ $task->task->reward }}{{ \Carbon\Carbon::parse($task->updated_at)->format('d. M Y H:i') }}
+ @endif +@endsection \ No newline at end of file diff --git a/resources/views/update-log.blade.php b/resources/views/update-log.blade.php new file mode 100644 index 00000000..6869a3d5 --- /dev/null +++ b/resources/views/update-log.blade.php @@ -0,0 +1,13 @@ +@extends('layouts.layout') + +@section('title') + {{ __('title.update-log') }} +@endsection + +@section('content') +

{{ __('title.update-log') }}

+ + @foreach ($updates as $log) +

{{ $log->username }} {{ \Carbon\Carbon::parse($log->updated_at)->format('d. M Y H:i') }}

+ @endforeach +@endsection \ No newline at end of file diff --git a/resources/views/user/edit.blade.php b/resources/views/user/edit.blade.php new file mode 100644 index 00000000..606059a2 --- /dev/null +++ b/resources/views/user/edit.blade.php @@ -0,0 +1,148 @@ +@extends('layouts.layout') + +@section('title') + {{ __('title.edit-member') }}: {{ $user->name }} +@endsection + +@section('content') + + +

{{ __('title.edit-member') }}: {{ $user->name }}

+ +
+ @method('PATCH') + @csrf + +
+ + +
+ + Your profile name displayed on this site. Not OSRS account. + + @error('name') + + {{ $message }} + + @enderror +
+
+ +
+ + +
+ + + @error('email') + + {{ $message }} + + @enderror +
+
+ +
+ + +
+
+
+ + + +
+ + @error('private') + + {{ $message }} + + @enderror +
+
+
+ + @if ($user->icon_id != null) +
+ + +
+ +
+
+ @endif + +
+ + +
+
+ +
+ + + Type in the ID of an icon you wish to display as your profile icon. Search icons here + + @error('icon_id') + + {{ $message }} + + @enderror +
+
+ +
+ + +
+ @foreach ($randomIcons as $icon) + + @endforeach + + @error('icon_id') + + {{ $message }} + + @enderror +
+
+ +
+
+ +
+
+
+@endsection \ No newline at end of file diff --git a/resources/views/welcome.blade.php b/resources/views/welcome.blade.php deleted file mode 100644 index 3fb48cc0..00000000 --- a/resources/views/welcome.blade.php +++ /dev/null @@ -1,100 +0,0 @@ - - - - - - - Laravel - - - - - - - - -
- @if (Route::has('login')) - - @endif - -
-
- Laravel -
- - -
-
- - diff --git a/routes/api.php b/routes/api.php index 73d0f116..3967dcc4 100644 --- a/routes/api.php +++ b/routes/api.php @@ -18,16 +18,21 @@ return $request->user(); }); -Route::prefix('/boss')->group(function () { - // Route::middleware('auth:api')->group(function () { - Route::get('/', 'CollectionController@index'); - Route::get('/{boss}', 'CollectionController@show'); - Route::put('/{boss}', 'BossController@update'); - // }); +Route::prefix('/hiscore')->group(function () { + Route::get('/skill/{skill}', 'Api\HiscoreController@skill')->name('show-skill-hiscore'); + Route::get('/boss/{skill}', 'Api\HiscoreController@boss')->name('show-boss-hiscore'); +}); + +Route::prefix('/account')->group(function () { + Route::get('/{account}', 'Api\AccountController@show')->name('show-account'); + Route::post('/{account}', 'Api\AccountController@store')->name('authenticate-account'); + + Route::get('/{accountUsername}/collection/{collectionName}', 'Api\AccountCollectionController@show')->name('show-account-collection'); + Route::put('/{accountUsername}/collection/{collectionName}', 'Api\AccountCollectionController@update')->name('update-account-collection'); }); Route::prefix('/collection')->group(function () { // Route::middleware('auth:api')->group(function () { - Route::get('/', 'CollectionController@bossList'); + Route::get('/{collectionType}', 'CollectionController@list'); // }); }); \ No newline at end of file diff --git a/routes/web.php b/routes/web.php index 0c16db42..a873e3b7 100644 --- a/routes/web.php +++ b/routes/web.php @@ -13,10 +13,59 @@ | */ -Route::get('/', function () { - return view('welcome'); -}); +/*==========Pages Controller=============*/ +Route::get('/', 'PageController@index')->name('index'); +Route::get('/update-log', 'PageController@updateLog')->name('update-log'); +Route::get('/home', 'HomeController@index')->name('home'); +Route::get('/hiscore/{hiscore}/{skill}', 'PageController@hiscore')->name('show-hiscore'); -Auth::routes(); +/*==========Member Controller=============*/ +Route::get('/account', 'AccountController@index')->name('account'); +Route::post('/account', 'AccountController@search')->name('search-account'); +Route::get('/account/create', 'AccountController@create')->name('create-account'); +Route::post('/account/create', 'AccountController@createAccountAuthStatus')->name('store-account'); +Route::get('/account/{id}', 'AccountController@show')->name('show-account'); -Route::get('/home', 'HomeController@index')->name('home'); +/*==========User Controller=============*/ +Route::get('/user/edit', 'UserController@edit')->name('edit-user'); +Route::patch('/user/edit', 'UserController@update')->name('update-user'); + +/*==========Tasks Controller=============*/ +Route::get('/task', 'TasksController@index')->name('task'); +Route::post('/task', 'TasksController@store')->name('store-task'); +Route::patch('/task', 'TasksController@update')->name('update-task'); + +/*==========News Controller=============*/ +Route::get('/news', 'NewsController@index')->name('news'); +Route::get('/news/{id}', 'NewsController@show')->name('show-newspost'); + +/*==========Admin Controller=============*/ + Route::group(['middleware' => ['permission:access admin']], function () { + Route::get('/admin', 'AdminController@index')->name('admin-index'); + /*==========News Controller=============*/ + Route::get('/admin/news', 'AdminNewsController@index')->name('admin-news'); + Route::get('/admin/news/create', 'AdminNewsController@create')->name('admin-create-newspost'); + Route::post('/admin/news/create', 'AdminNewsController@store')->name('admin-store-newspost'); + Route::get('/admin/news/{id}/show', 'AdminNewsController@show')->name('admin-show-newspost'); + Route::get('/admin/news/{id}/edit', 'AdminNewsController@edit')->name('admin-edit-newspost'); + Route::patch('/admin/news/{id}/edit', 'AdminNewsController@update')->name('admin-update-newspost'); + Route::delete('/admin/news/{id}/delete', 'AdminNewsController@destroy')->name('admin-delete-newspost'); + //Route::resource('/admin/news', 'AdminNewsController'); + /*==========User Controller=============*/ + Route::get('/admin/user', 'AdminUserController@index')->name('admin-user'); + Route::post('/admin/user', 'AdminUserController@search')->name('admin-search-user'); + Route::get('/admin/user/{id}/show', 'AdminUserController@show')->name('admin-show-user'); + Route::get('/admin/user/{id}/edit', 'AdminUserController@edit')->name('admin-edit-user'); + Route::patch('/admin/user/{id}/edit', 'AdminUserController@update')->name('admin-update-user'); + /*==========Member Controller=============*/ + Route::get('/admin/member', 'AdminAccountController@index')->name('admin-member'); + Route::post('/admin/member', 'AdminAccountController@search')->name('admin-search-member'); + Route::get('/admin/member/create', 'AdminAccountController@create')->name('admin-create-member'); + Route::post('/admin/member/create', 'AdminAccountController@store')->name('admin-store-member'); + Route::get('/admin/member/{id}/show', 'AdminAccountController@show')->name('admin-show-member'); + Route::patch('/admin/member/{id}/show', 'AdminAccountController@update')->name('admin-update-member'); + /*==========Rank Controller=============*/ + Route::get('/admin/rank', 'AdminRoleController@index')->name('admin-rank'); + }); + +Auth::routes(); \ No newline at end of file