Package com.any_erp_vendor.moa.objects.resources.v1_0

Examples of com.any_erp_vendor.moa.objects.resources.v1_0.Email


    try {
      LightweightPerson lightweightPerson = entUser.getLightweightPerson();
      enterpriseID = lightweightPerson.getInstitutionalId();
      BasicPerson basicPerson = getBasicPerson(enterpriseID);
      Name name = basicPerson.getName();
      String firstName = name.getFirstName();
      String lastName = name.getLastName();
      String middleName = name.getMiddleName();
      updateName (principal, firstName, lastName, middleName);
      List eMails = basicPerson.getEmail();
      updateEmail (principal, eMails);
      List phones = basicPerson.getPhone();
      updatePhone (principal, phones);
View Full Code Here


      if (bpBaseline != null) {
        try {
          logger.info("["+portletName+"] Baseline:\n"+bpBaseline.toXmlString());
          BasicPerson bp = (BasicPerson) bpBaseline.clone();
          bp.setBaseline(bpBaseline);
          Name name=bp.getName();
          name.setLastName(lastName);
          name.setFirstName(firstName);
          name.setMiddleName(middleName);
          bp.setName(name);
          if (gender!=null) {
            bp.setGender(gender);
          }
          List addressList = bp.getAddress();
View Full Code Here

   * @throws EnterpriseObjectCreateException
   */
  private BasicPerson createBasicPerson(String instID, String firstName, String lastName, String email) throws EnterpriseConfigurationObjectException, EnterpriseFieldException, EnterpriseObjectCreateException {
        BasicPerson aeo = (BasicPerson)appConfig.getObject(BASIC_PERSON);
        logger.info("["+portletName+"] Got " + BASIC_PERSON + " from AppConfig, performing Create...");
        Name aName = aeo.newName();
        aName.setFirstName(firstName);
        aName.setLastName(lastName);
        aeo.setName(aName);
        aeo.setInstitutionalId(instID);
        if (!"".equals(email)) {
          Email e = aeo.newEmail();
          e.setEmailAddress(email);
View Full Code Here

      // have to determine if we need to insert, delete or update any
      logger.info("Starting Phone update process...");
      java.util.List newPhones = newData.getPhone();
      java.util.List oldPhones = baselinePerson.getPhone();
      for (int i=0; i<newPhones.size(); i++) {
        Phone newPhone = (Phone)newPhones.get(i);
        String newPhoneKey = newPhone.getCombinedKeyValue();
        boolean foundMatch = false;
        for (int j=0; j<oldPhones.size(); j++) {
          Phone oldPhone = (Phone)oldPhones.get(j);
          String oldPhoneKey = oldPhone.getCombinedKeyValue();
          if (oldPhoneKey.equalsIgnoreCase(newPhoneKey)) {
            // found a match, might have to update...
            foundMatch = true;
            if (newPhone.equals(oldPhone) == false) {
              // need to update individual phone
              logger.info("updating existing phone object.");
              updatePhone(conn, msgCategory, msgObject, msgRelease, instId, newPhone);
            }
          }
        }
        if (foundMatch == false) {
          // need to create phone
          logger.info("creating new address object.");
          createPhone(conn, msgCategory, msgObject, msgRelease, instId, newPhone);
        }
      }
      // now we need to check the oldPhones and delete any that don't
      // exist in the newAddress list
      for (int i=0; i<oldPhones.size(); i++) {
        Phone oldPhone = (Phone)oldPhones.get(i);
        String oldPhoneKey = oldPhone.getCombinedKeyValue();
        boolean foundMatch = false;
        for (int j=0; j<newPhones.size(); j++) {
          Phone newPhone = (Phone)newPhones.get(j);
          String newPhoneKey = newPhone.getCombinedKeyValue();
          if (oldPhoneKey.equalsIgnoreCase(newPhoneKey)) {
            // found a match, don't delete
            foundMatch = true;
          }
        }
View Full Code Here

          // get the phones associated to the basic person
          java.util.List phones = bp.getPhone();
          java.util.Vector vPhone = new java.util.Vector();
          if (phones.size() > 0) {
            for (int j=0; j<phones.size(); j++) {
              Phone p = bp.getPhone(j);
              vPhone.add(p);
            }
          }
          bp_phoneList.setListData(vPhone);
          bp_phoneList.updateUI();
          // get the emails associated to the basic person
          java.util.List emails = bp.getEmail();
          java.util.Vector vEmail = new java.util.Vector();
          if (emails.size() > 0) {
            for (int j=0; j<emails.size(); j++) {
              Email p = bp.getEmail(j);
              vEmail.add(p);
              org.openeai.OpenEaiObject.logger.info("Email="+p.toXmlString());
            }
          }
          bp_emailList.setListData(vEmail);
          bp_emailList.updateUI();
         
View Full Code Here

   * Retrieves the Phone object stored in the List at the selected index and populates the Phone
   * form items with information contained in that Phone object.
   **/
  void bp_phoneList_mouseClicked(MouseEvent e)
  {
    Phone p = (Phone)bp_phoneList.getSelectedValue();
    if (p != null) {
      bp_phoneType.setSelectedItem(p.getType());
     
      bp_phoneAreaCode.setText(p.getPhoneArea());
      bp_phoneNumber.setText(p.getPhoneNumber());
    }
   
  }
View Full Code Here

        deleteAddress(conn, msgCategory, msgObject, msgRelease, instId, a);
      }

      // now the phone(s), using the same connection
      for (int i=0; i<bPerson.getPhone().size(); i++) {
        Phone phone = bPerson.getPhone(i);
        deletePhone(conn, msgCategory, msgObject, msgRelease, instId, phone);
      }

      // now the email(s), using the same connection
View Full Code Here

    protected void bp_phoneAdd_mouseClicked(MouseEvent e)
    {
      String messageObjectName = BASIC_PERSON;
      org.openeai.OpenEaiObject.logger.info("Message Object Name is: " + messageObjectName);
      try {
        Phone p = null;
        int index = bp_phoneList.getSelectedIndex();
        if (index == -1) {
          BasicPerson bPerson = (BasicPerson)APP_CONFIG.getObject(messageObjectName);
          org.openeai.OpenEaiObject.logger.info("got " + messageObjectName + " from AppConfig");
          p = bPerson.newPhone();
        }
        else {
          p = (Phone)bp_phoneList.getSelectedValue();
        }
        p.setType((String)bp_phoneType.getSelectedItem());
        p.setPhoneArea(bp_phoneAreaCode.getText());
        p.setPhoneNumber(bp_phoneNumber.getText());
       
        javax.swing.ListModel lm = bp_phoneList.getModel();
        java.util.Vector vPhones = new java.util.Vector();
        for (int i=0; i<lm.getSize(); i++) {
          vPhones.add(lm.getElementAt(i));
View Full Code Here

        createAddress(conn, msgCategory, msgObject, msgRelease, instId, a);
      }

      // now the phone(s), using the same connection
      for (int i=0; i<bPerson.getPhone().size(); i++) {
        Phone phone = bPerson.getPhone(i);
        createPhone(conn, msgCategory, msgObject, msgRelease, instId, phone);
      }

      // now the email(s), using the same connection
View Full Code Here

        ec_street1.setText(a.getStreet1());
        ec_city.setText(a.getCityOrLocality());
        ec_stateList.setSelectedItem(a.getStateOrProvince());
        ec_zip.setText(a.getZipOrPostalCode());
      }
      Phone p = ec.getPhone();
      if (p != null) {
        ec_phone.setText(p.getPhoneNumber());
      }
     
    }
View Full Code Here

TOP

Related Classes of com.any_erp_vendor.moa.objects.resources.v1_0.Email

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.