Parcourir la source

Fixes #3732 + updating license text in headers (Reservation feature)

Julio Montoya il y a 13 ans
Parent
commit
d32ddbd2e8

+ 1 - 0
license.txt

@@ -9,6 +9,7 @@ Copyright (c) 2003-2008 Vrije Universiteit Brussel (VUB)
 Copyright (c) 2004-2008 Hoogeschool Gent (HoGent)
 Copyright (c) Bart Mollet, Hogeschool Gent
 Copyright (c) Facultad de Matematicas, UADY (México) (Message plugin)
+Copyright (c) Kristof Van Steenkiste & Sebastien Jacobs (Reservation plugin) 
 	
 For a full list of contributors detaining copyrights over parts of
 the Chamilo software, see "documentation/credits.html".

+ 2 - 35
main/reservation/m_category.php

@@ -1,39 +1,14 @@
 <?php
-// $Id: m_category.php,v 1.2 2006/05/09 08:51:14 kvansteenkiste Exp $
-/*
-==============================================================================
-    Dokeos - elearning and course management software
-
-    Copyright (c) 2004-2008 Dokeos SPRL
-    Copyright (c) Sebastien Jacobs (www.spiritual-coder.com)
-    Copyright (c) Kristof Van Steenkiste
-    Copyright (c) Julio Montoya Armas
-
-    For a full list of contributors, see "credits.txt".
-    The full license can be read in "license.txt".
-
-    This program is free software; you can redistribute it and/or
-    modify it under the terms of the GNU General Public License
-    as published by the Free Software Foundation; either version 2
-    of the License, or (at your option) any later version.
-
-    See the GNU General Public License for more details.
-
-    Contact address: Dokeos, rue du Corbeau, 108, B-1030 Brussels, Belgium
-    Mail: info@dokeos.com
-==============================================================================
-*/
+/* For licensing terms, see /license.txt */
 /**
-    ---------------------------------------------------------------------
                 Category-manager (add, edit & delete)
-    ---------------------------------------------------------------------
  */
 require_once 'rsys.php';
 
 // TODO: The global initialization scripts loads once again here. To be checked.
 $language_file = 'admin';
 $cidReset = true;
-require '../inc/global.inc.php';
+require_once '../inc/global.inc.php';
 //
 
 $this_section = SECTION_PLATFORM_ADMIN;
@@ -44,10 +19,6 @@ Rsys :: protect_script('m_category');
 $tool_name = get_lang('BookingSystem');
 $interbreadcrumb[] = array ('url' => '../admin/index.php', 'name' => get_lang('PlatformAdmin'));
 
