constructor - j5 - 30 - Reference - Hexagon

j5 Framework IndustraForm API Reference

Language
English
Product
j5
Search by Category
Reference
j5 Version
30

constructor(element_data)

Represents an action for updating several elements in an IndustraForm at once.

When this action is performed using FormDataSnapshot.update_form or FormDataSnapshot.get_response_for_update it will raise a Value Error if the values in element_data do not conform to the following:

  • Hierarchy select (dropdown input style): list of strings e.g. ['selection1_level1', 'selection1_level2']

  • Hierarchy select (tree input style): list of lists e.g. [[selection1_level1, selection1_level2], [selection2_level1, selection2_level2]]

  • Asset select: list of logids e.g. ['ID1619183859759726619246']

  • Checklist item: boolean or "NOT_APPLICABLE"

  • DateTime: ISO 8601 timestamp or datetime_tz object

  • Date: '%Y-%m-%d' string or datetime.date object

  • Number: float or string

  • Integer: int or string

  • Checkbox: bool

  • Text, RichText and Choice: string

In the following cases an exception will not be raised; however the element will not be updated:

  • The element is in a repeating section.

  • The element type is not supported (Signature, Attachment, SpfObjects).

  • The element is of type Hierarchy Select or Choice and the provided value is an invalid option.

Parameters

  • element_data - A dictionary with element IDs as keys, providing new values for those elements.