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

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



Revision: 2320
          http://ledger-smb.svn.sourceforge.net/ledger-smb/?rev=2320&view=rev
Author:   einhverfr
Date:     2008-09-10 23:04:03 +0000 (Wed, 10 Sep 2008)

Log Message:
-----------

Correcting issue saving multiple contact info

Modified Paths:
--------------
    trunk/LedgerSMB/ScriptLib/Company.pm
    trunk/UI/Contact/contact.html
    trunk/UI/Contact/search.html

Modified: trunk/LedgerSMB/ScriptLib/Company.pm
===================================================================
--- trunk/LedgerSMB/ScriptLib/Company.pm	2008-09-10 18:36:37 UTC (rev 2319)
+++ trunk/LedgerSMB/ScriptLib/Company.pm	2008-09-10 23:04:03 UTC (rev 2320)
@@ -457,6 +457,23 @@
 
 =over
 
+=item save_contact_new($request)
+
+Saves contact info as a new line as per save_contact above.
+
+=cut
+
+sub save_contact_new{
+    my ($request) = @_;
+    delete $request->{old_contact};
+    delete $request->{old_contact_class};
+    save_contact($request);
+}
+
+=pod
+
+=over
+
 =item save_bank_account($request)
 
 Adds a bank account to a company and, if defined, an entity credit account.

Modified: trunk/UI/Contact/contact.html
===================================================================
--- trunk/UI/Contact/contact.html	2008-09-10 18:36:37 UTC (rev 2319)
+++ trunk/UI/Contact/contact.html	2008-09-10 23:04:03 UTC (rev 2320)
@@ -678,6 +678,14 @@
 		text =  text('Save Contact'),
 		class = "submit"
 		} #' ?>
+	<?lsmb IF contact.defined ?> 
+	<?lsmb PROCESS button element_data = {
+		name = "action",
+		value = "save_contact_new",
+		text =  text('Save As New'),
+		class = "submit"
+		} #' ?>
+ 	<?lsmb END # IF old_contact.defined ?>
 	</div>
 </form>
 	

Modified: trunk/UI/Contact/search.html
===================================================================
--- trunk/UI/Contact/search.html	2008-09-10 18:36:37 UTC (rev 2319)
+++ trunk/UI/Contact/search.html	2008-09-10 23:04:03 UTC (rev 2320)
@@ -1,5 +1,6 @@
 <?lsmb INCLUDE 'ui-header.html' ?> 
 <?lsmb PROCESS elements.html ?> 
+<?lsmb account_class = entity_class ?>
 <body>
 <?lsmb IF account_class == 1 -?>
 <?lsmb entity_type = 'Vendor' -?>
@@ -19,6 +20,7 @@
 } -?>
 <table width="100%">
   <tr><th class="listtop"><?lsmb title ?></th></tr>
+
   <tr><td /></tr>
   <tr valign="top">
     <td>


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