diff --git a/resources/inc/class.bo_acl.inc.php b/resources/inc/class.bo_acl.inc.php index adcfc65c94..91db963b10 100755 --- a/resources/inc/class.bo_acl.inc.php +++ b/resources/inc/class.bo_acl.inc.php @@ -2,12 +2,15 @@ /** * EGroupWare - resources * - * @license http://www.gnu.org/licenses/gpl.html GNU General Public License + * @license http://www.gnu.org/licenses/gpl.Api\Html GNU General Public License * @package resources * @link http://www.egroupware.org * @version $Id$ */ +use EGroupware\Api; +use EGroupware\Api\Acl; + /** * ACL business object for resources * @@ -30,7 +33,7 @@ class bo_acl /** * Instance of categories class for resources * - * @var categories + * @var egw_cats */ var $egw_cats; @@ -46,7 +49,7 @@ class bo_acl define('EGW_ACL_DIRECT_BOOKING',128); define('EGW_ACL_CALREAD',256); - $this->egw_cats = new categories($user, 'resources'); + $this->egw_cats = new Api\Categories($user, 'resources'); $this->debug = False; //all this is only needed when called from uiacl. @@ -86,7 +89,7 @@ class bo_acl * get list of cats where current user has given rights * * @author Cornelius Weiss <egw@von-und-zu-weiss.de> - * @param int $perm_type one of EGW_ACL_READ, EGW_ACL_ADD, EGW_ACL_EDIT, EGW_ACL_DELETE, EGW_ACL_DIRECT_BOOKING + * @param int $perm_type one of Acl::READ, Acl::ADD, Acl::EDIT, Acl::DELETE, EGW_ACL_DIRECT_BOOKING * @param int $parent_id=0 cat_id of parent to return only children of that category * @return array cat_id => cat_name * TODO mark subcats and so on! @@ -186,7 +189,7 @@ class bo_acl /** * checks one of the following rights for current user: * - * EGW_ACL_READ, EGW_ACL_ADD, EGW_ACL_EDIT, EGW_ACL_DELETE, EGW_ACL_DIRECT_BOOKING + * Acl::READ, Acl::ADD, Acl::EDIT, Acl::DELETE, EGW_ACL_DIRECT_BOOKING * * @param int $cat_id * @param int $right @@ -226,12 +229,12 @@ class bo_acl 'limit' => $this->limit, ); if($this->debug) { echo '<br>Read:'; _debug_array($data); } - $GLOBALS['egw']->session->appsession('session_data','resources_acl',$data); + Api\Cache::setSession('resources_acl', 'session_data', $data); } function read_sessiondata() { - $data = $GLOBALS['egw']->session->appsession('session_data','resources_acl'); + $data = Api\Cache::getSession('resources_acl', 'session_data'); if($this->debug) { echo '<br>Read:'; _debug_array($data); } $this->start = $data['start']; @@ -258,8 +261,8 @@ class bo_acl { $account_id = $account['account_id']; $rights = false; - $rights = in_array($account_id,$readcat) ? ($rights | EGW_ACL_READ) : false; - $rights = in_array($account_id,$writecat) ? ($rights | EGW_ACL_READ | EGW_ACL_ADD | EGW_ACL_EDIT | EGW_ACL_DELETE): $rights; + $rights = in_array($account_id,$readcat) ? ($rights | Acl::READ) : false; + $rights = in_array($account_id,$writecat) ? ($rights | Acl::READ | Acl::ADD | Acl::EDIT | Acl::DELETE): $rights; $rights = in_array($account_id,$calreadcat) ? ($rights | EGW_ACL_CALREAD) : $rights; $rights = in_array($account_id,$calbookcat) ? ($rights | EGW_ACL_DIRECT_BOOKING | EGW_ACL_CALREAD) : $rights; $rights = in_array($account_id,$admincat) ? ($rights = 511) : $rights; diff --git a/resources/inc/class.resources_bo.inc.php b/resources/inc/class.resources_bo.inc.php index 430536d0eb..6ca0b6c2f2 100755 --- a/resources/inc/class.resources_bo.inc.php +++ b/resources/inc/class.resources_bo.inc.php @@ -10,6 +10,11 @@ * @version $Id$ */ +use EGroupware\Api; +use EGroupware\Api\Link; +use EGroupware\Api\Egw; +use EGroupware\Api\Acl; +use EGroupware\Api\Vfs; /** * General business object for resources @@ -29,13 +34,13 @@ class resources_bo */ var $so; /** - * Instance of resources acl class + * Instance of resources Acl class * * @var bo_acl */ var $acl; /** - * Instance of categories class for resources + * Instance of Api\Categories class for resources */ var $cats; @@ -69,7 +74,7 @@ class resources_bo /** * Constructor * - * @param int $user=null account_id of user to use for acl, default current user + * @param int $user=null account_id of user to use for Acl, default current user */ function __construct($user=null) { @@ -78,9 +83,9 @@ class resources_bo $this->cats = $this->acl->egw_cats; $this->cal_right_transform = array( - EGW_ACL_CALREAD => EGW_ACL_READ, - EGW_ACL_DIRECT_BOOKING => EGW_ACL_READ | EGW_ACL_ADD | EGW_ACL_EDIT | EGW_ACL_DELETE, - EGW_ACL_CAT_ADMIN => EGW_ACL_READ | EGW_ACL_ADD | EGW_ACL_EDIT | EGW_ACL_DELETE, + EGW_ACL_CALREAD => Acl::READ, + EGW_ACL_DIRECT_BOOKING => Acl::READ | Acl::ADD | Acl::EDIT | Acl::DELETE, + EGW_ACL_CAT_ADMIN => Acl::READ | Acl::ADD | Acl::EDIT | Acl::DELETE, ); } @@ -93,11 +98,11 @@ class resources_bo { if(!$query['csv_export']) { - $GLOBALS['egw']->session->appsession('session_data','resources_index_nm',$query); + Api\Cache::setSession('resources', 'index_nm', $query); } if ($query['store_state']) // request to store state in session and filter in prefs? { - egw_cache::setSession('resources',$query['store_state'],$query); + Api\Cache::setSession('resources',$query['store_state'],$query); //echo "<p>".__METHOD__."() query[filter]=$query[filter], prefs[resources][filter]={$GLOBALS['egw_info']['user']['preferences']['resources']['filter']}</p>\n"; if ($query['filter'] != $GLOBALS['egw_info']['user']['preferences']['resources']['filter']) { @@ -147,7 +152,7 @@ class resources_bo if ($query['filter']) { - if (($children = $this->acl->get_cats(EGW_ACL_READ,$query['filter']))) + if (($children = $this->acl->get_cats(Acl::READ,$query['filter']))) { $filter['cat_id'] = array_keys($children); $filter['cat_id'][] = $query['filter']; @@ -157,7 +162,7 @@ class resources_bo $filter['cat_id'] = $query['filter']; } } - elseif (($readcats = $this->acl->get_cats(EGW_ACL_READ))) + elseif (($readcats = $this->acl->get_cats(Acl::READ))) { $filter['cat_id'] = array_keys($readcats); } @@ -189,10 +194,10 @@ class resources_bo return $nr; } - $config = config::read('resources'); + $config = Api\Config::read('resources'); foreach($rows as $num => &$resource) { - if (!$this->acl->is_permitted($resource['cat_id'],EGW_ACL_EDIT)) + if (!$this->acl->is_permitted($resource['cat_id'],Acl::EDIT)) { $readonlys["edit[$resource[res_id]]"] = true; } @@ -200,14 +205,14 @@ class resources_bo { $resource['class'] .= 'deleted '; } - if (!$this->acl->is_permitted($resource['cat_id'],EGW_ACL_DELETE) || + if (!$this->acl->is_permitted($resource['cat_id'],Acl::DELETE) || ($resource['deleted'] && !$GLOBALS['egw_info']['user']['apps']['admin'] && $config['history'] == 'history') ) { $readonlys["delete[$resource[res_id]]"] = true; $resource['class'] .= 'no_delete '; } - if ((!$this->acl->is_permitted($resource['cat_id'],EGW_ACL_ADD)) || + if ((!$this->acl->is_permitted($resource['cat_id'],Acl::ADD)) || // Allow new accessory action when viewing accessories of a certain resource $query['filter2'] <= 0 && $resource['accessory_of'] != -1) { @@ -266,7 +271,7 @@ class resources_bo $rows[$num]['admin'] = $this->acl->get_cat_admin($resource['cat_id']); } - if(!config::get_customfields('resources')) + if(!Api\Storage\Customfields::get('resources')) { $rows['no_customfields'] = true; } @@ -286,7 +291,7 @@ class resources_bo { return null; // not found } - if (!$this->acl->is_permitted($data['cat_id'],EGW_ACL_READ)) + if (!$this->acl->is_permitted($data['cat_id'],Acl::READ)) { return false; // permission denied } @@ -302,7 +307,7 @@ class resources_bo */ function save($resource) { - if(!$this->acl->is_permitted($resource['cat_id'],EGW_ACL_EDIT)) + if(!$this->acl->is_permitted($resource['cat_id'],Acl::EDIT)) { return lang('You are not permitted to edit this resource!'); } @@ -311,13 +316,13 @@ class resources_bo if(!$resource['res_id']) { $resource['res_owner'] = $GLOBALS['egw_info']['user']['account_id']; - $resource['res_created'] = egw_time::server2user(time(),'ts'); + $resource['res_created'] = Api\DateTime::server2user(time(),'ts'); $resource['res_id'] = $this->so->save($resource); } else { $resource['res_modifier'] = $GLOBALS['egw_info']['user']['account_id']; - $resource['res_modified'] = egw_time::server2user(time(),'ts'); + $resource['res_modified'] = Api\DateTime::server2user(time(),'ts'); $old = $this->read($resource['res_id']); } @@ -360,7 +365,7 @@ class resources_bo // Check for restore of deleted, restore held links if($old && $old['deleted'] && !$resource['deleted']) { - egw_link::restore('resources', $resource['res_id']); + Link::restore('resources', $resource['res_id']); } // delete old pictures @@ -370,22 +375,22 @@ class resources_bo } // Update link title - egw_link::notify_update('resources',$resource['res_id'], $resource); + Link::notify_update('resources',$resource['res_id'], $resource); // save links if(is_array($resource['link_to']['to_id'])) { - egw_link::link('resources',$resource['res_id'],$resource['link_to']['to_id']); + Link::link('resources',$resource['res_id'],$resource['link_to']['to_id']); } if($resource['accessory_of'] != $old['accessory_of']) { - egw_link::unlink(0,'resources',$resource['res_id'],'','resources',$old['accessory_of']); + Link::unlink(0,'resources',$resource['res_id'],'','resources',$old['accessory_of']); // Check for resource changing to accessory - move its accessories to resource if($old['accessory_of'] == -1 && $accessories = $this->get_acc_list($resource['res_id'])) { foreach($accessories as $accessory => $name) { - egw_link::unlink(0,'resources',$accessory,'','resources',$resource['res_id']); + Link::unlink(0,'resources',$accessory,'','resources',$resource['res_id']); $acc = $this->read($accessory); $acc['accessory_of'] = -1; $this->so->save($acc); @@ -394,7 +399,7 @@ class resources_bo } if($resource['accessory_of'] != -1) { - egw_link::link('resources',$resource['res_id'],'resources',$resource['accessory_of']); + Link::link('resources',$resource['res_id'],'resources',$resource['accessory_of']); } if(!empty($resource['res_id']) && $this->so->get_value("cat_id",$resource['res_id']) != $resource['cat_id'] && $resource['accessory_of'] == -1) @@ -432,19 +437,19 @@ class resources_bo */ function delete($res_id) { - if(!$this->acl->is_permitted($this->so->get_value('cat_id',$res_id),EGW_ACL_DELETE)) + if(!$this->acl->is_permitted($this->so->get_value('cat_id',$res_id),Acl::DELETE)) { return lang('You are not permitted to delete this resource!'); } // check if we only mark resources as deleted, or really delete them $old = $this->read($res_id); - $config = config::read('resources'); + $config = Api\Config::read('resources'); if ($config['history'] != '' && $old['deleted'] == null) { $old['deleted'] = time(); $this->save($old); - egw_link::unlink(0,'resources',$res_id,'','','',true); + Link::unlink(0,'resources',$res_id,'','','',true); $accessories = $this->get_acc_list($res_id); foreach($accessories as $acc_id => $name) { @@ -454,7 +459,7 @@ class resources_bo { $acc['deleted'] = time(); $this->save($acc); - egw_link::unlink(0,'resources',$acc_id,'','','',true); + Link::unlink(0,'resources',$acc_id,'','','',true); } } return false; @@ -472,7 +477,7 @@ class resources_bo } }; $this->remove_picture($res_id); - egw_link::unlink(0,'resources',$res_id); + Link::unlink(0,'resources',$res_id); // delete the resource from the calendar ExecMethod('calendar.calendar_so.deleteaccount','r'.$res_id); return false; @@ -533,7 +538,7 @@ class resources_bo $resource['responsible'] = $this->acl->get_cat_admin($resource['cat_id']); // preseed the cache - egw_link::set_cache('resources',$resource['res_id'],$t=$this->link_title($resource)); + Link::set_cache('resources',$resource['res_id'],$t=$this->link_title($resource)); } return $data; } @@ -577,13 +582,13 @@ class resources_bo $only_keys = 'res_id,name,short_description,bookable,useable'; // If no read access to any category, just stop - if(!$this->acl->get_cats(EGW_ACL_READ)) + if(!$this->acl->get_cats(Acl::READ)) { $options['total'] = 0; return array(); } $filter = array( - 'cat_id' => array_flip((array)$this->acl->get_cats(EGW_ACL_READ)), + 'cat_id' => array_flip((array)$this->acl->get_cats(Acl::READ)), //'accessory_of' => '-1' 'deleted' => null ); @@ -610,11 +615,11 @@ class resources_bo { $this->bocal = new calendar_bo(); } - $start = new egw_time($cal_info['start']); + $start = new Api\DateTime($cal_info['start']); $startarr= getdate($start->format('ts')); if (isset($cal_info['whole_day']) && $cal_info['whole_day']) { $startarr['hour'] = $startarr['minute'] = 0; - $start = new egw_time($startarr); + $start = new Api\DateTime($startarr); $end = $start->format('ts') + 86399; } else { $start = $start->format('ts'); @@ -717,7 +722,7 @@ class resources_bo { if (!($resource = $this->read(array('res_id' => $resource)))) return $resource; } - elseif (!$this->acl->is_permitted($resource['cat_id'],EGW_ACL_READ)) + elseif (!$this->acl->is_permitted($resource['cat_id'],Acl::READ)) { return false; } @@ -748,7 +753,7 @@ class resources_bo $titles[$resource['res_id']] = $this->link_title($resource); } } - // we assume all not returned contacts are not readable for the user (as we report all deleted contacts to egw_link) + // we assume all not returned contacts are not readable for the user (as we report all deleted contacts to Link) foreach($ids as $id) { if (!isset($titles[$id])) @@ -790,7 +795,7 @@ class resources_bo imagejpeg($src_img,$tmp_name); imagedestroy($src_img); - egw_link::attach_file('resources',$resouce_id,array( + Link::attach_file('resources',$resouce_id,array( 'tmp_name' => $tmp_name, 'name' => self::PICTURE_NAME, 'type' => 'image/jpeg', @@ -811,22 +816,21 @@ class resources_bo switch($resource['picture_src']) { case 'own_src': - $picture = egw_link::vfs_path('resources',$resource['res_id'],self::PICTURE_NAME,true); // vfs path + $picture = Link::vfs_path('resources',$resource['res_id'],self::PICTURE_NAME,true); // vfs path if ($fullsize) { - $picture = egw::link(egw_vfs::download_url($picture)); + $picture = Egw::link(Vfs::download_url($picture)); } else { - $picture = egw::link('/etemplate/thumbnail.php', array( + $picture = Egw::link('/api/thumbnail.php', array( 'path' => $picture ),false); } break; case 'cat_src': - list($picture) = $this->cats->return_single($resource['cat_id']); - $picture = unserialize($picture['data']); + $picture = Api\Categories::id2name($resource['cat_id'], 'data'); if($picture['icon']) { $picture = !$fullsize?$GLOBALS['egw_info']['server']['webserver_url'].'/phpgwapi/images/'.$picture['icon']:'/phpgwapi/images/'.$picture['icon']; @@ -851,7 +855,7 @@ class resources_bo */ function remove_picture($res_id) { - if (($arr = egw_link::delete_attached('resources',$res_id,self::PICTURE_NAME)) && is_array($arr)) + if (($arr = Link::delete_attached('resources',$res_id,self::PICTURE_NAME)) && is_array($arr)) { return array_shift($arr); // $arr = array($path => (bool)$ok); } diff --git a/resources/inc/class.resources_egw_record.inc.php b/resources/inc/class.resources_egw_record.inc.php index 00577529ea..c343aa0ee6 100644 --- a/resources/inc/class.resources_egw_record.inc.php +++ b/resources/inc/class.resources_egw_record.inc.php @@ -22,8 +22,8 @@ class resources_egw_record implements importexport_iface_egw_record private $record = array(); static $types = array( - 'date-time' => array(), - 'select-cat' => array('cat_id'), + 'date-time' => array(), + 'select-cat' => array('cat_id'), 'select-bool' => array('bookable'), // Links is field name => app name 'links' => array('accessory_of' => 'resources') diff --git a/resources/inc/class.resources_export_csv.inc.php b/resources/inc/class.resources_export_csv.inc.php index 7c63ea5fb5..642e3fc8db 100644 --- a/resources/inc/class.resources_export_csv.inc.php +++ b/resources/inc/class.resources_export_csv.inc.php @@ -11,6 +11,9 @@ * @version $Id$ */ +use EGroupware\Api; +use EGroupware\Api\Acl; + /** * export resources to CSV */ @@ -34,7 +37,7 @@ class resources_export_csv implements importexport_iface_export_plugin { $selection = array(); if ($options['selection'] == 'search') { // ui selection with checkbox 'selected' - $query = egw_cache::getSession('resources', 'get_rows'); + $query = Api\Cache::getSession('resources', 'get_rows'); $query['num_rows'] = -1; // all unset($query['store_state']); $query['csv_export'] = true; // so get_rows method _can_ produce different content or not store state in the session @@ -83,7 +86,7 @@ class resources_export_csv implements importexport_iface_export_plugin { // Check if we need to load the custom fields $need_custom = false; - foreach(config::get_customfields('resources') as $field => $settings) { + foreach(Api\Storage\Customfields::get('resources') as $field => $settings) { if($options['mapping']['#'.$field]) { $need_custom = true; break; @@ -179,7 +182,7 @@ class resources_export_csv implements importexport_iface_export_plugin { // In resources, not all categories are used $filters['cat_id']['type'] = 'select'; $filters['cat_id']['name'] = 'filter'; - $filters['cat_id']['values']= (array)$this->bo->acl->get_cats(EGW_ACL_READ); + $filters['cat_id']['values']= (array)$this->bo->acl->get_cats(Acl::READ); // Add in resources / accessories $filters['filter2'] = array( diff --git a/resources/inc/class.resources_hooks.inc.php b/resources/inc/class.resources_hooks.inc.php index d0c120569b..b144f359cb 100644 --- a/resources/inc/class.resources_hooks.inc.php +++ b/resources/inc/class.resources_hooks.inc.php @@ -10,6 +10,11 @@ * @version $Id$ */ +use EGroupware\Api; +use EGroupware\Api\Framework; +use EGroupware\Api\Egw; +use EGroupware\Api\Acl; + /** * General hook object for resources * It encapsulats all the diffent hook methods @@ -27,17 +32,17 @@ class resources_hooks if ($location == 'sidebox_menu') { // Magic etemplate2 favorites menu (from nextmatch widget) - display_sidebox($appname, lang('Favorites'), egw_framework::favorite_list($appname, 'nextmatch-resources.show.rows-favorite')); + display_sidebox($appname, lang('Favorites'), Framework\Favorites::list_favorites($appname, 'nextmatch-resources.show.rows-favorite')); $title = $GLOBALS['egw_info']['apps']['resources']['title'].' '.lang('Menu'); $file = array( - 'Resources list' => egw::link('/index.php',array( + 'Resources list' => Egw::link('/index.php',array( 'menuaction' => 'resources.resources_ui.index', 'ajax' => 'true')), ); - if($this->acl->get_cats(EGW_ACL_ADD)) + if($this->acl->get_cats(Acl::ADD)) { - $file['Add resource'] = "javascript:egw_openWindowCentered2('".egw::link('/index.php',array( + $file['Add resource'] = "javascript:egw_openWindowCentered2('".Egw::link('/index.php',array( 'menuaction' => 'resources.resources_ui.edit', 'accessory_of' => -1 ),false)."','_blank',800,600,'yes')"; @@ -48,12 +53,12 @@ class resources_hooks if ($GLOBALS['egw_info']['user']['apps']['admin']) { $file = Array( - 'Site Configuration' => egw::link('/index.php','menuaction=admin.admin_config.index&appname=' . $appname.'&ajax=true'), - 'Global Categories' => egw::link('/index.php',array( + 'Site Configuration' => Egw::link('/index.php','menuaction=admin.admin_config.index&appname=' . $appname.'&ajax=true'), + 'Global Categories' => Egw::link('/index.php',array( 'menuaction' => 'admin.admin_categories.index', 'appname' => $appname, 'global_cats'=> true)), - 'Configure Access Permissions' => egw::link('/index.php', + 'Configure Access Permissions' => Egw::link('/index.php', 'menuaction=resources.ui_acl.acllist'), 'Custom Fields'=>egw::link('/index.php', 'menuaction=admin.customfields.index&appname=resources'), @@ -112,14 +117,14 @@ class resources_hooks */ function delete_category($args) { - $cat = categories::read($args['cat_id']); + $cat = Api\Categories::read($args['cat_id']); if(!$cat) return; // Can't find current cat? if($cat['parent'] == 0) { // No parent, try the default cat from setup - $categories = new categories('', 'resources'); + $categories = new Api\Categories('', 'resources'); $default = $categories->name2id('General resources'); if($default) { @@ -214,7 +219,7 @@ class resources_hooks } /** - * Hook to tell framework we use only global categories (return link data in that case and false otherwise) + * Hook to tell framework we use only global Api\Categories (return link data in that case and false otherwise) * * @param string|array $data hook-data or location * @return boolean|array diff --git a/resources/inc/class.resources_import_csv.inc.php b/resources/inc/class.resources_import_csv.inc.php index 6d7dd00dee..0c32e5f107 100644 --- a/resources/inc/class.resources_import_csv.inc.php +++ b/resources/inc/class.resources_import_csv.inc.php @@ -11,6 +11,7 @@ * @version $Id$ */ +use EGroupware\Api; /** * class to import resources from CSV @@ -191,7 +192,7 @@ class resources_import_csv extends importexport_basic_import_csv { } } default: - throw new egw_exception('Unsupported action'); + throw new Api\Exception('Unsupported action'); } } diff --git a/resources/inc/class.resources_reserve.inc.php b/resources/inc/class.resources_reserve.inc.php index 9fd771ab07..c5c94442c7 100644 --- a/resources/inc/class.resources_reserve.inc.php +++ b/resources/inc/class.resources_reserve.inc.php @@ -10,6 +10,10 @@ * @version $Id$ */ +use EGroupware\Api; +use EGroupware\Api\Link; +use EGroupware\Api\Framework; + class resources_reserve { public function __construct() { @@ -22,7 +26,7 @@ class resources_reserve { */ public function book($content = array(), $arguments = array()) { - egw_framework::validate_file('jscalendar','calendar'); + Framework::includeJS('jscalendar','calendar'); $data = array(); $readonlys = array(); $display_days = $_GET['planner_days'] ? $_GET['planner_days'] : 3; @@ -32,11 +36,11 @@ class resources_reserve { $register_code = ($_GET['confirm'] && preg_match('/^[0-9a-f]{32}$/',$_GET['confirm'])) ? $_GET['confirm'] : false; if($register_code && $registration = registration_bo::confirm($register_code)) { // Get calendar through link - $links = egw_link::get_links('registration', $registration['reg_id'],'calendar'); + $links = Link::get_links('registration', $registration['reg_id'],'calendar'); $bo = new calendar_boupdate(); $data = $bo->read(current($links)); - $addressbook = new addressbook_bo(); + $addressbook = new Api\Contacts(); $data += $addressbook->read(key($data['participant_types']['c'])); // Show date of reservation, so they can see it blocked off @@ -50,7 +54,7 @@ class resources_reserve { 'quantity' => 0 ); calendar_so::split_status($data['participant_types']['r'][$content['resource']], $content['quantity'],$role); - $data['msg']= '<div class="confirm">'.lang('Registration confirmed %1', egw_time::to($data['start'])) .'</div>'; + $data['msg']= '<div class="confirm">'.lang('Registration confirmed %1', Api\DateTime::to($data['start'])) .'</div>'; } else { $data['msg']= '<div class="confirm">'.lang('Unable to process confirmation.').'</div>'; } @@ -83,7 +87,7 @@ class resources_reserve { // Use sitemgr's default appointment length if($GLOBALS['egw_info']['user']['account_lid'] != $GLOBALS['sitemgr_info']['anonymous_user']) { - $preferences = new preferences($GLOBALS['egw']->accounts->name2id($GLOBALS['sitemgr_info']['anonymous_user'])); + $preferences = new Api\Preferences($GLOBALS['egw']->accounts->name2id($GLOBALS['sitemgr_info']['anonymous_user'])); $preferences = $preferences->read_repository(); $duration = $preferences['calendar']['defaultlength'] * 60; } @@ -93,7 +97,7 @@ class resources_reserve { } $end_time = $start_time + $duration; - $config = config::read('registration'); + $config = Api\Config::read('registration'); // Not a user, need contact if($GLOBALS['egw_info']['user']['account_lid'] == $GLOBALS['sitemgr_info']['anonymous_user'] && !$content['contact_id']) @@ -104,14 +108,14 @@ class resources_reserve { $content['private'] = 0; // in case default_private is set } - $addressbook = new addressbook_bo(); + $addressbook = new Api\Contacts(); $contact_fields = $addressbook->contact_fields; unset($contact_fields['email']); // Always present unset($contact_fields['id']); // Address already there if(array_intersect_key($contact_fields,$content)) { $result = $addressbook->save($content); if(!$result) { - throw new egw_exception_no_permission($addressbook->error); + throw new Api\Exception\NoPermission($addressbook->error); return False; } @@ -129,7 +133,7 @@ class resources_reserve { if($contact) { // Make event $event = array( - 'title' => egw_link::title('addressbook', $contact_id), + 'title' => Link::title('addressbook', $contact_id), 'start' => $start_time, 'end' => $end_time, 'participants' => array( @@ -160,7 +164,7 @@ class resources_reserve { $data += $content; $data['msg'] = lang('Please choose a different time:')."\n"; foreach($freetime as $slot) { - $data['msg'] .= egw_time::to($slot['start']) . ' - ' . egw_time::to($slot['end'])."<br />\n"; + $data['msg'] .= Api\DateTime::to($slot['start']) . ' - ' . Api\DateTime::to($slot['end'])."<br />\n"; } } elseif ($preserve['confirmation'] && $contact_id && $result) @@ -175,21 +179,21 @@ class resources_reserve { if(is_numeric($reg_id)) { // Link to event - egw_link::link('registration', $reg_id, 'calendar', $result); + Link::link('registration', $reg_id, 'calendar', $result); $reg = registration_bo::read($reg_id); // Send email $email_info = $config + array( 'title' => $data['name'], - 'subject' => $data['name'] . ' ' . egw_time::to($start_time), + 'subject' => $data['name'] . ' ' . Api\DateTime::to($start_time), 'link' => $preserve['link'], ); if($preserve['email_message']) { $email_info['message'] = lang($preserve['email_message'], - egw_time::to($start_time), + Api\DateTime::to($start_time), $preserve['link'].'&confirm='.$reg['register_code'], - egw_time::to($reg['timestamp']) + Api\DateTime::to($reg['timestamp']) ); } $data['msg'] .= registration_bo::send_confirmation($email_info, $reg); @@ -219,7 +223,7 @@ class resources_reserve { // Use sitemgr's default appointment length if($GLOBALS['egw_info']['user']['account_lid'] != $GLOBALS['sitemgr_info']['anonymous_user']) { - $preferences = new preferences($GLOBALS['egw']->accounts->name2id($GLOBALS['sitemgr_info']['anonymous_user'])); + $preferences = new Api\Preferences($GLOBALS['egw']->accounts->name2id($GLOBALS['sitemgr_info']['anonymous_user'])); $preferences = $preferences->read_repository(); $data['duration'] = $preferences['calendar']['defaultlength']; } @@ -263,7 +267,7 @@ class resources_reserve { } public function ajax_update_planner($resource_id, $date) { - $response = egw_json_response::get(); + $response = Api\Json\Response::get(); $response->assign('exec[planner_div]','innerHTML',$this->get_planner( $resource_id, strtotime('yesterday',$date), @@ -314,7 +318,7 @@ class resources_reserve { public function confirm($registration) { // Get calendar through link - $links = egw_link::get_links('registration', $registration['reg_id'],'calendar'); + $links = Link::get_links('registration', $registration['reg_id'],'calendar'); $bo = new calendar_boupdate(); $event = $bo->read(current($links)); if($registration['status'] == registration_bo::CONFIRMED) diff --git a/resources/inc/class.resources_select_widget.inc.php b/resources/inc/class.resources_select_widget.inc.php deleted file mode 100644 index 69b232c4c7..0000000000 --- a/resources/inc/class.resources_select_widget.inc.php +++ /dev/null @@ -1,106 +0,0 @@ -<?php -/** - * eGroupWare - eTemplate Extension - Resource Select Widgets - * - * @license http://opensource.org/licenses/gpl-license.php GPL - GNU General Public License - * @package resources - * @link http://www.egroupware.org - * @author RalfBecker-AT-outdoor-training.de - * @version $Id$ - */ - -/** - * eTemplate Extension: select a resource - * - * @package resources - */ -class resources_select_widget -{ - /** - * exported methods of this class - * @var array - */ - var $public_functions = array( - 'pre_process' => True, - ); - /** - * availible extensions and there names for the editor - * @var array - */ - var $human_name = 'Select Resources'; - - /** - * Constructor of the extension - * - * @param string $ui '' for html - */ - function resources_select_widget($ui) - { - $this->ui = $ui; - } - - /** - * pre-processing of the extension - * - * This function is called before the extension gets rendered - * - * @param string $name form-name of the control - * @param mixed &$value value / existing content, can be modified - * @param array &$cell array with the widget, can be modified for ui-independent widgets - * @param array &$readonlys names of widgets as key, to be made readonly - * @param mixed &$extension_data data the extension can store persisten between pre- and post-process - * @param object &$tmpl reference to the template we belong too - * @return boolean true if extra label is allowed, false otherwise - */ - function pre_process($name,&$value,&$cell,&$readonlys,&$extension_data,&$tmpl) - { - if ($cell['readonly'] && !is_array($value)) - { - // no acl check here cause names are allways viewable - list($res_id,$quantity) = explode(':',$value); - $data = ExecMethod('resources.resources_bo.get_calendar_info',$res_id); - $cell['type'] = 'label'; - $value = $data[0]['name']. ($data[0]['useable'] > 1 ? ' ['. ($quantity > 1 ? $quantity : 1). '/'. $data[0]['useable']. ']' : ''); - return true; - } - - if (!$GLOBALS['egw_info']['user']['apps']['resources']) - { - $cell = $tmpl->empty_cell(); - $cell['label'] = 'no resources'; - return false; - } - $tpl = new etemplate('resources.resource_selectbox'); - // keep the editor away from the generated tmpls - $tpl->no_onclick = true; - - if ($value) - { - $value = is_array($value) ? $value : explode(',',$value); - foreach((array)$value as $id) - { - list($res_id,$quantity) = explode(':',$id); - $data = ExecMethod('resources.resources_bo.get_calendar_info',$res_id); - $sel_options[$data[0]['res_id'].($quantity > 1 ? (':'.$quantity) : '')] = - $data[0]['name'].' ['.($quantity > 1 ? $quantity : 1).'/'.$data[0]['useable'].']'; - } - $tpl->set_cell_attribute('resources','sel_options',$sel_options); - } - - $tpl->set_cell_attribute('resources','size',(int)$cell['size'].'+'); - $tpl->set_cell_attribute('resources','label',$cell['label']); - $tpl->set_cell_attribute('resources','id','resources_selectbox'); - $tpl->set_cell_attribute('resources','name',$cell['name']); - if ($cell['help']) - { - $tpl->set_cell_attribute('resources','help',$cell['help']); - $tpl->set_cell_attribute('popup','label',$cell['help']); - } - $cell['type'] = 'template'; - $cell['size'] = $cell['label'] = ''; - $cell['name'] = 'resources.resource_selectbox'; - $cell['obj'] =& $tpl; - - return True; // extra Label Ok - } -} diff --git a/resources/inc/class.resources_so.inc.php b/resources/inc/class.resources_so.inc.php index f2d1f65357..305939f335 100755 --- a/resources/inc/class.resources_so.inc.php +++ b/resources/inc/class.resources_so.inc.php @@ -10,13 +10,15 @@ * @version $Id$ */ +use EGroupware\Api; + /** * General storage object for resources * * @author Cornelius Weiss <egw@von-und-zu-weiss.de> * @package resources */ -class resources_so extends so_sql_cf +class resources_so extends Api\Storage { function __construct() { diff --git a/resources/inc/class.resources_tracking.inc.php b/resources/inc/class.resources_tracking.inc.php index f68a99df33..d8ba760538 100644 --- a/resources/inc/class.resources_tracking.inc.php +++ b/resources/inc/class.resources_tracking.inc.php @@ -6,17 +6,18 @@ * @copyright 2012 Nathan Gray * @package resources * @sub-package history - * @see bo_tracking + * @see Api\Storage\Tracking * * @license http://opensource.org/licenses/gpl-license.php GPL - GNU General Public License * @version $Id$ */ +use EGroupware\Api; /** * Resources - tracking object for history */ -class resources_tracking extends bo_tracking +class resources_tracking extends Api\Storage\Tracking { diff --git a/resources/inc/class.resources_ui.inc.php b/resources/inc/class.resources_ui.inc.php index 83e4889278..5aeb05fd7a 100755 --- a/resources/inc/class.resources_ui.inc.php +++ b/resources/inc/class.resources_ui.inc.php @@ -10,6 +10,12 @@ * @version $Id$ */ +use EGroupware\Api; +use EGroupware\Api\Link; +use EGroupware\Api\Framework; +use EGroupware\Api\Acl; +use EGroupware\Api\Etemplate; + /** * General userinterface object for resources * @@ -31,7 +37,7 @@ class resources_ui function __construct() { // print_r($GLOBALS['egw_info']); die(); - $this->tmpl = new etemplate_new('resources.show'); + $this->tmpl = new Etemplate('resources.show'); $this->bo = new resources_bo(); // $this->calui = CreateObject('resources.ui_calviews'); } @@ -49,7 +55,7 @@ class resources_ui { $sessiondata = $content['nm']; unset($sessiondata['rows']); - $GLOBALS['egw']->session->appsession('session_data','resources_index_nm',$sessiondata); + Api\Cache::setSession('resources', 'index_nm', $sessiondata); if (isset($content['btn_delete_selected'])) { @@ -72,7 +78,7 @@ class resources_ui if(isset($row['view_acc'])) { $sessiondata['filter2'] = array_search('pressed',$row['view_acc']); - $GLOBALS['egw']->session->appsession('session_data','resources_index_nm',$sessiondata); + Api\Cache::setSession('resources', 'index_nm', $sessiondata); return $this->index(); } } @@ -116,19 +122,19 @@ class resources_ui $content['nm']['row_id'] = 'res_id'; $content['nm']['favorites'] = true; - $nm_session_data = $GLOBALS['egw']->session->appsession('session_data','resources_index_nm'); + $nm_session_data = Api\Cache::getSession('resources', 'index_nm'); if($nm_session_data) { $content['nm'] = $nm_session_data; } - $content['nm']['options-filter']= array(''=>lang('all categories'))+(array)$this->bo->acl->get_cats(EGW_ACL_READ); + $content['nm']['options-filter']= array(''=>lang('all categories'))+(array)$this->bo->acl->get_cats(Acl::READ); $content['nm']['options-filter2'] = resources_bo::$filter_options; if(!$content['nm']['filter2']) { $content['nm']['filter2'] = key(resources_bo::$filter_options); } - $config = config::read('resources'); + $config = Api\Config::read('resources'); if($config['history']) { $content['nm']['options-filter2'][resources_bo::DELETED] = lang('Deleted'); @@ -146,14 +152,14 @@ class resources_ui // check if user is permitted to add resources // If they can't read any categories, they won't be able to save it - if(!$this->bo->acl->get_cats(EGW_ACL_ADD) || !$this->bo->acl->get_cats(EGW_ACL_READ)) + if(!$this->bo->acl->get_cats(Acl::ADD) || !$this->bo->acl->get_cats(Acl::READ)) { $no_button['add'] = $no_button['nm']['add'] = true; } $no_button['back'] = true; $GLOBALS['egw_info']['flags']['app_header'] = lang('resources'); - egw_framework::validate_file('.','resources','resources'); + Framework::includeJS('.','resources','resources'); if($content['nm']['filter2'] > 0) { @@ -169,7 +175,7 @@ class resources_ui $options = array(); - $GLOBALS['egw']->session->appsession('session_data','resources_index_nm',$content['nm']); + Api\Cache::setSession('resources', 'index_nm', $content['nm']); $this->tmpl->read('resources.show'); return $this->tmpl->exec('resources.resources_ui.index',$content,$sel_options,$no_button,$preserv); } @@ -187,14 +193,14 @@ class resources_ui 'caption' => 'open', 'allowOnMultiple' => false, 'url' => 'menuaction=resources.resources_ui.edit&res_id=$id', - 'popup' => egw_link::get_registry('resources', 'add_popup'), + 'popup' => Link::get_registry('resources', 'add_popup'), 'group' => $group=1, 'disableClass' => 'rowNoEdit', ), 'add' => array( 'caption' => 'New resource', 'url' => 'menuaction=resources.resources_ui.edit&accessory_of=-1', - 'popup' => egw_link::get_registry('resources', 'add_popup'), + 'popup' => Link::get_registry('resources', 'add_popup'), 'group' => $group, 'hideOnMobile' => true ), @@ -211,7 +217,7 @@ class resources_ui 'icon' => 'new', 'group' => $group, 'url' => 'menuaction=resources.resources_ui.edit&res_id=0&accessory_of=$id', - 'popup' => egw_link::get_registry('resources', 'add_popup'), + 'popup' => Link::get_registry('resources', 'add_popup'), 'disableClass' => 'no_new_accessory', 'allowOnMultiple' => false ), @@ -458,16 +464,16 @@ class resources_ui break; } } - egw_framework::refresh_opener($msg, 'resources',$content['res_id'],($button == 'delete'?'delete':'edit')); + Framework::refresh_opener($msg, 'resources',$content['res_id'],($button == 'delete'?'delete':'edit')); if($button != 'apply') { - egw_framework::window_close(); + Framework::window_close(); } } - $nm_session_data = $GLOBALS['egw']->session->appsession('session_data','resources_index_nm'); + $nm_session_data = Api\Cache::getSession('resources', 'index_nm'); $res_id = is_numeric($content) ? (int)$content : $content['res_id']; if (isset($_GET['res_id'])) $res_id = $_GET['res_id']; if (isset($nm_session_data['filter2']) && $nm_session_data['filter2'] > 0) $accessory_of = $nm_session_data['filter2']; @@ -520,7 +526,7 @@ class resources_ui $sel_options['status'] = resources_bo::$field2label; //$sel_options['gen_src_list'] = $this->bo->get_genpicturelist(); - $sel_options['cat_id'] = $this->bo->acl->get_cats(EGW_ACL_ADD); + $sel_options['cat_id'] = $this->bo->acl->get_cats(Acl::ADD); $sel_options['cat_id'] = count($sel_options['cat_id']) == 1 ? $sel_options['cat_id'] : array('' => lang('select one')) + $sel_options['cat_id']; if($accessory_of > 0 || $content['accessory_of'] > 0) @@ -545,12 +551,12 @@ class resources_ui // Permissions $read_only = array(); - if($res_id && !$this->bo->acl->is_permitted($content['cat_id'],EGW_ACL_EDIT)) + if($res_id && !$this->bo->acl->is_permitted($content['cat_id'],Acl::EDIT)) { $read_only['__ALL__'] = true; } - $config = config::read('resources'); - if(!$this->bo->acl->is_permitted($content['cat_id'],EGW_ACL_DELETE) || + $config = Api\Config::read('resources'); + if(!$this->bo->acl->is_permitted($content['cat_id'],Acl::DELETE) || ($content['deleted'] && !$GLOBALS['egw_info']['user']['apps']['admin'] && $config['history'] == 'history')) { $read_only['delete'] = true; @@ -564,7 +570,7 @@ class resources_ui } // Disable custom tab if there are no custom fields defined - $read_only['tabs']['custom'] = !(config::get_customfields('resources',true)); + $read_only['tabs']['custom'] = !(Api\Storage\Customfields::get('resources',true)); $read_only['tabs']['history'] = ($content['history']['id'] != 0?false:true); $preserv = $content; diff --git a/resources/inc/class.resources_wizard_export_csv.inc.php b/resources/inc/class.resources_wizard_export_csv.inc.php index da05adbb25..f0316461b9 100644 --- a/resources/inc/class.resources_wizard_export_csv.inc.php +++ b/resources/inc/class.resources_wizard_export_csv.inc.php @@ -10,6 +10,8 @@ * @version $Id$ */ +use EGroupware\Api; + class resources_wizard_export_csv extends importexport_wizard_basic_export_csv { public function __construct() { @@ -23,7 +25,7 @@ class resources_wizard_export_csv extends importexport_wizard_basic_export_csv unset($this->export_fields['prize']); // Custom fields - $custom = config::get_customfields('resources', true); + $custom = Api\Storage\Customfields::get('resources', true); foreach($custom as $name => $data) { $this->export_fields['#'.$name] = $data['label']; } diff --git a/resources/inc/class.resources_wizard_import_csv.inc.php b/resources/inc/class.resources_wizard_import_csv.inc.php index 7115a91767..9ea071ec94 100644 --- a/resources/inc/class.resources_wizard_import_csv.inc.php +++ b/resources/inc/class.resources_wizard_import_csv.inc.php @@ -10,6 +10,8 @@ * @version $Id$ */ +use EGroupware\Api; + class resources_wizard_import_csv extends importexport_wizard_basic_import_csv { @@ -44,7 +46,7 @@ class resources_wizard_import_csv extends importexport_wizard_basic_import_csv 'accessory_of' => lang('Accessory of') ); - $custom = config::get_customfields('resources', true); + $custom = Api\Storage\Customfields::get('resources', true); foreach($custom as $name => $data) { $this->mapping_fields['#'.$name] = $data['label']; } diff --git a/resources/inc/class.ui_acl.inc.php b/resources/inc/class.ui_acl.inc.php index e085adc40e..4f945c3063 100755 --- a/resources/inc/class.ui_acl.inc.php +++ b/resources/inc/class.ui_acl.inc.php @@ -2,12 +2,16 @@ /** * eGroupWare - resources * - * @license http://www.gnu.org/licenses/gpl.html GNU General Public License + * @license http://www.gnu.org/licenses/gpl.Api\Html GNU General Public License * @package resources * @link http://www.egroupware.org * @version $Id$ */ +use EGroupware\Api; +use EGroupware\Api\Egw; +use EGroupware\Api\Acl; + /** * ACL userinterface object for resources * @@ -46,10 +50,10 @@ class ui_acl if ($_POST['btnDone']) { - egw::redirect_link('/admin/index.php'); + Egw::redirect_link('/admin/index.php'); } - common::egw_header(); + $GLOBALS['egw']->framework->header(); echo parse_navbar(); if ($_POST['btnSave']) @@ -59,7 +63,7 @@ class ui_acl $this->bo->set_rights($cat_id,$_POST['inputread'][$cat_id],$_POST['inputwrite'][$cat_id], $_POST['inputcalread'][$cat_id],$_POST['inputcalbook'][$cat_id],$_POST['inputadmin'][$cat_id]); } - config::save_value('location_cats', implode(',', $_POST['location_cats']), 'resources'); + Api\Config::save_value('location_cats', implode(',', $_POST['location_cats']), 'resources'); } $template =& CreateObject('phpgwapi.Template',EGW_APP_TPL); $template->set_file(array('acl' => 'acl.tpl')); @@ -95,7 +99,7 @@ class ui_acl if ($this->bo->cats) { - $config = config::read('resources'); + $config = Api\Config::read('resources'); $location_cats = $config['location_cats'] ? explode(',', $config['location_cats']) : array(); foreach($this->bo->cats as $cat) { @@ -106,11 +110,11 @@ class ui_acl 'tr_color' => $tr_color, 'catname' => $cat['name'], 'catid' => $cat['id'], - 'read' => $this->selectlist(EGW_ACL_READ), - 'write' => $this->selectlist(EGW_ACL_ADD), + 'read' => $this->selectlist(Acl::READ), + 'write' => $this->selectlist(Acl::ADD), 'calread' => $this->selectlist(EGW_ACL_CALREAD), 'calbook' =>$this->selectlist(EGW_ACL_DIRECT_BOOKING), - 'admin' => '<option value="" selected="1">'.lang('choose categories admin').'</option>'.$this->selectlist(EGW_ACL_CAT_ADMIN,true), + 'admin' => '<option value="" selected="1">'.lang('choose Api\Categories admin').'</option>'.$this->selectlist(EGW_ACL_CAT_ADMIN,true), 'location_checked' => in_array($cat['id'], $location_cats) ? 'checked="1"' : '', )); $template->parse('Cblock','cat_list',True); @@ -167,7 +171,7 @@ class ui_acl { $selectlist .= ' selected="selected"'; } - $selectlist .= '>' . common::display_fullname($account['account_lid'],$account['account_firstname'], + $selectlist .= '>' . Api\Accounts::format_username($account['account_lid'],$account['account_firstname'], $account['account_lastname'],$account['account_id']) . '</option>' . "\n"; } return $selectlist; @@ -200,6 +204,6 @@ class ui_acl function deny() { echo '<p><center><b>'.lang('Access not permitted').'</b></center>'; - common::egw_exit(True); + exit(True); } } diff --git a/resources/setup/default_records.inc.php b/resources/setup/default_records.inc.php index 52d75c93fc..fa8c7f9436 100644 --- a/resources/setup/default_records.inc.php +++ b/resources/setup/default_records.inc.php @@ -9,14 +9,16 @@ * @version $Id$ */ +use EGroupware\Api; + $resources_table_prefix = 'egw_resources'; // Add a general category for resources -$GLOBALS['egw_setup']->db->insert($GLOBALS['egw_setup']->cats_table,array('cat_parent' => 0, 'cat_owner' => categories::GLOBAL_ACCOUNT,'cat_access' => 'public','cat_appname' => 'resources','cat_name' => 'General resources','cat_description' => 'This category has been added by setup','last_mod' => time()),false,__LINE__,__FILE__); +$GLOBALS['egw_setup']->db->insert($GLOBALS['egw_setup']->cats_table,array('cat_parent' => 0, 'cat_owner' => Api\Categories::GLOBAL_ACCOUNT,'cat_access' => 'public','cat_appname' => 'resources','cat_name' => 'General resources','cat_description' => 'This category has been added by setup','last_mod' => time()),false,__LINE__,__FILE__); $cat_id = $GLOBALS['egw_setup']->db->get_last_insert_id($GLOBALS['egw_setup']->cats_table,'cat_id'); -$GLOBALS['egw_setup']->db->insert($GLOBALS['egw_setup']->cats_table,array('cat_parent' => 0, 'cat_owner' => categories::GLOBAL_ACCOUNT,'cat_access' => 'public','cat_appname' => 'resources','cat_name' => 'Locations','cat_description' => 'This category has been added by setup','last_mod' => time()),false,__LINE__,__FILE__); +$GLOBALS['egw_setup']->db->insert($GLOBALS['egw_setup']->cats_table,array('cat_parent' => 0, 'cat_owner' => Api\Categories::GLOBAL_ACCOUNT,'cat_access' => 'public','cat_appname' => 'resources','cat_name' => 'Locations','cat_description' => 'This category has been added by setup','last_mod' => time()),false,__LINE__,__FILE__); $locations_cat_id = $GLOBALS['egw_setup']->db->get_last_insert_id($GLOBALS['egw_setup']->cats_table,'cat_id'); -config::save_value('location_cats', $locations_cat_id, 'resources'); +Api\Config::save_value('location_cats', $locations_cat_id, 'resources'); // Give default group all rights to this general cat $defaultgroup = $GLOBALS['egw_setup']->add_account('Default','Default','Group',False,False); diff --git a/resources/setup/etemplates.inc.php b/resources/setup/etemplates.inc.php deleted file mode 100644 index ae12275cae..0000000000 --- a/resources/setup/etemplates.inc.php +++ /dev/null @@ -1,96 +0,0 @@ -<?php -/** - * EGroupware - eTemplates for Application resources - * http://www.egroupware.org - * generated by soetemplate::dump4setup() 2013-07-08 09:03 - * - * @license http://opensource.org/licenses/gpl-license.php GPL - GNU General Public License - * @package resources - * @subpackage setup - * @version $Id$ - */ - -$templ_version=1; - -$templ_data[] = array('name' => 'resources.add','template' => '','lang' => '','group' => '0','version' => '','data' => 'a:1:{i:0;a:5:{s:4:"type";s:4:"grid";s:4:"data";a:3:{i:0;a:0:{}i:1;a:1:{s:1:"A";a:2:{s:4:"type";s:8:"template";s:4:"name";s:19:"resources.edit_tabs";}}i:2;a:1:{s:1:"A";a:2:{s:4:"type";s:8:"template";s:4:"name";s:21:"resources.add_buttons";}}}s:4:"rows";i:2;s:4:"cols";i:1;s:4:"size";s:4:"100%";}}','size' => '100%','style' => '','modified' => '1094579218',); - -$templ_data[] = array('name' => 'resources.add_buttons','template' => '','lang' => '','group' => '0','version' => '','data' => 'a:1:{i:0;a:5:{s:4:"type";s:4:"grid";s:4:"data";a:2:{i:0;a:1:{s:1:"C";s:4:"100%";}i:1;a:3:{s:1:"A";a:4:{s:4:"type";s:6:"button";s:5:"label";s:4:"Save";s:4:"name";s:4:"save";s:4:"help";s:21:"Saves entry and exits";}s:1:"B";a:3:{s:4:"type";s:6:"button";s:5:"label";s:6:"Cancel";s:4:"name";s:6:"cancel";}s:1:"C";a:2:{s:4:"type";s:5:"label";s:5:"align";s:5:"right";}}}s:4:"rows";i:1;s:4:"cols";i:3;s:4:"size";s:4:"100%";}}','size' => '100%','style' => '','modified' => '1094579498',); - -$templ_data[] = array('name' => 'resources.admin','template' => '','lang' => '','group' => '0','version' => '','data' => 'a:1:{i:0;a:4:{s:4:"type";s:4:"grid";s:4:"data";a:3:{i:0;a:0:{}i:1;a:1:{s:1:"A";a:3:{s:4:"type";s:8:"checkbox";s:5:"label";s:55:"Don\'t use vfs (this will need a symlink --> see README)";s:4:"name";s:12:"dont_use_vfs";}}i:2;a:1:{s:1:"A";a:4:{s:4:"type";s:4:"hbox";s:4:"size";s:1:"2";i:1;a:3:{s:4:"type";s:6:"button";s:5:"label";s:4:"Save";s:4:"name";s:4:"save";}i:2;a:3:{s:4:"type";s:6:"button";s:5:"label";s:6:"Cancel";s:4:"name";s:6:"cancel";}}}}s:4:"rows";i:2;s:4:"cols";i:1;}}','size' => '','style' => '','modified' => '1109673054',); - -$templ_data[] = array('name' => 'resources.edit','template' => '','lang' => '','group' => '0','version' => '1.9.002','data' => 'a:1:{i:0;a:4:{s:4:"type";s:4:"grid";s:4:"data";a:5:{i:0;a:2:{s:1:"A";s:3:"700";s:2:"h1";s:6:",!@msg";}i:1;a:1:{s:1:"A";a:4:{s:4:"type";s:5:"label";s:7:"no_lang";s:1:"1";s:4:"name";s:3:"msg";s:4:"span";s:11:"all,message";}}i:2;a:1:{s:1:"A";a:5:{s:4:"type";s:4:"hbox";s:4:"size";s:1:"3";i:1;a:5:{s:4:"type";s:4:"text";s:5:"label";s:4:"Name";s:4:"name";s:4:"name";s:4:"help";s:16:"Name of resource";s:6:"needed";s:1:"1";}i:2;a:3:{s:4:"type";s:4:"text";s:5:"label";s:16:"Inventory number";s:4:"name";s:16:"inventory_number";}i:3;a:7:{s:4:"type";s:6:"select";s:5:"label";s:8:"Category";s:7:"no_lang";s:1:"1";s:4:"name";s:6:"cat_id";s:6:"needed";s:1:"1";s:4:"help";s:44:"Which category does this resource belong to?";s:5:"align";s:5:"right";}}}i:3;a:1:{s:1:"A";a:2:{s:4:"type";s:8:"template";s:4:"name";s:19:"resources.edit_tabs";}}i:4;a:1:{s:1:"A";a:2:{s:4:"type";s:8:"template";s:4:"name";s:22:"resources.edit_buttons";}}}s:4:"rows";i:4;s:4:"cols";i:1;}}','size' => '','style' => '','modified' => '1357664574',); - -$templ_data[] = array('name' => 'resources.edit.accessories','template' => '','lang' => '','group' => '0','version' => '','data' => 'a:1:{i:0;a:4:{s:4:"type";s:4:"grid";s:4:"data";a:2:{i:0;a:0:{}i:1;a:1:{s:1:"A";a:3:{s:4:"type";s:9:"nextmatch";s:4:"name";s:2:"nm";s:4:"size";s:19:"resources.show.rows";}}}s:4:"rows";i:1;s:4:"cols";i:1;}}','size' => '','style' => '','modified' => '1352913344',); - -$templ_data[] = array('name' => 'resources.edit.custom','template' => '','lang' => '','group' => '0','version' => '1.9.001','data' => 'a:1:{i:0;a:6:{s:4:"type";s:4:"grid";s:4:"data";a:3:{i:0;a:1:{s:2:"c1";s:4:",top";}i:1;a:1:{s:1:"A";a:1:{s:4:"type";s:12:"customfields";}}i:2;a:1:{s:1:"A";a:1:{s:4:"type";s:5:"label";}}}s:4:"rows";i:2;s:4:"cols";i:1;s:4:"size";s:7:"700,380";s:7:"options";a:2:{i:0;s:3:"700";i:1;s:3:"380";}}}','size' => '700,380','style' => '','modified' => '1352913557',); - -$templ_data[] = array('name' => 'resources.edit.general','template' => '','lang' => '','group' => '0','version' => '1.9.001','data' => 'a:1:{i:0;a:6:{s:4:"type";s:4:"grid";s:4:"data";a:9:{i:0;a:2:{s:1:"C";s:2:"10";s:2:"h8";s:4:"100%";}i:1;a:4:{s:1:"A";a:2:{s:4:"type";s:5:"label";s:5:"label";s:19:"Description (short)";}s:1:"B";a:4:{s:4:"type";s:4:"text";s:4:"size";s:6:"50,100";s:4:"name";s:17:"short_description";s:4:"help";s:29:"Short description of resource";}s:1:"C";a:1:{s:4:"type";s:5:"label";}s:1:"D";a:2:{s:4:"type";s:5:"label";s:5:"label";s:29:"Short description of resource";}}i:2;a:4:{s:1:"A";a:2:{s:4:"type";s:5:"label";s:5:"label";s:8:"Location";}s:1:"B";a:4:{s:4:"type";s:4:"text";s:4:"size";s:6:"50,100";s:4:"name";s:8:"location";s:4:"help";s:20:"Location of resource";}s:1:"C";a:1:{s:4:"type";s:5:"label";}s:1:"D";a:2:{s:4:"type";s:5:"label";s:5:"label";s:28:"Where to find this resource?";}}i:3;a:4:{s:1:"A";a:2:{s:4:"type";s:5:"label";s:5:"label";s:19:"Storage information";}s:1:"B";a:4:{s:4:"type";s:4:"text";s:4:"size";s:6:"50,100";s:4:"name";s:12:"storage_info";s:4:"help";s:25:"Information about storage";}s:1:"C";a:1:{s:4:"type";s:5:"label";}s:1:"D";a:2:{s:4:"type";s:5:"label";s:5:"label";s:25:"Information about storage";}}i:4;a:4:{s:1:"A";a:2:{s:4:"type";s:5:"label";s:5:"label";s:8:"Quantity";}s:1:"B";a:4:{s:4:"type";s:4:"text";s:4:"size";s:4:"5,10";s:4:"name";s:8:"quantity";s:4:"help";s:20:"Quantity of resource";}s:1:"C";a:1:{s:4:"type";s:5:"label";}s:1:"D";a:2:{s:4:"type";s:5:"label";s:5:"label";s:20:"Quantity of resource";}}i:5;a:4:{s:1:"A";a:2:{s:4:"type";s:5:"label";s:5:"label";s:7:"Useable";}s:1:"B";a:4:{s:4:"type";s:4:"text";s:4:"size";s:4:"5,10";s:4:"name";s:7:"useable";s:4:"help";s:29:"How many of them are useable?";}s:1:"C";a:1:{s:4:"type";s:5:"label";}s:1:"D";a:2:{s:4:"type";s:5:"label";s:5:"label";s:38:"How many of the resources are useable?";}}i:6;a:4:{s:1:"A";a:2:{s:4:"type";s:5:"label";s:5:"label";s:8:"Bookable";}s:1:"B";a:3:{s:4:"type";s:8:"checkbox";s:4:"name";s:8:"bookable";s:4:"help";s:21:"Is resource bookable?";}s:1:"C";a:1:{s:4:"type";s:5:"label";}s:1:"D";a:2:{s:4:"type";s:5:"label";s:5:"label";s:26:"Is this resource bookable?";}}i:7;a:4:{s:1:"A";a:2:{s:4:"type";s:5:"label";s:5:"label";s:12:"Accessory of";}s:1:"B";a:3:{s:4:"type";s:6:"select";s:4:"name";s:12:"accessory_of";s:4:"size";s:4:"None";}s:1:"C";a:1:{s:4:"type";s:5:"label";}s:1:"D";a:1:{s:4:"type";s:5:"label";}}i:8;a:4:{s:1:"A";a:3:{s:4:"type";s:5:"label";s:5:"label";s:7:"Buyable";s:8:"disabled";s:1:"1";}s:1:"B";a:4:{s:4:"type";s:8:"checkbox";s:4:"name";s:7:"buyable";s:4:"help";s:20:"Is resource buyable?";s:8:"disabled";s:1:"1";}s:1:"C";a:1:{s:4:"type";s:5:"label";}s:1:"D";a:3:{s:4:"type";s:5:"label";s:5:"label";s:25:"Is this resource buyable?";s:8:"disabled";s:1:"1";}}}s:4:"rows";i:8;s:4:"cols";i:4;s:4:"size";s:7:"700,380";s:7:"options";a:2:{i:0;s:3:"700";i:1;s:3:"380";}}}','size' => '700,380','style' => '','modified' => '1352913589',); - -$templ_data[] = array('name' => 'resources.edit.links','template' => '','lang' => '','group' => '0','version' => '1.9.001','data' => 'a:1:{i:0;a:6:{s:4:"type";s:4:"grid";s:4:"data";a:6:{i:0;a:7:{s:1:"A";s:3:"100";s:2:"c1";s:2:"th";s:2:"c2";s:3:"row";s:2:"c3";s:2:"th";s:2:"c4";s:11:"row_off,top";s:2:"h4";s:3:"164";s:2:"h5";s:4:"100%";}i:1;a:2:{s:1:"A";a:3:{s:4:"type";s:5:"label";s:4:"span";s:3:"all";s:5:"label";s:16:"Create new links";}s:1:"B";a:1:{s:4:"type";s:5:"label";}}i:2;a:2:{s:1:"A";a:3:{s:4:"type";s:7:"link-to";s:4:"span";s:3:"all";s:4:"name";s:7:"link_to";}s:1:"B";a:1:{s:4:"type";s:5:"label";}}i:3;a:2:{s:1:"A";a:3:{s:4:"type";s:5:"label";s:4:"span";s:3:"all";s:5:"label";s:14:"Existing links";}s:1:"B";a:1:{s:4:"type";s:5:"label";}}i:4;a:2:{s:1:"A";a:3:{s:4:"type";s:9:"link-list";s:4:"span";s:3:"all";s:4:"name";s:7:"link_to";}s:1:"B";a:1:{s:4:"type";s:5:"label";}}i:5;a:2:{s:1:"A";a:1:{s:4:"type";s:5:"label";}s:1:"B";a:1:{s:4:"type";s:5:"label";}}}s:4:"rows";i:5;s:4:"cols";i:2;s:4:"size";s:7:"700,380";s:7:"options";a:2:{i:0;s:3:"700";i:1;s:3:"380";}}}','size' => '700,380','style' => '','modified' => '1352913520',); - -$templ_data[] = array('name' => 'resources.edit.page','template' => '','lang' => '','group' => '0','version' => '1.9.001','data' => 'a:1:{i:0;a:6:{s:4:"type";s:4:"grid";s:4:"data";a:2:{i:0;a:1:{s:2:"c1";s:4:",top";}i:1;a:1:{s:1:"A";a:4:{s:4:"type";s:8:"htmlarea";s:4:"name";s:16:"long_description";s:4:"help";s:26:"Web-Site for this resource";s:4:"size";s:23:"simple,350px,700px,true";}}}s:4:"rows";i:1;s:4:"cols";i:1;s:4:"size";s:8:"100%,380";s:7:"options";a:2:{i:0;s:4:"100%";i:1;s:3:"380";}}}','size' => '100%,380','style' => '','modified' => '1352913491',); - -$templ_data[] = array('name' => 'resources.edit.pictures','template' => '','lang' => '','group' => '0','version' => '1.9.001','data' => 'a:1:{i:0;a:6:{s:4:"type";s:4:"grid";s:4:"data";a:3:{i:0;a:2:{s:2:"c1";s:4:",top";s:2:"h2";s:4:"100%";}i:1;a:1:{s:1:"A";a:4:{s:4:"type";s:4:"hbox";s:4:"size";s:1:"2";i:1;a:4:{s:4:"type";s:4:"vbox";s:4:"size";s:1:"2";i:1;a:2:{s:4:"type";s:5:"image";s:4:"name";s:16:"resource_picture";}i:2;a:1:{s:4:"type";s:5:"label";}}i:2;a:4:{s:4:"type";s:8:"groupbox";s:4:"size";s:1:"1";i:1;a:4:{s:4:"type";s:4:"grid";s:4:"data";a:4:{i:0;a:0:{}i:1;a:3:{s:1:"A";a:3:{s:4:"type";s:5:"label";s:5:"label";s:26:"Use general resources icon";s:5:"align";s:5:"right";}s:1:"B";a:3:{s:4:"type";s:5:"radio";s:4:"size";s:7:"gen_src";s:4:"name";s:11:"picture_src";}s:1:"C";a:3:{s:4:"type";s:6:"select";s:7:"no_lang";s:1:"1";s:4:"name";s:12:"gen_src_list";}}i:2;a:3:{s:1:"A";a:3:{s:4:"type";s:5:"label";s:5:"label";s:23:"Use the category\'s icon";s:5:"align";s:5:"right";}s:1:"B";a:3:{s:4:"type";s:5:"radio";s:4:"size";s:7:"cat_src";s:4:"name";s:11:"picture_src";}s:1:"C";a:1:{s:4:"type";s:5:"label";}}i:3;a:3:{s:1:"A";a:3:{s:4:"type";s:5:"label";s:5:"label";s:15:"Use own picture";s:5:"align";s:5:"right";}s:1:"B";a:3:{s:4:"type";s:5:"radio";s:4:"size";s:7:"own_src";s:4:"name";s:11:"picture_src";}s:1:"C";a:2:{s:4:"type";s:4:"file";s:4:"name";s:8:"own_file";}}}s:4:"rows";i:3;s:4:"cols";i:3;}s:5:"label";s:14:"picture source";}}}i:2;a:1:{s:1:"A";a:1:{s:4:"type";s:5:"label";}}}s:4:"rows";i:2;s:4:"cols";i:1;s:4:"size";s:7:"700,380";s:7:"options";a:2:{i:0;s:3:"700";i:1;s:3:"380";}}}','size' => '700,380','style' => '','modified' => '1352913451',); - -$templ_data[] = array('name' => 'resources.edit_buttons','template' => '','lang' => '','group' => '0','version' => '','data' => 'a:1:{i:0;a:7:{s:4:"type";s:4:"grid";s:4:"data";a:2:{i:0;a:1:{s:1:"D";s:4:"100%";}i:1;a:4:{s:1:"A";a:6:{s:4:"type";s:4:"hbox";s:4:"size";s:1:"3";i:1;a:4:{s:4:"type";s:6:"button";s:5:"label";s:4:"Save";s:4:"name";s:4:"save";s:4:"help";s:21:"Saves entry and exits";}i:2;a:3:{s:4:"type";s:6:"button";s:5:"label";s:5:"Apply";s:4:"name";s:5:"apply";}s:4:"span";s:1:"3";i:3;a:3:{s:4:"type";s:6:"button";s:5:"label";s:6:"Cancel";s:7:"onclick";s:15:"window.close();";}}s:1:"B";a:1:{s:4:"type";s:5:"label";}s:1:"C";a:1:{s:4:"type";s:5:"label";}s:1:"D";a:5:{s:4:"type";s:6:"button";s:5:"label";s:6:"Delete";s:5:"align";s:5:"right";s:4:"name";s:6:"delete";s:7:"onclick";s:61:"return confirm(\'Do you really want do delte this resource?\');";}}}s:4:"rows";i:1;s:4:"cols";i:4;s:4:"size";s:4:"100%";s:4:"name";s:6:"button";s:7:"options";a:1:{i:0;s:4:"100%";}}}','size' => '100%','style' => '','modified' => '1093597552',); - -$templ_data[] = array('name' => 'resources.edit_pictures','template' => '','lang' => '','group' => '0','version' => '','data' => 'a:1:{i:0;a:4:{s:4:"type";s:4:"grid";s:4:"data";a:4:{i:0;a:3:{s:2:"c1";s:3:"nmr";s:2:"c2";s:3:"nmr";s:2:"c3";s:3:"nmr";}i:1;a:3:{s:1:"A";a:3:{s:4:"type";s:5:"label";s:5:"label";s:26:"Use general resources icon";s:5:"align";s:5:"right";}s:1:"B";a:3:{s:4:"type";s:5:"radio";s:4:"size";s:7:"gen_src";s:4:"name";s:11:"picture_src";}s:1:"C";a:3:{s:4:"type";s:6:"select";s:7:"no_lang";s:1:"1";s:4:"name";s:12:"gen_src_list";}}i:2;a:3:{s:1:"A";a:3:{s:4:"type";s:5:"label";s:5:"label";s:23:"Use the category\'s icon";s:5:"align";s:5:"right";}s:1:"B";a:3:{s:4:"type";s:5:"radio";s:4:"size";s:7:"cat_src";s:4:"name";s:11:"picture_src";}s:1:"C";a:1:{s:4:"type";s:5:"label";}}i:3;a:3:{s:1:"A";a:3:{s:4:"type";s:5:"label";s:5:"label";s:15:"Use own picture";s:5:"align";s:5:"right";}s:1:"B";a:3:{s:4:"type";s:5:"radio";s:4:"size";s:7:"own_src";s:4:"name";s:11:"picture_src";}s:1:"C";a:2:{s:4:"type";s:4:"file";s:4:"name";s:8:"own_file";}}}s:4:"rows";i:3;s:4:"cols";i:3;}}','size' => '','style' => '','modified' => '1108638846',); - -$templ_data[] = array('name' => 'resources.edit_tabs','template' => '','lang' => '','group' => '0','version' => '','data' => 'a:1:{i:0;a:6:{s:4:"type";s:4:"grid";s:4:"data";a:3:{i:0;a:3:{s:2:"c1";s:7:"row_off";s:1:"A";s:3:"700";s:2:"h2";s:4:"100%";}i:1;a:3:{s:1:"A";a:5:{s:4:"type";s:3:"tab";s:4:"span";s:3:"all";s:5:"label";s:48:"General|Description|Picture|Links|Custom|History";s:4:"name";s:47:"tabs=general|page|pictures|links|custom|history";s:4:"help";s:164:"General informations about resource|Informations about the location of resource|Prizeing information for booking or buying|Web-Page of resource|Pictures or resource";}s:1:"B";a:1:{s:4:"type";s:5:"label";}s:1:"C";a:1:{s:4:"type";s:5:"label";}}i:2;a:3:{s:1:"A";a:2:{s:4:"type";s:5:"label";s:4:"span";s:3:"all";}s:1:"B";a:1:{s:4:"type";s:5:"label";}s:1:"C";a:1:{s:4:"type";s:5:"label";}}}s:4:"rows";i:2;s:4:"cols";i:3;s:4:"size";s:4:",380";s:7:"options";a:1:{i:1;s:3:"380";}}}','size' => ',380','style' => '','modified' => '1116664222',); - -$templ_data[] = array('name' => 'resources.edit_tabs.accessories','template' => '','lang' => '','group' => '0','version' => '','data' => 'a:1:{i:0;a:4:{s:4:"type";s:4:"grid";s:4:"data";a:2:{i:0;a:0:{}i:1;a:1:{s:1:"A";a:3:{s:4:"type";s:9:"nextmatch";s:4:"name";s:2:"nm";s:4:"size";s:19:"resources.show.rows";}}}s:4:"rows";i:1;s:4:"cols";i:1;}}','size' => '','style' => '','modified' => '1109668181',); - -$templ_data[] = array('name' => 'resources.edit_tabs.custom','template' => '','lang' => '','group' => '0','version' => '','data' => 'a:1:{i:0;a:6:{s:4:"type";s:4:"grid";s:4:"data";a:3:{i:0;a:1:{s:2:"c1";s:4:",top";}i:1;a:1:{s:1:"A";a:1:{s:4:"type";s:12:"customfields";}}i:2;a:1:{s:1:"A";a:1:{s:4:"type";s:5:"label";}}}s:4:"rows";i:2;s:4:"cols";i:1;s:4:"size";s:7:"700,380";s:7:"options";a:2:{i:0;s:3:"700";i:1;s:3:"380";}}}','size' => '700,380','style' => '','modified' => '1131988154',); - -$templ_data[] = array('name' => 'resources.edit_tabs.general','template' => '','lang' => '','group' => '0','version' => '','data' => 'a:1:{i:0;a:6:{s:4:"type";s:4:"grid";s:4:"data";a:10:{i:0;a:2:{s:1:"C";s:2:"10";s:2:"h9";s:4:"100%";}i:1;a:4:{s:1:"A";a:2:{s:4:"type";s:5:"label";s:5:"label";s:19:"Description (short)";}s:1:"B";a:4:{s:4:"type";s:4:"text";s:4:"size";s:6:"50,100";s:4:"name";s:17:"short_description";s:4:"help";s:29:"Short description of resource";}s:1:"C";a:1:{s:4:"type";s:5:"label";}s:1:"D";a:2:{s:4:"type";s:5:"label";s:5:"label";s:29:"Short description of resource";}}i:2;a:4:{s:1:"A";a:2:{s:4:"type";s:5:"label";s:5:"label";s:8:"Location";}s:1:"B";a:4:{s:4:"type";s:4:"text";s:4:"size";s:6:"50,100";s:4:"name";s:8:"location";s:4:"help";s:20:"Location of resource";}s:1:"C";a:1:{s:4:"type";s:5:"label";}s:1:"D";a:2:{s:4:"type";s:5:"label";s:5:"label";s:28:"Where to find this resource?";}}i:3;a:4:{s:1:"A";a:2:{s:4:"type";s:5:"label";s:5:"label";s:19:"Storage information";}s:1:"B";a:4:{s:4:"type";s:4:"text";s:4:"size";s:6:"50,100";s:4:"name";s:12:"storage_info";s:4:"help";s:25:"Information about storage";}s:1:"C";a:1:{s:4:"type";s:5:"label";}s:1:"D";a:2:{s:4:"type";s:5:"label";s:5:"label";s:25:"Information about storage";}}i:4;a:4:{s:1:"A";a:2:{s:4:"type";s:5:"label";s:5:"label";s:8:"Quantity";}s:1:"B";a:4:{s:4:"type";s:4:"text";s:4:"size";s:4:"5,10";s:4:"name";s:8:"quantity";s:4:"help";s:20:"Quantity of resource";}s:1:"C";a:1:{s:4:"type";s:5:"label";}s:1:"D";a:2:{s:4:"type";s:5:"label";s:5:"label";s:20:"Quantity of resource";}}i:5;a:4:{s:1:"A";a:2:{s:4:"type";s:5:"label";s:5:"label";s:7:"Useable";}s:1:"B";a:4:{s:4:"type";s:4:"text";s:4:"size";s:4:"5,10";s:4:"name";s:7:"useable";s:4:"help";s:29:"How many of them are useable?";}s:1:"C";a:1:{s:4:"type";s:5:"label";}s:1:"D";a:2:{s:4:"type";s:5:"label";s:5:"label";s:38:"How many of the resources are useable?";}}i:6;a:4:{s:1:"A";a:2:{s:4:"type";s:5:"label";s:5:"label";s:8:"Bookable";}s:1:"B";a:3:{s:4:"type";s:8:"checkbox";s:4:"name";s:8:"bookable";s:4:"help";s:21:"Is resource bookable?";}s:1:"C";a:1:{s:4:"type";s:5:"label";}s:1:"D";a:2:{s:4:"type";s:5:"label";s:5:"label";s:26:"Is this resource bookable?";}}i:7;a:4:{s:1:"A";a:2:{s:4:"type";s:5:"label";s:5:"label";s:12:"Accessory of";}s:1:"B";a:3:{s:4:"type";s:6:"select";s:7:"no_lang";s:1:"1";s:4:"name";s:12:"accessory_of";}s:1:"C";a:1:{s:4:"type";s:5:"label";}s:1:"D";a:2:{s:4:"type";s:5:"label";s:4:"name";s:15:"accessory_label";}}i:8;a:4:{s:1:"A";a:3:{s:4:"type";s:5:"label";s:5:"label";s:7:"Buyable";s:8:"disabled";s:1:"1";}s:1:"B";a:4:{s:4:"type";s:8:"checkbox";s:4:"name";s:7:"buyable";s:4:"help";s:20:"Is resource buyable?";s:8:"disabled";s:1:"1";}s:1:"C";a:1:{s:4:"type";s:5:"label";}s:1:"D";a:3:{s:4:"type";s:5:"label";s:5:"label";s:25:"Is this resource buyable?";s:8:"disabled";s:1:"1";}}i:9;a:4:{s:1:"A";a:1:{s:4:"type";s:5:"label";}s:1:"B";a:1:{s:4:"type";s:5:"label";}s:1:"C";a:1:{s:4:"type";s:5:"label";}s:1:"D";a:1:{s:4:"type";s:5:"label";}}}s:4:"rows";i:9;s:4:"cols";i:4;s:4:"size";s:7:"700,380";s:7:"options";a:2:{i:0;s:3:"700";i:1;s:3:"380";}}}','size' => '700,380','style' => '','modified' => '1093597682',); - -$templ_data[] = array('name' => 'resources.edit_tabs.history','template' => '','lang' => '','group' => '0','version' => '','data' => 'a:1:{i:0;a:5:{s:4:"type";s:10:"historylog";s:4:"data";a:2:{i:0;a:1:{s:1:"A";s:4:"100%";}i:1;a:1:{s:1:"A";a:2:{s:4:"type";s:10:"historylog";s:4:"name";s:7:"history";}}}s:4:"rows";i:1;s:4:"cols";i:1;s:4:"name";s:7:"history";}}','size' => '','style' => '','modified' => '1355774114',); - -$templ_data[] = array('name' => 'resources.edit_tabs.links','template' => '','lang' => '','group' => '0','version' => '','data' => 'a:1:{i:0;a:6:{s:4:"type";s:4:"grid";s:4:"data";a:6:{i:0;a:7:{s:1:"A";s:3:"100";s:2:"c1";s:2:"th";s:2:"c2";s:3:"row";s:2:"c3";s:2:"th";s:2:"c4";s:11:"row_off,top";s:2:"h4";s:3:"164";s:2:"h5";s:4:"100%";}i:1;a:2:{s:1:"A";a:3:{s:4:"type";s:5:"label";s:4:"span";s:3:"all";s:5:"label";s:16:"Create new links";}s:1:"B";a:1:{s:4:"type";s:5:"label";}}i:2;a:2:{s:1:"A";a:3:{s:4:"type";s:7:"link-to";s:4:"span";s:3:"all";s:4:"name";s:7:"link_to";}s:1:"B";a:1:{s:4:"type";s:5:"label";}}i:3;a:2:{s:1:"A";a:3:{s:4:"type";s:5:"label";s:4:"span";s:3:"all";s:5:"label";s:14:"Existing links";}s:1:"B";a:1:{s:4:"type";s:5:"label";}}i:4;a:2:{s:1:"A";a:3:{s:4:"type";s:9:"link-list";s:4:"span";s:3:"all";s:4:"name";s:7:"link_to";}s:1:"B";a:1:{s:4:"type";s:5:"label";}}i:5;a:2:{s:1:"A";a:1:{s:4:"type";s:5:"label";}s:1:"B";a:1:{s:4:"type";s:5:"label";}}}s:4:"rows";i:5;s:4:"cols";i:2;s:4:"size";s:7:"700,380";s:7:"options";a:2:{i:0;s:3:"700";i:1;s:3:"380";}}}','size' => '700,380','style' => '','modified' => '1109248913',); - -$templ_data[] = array('name' => 'resources.edit_tabs.page','template' => '','lang' => '','group' => '0','version' => '','data' => 'a:1:{i:0;a:6:{s:4:"type";s:4:"grid";s:4:"data";a:2:{i:0;a:1:{s:2:"c1";s:4:",top";}i:1;a:1:{s:1:"A";a:4:{s:4:"type";s:8:"htmlarea";s:4:"name";s:16:"long_description";s:4:"help";s:26:"Web-Site for this resource";s:4:"size";s:17:",350px,700px,true";}}}s:4:"rows";i:1;s:4:"cols";i:1;s:4:"size";s:8:"100%,380";s:7:"options";a:2:{i:0;s:4:"100%";i:1;s:3:"380";}}}','size' => '100%,380','style' => '','modified' => '1093599237',); - -$templ_data[] = array('name' => 'resources.edit_tabs.pictures','template' => '','lang' => '','group' => '0','version' => '','data' => 'a:1:{i:0;a:6:{s:4:"type";s:4:"grid";s:4:"data";a:3:{i:0;a:2:{s:2:"c1";s:4:",top";s:2:"h2";s:4:"100%";}i:1;a:1:{s:1:"A";a:4:{s:4:"type";s:4:"hbox";s:4:"size";s:1:"2";i:1;a:4:{s:4:"type";s:4:"vbox";s:4:"size";s:1:"2";i:1;a:2:{s:4:"type";s:5:"image";s:4:"name";s:16:"resource_picture";}i:2;a:1:{s:4:"type";s:5:"label";}}i:2;a:4:{s:4:"type";s:8:"groupbox";s:4:"size";s:1:"1";i:1;a:4:{s:4:"type";s:4:"grid";s:4:"data";a:4:{i:0;a:0:{}i:1;a:3:{s:1:"A";a:3:{s:4:"type";s:5:"label";s:5:"label";s:26:"Use general resources icon";s:5:"align";s:5:"right";}s:1:"B";a:3:{s:4:"type";s:5:"radio";s:4:"size";s:7:"gen_src";s:4:"name";s:11:"picture_src";}s:1:"C";a:3:{s:4:"type";s:6:"select";s:7:"no_lang";s:1:"1";s:4:"name";s:12:"gen_src_list";}}i:2;a:3:{s:1:"A";a:3:{s:4:"type";s:5:"label";s:5:"label";s:23:"Use the category\'s icon";s:5:"align";s:5:"right";}s:1:"B";a:3:{s:4:"type";s:5:"radio";s:4:"size";s:7:"cat_src";s:4:"name";s:11:"picture_src";}s:1:"C";a:1:{s:4:"type";s:5:"label";}}i:3;a:3:{s:1:"A";a:3:{s:4:"type";s:5:"label";s:5:"label";s:15:"Use own picture";s:5:"align";s:5:"right";}s:1:"B";a:3:{s:4:"type";s:5:"radio";s:4:"size";s:7:"own_src";s:4:"name";s:11:"picture_src";}s:1:"C";a:2:{s:4:"type";s:4:"file";s:4:"name";s:8:"own_file";}}}s:4:"rows";i:3;s:4:"cols";i:3;}s:5:"label";s:14:"picture source";}}}i:2;a:1:{s:1:"A";a:1:{s:4:"type";s:5:"label";}}}s:4:"rows";i:2;s:4:"cols";i:1;s:4:"size";s:7:"700,380";s:7:"options";a:2:{i:0;s:3:"700";i:1;s:3:"380";}}}','size' => '700,380','style' => '','modified' => '1131048665',); - -$templ_data[] = array('name' => 'resources.export_csv_selectors','template' => '','lang' => '','group' => '0','version' => '1.9.001','data' => 'a:1:{i:0;a:4:{s:4:"type";s:4:"grid";s:4:"data";a:3:{i:0;a:0:{}i:1;a:1:{s:1:"A";a:4:{s:4:"type";s:5:"radio";s:5:"label";s:7:"Use all";s:4:"size";s:3:"all";s:4:"name";s:9:"selection";}}i:2;a:1:{s:1:"A";a:4:{s:4:"type";s:5:"radio";s:5:"label";s:18:"Use search results";s:4:"name";s:9:"selection";s:4:"size";s:8:"selected";}}}s:4:"rows";i:2;s:4:"cols";i:1;}}','size' => '','style' => '','modified' => '1289840391',); - -$templ_data[] = array('name' => 'resources.resource_select','template' => '','lang' => '','group' => '0','version' => '1.7.001','data' => 'a:1:{i:0;a:6:{s:4:"type";s:4:"grid";s:4:"data";a:2:{i:0;a:0:{}i:1;a:1:{s:1:"A";a:3:{s:4:"type";s:9:"nextmatch";s:4:"size";s:29:"resources.resource_select.row";s:4:"name";s:2:"nm";}}}s:4:"rows";i:1;s:4:"cols";i:1;s:4:"size";s:4:"100%";s:7:"options";a:1:{i:0;s:4:"100%";}}}','size' => '100%','style' => '','modified' => '1254212129',); - -$templ_data[] = array('name' => 'resources.resource_select.header','template' => '','lang' => '','group' => '0','version' => '','data' => 'a:1:{i:0;a:4:{s:4:"type";s:4:"grid";s:4:"data";a:2:{i:0;a:0:{}i:1;a:2:{s:1:"A";a:3:{s:4:"type";s:5:"image";s:4:"name";s:6:"navbar";s:5:"label";s:16:"Select resources";}s:1:"B";a:3:{s:4:"type";s:5:"label";s:4:"name";s:4:"$msg";s:7:"no_lang";s:1:"1";}}}s:4:"rows";i:1;s:4:"cols";i:2;}}','size' => '','style' => '','modified' => '1118502303',); - -$templ_data[] = array('name' => 'resources.resource_select.row','template' => '','lang' => '','group' => '0','version' => '1.7.002','data' => 'a:2:{i:0;a:6:{s:4:"type";s:4:"grid";s:4:"data";a:3:{i:0;a:3:{s:2:"c1";s:2:"th";s:2:"c2";s:3:"row";s:1:"G";s:2:"3%";}i:1;a:7:{s:1:"A";a:3:{s:4:"type";s:20:"nextmatch-sortheader";s:5:"label";s:4:"Name";s:4:"name";s:4:"name";}s:1:"B";a:3:{s:4:"type";s:20:"nextmatch-sortheader";s:5:"label";s:8:"Category";s:4:"name";s:6:"cat_id";}s:1:"C";a:3:{s:4:"type";s:20:"nextmatch-sortheader";s:5:"label";s:11:"Description";s:4:"name";s:17:"short_description";}s:1:"D";a:3:{s:4:"type";s:20:"nextmatch-sortheader";s:5:"label";s:8:"Location";s:4:"name";s:8:"location";}s:1:"E";a:3:{s:4:"type";s:20:"nextmatch-sortheader";s:5:"label";s:19:"Storage information";s:4:"name";s:12:"storage_info";}s:1:"F";a:3:{s:4:"type";s:16:"nextmatch-header";s:5:"label";s:8:"Quantity";s:4:"name";s:8:"quantity";}s:1:"G";a:1:{s:4:"type";s:5:"label";}}i:2;a:7:{s:1:"A";a:3:{s:4:"type";s:5:"label";s:4:"name";s:12:"${row}[name]";s:7:"no_lang";s:1:"1";}s:1:"B";a:3:{s:4:"type";s:10:"select-cat";s:4:"name";s:14:"${row}[cat_id]";s:8:"readonly";s:1:"1";}s:1:"C";a:2:{s:4:"type";s:5:"label";s:4:"name";s:25:"${row}[short_description]";}s:1:"D";a:2:{s:4:"type";s:5:"label";s:4:"name";s:16:"${row}[location]";}s:1:"E";a:2:{s:4:"type";s:5:"label";s:4:"name";s:20:"${row}[storage_info]";}s:1:"F";a:8:{s:4:"type";s:4:"hbox";s:7:"no_lang";s:1:"1";s:4:"data";a:2:{i:0;a:0:{}i:1;a:3:{s:1:"A";a:2:{s:4:"type";s:3:"int";s:4:"size";s:4:"1,,2";}s:1:"B";a:2:{s:4:"type";s:5:"label";s:5:"label";s:2:"of";}s:1:"C";a:3:{s:4:"type";s:5:"label";s:4:"name";s:15:"${row}[useable]";s:7:"no_lang";s:1:"1";}}}s:4:"rows";i:1;s:4:"cols";i:3;s:4:"size";s:6:"2,,0,0";i:1;a:3:{s:4:"type";s:3:"int";s:4:"size";s:4:"1,,2";s:4:"name";s:19:"${row}[default_qty]";}i:2;a:5:{s:4:"type";s:3:"int";s:5:"label";s:2:"of";s:4:"span";s:9:",leftPad5";s:4:"name";s:15:"${row}[useable]";s:8:"readonly";s:1:"1";}}s:1:"G";a:6:{s:4:"type";s:6:"button";s:4:"size";s:6:"select";s:7:"onclick";s:88:"addOption(\'$row_cont[name]\',$row_cont[res_id],this.id,$row_cont[useable]); return false;";s:6:"needed";s:1:"1";s:5:"label";s:15:"select resource";s:4:"name";s:6:"${row}";}}}s:4:"rows";i:2;s:4:"cols";i:7;s:4:"size";s:15:"100%,,,selTable";s:7:"options";a:2:{i:3;s:8:"selTable";i:0;s:4:"100%";}}i:1;a:10:{s:4:"type";s:4:"vbox";i:1;a:9:{s:4:"type";s:4:"hbox";s:5:"align";s:6:"center";s:4:"data";a:2:{i:0;a:0:{}i:1;a:1:{s:1:"A";a:1:{s:4:"type";s:5:"label";}}}s:4:"rows";i:1;s:4:"cols";i:1;s:4:"size";s:1:"2";i:1;a:3:{s:4:"type";s:5:"label";s:5:"label";s:9:"Selection";s:4:"span";s:4:",big";}i:2;a:6:{s:4:"type";s:6:"button";s:4:"size";s:6:"delete";s:5:"label";s:15:"clear selection";s:7:"onclick";s:38:"removeSelectedOptions(); return false;";s:6:"needed";s:1:"1";s:5:"align";s:5:"right";}s:4:"span";s:3:",th";}s:4:"data";a:4:{i:0;a:1:{s:2:"c1";s:2:"th";}i:1;a:1:{s:1:"A";a:3:{s:4:"type";s:5:"label";s:4:"span";s:5:"0,big";s:5:"label";s:9:"Selection";}}i:2;a:1:{s:1:"A";a:5:{s:4:"type";s:6:"select";s:4:"size";s:3:"13+";s:4:"name";s:9:"selectbox";s:4:"span";s:5:"0,sel";s:7:"no_lang";s:1:"1";}}i:3;a:1:{s:1:"A";a:4:{s:4:"type";s:6:"button";s:5:"label";s:5:"Close";s:5:"align";s:6:"center";s:7:"onclick";s:31:"oneLineSubmit();window.close();";}}}s:4:"rows";i:3;s:4:"cols";i:1;s:5:"align";s:5:"right";s:4:"size";s:1:"3";i:2;a:5:{s:4:"type";s:6:"select";s:4:"size";s:3:"13+";s:4:"name";s:9:"selectbox";s:4:"span";s:5:"0,sel";s:7:"no_lang";s:1:"1";}i:3;a:4:{s:4:"type";s:6:"button";s:5:"label";s:5:"Close";s:5:"align";s:6:"center";s:7:"onclick";s:31:"oneLineSubmit();window.close();";}s:4:"span";s:13:",selSelection";}}','size' => '100%,,,selTable','style' => '','modified' => '1126031297',); - -$templ_data[] = array('name' => 'resources.resource_selectbox','template' => '','lang' => '','group' => '0','version' => '','data' => 'a:1:{i:0;a:4:{s:4:"type";s:4:"grid";s:4:"data";a:2:{i:0;a:1:{s:2:"c1";s:7:",bottom";}i:1;a:2:{s:1:"A";a:4:{s:4:"type";s:6:"select";s:4:"size";s:3:"14+";s:4:"name";s:9:"resources";s:7:"no_lang";s:1:"1";}s:1:"B";a:6:{s:4:"type";s:6:"button";s:7:"onclick";s:160:"window.open(egw::link(\'/index.php\',\'menuaction=resources.resources_ui.select\'),\'\',\'dependent=yes,width=600,height=450,scrollbars=yes,status=yes\'); return false;";s:5:"label";s:13:"Add resources";s:4:"size";s:6:"navbar";s:6:"needed";s:1:"1";s:4:"name";s:5:"popup";}}}s:4:"rows";i:1;s:4:"cols";i:2;}}','size' => '','style' => '','modified' => '1118520536',); - -$templ_data[] = array('name' => 'resources.show','template' => '','lang' => '','group' => '0','version' => '1.9.003','data' => 'a:1:{i:0;a:6:{s:4:"type";s:4:"grid";s:4:"data";a:8:{i:0;a:4:{s:1:"A";s:4:"100%";s:2:"h1";s:6:",!@msg";s:2:"h4";s:34:",!@nm[selectcols]=/legacy_actions/";s:2:"h2";s:2:",1";}i:1;a:1:{s:1:"A";a:4:{s:4:"type";s:5:"label";s:4:"span";s:11:"all,message";s:4:"name";s:3:"msg";s:5:"align";s:6:"center";}}i:2;a:1:{s:1:"A";a:3:{s:4:"type";s:8:"template";s:5:"align";s:5:"right";s:4:"name";s:8:"nm_right";}}i:3;a:1:{s:1:"A";a:4:{s:4:"type";s:9:"nextmatch";s:4:"size";s:19:"resources.show.rows";s:7:"no_lang";s:1:"1";s:4:"name";s:2:"nm";}}i:4;a:1:{s:1:"A";a:6:{s:5:"align";s:5:"right";s:4:"span";s:3:"all";s:4:"type";s:4:"hbox";s:4:"size";s:1:"2";i:1;a:5:{s:5:"label";s:13:"Select action";s:7:"onclick";s:184:"if (!egw_globalObjectManager.getObjectById(\'resources.show.rows\').executeActionImplementation(this, \'popup\')) alert(egw::lang(\'You need to select some entries first!\')); return false;;";s:4:"name";s:14:"legacy_actions";s:4:"type";s:10:"buttononly";s:4:"help";s:13:"Select action";}i:2;a:8:{s:5:"label";s:9:"Check all";s:6:"needed";s:1:"1";s:7:"onclick";s:95:"egw_globalObjectManager.getObjectById(\'resources.show.rows\').toggleAllSelected(); return false;";s:4:"name";s:9:"check_all";s:4:"type";s:6:"button";s:4:"size";s:9:"arrow_ltr";s:4:"help";s:9:"Check all";s:4:"span";s:14:",checkAllArrow";}}}i:5;a:1:{s:1:"A";a:3:{s:4:"type";s:4:"hbox";s:4:"size";s:1:"1";i:1;a:4:{s:4:"type";s:6:"button";s:5:"label";s:3:"Add";s:7:"onclick";s:206:"window.open(egw::link(\'/index.php\',\'menuaction=resources.resources_ui.edit\'),\'\',\'dependent=yes,width=800,height=600,location=no,menubar=no,toolbar=no,scrollbars=yes,status=yes\'); return false; return false;";s:4:"name";s:3:"add";}}}i:6;a:1:{s:1:"A";a:6:{s:5:"class";s:12:"action_popup";s:4:"name";s:12:"delete_popup";s:4:"type";s:3:"box";s:4:"size";s:1:"1";i:1;a:6:{s:5:"class";s:6:"prompt";s:4:"type";s:4:"vbox";s:4:"size";s:1:"3";i:1;a:3:{s:4:"type";s:5:"label";s:5:"label";s:6:"Delete";s:4:"span";s:13:",promptheader";}i:2;a:2:{s:4:"type";s:5:"label";s:5:"label";s:45:"Delete accessories of selected resources too?";}i:3;a:5:{s:4:"type";s:4:"hbox";s:4:"size";s:1:"3";i:1;a:4:{s:5:"label";s:28:"Yes - Delete accessories too";s:7:"onclick";s:36:"nm_submit_popup(this); return false;";s:4:"name";s:6:"delete";s:4:"type";s:6:"button";}i:2;a:4:{s:5:"label";s:24:"No - Make them resources";s:7:"onclick";s:75:"nm_popup_action.id = \'delete_promote\'; nm_submit_popup(this); return false;";s:4:"name";s:14:"delete_promote";s:4:"type";s:6:"button";}i:3;a:3:{s:5:"label";s:6:"Cancel";s:7:"onclick";s:35:"nm_hide_popup(this,\'delete_popup\');";s:4:"type";s:10:"buttononly";}}}s:4:"span";s:20:",action_popup prompt";}}i:7;a:1:{s:1:"A";a:6:{s:5:"class";s:12:"action_popup";s:4:"name";s:13:"restore_popup";s:4:"type";s:3:"box";s:4:"size";s:1:"1";i:1;a:6:{s:5:"class";s:6:"prompt";s:4:"type";s:4:"vbox";s:4:"size";s:1:"3";i:1;a:3:{s:4:"type";s:5:"label";s:5:"label";s:9:"Un-delete";s:4:"span";s:13:",promptheader";}i:2;a:2:{s:4:"type";s:5:"label";s:5:"label";s:48:"Un-delete accessories of selected resources too?";}i:3;a:5:{s:4:"type";s:4:"hbox";s:4:"size";s:1:"3";i:1;a:4:{s:5:"label";s:31:"Yes - Un-delete accessories too";s:7:"onclick";s:79:"nm_popup_action.id = \'restore_accessories\';nm_submit_popup(this); return false;";s:4:"name";s:19:"restore_accessories";s:4:"type";s:6:"button";}i:2;a:4:{s:5:"label";s:15:"No - Leave them";s:7:"onclick";s:68:"nm_popup_action.id = \'restore\'; nm_submit_popup(this); return false;";s:4:"name";s:7:"restore";s:4:"type";s:6:"button";}i:3;a:3:{s:5:"label";s:6:"Cancel";s:7:"onclick";s:36:"nm_hide_popup(this,\'restore_popup\');";s:4:"type";s:10:"buttononly";}}}s:4:"span";s:20:",action_popup prompt";}}}s:4:"rows";i:7;s:4:"cols";i:1;s:4:"size";s:4:"100%";s:7:"options";a:1:{i:0;s:4:"100%";}}}','size' => '100%','style' => '.image16 img { - max-width: 16px; - max-height: 16px; -} -div.action_popup[id] { - position: fixed; - top: 200px; - left: 450px; - width: 76ex; - z-index: 20000; - display: none; - border-collapse:collapse; - border-spacing:0px -}','modified' => '1352242021',); - -$templ_data[] = array('name' => 'resources.show.actions','template' => '','lang' => '','group' => '0','version' => '','data' => 'a:1:{i:0;a:5:{s:4:"type";s:4:"grid";s:4:"data";a:3:{i:0;a:3:{s:1:"F";s:2:"3%";s:2:"c1";s:3:"nmh";s:2:"c2";s:3:"nmr";}i:1;a:6:{s:1:"A";a:3:{s:4:"type";s:20:"nextmatch-sortheader";s:5:"label";s:4:"Name";s:4:"name";s:4:"name";}s:1:"B";a:3:{s:4:"type";s:20:"nextmatch-sortheader";s:5:"label";s:17:"Short description";s:4:"name";s:17:"short_description";}s:1:"C";a:3:{s:4:"type";s:20:"nextmatch-sortheader";s:5:"label";s:7:"Useable";s:4:"name";s:7:"useable";}s:1:"D";a:3:{s:4:"type";s:20:"nextmatch-sortheader";s:5:"label";s:8:"Category";s:4:"name";s:6:"cat_id";}s:1:"E";a:3:{s:4:"type";s:20:"nextmatch-sortheader";s:5:"label";s:8:"Location";s:4:"name";s:8:"location";}s:1:"F";a:3:{s:4:"type";s:8:"template";s:5:"align";s:5:"right";s:4:"name";s:29:"resources.show.actions_header";}}i:2;a:6:{s:1:"A";a:3:{s:4:"type";s:5:"label";s:7:"no_lang";s:1:"1";s:4:"name";s:12:"${row}[name]";}s:1:"B";a:3:{s:4:"type";s:5:"label";s:7:"no_lang";s:1:"1";s:4:"name";s:25:"${row}[short_description]";}s:1:"C";a:3:{s:4:"type";s:5:"label";s:7:"no_lang";s:1:"1";s:4:"name";s:14:"${row}[usable]";}s:1:"D";a:3:{s:4:"type";s:5:"label";s:7:"no_lang";s:1:"1";s:4:"name";s:16:"${row}[category]";}s:1:"E";a:3:{s:4:"type";s:5:"label";s:7:"no_lang";s:1:"1";s:4:"name";s:16:"${row}[location]";}s:1:"F";a:3:{s:4:"type";s:6:"button";s:5:"align";s:5:"right";s:4:"name";s:20:"lukas[$row_cont[id]]";}}}s:4:"rows";i:2;s:4:"cols";i:6;s:4:"size";s:4:"100%";}}','size' => '100%','style' => '','modified' => '1098891355',); - -$templ_data[] = array('name' => 'resources.show.actions_header','template' => '','lang' => '','group' => '0','version' => '','data' => 'a:1:{i:0;a:4:{s:4:"type";s:4:"grid";s:4:"data";a:2:{i:0;a:0:{}i:1;a:2:{s:1:"A";a:2:{s:4:"type";s:5:"label";s:5:"label";s:6:"Action";}s:1:"B";a:3:{s:4:"type";s:6:"button";s:4:"size";s:9:"check.png";s:4:"name";s:30:"javascript:check_all(\'select\')";}}}s:4:"rows";i:1;s:4:"cols";i:2;}}','size' => '','style' => '','modified' => '1094025049',); - -$templ_data[] = array('name' => 'resources.show.nm_right','template' => '','lang' => '','group' => '0','version' => '1.9.002','data' => 'a:1:{i:0;a:4:{s:4:"type";s:4:"grid";s:4:"data";a:2:{i:0;a:0:{}i:1;a:1:{s:1:"A";a:4:{s:4:"type";s:10:"buttononly";s:5:"label";s:3:"Add";s:7:"onclick";s:206:"window.open(egw::link(\'/index.php\',\'menuaction=resources.resources_ui.edit\'),\'\',\'dependent=yes,width=800,height=600,location=no,menubar=no,toolbar=no,scrollbars=yes,status=yes\'); return false; return false;";s:4:"name";s:3:"add";}}}s:4:"rows";i:1;s:4:"cols";i:1;}}','size' => '','style' => '','modified' => '1331036827',); - -$templ_data[] = array('name' => 'resources.show.rows','template' => '','lang' => '','group' => '0','version' => '1.9.003','data' => 'a:1:{i:0;a:6:{s:4:"type";s:4:"grid";s:4:"data";a:3:{i:0;a:5:{s:1:"C";s:2:"3%";s:2:"c1";s:3:"nmh";s:2:"c2";s:24:"nmr $row_cont[class],top";s:1:"H";s:2:"5%";s:1:"G";s:17:",@no_customfields";}i:1;a:8:{s:1:"A";a:1:{s:4:"type";s:5:"label";}s:1:"B";a:4:{s:4:"type";s:4:"vbox";s:4:"size";s:1:"2";i:1;a:3:{s:4:"type";s:20:"nextmatch-sortheader";s:5:"label";s:4:"Name";s:4:"name";s:4:"name";}i:2;a:3:{s:4:"type";s:20:"nextmatch-sortheader";s:5:"label";s:17:"Short description";s:4:"name";s:17:"short_description";}}s:1:"C";a:4:{s:4:"type";s:4:"vbox";s:4:"size";s:1:"2";i:1;a:4:{s:4:"type";s:20:"nextmatch-sortheader";s:5:"label";s:7:"Useable";s:4:"name";s:7:"useable";s:4:"help";s:36:"How many of this resource are usable";}i:2;a:4:{s:4:"type";s:20:"nextmatch-sortheader";s:5:"label";s:8:"Quantity";s:4:"name";s:8:"quantity";s:4:"help";s:32:"How many of this resource exists";}}s:1:"D";a:4:{s:4:"type";s:4:"vbox";s:4:"size";s:1:"2";i:1;a:3:{s:4:"type";s:20:"nextmatch-sortheader";s:5:"label";s:8:"Category";s:4:"name";s:6:"cat_id";}i:2;a:2:{s:4:"type";s:5:"label";s:5:"label";s:13:"Administrator";}}s:1:"E";a:4:{s:4:"type";s:4:"vbox";s:4:"size";s:1:"2";i:1;a:3:{s:4:"type";s:20:"nextmatch-sortheader";s:5:"label";s:8:"Location";s:4:"name";s:8:"location";}i:2;a:2:{s:4:"type";s:5:"label";s:5:"label";s:19:"Storage information";}}s:1:"F";a:2:{s:4:"type";s:16:"nextmatch-header";s:5:"label";s:22:"Resource / Accessories";}s:1:"G";a:2:{s:4:"type";s:22:"nextmatch-customfields";s:4:"name";s:12:"customfields";}s:1:"H";a:7:{s:4:"type";s:4:"hbox";s:4:"size";s:1:"4";i:1;a:3:{s:4:"type";s:16:"nextmatch-header";s:5:"label";s:7:"Actions";s:4:"name";s:14:"legacy_actions";}i:2;a:1:{s:4:"type";s:5:"label";}i:3;a:2:{s:4:"type";s:5:"label";s:6:"needed";s:1:"1";}s:5:"align";s:5:"right";i:4;a:11:{s:4:"type";s:6:"button";s:4:"size";s:9:"check.png";s:5:"label";s:9:"Check all";s:5:"align";s:5:"right";s:4:"name";s:9:"check_all";s:4:"help";s:9:"Check all";i:1;a:1:{s:4:"type";s:5:"label";}i:2;a:1:{s:4:"type";s:5:"label";}i:3;a:1:{s:4:"type";s:5:"label";}s:6:"needed";s:1:"1";s:7:"onclick";s:76:"toggle_all(this.form,form::name(\'nm[rows][checkbox][]\'),true); return false;";}}}i:2;a:8:{s:1:"A";a:6:{s:4:"type";s:6:"button";s:5:"align";s:6:"center";s:4:"name";s:21:"${row}[picture_thumb]";s:4:"size";s:24:"$row_cont[picture_thumb]";s:7:"onclick";s:128:"if(\'${row_cont[picture_src]}\' == \'own_src\') {egw.open(\'/apps/resources/${row_cont[res_id]}/.picture.jpg\',\'file\');} return false;";s:4:"span";s:6:",thumb";}s:1:"B";a:4:{s:4:"type";s:4:"vbox";s:4:"size";s:1:"2";i:1;a:3:{s:4:"type";s:5:"label";s:7:"no_lang";s:1:"1";s:4:"name";s:12:"${row}[name]";}i:2;a:3:{s:4:"type";s:5:"label";s:7:"no_lang";s:1:"1";s:4:"name";s:25:"${row}[short_description]";}}s:1:"C";a:5:{s:4:"type";s:4:"vbox";s:4:"size";s:1:"2";s:5:"align";s:5:"right";i:1;a:4:{s:4:"type";s:5:"label";s:7:"no_lang";s:1:"1";s:5:"align";s:5:"right";s:4:"name";s:15:"${row}[useable]";}i:2;a:4:{s:4:"type";s:5:"label";s:7:"no_lang";s:1:"1";s:5:"align";s:5:"right";s:4:"name";s:16:"${row}[quantity]";}}s:1:"D";a:4:{s:4:"type";s:4:"vbox";s:4:"size";s:1:"2";i:1;a:4:{s:4:"type";s:10:"select-cat";s:7:"no_lang";s:1:"1";s:4:"name";s:14:"${row}[cat_id]";s:8:"readonly";s:1:"1";}i:2;a:4:{s:4:"type";s:14:"select-account";s:7:"no_lang";s:1:"1";s:4:"name";s:13:"${row}[admin]";s:8:"readonly";s:1:"1";}}s:1:"E";a:4:{s:4:"type";s:4:"vbox";s:4:"size";s:1:"2";i:1;a:3:{s:4:"type";s:5:"label";s:7:"no_lang";s:1:"1";s:4:"name";s:16:"${row}[location]";}i:2;a:3:{s:4:"type";s:5:"label";s:7:"no_lang";s:1:"1";s:4:"name";s:20:"${row}[storage_info]";}}s:1:"F";a:5:{s:4:"type";s:4:"vbox";s:7:"no_lang";s:1:"1";s:4:"size";s:1:"2";i:1;a:4:{s:4:"type";s:5:"label";s:7:"no_lang";s:1:"1";s:4:"name";s:26:"${row}[accessory_of_label]";s:4:"size";s:70:",resources.resources_ui.edit&res_id=$row_cont[accessory_of],,,,850x600";}i:2;a:7:{s:4:"type";s:4:"grid";s:4:"name";s:19:"${row}[accessories]";s:4:"size";s:4:"100%";s:4:"data";a:2:{i:0;a:0:{}i:1;a:1:{s:1:"A";a:4:{s:4:"type";s:5:"label";s:4:"size";s:64:",resources.resources_ui.edit&res_id=$row_cont[acc_id],,,,850x600";s:7:"no_lang";s:1:"1";s:4:"name";s:12:"${row}[name]";}}}s:4:"rows";i:1;s:4:"cols";i:1;s:7:"options";a:1:{i:0;s:4:"100%";}}}s:1:"G";a:2:{s:4:"type";s:17:"customfields-list";s:4:"name";s:4:"$row";}s:1:"H";a:7:{s:4:"type";s:4:"grid";s:5:"align";s:5:"right";s:4:"data";a:3:{i:0;a:0:{}i:1;a:4:{s:1:"A";a:8:{s:4:"type";s:6:"button";s:4:"size";s:17:"navbar,trams16x16";s:5:"label";s:18:"Book this resource";s:5:"align";s:6:"center";s:4:"help";s:18:"Book this resource";s:7:"onclick";s:223:"window.open(egw::link(\'/index.php\',\'menuaction=calendar.calendar_uiforms.edit&participants=r$cont[res_id]\'),\'\',\'dependent=yes,width=750,height=400,location=no,menubar=no,toolbar=no,scrollbars=yes,status=yes\'); return false;";s:4:"name";s:23:"bookable[$cont[res_id]]";s:4:"span";s:8:",image16";}s:1:"B";a:7:{s:4:"type";s:6:"button";s:4:"size";s:15:"edit,trans16x16";s:5:"label";s:4:"Edit";s:5:"align";s:6:"center";s:4:"help";s:15:"Edit this entry";s:7:"onclick";s:213:"window.open(egw::link(\'/index.php\',\'menuaction=resources.resources_ui.edit&res_id=$cont[res_id]\'),\'\',\'dependent=yes,width=800,height=600,location=no,menubar=no,toolbar=no,scrollbars=yes,status=yes\'); return false;";s:4:"name";s:19:"edit[$cont[res_id]]";}s:1:"C";a:7:{s:4:"type";s:6:"button";s:4:"size";s:14:"new,trans16x16";s:5:"label";s:38:"Create new accessory for this resource";s:5:"align";s:6:"center";s:4:"name";s:22:"new_acc[$cont[res_id]]";s:4:"help";s:38:"Create new accessory for this resource";s:7:"onclick";s:228:"window.open(egw::link(\'/index.php\',\'menuaction=resources.resources_ui.edit&res_id=0&accessory_of=$cont[res_id]\'),\'\',\'dependent=yes,width=800,height=600,location=no,menubar=no,toolbar=no,scrollbars=yes,status=yes\'); return false;";}s:1:"D";a:1:{s:4:"type";s:5:"label";}}i:2;a:4:{s:1:"A";a:7:{s:4:"type";s:6:"button";s:4:"size";s:27:"calendar/planner,trans16x16";s:5:"label";s:25:"Show calendar of resource";s:5:"align";s:6:"center";s:4:"help";s:25:"Show calendar of resource";s:4:"name";s:23:"calendar[$cont[res_id]]";s:7:"onclick";s:140:"location=egw::link(\'/index.php\',\'menuaction=calendar.calendar_uiviews.planner&sortby=user&owner=0,r$cont[res_id]\',\'calendar\'); return false;";}s:1:"B";a:7:{s:4:"type";s:6:"button";s:5:"label";s:6:"Delete";s:5:"align";s:6:"center";s:4:"name";s:21:"delete[$cont[res_id]]";s:4:"help";s:17:"Delete this entry";s:7:"onclick";s:36:"return confirm(\'Delete this entry\');";s:4:"size";s:17:"delete,trans16x16";}s:1:"C";a:6:{s:4:"type";s:6:"button";s:4:"size";s:19:"view_acc,trans16x16";s:5:"label";s:34:"View accessories for this resource";s:5:"align";s:6:"center";s:4:"name";s:23:"view_acc[$cont[res_id]]";s:4:"help";s:34:"View accessories for this resource";}s:1:"D";a:4:{s:4:"type";s:8:"checkbox";s:5:"align";s:5:"right";s:4:"name";s:10:"checkbox[]";s:4:"size";s:13:"$cont[res_id]";}}}s:4:"rows";i:2;s:4:"cols";i:4;s:4:"name";s:6:"${row}";s:7:"options";a:0:{}}}}s:4:"rows";i:2;s:4:"cols";i:8;s:4:"size";s:4:"100%";s:7:"options";a:1:{i:0;s:4:"100%";}}}','size' => '100%','style' => '','modified' => '1373295823',); - -$templ_data[] = array('name' => 'resources.showdetails','template' => '','lang' => '','group' => '0','version' => '1.5.001','data' => 'a:1:{i:0;a:6:{s:4:"type";s:4:"grid";s:4:"data";a:8:{i:0;a:8:{s:2:"c1";s:3:"nmh";s:1:"B";s:4:"100%";s:2:"c5";s:2:"th";s:2:"h3";s:2:"1%";s:2:"c6";s:11:"row_off,top";s:1:"A";s:3:"43%";s:2:"h1";s:5:"240px";s:2:"h5";s:10:",@!link_to";}i:1;a:2:{s:1:"A";a:3:{s:4:"type";s:5:"image";s:4:"name";s:16:"resource_picture";s:5:"align";s:6:"center";}s:1:"B";a:4:{s:4:"type";s:4:"grid";s:4:"data";a:9:{i:0;a:1:{s:2:"c5";s:4:",top";}i:1;a:2:{s:1:"A";a:3:{s:4:"type";s:5:"label";s:4:"size";s:1:"b";s:5:"label";s:5:"Name:";}s:1:"B";a:4:{s:4:"type";s:5:"label";s:4:"size";s:1:"b";s:7:"no_lang";s:1:"1";s:4:"name";s:4:"name";}}i:2;a:2:{s:1:"A";a:2:{s:4:"type";s:5:"label";s:5:"label";s:17:"Inventory number:";}s:1:"B";a:3:{s:4:"type";s:5:"label";s:7:"no_lang";s:1:"1";s:4:"name";s:16:"inventory_number";}}i:3;a:2:{s:1:"A";a:2:{s:4:"type";s:5:"label";s:5:"label";s:9:"Category:";}s:1:"B";a:3:{s:4:"type";s:10:"select-cat";s:4:"name";s:6:"cat_id";s:8:"readonly";s:1:"1";}}i:4;a:2:{s:1:"A";a:2:{s:4:"type";s:5:"label";s:5:"label";s:13:"Responsible: ";}s:1:"B";a:3:{s:4:"type";s:14:"select-account";s:4:"name";s:9:"cat_admin";s:8:"readonly";s:1:"1";}}i:5;a:2:{s:1:"A";a:2:{s:4:"type";s:5:"label";s:5:"label";s:10:"Quantity: ";}s:1:"B";a:2:{s:4:"type";s:5:"label";s:4:"name";s:8:"quantity";}}i:6;a:2:{s:1:"A";a:2:{s:4:"type";s:5:"label";s:5:"label";s:8:"Useable:";}s:1:"B";a:2:{s:4:"type";s:5:"label";s:4:"name";s:7:"useable";}}i:7;a:2:{s:1:"A";a:2:{s:4:"type";s:5:"label";s:5:"label";s:9:"Location:";}s:1:"B";a:3:{s:4:"type";s:5:"label";s:7:"no_lang";s:1:"1";s:4:"name";s:8:"location";}}i:8;a:2:{s:1:"A";a:2:{s:4:"type";s:5:"label";s:5:"label";s:20:"Storage information:";}s:1:"B";a:2:{s:4:"type";s:5:"label";s:4:"name";s:12:"storage_info";}}}s:4:"rows";i:8;s:4:"cols";i:2;}}i:2;a:2:{s:1:"A";a:1:{s:4:"type";s:5:"label";}s:1:"B";a:1:{s:4:"type";s:5:"label";}}i:3;a:2:{s:1:"A";a:4:{s:4:"type";s:4:"html";s:4:"span";s:1:"2";s:4:"name";s:11:"description";s:8:"readonly";s:1:"1";}s:1:"B";a:1:{s:4:"type";s:5:"label";}}i:4;a:2:{s:1:"A";a:1:{s:4:"type";s:5:"label";}s:1:"B";a:1:{s:4:"type";s:5:"label";}}i:5;a:2:{s:1:"A";a:6:{s:4:"type";s:5:"label";s:4:"span";s:1:"2";s:4:"data";a:2:{i:0;a:1:{s:1:"A";s:4:"100%";}i:1;a:4:{s:1:"A";a:2:{s:4:"type";s:5:"label";s:5:"label";s:13:"Related links";}s:1:"B";a:6:{s:4:"type";s:6:"button";s:5:"label";s:17:"Buy this resource";s:5:"align";s:5:"right";s:4:"size";s:7:"buyable";s:4:"help";s:17:"Buy this resource";s:4:"name";s:11:"btn_buyable";}s:1:"C";a:4:{s:4:"type";s:6:"button";s:5:"label";s:18:"Book this resource";s:4:"name";s:12:"btn_bookable";s:4:"size";s:8:"bookable";}s:1:"D";a:5:{s:4:"type";s:6:"button";s:5:"label";s:4:"edit";s:4:"name";s:8:"btn_edit";s:4:"size";s:4:"edit";s:4:"help";s:4:"edit";}}}s:4:"rows";i:1;s:4:"cols";i:4;s:5:"label";s:13:"Related links";}s:1:"B";a:1:{s:4:"type";s:5:"label";}}i:6;a:2:{s:1:"A";a:4:{s:4:"type";s:9:"link-list";s:4:"span";s:3:"all";s:4:"name";s:7:"link_to";s:8:"readonly";s:1:"1";}s:1:"B";a:1:{s:4:"type";s:5:"label";}}i:7;a:2:{s:1:"A";a:8:{s:4:"type";s:4:"hbox";s:5:"label";s:6:"Cancel";s:4:"span";s:1:"2";s:4:"size";s:1:"2";i:1;a:9:{s:4:"type";s:4:"hbox";s:5:"label";s:4:"Edit";s:4:"span";s:1:"2";s:4:"name";s:8:"btn_edit";s:4:"size";s:1:"4";i:1;a:5:{s:4:"type";s:6:"button";s:5:"label";s:4:"Edit";s:4:"span";s:1:"2";s:4:"name";s:8:"btn_edit";s:4:"help";s:16:"Buy this article";}i:2;a:3:{s:4:"type";s:6:"button";s:5:"label";s:6:"Cancel";s:7:"onclick";s:14:"window.close()";}i:3;a:6:{s:4:"type";s:6:"button";s:5:"label";s:8:"Calendar";s:4:"span";s:1:"2";s:4:"name";s:12:"btn_calendar";s:4:"help";s:25:"Show calendar of resource";s:7:"onclick";s:120:"opener.location=egw::link(\'/index.php\',\'menuaction=calendar.calendar_uiviews.month&owner=r$cont[res_id]\'); return false;";}i:4;a:5:{s:4:"type";s:6:"button";s:5:"label";s:4:"Book";s:7:"onclick";s:209:"window.open(egw::link(\'/index.php\',\'menuaction=calendar.calendar_uiforms.edit&participants=r$cont[res_id]\'),\'\',\'dependent=yes,width=750,height=400,location=no,menubar=no,toolbar=no,scrollbars=yes,status=yes\');";s:4:"name";s:8:"btn_book";s:4:"help";s:18:"Book this resource";}}i:2;a:4:{s:4:"type";s:4:"hbox";s:4:"size";s:1:"1";s:5:"align";s:5:"right";i:1;a:4:{s:4:"type";s:6:"button";s:5:"label";s:6:"Delete";s:7:"onclick";s:61:"return confirm(\'Do you really want do delte this resource?\');";s:4:"name";s:10:"btn_delete";}}i:3;a:1:{s:4:"type";s:5:"label";}i:4;a:4:{s:4:"type";s:6:"button";s:5:"label";s:6:"Delete";s:4:"name";s:10:"btn_delete";s:5:"align";s:5:"right";}}s:1:"B";a:1:{s:4:"type";s:5:"label";}}}s:4:"rows";i:7;s:4:"cols";i:2;s:4:"size";s:7:"750,480";s:7:"options";a:2:{i:0;s:3:"750";i:1;s:3:"480";}}}','size' => '750,480','style' => '','modified' => '1129667646',); - -$templ_data[] = array('name' => 'resources.sitemgr_book','template' => '','lang' => '','group' => '0','version' => '1.9.001','data' => 'a:1:{i:0;a:6:{s:4:"type";s:3:"box";s:4:"data";a:2:{i:0;a:0:{}i:1;a:1:{s:1:"A";a:1:{s:4:"type";s:5:"label";}}}s:4:"rows";i:1;s:4:"cols";i:1;s:4:"size";s:1:"1";i:1;a:6:{s:4:"type";s:4:"grid";s:4:"data";a:12:{i:0;a:6:{s:2:"h2";s:6:",!@msg";s:2:"h7";s:15:",!@contact_form";s:2:"h8";s:15:",!@show_contact";s:2:"h9";s:15:",!@show_contact";s:2:"h4";s:20:",!@short_description";s:2:"h5";s:19:",!@long_description";}i:1;a:2:{s:1:"A";a:2:{s:4:"type";s:6:"hidden";s:4:"name";s:6:"res_id";}s:1:"B";a:1:{s:4:"type";s:5:"label";}}i:2;a:2:{s:1:"A";a:3:{s:4:"type";s:4:"html";s:4:"span";s:11:"all,message";s:4:"name";s:3:"msg";}s:1:"B";a:1:{s:4:"type";s:5:"label";}}i:3;a:2:{s:1:"A";a:3:{s:4:"type";s:5:"label";s:4:"name";s:4:"name";s:4:"span";s:5:",name";}s:1:"B";a:4:{s:4:"type";s:5:"image";s:4:"name";s:7:"picture";s:5:"align";s:5:"right";s:4:"span";s:15:",resource_thumb";}}i:4;a:2:{s:1:"A";a:3:{s:4:"type";s:5:"label";s:4:"name";s:17:"short_description";s:4:"span";s:15:"all,description";}s:1:"B";a:1:{s:4:"type";s:5:"label";}}i:5;a:2:{s:1:"A";a:3:{s:4:"type";s:4:"html";s:4:"span";s:15:"all,description";s:4:"name";s:16:"long_description";}s:1:"B";a:1:{s:4:"type";s:5:"label";}}i:6;a:2:{s:1:"A";a:4:{s:4:"type";s:5:"label";i:1;a:3:{s:4:"type";s:4:"date";s:5:"label";s:4:"Date";s:4:"name";s:4:"date";}i:2;a:2:{s:4:"type";s:13:"date-timeonly";s:4:"name";s:4:"time";}s:5:"label";s:4:"Date";}s:1:"B";a:6:{s:4:"type";s:4:"hbox";s:4:"size";s:6:"4,,0,0";i:1;a:3:{s:4:"type";s:4:"date";s:4:"name";s:4:"date";s:8:"onchange";s:219:"var request = new egw_json_request(\'resources.resources_reserve.ajax_update_planner\',[document.getElementById(\'exec[res_id]\').value, Math.round(window.calendar.date.getTime()/1000)]);request.sendRequest(); return false;";}i:2;a:2:{s:4:"type";s:6:"select";s:4:"name";s:10:"time[hour]";}i:3;a:2:{s:4:"type";s:5:"label";s:5:"label";s:1:":";}i:4;a:3:{s:4:"type";s:13:"select-number";s:4:"name";s:12:"time[minute]";s:4:"size";s:21:",0,59,$cont[duration]";}}}i:7;a:2:{s:1:"A";a:3:{s:4:"type";s:8:"template";s:4:"span";s:3:"all";s:4:"name";s:13:"@contact_form";}s:1:"B";a:1:{s:4:"type";s:5:"label";}}i:8;a:2:{s:1:"A";a:2:{s:4:"type";s:5:"label";s:5:"label";s:4:"Name";}s:1:"B";a:4:{s:4:"type";s:4:"hbox";s:4:"size";s:6:"2,,0,0";i:1;a:3:{s:4:"type";s:4:"text";s:4:"name";s:7:"n_given";i:1;a:1:{s:4:"type";s:4:"hbox";}}i:2;a:2:{s:4:"type";s:4:"text";s:4:"name";s:8:"n_family";}}}i:9;a:2:{s:1:"A";a:2:{s:4:"type";s:5:"label";s:5:"label";s:5:"Email";}s:1:"B";a:4:{s:4:"type";s:9:"url-email";s:4:"size";s:2:"48";s:4:"name";s:5:"email";s:6:"needed";s:1:"1";}}i:10;a:2:{s:1:"A";a:2:{s:4:"type";s:5:"label";s:5:"label";s:10:"Party size";}s:1:"B";a:4:{s:4:"type";s:4:"hbox";s:4:"size";s:1:"2";i:1;a:2:{s:4:"type";s:3:"int";s:4:"name";s:8:"quantity";}i:2;a:4:{s:4:"type";s:6:"button";s:5:"label";s:4:"Book";s:5:"align";s:5:"right";s:4:"name";s:4:"book";}}}i:11;a:2:{s:1:"A";a:5:{s:4:"type";s:3:"box";s:4:"span";s:3:"all";s:4:"name";s:11:"planner_div";s:4:"size";s:1:"1";i:1;a:3:{s:4:"type";s:4:"html";s:4:"span";s:3:"all";s:4:"name";s:7:"planner";}}s:1:"B";a:1:{s:4:"type";s:5:"label";}}}s:4:"rows";i:11;s:4:"cols";i:2;s:4:"size";s:4:"100%";s:7:"options";a:1:{i:0;s:4:"100%";}}}}','size' => '','style' => '.resource_thumb img { -float:right; -position:absolute; -}','modified' => '1328133598',); - -$templ_data[] = array('name' => 'resources.test','template' => '','lang' => '','group' => '0','version' => '','data' => 'a:1:{i:0;a:4:{s:4:"type";s:4:"grid";s:4:"data";a:2:{i:0;a:0:{}i:1;a:1:{s:1:"A";a:3:{s:4:"type";s:16:"resources_select";s:4:"size";s:1:"5";s:4:"name";s:4:"test";}}}s:4:"rows";i:1;s:4:"cols";i:1;}}','size' => '','style' => '','modified' => '1249373358',); - diff --git a/resources/setup/setup.inc.php b/resources/setup/setup.inc.php index ae174f425c..0fce05fd5d 100755 --- a/resources/setup/setup.inc.php +++ b/resources/setup/setup.inc.php @@ -13,7 +13,7 @@ $setup_info['resources']['name'] = 'resources'; $setup_info['resources']['title'] = 'Resources'; -$setup_info['resources']['version'] = '14.1'; +$setup_info['resources']['version'] = '16.1'; $setup_info['resources']['app_order'] = 5; $setup_info['resources']['tables'] = array('egw_resources','egw_resources_extra'); $setup_info['resources']['enable'] = 1; @@ -37,12 +37,8 @@ $setup_info['resources']['hooks']['delete_category'] = 'resources.resources_hook $setup_info['resources']['hooks']['settings'] = 'resources_hooks::settings'; $setup_info['resources']['depends'][] = array( - 'appname' => 'phpgwapi', - 'versions' => Array('14.1') -); -$setup_info['resources']['depends'][] = array( // cause eTemplates is not in the api yet - 'appname' => 'etemplate', - 'versions' => Array('14.1') + 'appname' => 'api', + 'versions' => Array('16.1') ); diff --git a/resources/setup/tables_update.inc.php b/resources/setup/tables_update.inc.php index 59f6c7c6a4..2eb7dd685a 100755 --- a/resources/setup/tables_update.inc.php +++ b/resources/setup/tables_update.inc.php @@ -11,6 +11,9 @@ * @version $Id$ */ +use EGroupware\Api; +use EGroupware\Api\Vfs; + function resources_upgrade0_0_1_008() { $GLOBALS['phpgw_setup']->oProc->AddColumn('egw_resources','picture_src',array( @@ -291,24 +294,24 @@ function resources_upgrade1_2() */ function resources_upgrade1_4() { - egw_vfs::$is_root = true; - egw_vfs::load_wrapper('sqlfs'); - if (egw_vfs::is_dir('/resources/pictures')) + Vfs::$is_root = true; + Vfs::load_wrapper('sqlfs'); + if (Vfs::is_dir('/resources/pictures')) { - egw_vfs::remove('/resources/pictures/thumbs'); // remove thumb dir incl. thumbnails - foreach(egw_vfs::find('sqlfs://default/resources/pictures',array('url' => true)) as $url) + Vfs::remove('/resources/pictures/thumbs'); // remove thumb dir incl. thumbnails + foreach(Vfs::find('sqlfs://default/resources/pictures',array('url' => true)) as $url) { if (is_numeric($id = basename($url,'.jpg'))) { - if (!egw_vfs::is_dir($dir = "/apps/resources/$id")) + if (!Vfs::is_dir($dir = "/apps/resources/$id")) { - egw_vfs::mkdir($dir,0777,STREAM_MKDIR_RECURSIVE); + Vfs::mkdir($dir,0777,STREAM_MKDIR_RECURSIVE); } rename($url,'sqlfs://default'.$dir.'/.picture.jpg'); // we need to rename on the same wrapper! } } - egw_vfs::rmdir('/resources/pictures',0); - egw_vfs::rmdir('/resources',0); + Vfs::rmdir('/resources/pictures',0); + Vfs::rmdir('/resources',0); } return $GLOBALS['setup_info']['resources']['currentver'] = '1.6'; } @@ -323,9 +326,9 @@ function resources_upgrade1_6() function resources_upgrade1_8() { // add location category required for CalDAV to distinguish between locations and resources - $GLOBALS['egw_setup']->db->insert($GLOBALS['egw_setup']->cats_table,array('cat_parent' => 0, 'cat_owner' => categories::GLOBAL_ACCOUNT,'cat_access' => 'public','cat_appname' => 'resources','cat_name' => 'Locations','cat_description' => 'This category has been added by setup','last_mod' => time()),false,__LINE__,__FILE__); + $GLOBALS['egw_setup']->db->insert($GLOBALS['egw_setup']->cats_table,array('cat_parent' => 0, 'cat_owner' => Api\Categories::GLOBAL_ACCOUNT,'cat_access' => 'public','cat_appname' => 'resources','cat_name' => 'Locations','cat_description' => 'This category has been added by setup','last_mod' => time()),false,__LINE__,__FILE__); $locations_cat_id = $GLOBALS['egw_setup']->db->get_last_insert_id($GLOBALS['egw_setup']->cats_table,'cat_id'); - config::save_value('location_cats', $locations_cat_id, 'resources'); + Api\Config::save_value('location_cats', $locations_cat_id, 'resources'); // Give default group all rights to this general cat $defaultgroup = $GLOBALS['egw_setup']->add_account('Default','Default','Group',False,False); @@ -384,3 +387,7 @@ function resources_upgrade1_9_004() { return $GLOBALS['setup_info']['resources']['currentver'] = '14.1'; } +function resources_upgrade14_1() +{ + return $GLOBALS['setup_info']['resources']['currentver'] = '16.1'; +} \ No newline at end of file diff --git a/resources/sitemgr/class.module_resources_reservation.inc.php b/resources/sitemgr/class.module_resources_reservation.inc.php index b5c12eac9d..8dcf4e280e 100644 --- a/resources/sitemgr/class.module_resources_reservation.inc.php +++ b/resources/sitemgr/class.module_resources_reservation.inc.php @@ -9,6 +9,8 @@ * @version $Id$ */ +use EGroupware\Api; + /** * Needs permission to resources to read the resource, calendar app to properly push everything through */ @@ -21,7 +23,7 @@ class module_resources_reservation extends sitemgr_module $this->description = lang('Simple reservation of a single item'); $this->etemplate_method = 'resources.resources_reserve.book'; - $categories = new categories('', 'resources'); + $categories = new Api\Categories('', 'resources'); $cat_list = $categories->return_sorted_array(); $cat_options = array(); foreach($cat_list as $category) @@ -101,12 +103,12 @@ class module_resources_reservation extends sitemgr_module * * @param array &$arguments $arguments['arg1']-$arguments['arg3'] will be passed for non-submitted forms (first call) * @param array $properties - * @return string the html content + * @return string the Api\Html content */ function get_content(&$arguments,$properties) { list($app) = explode('.',$this->etemplate_method); - $GLOBALS['egw']->translation->add_app($app); + Api\Translation::add_app($app); $extra = "<style type=\"text/css\">\n<!--\n@import url(".$GLOBALS['egw_info']['server']['webserver_url']. "/etemplate/templates/default/app.css);\n";