DBTool->queryBySql($sql); return $res; } //新增基本房型 public function AddBaseroom($name,$user_id,$area_id) { $sql="insert into base_resource (res_id,res_name,res_type_id,create_user_id,create_time,area_id) VALUES ((select max(b.res_id)+1 from base_resource as b),'$name','26','$user_id',NOW(),'$area_id')"; writeLog(__FUNCTION__ . " sql= " . $sql); $res = $this->DBTool->execSql($sql); return $res; } //新增酒店 public function AddHotel($name, $area_id, $address, $room_type,$purchase_name,$user_id,$star_level) { $sql="insert into opera_hotel (hotel_name,area_id,hotel_address,room_type_all,room_type_sale,purchase_name,create_time,create_user_id,update_time,update_user_id,star_level) VALUES ('$name','$area_id','$address','$room_type','$room_type','$purchase_name',NOW(),'$user_id',NOW(),'$user_id','$star_level')"; writeLog(__FUNCTION__ . " sql= " . $sql); $res = $this->DBTool->execSql($sql); return $res; } }