Package wicket.markup.html.form

Examples of wicket.markup.html.form.Form


      }

      this.listeClubsLine.add(new ClubLine(club.getNomComplet(), etat, club));
    }

    final Form form = new Form("clubForm")
    {

      /**
       *
       */
      private static final long serialVersionUID = 3163017677464598472L;

      /*
       * (non-Javadoc)
       *
       * @see wicket.markup.html.form.Form#onSubmit()
       */
      @Override
      protected void onSubmit()
      {
        AffiliationsClubs affClubs = ListClubsPanel.this.affClubs;
       
        for (ClubLine line : ListClubsPanel.this.listeClubsLine)
        {
          //Si on veut ajouter le club a a saison
          if (line.getEtat())
          {
            try
            {
              affClubs.createAffiliationClub(ListClubsPanel.this.saison, line.getClub());
              super.error(String.valueOf(affClubs.size())+"Ajouté..."+line.getNomComplet());
            }
            catch (ActionException e)
            {
              throw new SystemeException(e);
            }
          }
          //Si on veut supprimer le club de la saison.
          else       
          {
            try
            {
              affClubs.RemoveAffiliationClub(ListClubsPanel.this.saison, line.getClub());
            }
            catch (ActionException e)
            {
              throw new SystemeException(e);
            }
          }
        }
        super.onSubmit();
      }

    };

    form.add(new ListClubsListView("ListeClubs", this.listeClubsLine));
    Map<Parameters, Object> params = new HashMap<Parameters, Object>();
    params = new HashMap<Parameters, Object>();
    params.put(Parameters.SELECTED_ITEM, this.saison);
    params.put(Parameters.IS_NEW, false);

    form.add(HomePage.link("retour", GestionEvenementsPanel.class, params));
    form.add(new FeedbackPanel("feedback"));
    this.add(form);
  }
View Full Code Here


   *            view context
   * @return form
   */
  public Form getForm(final String classSimpleName,
      final ModelContext modelContext, final ViewContext viewContext) {
    Form result = null;
    try {
      String actionType;
      if (viewContext.isUpdate()) {
        actionType = "update";
      } else {
View Full Code Here

      String keywords = (String) viewContext.getMoreArgs()
          .get("keywords");
      Boolean andKeywords = (Boolean) viewContext.getMoreArgs().get(
          "andKeywords");
      Form keywordSelectionForm = new KeywordSelectionPanelForm(
          "keywordSelectionForm", title, keywords, andKeywords);
      add(keywordSelectionForm);
      if (!app
          .isPropertyDisplayAllowed(getAppSession(), propertyConfig)) {
        keywordSelectionForm.setVisible(false);
      }
    } catch (Exception e) {
      log.error("Error in EntityPropertyKeywordSelectPanel: "
          + modelContext.getEntitiesCode() + " - " + e.getMessage());
    }
View Full Code Here

TOP

Related Classes of wicket.markup.html.form.Form

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.