From 7f274741595286a2c24dd1099751caffb54043e9 Mon Sep 17 00:00:00 2001 From: Ingo Schommer Date: Thu, 14 Jun 2012 20:36:36 +0200 Subject: [PATCH] BUGFIX Show AssetAdmin tree by not invoking $EditForm twice in template Both for performance reasons, and for weird behaviour on the second invocation (doesn't retain the same record context) --- templates/Includes/AssetAdmin_Content.ss | 47 +++++++++++------------- 1 file changed, 22 insertions(+), 25 deletions(-) diff --git a/templates/Includes/AssetAdmin_Content.ss b/templates/Includes/AssetAdmin_Content.ss index d3ed9c41..d14eb09d 100644 --- a/templates/Includes/AssetAdmin_Content.ss +++ b/templates/Includes/AssetAdmin_Content.ss @@ -1,36 +1,33 @@
+ <% with EditForm %>
- <% with EditForm %> -
- <% include BackLink_Button %> +
+ <% include BackLink_Button %> -

- <% with Controller %> - <% include CMSBreadcrumbs %> - <% end_with %> -

+

+ <% with Controller %> + <% include CMSBreadcrumbs %> + <% end_with %> +

+
+ <% if Fields.hasTabset %> + <% with Fields.fieldByName('Root') %> +
+
    + <% loop Tabs %> + class="$extraClass"<% end_if %>>$Title + <% end_loop %> +
- <% if Fields.hasTabset %> - <% with Fields.fieldByName('Root') %> -
-
    - <% loop Tabs %> - class="$extraClass"<% end_if %>>$Title - <% end_loop %> -
-
- <% end_with %> - <% end_if %> - <% end_with %> + <% end_with %> + <% end_if %>
- - $Tools - - $EditForm - + $Top.Tools + $forTemplate
+ <% end_with %>
\ No newline at end of file