Frontend vs backend expressions
Forms, data, security. A free Flowable lesson in simple English (2:17 minutes).
Open in the academy (practice, progress and notes)
Chapters
- 0:00 What you will learn
- 0:16 The two kinds
- 0:38 Examples
- 0:56 Temporary form data
- 1:11 Practice question 1
- 1:31 Practice question 2
- 1:56 Summary
Lesson text
0:00 What you will learn
Welcome to lesson twenty-three. Flowable uses two kinds of expressions. They look similar, so the exam likes to test the difference. An expression is a small formula that gives a value. This is an independent course. It is not made or approved by Flowable.
0:16 The two kinds
Let's compare them side by side. Frontend expressions are used in forms. They are written between double curly brackets. They work with the data in the form. Backend expressions run on the server, in processes and cases. They start with a dollar sign, and use single curly brackets. So, double curly brackets for the frontend. Dollar sign for the backend.
0:38 Examples
In a form, an expression in double curly brackets can show the customer's first name. On a sequence flow, a backend condition can check if the amount is more than one thousand. Both kinds can use the scope words. Flowable's documentation shows a backend example that uses parent, to read the business status.
0:56 Temporary form data
Forms also have a temporary scope. It starts with a dollar sign and the word temp. For example, a checkbox that only makes a form editable. Values in this temporary scope are not saved when the form is sent to the backend.
1:11 Practice question 1
Question one. Which one is a valid backend expression? Look at the board, and choose A, B, C, or D.
The answer is B. Backend expressions start with a dollar sign, and can use the word parent.
1:31 Practice question 2
Question two. A form stores a value in its temporary scope. Is it saved when the form is submitted? A, yes. B, no. C, only on Mondays. Or D, only for admins.
The answer is B, no. Values in the temporary scope are not saved.
1:56 Summary
Let's review. Frontend expressions use double curly brackets, in forms. Backend expressions use a dollar sign, on the server. Both can use scopes like parent and root. Temporary values in forms are not saved. In the next lesson, we will learn about identity links. Thank you for learning with us.
Practice questions
Which one is a valid BACKEND expression?
Answer: ${parent.customerEmail}. Backend expressions start with a dollar sign, and can use the word parent.
A form stores a value in $temp. Is it saved when the form is submitted?
Answer: No. Values in the temporary scope are not saved.