Exemplo n.º 1
0
     if (isset($_GET['room_devices_port'])) {
         $where_values['room_devices_port'] = $_GET['room_devices_port'];
     }
     if (isset($_GET['new_rooms_id'])) {
         $new_values['rooms_id'] = $_GET['new_rooms_id'];
     }
     if (isset($_GET['new_room_devices_name'])) {
         $new_values['room_devices_name'] = $_GET['new_room_devices_name'];
     }
     if (isset($_GET['new_room_devices_port'])) {
         $new_values['room_devices_port'] = $_GET['new_room_devices_port'];
     }
     if (isset($_GET['new_room_devices_status'])) {
         $new_values['room_devices_status'] = $_GET['new_room_devices_status'];
     }
     echo $operation->upd_rd(array($new_values, $where_values));
     break;
 case "add_rs":
     $values = array();
     if (isset($_GET['rooms_id'])) {
         $values['rooms_id'] = $_GET['rooms_id'];
     }
     if (isset($_GET['room_schedules_day'])) {
         $values['room_schedules_day'] = ucwords($_GET['room_schedules_day']);
     }
     if (isset($_GET['room_schedules_date'])) {
         $values['room_schedules_date'] = date("Y-m-d", strtotime($_GET['room_schedules_date']));
     }
     if (isset($_GET['room_schedules_time'])) {
         $values['room_schedules_time'] = intval($_GET['room_schedules_time']);
     }