From c7be5710a60714a661c79f2f1eaa215edbe1c6a6 Mon Sep 17 00:00:00 2001 From: Romain Neutron Date: Wed, 21 Dec 2011 17:50:17 +0100 Subject: [PATCH] Fix upload page --- www/upload/index.php | 519 ++++++++++++++++++++++--------------------- 1 file changed, 260 insertions(+), 259 deletions(-) diff --git a/www/upload/index.php b/www/upload/index.php index 6e1f8c3b76..03cf044486 100755 --- a/www/upload/index.php +++ b/www/upload/index.php @@ -26,7 +26,6 @@ function filize($x) return '*.' . $x; } - User_Adapter::updateClientInfos(8); phrasea::headers(); @@ -41,7 +40,7 @@ if (count($avBases) == 0) { header("Content-Type: text/html; charset=UTF-8"); -?> + ?> @@ -61,279 +60,281 @@ if (count($avBases) == 0) color:white; } - - + + - display('common/menubar.twig', array('module' => 'upload')); - ?> + display('common/menubar.twig', array('module' => 'upload')); + ?> -
- -
- - +
+ +
+ + -get_databoxes() as $databox) +{ + $groupopen = false; + $sbas_id = $databox->get_sbas_id(); + + foreach ($databox->get_collections() as $collection) + { + if (in_array($collection->get_base_id(), $avBases)) + { + if (!$groupopen) + { + $colls .= ''; + $groupopen = true; + } + $colls .= ''; } - $colls = ''; - $datasSB = array(); - $dstatus = databox_status::getDisplayStatus(); - - foreach ($appbox->get_databoxes() as $databox) + if (in_array($collection->get_base_id(), $avStatus)) { - $groupopen = false; - $sbas_id = $databox->get_sbas_id(); - - foreach ($databox->get_collections() as $collection) + $status = '0000000000000000000000000000000000000000000000000000000000000000'; + if ($sxe = simplexml_load_string($collection->get_prefs())) { - if (in_array($collection->get_base_id(), $avBases)) + if ($sxe->status) { - if (!$groupopen) - { - $colls .= ''; - $groupopen = true; - } - $colls .= ''; - } + $status = databox_status::hex2bin((string) ($sxe->status)); - if (in_array($collection->get_base_id(), $avStatus)) - { - $status = '0000000000000000000000000000000000000000000000000000000000000000'; - if ($sxe = simplexml_load_string($collection->get_prefs())) - { - if ($sxe->status) - { - $status = databox_status::hex2bin((string) ($sxe->status)); - - while (strlen($status) < 64) - $status = '0' . $status; - } - } - - $datasSB[$collection->get_base_id()] = ''; + while (strlen($status) < 64) + $status = '0' . $status; } } - if ($groupopen) - $colls .= ''; + + $datasSB[$collection->get_base_id()] = ''; } + } + if ($groupopen) + $colls .= ''; +} - $maxVolume = min((int) get_cfg_var('upload_max_filesize'), (int) get_cfg_var('post_max_size')); +$maxVolume = min((int) get_cfg_var('upload_max_filesize'), (int) get_cfg_var('post_max_size')); - header("Content-Type: text/html; charset=UTF-8"); +header("Content-Type: text/html; charset=UTF-8"); ?> - - - <?php echo $registry->get('GV_homeTitle'), ' ', _('admin::monitor: module upload'); ?> - - - - + + + <?php echo $registry->get('GV_homeTitle'), ' ', _('admin::monitor: module upload'); ?> + + + + - + - - + - - - get_count(); - } - catch (Exception $e) - { + + + +get_count(); +} +catch (Exception $e) +{ + +} - } - - $twig = new supertwig(); - $twig->display('common/menubar.twig', array('module' => 'upload')); - ?> +$twig = new supertwig(); +$twig->display('common/menubar.twig' + , array( + 'module' => 'upload' + , 'events' => eventsmanager_broker::getInstance($appbox) +)); +?>
    @@ -364,7 +365,7 @@ if (count($avBases) == 0)
- +
@@ -387,14 +388,14 @@ if (count($avBases) == 0)
- -
- $dat) - { - echo $dat; - } - ?> + +
+ $dat) + { + echo $dat; + } + ?>
@@ -428,26 +429,26 @@ if (count($avBases) == 0)
-
-
- -
+
+ +
-
+