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

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



Revision: 5919
          http://sourceforge.net/p/ledger-smb/code/5919
Author:   einhverfr
Date:     2013-07-24 08:11:04 +0000 (Wed, 24 Jul 2013)
Log Message:
-----------
Fixing inability to go from sales order to sales invoice

Modified Paths:
--------------
    trunk/bin/io.pl
    trunk/sql/Pg-database.sql
    trunk/sql/modules/Fixes.sql

Modified: trunk/bin/io.pl
===================================================================
--- trunk/bin/io.pl	2013-07-23 07:55:02 UTC (rev 5918)
+++ trunk/bin/io.pl	2013-07-24 08:11:04 UTC (rev 5919)
@@ -1547,7 +1547,7 @@
 }
 sub print {
 
-    $logger->trace("setting fax from LedgerSMB::Company_Config::settings \$form->{formname}=$form->{formname} \$form->{fax}=$form->{fax}");
+  #  $logger->trace("setting fax from LedgerSMB::Company_Config::settings \$form->{formname}=$form->{formname} \$form->{fax}=$form->{fax}");
 
 
     # if this goes to the printer pass through
@@ -1793,7 +1793,7 @@
         }
     }
 
-    $logger->trace("\$form->{formname}=$form->{formname} \$form->{fax}=$form->{fax} \$shipto=$shipto \$form->{shiptofax}=$form->{shiptofax}");
+    # $logger->trace("\$form->{formname}=$form->{formname} \$form->{fax}=$form->{fax} \$shipto=$shipto \$form->{shiptofax}=$form->{shiptofax}");
     if ($shipto) {
         if (   $form->{formname} eq 'purchase_order'
             || $form->{formname} eq 'request_quotation' )

Modified: trunk/sql/Pg-database.sql
===================================================================
--- trunk/sql/Pg-database.sql	2013-07-23 07:55:02 UTC (rev 5918)
+++ trunk/sql/Pg-database.sql	2013-07-24 08:11:04 UTC (rev 5919)
@@ -2000,7 +2000,7 @@
 );
 
 CREATE TABLE business_unit_oitem (
-  entry_id int references orderitems(id),
+  entry_id int references orderitems(id) on delete cascade,
   class_id int references business_unit_class(id),
   bu_id int,
   primary key(bu_id, class_id, entry_id),

Modified: trunk/sql/modules/Fixes.sql
===================================================================
--- trunk/sql/modules/Fixes.sql	2013-07-23 07:55:02 UTC (rev 5918)
+++ trunk/sql/modules/Fixes.sql	2013-07-24 08:11:04 UTC (rev 5919)
@@ -180,3 +180,13 @@
 BEGIN;
 CREATE INDEX menu_acl_node_id_idx ON menu_acl (node_id);
 COMMIT;
+
+BEGIN;
+
+alter table business_unit_oitem 
+drop constraint business_unit_oitem_entry_id_fkey;
+
+alter table business_unit_oitem 
+add foreign key (entry_id) references orderitems(id) on delete cascade;
+
+COMMIT;

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