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

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



Revision: 5170
          http://ledger-smb.svn.sourceforge.net/ledger-smb/?rev=5170&view=rev
Author:   einhverfr
Date:     2012-11-08 08:25:10 +0000 (Thu, 08 Nov 2012)
Log Message:
-----------
Merged from branches/1.3

Modified Paths:
--------------
    trunk/Changelog
    trunk/INSTALL
    trunk/LedgerSMB/DBObject/Payment.pm
    trunk/LedgerSMB/File.pm
    trunk/LedgerSMB/IS.pm
    trunk/LedgerSMB/Scripts/payment.pm
    trunk/UI/payments/payment2.html
    trunk/UI/payments/payments_detail.html
    trunk/bin/io.pl
    trunk/bin/is.pl
    trunk/templates/demo/check_base.tex

Property Changed:
----------------
    trunk/
    trunk/LedgerSMB/Scripts/payment.pm


Property changes on: trunk
___________________________________________________________________
Modified: svn:mergeinfo
   - /branches/1.3:3711-5160
   + /branches/1.3:3711-5169

Modified: trunk/Changelog
===================================================================
--- trunk/Changelog	2012-11-07 13:22:24 UTC (rev 5169)
+++ trunk/Changelog	2012-11-08 08:25:10 UTC (rev 5170)
@@ -81,10 +81,16 @@
 * Fixed error in msgid for "Add Language" (Havard S, h/t Robert C)
 * Moved Makefile.PL to version_from to reduce errors (Chris T, h/t Robert C)
 * Prompts added to configure_apache.sh (Berend T)
+* Corrected image not showable on html invoice (Chris T)
+* Fixed invoice date not printing on checks (Chris T, h/t Neil S)
+* Changed INSTALL to do make test, not of make install (Chris T h/t Kevin B)
+* Fixed framework for printing parts tumbnails in invoices (Chris T)
 
 berend T is Berend Tober
 Chris T is Chris Travers
 Havard S is Havard Sorli
+Kevin B is Kevin Bailey
+Neil S is Neil Smith
 Robert C is Robert James Clay
 
 Changelog for 1.3.23

Modified: trunk/INSTALL
===================================================================
--- trunk/INSTALL	2012-11-07 13:22:24 UTC (rev 5169)
+++ trunk/INSTALL	2012-11-08 08:25:10 UTC (rev 5170)
@@ -155,7 +155,10 @@
   XML::Twig               [Support for OpenOffice output]
   Excel::Template::Plus   [Support for Excel output]
 
+To build using the Makefile.PL you will also need:
 
+  Module::Install
+
 All these modules can be downloaded from CPAN, the modules distribution
 archive for Perl. However our experience has been that if your distribution
 provides a module via its package manager (apt, rpm, etc.), you will have
@@ -170,7 +173,7 @@
 you should proceed to run:
 
  $ perl Makefile.PL
- $ make install
+ $ make test
 
 which will ask you which modules it should download, if you didn't install
 - using your package manager - all of the required and optional modules

Modified: trunk/LedgerSMB/DBObject/Payment.pm
===================================================================
--- trunk/LedgerSMB/DBObject/Payment.pm	2012-11-07 13:22:24 UTC (rev 5169)
+++ trunk/LedgerSMB/DBObject/Payment.pm	2012-11-08 08:25:10 UTC (rev 5170)
@@ -772,7 +772,10 @@
 my ($self) = @_;
 @{$self->{header_info}} = $self->exec_method(funcname => 'payment_gather_header_info');
 @{$self->{line_info}}   = $self->exec_method(funcname => 'payment_gather_line_info');
+for my $row(@{$self->{line_info}}){
+    $row->{invoice_date} = $row->{trans_date};
 }
+}
 
 =item get_open_overpayment_entities 
 

Modified: trunk/LedgerSMB/File.pm
===================================================================
--- trunk/LedgerSMB/File.pm	2012-11-07 13:22:24 UTC (rev 5169)
+++ trunk/LedgerSMB/File.pm	2012-11-08 08:25:10 UTC (rev 5170)
@@ -250,6 +250,12 @@
            $result->{sizex} = $x;
            $result->{sizey} = $y;
         };
