From c8d3cff6e3026ac4f5dc59930220489ebe3d542f Mon Sep 17 00:00:00 2001 From: ivan Date: Fri, 9 Jan 2004 22:15:36 +0000 Subject: correct tyop --- FS/FS/Conf.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/FS/FS/Conf.pm b/FS/FS/Conf.pm index 11243a91b..467a856c1 100644 --- a/FS/FS/Conf.pm +++ b/FS/FS/Conf.pm @@ -1159,7 +1159,7 @@ httemplate/docs/config.html }, { - 'key' => 'system_usernames' + 'key' => 'system_usernames', 'section' => 'username', 'description' => 'A list of system usernames that cannot be edited or removed, one per line. Use a bare username to prohibit modification/deletion of the username in any domain, or username@domain to prohibit modification/deletetion of a specific username and domain.', 'type' => 'textarea', -- cgit v1.2.1 From c085c3ba3bd0677719407ce613dd24466f05abe2 Mon Sep 17 00:00:00 2001 From: ivan Date: Fri, 9 Jan 2004 22:39:22 +0000 Subject: credit deletions: need to use Date::Format and FS::Misc qw(send_email) in cust_credit.pm, need a link to delete unapplied credits too --- FS/FS/cust_credit.pm | 2 ++ httemplate/view/cust_main.cgi | 6 +++++- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/FS/FS/cust_credit.pm b/FS/FS/cust_credit.pm index 90f9b59ed..19a54534f 100644 --- a/FS/FS/cust_credit.pm +++ b/FS/FS/cust_credit.pm @@ -2,8 +2,10 @@ package FS::cust_credit; use strict; use vars qw( @ISA $conf $unsuspendauto ); +use Date::Format; use FS::UID qw( dbh getotaker ); use FS::Record qw( qsearch qsearchs ); +use FS::Misc qw(send_email); use FS::cust_main; use FS::cust_refund; use FS::cust_credit_bill; diff --git a/httemplate/view/cust_main.cgi b/httemplate/view/cust_main.cgi index 8123b2f82..ee5f86973 100755 --- a/httemplate/view/cust_main.cgi +++ b/httemplate/view/cust_main.cgi @@ -668,12 +668,16 @@ if ( $conf->config('payby-default') ne 'HIDE' ) { qsearch('cust_credit',{'custnum'=>$custnum}); foreach my $credit (@credits) { my($cref)=$credit->hashref; + my $delete = + $credit->closed !~ /^Y/i && $conf->exists('deletecredits') + ? qq! (delete)! + : ''; push @history, $cref->{_date} . "\t" . qq!!. 'Unapplied credit #' . $cref->{crednum} . ": ". - $cref->{reason} . "\t\t\t" . $credit->credited . "\t"; + $cref->{reason} . "$delete\t\t\t" . $credit->credited . "\t"; } my(@refunds)=qsearch('cust_refund',{'custnum'=> $custnum } ); -- cgit v1.2.1 From 86794f71a5fec8cbb6ab3a49d9bfe7fdaf21d183 Mon Sep 17 00:00:00 2001 From: ivan Date: Fri, 9 Jan 2004 22:46:48 +0000 Subject: add customer number --- httemplate/search/report_receivables.cgi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/httemplate/search/report_receivables.cgi b/httemplate/search/report_receivables.cgi index 66928ebbb..ad353a1b3 100755 --- a/httemplate/search/report_receivables.cgi +++ b/httemplate/search/report_receivables.cgi @@ -130,7 +130,7 @@ END } %> - + <%= $row->{'custnum'} %>: <%= $row->{'company'} ? $row->{'company'}. ' (' : '' %><%= $row->{'last'}. ', '. $row->{'first'} %><%= $row->{'company'} ? ')' : '' %> <%= $status %> -- cgit v1.2.1 From f0bcdae0719f2634df3c51bd3f21906de14817d4 Mon Sep 17 00:00:00 2001 From: ivan Date: Sat, 10 Jan 2004 03:50:59 +0000 Subject: fix UI: displaying "Add" on invoice event edits --- httemplate/edit/part_bill_event.cgi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/httemplate/edit/part_bill_event.cgi b/httemplate/edit/part_bill_event.cgi index 6426eed93..48ed7916b 100755 --- a/httemplate/edit/part_bill_event.cgi +++ b/httemplate/edit/part_bill_event.cgi @@ -20,7 +20,7 @@ if ( $query && $query =~ /^(\d+)$/ ) { } else { $part_bill_event ||= new FS::part_bill_event {}; } -$action ||= $part_bill_event->pkgpart ? 'Edit' : 'Add'; +$action ||= $part_bill_event->eventpart ? 'Edit' : 'Add'; my $hashref = $part_bill_event->hashref; print header("$action Invoice Event Definition", menubar( -- cgit v1.2.1 From 4b5d23a37ae4d83695c79ca02718250f317b7f74 Mon Sep 17 00:00:00 2001 From: ivan Date: Sat, 10 Jan 2004 04:19:06 +0000 Subject: don't require payname for DCHK either --- FS/FS/cust_main.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/FS/FS/cust_main.pm b/FS/FS/cust_main.pm index 3e40cc127..86962ce61 100644 --- a/FS/FS/cust_main.pm +++ b/FS/FS/cust_main.pm @@ -880,7 +880,7 @@ sub check { if !$import && ( $y<$nowy || ( $y==$nowy && $1<$nowm ) ); } - if ( $self->payname eq '' && $self->payby ne 'CHEK' && + if ( $self->payname eq '' && $self->payby !~ /^(CHEK|DCHK)$/ && ( ! $conf->exists('require_cardname') || $self->payby !~ /^(CARD|DCRD)$/ ) ) { -- cgit v1.2.1 From 2ee78e49dd604c6269463fd0431bb7bf361a170a Mon Sep 17 00:00:00 2001 From: ivan Date: Sat, 10 Jan 2004 11:17:45 +0000 Subject: workaround stubborn shells globbing [a-z] to include CVS/ --- Makefile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 42dba360f..2c2b7a5be 100644 --- a/Makefile +++ b/Makefile @@ -164,7 +164,8 @@ create-config: install-perl-modules mkdir "${FREESIDE_CONF}/conf.${DATASOURCE}" rm -rf conf/registries #old dirs just won't go away - cp conf/[a-z]* "${FREESIDE_CONF}/conf.${DATASOURCE}" + #cp conf/[a-z]* "${FREESIDE_CONF}/conf.${DATASOURCE}" + cp `ls -d conf/[a-z]* | grep -v CVS` "${FREESIDE_CONF}/conf.${DATASOURCE}" chown -R freeside "${FREESIDE_CONF}/conf.${DATASOURCE}" mkdir "${FREESIDE_CONF}/counters.${DATASOURCE}" -- cgit v1.2.1 From e09c90ae3aa34e1e5a98bf024d99fbd07a50c3e4 Mon Sep 17 00:00:00 2001 From: ivan Date: Sat, 10 Jan 2004 11:32:24 +0000 Subject: update paths --- install/redhat/9/INSTALL | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/install/redhat/9/INSTALL b/install/redhat/9/INSTALL index 2fecd1164..813f6947b 100644 --- a/install/redhat/9/INSTALL +++ b/install/redhat/9/INSTALL @@ -30,9 +30,9 @@ perl -MCPAN -e"install Locale::Country, Net::Whois, Business::CreditCard, \ #edit /etc/init.d/httpd, add -DHAVE_PERL -DHAVE_SSL, then remove perl & ssl # module load bits from /etc/httpd/conf/httpd.conf -useradd freeside +/usr/sbin/useradd freeside -chkconfig postgresql on +/sbin/chkconfig postgresql on /etc/init.d/postgresql start su postgres -c "createuser -P freeside" @@ -40,7 +40,7 @@ su postgres -c "createuser -P freeside" su freeside -c "createdb freeside" #? -cd ../.. +cd ../../.. make install-perl-modules make create-config freeside-adduser -c -h /usr/local/etc/freeside/htpasswd ivan -- cgit v1.2.1 From 01c33bcdfa27576bee4ab922095749794a6b9f57 Mon Sep 17 00:00:00 2001 From: ivan Date: Sun, 11 Jan 2004 23:37:08 +0000 Subject: adding --- httemplate/view/cust_bill-pdf.cgi | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100755 httemplate/view/cust_bill-pdf.cgi diff --git a/httemplate/view/cust_bill-pdf.cgi b/httemplate/view/cust_bill-pdf.cgi new file mode 100755 index 000000000..03340a16f --- /dev/null +++ b/httemplate/view/cust_bill-pdf.cgi @@ -0,0 +1,13 @@ +<% + +#untaint invnum +my($query) = $cgi->keywords; +$query =~ /^(\d+)$/; +my $invnum = $1; + +my $cust_bill = qsearchs('cust_bill',{'invnum'=>$invnum}); +die "Invoice #$invnum not found!" unless $cust_bill; + +http_header('Content-Type' => 'application/postscript' ); +%> +<%= $cust_bill->print_ps %> -- cgit v1.2.1