From 38aad287ebe7fc945203051aff477b049fa2418b Mon Sep 17 00:00:00 2001 From: plegall Date: Fri, 31 Dec 2010 15:19:11 +0000 Subject: feature 2089: finish removing element_set, now it's time for batch_manager git-svn-id: http://piwigo.org/svn/trunk@8417 68402e56-0260-453c-a942-63ccdbb3a9ee --- admin/batch_manager_global.php | 1 - admin/cat_list.php | 2 +- admin/cat_modify.php | 2 +- admin/element_set.php | 247 ----------- admin/element_set_global.php | 490 --------------------- admin/element_set_unit.php | 286 ------------ admin/include/functions.php | 14 +- admin/photos_add_direct.php | 4 +- .../themes/default/template/element_set_global.tpl | 227 ---------- admin/themes/default/template/element_set_unit.tpl | 151 ------- 10 files changed, 5 insertions(+), 1419 deletions(-) delete mode 100644 admin/element_set.php delete mode 100644 admin/element_set_global.php delete mode 100644 admin/element_set_unit.php delete mode 100644 admin/themes/default/template/element_set_global.tpl delete mode 100644 admin/themes/default/template/element_set_unit.tpl diff --git a/admin/batch_manager_global.php b/admin/batch_manager_global.php index c9305488d..2741096bf 100644 --- a/admin/batch_manager_global.php +++ b/admin/batch_manager_global.php @@ -42,7 +42,6 @@ check_status(ACCESS_ADMINISTRATOR); trigger_action('loc_begin_element_set_global'); -// the $_POST['selection'] was already checked in element_set.php check_input_parameter('del_tags', $_POST, true, PATTERN_ID); check_input_parameter('associate', $_POST, false, PATTERN_ID); check_input_parameter('dissociate', $_POST, false, PATTERN_ID); diff --git a/admin/cat_list.php b/admin/cat_list.php index b75b4d084..680550f90 100644 --- a/admin/cat_list.php +++ b/admin/cat_list.php @@ -311,7 +311,7 @@ foreach ($categories as $category) if ( array_key_exists($category['id'], $categories_with_images) ) { $tpl_cat['U_MANAGE_ELEMENTS']= - $base_url.'element_set&cat='.$category['id']; + $base_url.'batch_manager&cat='.$category['id']; } if ('private' == $category['status']) diff --git a/admin/cat_modify.php b/admin/cat_modify.php index b6e43a3b3..a30fea4ba 100644 --- a/admin/cat_modify.php +++ b/admin/cat_modify.php @@ -278,7 +278,7 @@ if ($category['has_images']) { $template->assign( 'U_MANAGE_ELEMENTS', - $base_url.'element_set&cat='.$category['id'] + $base_url.'batch_manager&cat='.$category['id'] ); $template->assign( 'U_MANAGE_RANKS', diff --git a/admin/element_set.php b/admin/element_set.php deleted file mode 100644 index 11bbcb2ac..000000000 --- a/admin/element_set.php +++ /dev/null @@ -1,247 +0,0 @@ - 0) - { - $query = ' -DELETE - FROM '.CADDIE_TABLE.' - WHERE element_id IN ('.implode(',', $_POST['selection']).') - AND user_id = '.$user['id'].' -;'; - pwg_query($query); - } - else - { - // TODO : add error - } - break; - } - case 'add_selected' : - { - if (isset($_POST['selection']) and count($_POST['selection']) > 0) - { - fill_caddie($_POST['selection']); - } - else - { - // TODO : add error - } - break; - } - } - } - else - { - // TODO : add error - } -} - -// +-----------------------------------------------------------------------+ -// | initialize info about category | -// +-----------------------------------------------------------------------+ - -// To element_set_(global|unit).php, we must provide the elements id of the -// managed category in $page['cat_elements_id'] array. -$page['cat_elements_id'] = array(); -if (is_numeric($_GET['cat'])) -{ - $page['title'] = - get_cat_display_name_from_id( - $_GET['cat'], - PHPWG_ROOT_PATH.'admin.php?page=cat_modify&cat_id=', - false - ); - - $query = ' -SELECT image_id - FROM '.IMAGE_CATEGORY_TABLE.' - WHERE category_id = '.$_GET['cat'].' -;'; - $page['cat_elements_id'] = array_from_query($query, 'image_id'); -} -else if ('caddie' == $_GET['cat']) -{ - $page['title'] = l10n('caddie'); - - $query = ' -SELECT element_id - FROM '.CADDIE_TABLE.' - WHERE user_id = '.$user['id'].' -;'; - $page['cat_elements_id'] = array_from_query($query, 'element_id'); -} -else if ('not_linked' == $_GET['cat']) -{ - $page['title'] = l10n('Not linked elements'); - $template->assign(array('U_ACTIVE_MENU' => 5 )); - - // we are searching elements not linked to any virtual category - $query = ' -SELECT id - FROM '.IMAGES_TABLE.' -;'; - $all_elements = array_from_query($query, 'id'); - - $linked_to_virtual = array(); - - $query = ' -SELECT id - FROM '.CATEGORIES_TABLE.' - WHERE dir IS NULL -;'; - $virtual_categories = array_from_query($query, 'id'); - if (!empty($virtual_categories)) - { - $query = ' -SELECT DISTINCT(image_id) - FROM '.IMAGE_CATEGORY_TABLE.' - WHERE category_id IN ('.implode(',', $virtual_categories).') -;'; - $linked_to_virtual = array_from_query($query, 'image_id'); - } - - $page['cat_elements_id'] = array_diff($all_elements, $linked_to_virtual); -} -else if ('duplicates' == $_GET['cat']) -{ - $page['title'] = l10n('Files with same name in more than one physical album'); - $template->assign(array('U_ACTIVE_MENU' => 5 )); - - // we are searching related elements twice or more to physical categories - // 1 - Retrieve Files - $query = ' -SELECT DISTINCT(file) - FROM '.IMAGES_TABLE.' - GROUP BY file -HAVING COUNT(DISTINCT storage_category_id) > 1 -;'; - - $duplicate_files = array_from_query($query, 'file'); - $duplicate_files[]='Nofiles'; - // 2 - Retrives related picture ids - $query = ' -SELECT id, file - FROM '.IMAGES_TABLE.' -WHERE file IN (\''.implode("','", $duplicate_files).'\') -ORDER BY file, id -;'; - - $page['cat_elements_id'] = array_from_query($query, 'id'); -} -elseif ('recent'== $_GET['cat']) -{ - $page['title'] = l10n('Recent pictures'); - $query = 'SELECT MAX(date_available) AS date - FROM '.IMAGES_TABLE; - $row = pwg_db_fetch_assoc(pwg_query($query)); - if (!empty($row['date'])) - { - $query = 'SELECT id - FROM '.IMAGES_TABLE.' - WHERE date_available BETWEEN '.pwg_db_get_recent_period_expression(1, $row['date']).' AND \''.$row['date'].'\''; - $page['cat_elements_id'] = array_from_query($query, 'id'); - } -} - -// +-----------------------------------------------------------------------+ -// | first element to display | -// +-----------------------------------------------------------------------+ - -// $page['start'] contains the number of the first element in its -// category. For exampe, $page['start'] = 12 means we must show elements #12 -// and $page['nb_images'] next elements - -if (!isset($_GET['start']) - or !is_numeric($_GET['start']) - or $_GET['start'] < 0 - or (isset($_GET['display']) and 'all' == $_GET['display'])) -{ - $page['start'] = 0; -} -else -{ - $page['start'] = $_GET['start']; -} - -// +-----------------------------------------------------------------------+ -// | open specific mode | -// +-----------------------------------------------------------------------+ - -$_GET['mode'] = !empty($_GET['mode']) ? $_GET['mode'] : 'global'; - -switch ($_GET['mode']) -{ - case 'global' : - { - include(PHPWG_ROOT_PATH.'admin/element_set_global.php'); - break; - } - case 'unit' : - { - include(PHPWG_ROOT_PATH.'admin/element_set_unit.php'); - break; - } -} -?> diff --git a/admin/element_set_global.php b/admin/element_set_global.php deleted file mode 100644 index 26eb57ca6..000000000 --- a/admin/element_set_global.php +++ /dev/null @@ -1,490 +0,0 @@ - 0) - { - $deleted_count = delete_elements($collection, true); - if ($deleted_count > 0) - { - array_push( - $page['infos'], - sprintf( - l10n_dec( - '%d photo was deleted', - '%d photos were deleted', - $deleted_count - ), - $deleted_count - ) - ); - } - else - { - array_push($page['errors'], l10n('No photo can be deleted')); - } - } - } - else - { - array_push($page['errors'], l10n('You need to confirm deletion')); - } -} - -// +-----------------------------------------------------------------------+ -// | global mode form submission | -// +-----------------------------------------------------------------------+ - -if (isset($_POST['submit'])) -{ - $collection = array(); - -// echo '
';
-//   print_r($_POST);
-//   echo '
'; -// exit(); - - switch ($_POST['target']) - { - case 'all' : - { - $collection = $page['cat_elements_id']; - break; - } - case 'selection' : - { - if (!isset($_POST['selection']) or count($_POST['selection']) == 0) - { - array_push($page['errors'], l10n('Select at least one picture')); - } - else - { - $collection = $_POST['selection']; - } - break; - } - } - - if (isset($_POST['add_tags']) and count($collection) > 0) - { - $tag_ids = get_fckb_tag_ids($_POST['add_tags']); - add_tags($tag_ids, $collection); - } - - if (isset($_POST['del_tags']) and count($collection) > 0) - { - $query = ' -DELETE - FROM '.IMAGE_TAG_TABLE.' - WHERE image_id IN ('.implode(',', $collection).') - AND tag_id IN ('.implode(',', $_POST['del_tags']).') -;'; - pwg_query($query); - } - - if ($_POST['associate'] != 0 and count($collection) > 0) - { - associate_images_to_categories( - $collection, - array($_POST['associate']) - ); - } - - if ($_POST['dissociate'] != 0 and count($collection) > 0) - { - // physical links must not be broken, so we must first retrieve image_id - // which create virtual links with the category to "dissociate from". - $query = ' -SELECT id - FROM '.IMAGE_CATEGORY_TABLE.' - INNER JOIN '.IMAGES_TABLE.' ON image_id = id - WHERE category_id = '.$_POST['dissociate'].' - AND id IN ('.implode(',', $collection).') - AND ( - category_id != storage_category_id - OR storage_category_id IS NULL - ) -;'; - $dissociables = array_from_query($query, 'id'); - - if (!empty($dissociables)) - { - $query = ' -DELETE - FROM '.IMAGE_CATEGORY_TABLE.' - WHERE category_id = '.$_POST['dissociate'].' - AND image_id IN ('.implode(',', $dissociables).') -'; - pwg_query($query); - - // we remove the dissociated images if we are currently displaying the - // category to dissociate from. - if (is_numeric($_GET['cat']) and $_POST['dissociate'] == $_GET['cat']) - { - $page['cat_elements_id'] = array_diff( - $page['cat_elements_id'], - $dissociables - ); - } - } - - update_category($_POST['dissociate']); - } - - $datas = array(); - $dbfields = array('primary' => array('id'), 'update' => array()); - - $formfields = array('author', 'name', 'date_creation', 'level'); - foreach ($formfields as $formfield) - { - if ($_POST[$formfield.'_action'] != 'leave') - { - array_push($dbfields['update'], $formfield); - } - } - - // updating elements is useful only if needed... - if (count($dbfields['update']) > 0 and count($collection) > 0) - { - $query = ' -SELECT id - FROM '.IMAGES_TABLE.' - WHERE id IN ('.implode(',', $collection).') -;'; - $result = pwg_query($query); - - while ($row = pwg_db_fetch_assoc($result)) - { - $data = array(); - $data['id'] = $row['id']; - - if ('set' == $_POST['author_action']) - { - $data['author'] = $_POST['author']; - if ('' == $data['author']) - { - unset($data['author']); - } - } - - if ('set' == $_POST['name_action']) - { - $data['name'] = $_POST['name']; - if ('' == $data['name']) - { - unset($data['name']); - } - } - - if ('set' == $_POST['date_creation_action']) - { - $data['date_creation'] = - $_POST['date_creation_year'] - .'-'.$_POST['date_creation_month'] - .'-'.$_POST['date_creation_day'] - ; - } - - if ('set' == $_POST['level_action']) - { - $data['level'] = $_POST['level']; - } - - array_push($datas, $data); - } - // echo '
'; print_r($datas); echo '
'; - mass_updates(IMAGES_TABLE, $dbfields, $datas); - } -} - -// +-----------------------------------------------------------------------+ -// | template init | -// +-----------------------------------------------------------------------+ -$template->set_filenames( - array('element_set_global' => 'element_set_global.tpl')); - -$base_url = get_root_url().'admin.php'; - -// $form_action = $base_url.'?page=element_set_global'; - -$template->assign( - array( - 'CATEGORIES_NAV'=>$page['title'], - - 'U_DISPLAY'=>$base_url.get_query_string_diff(array('display')), - - 'U_UNIT_MODE' - => - $base_url - .get_query_string_diff(array('mode','display')) - .'&mode=unit', - - 'F_ACTION'=>$base_url.get_query_string_diff(array()), - ) - ); - -// +-----------------------------------------------------------------------+ -// | caddie options | -// +-----------------------------------------------------------------------+ - -$template->assign('IN_CADDIE', 'caddie' == $_GET['cat'] ? true : false ); - -// +-----------------------------------------------------------------------+ -// | deletion form | -// +-----------------------------------------------------------------------+ - -// we can only remove photos that are not remote -if (count($page['cat_elements_id']) > 0) -{ - $query = ' -SELECT - COUNT(*) - FROM '.IMAGES_TABLE.' - WHERE id IN ('.implode(',', $page['cat_elements_id']).') - AND path NOT LIKE \'http%\' -;'; - list($counter) = pwg_db_fetch_row(pwg_query($query)); - - if ($counter > 0) - { - $template->assign('show_delete_form', true); - } -} - -// +-----------------------------------------------------------------------+ -// | global mode form | -// +-----------------------------------------------------------------------+ - -// Virtualy associate a picture to a category -$query = ' -SELECT id,name,uppercats,global_rank - FROM '.CATEGORIES_TABLE.' -;'; -display_select_cat_wrapper($query, array(), 'associate_options', true); - -// Dissociate from a category : categories listed for dissociation can -// only represent virtual links. Links to physical categories can't be -// broken -if (count($page['cat_elements_id']) > 0) -{ - $query = ' -SELECT - DISTINCT(category_id) AS id, - c.name, - c.uppercats, - c.global_rank - FROM '.IMAGE_CATEGORY_TABLE.' AS ic - JOIN '.CATEGORIES_TABLE.' AS c ON c.id = ic.category_id - JOIN '.IMAGES_TABLE.' AS i ON i.id = ic.image_id - WHERE ic.image_id IN ('.implode(',', $page['cat_elements_id']).') - AND ( - ic.category_id != i.storage_category_id - OR i.storage_category_id IS NULL - ) -;'; - display_select_cat_wrapper($query, array(), 'dissociate_options', true); -} - -if (count($page['cat_elements_id']) > 0) -{ - // remove tags - $tags = get_common_tags($page['cat_elements_id'], -1); - - $template->assign( - array( - 'DEL_TAG_SELECTION' => get_html_tag_selection($tags, 'del_tags'), - ) - ); -} - -// creation date -$day = -empty($_POST['date_creation_day']) ? date('j') : $_POST['date_creation_day']; - -$month = -empty($_POST['date_creation_month']) ? date('n') : $_POST['date_creation_month']; - -$year = -empty($_POST['date_creation_year']) ? date('Y') : $_POST['date_creation_year']; - -$month_list = $lang['month']; -$month_list[0]='------------'; -ksort($month_list); -$template->assign( array( - 'month_list' => $month_list, - 'DATE_CREATION_DAY' => (int)$day, - 'DATE_CREATION_MONTH'=> (int)$month, - 'DATE_CREATION_YEAR' => (int)$year, - ) - ); - -// image level options -$template->assign( - array( - 'level_options'=> get_privacy_level_options(), - 'level_options_selected' => 0, - ) - ); - -// +-----------------------------------------------------------------------+ -// | global mode thumbnails | -// +-----------------------------------------------------------------------+ - -// how many items to display on this page -if (!empty($_GET['display'])) -{ - if ('all' == $_GET['display']) - { - $page['nb_images'] = count($page['cat_elements_id']); - } - else - { - $page['nb_images'] = intval($_GET['display']); - } -} -else -{ - $page['nb_images'] = 20; -} - -if (count($page['cat_elements_id']) > 0) -{ - $nav_bar = create_navigation_bar( - $base_url.get_query_string_diff(array('start')), - count($page['cat_elements_id']), - $page['start'], - $page['nb_images'] - ); - $template->assign('navbar', $nav_bar); - - $query = ' -SELECT id,path,tn_ext,file,filesize,level - FROM '.IMAGES_TABLE; - - if (is_numeric($_GET['cat'])) - { - $category_info = get_cat_info($_GET['cat']); - - $conf['order_by'] = $conf['order_by_inside_category']; - if (!empty($category_info['image_order'])) - { - $conf['order_by'] = ' ORDER BY '.$category_info['image_order']; - } - - $query.= ' - JOIN '.IMAGE_CATEGORY_TABLE.' ON id = image_id'; - } - - $query.= ' - WHERE id IN ('.implode(',', $page['cat_elements_id']).')'; - - if (is_numeric($_GET['cat'])) - { - $query.= ' - AND category_id = '.$_GET['cat']; - } - - $query.= ' - '.$conf['order_by'].' - LIMIT '.$page['nb_images'].' OFFSET '.$page['start'].' -;'; - $result = pwg_query($query); - - // template thumbnail initialization - while ($row = pwg_db_fetch_assoc($result)) - { - $src = get_thumbnail_url($row); - - $template->append( - 'thumbnails', - array( - 'ID' => $row['id'], - 'TN_SRC' => $src, - 'FILE' => $row['file'], - 'TITLE' => get_thumbnail_title($row), - 'LEVEL' => $row['level'] - ) - ); - } -} - -trigger_action('loc_end_element_set_global'); - -//----------------------------------------------------------- sending html code -$template->assign_var_from_handle('ADMIN_CONTENT', 'element_set_global'); -?> diff --git a/admin/element_set_unit.php b/admin/element_set_unit.php deleted file mode 100644 index fa89db7f2..000000000 --- a/admin/element_set_unit.php +++ /dev/null @@ -1,286 +0,0 @@ - array('id'), - 'update' => array('name','author','level','comment','date_creation') - ), - $datas - ); - - array_push($page['infos'], l10n('Picture informations updated')); -} - -// +-----------------------------------------------------------------------+ -// | template init | -// +-----------------------------------------------------------------------+ - -$template->set_filenames( - array('element_set_unit' => 'element_set_unit.tpl')); - -$base_url = PHPWG_ROOT_PATH.'admin.php'; - -$month_list = $lang['month']; -$month_list[0]='------------'; -ksort($month_list); - -$template->assign( - array( - 'CATEGORIES_NAV'=>$page['title'], - 'U_ELEMENTS_PAGE' - =>$base_url.get_query_string_diff(array('display','start')), - 'U_GLOBAL_MODE' - => - $base_url - .get_query_string_diff(array('mode','display')) - .'&mode=global', - 'F_ACTION'=>$base_url.get_query_string_diff(array()), - 'month_list' => $month_list, - 'level_options' => get_privacy_level_options(), - ) - ); - -// +-----------------------------------------------------------------------+ -// | global mode thumbnails | -// +-----------------------------------------------------------------------+ - -// how many items to display on this page -if (!empty($_GET['display'])) -{ - if ('all' == $_GET['display']) - { - $page['nb_images'] = count($page['cat_elements_id']); - } - else - { - $page['nb_images'] = intval($_GET['display']); - } -} -else -{ - $page['nb_images'] = 5; -} - - - -if (count($page['cat_elements_id']) > 0) -{ - $nav_bar = create_navigation_bar( - $base_url.get_query_string_diff(array('start')), - count($page['cat_elements_id']), - $page['start'], - $page['nb_images'] - ); - $template->assign(array('navbar' => $nav_bar)); - - // tags - $all_tags = get_all_tags(); - - $element_ids = array(); - - $query = ' -SELECT id,path,tn_ext,name,date_creation,comment,author,level,file - FROM '.IMAGES_TABLE; - - if (is_numeric($_GET['cat'])) - { - $category_info = get_cat_info($_GET['cat']); - - $conf['order_by'] = $conf['order_by_inside_category']; - if (!empty($category_info['image_order'])) - { - $conf['order_by'] = ' ORDER BY '.$category_info['image_order']; - } - - $query.= ' - JOIN '.IMAGE_CATEGORY_TABLE.' ON id = image_id'; - } - - $query.= ' - WHERE id IN ('.implode(',', $page['cat_elements_id']).')'; - - if (is_numeric($_GET['cat'])) - { - $query.= ' - AND category_id = '.$_GET['cat']; - } - - $query.= ' - '.$conf['order_by'].' - LIMIT '.$page['nb_images'].' OFFSET '.$page['start'].' -;'; - $result = pwg_query($query); - - while ($row = pwg_db_fetch_assoc($result)) - { - array_push($element_ids, $row['id']); - - $src = get_thumbnail_url($row); - - // creation date - if (!empty($row['date_creation'])) - { - list($year,$month,$day) = explode('-', $row['date_creation']); - } - else - { - list($year,$month,$day) = array('',0,0); - } - - $query = ' -SELECT - tag_id, - name AS tag_name - FROM '.IMAGE_TAG_TABLE.' AS it - JOIN '.TAGS_TABLE.' AS t ON t.id = it.tag_id - WHERE image_id = '.$row['id'].' -;'; - $tag_selection = get_fckb_taglist($query); - - $template->append( - 'elements', - array( - 'ID' => $row['id'], - 'TN_SRC' => $src, - 'LEGEND' => !empty($row['name']) ? - $row['name'] : get_name_from_file($row['file']), - 'U_EDIT' => - PHPWG_ROOT_PATH.'admin.php?page=picture_modify'. - '&image_id='.$row['id'], - 'NAME' => !empty($row['name'])?$row['name']:'', - 'AUTHOR' => !empty($row['author'])?htmlspecialchars($row['author']):'', - 'LEVEL' => !empty($row['level'])?$row['level']:'0', - 'DESCRIPTION' => !empty($row['comment'])?$row['comment']:'', - 'DATE_CREATION_YEAR' => $year, - 'DATE_CREATION_MONTH' => (int)$month, - 'DATE_CREATION_DAY' => (int)$day, - 'TAGS' => $tag_selection, - ) - ); - } - - $template->assign('ELEMENT_IDS', implode(',', $element_ids)); -} - -trigger_action('loc_end_element_set_unit'); - -// +-----------------------------------------------------------------------+ -// | sending html code | -// +-----------------------------------------------------------------------+ - -$template->assign_var_from_handle('ADMIN_CONTENT', 'element_set_unit'); -?> \ No newline at end of file diff --git a/admin/include/functions.php b/admin/include/functions.php index 82c0b4804..5a949964e 100644 --- a/admin/include/functions.php +++ b/admin/include/functions.php @@ -1981,19 +1981,6 @@ function get_active_menu($menu_page) return $page['active_menu']; } - // specific cases - if ('element_set' == $menu_page) - { - if (isset($_GET['cat']) and is_numeric($_GET['cat'])) - { - return 1; - } - else - { - return 0; - } - } - switch ($menu_page) { case 'photos_add': @@ -2001,6 +1988,7 @@ function get_active_menu($menu_page) case 'rating': case 'tags': case 'picture_modify': + case 'batch_manager': return 0; case 'cat_list': diff --git a/admin/photos_add_direct.php b/admin/photos_add_direct.php index 727045c6a..298fa982b 100644 --- a/admin/photos_add_direct.php +++ b/admin/photos_add_direct.php @@ -55,7 +55,7 @@ DELETE FROM '.CADDIE_TABLE.' $inserts ); - redirect(get_root_url().'admin.php?page=element_set&cat=caddie'); + redirect(get_root_url().'admin.php?page=batch_manager&cat=caddie'); } // +-----------------------------------------------------------------------+ @@ -294,7 +294,7 @@ SELECT // a function get_image_name($name, $file) (if name is null, then // compute a temporary name from filename) that would be also used in // picture.php. UPDATE: in fact, "get_name_from_file($file)" already - // exists and is used twice (element_set_unit + comments, but not in + // exists and is used twice (batch_manager_unit + comments, but not in // picture.php I don't know why) with the same pattern if // (empty($name)) {$name = get_name_from_file($file)}, a clean // function get_image_name($name, $file) would be better diff --git a/admin/themes/default/template/element_set_global.tpl b/admin/themes/default/template/element_set_global.tpl deleted file mode 100644 index d2c08bf8b..000000000 --- a/admin/themes/default/template/element_set_global.tpl +++ /dev/null @@ -1,227 +0,0 @@ -{include file='include/tag_selection.inc.tpl'} -{include file='include/datepicker.inc.tpl'} - -{footer_script}{literal} - pwg_initialization_datepicker("#date_creation_day", "#date_creation_month", "#date_creation_year", "#date_creation_linked_date", "#date_creation_action_set"); -{/literal}{/footer_script} - -{combine_script id='jquery.fcbkcomplete' load='async' require='jquery' path='themes/default/js/plugins/jquery.fcbkcomplete.js'} -{footer_script require='jquery.fcbkcomplete'}{literal} -jQuery(document).ready(function() { - jQuery("#tags").fcbkcomplete({ - json_url: "admin.php?fckb_tags=1", - cache: false, - filter_case: false, - filter_hide: true, - firstselected: true, - filter_selected: true, - maxitems: 100, - newel: true - }); -}); -{/literal}{/footer_script} - -

