diff options
-rw-r--r-- | LedgerSMB/ScriptLib/Company.pm | 17 | ||||
-rw-r--r-- | UI/Contact/contact.html | 8 | ||||
-rw-r--r-- | UI/Contact/search.html | 2 |
3 files changed, 27 insertions, 0 deletions
diff --git a/LedgerSMB/ScriptLib/Company.pm b/LedgerSMB/ScriptLib/Company.pm index e888c283..9b9b87c9 100644 --- a/LedgerSMB/ScriptLib/Company.pm +++ b/LedgerSMB/ScriptLib/Company.pm @@ -457,6 +457,23 @@ sub save_contact { =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. diff --git a/UI/Contact/contact.html b/UI/Contact/contact.html index ac00cb72..c061ac52 100644 --- a/UI/Contact/contact.html +++ b/UI/Contact/contact.html @@ -678,6 +678,14 @@ problems with multi-word single-quoted constructs in PI tags. -CT --> 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> diff --git a/UI/Contact/search.html b/UI/Contact/search.html index e90d6564..f0cee902 100644 --- a/UI/Contact/search.html +++ b/UI/Contact/search.html @@ -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> |