Loading...
 
Skip to main content

Alternate block is cancelled when it is used twice in a module

Status
Closed
Subject
Alternate block is cancelled when it is used twice in a module
Version
23.x
Category
  • Regression
Feature
Wiki Plugin (extends basic syntax)
Resolution status
New
Submitted by
Bernard Sfez / Tiki Specialist
Lastmod by
Bernard Sfez / Tiki Specialist
Rating
(0)
Description

On a Tiki22 I had the following in a module displayed at the top area.

Copy to clipboard
{LIST()} {filter content="2" field="tracker_id"} {filter content="" field="tracker_field_childrenFamilyName"} {output template="child_picture_inner.tpl"}{ALTERNATE()} {ALTERNATE} {FORMAT(name="picture")}{display name="tracker_field_childrenPicture" default=" "}{FORMAT} {LIST} {LIST()} {filter content="3" field="tracker_id"} {filter content="" field="tracker_field_parentsFamilyName"} {output template="child_picture_inner.tpl"}{ALTERNATE()} {ALTERNATE} {FORMAT(name="picture")}{display name="tracker_field_parentsPicture" default=" "}{FORMAT} {LIST}


A user have an item in one tracker or the other.
And so pictures here (tracker2) or there (tracker3) not in both so it worked ok.

This code using Tiki22:
If you have a picture in tracker3 and not in 2 then if you have a picture in tracker2 but not in 3.
Image
Image

Same code using Tiki23:
Chrome
Image

Safari
Image

Workaround

As those users are in different group I used an additional plugins.

Copy to clipboard
{GROUP(groups="Parents" notgroups="Anonymous|Registered")} {LIST()} {filter content="2" field="tracker_id"} {filter content="" field="tracker_field_childrenFamilyName"} {output template="child_picture_inner.tpl"}{ALTERNATE() {ALTERNATE} {FORMAT(name="picture")}{display name="tracker_field_childrenPicture" default=" "}{FORMAT} {LIST} {ELSE} {LIST()} {filter content="3" field="tracker_id"} {filter content="" field="tracker_field_parentsFamilyName"} {output template="child_picture_inner.tpl"}{ALTERNATE()} {ALTERNATE} {FORMAT(name="picture")}{display name="tracker_field_parentsPicture" default=" "}{FORMAT} {LIST} {GROUP}
Importance
5
Easy to solve?
5
Priority
25
Demonstrate Bug on Tiki 19+
Demonstrate Bug (older Tiki versions)
Ticket ID
7817
Created
Saturday 28 August, 2021 11:57:53 UTC
by Bernard Sfez / Tiki Specialist
LastModif
Monday 30 August, 2021 13:56:48 UTC


Show PHP error messages