projects
/
freeside.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
d46254f
)
give discounts a default name, #31273
author
Mark Wells
<mark@freeside.biz>
Sat, 31 Jan 2015 23:29:30 +0000
(15:29 -0800)
committer
Mark Wells
<mark@freeside.biz>
Sun, 1 Feb 2015 00:29:54 +0000
(16:29 -0800)
FS/FS/discount.pm
patch
|
blob
|
history
diff --git
a/FS/FS/discount.pm
b/FS/FS/discount.pm
index
4c9898a
..
1491139
100644
(file)
--- a/
FS/FS/discount.pm
+++ b/
FS/FS/discount.pm
@@
-175,7
+175,12
@@
sub description_short {
my $conf = new FS::Conf;
my $money_char = $conf->config('money_char') || '$';
- my $desc = $self->name ? $self->name.': ' : '';
+ my $desc;
+ if ( $self->name ) {
+ $desc = $self->name . ': ';
+ } else {
+ $desc = 'Discount of ';
+ }
$desc .= $money_char. sprintf('%.2f/month', $self->amount)
if $self->amount > 0;