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

Fileupload coral3 resource-type not working.

Avatar

Avatar
Ignite 1
Level 2
ks_hitijingole
Level 2

Likes

3 likes

Total Posts

8 posts

Correct Reply

0 solutions
Top badges earned
Ignite 1
Give Back 3
Give Back
Boost 3
Boost 1
View profile

Avatar
Ignite 1
Level 2
ks_hitijingole
Level 2

Likes

3 likes

Total Posts

8 posts

Correct Reply

0 solutions
Top badges earned
Ignite 1
Give Back 3
Give Back
Boost 3
Boost 1
View profile
ks_hitijingole
Level 2

21-04-2021

I am trying to migrate a component from Coral 2 to Coral 3. We have a sling:resourceType= granite/ui/components/foundation/form/fileupload which we changed to granite/ui/components/coral/foundation/form/fileupload. But after doing so the component dialog doesn't open.

 

I looked at the OOTB AEM core image component at this location (/apps/core/wcm/components/image/v1/image) and got surprised that its using “cq/gui/components/authoring/dialog/fileupload”, instead of coral-3 resource type (/libs/granite/ui/components/coral/foundation/form/fileupload). All other nodes in this component are using coral-3 resource-type, but not the fileupload. Is there any reason for that?

 

We went ahead with the cq/gui/components/authoring/dialog/fileupload, but this is breaking our Alt Text validation functionality. Can you please let me know why in Coral3 granite/ui/components/coral/foundation/form/fileupload is not being used?

Replies

Avatar

Avatar
Affirm 100
Level 10
asutosh_jena
Level 10

Likes

373 likes

Total Posts

480 posts

Correct Reply

133 solutions
Top badges earned
Affirm 100
Ignite 1
Establish
Give Back 50
Give Back 5
View profile

Avatar
Affirm 100
Level 10
asutosh_jena
Level 10

Likes

373 likes

Total Posts

480 posts

Correct Reply

133 solutions
Top badges earned
Affirm 100
Ignite 1
Establish
Give Back 50
Give Back 5
View profile
asutosh_jena
Level 10

21-04-2021

HI @ks_hitijingole 

 

Which version of AEM you are finding this issue?

 

Update:

Please try with the below code. It works on AEM 6.5

 

<image
jcr:primaryType="nt:unstructured"
sling:resourceType="granite/ui/components/coral/foundation/form/fileupload"
autoStart="{Boolean}false"
fieldLabel="Image"
class="cq-droptarget"
fieldDescription="Configure Image"
fileNameParameter="./fileName"
fileReferenceParameter="./fileReference"
mimeTypes="[image/gif,image/jpeg,image/png,image/tiff,image/svg+xml]"
multiple="{Boolean}false"
name="./file"
text="Upload"
title="Upload Image Asset"
useHTML5="{Boolean}true"/>

 

Ensure to remove "uploadUrl" if you are not using the "autoStart" as "true". The URL to upload the file. This is only required when autoStart is true.

https://helpx.adobe.com/experience-manager/6-4/sites/developing/using/reference-materials/granite-ui...

 

asutosh_jena_0-1619074704698.png

 

 

Thanks!

Avatar

Avatar
Ignite 1
Level 2
ks_hitijingole
Level 2

Likes

3 likes

Total Posts

8 posts

Correct Reply

0 solutions
Top badges earned
Ignite 1
Give Back 3
Give Back
Boost 3
Boost 1
View profile

Avatar
Ignite 1
Level 2
ks_hitijingole
Level 2

Likes

3 likes

Total Posts

8 posts

Correct Reply

0 solutions
Top badges earned
Ignite 1
Give Back 3
Give Back
Boost 3
Boost 1
View profile
ks_hitijingole
Level 2

21-04-2021

Hi @asutosh_jena we are facing the issue with AEM 6.5.6.0.

Avatar

Avatar
Affirm 100
Level 10
asutosh_jena
Level 10

Likes

373 likes

Total Posts

480 posts

Correct Reply

133 solutions
Top badges earned
Affirm 100
Ignite 1
Establish
Give Back 50
Give Back 5
View profile

Avatar
Affirm 100
Level 10
asutosh_jena
Level 10

Likes

373 likes

Total Posts

480 posts

Correct Reply

