Articles on: Process Form
This article is also available in:

Table type field

You can now create tables in your process form. We added a table field type to group information into rows and columns, providing the ability to create custom spreadsheets in your process form.

In order to create a table field type, select the data type “Table” and click on the link that appears below to configure it.

You can define how many columns you want to include, the heading and the type of data it will contain.

By default, tables will be displayed horizontally but you can choose to display them vertically.



In the table columns will be displayed from left to right following the same order in which you added them. When setting the columns of the table you can drag and drop them to rearrange the order.

It is also possible to define a maximum of rows. If that field is left empty, the number of rows allowed will be unlimited.

As with other types of data, tables must include a name and may include a description. They also need to include at least one column in order to create them.



Once you defined the table field, you can define the visibility of the table for each task. If the table is editable or required, you can even define the visibility for each of its columns as follows:



Once inside the visibility settings for the table, you will be able to choose each column as: Editable, Read Only or Required.



Once the table field is configured and the process deployed, you’ll see it in the process instance. For example, the table set up in the previous image will look like this:



When the table visibility is set to ‘Editable’, users can complete table cells and add or delete as many rows as they want (always bearing in mind the maximum number of rows allowed). This means that users can modify the content and rows of the table, but not the columns. Columns can only be modified when setting up the table.

To insert new rows, click on the ‘Add Record’ button. To delete rows, click on the bin icon.

Add images to a table



To add images to a table type field, simply edit the table and add the column where you want to add images. Then select the "Image (url)" data type and you are ready to add images.

Keep in mind that you must insert the URL of the images in the table in order for them to appear visible.

If you already have images stored in Google Drive, you may select the URL of each image manually and insert them in the table. If you want to automate this process, you can save the URL of each image in a Flokzu database and then set up a trigger in such a way that, when you select certain item, the URL of the image be retrieved and uploaded automatically to the corresponding column in your table.

Import table values (.csv)



You may also import values to a table by using the '.csv' format. Example: You have an Excel spreadsheet with several columns and each of them has many values. If you export the spreadsheet in '.csv' format, you can then import it to a Flokzu table, automatically uploading all the values from your spreadsheet.



Keep in mind that to be able to import values, the columns of the original file must have the same name that the table columns, the first row of the original file corresponding to the names of the columns.

Defining formulas within a table



You can define formulas within columns of a table. This allows you to automatically calculate values based on other columns of the table.

Example: If you register the purchase of products with a table, we will have a column indicating the quantity to be purchased and the price of each product. Then you can add another column that automatically calculates the total price by multiplying the price and quantity.

To set a formula follow these steps:



To reference columns, indicate the name using the mustache format (enclosed in {{ }}).

You can enter any mathematical expression. See useful examples below:



This functionality can be combined with others to make your forms even more powerful. For example, you can define a calculated field after the table which sums the “Total” column to automatically obtain the total amount of the purchase.

Change the size of the columns



In case you want to modify the size of the columns of a table, you must use the following script.

The sum of all the values must = 100. In this case, our table has 5 columns, and that’s why we have 5 sizes.

function resize(){
   Flokzu.resizeTable( [[Table Name]] , [ 60, 10, 10, 10, 10 ] );
}

Flokzu.onInit(resize);


This script must be located in the tab Scripts, inside Visibility settings and Scripts.

In case you want to maintain the size in every task, you must locate it in -Master script-

Updated on: 26/04/2019

Was this article helpful?

Share your feedback

Cancel

Thank you!