Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  • To reuse the predefined template, just override the theme method and set your custom HTML to the available variable of the template.
  • Example: To reuse the header.ftl template in getHeader method.
Code Block
languagejava
    @Override
    public String getHeader(Map<String, Object> data) {
        data.put("header_classes", "navbar");
        data.put("header_inner_before", "<div class=\"navbar-inner\"><div class=\"container-fluid\">");
        data.put("header_inner_after", "</div></div>");
        data.put("header_info_after", "<a id=\"mobile_menu\" class=\"btn btn-navbar\"><span class=\"icon-bar\"></span><span class=\"icon-bar\"></span><span class=\"icon-bar\"></span></a>");
        data.put("header_link_classes", "brand");
        data.put("header_info_classes", "inline-block");
        data.put("header_name_classes", "inline-block");
        data.put("header_description_classes", "inline-block visible-desktop");
        data.put("header_description_span_classes", "brand");
        return super.getHeader(data);
    }

...

  • To override or replace the predefined template, you just need to create your own template using FreeMaker syntax.
  • Example: Using a custom template file in getHeader method.
Code Block
languagejava
    @Override
    public String getHeader(Map<String, Object> data) {
        return UserviewUtil.getTemplate(this, data, "/templates/userview/customHeader.ftl");
    }

...

Tutorials

Related Community Plugins

  • Corporati Theme
    org.joget.plugin.enterprise.CorporatiTheme (wflow-core)
  • V3 Default Theme
    org.joget.apps.userview.lib.DefaultTheme (wflow-core)Not available right now