Difference between revisions of "How Calculated Custom Fields Work"
From SmartWiki
(→Special - Browser Script) |
|||
(One intermediate revision by the same user not shown) | |||
Line 12: | Line 12: | ||
* Generally, this field type is used to specify validation routines. | * Generally, this field type is used to specify validation routines. | ||
* Functions defined in these scripts can be referenced in other calculated [[Custom Field|custom field]]. | * Functions defined in these scripts can be referenced in other calculated [[Custom Field|custom field]]. | ||
− | * You can control when the script is executed by using any valid '''JavaScript''' event triggers. You could force the script execution on '''page load''' (onLoad) or '''Save''' (OnSubmit). | + | * You can control when the script is executed by using any valid '''JavaScript''' event triggers. You could force the script execution on '''page load''' ([[onloadfunc|onLoad]]) or '''Save''' (OnSubmit). |
− | ==[[Template / Type Formula | + | ==[[Template / Type Formula|Template Level Formulas]]== |
* Template level formulas can be associated with [[UTA]] {{l1}} and {{l2}} [[Template|templates]] plus [[Sales Tracking]]. | * Template level formulas can be associated with [[UTA]] {{l1}} and {{l2}} [[Template|templates]] plus [[Sales Tracking]]. |
Latest revision as of 09:17, 19 November 2013
Contents
Special - Calculated Value
- Expressions entered into this field type are evaluated as JavaScript functions.
- These functions are added to associated page and executed in the client browser.
- You can enter any valid JavaScript construct into these expressions.
- The major limitation of this expression type is that it can only use values that are within the current page.
- The expression cannot be used to manipulate values stored on other tabs or aggregate data from related entities.
Special - Browser Script
- If you need to add a JavaScript to a page that does not manifest on the page then you can use the Special - Browser Script field type.
- Generally, this field type is used to specify validation routines.
- Functions defined in these scripts can be referenced in other calculated custom field.
- You can control when the script is executed by using any valid JavaScript event triggers. You could force the script execution on page load (onLoad) or Save (OnSubmit).
Template Level Formulas
- Template level formulas can be associated with UTA Level 1 and Level 2 templates plus Sales Tracking.
- Template level formulas are not JavaScript functions and are not executed in the client browser.
- These formulas are executed in the database server and are constructed using valid SQL syntax.
- The benefit of this approach is that you can aggregate data across entities and update information across other entities.