Skip to content

Configuration

You can either configure actions in Lime admin in the view config for a limetype.

Or you can trigger the commands in your custom flow.

Add Action in View config

Go to Lime admin => Views => <Any limetype>.

Decide if you want a Promoted or Unpromoted action and click the add button you decide.

Add the command you want:

Snackbar parameters

In all of the below commands you can add the snackbar parameters

Open create new

Command id: limepkg_standard_actions.open-create-new

Parameters:

Name Required Type Default value Descriptive
limeType X string, LimeType - What limetype to create
limeObject Record<string, ValueConfig> {} What value to set in each field (ValueConfig)

Update lime object

Command id: limepkg_standard_actions.update-limeobject

Parameters:

Name Required Type Default value Descriptive
limeObject X Record<string, ValueConfig> - What value to set in each field (ValueConfig)

Open form

Command id: limepkg_standard_actions.open-form

Parameters:

Name Required Type Default value Descriptive
properties X Record<string, FieldConfig> - What value to set in each field (FieldConfig)
limeObject Record<string, ValueConfig> - What values to set on each field but isn't shown in the form (ValueConfig)
dialog FormDialogSettings - Settings for the dialog visualization (FormDialogSettings)

Field Config

Name Required Type Default value Descriptive
value ValueConfig - Override the existing value of the field (ValueConfig)
options FieldPropertySettings - Override the card view settings for the property (FieldPropertySettings)

Field Property Settings

You can override all properties on the šŸŒLimeSchemaOptions from Lime Elements

This is some extra settings that can be overridden.

Name Required Type Default value Descriptive
required boolean - Override required
readOnly boolean - Override read-only

Form Dialog Settings

Name Required Type Default value Descriptive
heading FormDialogHeading - Heading settings for the dialog (FormDialogHeading)
size FormDialogSize x-small Size of the dialog (FormDialogSize)
autoHeight boolean true If the height should be increased based on the field sizes, instead of a fixed height
closingActions closingActions {"escapeKey": true, "scrimClick": false} šŸŒClosingActions from Lime Elements

Form Dialog Heading

You can override all properties on the šŸŒDialogHeading from Lime Elements

This is some extra settings that can be overridden.

Name Required Type Default value Descriptive
color string Limetype color Color of heading

Form Dialog Size

Available sizes:

Name Descriptive
x-small Single column view
small Two column view
medium 5 column view
large Bigger 5 column view
fullscreen 5 column view in full screen

Create new

Command id: limepkg_standard_actions.create-new

Parameters:

Name Required Type Default value Descriptive
limeType X string, LimeType - What limetype to create
limeObject Record<string, ValueConfig> {} What value to set in each field (ValueConfig)
autoAttachRelation string Takes first relation that matches LimeType to create What relation tab on the current object to use for relating the created object

Command id: limepkg_standard_actions.open-link

Parameters:

Name Required Type Default value Descriptive
link X ValueConfig - What value to set in each field (ValueConfig)
openInNewTab boolean true If the tab should open in a new tab by default
type LinkType url What type of link it is (LinkType)
Name Descriptive
url A URL link (Adds https:// if it's missing)
email An email link (Adds mailto: if it's missing)
phone A phone number link (Adds tel: if it's missing)
custom A custom link (Doesn't add anything)

Common config

Value config

Must set either constant OR formula

Name Type Default value Descriptive
constant unknown - Hard coded output value
formula string - A formula that will be rendered. Read more about it here
expectedOutputType OutputType auto What type data type the output should be casted to (OutputType)

Snackbar parameters

Name Required Type Default value Descriptive
notificationMessage X string - What message the user should see, can be a translation key
notificationOptions NotificationOptions {} Settings for the notifications Read more here

Output type

Name Descriptive
auto If property given, cast based on property type. Otherwise tries to guess the type based on the output value
int Cast to int defaults to null
float Cast to float defaults to null
str Return raw result as string
datetime Cast to datetime if possible
list Cast to a list if possible