X-Git-Url: http://wagnertech.de/gitweb/gitweb.cgi/mfinanz.git/blobdiff_plain/6061749dc0ece2873ef61a0c14af1b8a9e46034a..6e1582b8d7511735d585d22680e94f7c1963105b:/SL/Controller/Base.pm diff --git a/SL/Controller/Base.pm b/SL/Controller/Base.pm index 2d86f0f96..876aac30f 100644 --- a/SL/Controller/Base.pm +++ b/SL/Controller/Base.pm @@ -60,6 +60,9 @@ sub render { my $template = shift; my ($options, %locals) = (@_ && ref($_[0])) ? @_ : ({ }, @_); + # Special handling/shortcut for an instance of SL::ClientJS: + return $self->render(\$template->to_json, { type => 'json' }) if ref($template) eq 'SL::ClientJS'; + # Set defaults for all available options. my %defaults = ( type => 'html',