{'Batch management'|@translate}

- -

{$CATEGORIES_NAV}

- -{if !empty($thumbnails)} -

- {'global mode'|@translate} - | {'unit mode'|@translate} -

- -
- - {'Display options'|@translate} - -

{'elements per page'|@translate}: - 20 - | 50 - | 100 - | {'all'|@translate} -

- -
- -
- -
- - {'Elements'|@translate} - - {if !empty($navbar) }{include file='navigation_bar.tpl'|@get_extent:'navbar'}{/if} - - {if !empty($thumbnails)} -
    - {foreach from=$thumbnails item=thumbnail} -
  • - - -
  • - {/foreach} -
- {/if} - -
- - {if isset($show_delete_form) } -
- {'Deletions'|@translate} -

- {'target'|@translate} - - -

-

- - -

-
- {/if} - -
- - {'Form'|@translate} - - - - - - - - - - - - - - - - - - - {if !empty($DEL_TAG_SELECTION)} - - - - - {/if} - - - - - - - - - - - - - - - - - - - - - -
{'Associate to album'|@translate} - -
{'Dissociate from album'|@translate} - -
{'add tags'|@translate} - -
{'remove tags'|@translate}{$DEL_TAG_SELECTION}
{'Author'|@translate} - - - - -
{'title'|@translate} - - - - -
{'Creation date'|@translate} - - - - - - - -
{'Who can see these photos?'|@translate} - - - -
- -

