projects
/
freeside.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
RT#39115: View SNMP info on svc_broadband service [timeout fix & multiple value handling]
[freeside.git]
/
bin
/
billco-upload
diff --git
a/bin/billco-upload
b/bin/billco-upload
index
165eafa
..
a5f67cd
100644
(file)
--- a/
bin/billco-upload
+++ b/
bin/billco-upload
@@
-1,14
+1,15
@@
-#!/
bin/sh
+#!/
usr/bin/perl
-date=`date +"%Y%m%d"`
-dir="/usr/local/etc/freeside/export.DBI:Pg:dbname=freeside/cust_bill"
-cd "$dir"
+use FS::UID qw(adminsuidsetup);
+use FS::Cron::upload;
-for a in header detail; do
- mv spool-$a.csv $date-$a.csv
-done
+adminsuidsetup shift or die "usage: billco-upload username agentnum\n";
+my $agentnum = shift or die "usage: billco-upload username agentnum\n";
-echo zip $date.zip $date-header.csv $date-detail.csv
-
-echo $dir/$date.zip
+FS::Cron::upload::billco_upload( 'agentnum' => $agentnum,
+ 'date' => time,
+ 'v' => 1,
+ 'l' => 2,
+ );
+1;