From f76842f705192fc4d5cb8f911c1c14a5ec02ddf3 Mon Sep 17 00:00:00 2001 From: Colin Kuskie Date: Tue, 29 Dec 2009 12:05:31 -0800 Subject: [PATCH] Tinkering with url. --- lib/WebGUI/Asset.pm | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/lib/WebGUI/Asset.pm b/lib/WebGUI/Asset.pm index 3adfd6d1c..316d1884d 100644 --- a/lib/WebGUI/Asset.pm +++ b/lib/WebGUI/Asset.pm @@ -84,6 +84,7 @@ around url => sub { if (@_ > 0) { my $url = $_[0]; $url = $self->fixUrl($url); + unshift @_, $url; } $self->$orig(@_); }; @@ -213,6 +214,11 @@ property inheritUrlFromParent => ( fieldType => 'yesNo', defaultValue => 0, ); +after inheritUrlFromParent => sub { + my $self = shift; + return unless $self->inheritUrlFromParent; + $self->url($self->url); +}; property status => ( noFormPost => 1, fieldType => 'text',