Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

List not working

Hello,

 

I want to create a list in my configuration of my component. My List look like:

 

@Option("providedInformation")
@Documentation("providedInformation")
private List<ProvInfo> providedInformation = new ArrayList<>();

public class ProvInfo {

@Documentation("name")
@Option("name")
private String name;

@Documentation("url")
@Option("url")
private Url url;
....

In my configuration field there is a list, butI can not edit:

0683p000009M1Y2.png

I use version 1.1.1, in a earlier version it works.

Labels (3)
7 Replies
Anonymous
Not applicable
Author

Hello @benjamin,

 

Can you confirm you can't click on the "+" button under the table to add a line?

Anonymous
Not applicable
Author

I can click the plus Button, but I can not write into the fields.

Anonymous
Not applicable
Author

Hello,
You are missing the layout for your ProvInfo class that define your table. This is why you are getting a table with no columns and so not editable.
Please add layout to your class.

A simple one can be

@OptionsOrder({ "name", "url" })

Hope it helps.

Anonymous
Not applicable
Author

Hi Anas,

 

in my case its not working it only works in the  basic settings, but in the previous versions it worked both in basic and advanced settings maybe this is a bug to look into? 

 

 

best regards.

Anonymous
Not applicable
Author

I have tried the suggested solution on the studio TOS_DI-20181026_1147-V7.1.1 and framework version 1.1.1 and it works.
@mbocquet  on which version are you having the issue exactly ?

Anonymous
Not applicable
Author

Hi Anas,

i m using it on version 1.1.1 of the framework and TOS 7.1.1, an it only works in the basic settings. this is the version of the framework i m using 

       <dependency>
            <groupId>org.talend.sdk.component</groupId>
            <artifactId>component-api</artifactId>
            <version>1.1.1</version>
            <scope>provided</scope>
        </dependency>
Anonymous
Not applicable
Author

When defining advanced settings properties. layout is also required. and in this version only configuration that belong to advanced settings will shows in advanced tab including for tables.

To get it works you will need to defined the columns of your table in the advanced settings layout.

@GridLayout(names = ADVANCED, value = { @GridLayout.Row("providedInformation"), @GridLayout.Row("myURL") })
public class MyConfig implements Serializable {

    @Option("providedInformation")
    private List<ProvInfo> providedInformation = new ArrayList<>();


    @GridLayout(names = ADVANCED, value = { @GridLayout.Row({ "name", "url" }) })
    public static class ProvInfo {

        @Option("name")
        private String name;

        @Option("url")
        private URL url;
    }
}