diff options
author | Ivan Kohler <ivan@freeside.biz> | 2013-10-08 23:00:26 -0700 |
---|---|---|
committer | Ivan Kohler <ivan@freeside.biz> | 2013-10-08 23:00:26 -0700 |
commit | fe4515eb37d76849dd08c62782d86bc7ba311dcd (patch) | |
tree | 6952cc3598de0c72b6a3eab1d53bde07a16c27f2 /bin | |
parent | f2766e203e1aa144d046a26cf13e01e1f5b00f64 (diff) | |
parent | 81ae0992cf8506c6a77485548ebde25eb946a9a9 (diff) |
Merge branch 'master' of git.freeside.biz:/home/git/freeside
Conflicts:
FS/FS/cust_main.pm
Diffstat (limited to 'bin')
-rwxr-xr-x | bin/generate-table-module | 4 | ||||
-rwxr-xr-x | bin/standardize-locations | 25 | ||||
-rwxr-xr-x[-rw-r--r--] | bin/test-event | 5 |
3 files changed, 31 insertions, 3 deletions
diff --git a/bin/generate-table-module b/bin/generate-table-module index b536360c5..37a581200 100755 --- a/bin/generate-table-module +++ b/bin/generate-table-module @@ -95,10 +95,10 @@ close TEST; # add them to MANIFEST ### -#system('cvs edit FS/MANIFEST'); - open(MANIFEST,">>FS/MANIFEST") or die $!; print MANIFEST "FS/$table.pm\n", "t/$table.t\n"; close MANIFEST; +system("git add FS/FS/$table.pm FS/t/$table.t"); + diff --git a/bin/standardize-locations b/bin/standardize-locations new file mode 100755 index 000000000..6e5fd3c16 --- /dev/null +++ b/bin/standardize-locations @@ -0,0 +1,25 @@ +#!/usr/bin/perl -w + +use strict; +use FS::UID 'adminsuidsetup'; +use FS::Conf; +use FS::queue; + +my $user = shift or die "usage:\n standardize-locations user"; +adminsuidsetup($user); +my $conf = FS::Conf->new; +my $method = $conf->config('address_standardize_method') + or die "No address standardization method configured.\n"; +if ($method eq 'usps') { + # we're not supposed to do this + # (allow it anyway with a warning?) + die "USPS standardization does not allow batch processing.\n"; +} +my $job = FS::queue->new({ + job => 'FS::cust_location::process_standardize' +}); +my $error = $job->insert('_JOB'); +die $error if $error; +print "Address standardization job scheduled.\n"; + +1; diff --git a/bin/test-event b/bin/test-event index d3a9f110d..73c9d31ec 100644..100755 --- a/bin/test-event +++ b/bin/test-event @@ -34,7 +34,10 @@ print "\n"; my @conditions = $part_event->part_event_condition; foreach my $condition ( @conditions ) { - my $sat = $condition->condition( $object, 'cust_event' => $cust_event ); + my $sat = $condition->condition( $object, + 'cust_event' => $cust_event, + 'time' => time, + ); my $sql = $condition->condition_sql(); |