[freeside-commits] branch FREESIDE_3_BRANCH updated. cc31c0b9d0af6ef6986a0349ae083ca29820eeac
Ivan
ivan at 420.am
Wed Jan 29 14:34:44 PST 2014
The branch, FREESIDE_3_BRANCH has been updated
via cc31c0b9d0af6ef6986a0349ae083ca29820eeac (commit)
from e345aa297433b9653f42fc81145eb107c482a19d (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 cc31c0b9d0af6ef6986a0349ae083ca29820eeac
Author: Ivan Kohler <ivan at freeside.biz>
Date: Wed Jan 29 14:34:43 2014 -0800
fix for data in latest cch update, RT#26740
diff --git a/FS/FS/tax_rate.pm b/FS/FS/tax_rate.pm
index 095939f..c54f5a6 100644
--- a/FS/FS/tax_rate.pm
+++ b/FS/FS/tax_rate.pm
@@ -215,7 +215,7 @@ sub check {
$self->ut_numbern('taxnum')
|| $self->ut_text('geocode')
|| $self->ut_textn('data_vendor')
- || $self->ut_textn('location')
+ || $self->ut_cch_textn('location')
|| $self->ut_foreign_key('taxclassnum', 'tax_class', 'taxclassnum')
|| $self->ut_snumbern('effective_date')
|| $self->ut_float('tax')
@@ -229,7 +229,7 @@ sub check {
|| $self->ut_floatn('excessfee')
|| $self->ut_floatn('feemax')
|| $self->ut_numbern('maxtype')
- || $self->ut_textn('taxname')
+ || $self->ut_cch_textn('taxname')
|| $self->ut_numbern('taxauth')
|| $self->ut_numbern('basetype')
|| $self->ut_numbern('passtype')
@@ -245,6 +245,18 @@ sub check {
}
+#ut_text / ut_textn w/ ` added cause now that's in the data
+sub ut_cch_textn {
+ my($self,$field)=@_;
+ $self->getfield($field)
+ =~ /^([\wô \!\@\#\$\%\&\(\)\-\+\;\:\'\"\,\.\?\/\=\[\]\<\>\`]*)$/
+ or return gettext('illegal_or_empty_text'). " $field: ".
+ $self->getfield($field);
+ $self->setfield($field,$1);
+ '';
+
+}
+
=item taxclass_description
Returns the human understandable value associated with the related
-----------------------------------------------------------------------
Summary of changes:
FS/FS/tax_rate.pm | 16 ++++++++++++++--
1 files changed, 14 insertions(+), 2 deletions(-)
More information about the freeside-commits
mailing list