From 05aa284f4ba0394685ffbe6c855698f929aeb7b2 Mon Sep 17 00:00:00 2001 From: franck Date: Thu, 19 Sep 2013 17:06:10 +0200 Subject: [PATCH] Fixed minor UI glithces --- templates/admin/default/categories.html | 8 +- templates/admin/default/category-edit.html | 99 +++++++++++++--------- 2 files changed, 61 insertions(+), 46 deletions(-) diff --git a/templates/admin/default/categories.html b/templates/admin/default/categories.html index 3c2e6f00a..68fd220b5 100755 --- a/templates/admin/default/categories.html +++ b/templates/admin/default/categories.html @@ -266,14 +266,14 @@ {loop type="image" name="cat_image" source="product" source_id="$ID" limit="1" width="50" height="50" resize_mode="crop" backend_context="1"} - + {$TITLE} {/loop} - {$REF} + {$REF} - {$TITLE} + {$TITLE} {module_include location='product_list_row'} @@ -305,7 +305,7 @@
{loop type="auth" name="can_change" roles="ADMIN" permissions="admin.product.edit"} - + {/loop} {loop type="auth" name="can_delete" roles="ADMIN" permissions="admin.product.delete"} diff --git a/templates/admin/default/category-edit.html b/templates/admin/default/category-edit.html index ddf39f5f2..a4a69ff3d 100755 --- a/templates/admin/default/category-edit.html +++ b/templates/admin/default/category-edit.html @@ -40,24 +40,23 @@
-
+
{form name="thelia.admin.category.modification"}
- {include file="includes/inner-form-toolbar.html" close_url="{url path='/admin/categories' category_id=$category_id}"} + {include file="includes/inner-form-toolbar.html" close_url="{url path='/admin/categories' category_id=$PARENT}"} {* Be sure to get the category ID, even if the form could not be validated *} @@ -141,7 +140,7 @@
-
+
@@ -149,9 +148,12 @@ {include file="includes/inner-form-toolbar.html" hide_submit_buttons=true - close_url="{url path='/admin/categories' category_id=$category_id}" + close_url="{url path='/admin/categories' category_id=$PARENT}" } +

{intl l='Related content'}

+

{intl l='You can attach here some content to this product'}

+ @@ -162,8 +164,8 @@
@@ -183,6 +185,12 @@ {intl l='Select a content and click (+) to add it to this category'}
+ +
+
+ {intl l="No available content in this folder"} +
+
@@ -200,7 +208,7 @@ {intl l='ID'} - {intl l='Attribute title'} + {intl l='Content title'} {module_include location='category_contents_table_header'} @@ -245,13 +253,13 @@
-
+
-
+
-
+
@@ -287,7 +295,7 @@ {block name="javascript-initialization"} - + @@ -317,12 +325,6 @@ $(function() { ev.preventDefault(); }); - // Show proper tab, if defined - {if ! empty($current_tab)} - $('#tabbed-menu a[href="#{$current_tab}"]').tab('show') - {/if} - - // Set proper content ID in delete content from $('a.delete-content').click(function(ev) { $('#content_delete_id').val($(this).data('id')); @@ -331,28 +333,41 @@ $(function() { // Load content on folder selection $('#folder_id').change(function(event) { - $.ajax({ - url : '{url path="/admin/category/$category_id/available-related-content/"}' + $(this).val() + '.xml', - type : 'get', - dataType : 'json', - success : function(json) { - $('#content_id :not(:first-child)').remove(); - var have_content = false; + var val = $(this).val(); - $.each(json, function(idx, value) { - $('#content_id').append($('