Class PetsPageBuilders

java.lang.Object
org.apache.juneau.petstore.console.pages.PetsPageBuilders

public final class PetsPageBuilders extends Object
Builder twins of the Pets pages: P2 Pets (pets.ftlh), its ?mixed variant, P3 Sold (pets-sold.ftlh) and P4 one pet (pet.ftlh).
Example:

return twin(req, PetsPageBuilders.pets());

  • Method Details

    • pets

      public static PageSpec pets()
      P2 Pets.
      Returns:
      The page spec.
    • petsMixed

      public static PageSpec petsMixed()
      P2 Pets, half FTL: pets-mixed.ftlh lays out the page and places this spec's table with <@card ref="pets"/>.
      Returns:
      The page spec.
    • sold

      public static PageSpec sold()
      P3 Sold.
      Returns:
      The page spec.
    • pet

      public static PageSpec pet(Pet pet, String tab, String activeNav, Order order, List<String> roles, String apiCsrf)
      P4 one pet, on one tab.
      Parameters:
      pet - The pet.
      tab - The tab: summary, photo, orders or history.
      activeNav - The active nav path, pets/p<id>/<tab> or pets/p<id>/orders/o<orderId>.
      order - The selected order on the orders tab, or null.
      roles - The viewer's roles.
      apiCsrf - The API's CSRF token for the photo upload form, or null to render the form without one.
      Returns:
      The page spec.