Data in depth
Part 9 of the Laravel course. Collections, Carbon dates, pagination, file uploads, query scopes, accessors and casts, and transactions with row locks.
The cards below open the lessons of the part, and the tree lists them in the reading order of the whole
course. The previous and the next page at the bottom move through that order.
9.1
Collections
Shape arrays with Laravel collections: wrap anything, map and filter, group by key and stay lazy on huge sets.
Open
9.2
Carbon dates
Work with dates through Carbon: read now, parse input, add days and diff, then format output.
Open
9.3
Pagination
Split long lists with Laravel pagination: paginate queries, render links, use simple mode and paginate APIs.
Open
9.4
File uploads
Accept file uploads in Laravel: validate files, store them on a disk, link the public disk and serve files back.
Open
9.5
Eloquent advanced
Level up Eloquent models: add query scopes, computed accessors, attribute casts and touch parent timestamps.
Open
9.6
Transactions and locks
Keep writes safe with database transactions: wrap work, control commits by hand, lock rows and retry deadlocks.
Open