$customerhistory = Customerhistory::where('customer_id', 1)
->select('freetext') // also laravel include crated_at and updated_at timestamps as default
->first();
$date = \Carbon\Carbon::createFromFormat('Y-m-d H:i:s', $customerhistory->created_at)->format('Y-m-d');
Sign in to participate in this thread!
The Laravel portal for problem solving, knowledge sharing and community building.
The community