代码如下:
$supply = new Supply();
$user_id = session(SESSION_USER_ID);
$supply = $supply->where("user_id", $user_id)
->where("goods_id = :id")->bind([ "id"=>$goods_id])
->where("special_type", 1)
->find();
//更新数据
$supply["is_delete"] = 1;
$supply->save();结果就报错:UPDATE `tp_supply` SET `is_delete`=1 WHERE `user_id` = 10021 AND ( goods_id = :id ) AND `special_type` = 1记录都找出来了,还需要bind一次? $supply->bind([ "id"=>$goods_id])->save();各位朋友是否有其他方法? 最佳答案