Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
BedrockMission!

Learn More

View all

Sign in to view all badges

cq included or sly included components dialog "selected" property is not respected for select drop down

Avatar

Avatar
Validate 10
Level 4
Var
Level 4

Likes

44 likes

Total Posts

113 posts

Correct Reply

5 solutions
Top badges earned
Validate 10
Validate 1
Boost 5
Boost 3
Boost 25
View profile

Avatar
Validate 10
Level 4
Var
Level 4

Likes

44 likes

Total Posts

113 posts

Correct Reply

5 solutions
Top badges earned
Validate 10
Validate 1
Boost 5
Boost 3
Boost 25
View profile
Var
Level 4

07-01-2019

Steps to reproduce the issue.

  1. Add a drop down to the text component as shown below.

1662355_pastedImage_2.png

     2. add the selected property to one of the drop down list options ( Note :- Other than first option.)

1662362_pastedImage_3.png

  3. Include the Text component into the Title component as shown below. by using the

<div data-sly-resource="${'par' @ resourceType='/apps/core/wcm/components/text/v2/text'}"></div>

1662363_pastedImage_9.png

   4. Open any page http://localhost:4502/editor.html/content/we-retail/language-masters/en/men.html, add both the components (Text and Title Components) to the page as shown below.

1662364_pastedImage_14.png

5. Observe that the Individually added Text component dialog able to respect the "Selected" property but not the sly/cq included Text component

1662366_pastedImage_28.png

1662367_pastedImage_29.png

Observe the Issue : The sly/CQ included component is not able to load the "Selected" property option as the default value

Replies

Avatar

Avatar
Coach
MVP
Arun_Patidar
MVP

Likes

1,356 likes

Total Posts

3,227 posts

Correct Reply

917 solutions
Top badges earned
Coach
Contributor 2
Ignite 10
Give Back 700
Boost 1000
View profile

Avatar
Coach
MVP
Arun_Patidar
MVP

Likes

1,356 likes

Total Posts

3,227 posts

Correct Reply

917 solutions
Top badges earned
Coach
Contributor 2
Ignite 10
Give Back 700
Boost 1000
View profile
Arun_Patidar
MVP

07-01-2019

Hi,

create selected property as String not Boolean.

Avatar

Avatar
Validate 10
Level 4
Var
Level 4

Likes

44 likes

Total Posts

113 posts

Correct Reply

5 solutions
Top badges earned
Validate 10
Validate 1
Boost 5
Boost 3
Boost 25
View profile

Avatar
Validate 10
Level 4
Var
Level 4

Likes

44 likes

Total Posts

113 posts

Correct Reply

5 solutions
Top badges earned
Validate 10
Validate 1
Boost 5
Boost 3
Boost 25
View profile
Var
Level 4

08-01-2019

Even after changing to String property still same issue.

1662964_pastedImage_0.png

1662980_pastedImage_2.png

Avatar

Avatar
Coach
MVP
Arun_Patidar
MVP

Likes

1,356 likes

Total Posts

3,227 posts

Correct Reply

917 solutions
Top badges earned
Coach
Contributor 2
Ignite 10
Give Back 700
Boost 1000
View profile

Avatar
Coach
MVP
Arun_Patidar
MVP

Likes

1,356 likes

Total Posts

3,227 posts

Correct Reply

917 solutions
Top badges earned
Coach
Contributor 2
Ignite 10
Give Back 700
Boost 1000
View profile
Arun_Patidar
MVP

08-01-2019

Hi,

What version are you using?

I tried in AEM 6.3 and working fine.

Screenshot 2019-01-08 at 10.12.21 PM.png

Screenshot 2019-01-08 at 10.12.35 PM.png

However the values won't be render in page until you submit dialog.

Avatar

Avatar
Validate 10
Level 4
Var
Level 4

Likes

44 likes

Total Posts

113 posts

Correct Reply

5 solutions
Top badges earned
Validate 10
Validate 1
Boost 5
Boost 3
Boost 25
View profile

Avatar
Validate 10
Level 4
Var
Level 4

Likes

44 likes

Total Posts

113 posts

Correct Reply

5 solutions
Top badges earned
Validate 10
Validate 1
Boost 5
Boost 3
Boost 25
View profile
Var
Level 4

08-01-2019

