@Override
 protected void onReset() {
   super.onReset();
   PlaceRequest currentPlace = placeManager.getCurrentPlaceRequest();
   if (phenotype != null) {
     getView().showPhenotypeInfo(phenotype);
     if (currentPlace.getParameterNames().size() == 1) {
       phenotypeOverviewPresenter.setData(phenotype, mRNAHistogramDataTable, bsHistogramDataTable);
       setInSlot(TYPE_SetMainContent, phenotypeOverviewPresenter);
       getView().setActiveLink(NAV_ITEMS.Overview, SUB_NAV_ITEMS.mRNA);
     } else {
       Dataset dataset =
           phenotype.getDatasetFromName(
               Dataset.TYPE.valueOf(currentPlace.getParameter("dataset", "")));
       String env = currentPlace.getParameter("env", "");
       if (env.equals("GxE")) {
         gxeDetailPresenter.setData(phenotype, dataset);
         setInSlot(TYPE_SetMainContent, gxeDetailPresenter);
       } else {
         phenotypeDetailPresenter.setData(
             phenotype,
             dataset.getEnvironmentFromName(env),
             getSingleHistogramDataTable(env, dataset.getType()));
         setInSlot(TYPE_SetMainContent, phenotypeDetailPresenter);
       }
       getView().setActiveLink(NAV_ITEMS.valueOf(env), SUB_NAV_ITEMS.mRNA);
     }
   }
 }
示例#2
0
  @Override
  public void prepareFromRequest(PlaceRequest request) {

    String dpl = request.getParameter("dpl", null);
    if (dpl != null) {
      this.selectedUnit = new String[] {dpl, request.getParameter("unit", null)};
    } else {
      this.selectedUnit = null;
    }
  }
