Change assetManager search to work like assetManager manage. Fixes bug #11272

Force all actions to be routed through asset methods with Csrf and
permission checks.
This commit is contained in:
Colin Kuskie 2009-11-24 21:38:58 -08:00
parent da6743c211
commit f96c2f7af1
4 changed files with 65 additions and 50 deletions

View file

@ -1402,6 +1402,21 @@ sub getRoot {
}
#-------------------------------------------------------------------
=head2 getSearchUrl ( )
Returns the URL for the search screen of the asset manager.
=cut
sub getSearchUrl {
my $self = shift;
return $self->getUrl( 'op=assetManager;method=search' );
}
#-------------------------------------------------------------------
=head2 getSeparator
@ -2891,8 +2906,7 @@ sub www_editSave {
=head2 www_manageAssets ( )
Redirect to the asset manager content handler (for backwards
compatibility)
Redirect to the asset manager content handler (for backwards compatibility)
=cut
@ -2904,6 +2918,21 @@ sub www_manageAssets {
#-------------------------------------------------------------------
=head2 www_searchAssets ( )
Redirect to the asset manager content handler (for backwards
compatibility)
=cut
sub www_searchAssets {
my $self = shift;
$self->session->http->setRedirect( $self->getSearchUrl );
return "redirect";
}
#-------------------------------------------------------------------
=head2 www_view ( )
Returns the view() method of the asset object if the requestor canView.