Examples of OrganizationVO


Examples of org.jallinone.subjects.java.OrganizationVO

      if (vo.getCompanyCodeSys01SAL09()!=null) {
        // set default currency code...
        Response res = ClientUtils.getData("loadCompany",vo.getCompanyCodeSys01SAL09());
        if (!res.isError()) {
          OrganizationVO compVO = (OrganizationVO)((VOResponse)res).getVo();
          vo.setCurrencyCodeReg03SAL09(compVO.getCurrencyCodeReg03());
        }
      }
    }

  }
View Full Code Here

Examples of org.jallinone.subjects.java.OrganizationVO

   * @param newValueObject value object to save
   * @return an ErrorResponse value object in case of errors, VOResponse if the operation is successfully completed
   */
  public Response insertRecord(ValueObject newPersistentObject) throws Exception {
    if (frame.getControlSubjectType().getValue().equals(ApplicationConsts.SUBJECT_ORGANIZATION)) {
      OrganizationVO vo = (OrganizationVO)newPersistentObject;
      vo.setCompanyCodeSys01REG04((String)frame.getControlCompaniesCombo().getValue());
      vo.setSubjectTypeREG04(ApplicationConsts.SUBJECT_ORGANIZATION_CONTACT);
    }
    else {
      PeopleVO vo = (PeopleVO)newPersistentObject;
      vo.setCompanyCodeSys01REG04((String)frame.getControlCompaniesCombo().getValue());
      vo.setSubjectTypeREG04(ApplicationConsts.SUBJECT_PEOPLE_CONTACT);
    }

    Response res = ClientUtils.getData("insertSubject",newPersistentObject);
    if (!res.isError()) {

View Full Code Here

Examples of org.jallinone.subjects.java.OrganizationVO

      setSize(750,640);
      setMinimumSize(new Dimension(750,640));

      organizationPanel.setFunctionId("REG04_CONTACTS");
      organizationPanel.setVOClassName("org.jallinone.subjects.java.OrganizationVO");
      organizationPanel.getVOModel().setValueObject(new OrganizationVO());
      organizationPanel.setFormController(callOutSubjectController);
      organizationPanel.setInsertButton(insertButton5);
      organizationPanel.setEditButton(editButton5);
      organizationPanel.setSaveButton(saveButton5);
      organizationPanel.setReloadButton(reloadButton5);

      peoplePanel.setFunctionId("REG04_CONTACTS");
      peoplePanel.setVOClassName("org.jallinone.subjects.java.PeopleVO");
      peoplePanel.getVOModel().setValueObject(new PeopleVO());
      peoplePanel.setFormController(callOutSubjectController);
      peoplePanel.setInsertButton(insertButton5);
      peoplePanel.setEditButton(editButton5);
      peoplePanel.setSaveButton(saveButton5);
      peoplePanel.setReloadButton(reloadButton5);


      calloutPanel.setFormController(controller);

      CustomizedControls customizedControls = new CustomizedControls(tab,calloutPanel,ApplicationConsts.ID_CALL_OUTS);

      // people lookup...
      peopleDataLocator.setGridMethodName("loadSubjectPerName");
      peopleDataLocator.setValidationMethodName("");
      filterPeopleButton.setLookupController(peopleController);
      peopleController.setLookupDataLocator(peopleDataLocator);
      peopleController.setFrameTitle("people");
      peopleController.setLookupValueObjectClassName("org.jallinone.subjects.java.PeopleVO");
      peopleController.setAllColumnVisible(false);
      peopleController.setVisibleColumn("name_1REG04", true);
      peopleController.setVisibleColumn("name_2REG04", true);
      peopleController.setVisibleColumn("addressREG04", true);
      peopleController.setVisibleColumn("cityREG04", true);
      peopleController.setVisibleColumn("provinceREG04", true);
      peopleController.setVisibleColumn("countryREG04", true);
      peopleController.setVisibleColumn("zipREG04", true);
      peopleController.setHeaderColumnName("addressREG04", "address");
      peopleController.setHeaderColumnName("cityREG04", "city");
      peopleController.setHeaderColumnName("provinceREG04", "prov");
      peopleController.setHeaderColumnName("countryREG04", "country");
      peopleController.setHeaderColumnName("zipREG04", "zip");
      peopleController.setPreferredWidthColumn("name_1REG04", 120);
      peopleController.setPreferredWidthColumn("name_2REG04", 120);
      peopleController.setPreferredWidthColumn("addressREG04", 200);
      peopleController.setPreferredWidthColumn("provinceREG04", 50);
      peopleController.setPreferredWidthColumn("countryREG04", 70);
      peopleController.setPreferredWidthColumn("zipREG04", 50);
      peopleController.setFramePreferedSize(new Dimension(740,500));
      peopleController.addLookupListener(new LookupListener() {

        public void codeValidated(boolean validated) {}

        public void codeChanged(ValueObject parentVO,Collection parentChangedAttributes) {
          PeopleVO vo = (PeopleVO)peopleController.getLookupVO();
          peoplePanel.getVOModel().setValueObject(vo);
          peoplePanel.setMode(Consts.READONLY);
          peoplePanel.pull();
          tab.setEnabledAt(1,true);
          controlCompaniesCombo.setEnabled(false);
          controlSubjectType.setEnabled(false);
        }

        public void beforeLookupAction(ValueObject parentVO) {
          peopleDataLocator.getLookupFrameParams().put(ApplicationConsts.COMPANY_CODE_SYS01,controlCompaniesCombo.getValue());
          peopleDataLocator.getLookupFrameParams().put(ApplicationConsts.SUBJECT_TYPE,ApplicationConsts.SUBJECT_PEOPLE);
        }

        public void forceValidate() {}

      });


      // organization lookup...
      orgDataLocator.setGridMethodName("loadSubjectPerName");
      orgDataLocator.setValidationMethodName("");
      filterOrgButton.setLookupController(orgController);
      orgController.setLookupDataLocator(orgDataLocator);
      orgController.setFrameTitle("organizations");
      orgController.setLookupValueObjectClassName("org.jallinone.subjects.java.OrganizationVO");
      orgController.setAllColumnVisible(false);
      orgController.setVisibleColumn("name_1REG04", true);
      orgController.setVisibleColumn("addressREG04", true);
      orgController.setVisibleColumn("cityREG04", true);
      orgController.setVisibleColumn("provinceREG04", true);
      orgController.setVisibleColumn("countryREG04", true);
      orgController.setVisibleColumn("zipREG04", true);
      orgController.setHeaderColumnName("addressREG04", "address");
      orgController.setHeaderColumnName("cityREG04", "city");
      orgController.setHeaderColumnName("provinceREG04", "prov");
      orgController.setHeaderColumnName("countryREG04", "country");
      orgController.setHeaderColumnName("zipREG04", "zip");
      orgController.setPreferredWidthColumn("name_1REG04", 150);
      orgController.setPreferredWidthColumn("addressREG04", 200);
      orgController.setPreferredWidthColumn("provinceREG04", 50);
      orgController.setPreferredWidthColumn("zipREG04", 50);
      orgController.setFramePreferedSize(new Dimension(740,500));
      orgController.addLookupListener(new LookupListener() {

        public void codeValidated(boolean validated) {}

        public void codeChanged(ValueObject parentVO,Collection parentChangedAttributes) {
          OrganizationVO vo = (OrganizationVO)orgController.getLookupVO();
          organizationPanel.getVOModel().setValueObject(vo);
          organizationPanel.setMode(Consts.READONLY);
          organizationPanel.pull();
          tab.setEnabledAt(1,true);
          controlCompaniesCombo.setEnabled(false);
          controlSubjectType.setEnabled(false);
        }

        public void beforeLookupAction(ValueObject parentVO) {
          orgDataLocator.getLookupFrameParams().put(ApplicationConsts.COMPANY_CODE_SYS01,controlCompaniesCombo.getValue());
          orgDataLocator.getLookupFrameParams().put(ApplicationConsts.SUBJECT_TYPE,ApplicationConsts.SUBJECT_ORGANIZATION);
        }

        public void forceValidate() {}

      });


      // call-out code lookup...
      callOutDataLocator.setGridMethodName("loadCallOuts");
      callOutDataLocator.setValidationMethodName("validateCallOutCode");
      controlCallOutCode.setLookupController(callOutController);
      controlCallOutCode.setControllerMethodName("getCallOuts");
      callOutController.setCodeSelectionWindow(callOutController.TREE_GRID_FRAME);
      callOutController.setLookupDataLocator(callOutDataLocator);
      callOutTreeLevelDataLocator.setServerMethodName("loadCompanyHierarchy");
      callOutDataLocator.setTreeDataLocator(callOutTreeLevelDataLocator);
      callOutController.setFrameTitle("call-outs");
      callOutController.setLookupValueObjectClassName("org.jallinone.scheduler.callouts.java.CallOutVO");
      callOutController.addLookup2ParentLink("callOutCodeSCH10", "callOutCodeSch10SCH03");
      callOutController.addLookup2ParentLink("descriptionSYS10", "callOutDescriptionSYS10");
      callOutController.setAllColumnVisible(false);
      callOutController.setVisibleColumn("callOutCodeSCH10", true);
      callOutController.setVisibleColumn("descriptionSYS10", true);
      callOutController.setPreferredWidthColumn("descriptionSYS10",250);
      callOutController.setFramePreferedSize(new Dimension(600,500));
      callOutDataLocator.setNodeNameAttribute("descriptionSYS10");
      callOutController.addLookupListener(new LookupListener() {

        public void codeValidated(boolean validated) {}

        public void codeChanged(ValueObject parentVO,Collection parentChangedAttributes) {
          DetailCallOutRequestVO vo = (DetailCallOutRequestVO)calloutPanel.getVOModel().getValueObject();
          vo.setDescriptionSCH03(vo.getCallOutDescriptionSYS10());
          calloutPanel.pull("descriptionSCH03");
        }

        public void beforeLookupAction(ValueObject parentVO) {
          DetailCallOutRequestVO vo = (DetailCallOutRequestVO)calloutPanel.getVOModel().getValueObject();
          if (vo.getCompanyCodeSys01SCH03()==null)
            vo.setCompanyCodeSys01SCH03((String)controlCompaniesCombo.getValue());
          callOutTreeLevelDataLocator.getTreeNodeParams().put(ApplicationConsts.PROGRESSIVE_HIE02,vo.getProgressiveHie02SCH10());
          callOutTreeLevelDataLocator.getTreeNodeParams().put(ApplicationConsts.COMPANY_CODE_SYS01,vo.getCompanyCodeSys01SCH03());
          callOutDataLocator.getLookupFrameParams().put(ApplicationConsts.PROGRESSIVE_HIE02,vo.getProgressiveHie02SCH10());
          callOutDataLocator.getLookupValidationParameters().put(ApplicationConsts.PROGRESSIVE_HIE02,vo.getProgressiveHie02SCH10());
          callOutDataLocator.getLookupFrameParams().put(ApplicationConsts.COMPANY_CODE_SYS01,vo.getCompanyCodeSys01SCH03());
          callOutDataLocator.getLookupValidationParameters().put(ApplicationConsts.COMPANY_CODE_SYS01,vo.getCompanyCodeSys01SCH03());
        }

        public void forceValidate() {}

      });
View Full Code Here

Examples of org.jallinone.subjects.java.OrganizationVO

    Response res = ClientUtils.getData("loadSubjectPerName",gridParams);
    if (!res.isError()) {
      java.util.List vos = ((VOListResponse)res).getRows();
      if (vos.size()==1) {
        // organization found...
        OrganizationVO vo = (OrganizationVO)vos.get(0);
        organizationPanel.getVOModel().setValueObject(vo);
        organizationPanel.setMode(Consts.READONLY);
        organizationPanel.pull();
        tab.setEnabledAt(1,true);
        controlCompaniesCombo.setEnabled(false);
View Full Code Here

Examples of org.jallinone.subjects.java.OrganizationVO

    orgController.addLookupListener(new LookupListener() {

      public void codeValidated(boolean validated) {}

      public void codeChanged(ValueObject parentVO,Collection parentChangedAttributes) {
        OrganizationVO vo = (OrganizationVO)orgController.getLookupVO();
        controlName_1.setValue(vo.getName_1REG04());
        controlName_2.setValue(vo.getName_2REG04());
        filterOrgButton.setValue(vo.getProgressiveREG04());
      }

      public void beforeLookupAction(ValueObject parentVO) {
//        orgDataLocator.getLookupFrameParams().put(ApplicationConsts.COMPANY_CODE_SYS01,empVO.getCompanyCodeSys01REG04());
        orgDataLocator.getLookupFrameParams().put(ApplicationConsts.SUBJECT_TYPE,ApplicationConsts.SUBJECT_ORGANIZATION);
View Full Code Here

Examples of org.jallinone.subjects.java.OrganizationVO

   * Method called by the Form panel to delete existing data.
   * @param persistentObject value object to delete
   * @return an ErrorResponse value object in case of errors, VOResponse if the operation is successfully completed
   */
  public Response deleteRecord(ValueObject persistentObject) throws Exception {
    OrganizationVO vo = (OrganizationVO)persistentObject;
    SubjectPK pk = new SubjectPK(vo.getCompanyCodeSys01REG04(),vo.getProgressiveREG04());
    Response response = ClientUtils.getData("deleteCompany",pk);
    if (!response.isError()) {
      gridFrame.reloadData();
    }
    return response;
View Full Code Here

Examples of org.jallinone.subjects.java.OrganizationVO

      // retrieve company data...
      //SubjectPK subjectPK = new SubjectPK(pk.getCompanyCodeSys01DOC01(),progressiveREG04);
      Response companyRes = companyAction.loadCompany(pk.getCompanyCodeSys01DOC01(),serverLanguageId,username);
      if (companyRes.isError())
        throw new Exception(companyRes.getErrorMessage());
      OrganizationVO companyVO = (OrganizationVO)((VOResponse)companyRes).getVo();

      // prepare text file...
      GridSaleDocRowVO docRowVO = null;
      String tmpFile = path+"/receipt_"+docVO.getDocYearDOC01()+"_"+docVO.getDocSequenceDOC01()+".tmp";
      PrintWriter pw = new PrintWriter(new FileOutputStream(tmpFile));
      pw.println(companyVO.getName_1REG04());
      pw.println(companyVO.getAddressREG04()==null?"":companyVO.getAddressREG04());
      pw.println(companyVO.getCityREG04()==null?"":companyVO.getCityREG04());
      pw.println(companyVO.getProvinceREG04()==null?"":companyVO.getProvinceREG04());
      pw.println(companyVO.getTaxCodeREG04()==null?"":companyVO.getTaxCodeREG04());
      pw.println();

      for(int i=0;i<rows.size();i++) {
        docRowVO = (GridSaleDocRowVO)rows.get(i);
        pw.println(
View Full Code Here

Examples of org.jallinone.subjects.java.OrganizationVO

          "COMPANY_CODE_SYS01='"+companyCode+"' and "+
          "REG04_SUBJECTS.COMPANY_CODE_SYS01=SYS01_COMPANIES.COMPANY_CODE and "+
          "SYS01_COMPANIES.ENABLED='Y' and "+
          "REG04_SUBJECTS.SUBJECT_TYPE='M'"
      );
      OrganizationVO vo = new OrganizationVO();
      if(rset.next()) {
        vo.setCompanyCodeSys01REG04(companyCode);
        vo.setSubjectTypeREG04(rset.getString(1));
        vo.setName_1REG04(rset.getString(2));
        vo.setName_2REG04(rset.getString(3));
        vo.setAddressREG04(rset.getString(4));

        vo.setCityREG04(rset.getString(5));
        vo.setZipREG04(rset.getString(6));
        vo.setProvinceREG04(rset.getString(7));
        vo.setCountryREG04(rset.getString(8));
        vo.setTaxCodeREG04(rset.getString(9));
        vo.setPhoneNumberREG04(rset.getString(10));
        vo.setFaxNumberREG04(rset.getString(11));
        vo.setEmailAddressREG04(rset.getString(12));
        vo.setWebSiteREG04(rset.getString(13));
        vo.setLawfulSiteREG04(rset.getString(14));
        vo.setNoteREG04(rset.getString(15));
        vo.setCurrencyCodeReg03(rset.getString(16));
        vo.setProgressiveREG04(rset.getBigDecimal(17));
        rset.close();

      }
      else {
        rset.close();
View Full Code Here

Examples of org.jallinone.subjects.java.OrganizationVO

    return "updateCompany";
  }


  public final Response executeCommand(Object inputPar,UserSessionParameters userSessionPars,HttpServletRequest request, HttpServletResponse response,HttpSession userSession,ServletContext context) {
    OrganizationVO oldVO = (OrganizationVO)((ValueObject[])inputPar)[0];
    OrganizationVO newVO = (OrganizationVO)((ValueObject[])inputPar)[1];
    try {
      // retrieve internationalization settings (Resources object)...
      ServerResourcesFactory factory = (ServerResourcesFactory)context.getAttribute(Controller.RESOURCES_FACTORY);
      String serverLanguageId = ((JAIOUserSessionParameters)userSessionPars).getServerLanguageId();
      String t1 = factory.getResources(serverLanguageId).getResource("there is already another people with the same first and last name.");
View Full Code Here

Examples of org.jallinone.subjects.java.OrganizationVO

    return "insertCompany";
  }


  public final Response executeCommand(Object inputPar,UserSessionParameters userSessionPars,HttpServletRequest request, HttpServletResponse response,HttpSession userSession,ServletContext context) {
    OrganizationVO vo = (OrganizationVO)inputPar;
    try {
      // retrieve internationalization settings (Resources object)...
      ServerResourcesFactory factory = (ServerResourcesFactory)context.getAttribute(Controller.RESOURCES_FACTORY);
      String serverLanguageId = ((JAIOUserSessionParameters)userSessionPars).getServerLanguageId();
      String t1 = factory.getResources(serverLanguageId).getResource("there is already another organization with the same corporate name.");

      Companies bean = (Companies)JAIOBeanFactory.getInstance().getBean(Companies.class);
      Response answer = bean.insertCompany(vo,t1,((JAIOUserSessionParameters)userSessionPars).getServerLanguageId(),userSessionPars.getUsername());

      VariantDescriptionsVO d = new VariantDescriptionsVO();
      ((JAIOUserSessionParameters)userSessionPars).getVariantDescriptionsVO().put(vo.getCompanyCodeSys01REG04(),d);

      return answer;
    }
    catch (Throwable ex) {
      Logger.error(userSessionPars.getUsername(),this.getClass().getName(),"executeCommand","Error while processing request",ex);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.