I update 2 data, the first data is in the normal table, the second data uses EAV, therefore I have to use where to update the data that has the input ID
What im doing wrong..im getting this error..
this my controller
this is normal table
 $vendor = Vendor::find($request->id);
        $vendor->is_active = '0';
        $vendor->name = $request->name;
        $vendor->address = $request->address;
        $vendor->save();
this is EAV Table
        $values=array('detail'=> $request->detail,
                      'join_at'=>  Carbon::now(),
                    );
        VendorDetail::whereIn('vendor_id',$request->id)->update($values);
via Chebli Mohamed
 
Aucun commentaire:
Enregistrer un commentaire