From 06ece674333772d48c1a88cb52e2076701fb2e24 Mon Sep 17 00:00:00 2001 From: mMarinetti Date: Wed, 16 Nov 2011 13:03:02 +0000 Subject: [PATCH] // javascript for warnings and errors message are now in footer.tpl --- admin-dev/themes/template/footer.tpl | 37 ++++++++++++++++++++++++-- admin-dev/themes/template/layout.tpl | 39 +++------------------------- 2 files changed, 39 insertions(+), 37 deletions(-) diff --git a/admin-dev/themes/template/footer.tpl b/admin-dev/themes/template/footer.tpl index 0dcc26130..41e6f7632 100644 --- a/admin-dev/themes/template/footer.tpl +++ b/admin-dev/themes/template/footer.tpl @@ -89,8 +89,41 @@ } }); }); // end bind - }); - + + // if count errors + $('#hideError').live('click', function(e) + { + e.preventDefault(); + $('.error').hide('slow', function (){ + $('.error').remove(); + }); + return false; + }); + + // if count warnings + $('#linkSeeMore').live('click', function(e){ + e.preventDefault(); + $('#seeMore').show('slow'); + $(this).hide(); + $('#linkHide').show(); + return false; + }); + $('#linkHide').live('click', function(e){ + e.preventDefault(); + $('#seeMore').hide('slow'); + $(this).hide(); + $('#linkSeeMore').show(); + return false; + }); + $('#hideWarn').live('click', function(e){ + e.preventDefault(); + $('.warn').hide('slow', function (){ + $('.warn').remove(); + }); + return false; + }); + + }); diff --git a/admin-dev/themes/template/layout.tpl b/admin-dev/themes/template/layout.tpl index 436aa1649..0b0b9720a 100644 --- a/admin-dev/themes/template/layout.tpl +++ b/admin-dev/themes/template/layout.tpl @@ -31,20 +31,11 @@ {/if} {if count($errors)} {* @todo what is ??? AND $this->_includeContainer *} -
- X + + X + + {if count($errors) == 1} {$errors[0]} {else} @@ -76,28 +67,6 @@ {/if} {if count($warnings)} -
X