]> git.mxchange.org Git - jfinancials-war.git/commitdiff
Continued a bit: (please cherry-pick)
authorRoland Häder <roland@mxchange.org>
Mon, 8 Aug 2016 16:10:15 +0000 (18:10 +0200)
committerRoland Haeder <roland@mxchange.org>
Mon, 8 Aug 2016 18:38:53 +0000 (20:38 +0200)
- also here use isEmpty()

src/java/org/mxchange/addressbook/beans/contact/phone/AddressbookContactPhoneWebSessionBean.java
web/admin/cellphone/admin_contact_cellphone_list.xhtml

index df897facd82c2e73ca873e00ebbf606c7024bf58..da3a5228dd87b7e3c1b14499bf7bf217c350d050 100644 (file)
@@ -121,6 +121,15 @@ public class AddressbookContactPhoneWebSessionBean extends BaseAddressbookContro
                        throw new IllegalArgumentException(MessageFormat.format("event.addedContact.contactId={0} is not valid", event.getAddedContact().getContactId())); //NOI18N //NOI18N
                }
 
+               // Get contact
+               Contact contact = event.getAddedContact();
+
+               // Is cellphone set?
+               if (contact.getContactCellphoneNumber() instanceof DialableCellphoneNumber) {
+                       // Unique-add it
+                       this.uniqueAddCellphoneNumber(contact.getContactCellphoneNumber());
+               }
+
                // Clear this bean
                this.clear();
        }
index e3e4aa93143926b209407cd991c0b5708aa77b8d..b319d1e620fd0a1000e6518bf96daae357f15eb6 100644 (file)
@@ -15,7 +15,7 @@
                </ui:define>
 
                <ui:define name="content">
-                       <h:dataTable id="table_list_cellphones" var="cellphone" value="#{phoneController.allCellphones()}" styleClass="table_big" headerClass="table_header_column" summary="#{msg.TABLE_SUMMARY_ADMIN_LIST_CELLPHONES}" rendered="#{phoneController.hasCellphones()}">
+                       <h:dataTable id="table_list_cellphones" var="cellphone" value="#{phoneController.allCellphones()}" styleClass="table_big" headerClass="table_header_column" summary="#{msg.TABLE_SUMMARY_ADMIN_LIST_CELLPHONES}" rendered="#{not phoneController.allCellphones().isEmpty()}">
                                <h:column>
                                        <f:facet name="header">
                                                <h:outputText value="#{msg.ADMIN_SHOW_CELLPHONE_ID}" />