- Bug: data serialisaion on laravel 7.x (Coverage.php)
- solr path without solr string - composer updates
This commit is contained in:
parent
b335bd7e9c
commit
9601389d83
4 changed files with 20 additions and 10 deletions
|
@ -3,6 +3,7 @@ namespace App\Models;
|
|||
|
||||
use App\Models\Dataset;
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
use DateTimeInterface;
|
||||
|
||||
class Coverage extends Model
|
||||
{
|
||||
|
@ -47,6 +48,16 @@ class Coverage extends Model
|
|||
{
|
||||
$this->attributes['time_max'] = empty($date) ? null : \Illuminate\Support\Carbon::createFromFormat('Y-m-d H:i:s', $date);
|
||||
}
|
||||
/**
|
||||
* Prepare a date for array / JSON serialization.
|
||||
*
|
||||
* @param \DateTimeInterface $date
|
||||
* @return string
|
||||
*/
|
||||
protected function serializeDate(DateTimeInterface $date)
|
||||
{
|
||||
return $date->format('Y-m-d H:i:s');
|
||||
}
|
||||
|
||||
/**
|
||||
* relationship to dataset
|
||||
|
|
Loading…
Add table
editor.link_modal.header
Reference in a new issue