Package org.jallinone.subjects.java

Examples of org.jallinone.subjects.java.SubjectPK


          }
        }

        public void beforeLookupAction(ValueObject parentVO) {
          DetailSaleDocVO vo = (DetailSaleDocVO)form.getVOModel().getValueObject();
          destDataLocator.getLookupFrameParams().put(ApplicationConsts.SUBJECT_PK,new SubjectPK(vo.getCompanyCodeSys01DOC01(),vo.getProgressiveReg04DOC01()));
          destDataLocator.getLookupValidationParameters().put(ApplicationConsts.SUBJECT_PK,new SubjectPK(vo.getCompanyCodeSys01DOC01(),vo.getProgressiveReg04DOC01()));
        }

        public void forceValidate() {}

      });
View Full Code Here


  /**
   * Retrieve employee detail and employee working hours.
   */
  private void loadEmployeeDetail(String companyCodeSys01SYS03,BigDecimal progressiveReg04SYS03) {
    // retrieve employee detail...
    Response res = ClientUtils.getData("loadEmployee",new SubjectPK(companyCodeSys01SYS03,progressiveReg04SYS03));
    if (res.isError()) {
      JOptionPane.showMessageDialog(
          ClientUtils.getParentFrame(this),
          res.getErrorMessage(),
          ClientSettings.getInstance().getResources().getResource("Error"),
View Full Code Here

    // since this method could be invoked also when selecting another row on the linked grid,
    // the pk attribute must be recalculated from the grid...
    int row = gridFrame.getGrid().getSelectedRow();
    if (row!=-1) {
      Subject gridVO = (Subject)gridFrame.getGrid().getVOListTableModel().getObjectForRow(row);
      pk = new SubjectPK(gridVO.getCompanyCodeSys01REG04(),gridVO.getProgressiveREG04());
    }


    return ClientUtils.getData("loadSupplier",pk);
  }
View Full Code Here

      DetailSupplierVO vo = (DetailSupplierVO)detailFrame.getCurrentForm().getVOModel().getValueObject();
      detailFrame.setTitle(ClientSettings.getInstance().getResources().getResource("supplier")+" "+vo.getSupplierCodePUR01()+" - "+vo.getName_1REG04());

      detailFrame.getReferencesPanel().getGrid().getOtherGridParams().put(
          ApplicationConsts.SUBJECT_PK,
          new SubjectPK(pk.getCompanyCodeSys01REG04(),pk.getProgressiveREG04())
      );
      detailFrame.getReferencesPanel().getGrid().reloadData();
      detailFrame.getHierarchiesPanel().getGrid().getOtherGridParams().put(
          ApplicationConsts.SUBJECT_PK,
          new SubjectPK(pk.getCompanyCodeSys01REG04(),pk.getProgressiveREG04())
      );
      detailFrame.getHierarchiesPanel().getGrid().getOtherGridParams().put(
          ApplicationConsts.SUBJECT_TYPE,
          ApplicationConsts.SUBJECT_SUPPLIER
      );
View Full Code Here

   */
  public Response insertRecord(ValueObject newPersistentObject) throws Exception {
    Response response = ClientUtils.getData("insertSupplier",newPersistentObject);
    if (!response.isError()) {
      DetailSupplierVO vo = (DetailSupplierVO)((VOResponse)response).getVo();
      pk = new SubjectPK(
        vo.getCompanyCodeSys01REG04(),
        vo.getProgressiveREG04()
      );
//      gridFrame.reloadData();
      detailFrame.getReferencesPanel().getGrid().getOtherGridParams().put(
          ApplicationConsts.SUBJECT_PK,
          new SubjectPK(pk.getCompanyCodeSys01REG04(),pk.getProgressiveREG04())
      );
      detailFrame.getReferencesPanel().getGrid().reloadData();
      detailFrame.getHierarchiesPanel().getGrid().getOtherGridParams().put(
          ApplicationConsts.SUBJECT_PK,
          new SubjectPK(pk.getCompanyCodeSys01REG04(),pk.getProgressiveREG04())
      );
      detailFrame.getHierarchiesPanel().getGrid().getOtherGridParams().put(
          ApplicationConsts.SUBJECT_TYPE,
          ApplicationConsts.SUBJECT_SUPPLIER
      );
View Full Code Here

   * @return an ErrorResponse value object in case of errors, VOResponse if the operation is successfully completed
   */
  public Response deleteRecord(ValueObject persistentObject) throws Exception {
    ArrayList list = new ArrayList();
    DetailSupplierVO vo = (DetailSupplierVO)persistentObject;
    list.add(new SubjectPK(vo.getCompanyCodeSys01REG04(),vo.getProgressiveREG04()));
    Response response = ClientUtils.getData("deleteSuppliers",list);
    if (!response.isError()) {
      gridFrame.reloadData();
      detailFrame.getReferencesPanel().getGrid().clearData();
      detailFrame.getHierarchiesPanel().getGrid().clearData();
View Full Code Here

      attribute2dbField.put("destinationCodeREG18","REG18_DESTINATIONS.DESTINATION_CODE");
      attribute2dbField.put("descriptionREG18","REG18_DESTINATIONS.DESCRIPTION");

      ArrayList values = new ArrayList();

      SubjectPK pk = (SubjectPK)gridParams.getOtherGridParams().get(ApplicationConsts.SUBJECT_PK);

      values.add(pk.getCompanyCodeSys01REG04());
      values.add(pk.getProgressiveREG04());


      // read from REG18 table...
      Response answer = QueryUtil.getQuery(
          conn,
View Full Code Here

      attribute2dbField.put("countryREG18","REG18_DESTINATIONS.COUNTRY");
      attribute2dbField.put("destinationCodeREG18","REG18_DESTINATIONS.DESTINATION_CODE");
      attribute2dbField.put("descriptionREG18","REG18_DESTINATIONS.DESCRIPTION");

      ArrayList values = new ArrayList();
      SubjectPK pk = (SubjectPK)validationPars.getLookupValidationParameters().get(ApplicationConsts.SUBJECT_PK);
      values.add(pk.getCompanyCodeSys01REG04());
      values.add(pk.getProgressiveREG04());

      GridParams gridParams = new GridParams();

      // read from REG18 table...
      Response answer = QueryUtil.getQuery(
View Full Code Here

  /**
   * Callback method called when the data loading is completed.
   * @param error <code>true</code> if an error occours during data loading, <code>false</code> if data loading is successfully completed
   */
  public void loadDataCompleted(boolean error) {
    SubjectPK pk = new SubjectPK(
        subVO.getCompanyCodeSys01REG04(),
        subVO.getProgressiveREG04()
    );
    detailFrame.getReferencesPanel().getGrid().getOtherGridParams().put(
        ApplicationConsts.SUBJECT_PK,
        pk
    );
    detailFrame.getReferencesPanel().getGrid().reloadData();

    detailFrame.getHierarchiesPanel().getGrid().getOtherGridParams().put(
        ApplicationConsts.SUBJECT_PK,
        pk
    );
    detailFrame.getHierarchiesPanel().getGrid().getOtherGridParams().put(
        ApplicationConsts.SUBJECT_TYPE,
        ApplicationConsts.SUBJECT_ORGANIZATION_CONTACT
    );
    detailFrame.getHierarchiesPanel().getGrid().reloadData();

    detailFrame.getContactsPanel().getGrid().getOtherGridParams().put(
        ApplicationConsts.SUBJECT_PK,
        pk
    );
    detailFrame.getContactsPanel().getGrid().reloadData();

    detailFrame.getActivitiesGrid().getOtherGridParams().put(ApplicationConsts.COMPANY_CODE_SYS01,pk.getCompanyCodeSys01REG04());
    detailFrame.getActivitiesGrid().getOtherGridParams().put(ApplicationConsts.PROGRESSIVE_REG04_SUBJECT,pk.getProgressiveREG04());
    detailFrame.getActivitiesGrid().reloadData();


    // disable people contacts panel if this is not an organization...
    if (organization!=null || subVO.getSubjectTypeREG04().equals(ApplicationConsts.SUBJECT_PEOPLE_CONTACT))
View Full Code Here

          sub.getProgressiveREG04(),
          null, // it's not very good...
          null, // it's not very good...
          sub.getSubjectTypeREG04()
      );
      SubjectPK pk = new SubjectPK(
          sub.getCompanyCodeSys01REG04(),
          sub.getProgressiveREG04()
      );

//      gridFrame.reloadData();

      detailFrame.getReferencesPanel().getGrid().getOtherGridParams().put(
          ApplicationConsts.SUBJECT_PK,
          pk
      );
      detailFrame.getReferencesPanel().getGrid().reloadData();

      detailFrame.getHierarchiesPanel().getGrid().getOtherGridParams().put(
          ApplicationConsts.SUBJECT_PK,
          pk
      );

      detailFrame.getHierarchiesPanel().getGrid().getOtherGridParams().put(
          ApplicationConsts.SUBJECT_TYPE,
          ApplicationConsts.SUBJECT_ORGANIZATION_CONTACT
      );
      detailFrame.getHierarchiesPanel().getGrid().reloadData();

      detailFrame.getContactsPanel().getGrid().getOtherGridParams().put(
          ApplicationConsts.SUBJECT_PK,
          pk
      );
      detailFrame.getContactsPanel().getGrid().reloadData();

      detailFrame.getActivitiesGrid().getOtherGridParams().put(ApplicationConsts.COMPANY_CODE_SYS01,pk.getCompanyCodeSys01REG04());
      detailFrame.getActivitiesGrid().getOtherGridParams().put(ApplicationConsts.PROGRESSIVE_REG04_SUBJECT,pk.getProgressiveREG04());
      detailFrame.getActivitiesGrid().reloadData();

      // disable people contacts panel if this is not an organization...
      if (organization!=null || subVO.getSubjectTypeREG04().equals(ApplicationConsts.SUBJECT_PEOPLE_CONTACT))
        detailFrame.getTabbedPane().setEnabledAt(3,false);
View Full Code Here

TOP

Related Classes of org.jallinone.subjects.java.SubjectPK

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.