[795] | 1 | <?php |
---|
| 2 | /**************************************************************************\ |
---|
| 3 | * eGroupWare * |
---|
| 4 | * http://www.egroupware.org * |
---|
| 5 | * -------------------------------------------- * |
---|
| 6 | * This program is free software; you can redistribute it and/or modify it * |
---|
| 7 | * under the terms of the GNU General Public License as published by the * |
---|
| 8 | * Free Software Foundation; either version 2 of the License, or (at your * |
---|
| 9 | * option) any later version. * |
---|
| 10 | \**************************************************************************/ |
---|
| 11 | |
---|
| 12 | /* if the menuaction variable is set, then let the expresso index deal with it */ |
---|
| 13 | if (isset($_GET['menuaction'])) |
---|
| 14 | { |
---|
| 15 | /* in case it's an Ajax call from the processes, then check for expired session */ |
---|
[2193] | 16 | if (($_GET['menuaction'] == 'workflow.run_activity.goAjax')) |
---|
[795] | 17 | { |
---|
[2193] | 18 | if (empty($_SESSION['phpgw_session']['session_id'])) |
---|
[795] | 19 | { |
---|
| 20 | /* the session is expired, return a NanoAjax exception */ |
---|
| 21 | require_once dirname(__FILE__) . '/inc/nano/JSON.php'; |
---|
| 22 | require_once dirname(__FILE__) . '/inc/nano/NanoJsonConverter.class.php'; |
---|
[2372] | 23 | $nanoController = &Factory::newInstance('NanoController'); |
---|
[795] | 24 | $nanoController->throwErrorOnAllVirtualRequests('__NANOAJAX_SESSION_EXPIRED__'); |
---|
| 25 | exit; |
---|
| 26 | } |
---|
| 27 | } |
---|
| 28 | chdir('..'); |
---|
| 29 | require_once 'index.php'; |
---|
| 30 | } |
---|
| 31 | else |
---|
| 32 | { |
---|
| 33 | $phpgw_info = array(); |
---|
| 34 | $GLOBALS['phpgw_info']['flags'] = array( |
---|
| 35 | 'currentapp' => 'workflow', |
---|
| 36 | 'noheader' => True, |
---|
| 37 | 'nonavbar' => True |
---|
| 38 | ); |
---|
| 39 | require_once '../header.inc.php'; |
---|
| 40 | require_once 'inc/common.inc.php'; |
---|
| 41 | |
---|
| 42 | if (isset($_GET['start_tab'])) |
---|
| 43 | { |
---|
| 44 | $start_tab = $_GET['start_tab']; |
---|
| 45 | } |
---|
| 46 | else |
---|
| 47 | { |
---|
[2492] | 48 | $start_tab = Settings::get('workflow', 'preferences', 'startpage'); |
---|
[795] | 49 | if (is_null($start_tab)) |
---|
| 50 | $start_tab = 1; |
---|
| 51 | } |
---|
| 52 | ExecMethod('workflow.ui_userinterface.draw', $start_tab); |
---|
| 53 | } |
---|
| 54 | ?> |
---|