diff --git a/Netdisco/Changes b/Netdisco/Changes index 9543a59c..92e6aae7 100644 --- a/Netdisco/Changes +++ b/Netdisco/Changes @@ -1,3 +1,9 @@ +2.020001 - 2013-12-08 + + [BUG FIXES] + + * Plugin CSS and JS included file fix + 2.020000 - 2013-12-08 [NEW FEATURES] diff --git a/Netdisco/lib/App/Netdisco/Web/Static.pm b/Netdisco/lib/App/Netdisco/Web/Static.pm index 0522386e..8138f340 100644 --- a/Netdisco/lib/App/Netdisco/Web/Static.pm +++ b/Netdisco/lib/App/Netdisco/Web/Static.pm @@ -7,7 +7,7 @@ get '/plugin/*/*.js' => sub { my ($plugin) = splat; my $content = template - "plugin/$plugin/$plugin.js", {}, + 'plugin.tt', { target => "plugin/$plugin/$plugin.js" }, { layout => undef }; send_file \$content, @@ -19,7 +19,7 @@ get '/plugin/*/*.css' => sub { my ($plugin) = splat; my $content = template - "plugin/$plugin/$plugin.css", {}, + 'plugin.tt', { target => "plugin/$plugin/$plugin.css" }, { layout => undef }; send_file \$content, diff --git a/Netdisco/share/views/plugin.tt b/Netdisco/share/views/plugin.tt new file mode 100644 index 00000000..15f89fff --- /dev/null +++ b/Netdisco/share/views/plugin.tt @@ -0,0 +1,5 @@ +[% TRY %] +[% INCLUDE $target %] +[% CATCH %] + +[% END %]