[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
SF.net SVN: ledger-smb:[4048] branches/1.3
- Subject: SF.net SVN: ledger-smb:[4048] branches/1.3
- From: ..hidden..
- Date: Thu, 24 Nov 2011 12:20:43 +0000
Revision: 4048
http://ledger-smb.svn.sourceforge.net/ledger-smb/?rev=4048&view=rev
Author: einhverfr
Date: 2011-11-24 12:20:42 +0000 (Thu, 24 Nov 2011)
Log Message:
-----------
Pricelist now displaying, need to add add/delete functions too
Modified Paths:
--------------
branches/1.3/LedgerSMB/ScriptLib/Company.pm
branches/1.3/UI/Contact/pricelist.html
Modified: branches/1.3/LedgerSMB/ScriptLib/Company.pm
===================================================================
--- branches/1.3/LedgerSMB/ScriptLib/Company.pm 2011-11-24 11:08:10 UTC (rev 4047)
+++ branches/1.3/LedgerSMB/ScriptLib/Company.pm 2011-11-24 12:20:42 UTC (rev 4048)
@@ -992,6 +992,19 @@
my $company = new_company($request);
$company->get();
$company->get_pricematrix();
+ for my $l (qw(pricematrix pricematrix_pricegroup)){
+ for my $p (@{$company->{$l}}){
+ $p->{sellprice} = $company->format_amount(
+ {amount => $p->{sellprice}, money => 1}
+ );
+ $p->{pricebreak} = $company->format_amount(
+ {amount => $p->{sellprice}, money => 1}
+ );
+ $p->{lastcost} = $company->format_amount(
+ {amount => $p->{sellprice}, money => 1}
+ );
+ }
+ }
my $template = LedgerSMB::Template->new(
user => $request->{_user},
path => 'UI/Contact' ,
@@ -1000,7 +1013,7 @@
locale => $company->{_locale},
);
- $template->render($request);
+ $template->render($company);
}
Modified: branches/1.3/UI/Contact/pricelist.html
===================================================================
--- branches/1.3/UI/Contact/pricelist.html 2011-11-24 11:08:10 UTC (rev 4047)
+++ branches/1.3/UI/Contact/pricelist.html 2011-11-24 12:20:42 UTC (rev 4048)
@@ -10,6 +10,7 @@
-CT
-->
+<?lsmb account_class = entity_class ?>
<body>
<div class="listtop"><?lsmb text('Pricelist') ?> <?lsmb pricematrix.length ?></div>
<table>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.