It is on AEM 6.4

Avatar

Avatar
Coach
MVP
Arun_Patidar
MVP

Likes

1,356 likes

Total Posts

3,227 posts

Correct Reply

917 solutions
Top badges earned
Coach
Contributor 2
Ignite 10
Give Back 700
Boost 1000
View profile

Avatar
Coach
MVP
Arun_Patidar
MVP

Likes

1,356 likes

Total Posts

3,227 posts

Correct Reply

917 solutions
Top badges earned
Coach
Contributor 2
Ignite 10
Give Back 700
Boost 1000
View profile
Arun_Patidar
MVP

08-01-2019

I tested in AEM 6.4, working fine.

Screenshot 2019-01-08 at 11.51.47 PM.png

chrome-capture (1).gif

Avatar

Avatar
Validate 10
Level 4
Var
Level 4

Likes

44 likes

Total Posts

113 posts

Correct Reply

5 solutions
Top badges earned
Validate 10
Validate 1
Boost 5
Boost 3
Boost 25
View profile

Avatar
Validate 10
Level 4
Var
Level 4

Likes

44 likes

Total Posts

113 posts

Correct Reply

5 solutions
Top badges earned
Validate 10
Validate 1
Boost 5
Boost 3
Boost 25
View profile
Var
Level 4

08-01-2019

Strange, have you included the component by using below sly include .?

<div data-sly-resource="${'par' @ resourceType='/apps/core/wcm/components/text/v2/text'}"></div>

Avatar

Avatar
Validate 25
Level 10
smacdonald2008
Level 10

Likes

1,408 likes

Total Posts

12,671 posts

Correct Reply

2,278 solutions
Top badges earned
Validate 25
Validate 10
Validate 1
Give back 900
Give back 600
View profile

Avatar
Validate 25
Level 10
smacdonald2008
Level 10

Likes

1,408 likes

Total Posts

12,671 posts

Correct Reply

2,278 solutions
Top badges earned
Validate 25
Validate 10
Validate 1
Give back 900
Give back 600
View profile
smacdonald2008
Level 10

08-01-2019

Select field in a component dialog works fine - see this article -- Building Experience Manager Components using Granite/Coral Resource Types

Also - to display the value of a select value in a component - you need to write code  - like this where name of Select field is path (all discussed in the above article):

<div>

<p>This is your AEM HTML Template Language component:</p>

      <h1>${properties.heading}</h1>

       <p>${properties.description}</p>

       <p>The following values are the resource types added to the dialog</p>

      <p><b>Selected Path value:</b> ${properties.path}</p>

       <p>

            <b>Date:</b>

                  ${'yyyy-MM-dd HH:mm:ss.SSSXXX' @ format=properties.startdate, timezone='UTC'}

        </p>

        <p>

            <b>Size:</b> ${properties.size}

        </p>

        <p>

            <b>Checkbox:</b> ${properties.show}

        </p>

</div>

Avatar

Avatar
Coach
MVP
Arun_Patidar
MVP

Likes

1,356 likes

Total Posts

3,227 posts

Correct Reply

917 solutions
Top badges earned
Coach
Contributor 2
Ignite 10
Give Back 700
Boost 1000
View profile

Avatar
Coach
MVP
Arun_Patidar
MVP

Likes

1,356 likes

Total Posts

3,227 posts

Correct Reply

917 solutions
Top badges earned
Coach
Contributor 2
Ignite 10
Give Back 700
Boost 1000
View profile
Arun_Patidar
MVP

08-01-2019

Yes, It is not working when add component directly in HTL.

Though you ca achieve this using javascript.

Avatar

Avatar
Validate 10
Level 4
Var
Level 4

Likes

44 likes

Total Posts

113 posts

Correct Reply

5 solutions
Top badges earned
Validate 10
Validate 1
Boost 5
Boost 3
Boost 25
View profile

Avatar
Validate 10
Level 4
Var
Level 4

Likes

44 likes

Total Posts

113 posts

Correct Reply

5 solutions
Top badges earned
Validate 10
Validate 1
Boost 5
Boost 3
Boost 25
View profile
Var
Level 4

08-01-2019

Hi smacdonald2008​,

I i stated in the use case steps, it is not working when i am including the component into another component by CQ/Sly include.