[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
SF.net SVN: ledger-smb: [2187] trunk
- Subject: SF.net SVN: ledger-smb: [2187] trunk
- From: ..hidden..
- Date: Sat, 05 Jul 2008 15:13:42 -0700
Revision: 2187
http://ledger-smb.svn.sourceforge.net/ledger-smb/?rev=2187&view=rev
Author: einhverfr
Date: 2008-07-05 15:13:42 -0700 (Sat, 05 Jul 2008)
Log Message:
-----------
Removing debugging code accidently left in
Modified Paths:
--------------
trunk/LedgerSMB/Template/HTML.pm
trunk/UI/payments/payments_detail.html
trunk/scripts/payment.pl
trunk/templates/Default-check.tex
Modified: trunk/LedgerSMB/Template/HTML.pm
===================================================================
--- trunk/LedgerSMB/Template/HTML.pm 2008-07-05 22:11:54 UTC (rev 2186)
+++ trunk/LedgerSMB/Template/HTML.pm 2008-07-05 22:13:42 UTC (rev 2187)
@@ -69,7 +69,6 @@
} elsif ($type eq 'SCALAR' or $type eq 'Math::BigInt::GMP') {
return escapeHTML($$rawvars);
} else { # Hashes and objects
- print STDERR "$_ is $type:$rawvars";
for ( keys %{$rawvars} ) {
$vars->{preprocess($_)} = preprocess( $rawvars->{$_} );
}
Modified: trunk/UI/payments/payments_detail.html
===================================================================
--- trunk/UI/payments/payments_detail.html 2008-07-05 22:11:54 UTC (rev 2186)
+++ trunk/UI/payments/payments_detail.html 2008-07-05 22:13:42 UTC (rev 2187)
@@ -188,7 +188,7 @@
END
?>"><?lsmb r.contact_name ?></span></td>
<td class="invoice"><?lsmb r.total_due ?> <?lsmb currency ?></td>
- <td class="payment">
+ <td class="payment" class="details_select">
<?lsmb INCLUDE input element_data = {
name = "paid_$r.contact_id"
value = "some"
@@ -214,7 +214,7 @@
</tr>
<tr class="listrow<?lsmb rc ?>">
<td class="invoice_detail_list" colspan="3">
- <table id = "invoice_data_table_<?lsmb r.contact_id ?>" width="100%">
+ <table id = "invoice_data_table_<?lsmb r.contact_id ?>" width="100%" class = "detail_table_visible">
<tr class="listheading">
<th class="invoice_date_list"><?lsmb text('Date') ?>
</th>
@@ -291,6 +291,26 @@
class = 'submit'
name = 'action'
} ?>
+ <?lsmb IF can_print ?>
+ <?lsmb INCLUDE select element_data = {
+ name = "media"
+ class = "select"
+ options = media_options
+ value = media
+ } ?>
+ <?lsmb INCLUDE select element_data = {
+ name = "format"
+ class = "select"
+ options = format_options
+ value = format
+ } ?>
+ <?lsmb INCLUDE button element_data = {
+ text = text('Print')
+ value = 'print'
+ class = 'submit'
+ name = 'action'
+ } ?>
+ <?lsmb END # IF can_print ?>
</form>
</body>
</html>
Modified: trunk/scripts/payment.pl
===================================================================
--- trunk/scripts/payment.pl 2008-07-05 22:11:54 UTC (rev 2186)
+++ trunk/scripts/payment.pl 2008-07-05 22:13:42 UTC (rev 2187)
@@ -72,6 +72,7 @@
my ($request) = @_;
my $payment = LedgerSMB::DBObject::Payment->new({'base' => $request});
$payment->get_metadata();
+ $payment->debug({file => '/tmp/delme'});
my $template = LedgerSMB::Template->new(
user => $request->{_user},
locale => $request->{_locale},
@@ -260,6 +261,23 @@
for (@{$payment->{contact_invoices}}){
$_->{total_due} = $payment->format_amount(amount => $_->{total_due});
}
+
+ @{$payment->{media_options}} = (
+ {text => $request->{_locale}->text('Screen'),
+ value => 'screen'});
+ for (keys %LedgerSMB::Sysconfig::printer){
+ push @{$payment->{media_options}},
+ {text => $_,
+ value => $LedgerSMB::Sysconfig::printer{$_}};
+ }
+ if ($LedgerSMB::Sysconfig::latex){
+ @{$payment->{format_options}} = (
+ {text => 'PDF', value => 'PDF'},
+ {text => 'Postscript', value => 'Postscript'},
+ );
+ $payment->{can_print} = 1;
+ }
+
my $template = LedgerSMB::Template->new(
user => $request->{_user},
locale => $request->{_locale},
Modified: trunk/templates/Default-check.tex
===================================================================
--- trunk/templates/Default-check.tex 2008-07-05 22:11:54 UTC (rev 2186)
+++ trunk/templates/Default-check.tex 2008-07-05 22:13:42 UTC (rev 2187)
@@ -4,6 +4,8 @@
\usepackage[letterpaper,top=2cm,bottom=1.5cm,left=1.1cm,right=1.5cm]{geometry}
\usepackage{graphicx}
+<?lsmb REQUIRE check_base.tex ?>
+
\begin{document}
\pagestyle{myheadings}
@@ -11,67 +13,6 @@
\fontfamily{cmss}\fontsize{9pt}{9pt}\selectfont
-\parbox[t]{12cm}{
- <?lsmb company ?>
+<?lsmb PROCESS check_single ?>
- <?lsmb address ?>}
-\hfill
-\parbox[t]{6cm}{\hfill <?lsmb source ?>}
-
-\vspace*{0.6cm}
-
-<?lsmb text_amount ?> \dotfill <?lsmb decimal ?>/100 \makebox[0.5cm]{\hfill}
-
-\vspace{0.5cm}
-
-\hfill <?lsmb datepaid ?> \makebox[2cm]{\hfill} <?lsmb amount ?>
-
-% different date format for datepaid
-% <?lsmb DD ?><?lsmb MM ?><?lsmb YYYY ?>
-
-\vspace{0.5cm}
-
-<?lsmb name ?>
-
-<?lsmb address1 ?>
-
-<?lsmb address2 ?>
-
-<?lsmb city ?>
-<?lsmb if state ?>
-\hspace{-0.1cm}, <?lsmb state ?>
-<?lsmb end state ?>
-<?lsmb zipcode ?>
-
-<?lsmb country ?>
-
-\vspace{1.8cm}
-
-<?lsmb memo ?>
-
-\vspace{0.8cm}
-
-<?lsmb company ?>
-
-\vspace{0.5cm}
-
-<?lsmb name ?> \hfill <?lsmb datepaid ?> \hfill <?lsmb source ?>
-
-\vspace{0.5cm}
..hidden..
-\textbf{Invoice \#} & \textbf{Invoice Date}
- & \textbf{Amount Due} & \textbf{Applied} \\
-<?lsmb foreach invnumber ?>
-<?lsmb invnumber ?> & <?lsmb invdate ?> \dotfill
- & <?lsmb due ?> & <?lsmb paid ?> \\
-<?lsmb end invnumber ?>
-\end{tabularx}
-
-\vspace{1cm}
-
-<?lsmb memo ?>
-
-\vfill
-<?lsmb message ?>
\end{document}
-
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.