9 years ago
1
Topic

Hi

It seems there is another possible issue with the conditional states on search forms: when a condition state fills a field from a select dynamic (multiple) all the values are separated by a comma without space even if you specified a ', ' separator in the select dynamic.

I must add that if I don't use the conditional state but a JS script instead in the destination field:

$("#source_field").on("change", function()

{

$("#destination_field").val($(this).val()); });

I get the SAME issue, so maybe the problem is not the conditional state but the way the first field (select dynamic) sends the data ?

I tested with J3.4.3 + Seblod 3.7.0

Before I write a possible issue on the Github, may be someone can tell me what I may have forgotten please ?

thanks

cyril

Get a Book for SEBLOD
9 years ago
0
Level 1

Hi again

I found the solution with the JS code in the destination field to replace the conditional state:

$("#source_field").on("change", function(){ $("#destination_field").val($(this).val().join(", ")); });


this way the destination field is filled with the values from the source field BUT with the space after the comma!


The conclusion I get here is that conditional state are great for simple function but should be replaced by JS code when you need something more special.


thanks SEBLOD TEAM to let us choose !



Cyril

Get a VIP membership