- {'target'|@translate} - - -

- - -

- -
- -
- - {'Caddie management'|@translate} - -
    - {if ($IN_CADDIE)} -
  • -
  • - {else} -
  • - {/if} -
- -

- -
- -
- -{else} -

{'Caddie is currently empty'|@translate}

-{/if} diff --git a/admin/themes/default/template/element_set_unit.tpl b/admin/themes/default/template/element_set_unit.tpl deleted file mode 100644 index dd2080667..000000000 --- a/admin/themes/default/template/element_set_unit.tpl +++ /dev/null @@ -1,151 +0,0 @@ - -{include file='include/autosize.inc.tpl'} -{include file='include/datepicker.inc.tpl'} - -{combine_script id='jquery.fcbkcomplete' load='async' require='jquery' path='themes/default/js/plugins/jquery.fcbkcomplete.js'} -{footer_script require='jquery.fcbkcomplete'} -var tag_boxes_selector = ""; -{foreach from=$elements item=element name=element} -{if $smarty.foreach.element.first} -var prefix = ""; -{else} -prefix = ", "; -{/if} - tag_boxes_selector = tag_boxes_selector + prefix + "#tags-" + {$element.ID}; -{/foreach} -{literal} -jQuery(document).ready(function() { - $(tag_boxes_selector).fcbkcomplete({ - json_url: "admin.php?fckb_tags=1", - cache: false, - filter_case: false, - filter_hide: true, - firstselected: true, - filter_selected: true, - maxitems: 100, - newel: true - }); -}); -{/literal}{/footer_script} - -

{'Batch management'|@translate}

- -

{$CATEGORIES_NAV}

- -

- {'global mode'|@translate} - | {'unit mode'|@translate} -

- -
-
- {'Display options'|@translate} -

{'elements per page'|@translate} : - 5 - | 10 - | 50 - | {'all'|@translate} -

- -
- -{if !empty($navbar) }{include file='navigation_bar.tpl'|@get_extent:'navbar'}{/if} - -{if !empty($elements) } -
-{foreach from=$elements item=element} -
- {$element.LEGEND} - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
{'Name'|@translate}
{'Author'|@translate}
{'Creation date'|@translate} - - - - - - - - {footer_script} - pwg_initialization_datepicker("#date_creation_day-{$element.ID}", "#date_creation_month-{$element.ID}", "#date_creation_year-{$element.ID}", "#date_creation_linked_date-{$element.ID}", "#date_creation_action_set-{$element.ID}"); - {/footer_script} -
{'Who can see this photo?'|@translate} - -
{'Tags'|@translate} - - - -
{'Description'|@translate}
- -
-{/foreach} - -

- - -

-{/if} - -
- - -- cgit v1.2.3