fmsystem-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Fmsystem-commits] [10813] mobilefrontend: refactor


From: Sigurd Nes
Subject: [Fmsystem-commits] [10813] mobilefrontend: refactor
Date: Thu, 14 Feb 2013 08:55:19 +0000

Revision: 10813
          http://svn.sv.gnu.org/viewvc/?view=rev&root=fmsystem&revision=10813
Author:   sigurdne
Date:     2013-02-14 08:55:18 +0000 (Thu, 14 Feb 2013)
Log Message:
-----------
mobilefrontend: refactor

Modified Paths:
--------------
    trunk/mobilefrontend/index.php

Added Paths:
-----------
    trunk/mobilefrontend/inc/controller/
    trunk/mobilefrontend/inc/controller/class.uicontrol.inc.php

Removed Paths:
-------------
    trunk/mobilefrontend/inc/class.uicontrol.inc.php

Deleted: trunk/mobilefrontend/inc/class.uicontrol.inc.php
===================================================================
--- trunk/mobilefrontend/inc/class.uicontrol.inc.php    2013-02-14 08:53:33 UTC 
(rev 10812)
+++ trunk/mobilefrontend/inc/class.uicontrol.inc.php    2013-02-14 08:55:18 UTC 
(rev 10813)
@@ -1,50 +0,0 @@
-<?php
-       /**
-       * phpGroupWare - controller: a part of a Facilities Management System.
-       *
-       * @author Erink Holm-Larsen <address@hidden>
-       * @author Torstein Vadla <address@hidden>
-       * @copyright Copyright (C) 2011,2012 Free Software Foundation, Inc. 
http://www.fsf.org/
-       * This file is part of phpGroupWare.
-       *
-       * phpGroupWare 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.
-       *
-       * phpGroupWare is distributed in the hope that it will be useful,
-       * but WITHOUT ANY WARRANTY; without even the implied warranty of
-       * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-       * GNU General Public License for more details.
-       *
-       * You should have received a copy of the GNU General Public License
-       * along with phpGroupWare; if not, write to the Free Software
-       * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301 
 USA
-       *
-       * @license http://www.gnu.org/licenses/gpl.html GNU General Public 
License
-       * @internal Development of this application was funded by 
http://www.bergen.kommune.no/
-       * @package property
-       * @subpackage controller
-       * @version $Id$
-       */      
-
-       
-       phpgw::import_class('controller.uicontrol');
-
-       class mobilefrontend_uicontrol extends controller_uicontrol
-       {
-               public $public_functions = array
-               (
-                       'view_control_details'  =>      true,
-               );
-
-               public function __construct()
-               {
-                       parent::__construct();
-               }
-               
-               public function view_control_details($control = null)
-               {
-                       parent::view_control_details($control);
-               }
-       }

Added: trunk/mobilefrontend/inc/controller/class.uicontrol.inc.php
===================================================================
--- trunk/mobilefrontend/inc/controller/class.uicontrol.inc.php                 
        (rev 0)
+++ trunk/mobilefrontend/inc/controller/class.uicontrol.inc.php 2013-02-14 
08:55:18 UTC (rev 10813)
@@ -0,0 +1,50 @@
+<?php
+       /**
+       * phpGroupWare - controller: a part of a Facilities Management System.
+       *
+       * @author Erink Holm-Larsen <address@hidden>
+       * @author Torstein Vadla <address@hidden>
+       * @copyright Copyright (C) 2011,2012 Free Software Foundation, Inc. 
http://www.fsf.org/
+       * This file is part of phpGroupWare.
+       *
+       * phpGroupWare 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.
+       *
+       * phpGroupWare is distributed in the hope that it will be useful,
+       * but WITHOUT ANY WARRANTY; without even the implied warranty of
+       * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+       * GNU General Public License for more details.
+       *
+       * You should have received a copy of the GNU General Public License
+       * along with phpGroupWare; if not, write to the Free Software
+       * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301 
 USA
+       *
+       * @license http://www.gnu.org/licenses/gpl.html GNU General Public 
License
+       * @internal Development of this application was funded by 
http://www.bergen.kommune.no/
+       * @package property
+       * @subpackage controller
+       * @version $Id: class.uicontrol.inc.php 10804 2013-02-13 13:24:06Z 
sigurdne $
+       */      
+
+       
+       phpgw::import_class('controller.uicontrol');
+
+       class mobilefrontend_uicontrol extends controller_uicontrol
+       {
+               public $public_functions = array
+               (
+                       'view_control_details'  =>      true,
+               );
+
+               public function __construct()
+               {
+                       parent::__construct();
+               }
+               
+               public function view_control_details($control = null)
+               {
+                       parent::view_control_details($control);
+               }
+       }

Modified: trunk/mobilefrontend/index.php
===================================================================
--- trunk/mobilefrontend/index.php      2013-02-14 08:53:33 UTC (rev 10812)
+++ trunk/mobilefrontend/index.php      2013-02-14 08:55:18 UTC (rev 10813)
@@ -190,7 +190,16 @@
                $method = 'index';
        }
 
-       $GLOBALS[$class] = CreateObject("{$app}.{$class}");
+       if(is_file(PHPGW_SERVER_ROOT. 
"/mobilefrontend/inc/class.{$class}.inc.php"))
+       {
+               $GLOBALS[$class] = CreateObject("{$app}.{$class}");
+       }
+       else
+       {
+               include_class('mobilefrontend', $class, "inc/{$app}/");
+               $_class = "mobilefrontend_{$class}";
+               $GLOBALS[$class] = new $_class;
+       }
 
        $invalid_data = false; //FIXME consider whether this should be computed 
as in the main index.php
        if ( !$invalid_data 




reply via email to

[Prev in Thread] Current Thread [Next in Thread]