summaryrefslogtreecommitdiff
path: root/rt/lib
diff options
context:
space:
mode:
authorMark Wells <mark@freeside.biz>2013-01-03 12:47:41 -0800
committerMark Wells <mark@freeside.biz>2013-01-03 12:47:41 -0800
commit949114e0f65232b405e084bcfcff37b1fd9a2926 (patch)
tree529d2f1f951c7ccd4420220fe0fdb4d583409155 /rt/lib
parent47835e6fb2ff9da30bd95ce10f1f22a3ce1cb8b5 (diff)
more reasonable solution for #17067
Diffstat (limited to 'rt/lib')
-rw-r--r--rt/lib/RT/URI/freeside/Internal.pm28
1 files changed, 13 insertions, 15 deletions
diff --git a/rt/lib/RT/URI/freeside/Internal.pm b/rt/lib/RT/URI/freeside/Internal.pm
index 61b256ef9..b0962860d 100644
--- a/rt/lib/RT/URI/freeside/Internal.pm
+++ b/rt/lib/RT/URI/freeside/Internal.pm
@@ -143,7 +143,7 @@ sub small_custview {
}
-sub _FreesideURILabelLong {
+sub AsStringLong {
my $self = shift;
@@ -161,30 +161,28 @@ sub _FreesideURILabelLong {
} elsif ( $table eq 'cust_svc' ) {
my $string = '';
- # we now do this within the UI
- #my $cust = $self->CustomerResolver;
- #if ( $cust ) {
- # $string = $cust->AsStringLong;
- #}
- $string .= $self->AsString;
+ my $cust = $self->CustomerResolver;
+ if ( $cust ) {
+ # the customer's small_custview
+ $string = $cust->AsStringLong();
+ }
+ # + the service label and link
+ $string .= $self->ShortLink;
return $string;
} else {
- return $self->_FreesideURILabel();
+ return $self->SUPER::AsStringLong;
}
}
-sub AsString {
+sub ShortLink {
+ # because I don't want AsString to sometimes return a hunk of HTML, but
+ # on the other hand AsStringLong does something specific.
my $self = shift;
- if ( $self->{'fstable'} eq 'cust_svc' ) {
- return '<B><A HREF="' . $self->HREF . '">' .
- $self->_FreesideURILabel . '</A></B>';
- } else {
- $self->SUPER::AsString;
- }
+ '<B><A HREF="'.$self->HREF.'">' . $self->_FreesideURILabel . '</A></B>';
}
sub CustomerResolver {