[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

SF.net SVN: ledger-smb: [2175] trunk



Revision: 2175
          http://ledger-smb.svn.sourceforge.net/ledger-smb/?rev=2175&view=rev
Author:   einhverfr
Date:     2008-06-26 10:02:41 -0700 (Thu, 26 Jun 2008)

Log Message:
-----------
Altering payment batch creation to allow for adding payments to existing batches

Modified Paths:
--------------
    trunk/UI/create_batch.html
    trunk/scripts/vouchers.pl

Modified: trunk/UI/create_batch.html
===================================================================
--- trunk/UI/create_batch.html	2008-06-25 22:22:21 UTC (rev 2174)
+++ trunk/UI/create_batch.html	2008-06-26 17:02:41 UTC (rev 2175)
@@ -6,6 +6,7 @@
         ]
 ?>
 <body>
+<div class="listtop"><?lsmb text('Create New Batch') ?></div>
 <form name="create_batch" method="post">
 <div class="labelledinput">
   <div class="input">
@@ -39,5 +40,24 @@
 <input type=hidden name="<?lsmb item.name ?>" value="<?lsmb item.value ?>">
 <?lsmb END ?>
 </form>
+<div class="listtop"><?lsmb text('Or Add To Batch') ?></div>
+<table>
+<tr class="listheading">
+  <th><?lsmb text('Batch Type') ?></th>
+  <th><?lsmb text('Control Number') ?></th>
+  <th><?lsmb text('Description') ?></th>
+  <th><?lsmb text('Created By') ?></th>
+  <th><?lsmb text('Created On') ?></th>
+</tr>
+<?lsmb FOR row = search_results ?>
+<tr>
+  <td><?lsmb text(row.batch_class) ?></td>
+  <td><a href="<?lsmb "vouchers.pl?action=add_vouchers&batch_type=$batch_type&id=$row.id" ?>"><?lsmb row.control_code ?></td>
+  <td><?lsmb row.description ?></td>
+  <td><?lsmb row.created_by ?></td>
+  <td><?lsmb row.created_on ?></td>
+</tr>
+<?lsmb END ?>
+</table>
 </body>
 </html>

Modified: trunk/scripts/vouchers.pl
===================================================================
--- trunk/scripts/vouchers.pl	2008-06-25 22:22:21 UTC (rev 2174)
+++ trunk/scripts/vouchers.pl	2008-06-26 17:02:41 UTC (rev 2175)
@@ -20,6 +20,10 @@
     $request->{hidden} = [
         {name => "batch_type", value => $request->{batch_type}},
     ];
+
+    my $batch = LedgerSMB::Batch->new({base => $request});
+    $batch->get_search_results;
+
     my $template = LedgerSMB::Template->new(
         user =>$request->{_user}, 
         locale => $request->{_locale},
@@ -27,7 +31,7 @@
         template => 'create_batch',
         format => 'HTML'
     );
-    $template->render($request);
+    $template->render($batch);
 }
 
 sub create_vouchers {


This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.