Control Add search Condition operators

Hi,

I have two questions regarding the current operator functionality present in add search condition:

First, is it possible to hide the contains operator? It generally results in a high system load, and we would like to limit its use.

Second, regarding the in operator, I currently have to add values manually and click add for each one. This is time-consuming when dealing with a large number of values (e.g., 20 or more). Is it possible to support comma-separated values so they can be added all at once? I attempted to do this, but the values were not fetched correctly.

Hi, adnan!

Could you please specify the Jmix version you are using? This will help us provide a more accurate answer for both points.

@p.aleksandrov

Jmix version 1.5

Hello Adnan!

Conditions you added using “Add search condition” are converted to PropertyFilter that does not support limiting available operations.

I’ve created a GitHub issue for PropertyFilter: Make operation list configurable in PropertyFilter · Issue #5087 · jmix-framework/jmix · GitHub, but it does not resolve the problem of supporting it in GenericFilter.

Is it possible to support comma-separated values so they can be added all at once?

The SelectValueDialog invoked for adding values uses type oriented fields for the “IN” operation. It means that for an Integer property, the dialog generates a field with IntegerDatatype, so you cannot use commas or other symbols in the field.
You can try to override this dialog and generate a field with the String type only, but then you will have to validate each entered value and somehow distinguish a comma used as a decimal separator from a comma used as a value delimiter.