-/**
-    ---------------------------------------------------------------------
- */
-
 /**
  *  Filter to display the modify-buttons
  *
@@ -57,10 +28,6 @@ function modify_filter($id) {
 	return '<a href="m_category.php?action=edit&amp;id='.$id.'" title="'.get_lang("EditResourceType").'"><img alt="" src="../img/edit.gif" /></a>'.' <a href="m_category.php?action=delete&amp;id='.$id.'" title="'.get_lang("DeleteResourceType").'" onclick="javascript:if(!confirm('."'".addslashes(api_htmlentities(get_lang("ConfirmDeleteResourceType")))."'".')) return false;"><img alt="" src="../img/delete.gif" /></a>';
 }
 
-/**
-    ---------------------------------------------------------------------
- */
-
 switch ($_GET['action']) {
 	case 'add' :
 		$interbreadcrumb[] = array ("url" => "m_category.php", "name" => $tool_name);

+ 2 - 34
main/reservation/m_item.php

@@ -1,42 +1,14 @@
 <?php
-// $Id: m_item.php,v 1.13 2006/05/11 14:29:52 sjacobs Exp $
-/*
-==============================================================================
-    Dokeos - elearning and course management software
-
-    Copyright (c) 2004-2008 Dokeos SPRL
-    Copyright (c) Sebastien Jacobs (www.spiritual-coder.com)
-    Copyright (c) Kristof Van Steenkiste
-    Copyright (c) Julio Montoya Armas
-
-    For a full list of contributors, see "credits.txt".
-    The full license can be read in "license.txt".
-
-    This program is free software; you can redistribute it and/or
-    modify it under the terms of the GNU General Public License
-    as published by the Free Software Foundation; either version 2
-    of the License, or (at your option) any later version.
-
-    See the GNU General Public License for more details.
-
-    Contact address: Dokeos, rue du Corbeau, 108, B-1030 Brussels, Belgium
-    Mail: info@dokeos.com
-==============================================================================
-*/
+/* For licensing terms, see /license.txt */
+
 /**
-    ---------------------------------------------------------------------
                 Item-manager (add, edit & delete)
-    ---------------------------------------------------------------------
  */
 require_once ('rsys.php');
 Rsys :: protect_script('m_item');
 $tool_name = get_lang('ResourceList');
 //$interbreadcrumb[] = array ("url" => "../admin/index.php", "name" => get_lang('PlatformAdmin'));
 
-/**
-    ---------------------------------------------------------------------
- */
-
 /**
  *  Filter to display the modify-buttons
  *
@@ -73,10 +45,6 @@ function modify_rights_filter($id) {
 	return ' <a href="m_item.php?action=m_rights&amp;subaction=delete&amp;item_id='.substr($id, 0, strpos($id, '-')).'&amp;class_id='.substr($id, strrpos($id, '-') + 1).'" title="'.get_lang("RemoveClassRights").'" onclick="javascript:if(!confirm('."'".addslashes(api_htmlentities(get_lang("ConfirmDeleteResource")))."'".')) return false;"><img alt="" src="../img/delete.gif" /></a>';
 }
 
-/**
-    ---------------------------------------------------------------------
- */
-
 if (isset ($_POST['action'])) {
 	switch ($_POST['action']) {
 		case 'delete_items' :

+ 1 - 34
main/reservation/m_item_origineel.php

@@ -1,32 +1,7 @@
 <?php
-// $Id: m_item.php,v 1.13 2006/05/11 14:29:52 sjacobs Exp $
-/*
-==============================================================================
-    Dokeos - elearning and course management software
-
-    Copyright (c) 2004-2008 Dokeos SPRL
-    Copyright (c) Sebastien Jacobs (www.spiritual-coder.com)
-    Copyright (c) Kristof Van Steenkiste
-    Copyright (c) Julio Montoya Armas
-
-    For a full list of contributors, see "credits.txt".
-    The full license can be read in "license.txt".
-
-    This program is free software; you can redistribute it and/or
-    modify it under the terms of the GNU General Public License
-    as published by the Free Software Foundation; either version 2
-    of the License, or (at your option) any later version.
-
-    See the GNU General Public License for more details.
-
-    Contact address: Dokeos, rue du Corbeau, 108, B-1030 Brussels, Belgium
-    Mail: info@dokeos.com
-==============================================================================
-*/
+/* For licensing terms, see /license.txt */
 /**
-    ---------------------------------------------------------------------
                 Item-manager (add, edit & delete)
-    ---------------------------------------------------------------------
  */
 require_once('rsys.php');
 
@@ -34,10 +9,6 @@ Rsys :: protect_script('m_item');
 $tool_name = get_lang('ItemManagerHeader');
 //$interbreadcrumb[] = array ("url" => "../admin/index.php", "name" => get_lang('PlatformAdmin'));
 
-/**
-    ---------------------------------------------------------------------
- */
-
 /**
  *  Filter to display the modify-buttons
  *
@@ -67,10 +38,6 @@ function modify_rights_filter($id) {
 	return ' <a href="m_item.php?action=m_rights&amp;subaction=delete&amp;item_id='.substr($id, 0, strpos($id, '-')).'&amp;class_id='.substr($id, strrpos($id, '-') + 1).'" title="'.get_lang("RemoveClassRights").'" onclick="javascript:if(!confirm('."'".addslashes(api_htmlentities(get_lang("ConfirmDeleteItem"), ENT_QUOTES, api_get_system_encoding()))."'".')) return false;"><img alt="" src="../img/delete.gif" /></a>';
 }
 
-/**
-    ---------------------------------------------------------------------
- */
-
 if (isset ($_POST['action'])) {
 	switch ($_POST['action']) {
 		case 'delete_items' :

+ 2 - 30
main/reservation/m_reservation.php

@@ -1,42 +1,14 @@
 <?php
-// $Id: m_reservation.php,v 1.26 2006/05/12 08:38:34 kvansteenkiste Exp $
-/*
-==============================================================================
-    Dokeos - elearning and course management software
-
-    Copyright (c) 2004-2008 Dokeos SPRL
-    Copyright (c) Sebastien Jacobs (www.spiritual-coder.com)
-    Copyright (c) Kristof Van Steenkiste
-    Copyright (c) Julio Montoya Armas
-
-    For a full list of contributors, see "credits.txt".
-    The full license can be read in "license.txt".
-
-    This program is free software; you can redistribute it and/or
-    modify it under the terms of the GNU General Public License
-    as published by the Free Software Foundation; either version 2
-    of the License, or (at your option) any later version.
-
-    See the GNU General Public License for more details.
-
-    Contact address: Dokeos, rue du Corbeau, 108, B-1030 Brussels, Belgium
-    Mail: info@dokeos.com
-==============================================================================
-*/
+/* For licensing terms, see /license.txt */
+
 /**
-    ---------------------------------------------------------------------
                 Reservation-manager (add, edit & delete)
-    ---------------------------------------------------------------------
  */
 require_once('rsys.php');
 
 Rsys :: protect_script('m_reservation', $_GET['item_id']);
 $tool_name = get_lang('BookingPeriodList');
 
-/**
-    ---------------------------------------------------------------------
- */
-
 /**
  *  Filter to display the modify-buttons
  *

+ 2 - 33
main/reservation/mysubscriptions.php

@@ -1,45 +1,18 @@
-<?php // $Id: mysubscriptions.php,v 1.3 2006/04/27 14:14:03 kvansteenkiste Exp $
-/*
-==============================================================================
-    Dokeos - elearning and course management software
+<?php
+/* For licensing terms, see /license.txt */
 
-    Copyright (c) 2004-2008 Dokeos S.
-    Copyright (c) Sebastien Jacobs (www.spiritual-coder.com)
-    Copyright (c) Kristof Van Steenkiste
-    Copyright (c) Julio Montoya Armas
-
-    For a full list of contributors, see "credits.txt".
-    The full license can be read in "license.txt".
-
-    This program is free software; you can redistribute it and/or
-    modify it under the terms of the GNU General Public License
-    as published by the Free Software Foundation; either version 2
-    of the License, or (at your option) any later version.
-
-    See the GNU General Public License for more details.
-
-    Contact address: Dokeos, rue du Corbeau, 108, B-1030 Brussels, Belgium
-    Mail: info@dokeos.com
-==============================================================================
-*/
 /**
-    ---------------------------------------------------------------------
         An overview with a list of upcoming reservations where
         the user has subscribed to (may also be viewable in the agenda)
 
         Later: links to m_item & m_reservation for every item your group (class) owns and
         the possibility (links) for adding new items or reservations
-    ---------------------------------------------------------------------
  */
 require_once('rsys.php');
 
 Rsys::protect_script('mysubscriptions');
 $tool_name = get_lang('Booking');
 
-/**
-    ---------------------------------------------------------------------
- */
-
 /**
  *  Filter to display the modify-buttons
  */
@@ -47,10 +20,6 @@ function modify_filter($id){
      return ' <a href="mysubscriptions.php?action=delete&amp;reservation_id='.substr($id,0,strpos($id,'-')).'&amp;dummy='.substr($id,strrpos($id,'-')+1).'" title="'.get_lang("DeleteSubscription").'" onclick="javascript:if(!confirm('."'".addslashes(api_htmlentities(get_lang("ConfirmDeleteSubscription")))."'".')) return false;"><img alt="" src="../img/delete.gif" /></a>';
 }
 
-/**
-    ---------------------------------------------------------------------
- */
-
 switch ($_GET['action']) {
     case 'delete' :
         Rsys :: delete_subscription($_GET['reservation_id'],$_GET['dummy']);

+ 3 - 27
main/reservation/rcalendar.php

@@ -1,30 +1,7 @@
-<?php // $Id: rcalendar.php,v 1.50 2006/05/12 07:33:26 sjacobs Exp $
-/*
-==============================================================================
-    Dokeos - elearning and course management software
-
-    Copyright (c) 2004-2008 Dokeos SPRL
-    Copyright (c) Sebastien Jacobs (www.spiritual-coder.com)
-    Copyright (c) Kristof Van Steenkiste
-
-    For a full list of contributors, see "credits.txt".
-    The full license can be read in "license.txt".
-
-    This program is free software; you can redistribute it and/or
-    modify it under the terms of the GNU General Public License
-    as published by the Free Software Foundation; either version 2
-    of the License, or (at your option) any later version.
-
-    See the GNU General Public License for more details.
-
-    Contact address: Dokeos, rue du Corbeau, 108, B-1030 Brussels, Belgium
-    Mail: info@dokeos.com
-==============================================================================
-*/
+<?php
+/* For licensing terms, see /license.txt */
 /**
-    --------------
     The rCalendar
-    --------------
  */
 $DaysShort = api_get_week_days_short();
 $DaysLong = api_get_week_days_long();
@@ -471,5 +448,4 @@ class rCalendar {
         	$GLOBALS['weekstart']=date('d/m/Y',$day_start_dates[1]);
         	$GLOBALS['weekend']=date('d/m/Y',$day_start_dates[7]);
 	}
-}
-?>
+}

+ 4 - 27
main/reservation/reservation.php

@@ -1,31 +1,8 @@
-<?php // $Id: reservation.php,v 1.34 2006/05/10 12:30:38 sjacobs Exp $
-/*
-==============================================================================
-    Dokeos - elearning and course management software
-
-    Copyright (c) 2004-2008 Dokeos SPRL
-    Copyright (c) Sebastien Jacobs (www.spiritual-coder.com)
-    Copyright (c) Kristof Van Steenkiste
-    Copyright (c) Julio Montoya Armas
-
-    For a full list of contributors, see "credits.txt".
-    The full license can be read in "license.txt".
-
-    This program is free software; you can redistribute it and/or
-    modify it under the terms of the GNU General Public License
-    as published by the Free Software Foundation; either version 2
-    of the License, or (at your option) any later version.
-
-    See the GNU General Public License for more details.
-
-    Contact address: Dokeos, rue du Corbeau, 108, B-1030 Brussels, Belgium
-    Mail: info@dokeos.com
-==============================================================================
-*/
+<?php 
+/* For licensing terms, see /license.txt */
+
 /**
-    ---------------------------------------------------------------------
-                Reservation-manager (add, edit & delete)
-    ---------------------------------------------------------------------
+	Reservation-manager (add, edit & delete)
  */
 require_once('rsys.php');
 

+ 2 - 33
main/reservation/rsys.php

@@ -1,32 +1,7 @@
 <?php
-// $Id: rsys.php,v 1.80 2006/05/12 08:48:49 sjacobs Exp $
-/*
-==============================================================================
-    Dokeos - elearning and course management software
-
-    Copyright (c) 2004-2008 Dokeos SPRL
-    Copyright (c) Sebastien Jacobs (www.spiritual-coder.com)
-    Copyright (c) Kristof Van Steenkiste
-    Copyright (c) Julio Montoya Armas
-
-    For a full list of contributors, see "credits.txt".
-    The full license can be read in "license.txt".
-
-    This program is free software; you can redistribute it and/or
-    modify it under the terms of the GNU General Public License
-    as published by the Free Software Foundation; either version 2
-    of the License, or (at your option) any later version.
-
-    See the GNU General Public License for more details.
-
-    Contact address: Dokeos, rue du Corbeau, 108, B-1030 Brussels, Belgium
-    Mail: info@dokeos.com
-==============================================================================
-*/
+/* For licensing terms, see /license.txt */
 /**
-    ---------------------------------------------------------------------
     The class-library with all reservation-system specific functionality
-    ---------------------------------------------------------------------
  */
 class Rsys {
 	/**
@@ -150,11 +125,7 @@ class Rsys {
 		return $user_info['status'];
 	}
 	/*
-	 ============================================================================================
-
 	                                    CATEGORIES
-
-	 ============================================================================================
 	*/
 
 	/**
@@ -1773,6 +1744,4 @@ require_once '../inc/global.inc.php';
 require_once api_get_path(LIBRARY_PATH).'sortabletable.class.php';
 Rsys :: init();
 require_once 'rcalendar.php';
-require_once api_get_path(LIBRARY_PATH).'formvalidator/FormValidator.class.php';
-
-?>
+require_once api_get_path(LIBRARY_PATH).'formvalidator/FormValidator.class.php';

+ 4 - 33
main/reservation/subscribe.php

@@ -1,38 +1,12 @@
 <?php
-// $Id: subscribe.php,v 1.9 2006/05/11 14:36:10 kvansteenkiste Exp $
-/*
-==============================================================================
-    Dokeos - elearning and course management software
-
-    Copyright (c) 2004-2008 Dokeos SPRL
-    Copyright (c) Sebastien Jacobs (www.spiritual-coder.com)
-    Copyright (c) Kristof Van Steenkiste
-    Copyright (c) Julio Montoya Armas
-
-    For a full list of contributors, see "credits.txt".
-    The full license can be read in "license.txt".
-
-    This program is free software; you can redistribute it and/or
-    modify it under the terms of the GNU General Public License
-    as published by the Free Software Foundation; either version 2
-    of the License, or (at your option) any later version.
-
-    See the GNU General Public License for more details.
-
-    Contact address: Dokeos, rue du Corbeau, 108, B-1030 Brussels, Belgium
-    Mail: info@dokeos.com
-==============================================================================
-*/
+/* For licensing terms, see /license.txt */
 /**
-    ---------------------------------------------------------------------
-                Reservation-manager (add, edit & delete)
-    ---------------------------------------------------------------------
- */
+	Reservation-manager (add, edit & delete)
+*/
 
 require_once('rsys.php');
 Rsys :: protect_script('reservation');
 
-
 if (!empty($_GET['cat']) && !empty($_GET['item'] )) {
 	$cat = (int)$_GET['cat'];
 	$item = (int)$_GET['item'];
@@ -173,7 +147,4 @@ if ($reservation[0][9] < $reservation[0][4]) {
 } else {
 	Display :: display_normal_message(Rsys :: get_return_msg2(get_lang('ReservationTresspassing'), "javascript:history.go(-2)", get_lang('BookingView')),false);
 }
-
-
-Display :: display_footer();
-?>
+Display :: display_footer();