repeatSlide
A child command of composePPTXContent that iterates over a Collection and produces as many copies of a specific slide of the parent command's presentation as there are items in the Collection. The specified slide and each of the produced slide copies undergo content command evaluation with one of the Collection's items available in the variable context. The produced slide copies are placed after the slide they're copies of.
Parent commands
composePPTXContent
Required. Defines the presentation that this command modifies.
Attributes
value | ||
---|---|---|
Required | Value type | EL-evaluated |
Yes | Collection, Map, Data Item | Yes |
This attribute defines the container whose contents the command will iterate through. While this container is primarily expected to be a Collection, two other types of values are also accepted. The three types are handled in the following ways:
|
var | ||
---|---|---|
Required | Value type | EL-evaluated |
Yes | String | No |
The value of this attribute defines the name of the local context variable that holds the current item of the loop. |
varStatus | ||
---|---|---|
Required | Value type | EL-evaluated |
No | String | No |
Defines the name of the variable that holds a Loop Status value. Loop Status has the properties Property |
roundTest | ||
---|---|---|
Required | Value type | EL-evaluated |
No | Boolean | Yes |
This attribute can be used to define a condition for skipping certain iteration rounds. This attribute's expression is evaluated at the start of every round and if it doesn't resolve into If undefined, no iteration rounds are skipped. |
slide | ||
---|---|---|
Required | Value type | EL-evaluated |
Yes | Number, String | Yes |
Defines the number of the slide to produce copies of, with 1 being the number of the first slide. The resolved value is expected to be a Number, or a number-like String. Note that this slide number is interpreted in the context of the presentation's original structure before any commands have altered it. If, for example, the slide that was originally number 2 has moved to become number 7 due to other commands placing more slides into the presentation, the value of '2' will refer to that slide despite its current number. If the resolved numerical value is less than 1, or higher than the amount of slides originally in the presentation, an error is produced. |
Examples
The repeatSlide
command can be used to build a sequence of slides based on the data of a Collection. It could, for example, be used to construct slides presenting results of a Salesforce query retrieving data of products.
<composePPTXContent var="productShow" value="${productTemplate}"><repeatSlide value="${productData}" var="product" slide="2">
In this case, slide number 2 of the template should contain content commands and inline EL expressions making use of the "product" variable.