Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

$date-mutators support #31

Open
gineign opened this issue Apr 8, 2020 · 0 comments
Open

$date-mutators support #31

gineign opened this issue Apr 8, 2020 · 0 comments

Comments

@gineign
Copy link

gineign commented Apr 8, 2020

setAttribute to support $dates

        // If an attribute is listed as a "date", we'll convert it from a DateTime
        // instance into a form proper for storage on the database tables using
        // the connection grammar's date format. We will auto set the values.
        elseif ($value && $this->isDateAttribute($key)) {
            $value = $this->fromDateTime($value);
        }

https://laravel.com/docs/7.x/eloquent-mutators#date-mutators

@gineign gineign changed the title setAttribute to support $date $date-mutators support Apr 8, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant