Minor - format code

pull/3174/head
Julio Montoya 6 years ago
parent bd4d935ded
commit 88c447d704
  1. 18
      main/inc/ajax/agenda.ajax.php
  2. 1
      main/ticket/settings.php
  3. 3
      main/ticket/status.php
  4. 4
      main/ticket/ticket_assign_log.php
  5. 1
      main/ticket/ticket_details.php
  6. 1
      main/ticket/tickets.php
  7. 4
      main/ticket/tutor.php
  8. 3
      main/ticket/tutor_report.lib.php

@ -1,4 +1,5 @@
<?php
/* For licensing terms, see /license.txt */
/**
@ -6,7 +7,7 @@
*/
$type = isset($_REQUEST['type']) && in_array($_REQUEST['type'], ['personal', 'course', 'admin']) ? $_REQUEST['type'] : 'personal';
if ($type == 'personal') {
if ($type === 'personal') {
$cidReset = true; // fixes #5162
}
@ -15,16 +16,13 @@ require_once __DIR__.'/../global.inc.php';
$action = isset($_REQUEST['a']) ? $_REQUEST['a'] : null;
$group_id = api_get_group_id();
if ($type == 'course') {
if ($type === 'course') {
api_protect_course_script(true);
}
$logInfo = [
'tool' => TOOL_CALENDAR_EVENT,
'tool_id' => 0,
'tool_id_detail' => 0,
'action' => $action,
'info' => '',
];
Event::registerLog($logInfo);
@ -51,9 +49,9 @@ switch ($action) {
$content,
$userToSend,
$add_as_announcement,
null, //$parentEventId = null,
[], //$attachmentArray = array(),
null, //$attachmentComment = null,
null,
[],
null,
$comment
);
break;
@ -111,7 +109,7 @@ switch ($action) {
$start = isset($_REQUEST['start']) ? api_strtotime($_REQUEST['start']) : null;
$end = isset($_REQUEST['end']) ? api_strtotime($_REQUEST['end']) : null;
if ($type == 'personal' && !empty($sessionId)) {
if ($type === 'personal' && !empty($sessionId)) {
$agenda->setSessionId($sessionId);
}
@ -126,7 +124,7 @@ switch ($action) {
echo $events;
break;
case 'get_user_agenda':
//Used in the admin user list
// Used in the admin user list.
api_protect_admin_script();
if (api_is_allowed_to_edit(null, true)) {

@ -1,4 +1,5 @@
<?php
/* For licensing terms, see /license.txt */
$cidReset = true;

@ -1,12 +1,11 @@
<?php
/* For licensing terms, see /license.txt */
use ChamiloSession as Session;
/**
* This script is the Tickets plugin main entry point.
*
* @package chamilo.plugin.ticket
*/
$cidReset = true;

@ -1,9 +1,7 @@
<?php
/* For licensing terms, see /license.txt */
/**
* @package chamilo.plugin.ticket
*/
require_once __DIR__.'/../inc/global.inc.php';
api_protect_admin_script();

@ -322,7 +322,6 @@ if ($allowEdition &&
header("Location:".api_get_self()."?ticket_id=".$ticket_id);
exit;
}
}
Display::display_header();

@ -1,4 +1,5 @@
<?php
/* For licensing terms, see /license.txt */
use ChamiloSession as Session;

@ -1,9 +1,7 @@
<?php
/* For licensing terms, see /license.txt */
/**
* @package chamilo.plugin.ticket
*/
exit;
require_once __DIR__.'/../inc/global.inc.php';
require_once __DIR__.'/tutor_report.lib.php';

@ -1,10 +1,9 @@
<?php
/* For licensing terms, see /license.txt */
/**
* Helper library for weekly reports.
*
* @package chamilo.plugin.ticket
*/
/**

Loading…
Cancel
Save