Package org.dmrad.view.context

Examples of org.dmrad.view.context.ViewContext


          "neighborEmptyNameLabelListViewHead", childNeighborNames));

      ModelContext entityDisplayTableListModelContext = new ModelContext(
          modelContext);

      ViewContext entityDisplayTableListViewContext = new ViewContext(
          viewContext);
      entityDisplayTableListViewContext
          .setWicketId("entityDisplayTableListView");

      PageableListView entityDisplayTableListView = app.getViewMeta()
          .getPageableListView("EntityDisplayTableListView",
              entityDisplayTableListModelContext,
View Full Code Here


      Label entryConceptName = new Label("entryName", conceptName);
      item.add(entryConceptName);

      ModelContext entryContext = new ModelContext(modelContext);
      entryContext.setEntities(entry);
      ViewContext entityUpdateTablePageContext = new ViewContext(
          viewContext);
      WebPage entryConceptPage = app.getViewMeta().getPage(
          "EntityUpdateTablePage", entryContext,
          entityUpdateTablePageContext);
      Link entryConceptLink = new PageLink("entryUpdateTable",
View Full Code Here

            IEntity afterUpdateEntity = entityEditFormPageModelContext
                .getUpdateEntity();
            if (afterUpdateEntity != null) {
              afterUpdateEntity.setProperty(baseEntityPropertyConfig
                  .getCode(), null);
              ViewContext entityEditFormPageViewContext = new ViewContext(
                  viewContext);
              if (modelContext.getAction().equals("update")) {
                setResponsePage(app.getViewMeta().getPage(
                    "EntityEditFormPage",
                    entityEditFormPageModelContext,
View Full Code Here

        entities.getErrors().empty();
        if (entities.update(entity, updateEntity)) {
          ModelContext entityUpdateTablePageModelContext = new ModelContext(
              modelContext);
          entityUpdateTablePageModelContext.setUpdateEntity(null);
          ViewContext entityUpdateTablePageViewContext = new ViewContext(
              viewContext);
          setResponsePage(app.getViewMeta().getPage(
              "EntityUpdateTablePage",
              entityUpdateTablePageModelContext,
              entityUpdateTablePageViewContext));
View Full Code Here

      ConceptConfig conceptConfig = entity.getConceptConfig();
      ModelContext slideNavigateModelContext = new ModelContext(
          modelContext);

      ViewContext slideNavigateViewContext = new ViewContext(viewContext);
      slideNavigateViewContext.setWicketId("slideNavigatePanel");
      Panel entitySlideNavigatePanel = new EntitySlideNavigatePanel(
          slideNavigateModelContext, slideNavigateViewContext);
      add(entitySlideNavigatePanel);
      if (!app.isConceptDisplayAllowed(getAppSession(), conceptConfig)) {
        entitySlideNavigatePanel.setVisible(false);
      }

      List<Panel> neighborList = new ArrayList<Panel>();
      NeighborsConfig neighborsConfig = conceptConfig
          .getNeighborsConfig();
      for (IEntity neighborConfigEntity : neighborsConfig) {
        NeighborConfig neighborConfig = (NeighborConfig) neighborConfigEntity;
        if (neighborConfig.getType().equals("child")) {
          String neighborCode = neighborConfig.getCode();
          IDomainModel domainModel = app.getDomainModel();
          IOrderedEntities childEntities = (IOrderedEntities) domainModel
              .getModelMeta().getNeighborEntities(entity,
                  neighborCode);

          ModelContext neighborModelContext = new ModelContext(
              modelContext);
          neighborModelContext.setContextEntities(entities);
          neighborModelContext.setContextEntity(entity);
          neighborModelContext.setEntities(childEntities);

          ViewContext neighborViewContext = new ViewContext(
              viewContext);
          neighborViewContext.setWicketId("entityDisplayListPanel");

          Panel entityDisplayListPanel = app.getViewMeta().getPanel(
              "EntityDisplayListPanel", neighborModelContext,
              neighborViewContext);
          neighborList.add(entityDisplayListPanel);
View Full Code Here

      ModelContext entityUpdateTablePanelModelContext = new ModelContext(
          modelContext);
      entityUpdateTablePanelModelContext.setAction(null);

      ViewContext entityUpdateTablePanelViewContext = new ViewContext(
          viewContext);
      entityUpdateTablePanelViewContext.setContextPage(this);
      entityUpdateTablePanelViewContext.setPage(this);
      entityUpdateTablePanelViewContext.setUpdate(true);
      entityUpdateTablePanelViewContext
          .setWicketId("entityUpdateTablePanel");

      add(app.getViewMeta().getPanel("EntityUpdateTablePanel",
          entityUpdateTablePanelModelContext,
          entityUpdateTablePanelViewContext));
View Full Code Here

    super(modelContext, viewContext);
    try {
      ModelContext entryDisplayTablePanelModelContext = new ModelContext(
          modelContext);

      ViewContext entryDisplayTablePanelViewContext = new ViewContext(
          viewContext);
      entryDisplayTablePanelViewContext
          .setWicketId("entryDisplayTablePanel");
      viewContext.setContextPage(this);
      viewContext.setPage(this);

      add(new EntryDisplayTablePanel(entryDisplayTablePanelModelContext,
View Full Code Here

  public PropertyListPanel(final ModelContext modelContext,
      final ViewContext viewContext) {
    super(modelContext, viewContext);
    try {
      ModelContext propertiesModelContext = new ModelContext(modelContext);
      ViewContext propertiesViewContext = new ViewContext(viewContext);
      propertiesViewContext.setWicketId("propertyList");
      PropertyList propertyList = new PropertyList(
          propertiesModelContext, propertiesViewContext);
      add(propertyList);
    } catch (Exception e) {
      log.error("Error in PropertyListPanel: " + e.getMessage());
View Full Code Here

    super(modelContext, viewContext);
    try {
      ModelContext conceptsModelContext = new ModelContext(modelContext);
      IEntities concepts = conceptsModelContext.getEntities();
      if (concepts != null) {
        ViewContext conceptsViewContext = new ViewContext(viewContext);
        conceptsViewContext.setWicketId("conceptList");
        ConceptList conceptList = new ConceptList(conceptsModelContext,
            conceptsViewContext);
        add(conceptList);
      }
    } catch (Exception e) {
View Full Code Here

      item.add(conceptNameLabel);

      ModelContext propertiesModelContext = new ModelContext(modelContext);
      Properties properties = concept.getProperties();
      propertiesModelContext.setEntities(properties);
      ViewContext propertiesViewContext = new ViewContext(viewContext);
      propertiesViewContext.setWicketId("propertyListPanel");
      PropertyListPanel propertyListPanel = new PropertyListPanel(
          propertiesModelContext, propertiesViewContext);
      item.add(propertyListPanel);

      ModelContext neighborsModelContext = new ModelContext(modelContext);
      Neighbors neighbors = concept.getNeighbors();
      neighborsModelContext.setEntities(neighbors);
      ViewContext neighborsViewContext = new ViewContext(viewContext);
      neighborsViewContext.setWicketId("neighborListPanel");
      NeighborListPanel neighborListPanel = new NeighborListPanel(
          neighborsModelContext, neighborsViewContext);
      item.add(neighborListPanel);
    } catch (Exception e) {
      log.error("Error in ConceptList: " + e.getMessage());
View Full Code Here

TOP

Related Classes of org.dmrad.view.context.ViewContext

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.