You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
will send a populated result, where 1 is the number of the template used in the resources.
Next, install a number of Extras through the Modx packaging system and at some point (I have not established when, it appears to be random), the &where capabilities of getResources go wrong and a full list of results will always appear regardless of what is placed in the &where statement.
Observed behavior
How it behaved after following steps above.
Whatever statement you put into &where , a full listing of resources is always returned.
Expected behavior
How it should behave after following steps above.
&where should be parsing the statement and returning a matching set of results.
Environment
MODX version, apache/nginx and version, mysql version, browser, etc. Any relevant information.
MODX Revolution 2.5.0-pl on Debian Stable (Jessie), MySQL 5.5.49, PHP 5.6.22, Apache 2.4.10-10+deb8u4.
also
MODX Revolution 2.5.0-pl on Debian Unstable, MySQL 5.6.30-1, PHP 7.0.7-4, Apache 2.4.20-2.
Both using getResources Version: 1.6.0-pl from the Modx packaging system.
Summary
Quick summary what's this issue about.
The &where capabilities of getResources stop working after installing a number of different extras packages.
Step to reproduce
How to reproduce the issue, including custom code if needed.
Install Modx 2.5.0.pl, create a document resource and then several document resources using the first as a container.
Put a simple getResources request in the container document and make a template chunk to render it.
The &where capability of getResources will work at this point. If you place an untrue statement in there, the listing returned is empty. eg.
[[!getResources? &parents=
[[*id]]&where=
{"template:=":1234}&tpl=
mytemplate]]
whilst
[[!getResources? &parents=
[[*id]]&where=
{"template:=":1}&tpl=
mytemplate]]
will send a populated result, where 1 is the number of the template used in the resources.
Next, install a number of Extras through the Modx packaging system and at some point (I have not established when, it appears to be random), the &where capabilities of getResources go wrong and a full list of results will always appear regardless of what is placed in the &where statement.
Observed behavior
How it behaved after following steps above.
Whatever statement you put into &where , a full listing of resources is always returned.
Expected behavior
How it should behave after following steps above.
&where should be parsing the statement and returning a matching set of results.
Environment
MODX version, apache/nginx and version, mysql version, browser, etc. Any relevant information.
MODX Revolution 2.5.0-pl on Debian Stable (Jessie), MySQL 5.5.49, PHP 5.6.22, Apache 2.4.10-10+deb8u4.
also
MODX Revolution 2.5.0-pl on Debian Unstable, MySQL 5.6.30-1, PHP 7.0.7-4, Apache 2.4.20-2.
Both using getResources Version: 1.6.0-pl from the Modx packaging system.
These are the Extras that i installed:
Archivist 1.2.4-pl
Collections 3.4.2-pl
getDate 1.0.0-pl
getPage 1.2.4-pl
getResources 1.6.1-pl
lessCSS 1.3-pl
Markdown Editor 1.1.0-pl
oEmbed 0.2.2-pl
pdoTools 2.5.3-pl
Tagger 1.7.0-pl
Finally
There is a thread covering this issue on the Modx forum.
https://forums.modx.com/thread/100391/getresources-where-does-not-work
The text was updated successfully, but these errors were encountered: