Template:CardSearch: Difference between revisions

From LOTR-TCG Wiki
No edit summary
No edit summary
Line 26: Line 26:
AND ("{{{twilightLess|}}}" = "" OR CR.TwilightCost <= "{{{twilightLess|}}}")
AND ("{{{twilightLess|}}}" = "" OR CR.TwilightCost <= "{{{twilightLess|}}}")
AND ("{{{strength|}}}" = "" OR CASE WHEN "{{{strength|}}}" LIKE '+%' OR "{{{strength|}}}" LIKE '-%' THEN CR.StrengthMod = "{{{strength|}}}" ELSE CR.Strength = "{{{strength|}}}" END)
AND ("{{{strength|}}}" = "" OR CASE WHEN "{{{strength|}}}" LIKE '+%' OR "{{{strength|}}}" LIKE '-%' THEN CR.StrengthMod = "{{{strength|}}}" ELSE CR.Strength = "{{{strength|}}}" END)
AND ("{{{strengthMore|}}}" = "" OR CASE WHEN "{{{strengthMore|}}}" LIKE '+%' OR "{{{strengthMore|}}}" LIKE '-%' THEN CR.StrengthMod >= "{{{strengthMore|}}}" ELSE CR.Strength >= "{{{strengthMore|}}}" END)
AND ("{{{strengthMore|}}}" = "" OR CASE WHEN "{{{strengthMore|}}}" RLIKE '(+{{!}}-)\d+%' THEN CAST(CR.StrengthMod AS INT) >= CAST("{{{strengthMore|}}}" AS INT) ELSE CR.Strength >= "{{{strengthMore|}}}" END)
AND ("{{{strengthLess|}}}" = "" OR CASE WHEN "{{{strengthLess|}}}" LIKE '+%' OR "{{{strengthLess|}}}" LIKE '-%' THEN CR.StrengthMod <= "{{{strengthLess|}}}" ELSE CR.Strength <= "{{{strengthLess|}}}" END)
AND ("{{{strengthLess|}}}" = "" OR CASE WHEN "{{{strengthLess|}}}" LIKE '+%' OR "{{{strengthLess|}}}" LIKE '-%' THEN CR.StrengthMod <= "{{{strengthLess|}}}" ELSE CR.Strength <= "{{{strengthLess|}}}" END)



Revision as of 22:06, 25 September 2022

This is the "CardSearch" template.

It should be called in the following format:

{{CardSearch
|isUnique=
|sort=
}}

Edit the page to see the template text.