Skip to main content

Resources

What's a Resource ?

A Resource is a file linked to a Business object, an External object, a Disposition or a Business Process.

They are a versatile component of the platform and have many use-cases.

Resource types

TypeExample use-case 
ImageImage file that can be used in a publication
Style CSS CSS stylesheet for customizing the UI
Object iconIcon set
JavascriptJavascript file for front-end customization
HTMLUsed for the content of a publication
MarkdownStore a Markdown file
PDF Store a PDF file in the application for use in business process
File setFor an external object, it can be used to store a static web site
FontFont file for customizing the UI
XMLStore an XML file
JSONStore a JSON file
Other Any other file type

How to create Resources ?

For a Business Object, Disposition or Business Process

Go to the object's form and click Create in the Resources tab :

For an External Object

Use the Create Resources action button in the external object's form :

Configuration

FieldDescription
ObjectThe Business Object, External Object, Disposition or Business Process that uses the resource
TypeType of the resource from (types)
LanguageLanguage of the resource ('*' by default, otherwise English or French)
CodeName of the resource
Cached?Tells if the resource is included in the cache or not (No by default)

Using the Java API

The main methods used to access a Resource are :

  • HTMLTool.getResourceHTMLContent(Grant g, String code)
  • HTMLTool.getResourceCSSContent(Grant g, String code)
  • HTMLTool.getResourceJSContent(Grant g, String code)
  • See the Javadoc for more details

Read more