[freeside-commits] branch FREESIDE_3_BRANCH updated. 745e36b35b36607f450d16944469f52e362bf934

Ivan ivan at 420.am
Wed Feb 4 13:10:56 PST 2015


The branch, FREESIDE_3_BRANCH has been updated
       via  745e36b35b36607f450d16944469f52e362bf934 (commit)
       via  bb6062a26c2d6ec9a2aef2455be1f93719764e0c (commit)
      from  a3f6785d22a743f03a805f537083ab57a20d5c6f (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 745e36b35b36607f450d16944469f52e362bf934
Merge: bb6062a a3f6785
Author: Ivan Kohler <ivan at freeside.biz>
Date:   Wed Feb 4 13:10:51 2015 -0800

    Merge branch 'FREESIDE_3_BRANCH' of git.freeside.biz:/home/git/freeside into FREESIDE_3_BRANCH


commit bb6062a26c2d6ec9a2aef2455be1f93719764e0c
Author: Ivan Kohler <ivan at freeside.biz>
Date:   Wed Feb 4 13:10:46 2015 -0800

    fix stickiness of contact info on errors when editing customer, backport/byproduct of 4.x work on #27943

diff --git a/httemplate/edit/cust_main/contacts_new.html b/httemplate/edit/cust_main/contacts_new.html
index f59126a..cbeb1e9 100644
--- a/httemplate/edit/cust_main/contacts_new.html
+++ b/httemplate/edit/cust_main/contacts_new.html
@@ -36,8 +36,8 @@ my $m2_error_callback = sub {
   my($cgi, $object) = @_;
 
   #process_o2m fields in process/cust_main-contacts.html
-  my @fields = qw( first last title comment );
-  my @gfields = ( '', map "_$_", @fields );
+  my $fields = FS::contact->cgi_contact_fields;
+  my @gfields = ( '', map "_$_", @$fields );
 
   map {
         if ( /^contactnum(\d+)$/ ) {
@@ -45,7 +45,7 @@ my $m2_error_callback = sub {
           if ( grep $cgi->param("contactnum$num$_"), @gfields ) {
             my $x = new FS::contact {
               'contactnum' => scalar($cgi->param("contactnum$num")),
-              map { $_ => scalar($cgi->param("contactnum${num}_$_")) } @fields,
+              map { $_ => scalar($cgi->param("contactnum${num}_$_")) } @$fields,
             };
             $x;
           } else {

-----------------------------------------------------------------------

Summary of changes:
 httemplate/edit/cust_main/contacts_new.html |    6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)




More information about the freeside-commits mailing list