dotvvm icon indicating copy to clipboard operation
dotvvm copied to clipboard

Business Pack ComboBox Server Search does not work

Open vstribrny opened this issue 6 years ago • 6 comments

I am evaluating Business Pack controls with DotVVM 2. I tried "Server Search" functionality while following the documentation ("Sample 7: Server Search"). The problem is that the text being typed by the user is not transferred to ViewModel's Text property when the LoadItems command is invoked, so the server-side searching cannot be performed. Maybe I am missing something not mentioned in the sample in the doc?

vstribrny avatar Jul 25 '18 13:07 vstribrny

Hi, the ComboBox is still a work in progress.

You can try to replace LoadItems="{staticCommand: LoadCountries(Text)}" with LoadItems="{staticCommand: LoadCountries(text)}". text is not a property in a viewModel, it's a "temporary" variable which contains current text value even if the value is not yet commited to the viewModel property.

adamjez avatar Jul 26 '18 07:07 adamjez

Hi Adam, the "text" workaround works, thanks. Please when can we expect the "RTM" version of Business Pack controls for DotVVM 2?

In addition, there is also a problem that the LoadItems command does not get called when the text gets empty (e.g. when the user deletes the last character). As a result, the content of drop-down list is the previous return value of LoadItems command. Is there a solution also for this problem?

vstribrny avatar Jul 26 '18 14:07 vstribrny

We don't have any ETA for BusinessPack control release yet. Soon we will publicly share one.

Thank you for reporting the problem you described, it's fixed and it will be included in next preview release.

adamjez avatar Jul 29 '18 07:07 adamjez

Great, thanks for fixing it.

vstribrny avatar Jul 29 '18 07:07 vstribrny

I can confirm I have same problem. BussinessPack v 2.3.1.

readcom avatar Jul 10 '19 14:07 readcom

@readcom Hi, there was an issue with the documentation regarding the server-side search feature of ComboBox. We have updated the sample as suggested by @adamjez. Can you please try it?

mrnustik avatar Jun 01 '20 12:06 mrnustik