Writing A text for my own Laravel skill-building
I started with the text below from the github squash merge, but I wanted to refine the text for my own Laravel skill-building, so ideas for writing-TODOs are:
- Look through paper notes and index cards and SketchNotes and printed out code and bullet journal
- Look through my 7 half written blog-posts from August
- Look through my 6 half written blog-posts from July
- Look through my 3 half written blog-posts from June
- Look through commits on github
- Look through comments from Queen @raae on github
- Look through comments from Queen @raae on Slack
- Look through tweets from Queen @raae
- Look through Queen @raae ‘s Bluesky
- Look through tweets from me
- Look through my Bluesky
- Write ideas
Output
- Make some sketchNotes
- Collect Tiny-Tasks for Practice and Repetition
- Collect and organize index cards in The Yellow Chocolate Factory Inventor Book
- Shoot one youtube short
- Write One blog-post
Summing up booking on Whee 🚴♀️ #136
-
notes commit
-
Created a new view ‘booking’ and a new route ‘/booking’ commit
-
added an array of dummy data to routes commit
// Practice Rou::ge();
// Rou::ge('/ice', fun () {
// re view('ice', [
// '🤡' => ['time' => '26. august 2025', 'location' => 'Sandaker']
// ]);
// });
Route::get('/practice', function () {
return view('practice', [
'dummyAirtableArray' => ['time' => '26. august 2025', 'location' => 'Sandaker']
]);
});
- created a dynamic route and moved the booking route to the bottom of web.php and display the dummy data in ‘/booking/{id}’ commit
Comment from Queen @raae on github
Veldig bra med booking side. Trenger kun booking, ikke booking med id da vi kun skal vise frem kundens siste booking.
Jeg foreslår du hardkoder en booking i en funksjon som heter getNextBooking in AirtableService filen. Så kaller du på den i web.php og sender til viewet booking. Det vil si at det ikke trengs noen command eller ny service.
Senere kan du se på det jeg gjør med å vise frem kundens sykkel, og gjøre det likt.
-
Step 6 starting on the api call with a simple api about conferences that has ‘time’ and ‘location’ in the data commit
-
php artisan make:command ImportConferences commit
-
‘cfps:import’ commit
-
php artisan cfps:import gives me Target class [App\Console\Commands\CallingAllPapers] does not exist commit
-
🥳 Iiiiit woooorks! 🥳🏴☠️ commit
-
Created a class that says for a conference with a unique id, the ‘cfp_uri’ import it and dd() the ‘cfp_uri’ commit
-
Deleted my first try on the CallingAllPapers class commit
-
‘dateEventStart’ and ‘locatio’ from the api commit
-
found location in the conference api commit
-
Can I use CallingAllPapers in routes > web.php? commit
-
Now GetNextBooking works in the router 🥳 commit
// web.php
class GetNextBooking
{
public static function all(): array
{
return ['time' => '26. august 2025', 'location' => 'Sandaker'];
}
}
Route::get('/bokn', function () {
return view('bokn', ['booking' => GetNextBooking::all()]);
});
-
I didn’t get around to passing this on to web.php commit
-
Internal Server Error Call to a member function getNextBooking() on string commit
-
iiiiit wooooorks! 🥳🏴☠️ commit
$bookings = AirtableService::getNextBooking();
// web.php
Route::get('/book', function () {
$bookings = AirtableService::getNextBooking();
return view('bokn', ['booking' => $bookings]);
});
// app/Services/AirtableService.php
public static function getNextBooking ()
{
return ['time' => '26. august 2025', 'location' => 'Sandaker'];
}
Comment from Queen @raae on github
Veldig bra, nå vis frem kun én booking i dashboard. Altså hardkode en booking, ikke en liste av bookings og send den inn til view dashboard og så vis den frem der. Bonus, lenke til den bookingens side på booking/{id} som allerede fungerer.
Bra gjort med AirtableService::getNextBooking
.
For å fullføre:
- Rydd opp, dvs. fjerne
booking/{id}
ogbokn/{id}
- Flytt
/book
under auth på samme måte som/dashboard
sånn at kun innloggede får tilgang til å endre - Flytte booking info i dashboardet under account info, trenger ikke style
Comment from Queen @raae on github
Slett command og call all papers service så er den good to go!
- hardcoded ONE 🚴♀️ booking, commit in web.php and sendt it in to view > dashboard.blade.php and showed it there
Bonus, link to the change 🚴♀️ bookings page at /book which already works
- hardkodet en booking, i web.php og sendte den inn til view dashboard og så vis den frem der.
Bonus, lenke til den bookingens side på /book som allerede fungerer. @olavea olavea force-pushed the booking branch from 224bd28 to 9cb75bf 2 days ago
- Moved down service (and added som tailwind styling for fun 🥳) commit
Add code
-
So, we don’t need the hardcoded service times in web.php anymore commit
-
Moved /book under auth so that only logged in users get access and can change service times commit
// web.php
Route::middleware('auth')->group(function () {
Route::get('/book', function () {
$bookings = AirtableService::getNextBooking();
return view('bokn', ['booking' => $bookings]);
});
});
<div class="mb-6">
<div class="space-y-2">
// why " and not '?
{{ $booking["time"] }}
på {{ $booking["location"] }}
// what is | ? just a | between
<a href="/booking" class="text-sm text-gray-600">
Endre tid
</a>
|
<a href="/booking" class="text-sm text-gray-600">
Kanseller
</a>
</div>
// web.php
// Protected routes
Route::middleware('auth')->group(function () {
Route::get('/min-side', function () {
$booking = AirtableService::getNextBooking();
return view('dashboard', ['booking' => $booking]);
})->name('dashboard');
Route::get('/booking', function () {
$booking = AirtableService::getNextBooking();
return view('booking', ['booking' => $booking]);
})->name('booking');
});
- Deleted command og callAllPapers service commit
Co-authored-by: raae queen@raae.codes