Getting list from back end to Ui | Community
Skip to main content
Ricky99999
Level 4
Sep 11, 2019 12:57 PM UTC
Solved

Getting list from back end to Ui

Hi Team,

I am  getting a list from back end, and reading in sightly and displaying on the page.

1. List1

2. List2

3. List3

4. List5

But now I want to insert a value before the last one  like below

1. List1

2. List2

3. List3

4. Value1

5.List5

I am not able to break the list can anyone help me in this.

Thanks in advance

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
antoniom5495929
antoniom5495929Accepted solution
Level 7
Sep 11, 2019 1:25 PM UTC

Hi,

if you want to manipulate the order of values you need to use Sling Model.

Sightly was introduced in order to ensure a develop MVC compliant, so if you need to manipulate data you need to move your logic into a Sling Model and then render your list in sightly.

Please find here some references:

Adobe Experience Manager Help | Working with Sling Models in Adobe Experience Manager

Adobe Experience Manager Help | Creating Adobe Experience Manager 6.3 Sling Model Components

Apache Sling :: Sling Models

Thanks,

Antonio

3 replies

antoniom5495929
Level 7
Sep 11, 2019 1:49 PM UTC

Hi,

you can't manipulate data directly in Sightly. Only testing and listing statement are available: HTL Block Statements​

Thanks,

Antonio

Translate
Ricky99999
Level 4
Sep 11, 2019 1:43 PM UTC

Can we manuplate the data with sightly..

Translate
antoniom5495929
antoniom5495929Accepted solution
Level 7
Sep 11, 2019 1:25 PM UTC

Hi,

if you want to manipulate the order of values you need to use Sling Model.

Sightly was introduced in order to ensure a develop MVC compliant, so if you need to manipulate data you need to move your logic into a Sling Model and then render your list in sightly.

Please find here some references:

Adobe Experience Manager Help | Working with Sling Models in Adobe Experience Manager

Adobe Experience Manager Help | Creating Adobe Experience Manager 6.3 Sling Model Components

Apache Sling :: Sling Models

Thanks,

Antonio

Translate