Answer the question
In order to leave comments, you need to log in
How to set custom date to NULL in laravel?
In migration: $table->timestamp('date_of'); // дата выдачи
I tried to set ->nullable() and ->default(NULL)
All the same, it adds the current date with time to the database.
Even changed to string. Maybe in the controller you need to set the date to null when adding an entry to the database?
When adding an order, the date must be empty, because the order has not been issued yet. And when editing, the date of issue is put.
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question