function refreshNotification($pDB) { $response = array('action' => 'refreshNotification', 'message' => 'Làm tươi dữ liệu thành công'); $pOverall_setting = new paloSantoOverall_setting($pDB); $result = $pOverall_setting->getNotification(); // return json if (!$result) { $response['action'] = 'error'; $response['message'] = 'Lỗi: ' . $pOverall_setting->errMsg; } $json = new Services_JSON(); Header('Content-Type: application/json'); return $json->encode($result[0]); }