Support the ongoing development of Laravel.io →
Database Eloquent
Last updated 1 year ago.
0

well, you should have a look here: http://laravel.com/docs/eloquent#timestamps and here http://laravel.com/docs/schema

long storry short. -> In your model (Music), add the following somewhere near the top

 public $timestamps = false;

OR in your migration, add

$table->timestamps();

and rerun the migration

Last updated 1 year ago.
0

So did you read the docs? http://laravel.com/docs/eloquent

Once a model is defined, you are ready to start retrieving and creating records in your table. Note that you will need to place updated_at and created_at columns on your table by default. If you do not wish to have these columns automatically maintained, set the $timestamps property on your model to false.

If you want timestamp, just add $table->timestamps(); to your migration.

Last updated 1 year ago.
0

Oh. Now i feel stupid!

Last updated 1 year ago.
0

Sign in to participate in this thread!

Eventy

Your banner here too?

d1p d1p Joined 28 Mar 2014

Moderators

We'd like to thank these amazing companies for supporting us

Your logo here?

Laravel.io

The Laravel portal for problem solving, knowledge sharing and community building.

© 2024 Laravel.io - All rights reserved.