Project

General

Profile

Actions

Bug #8706

closed

JS conditions do not function properly with related conditions

Added by krileon about 3 years ago. Updated about 3 years ago.

Status:
Closed
Priority:
High
Assignee:
Target version:
Start date:
10 September 2021
Due date:
% Done:

100%

Estimated time:

Description

If a field is conditioned twice, but an external parent node then when 1 condition is checked the other is not even though it's always an AND situation. This results in inputs being made visible or hidden when they shouldn't be. Example as follows.

<if name="from_user" nametype="param:int" operator="=" value="0" valuetype="const:int" type="showhide">
<if name="from_system" nametype="param:int" operator="=" value="0" valuetype="const:int" type="showhide">
<param name="from_name" type="string" label="From Name" size="40" description="Input the name of the guest sending the message." validate="required" />
<param name="from_email" type="string" label="From Email Address" size="40" description="Input the email address of the guest sending the message." validate="required,email" />
</if>
</if>

With the above for example if from_user is set to 0 then from_name and from_email should be hidden regardless of from_system value, but if you toggle from_system to Yes then back to No from_name and from_email become visible. This is due to the related.. or parent.. conditions not being checked.

Actions #1

Updated by krileon about 3 years ago

  • Status changed from Assigned to Resolved
  • % Done changed from 0 to 100

Fixed in MR !1725

Actions #2

Updated by beat about 3 years ago

  • Target version changed from CB 2.7 to CB 2.6.3
Actions #3

Updated by beat about 3 years ago

  • Status changed from Resolved to Closed
Actions

Also available in: Atom PDF