+        if ($result->{file_class} == 3){ 
+           $result->{ref_key} = $result->{file_name};
+           $result->{ref_key} =~ s/-.*//;
+        } else {
+           $result->{ref_key} = $args->{ref_key};
+        }
     }
 }
 

Modified: trunk/LedgerSMB/IS.pm
===================================================================
--- trunk/LedgerSMB/IS.pm	2012-11-07 13:22:24 UTC (rev 5169)
+++ trunk/LedgerSMB/IS.pm	2012-11-08 08:25:10 UTC (rev 5170)
@@ -356,6 +356,7 @@
             # add number, description and qty to $form->{number}...
             push( @{ $form->{runningnumber} }, $runningnumber++ );
             push( @{ $form->{number} },        $form->{"partnumber_$i"} );
+            push( @{ $form->{image} },        $form->{"image_$i"} );
             push( @{ $form->{sku} },           $form->{"sku_$i"} );
             push( @{ $form->{serialnumber} },  $form->{"serialnumber_$i"} );
 
@@ -1988,7 +1989,8 @@
 			          p.partnumber AS sku, p.listprice, p.lastcost,
 			          p.weight, p.onhand, p.inventory_accno_id, 
 			          p.income_accno_id, p.expense_accno_id,
-			          t.description AS partsgrouptranslation
+			          t.description AS partsgrouptranslation, 
+                                  p.image
 			     FROM invoice i
 		             JOIN parts p ON (i.parts_id = p.id)
 			LEFT JOIN partsgroup pg ON (p.partsgroup_id = pg.id)

Modified: trunk/LedgerSMB/Scripts/payment.pm
===================================================================
--- trunk/LedgerSMB/Scripts/payment.pm	2012-11-07 13:22:24 UTC (rev 5169)
+++ trunk/LedgerSMB/Scripts/payment.pm	2012-11-08 08:25:10 UTC (rev 5170)
@@ -488,7 +488,7 @@
             for my $inv (1 .. $payment->{"invoice_count_$id"}){
                 my $invhash = {};
                 my $inv_id = $payment->{"invoice_${id}_$inv"};
-                for (qw(invnumber due)){
+                for (qw(invnumber due invoice_date)){
                     $invhash->{$_} = $payment->{"${_}_$inv_id"};
                 }
                 if ($payment->{"paid_$id"} eq 'some'){


Property changes on: trunk/LedgerSMB/Scripts/payment.pm
___________________________________________________________________
Modified: svn:mergeinfo
   - /branches/1.3/LedgerSMB/Scripts/payment.pm:3712-4945
/branches/1.3/scripts/payment.pl:3711-4680
   + /branches/1.3/LedgerSMB/Scripts/payment.pm:3712-4945
/branches/1.3/scripts/payment.pl:3711-5169

Modified: trunk/UI/payments/payment2.html
===================================================================
--- trunk/UI/payments/payment2.html	2012-11-07 13:22:24 UTC (rev 5169)
+++ trunk/UI/payments/payment2.html	2012-11-08 08:25:10 UTC (rev 5170)
@@ -148,6 +148,8 @@
         <input type="hidden" value="<?lsmb row.invoice.id ?>" />                 </td>
     <?lsmb # we can use an href to link this invoice number to the invoice ?>
     <td><?lsmb row.invoice_date ?></td>
+    <input type="hidden" name="<?lsmb "invoice_date_$row.invoice.id" ?>" 
+          value="<?lsmb row.invoice_date ?>" />
     <td><?lsmb row.amount ?></td>
     <td><?lsmb row.paid ?></td>
     <td><?lsmb row.discount ?></td>

Modified: trunk/UI/payments/payments_detail.html
===================================================================
--- trunk/UI/payments/payments_detail.html	2012-11-07 13:22:24 UTC (rev 5169)
+++ trunk/UI/payments/payments_detail.html	2012-11-08 08:25:10 UTC (rev 5170)
@@ -301,7 +301,12 @@
 		<?lsmb IF i.7 ?>
 		<?lsmb icount = icount + 1 ?>
 		<tr>
-			<td class="invoice_date_list">&nbsp;<?lsmb i.2 ?></td>
+			<td class="invoice_date_list">&nbsp;<?lsmb i.2 ?>
+                        <input type = "hidden"
+                               name = "<?lsmb "invoice_date_$i.0" ?>"
+                              value = "<?lsmb i.2 ?>"
+                        />
+                        </td>
 			<td class="invoice_list">&nbsp;<?lsmb i.1 ?></td>
                         <input
                                type = "hidden"

Modified: trunk/bin/io.pl
===================================================================
--- trunk/bin/io.pl	2012-11-07 13:22:24 UTC (rev 5169)
+++ trunk/bin/io.pl	2012-11-08 08:25:10 UTC (rev 5170)
@@ -1628,7 +1628,17 @@
         my @files = $file->get_for_template(
                 {ref_key => $form->{id}, file_class => $fc}
         );
-        $form->{file_list} = ..hidden..;
+        my @main_files;
+        my %parts_files;
+        for my $f (@files){
+            if ($f->{file_class} == 3) {
+              $parts_files{$f->{ref_key}} = $f;
+            } else {
+               push @main_files, $f;
+            }
+        }
+        $form->{file_list} = ..hidden..;
+        $form->{parts_files} = \%parts_files;
         $form->{file_path} = $file->file_path;
     }
 
@@ -1670,7 +1680,7 @@
             "projectnumber_$i", "partsgroup_$i",
             "serialnumber_$i",  "bin_$i",
             "unit_$i",          "notes_$i", 
-            "image_$i",
+            "image_$i",         "id_$i"
           );
     }
     for ( split / /, $form->{taxaccounts} ) { push @vars, "${_}_description" }