133 solutions
Top badges earned
Affirm 100
Ignite 1
Establish
Give Back 50
Give Back 5
View profile
asutosh_jena
Level 10

21-04-2021

Hi @ks_hitijingole 

 

Please try with above code. It should work.

 

Thanks!

Avatar

Avatar
Coach
MVP
Arun_Patidar
MVP

Likes

1,261 likes

Total Posts

3,150 posts

Correct Reply

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

Avatar
Coach
MVP
Arun_Patidar
MVP

Likes

1,261 likes

Total Posts

3,150 posts

Correct Reply

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

22-04-2021

I would recommend to use cq/gui/components/authoring/dialog/fileupload orgranite/ui/components/foundation/form/fileupload instead of granite/ui/components/coral/foundation/form/fileupload, coral3 fileupload does not provide functionality to browse assets from AEM DAM. you can only upload from local.

Avatar

Avatar
Ignite 1
Level 2
ks_hitijingole
Level 2

Likes

3 likes

Total Posts

8 posts

Correct Reply

0 solutions
Top badges earned
Ignite 1
Give Back 3
Give Back
Boost 3
Boost 1
View profile

Avatar
Ignite 1
Level 2
ks_hitijingole
Level 2

Likes

3 likes

Total Posts

8 posts

Correct Reply

0 solutions
Top badges earned
Ignite 1
Give Back 3
Give Back
Boost 3
Boost 1
View profile
ks_hitijingole
Level 2

22-04-2021

Hey @Arun_Patidar, is it okay to use a Coral UI 2 resourceType while other nodes in the component are in Coral UI 3?

Avatar

Avatar
Coach
MVP
Arun_Patidar
MVP

Likes

1,261 likes

Total Posts

3,150 posts

Correct Reply

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

Avatar
Coach
MVP
Arun_Patidar
MVP

Likes

1,261 likes

Total Posts

3,150 posts

Correct Reply

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

22-04-2021

Hi, This is totally fine to use coral2 or foundations. Coral3 are the upgraded one with bug fixes and improvements but if that does not fulfill your requirement you can use coral2 or foundation.

Avatar

Avatar
Ignite 1
Level 2
ks_hitijingole
Level 2

Likes

3 likes

Total Posts

8 posts

Correct Reply

0 solutions
Top badges earned
Ignite 1
Give Back 3
Give Back
Boost 3
Boost 1
View profile

Avatar
Ignite 1
Level 2
ks_hitijingole
Level 2

Likes

3 likes

Total Posts

8 posts

Correct Reply

0 solutions
Top badges earned
Ignite 1
Give Back 3
Give Back
Boost 3
Boost 1
View profile
ks_hitijingole
Level 2

22-04-2021

Hi @asutosh_jena , I tried with the above code. But it did not work for me. The Drag and drop field appears to be broken.

 

Please find attached content.xml for the node :

 

 

<mediaContianer
                                jcr:primaryType="nt:unstructured"
                                sling:resourceType="granite/ui/components/coral/foundation/form/fileupload"
                                allowUpload="{Boolean}false"
                                autoStart="{Boolean}false"
                                class="cq-droptarget"
                                fieldDescription="Upload Image(Expected Image for inside view size:2880x1404 and for outside view size:1072x912)"
                                fieldLabel="Roche Dam asset"
                                fileNameParameter="./mediaContainer"
                                fileReferenceParameter="./fileReference"
                                mimeTypes="[image,video/.*]"
                                multiple="{Boolean}false"
                                name="./mediaContainer"
                                required="{Boolean}true"
                                title="Upload Image Asset"
                                useHTML5="{Boolean}true"/>

 

 

ks_hitijingole_0-1619089060193.png

 

Avatar

Avatar
Affirm 100
Level 10
asutosh_jena
Level 10

Likes

373 likes

Total Posts

480 posts

Correct Reply

133 solutions
Top badges earned
Affirm 100
Ignite 1
Establish
Give Back 50
Give Back 5
View profile

Avatar
Affirm 100
Level 10
asutosh_jena
Level 10

Likes

373 likes

Total Posts

480 posts

Correct Reply

133 solutions
Top badges earned
Affirm 100
Ignite 1
Establish
Give Back 50
Give Back 5
View profile
asutosh_jena
Level 10

22-04-2021

If you want the drag and drop functionality you need to use cq/gui/components/authoring/dialog/fileupload