Answers for "Uncaught TypeError: Argument 1 passed to NotORM_Result::update() php slim"

PHP
0

Uncaught TypeError: Argument 1 passed to NotORM_Result::update() php slim

From index.php pass data(array) to dbhandler.php
//Update Calendar Status by todo_id (index.php)
$app->get('/TodoUpdateCalendarStatus/:todo_id',function($todo_id) use ($app){
    $db =new DbHandler();
    $update_data = array(
        'calendar_status' => 1
    );
    $data = $db->TodoUpdateCalendarStatus($todo_id,$update_data);
    $app->response()->header('Content-Type', 'application/json');
    echo json_encode($data);
});
dbhandler.php
 public function TodoUpdateCalendarStatus($tid,$u_data)
    {
        return $this->db->tbl_todo_master()
        ->where('todo_master_id = ?', $tid)
        ->update($u_data);    
    }
//end
Posted by: Guest on December-23-2020

Code answers related to "Uncaught TypeError: Argument 1 passed to NotORM_Result::update() php slim"

Browse Popular Code Answers by Language