in your database is active a boolean, tinyint(1) or a string?
what do you see in your database for this column?
Also a similar issue like this was posted here few months back.. i wish i could remember what the resolution was
I have tinyint(1) but if to change for int or varchar, the result is identical. However such request works always correctly: \DB:: table ('price_lists')->where ('category', $section)->where ('active', '=', 1)->get ();
can you maybe try casting it as a boolean in your MODEL.. and see if that fixes it? worth a shot..
shez1983 said:
can you maybe try casting it as a boolean in your MODEL.. and see if that fixes it? worth a shot..
If you mean the migration, the changes do not lead to error correction. The model itself is only indicated field: protected $ table = 'price_lists';
protected $ fillable = ['name', 'type', 'category', 'active'];
protected $ dates = ['created_at', 'updated_at'];
Sign in to participate in this thread!
The Laravel portal for problem solving, knowledge sharing and community building.
The community