示例#1
0
 public void setTypeCode(String typeCode) {
   String oldValue = null;
   if (baUnitType != null) {
     oldValue = baUnitType.getCode();
   }
   setBaUnitType(CacheManager.getBeanByCode(CacheManager.getBaUnitTypes(), typeCode));
   propertySupport.firePropertyChange(TYPE_CODE_PROPERTY, oldValue, typeCode);
 }
 public void setStatusCode(String statusCode) {
   String oldValue = null;
   if (status != null) {
     oldValue = status.getCode();
   }
   setStatus(CacheManager.getBeanByCode(CacheManager.getRegistrationStatusTypes(), statusCode));
   propertySupport.firePropertyChange(STATUS_CODE_PROPERTY, oldValue, statusCode);
 }
 /**
  * Loads list of {@link ServiceActionTypeBean}.
  *
  * @param createDummy Indicates whether to add empty object on the list.
  */
 public final void loadList(boolean createDummy) {
   loadCodeList(
       ServiceActionTypeBean.class,
       serviceActionTypes,
       CacheManager.getAppServiceActionTypes(),
       createDummy);
 }
示例#4
0
  // TODO - Fix code to use localized strings and system code values.
  public String getDescription() {
    String description = "";
    String actType = getActionType();
    if (getRecordGroup().equalsIgnoreCase("application")) {
      ApplicationActionTypeBean appActionTypeBean =
          CacheManager.getBeanByCode(CacheManager.getApplicationActionTypes(), actType);
      actType =
          appActionTypeBean == null
              ? actType.substring(0, 1).toUpperCase() + actType.substring(1)
              : appActionTypeBean.getDisplayValue();
      description = "Application, Action: " + actType;
    } else if (getRecordGroup().equalsIgnoreCase("service")) {
      ServiceActionTypeBean serActionTypeBean =
          CacheManager.getBeanByCode(CacheManager.getAppServiceActionTypes(), actType);
      actType =
          serActionTypeBean == null
              ? actType.substring(0, 1).toUpperCase() + actType.substring(1)
              : serActionTypeBean.getDisplayValue();

      String requestType = getRecordType();
      RequestTypeBean requestTypeBean =
          CacheManager.getBeanByCode(CacheManager.getRequestTypes(), getRecordType());
      requestType = requestTypeBean == null ? requestType : requestTypeBean.getDisplayValue();

      description = requestType + " (" + getNumber() + "), Action: " + actType;
    } else {
      actType = actType.substring(0, 1).toUpperCase() + actType.substring(1);
      description = getRecordType() + " " + getNumber() + ", Action: " + actType;
    }
    return description;
  }
 /**
  * Initializes object's instance and populates {@link ObservableList}< {@link RrrTypeBean} >
  * with values from the cache.
  */
 public CadastreObjectTypeListBean() {
   // Load from cache by default
   cadastreObjectTypeList =
       new SolaCodeList<CadastreObjectTypeBean>(CacheManager.getCadastreObjectTypes());
 }