Support the ongoing development of Laravel.io →

ahmd8

Joined 15 Feb 2014

Statistics

Threads 1
Replies 1
Solutions 0
Articles 0
posted 10 years ago

How to add user id as a default value when inserting new records

I am building app for enterprise their are three tables: users table (belong to company) companies...

0 Likes
5 Replies
replied 10 years ago

How to add user id as a default value when inserting new records

here is the answer public function save(array $options = array()) { if( ! $this->company_id)...

0 Likes

We'd like to thank these amazing companies for supporting us

Your logo here?

Laravel.io

The Laravel portal for problem solving, knowledge sharing and community building.

© 2024 Laravel.io - All rights reserved.