<?xml version="1.0" encoding="UTF-8"?>
<Scene Scope="Project" version="2">
- <Scope Scope="Faces Configuration Only">
- <Node id="admin/admin_logout.xhtml" x="650" y="150" zoom="true"/>
- <Node id="user/login.xhtml" x="150" y="300" zoom="true"/>
- <Node id="admin/index.xhtml" x="400" y="300" zoom="true"/>
- <Node id="user/lost_passwd.xhtml" x="400" y="450" zoom="true"/>
- <Node id="*" x="1150" y="150" zoom="true"/>
- <Node id="terms.xhtml" x="400" y="150" zoom="true"/>
- <Node id="bye.xhtml" x="150" y="450" zoom="true"/>
- <Node id="privacy.xhtml" x="650" y="300" zoom="true"/>
- <Node id="index.xhtml" x="900" y="150" zoom="true"/>
- <Node id="imprint.xhtml" x="150" y="600" zoom="true"/>
- <Node id="admin/category.xhtml" x="650" y="450" zoom="true"/>
- <Node id="user/register.xhtml" x="150" y="150" zoom="true"/>
- <Node id="admin/product.xhtml" x="900" y="300" zoom="true"/>
- </Scope>
- <Scope Scope="Project">
- <Node id="admin/admin_logout.xhtml" x="400" y="600" zoom="true"/>
- <Node id="user/login.xhtml" x="900" y="150" zoom="true"/>
- <Node id="login/login_edit_address.xhtml" x="150" y="300" zoom="true"/>
- <Node id="login/login_edit_user_data.xhtml" x="1150" y="150" zoom="true"/>
- <Node id="login/login_other_addressbooks.xhtml" x="650" y="450" zoom="true"/>
- <Node id="user/lost_passwd.xhtml" x="900" y="300" zoom="true"/>
- <Node id="*" x="650" y="150" zoom="true"/>
- <Node id="terms.xhtml" x="150" y="600" zoom="true"/>
- <Node id="login/login_own_addressbooks.xhtml" x="400" y="150" zoom="true"/>
- <Node id="user/register_done.xhtml" x="1150" y="300" zoom="true"/>
- <Node id="bye.xhtml" x="650" y="300" zoom="true"/>
- <Node id="user/login_error.xhtml" x="1400" y="150" zoom="true"/>
- <Node id="privacy.xhtml" x="400" y="750" zoom="true"/>
- <Node id="admin/admin_index.xhtml" x="400" y="450" zoom="true"/>
- <Node id="index.xhtml" x="650" y="600" zoom="true"/>
- <Node id="login/login_user_list.xhtml" x="150" y="150" zoom="true"/>
- <Node id="imprint.xhtml" x="900" y="450" zoom="true"/>
- <Node id="login/login_index.xhtml" x="150" y="750" zoom="true"/>
- <Node id="user/register.xhtml" x="400" y="300" zoom="true"/>
- <Node id="user/resend_link.xhtml" x="150" y="450" zoom="true"/>
- </Scope>
- <Scope Scope="All Faces Configurations">
- <Node id="admin/admin_logout.xhtml" x="650" y="150" zoom="true"/>
- <Node id="user/login.xhtml" x="150" y="300" zoom="true"/>
- <Node id="admin/index.xhtml" x="400" y="300" zoom="true"/>
- <Node id="user/lost_passwd.xhtml" x="400" y="450" zoom="true"/>
- <Node id="*" x="1150" y="150" zoom="true"/>
- <Node id="terms.xhtml" x="400" y="150" zoom="true"/>
- <Node id="bye.xhtml" x="150" y="450" zoom="true"/>
- <Node id="privacy.xhtml" x="650" y="300" zoom="true"/>
- <Node id="index.xhtml" x="900" y="150" zoom="true"/>
- <Node id="imprint.xhtml" x="150" y="600" zoom="true"/>
- <Node id="admin/category.xhtml" x="650" y="450" zoom="true"/>
- <Node id="user/register.xhtml" x="150" y="150" zoom="true"/>
- <Node id="admin/product.xhtml" x="900" y="300" zoom="true"/>
- </Scope>
+ <Scope Scope="Faces Configuration Only">
+ <Node id="admin/admin_logout.xhtml" x="650" y="150" zoom="true"/>
+ <Node id="user/login.xhtml" x="150" y="300" zoom="true"/>
+ <Node id="admin/index.xhtml" x="400" y="300" zoom="true"/>
+ <Node id="user/lost_passwd.xhtml" x="400" y="450" zoom="true"/>
+ <Node id="*" x="1150" y="150" zoom="true"/>
+ <Node id="terms.xhtml" x="400" y="150" zoom="true"/>
+ <Node id="bye.xhtml" x="150" y="450" zoom="true"/>
+ <Node id="privacy.xhtml" x="650" y="300" zoom="true"/>
+ <Node id="index.xhtml" x="900" y="150" zoom="true"/>
+ <Node id="imprint.xhtml" x="150" y="600" zoom="true"/>
+ <Node id="admin/category.xhtml" x="650" y="450" zoom="true"/>
+ <Node id="user/register.xhtml" x="150" y="150" zoom="true"/>
+ <Node id="admin/product.xhtml" x="900" y="300" zoom="true"/>
+ </Scope>
+ <Scope Scope="Project">
+ <Node id="admin/admin_logout.xhtml" x="400" y="600" zoom="true"/>
+ <Node id="user/login.xhtml" x="900" y="150" zoom="true"/>
+ <Node id="login/login_edit_address.xhtml" x="150" y="300" zoom="true"/>
+ <Node id="login/login_edit_user_data.xhtml" x="1150" y="150" zoom="true"/>
+ <Node id="login/login_other_addressbooks.xhtml" x="650" y="450" zoom="true"/>
+ <Node id="user/lost_passwd.xhtml" x="900" y="300" zoom="true"/>
+ <Node id="*" x="650" y="150" zoom="true"/>
+ <Node id="terms.xhtml" x="150" y="600" zoom="true"/>
+ <Node id="login/login_own_addressbooks.xhtml" x="400" y="150" zoom="true"/>
+ <Node id="user/register_done.xhtml" x="1150" y="300" zoom="true"/>
+ <Node id="bye.xhtml" x="650" y="300" zoom="true"/>
+ <Node id="user/login_error.xhtml" x="1400" y="150" zoom="true"/>
+ <Node id="privacy.xhtml" x="400" y="750" zoom="true"/>
+ <Node id="admin/admin_index.xhtml" x="400" y="450" zoom="true"/>
+ <Node id="index.xhtml" x="650" y="600" zoom="true"/>
+ <Node id="login/login_user_list.xhtml" x="150" y="150" zoom="true"/>
+ <Node id="imprint.xhtml" x="900" y="450" zoom="true"/>
+ <Node id="login/login_index.xhtml" x="150" y="750" zoom="true"/>
+ <Node id="user/register.xhtml" x="400" y="300" zoom="true"/>
+ <Node id="user/resend_link.xhtml" x="150" y="450" zoom="true"/>
+ </Scope>
+ <Scope Scope="All Faces Configurations">
+ <Node id="admin/admin_logout.xhtml" x="650" y="150" zoom="true"/>
+ <Node id="user/login.xhtml" x="150" y="300" zoom="true"/>
+ <Node id="admin/index.xhtml" x="400" y="300" zoom="true"/>
+ <Node id="user/lost_passwd.xhtml" x="400" y="450" zoom="true"/>
+ <Node id="*" x="1150" y="150" zoom="true"/>
+ <Node id="terms.xhtml" x="400" y="150" zoom="true"/>
+ <Node id="bye.xhtml" x="150" y="450" zoom="true"/>
+ <Node id="privacy.xhtml" x="650" y="300" zoom="true"/>
+ <Node id="index.xhtml" x="900" y="150" zoom="true"/>
+ <Node id="imprint.xhtml" x="150" y="600" zoom="true"/>
+ <Node id="admin/category.xhtml" x="650" y="450" zoom="true"/>
+ <Node id="user/register.xhtml" x="150" y="150" zoom="true"/>
+ <Node id="admin/product.xhtml" x="900" y="300" zoom="true"/>
+ </Scope>
</Scene>
--- /dev/null
+package org.mxchange.addressbook.beans.smsprovider;
+
+/*
+ * Copyright (C) 2015 Roland Haeder
+ *
+ * This program is free software: you can redistribute it and/or modify it under
+ * the terms of the GNU General Public License as published by the Free Software
+ * Foundation, either version 3 of the License, or (at your option) any later
+ * version.
+ *
+ * This program is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
+ * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
+ * details.
+ *
+ * You should have received a copy of the GNU General Public License along with
+ * this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+import java.util.Collections;
+import java.util.List;
+import javax.annotation.PostConstruct;
+import javax.enterprise.context.ApplicationScoped;
+import javax.faces.view.facelets.FaceletException;
+import javax.inject.Named;
+import javax.naming.Context;
+import javax.naming.InitialContext;
+import javax.naming.NamingException;
+import org.mxchange.jphone.phonenumbers.smsprovider.AddressbookSmsProviderSingletonBeanRemote;
+import org.mxchange.jphone.phonenumbers.smsprovider.SmsProvider;
+
+/**
+ * A country bean
+ * <p>
+ * @author Roland Haeder<roland@mxchange.org>
+ */
+@Named ("cellphone")
+@ApplicationScoped
+public class SmsProviderWebBean implements SmsProviderWebController {
+
+ /**
+ * Serial number
+ */
+ private static final long serialVersionUID = 176_985_298_681_742_960L;
+
+ /**
+ * Remote country EJB
+ */
+ private final AddressbookSmsProviderSingletonBeanRemote cellphoneBean;
+
+ /**
+ * List of all countries
+ */
+ private List<SmsProvider> cellphoneList;
+
+ /**
+ * Default constructor
+ */
+ public SmsProviderWebBean () {
+ // Try this
+ try {
+ // Get initial context
+ Context context = new InitialContext();
+
+ // Try to lookup the bean
+ this.cellphoneBean = (AddressbookSmsProviderSingletonBeanRemote) context.lookup("ejb/addressbook-singleton-smsprovider"); //NOI18N
+ } catch (final NamingException ex) {
+ // Continue to throw
+ throw new FaceletException(ex);
+ }
+ }
+
+ @Override
+ public List<SmsProvider> allSmsProvider () {
+ // Return "cached" version
+ return Collections.unmodifiableList(this.cellphoneList);
+ }
+
+ @PostConstruct
+ public void init () {
+ this.cellphoneList = this.cellphoneBean.allSmsProvider();
+ }
+}
--- /dev/null
+package org.mxchange.addressbook.beans.smsprovider;
+
+/*
+ * Copyright (C) 2015 Roland Haeder
+ *
+ * This program is free software: you can redistribute it and/or modify it under
+ * the terms of the GNU General Public License as published by the Free Software
+ * Foundation, either version 3 of the License, or (at your option) any later
+ * version.
+ *
+ * This program is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
+ * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
+ * details.
+ *
+ * You should have received a copy of the GNU General Public License along with
+ * this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+import java.io.Serializable;
+import java.util.List;
+import org.mxchange.jphone.phonenumbers.smsprovider.SmsProvider;
+
+/**
+ * An interface for country beans
+ * <p>
+ * @author Roland Haeder<roland@mxchange.org>
+ */
+public interface SmsProviderWebController extends Serializable {
+
+ /**
+ * A list of all countries
+ * <p>
+ * @return All countries
+ */
+ public List<SmsProvider> allSmsProvider ();
+}
import org.mxchange.jcontacts.contact.UserContact;
import org.mxchange.jcontacts.contact.gender.Gender;
import org.mxchange.jcountry.data.Country;
+import org.mxchange.jphone.phonenumbers.cellphone.CellphoneNumber;
import org.mxchange.jphone.phonenumbers.cellphone.DialableCellphoneNumber;
import org.mxchange.jphone.phonenumbers.fax.DialableFaxNumber;
+import org.mxchange.jphone.phonenumbers.fax.FaxNumber;
import org.mxchange.jphone.phonenumbers.landline.DialableLandLineNumber;
+import org.mxchange.jphone.phonenumbers.landline.LandLineNumber;
+import org.mxchange.jphone.phonenumbers.smsprovider.SmsProvider;
import org.mxchange.jusercore.model.user.LoginUser;
import org.mxchange.jusercore.model.user.User;
import org.mxchange.jusercore.model.user.UserSessionBeanRemote;
*/
private Date birthday;
+ /**
+ * Cellphone number's carrier
+ */
+ private SmsProvider cellphoneCarrier;
+
/**
* Cellphone number
*/
- private DialableCellphoneNumber cellphoneNumber;
+ private Long cellphoneNumber;
/**
* City
*/
private String familyName;
+ /**
+ * Fax number's area code
+ */
+ private Integer faxAreaCode;
+
+ /**
+ * Country instance for fax number
+ */
+ private Country faxCountry;
+
/**
* Fax number
*/
- private DialableFaxNumber faxNumber;
+ private Long faxNumber;
/**
* First name
*/
private Short houseNumber;
+ /**
+ * Phone number area code
+ */
+ private Integer phoneAreaCode;
+
+ /**
+ * Country instance for phone number
+ */
+ private Country phoneCountry;
+
/**
* Phone number
*/
- private DialableLandLineNumber phoneNumber;
+ private Long phoneNumber;
/**
* Street
// - contact data
this.setEmailAddress(null);
this.setEmailAddressRepeat(null);
- this.setPhoneNumber(null);
- this.setCellphoneNumber(null);
- this.setFaxNumber(null);
+ this.setPhoneAreaCode(null);
+ this.setCellphoneCarrier(null);
+ this.setFaxAreaCode(null);
// - other data
this.setBirthday(null);
this.setCity(user.getUserContact().getCity());
this.setCountry(user.getUserContact().getCountry());
+ // Get cellphone, phone and fax instance
+ DialableCellphoneNumber cellphone = user.getUserContact().getCellphoneNumber();
+ DialableFaxNumber fax = user.getUserContact().getFaxNumber();
+ DialableLandLineNumber phone = user.getUserContact().getPhoneNumber();
+
// - contact data
- this.setPhoneNumber(user.getUserContact().getPhoneNumber());
- this.setCellphoneNumber(user.getUserContact().getCellphoneNumber());
- this.setFaxNumber(user.getUserContact().getFaxNumber());
+ if (phone instanceof DialableLandLineNumber) {
+ this.setPhoneCountry(phone.getPhoneCountry());
+ this.setPhoneAreaCode(phone.getPhoneAreaCode());
+ this.setPhoneNumber(phone.getPhoneNumber());
+ }
+ if (cellphone instanceof DialableCellphoneNumber) {
+ this.setCellphoneCarrier(cellphone.getCellphoneProvider());
+ this.setCellphoneNumber(cellphone.getPhoneNumber());
+ }
+ if (fax instanceof DialableFaxNumber) {
+ this.setFaxCountry(fax.getPhoneCountry());
+ this.setFaxAreaCode(fax.getPhoneAreaCode());
+ this.setFaxNumber(fax.getPhoneNumber());
+ }
this.setEmailAddress(user.getUserContact().getEmailAddress());
// -- other data
User user = new LoginUser();
user.setUserName(this.getUserName());
+ // Generate phone number
+ DialableLandLineNumber phone = new LandLineNumber(this.getPhoneCountry(), this.getPhoneAreaCode(), this.getPhoneNumber());
+ DialableCellphoneNumber cellphone = new CellphoneNumber(this.getCellphoneCarrier(), this.getCellphoneNumber());
+ DialableFaxNumber fax = new FaxNumber(this.getFaxCountry(), this.getFaxAreaCode(), this.getFaxNumber());
+
// Create new contact
Contact contact = new UserContact(this.getGender(), this.getFirstName(), this.getFamilyName());
contact.setStreet(this.getStreet());
contact.setCity(this.getCity());
contact.setCountry(this.getCountry());
contact.setEmailAddress(this.getEmailAddress());
- contact.setPhoneNumber(this.getPhoneNumber());
- contact.setFaxNumber(this.getFaxNumber());
- contact.setCellphoneNumber(this.getCellphoneNumber());
+ contact.setPhoneNumber(phone);
+ contact.setFaxNumber(fax);
+ contact.setCellphoneNumber(cellphone);
contact.setBirthday(this.getBirthday());
contact.setComment(this.getComment());
}
@Override
- public DialableCellphoneNumber getCellphoneNumber () {
+ public SmsProvider getCellphoneCarrier () {
+ return this.cellphoneCarrier;
+ }
+
+ @Override
+ public void setCellphoneCarrier (final SmsProvider cellphoneCarrier) {
+ this.cellphoneCarrier = cellphoneCarrier;
+ }
+
+ @Override
+ public Long getCellphoneNumber () {
return this.cellphoneNumber;
}
@Override
- public void setCellphoneNumber (final DialableCellphoneNumber cellphoneNumber) {
+ public void setCellphoneNumber (Long cellphoneNumber) {
this.cellphoneNumber = cellphoneNumber;
}
}
@Override
- public DialableFaxNumber getFaxNumber () {
+ public Integer getFaxAreaCode () {
+ return this.faxAreaCode;
+ }
+
+ @Override
+ public void setFaxAreaCode (final Integer faxAreaCode) {
+ this.faxAreaCode = faxAreaCode;
+ }
+
+ @Override
+ public Country getFaxCountry () {
+ return this.faxCountry;
+ }
+
+ @Override
+ public void setFaxCountry (final Country faxCountry) {
+ this.faxCountry = faxCountry;
+ }
+
+ @Override
+ public Long getFaxNumber () {
return this.faxNumber;
}
@Override
- public void setFaxNumber (final DialableFaxNumber faxNumber) {
+ public void setFaxNumber (final Long faxNumber) {
this.faxNumber = faxNumber;
}
}
@Override
- public DialableLandLineNumber getPhoneNumber () {
+ public Integer getPhoneAreaCode () {
+ return this.phoneAreaCode;
+ }
+
+ @Override
+ public void setPhoneAreaCode (final Integer phoneAreaCode) {
+ this.phoneAreaCode = phoneAreaCode;
+ }
+
+ @Override
+ public Country getPhoneCountry () {
+ return this.phoneCountry;
+ }
+
+ @Override
+ public void setPhoneCountry (final Country phoneCountry) {
+ this.phoneCountry = phoneCountry;
+ }
+
+ @Override
+ public Long getPhoneNumber () {
return this.phoneNumber;
}
@Override
- public void setPhoneNumber (final DialableLandLineNumber phoneNumber) {
+ public void setPhoneNumber (final Long phoneNumber) {
this.phoneNumber = phoneNumber;
}
@Override
public boolean isRequiredPersonalDataSet () {
- return ((this.getUserName() != null) &&
- (this.getGender() != null) &&
- (this.getFirstName() != null) &&
- (this.getFamilyName() != null) &&
- (this.getStreet() != null) &&
- (this.getHouseNumber() != null) &&
- (this.getZipCode() != null) &&
- (this.getCity() != null) &&
- (this.getEmailAddress() != null) &&
- (this.getEmailAddressRepeat() != null) &&
- (this.getUserPassword() != null) &&
- (this.getUserPasswordRepeat() != null));
+ return ((this.getUserName() != null)
+ && (this.getGender() != null)
+ && (this.getFirstName() != null)
+ && (this.getFamilyName() != null)
+ && (this.getStreet() != null)
+ && (this.getHouseNumber() != null)
+ && (this.getZipCode() != null)
+ && (this.getCity() != null)
+ && (this.getEmailAddress() != null)
+ && (this.getEmailAddressRepeat() != null)
+ && (this.getUserPassword() != null)
+ && (this.getUserPasswordRepeat() != null));
}
@Override
import java.util.Date;
import org.mxchange.jcontacts.contact.gender.Gender;
import org.mxchange.jcountry.data.Country;
-import org.mxchange.jphone.phonenumbers.cellphone.DialableCellphoneNumber;
-import org.mxchange.jphone.phonenumbers.fax.DialableFaxNumber;
-import org.mxchange.jphone.phonenumbers.landline.DialableLandLineNumber;
+import org.mxchange.jphone.phonenumbers.smsprovider.SmsProvider;
import org.mxchange.jusercore.model.user.User;
/**
public void setBirthday (final Date birthday);
/**
- * Cellphone number
+ * Getter for ellphone number's carrier
* <p>
- * @return the cellphoneNumber
+ * @return Cellphone number's carrier
*/
- public DialableCellphoneNumber getCellphoneNumber ();
+ public SmsProvider getCellphoneCarrier ();
/**
- * Cellphone number
+ * Setter for cellphone number's carrier prefix
* <p>
- * @param cellphoneNumber the cellphoneNumber to set
+ * @param cellphoneCarrier Cellphone number's carrier prefix
*/
- public void setCellphoneNumber (final DialableCellphoneNumber cellphoneNumber);
+ public void setCellphoneCarrier (final SmsProvider cellphoneCarrier);
+
+ /**
+ * Getter for ellphone number
+ * <p>
+ * @return Cellphone number
+ */
+ public Long getCellphoneNumber ();
+
+ /**
+ * Setter for ellphone number
+ * <p>
+ * @param cellphoneNumber Cellphone number
+ */
+ public void setCellphoneNumber (final Long cellphoneNumber);
/**
* City
public void setFamilyName (final String familyName);
/**
- * Fax number
+ * Getter for fax number's area code
+ * <p>
+ * @return Fax number's area code
+ */
+ public Integer getFaxAreaCode ();
+
+ /**
+ * Setter for fax number's area code
+ * <p>
+ * @param faxAreaCode Fax number's area code
+ */
+ public void setFaxAreaCode (final Integer faxAreaCode);
+
+ /**
+ * Getter for fax's country instance
+ * <p>
+ * @return Fax' country instance
+ */
+ public Country getFaxCountry ();
+
+ /**
+ * Setter for fax's country instance
* <p>
- * @return the faxNumber
+ * @param faxCountry Fax' country instance
*/
- public DialableFaxNumber getFaxNumber ();
+ public void setFaxCountry (final Country faxCountry);
/**
- * Fax number
+ * Getter for fax number
* <p>
- * @param faxNumber the faxNumber to set
+ * @return Fax number
*/
- public void setFaxNumber (final DialableFaxNumber faxNumber);
+ public Long getFaxNumber ();
+
+ /**
+ * Setter for fax number
+ * <p>
+ * @param faxNumber Fax number
+ */
+ public void setFaxNumber (final Long faxNumber);
/**
* First name
public void setHouseNumber (final Short houseNumber);
/**
- * Phone number
+ * Getter for phone number's area code
+ * <p>
+ * @return Phone number's area code
+ */
+ public Integer getPhoneAreaCode ();
+
+ /**
+ * Setter for phone number's area code
+ * <p>
+ * @param phoneAreaCode Phone number's area code
+ */
+ public void setPhoneAreaCode (final Integer phoneAreaCode);
+
+ /**
+ * Getter for phone number's country instance
+ * <p>
+ * @return Phone number's country instance
+ */
+ public Country getPhoneCountry ();
+
+ /**
+ * Setter for phone number's country instance
+ * <p>
+ * @param phoneCountry Phone number's country instance
+ */
+ public void setPhoneCountry (final Country phoneCountry);
+
+ /**
+ * Getter for phone number
* <p>
- * @return the phoneNumber
+ * @return Phone number
*/
- public DialableLandLineNumber getPhoneNumber ();
+ public Long getPhoneNumber ();
/**
- * Phone number
+ * Setter for phone number
* <p>
- * @param phoneNumber the phoneNumber to set
+ * @param phoneNumber Phone number
*/
- public void setPhoneNumber (final DialableLandLineNumber phoneNumber);
+ public void setPhoneNumber (final Long phoneNumber);
/**
* Street
<div class="table_row">
<div class="table_left">
- <h:outputLabel for="phoneNumber" value="#{msg.PERSONAL_DATA_PHONE_NUMBER}" />
+ <h:outputLabel value="#{msg.PERSONAL_DATA_PHONE_NUMBER}" />
</div>
<div class="table_right">
- <h:inputText class="input" id="phoneNumber" size="20" maxlength="255" value="#{userController.phoneNumber}" />
+ <h:selectOneMenu class="select" id="phoneCountryCode" value="#{userController.phoneCountry}">
+ <f:selectItems value="#{country.allCountries()}" var="c" itemValue="#{c}" itemLabel="#{c.countryAbroadDialPrefix}#{c.countryPhoneCode}" />
+ </h:selectOneMenu>
+
+ <h:inputText class="input" id="phoneAreaCode" size="5" maxlength="10" value="#{userController.phoneAreaCode}">
+ <f:validator for="phoneAreaCode" validatorId="PhoneNumberValidator" />
+ </h:inputText>
+
+ <h:inputText class="input" id="phoneNumber" size="10" maxlength="20" value="#{userController.phoneNumber}">
+ <f:validator for="phoneNumber" validatorId="PhoneNumberValidator" />
+ </h:inputText>
</div>
<div class="clear"></div>
</div>
<div class="table_right">
- <h:inputText class="input" id="faxNumber" size="20" maxlength="255" value="#{userController.faxNumber}" />
+ <h:selectOneMenu class="select" id="faxCountryCode" value="#{userController.faxCountry}">
+ <f:selectItems value="#{country.allCountries()}" var="c" itemValue="#{c}" itemLabel="#{c.countryAbroadDialPrefix}#{c.countryPhoneCode}" />
+ </h:selectOneMenu>
+
+ <h:inputText class="input" id="faxAreaCode" size="5" maxlength="10" value="#{userController.faxAreaCode}">
+ <f:validator for="faxAreaCode" validatorId="PhoneNumberValidator" />
+ </h:inputText>
+
+ <h:inputText class="input" id="faxNumber" size="10" maxlength="20" value="#{userController.faxNumber}">
+ <f:validator for="faxNumber" validatorId="PhoneNumberValidator" />
+ </h:inputText>
</div>
<div class="clear"></div>
</div>
<div class="table_right">
- <h:inputText class="input" id="cellphoneNumber" size="20" maxlength="255" value="#{userController.cellphoneNumber}" />
+ <h:selectOneMenu class="select" id="cellphoneCarrier" value="#{userController.cellphoneCarrier}">
+ <f:selectItems value="#{cellphone.allSmsProvider()}" var="c" itemValue="#{c}" itemLabel="#{c.countryAbroadDialPrefix}#{c.countryPhoneCode}" />
+ </h:selectOneMenu>
+
+ <h:inputText class="input" id="cellphoneNumber" size="10" maxlength="20" value="#{userController.cellphoneNumber}">
+ <f:validator for="cellphoneNumber" validatorId="PhoneNumberValidator" />
+ </h:inputText>
</div>
<div class="clear"></div>