@@ -1708,7 +1718,7 @@
     }
     else {
         IS->invoice_details( \%myconfig, $form );
-    }
+    } 
     if ( exists $form->{longformat} ) {
         $form->{"${due}date"} = $duedate;
         for ( "${inv}date", "${due}date", "shippingdate", "transdate" ) {
@@ -1716,7 +1726,6 @@
               $locale->date( \%myconfig, $form->{$_}, $form->{longformat} );
         }
     }
-
     @vars =
       qw(name address1 address2 city state zipcode country contact phone fax email);
 

Modified: trunk/bin/is.pl
===================================================================
--- trunk/bin/is.pl	2012-11-07 13:22:24 UTC (rev 5169)
+++ trunk/bin/is.pl	2012-11-08 08:25:10 UTC (rev 5170)
@@ -752,10 +752,13 @@
     $form->format_amount( \%myconfig, $form->{invtotal}, 2, 0 );
     
     my $hold;
-    
+    my $hold_button_text;
     if ($form->{on_hold}) {
         
         $hold = qq| <font size="17"><b> This invoice is On Hold </b></font> |;
+        $hold_button_text = $locale->text('Off Hold');
+    } else {
+        $hold_button_text = $locale->text('On Hold');
     }
 
     print qq|
@@ -962,7 +965,7 @@
             'schedule' =>
               { ndx => 10, key => 'H', value => $locale->text('Schedule') },
             'on_hold' =>
-              { ndx => 12, key => 'O', value => $locale->text('On Hold') },
+              { ndx => 12, key => 'O',  value => $hold_button_text },
              'void'  => 
                 { ndx => 13, key => 'V', value => $locale->text('Void') },
              'save_info'  => 

Modified: trunk/templates/demo/check_base.tex
===================================================================
--- trunk/templates/demo/check_base.tex	2012-11-07 13:22:24 UTC (rev 5169)
+++ trunk/templates/demo/check_base.tex	2012-11-08 08:25:10 UTC (rev 5170)
@@ -52,7 +52,7 @@
 \textbf{<?lsmb text('Invoice #') ?>} & \textbf{<?lsmb text('Invoice Date') ?>}
   & \textbf{<?lsmb text('Amount Due') ?>} & \textbf{<?lsmb text('Applied') ?>} \\
 <?lsmb FOR inv = invoices ?>
-<?lsmb inv.invnumber ?> & <?lsmb inv.invdate ?> \dotfill
+<?lsmb inv.invnumber ?> & <?lsmb inv.invoice_date ?> \dotfill
   & <?lsmb inv.due ?> & <?lsmb inv.paid ?> \\
 <?lsmb END # FOREACH inv ?>
 \end{tabularx}

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