Difference between revisions of "OmniMedia"

From Sega Retro

Line 33: Line 33:
 
|fields=relationships.name,releases.date
 
|fields=relationships.name,releases.date
 
|where=relationships.relatedto="{{{1|}}}" and relationships.relationshiptype="video"
 
|where=relationships.relatedto="{{{1|}}}" and relationships.relationshiptype="video"
|join on=relationships.name=releases.name
 
|group by=releases.name
 
|order by=releases.date
 
|format=template
 
|template=OmniMedia/Cargo
 
|default=
 
}}}}{{#vardefine:prereleaseresult|{{#cargo_query:
 
tables=relationships,releases
 
|fields=relationships.name,releases.date
 
|where=relationships.relatedto="{{{1|}}}" and relationships.relationshiptype="prerelease"
 
 
|join on=relationships.name=releases.name
 
|join on=relationships.name=releases.name
 
|group by=releases.name
 
|group by=releases.name
Line 53: Line 43:
 
#if:{{#var:musicresult}}|'''Music:''' {{#sub:{{#var:musicresult}}|0|-2}}<br/>|}}{{
 
#if:{{#var:musicresult}}|'''Music:''' {{#sub:{{#var:musicresult}}|0|-2}}<br/>|}}{{
 
#if:{{#var:audiobookresult}}|'''Audiobooks:''' {{#sub:{{#var:audiobookresult}}|0|-2}}<br/>|}}{{
 
#if:{{#var:audiobookresult}}|'''Audiobooks:''' {{#sub:{{#var:audiobookresult}}|0|-2}}<br/>|}}{{
#if:{{#var:videoresult}}|'''Videos:''' {{#sub:{{#var:videoresult}}|0|-2}}<br/>|}}{{
+
#if:{{#var:videoresult}}|'''Videos:''' {{#sub:{{#var:videoresult}}|0|-2}}<br/>|}}
#if:{{#var:prereleaseresult}}|'''Prereleases:''' {{#sub:{{#var:prereleaseresult}}|0|-2}}<br/>|}}
 
 
{{clearvar|bookresult|musicresult|audiobookresult|videoresult|prereleaseresult}}</includeonly><noinclude>[[Category:Sega Retro templates]]
 
{{clearvar|bookresult|musicresult|audiobookresult|videoresult|prereleaseresult}}</includeonly><noinclude>[[Category:Sega Retro templates]]
 
Template that generates relevant media for Omni tables, so you don't have to.
 
Template that generates relevant media for Omni tables, so you don't have to.

Revision as of 05:49, 22 December 2020