bonzai left a reply on Mccool Presenter In Controller Not Working In Laravel 5?
You need to decorate it youself, because the package will only automatically decorate objects: - bound to views, - within paginator instances, - within collection objects
$decorated_model = app('autopresenter')->decorate($plain_model);
bonzai left a reply on Is There A Point To Using Homestead When Running Ubuntu 14 ?
Tip: there is a nice tool to create your "own" VM, if you don't want to use Homestead or Vaprobash – https://puphpet.com/.
/// To update a model, you may retrieve it, change an attribute, and use the save method: $user = User::find(1); $user->email = 'email@example.com'; $user->save();
"If I had a dime for every time I've seen someone use FLOAT to store currency, I'd have $999.997634" -- Bill Karwin
Nah, don't use
FLOAT to store monetary values. Try to change it to
DECIMAL(8,2) or better – keep values as cents (
INT field) and use:
What's the type of the price field? Is it