FEATURE: add bootstrap datepicker. All elements with .date class are now datepicker holders

This commit is contained in:
Michal Kváček
2017-09-25 23:22:25 +02:00
parent 271e7f5170
commit c69bd9bcf7
7 changed files with 19 additions and 5 deletions
+1 -1
View File
@@ -17,7 +17,7 @@ trait Nullable {
* @return null|string
*/
public function nullableDate($date) {
return empty($date) ? null : Carbon::parse($date)->toDateTimeString();
return empty($date) ? null : Carbon::createFromFormat(config('app.date_format'), $date)->toDateTimeString();
}
/**