InputDialog EntityParameter Filter

Hi,

I’m using Cuba 7.2

I have started using InputDialog recently and see that it is quite handy but I need a way to filter values in Entity Parameter.

How do I do?

Thanks,
Hari

Hi,
Isn’t example “2. Input dialog with a custom parameter:” from the documentation the thing you need?
https://doc.cuba-platform.com/manual-7.2/gui_dialogs.html

    dialogs.createInputDialog(this)
            .withCaption("Enter some values")
            .withParameters(
                    InputParameter.stringParameter("name").withCaption("Name"),
                    InputParameter.parameter("customer") 
                            .withField(() -> {
                                LookupField<Customer> field = uiComponents.create(
                                        LookupField.of(Customer.class));
                                field.setOptionsList(dataManager.load(Customer.class).list());
                                field.setCaption("Customer"); 
                                field.setWidthFull();
                                return field;
                            })
            )
...

This will work.