Exemplo n.º 1
0
 @Override
 public void addListArticlePfListBox(
     List<ArticlePf> articlePfList, boolean isStock, boolean isResp) {
   if (isResp) {
     addArticleGroupValue(MESSAGES.fournisseur_resp_produit(), articlePfList);
   } else {
     if (isStock) {
       if (!isOutStockArticlePfListFill) {
         stockArticlePfList.addAll(articlePfList);
         isStockArticlePfListFill = true;
       } else {
         addArticleGroupValue(MESSAGES.stock_stock(), articlePfList);
         addArticleGroupValue(MESSAGES.stock_horsstock(), outStockArticlePfList);
         clearArticleLists();
       }
     } else {
       if (!isStockArticlePfListFill) {
         outStockArticlePfList.addAll(articlePfList);
         isOutStockArticlePfListFill = true;
       } else {
         addArticleGroupValue(MESSAGES.stock_stock(), stockArticlePfList);
         addArticleGroupValue(MESSAGES.stock_horsstock(), articlePfList);
         clearArticleLists();
       }
     }
   }
   articlePfValueListBox.setIndex(0);
   if (!articlePfList.isEmpty()) {
     lastArticleChoice = articlePfList.get(0);
     presenter.setParamSessionArticlePf(articlePfList.get(0));
   }
 }
Exemplo n.º 2
0
  @Override
  public void addListPlatformListBox(
      List<Platform> platformList, boolean isPlatformView, boolean isStock) {
    platformValueListBox.setVisible(true);
    if (isPlatformView) {
      addPlatformGroupValue(MESSAGES.group_element_platform(), platformList);

    } else {
      if (isStock) {
        if (!isOutStockPlatformListFill) {
          stockPlatformList.addAll(platformList);
          isStockPlatformListFill = true;
        } else {
          addPlatformGroupValue(MESSAGES.stock_stock(), platformList);
          addPlatformGroupValue(MESSAGES.stock_horsstock(), outStockPlatformList);
          clearPlatformLists();
        }
      } else {
        if (!isStockPlatformListFill) {
          outStockPlatformList.addAll(platformList);
          isOutStockPlatformListFill = true;
        } else {
          addPlatformGroupValue(MESSAGES.stock_stock(), stockPlatformList);
          addPlatformGroupValue(MESSAGES.stock_horsstock(), platformList);
          clearPlatformLists();
        }
      }
    }
    platformValueListBox.setIndex(0);
    if (!platformList.isEmpty()) {
      lastPlatformChoice = platformList.get(0);
    }
  }
Exemplo n.º 3
0
 @Override
 public void backValuePlatform() {
   int index = platformValueListBox.getIndex();
   int size = platformValueListBox.getListSize();
   platformValueListBox.setFocus(false);
   if (index - 1 > 0) {
     platformValueListBox.setIndex(index - 1);
     arrowStatus(index - 1, size);
     Platform platform = platformValueListBox.getValue();
     presenter.getEventBus().searchForArticlePf(platform, false);
     lastPlatformChoice = platform;
   }
 }
Exemplo n.º 4
0
 @Override
 public void backValueArticle() {
   int index = articlePfValueListBox.getIndex();
   int size = articlePfValueListBox.getListSize();
   articlePfValueListBox.setFocus(false);
   if (index - 1 > 0) {
     articlePfValueListBox.setIndex(index - 1);
     arrowStatus(index - 1, size);
     ArticlePf article = articlePfValueListBox.getValue();
     presenter.getEventBus().searchForStock(article, false);
     lastArticleChoice = article;
     presenter.setParamSessionArticlePf(article);
   }
 }