示例#3
0
  @Override
  public void prepareFromRequest(PlaceRequest request) {
    super.prepareFromRequest(request);
    chart.setParent(this);
    chartType = request.getParameter("chartType", "");
    storeId = request.getParameter("storeId", "");
    storeName = request.getParameter("storeName", "");
    timePeriod = request.getParameter("timePeriod", "");
    year = request.getParameter("year", "");
    month = request.getParameter("month", "");
    day = request.getParameter("day", "");
    category = request.getParameter("category", "");
    cdDvdName = request.getParameter("cdDvdName", "");

    setLabels();

    HashMap<String, String> options = new HashMap<String, String>();
    options.put("branchId", storeId);
    options.put("year", year);
    options.put("month", month);
    options.put("day", day);
    options.put("category", category);
    options.put("cdDvdName", cdDvdName);
    setData(options);
  }
 /**
  * @function onhideBtnClicked
  * @created_date : 11-Dec-2013
  * @description
  * @parm(s) : @param clickEvent
  * @return : void
  * @throws : <Mentioned if any exceptions>
  */
 @UiHandler("hideButton")
 public void onhideBtnClicked(ClickEvent clickEvent) {
   PlaceRequest collectionRequest = AppClientFactory.getPlaceManager().getCurrentPlaceRequest();
   String collectionId = collectionRequest.getParameter("id", null);
   String collectionItemId = collectionRequest.getParameter("rid", null);
   String chkViewParam = collectionRequest.getParameter("view", null);
   if (AppClientFactory.getCurrentPlaceToken().contains(PlaceTokens.RESOURCE_PLAY)) {
     PlaceRequest request = new PlaceRequest(PlaceTokens.RESOURCE_PLAY).with("id", collectionId);
     AppClientFactory.getPlaceManager().revealPlace(false, request, true);
   } else if (AppClientFactory.getCurrentPlaceToken().contains(PlaceTokens.COLLECTION_PLAY)
       && chkViewParam == null
       && collectionItemId != null) {
     PlaceRequest request =
         new PlaceRequest(PlaceTokens.COLLECTION_PLAY)
             .with("id", collectionId)
             .with("rid", collectionItemId);
     AppClientFactory.getPlaceManager().revealPlace(false, request, true);
   } else if (AppClientFactory.getCurrentPlaceToken().contains(PlaceTokens.PREVIEW_PLAY)
       && chkViewParam == null
       && collectionItemId != null) {
     PlaceRequest request =
         new PlaceRequest(PlaceTokens.PREVIEW_PLAY)
             .with("id", collectionId)
             .with("rid", collectionItemId);
     AppClientFactory.getPlaceManager().revealPlace(false, request, true);
   } else if (AppClientFactory.getCurrentPlaceToken().contains(PlaceTokens.COLLECTION_PLAY)
       && chkViewParam == null
       && collectionItemId == null) {
     PlaceRequest request = new PlaceRequest(PlaceTokens.COLLECTION_PLAY).with("id", collectionId);
     AppClientFactory.getPlaceManager().revealPlace(false, request, true);
   } else if (AppClientFactory.getCurrentPlaceToken().contains(PlaceTokens.PREVIEW_PLAY)
       && chkViewParam == null
       && collectionItemId == null) {
     PlaceRequest request = new PlaceRequest(PlaceTokens.PREVIEW_PLAY).with("id", collectionId);
     AppClientFactory.getPlaceManager().revealPlace(false, request, true);
   } else if (AppClientFactory.getCurrentPlaceToken().contains(PlaceTokens.COLLECTION_PLAY)
       && chkViewParam.equalsIgnoreCase("end")) {
     PlaceRequest request =
         new PlaceRequest(PlaceTokens.COLLECTION_PLAY)
             .with("id", collectionId)
             .with("view", "end");
     AppClientFactory.getPlaceManager().revealPlace(false, request, true);
   } else if (AppClientFactory.getCurrentPlaceToken().contains(PlaceTokens.PREVIEW_PLAY)
       && chkViewParam.equalsIgnoreCase("end")) {
     PlaceRequest request =
         new PlaceRequest(PlaceTokens.PREVIEW_PLAY).with("id", collectionId).with("view", "end");
     AppClientFactory.getPlaceManager().revealPlace(false, request, true);
   }
 }
  @Override
  public void prepareFromRequest(PlaceRequest request) {
    super.prepareFromRequest(request);
    PlaceRequest currentPlace = placeManager.getCurrentPlaceRequest();
    String phenotype_id = currentPlace.getParameter("id", "");
    if (phenotype_id.equals("")) getProxy().manualReveal(PhenotypePresenter.this);
    else {
      dispatch.execute(
          new GetPhenotypeDataAction(phenotype_id, phenotypeReader),
          new CustomCallback<GetPhenotypeDataActionResult>(getEventBus()) {

            @Override
            public void onSuccess(GetPhenotypeDataActionResult result) {
              PhenotypePresenter.this.phenotype = result.getPhenotype();
              PhenotypePresenter.this.mRNAHistogramDataTable = result.getmRNAHistogramDataTable();
              PhenotypePresenter.this.bsHistogramDataTable = result.getBsHistogramDataTable();
              getProxy().manualReveal(PhenotypePresenter.this);
            }

            @Override
            public void onFailure(Throwable caught) {
              getProxy().manualReveal(PhenotypePresenter.this);
              super.onFailure(caught);
              // getProxy().manualRevealFailed();
            }
          });
    }
  }
  @Override
  public void prepareFromRequest(PlaceRequest request) {

    String action = request.getParameter("action", null);

    if ("new".equals(action)) {
      launchNewConfigDialoge();
    }
  }
  @Override
  public void prepareFromRequest(PlaceRequest request) {
    String taskIdStr = request.getParameter("taskId", "0l");

    //		long taskId = new Long(taskIdStr);
    //		dispatcher.execute(new GetTask(AppContext.getUserId(), taskId), new
    // TaskServiceCallback<GetTaskResult>() {
    //			@Override
    //			public void processResult(GetTaskResult result) {
    //				setTask(result.getTask());
    //			}
    //		});

  }
示例#8
0
 */ @Override
 public void setBackToSearch() {
   boolean visible = false;
   searchRequest = AppClientFactory.getPlaceManager().getPreviousRequest();
   if (searchRequest != null) {
     String query = searchRequest.getParameter("query", null);
     visible = searchRequest != null && query != null;
     backToSearchFloPanel.getElement().getStyle().setDisplay(Display.BLOCK);
     if (visible) {
       if (query.length() > 50) {
         query = query.substring(0, 50) + "...";
         backToSearchHtml.setHTML(PRE_SEARCH_LINK + query + "\"");
       } else {
         backToSearchHtml.setHTML(PRE_SEARCH_LINK + query + "\"");
       }
     }
   }
   backToSearchPreHtml.setVisible(visible);
   backToSearchHtml.setVisible(visible);
 }
 @Override
 public void prepareFromRequest(final PlaceRequest request) {
   super.prepareFromRequest(request);
   fake = Boolean.valueOf(request.getParameter("fake", "false"));
   hostIndex = Integer.parseInt(request.getParameter("hostIndex", "0"));
 }