[freeside-commits] branch master updated. 2177596bf13e9de77f09c7380d038200bd675f46
Jonathan Prykop
jonathan at 420.am
Mon Feb 2 20:03:21 PST 2015
The branch, master has been updated
via 2177596bf13e9de77f09c7380d038200bd675f46 (commit)
from 5b884dd940f7dce415ba77dcbc2ab6840f0b5673 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit 2177596bf13e9de77f09c7380d038200bd675f46
Author: Jonathan Prykop <jonathan at freeside.biz>
Date: Mon Feb 2 22:02:53 2015 -0600
RT#27425: Fixed/blank svc_phone domain
diff --git a/FS/FS/part_svc.pm b/FS/FS/part_svc.pm
index 2748686..f56878a 100644
--- a/FS/FS/part_svc.pm
+++ b/FS/FS/part_svc.pm
@@ -697,6 +697,8 @@ some components specified by "select-.*.html", and a bunch more...
=item select_label - Used with select_table, this is the field name of labels
+=item select_allow_empty - Used with select_table, adds an empty option
+
=back
=cut
diff --git a/FS/FS/svc_phone.pm b/FS/FS/svc_phone.pm
index 06ce948..71a61ad 100644
--- a/FS/FS/svc_phone.pm
+++ b/FS/FS/svc_phone.pm
@@ -196,6 +196,7 @@ sub table_info {
select_table => 'svc_domain',
select_key => 'svcnum',
select_label => 'domain',
+ select_allow_empty => 1,
disable_inventory => 1,
},
'circuit_svcnum' => { label => 'Circuit',
diff --git a/httemplate/edit/elements/part_svc_column.html b/httemplate/edit/elements/part_svc_column.html
index 53cda85..2bb4f5e 100644
--- a/httemplate/edit/elements/part_svc_column.html
+++ b/httemplate/edit/elements/part_svc_column.html
@@ -140,7 +140,8 @@ that field.
'value_col' => $def->{'select_key'},
'order_by' => dbdef->table($def->{'select_table'})->primary_key,
'multiple' => $def->{'multiple'},
- 'disable_empty' => 1,
+ 'disable_empty' => $def->{'select_allow_empty'} ? undef : 1,
+ 'empty_label' => $def->{'select_allow_empty'} ? ' ' : undef,
'curr_value' => $value,
# these can be switched between multiple and singular,
# so put the complete curr_value in an attribute
-----------------------------------------------------------------------
Summary of changes:
FS/FS/part_svc.pm | 2 ++
FS/FS/svc_phone.pm | 1 +
httemplate/edit/elements/part_svc_column.html | 3 ++-
3 files changed, 5 insertions(+), 1 deletion(-)
More information about the freeside-commits
mailing list