Difference between revisions of "Template: RNPrint"
From Genesys Documentation
production>Bgrenon ((by SublimeText.Mediawiker)) |
|||
Line 1: | Line 1: | ||
− | <includeonly><h2>{{#ifeq:{{#cargo_query:tables=ArticleCloudRN,ArticleCloudRN__ComponentId|join on=ArticleCloudRN._ID=ArticleCloudRN__ComponentId._rowID|fields=COUNT(*)|where=ArticleCloudRN._pageName="{{FULLPAGENAME}}" AND ArticleCloudRN._pageNamespace="{{NAMESPACENUMBER}}"|no html}}|1||{{{ComponentName|}}}:}} {{#if:{{{ReleaseDate|}}}|{{#time:F d, Y|{{{ReleaseDate|}}}}}|<span style="background-color:yellow">Date needed</span>}} {{#cargo_query: | + | <includeonly><!-- Creating section heading--><h2>{{#ifeq:{{#cargo_query:tables=ArticleCloudRN, |
− | tables=ComponentRN,DeploymentType=DT | + | ArticleCloudRN__ComponentId |
+ | |join on=ArticleCloudRN._ID=ArticleCloudRN__ComponentId._rowID | ||
+ | |fields=COUNT(*) | ||
+ | |where=ArticleCloudRN._pageName="{{FULLPAGENAME}}" | ||
+ | AND ArticleCloudRN._pageNamespace="{{NAMESPACENUMBER}}"|no html}}|1||{{{ComponentName|}}}:}} {{#if:{{{ReleaseDate|}}}|{{#time:F d, Y|{{{ReleaseDate|}}}}}|<span style="background-color:yellow">Date needed</span>}} {{#cargo_query: | ||
+ | tables=ComponentRN, | ||
+ | DeploymentType=DT | ||
|join on=ComponentRN.DeploymentTypeId HOLDS DT.Id | |join on=ComponentRN.DeploymentTypeId HOLDS DT.Id | ||
|fields=CONCAT('[[File:',DT.Image,'|',Size,'px|link=]]') | |fields=CONCAT('[[File:',DT.Image,'|',Size,'px|link=]]') | ||
|delimiter= | |delimiter= | ||
− | |where=ComponentRN.ComponentId | + | |where=ComponentRN.ComponentId="{{{Component|}}}" |
− | }}<!-- | + | AND ReleaseNumber="{{{ReleaseNumber|}}}" |
− | + | AND ComponentRN._pageNamespace="{{NAMESPACENUMBER}}" | |
− | + | }}</h2><!-- adding anchor div for linking to RN entry -->{{AnchorDiv|{{{ComponentName|}}}-{{{ReleaseNumber|}}}}}<!-- printing subheading to indicate private edition or mixed mode release info --><!-- IMPORTANT: This query includes hard-coded value for DeploymentType.Name-->{{#cargo_query: | |
− | + | tables=ComponentRN, | |
− | + | DeploymentType=DT | |
− | |||
− | |||
− | tables=ComponentRN,DeploymentType=DT | ||
|join on=ComponentRN.DeploymentTypeId HOLDS DT.Id | |join on=ComponentRN.DeploymentTypeId HOLDS DT.Id | ||
− | |fields=DT.Image=Image,DT.Size=Size,DT.Name=DTName,ComponentRN.ComponentId=ComponentId,ReleaseNumber,PrivateEditionReleaseDate=PEDate,MixedModeReleaseDate=MixedDate | + | |fields=DT.Image=Image, |
+ | DT.Size=Size, | ||
+ | DT.Name=DTName, | ||
+ | ComponentRN.ComponentId=ComponentId, | ||
+ | ReleaseNumber, | ||
+ | PrivateEditionReleaseDate=PEDate, | ||
+ | MixedModeReleaseDate=MixedDate | ||
|named args=yes | |named args=yes | ||
|format=template | |format=template | ||
|template=RNPrintSubhead | |template=RNPrintSubhead | ||
|default= | |default= | ||
− | |where=ComponentRN._pageNamespace="{{NAMESPACENUMBER}}" AND | + | |where=ComponentRN._pageNamespace="{{NAMESPACENUMBER}}" |
− | }}{{#cargo_query: | + | AND ComponentRN.ComponentId="{{{Component|}}}" |
− | tables=ComponentRN,Issue,IssueCategory | + | AND ReleaseNumber="{{{ReleaseNumber|}}}" |
− | |join on=ComponentRN._pageName=Issue._pageName,Issue.IssueCategoryId=IssueCategory.Id | + | AND (DT.Name="Private Edition" OR DT.Name="Mixed mode") |
− | |fields=IssueCategory.SectionName=Name,SupportingDocumentation,LocalContent,Issue.TicketNumber,SupportingDocumentation,NFBoilerplateId,ReleaseNumber,ComponentId | + | }}<!-- printing out the list of Issues according to their IssueCategory-->{{#cargo_query: |
+ | tables=ComponentRN, | ||
+ | Issue, | ||
+ | IssueCategory | ||
+ | |join on=ComponentRN._pageName=Issue._pageName, | ||
+ | Issue.IssueCategoryId=IssueCategory.Id | ||
+ | |fields=IssueCategory.SectionName=Name, | ||
+ | SupportingDocumentation, | ||
+ | LocalContent, | ||
+ | Issue.TicketNumber, | ||
+ | SupportingDocumentation, | ||
+ | NFBoilerplateId, | ||
+ | ReleaseNumber, | ||
+ | ComponentId | ||
|format=template | |format=template | ||
|template=RNPrintFormat | |template=RNPrintFormat | ||
|named args=yes | |named args=yes | ||
− | |where=ComponentRN.ComponentId | + | |where=ComponentRN.ComponentId = "{{{Component|}}}" AND ReleaseNumber="{{{ReleaseNumber|}}}" AND IssueCategoryId IS NOT NULL AND ComponentRN._pageNamespace="{{NAMESPACENUMBER}}" |
|order by=IssueCategory.PrintOrder ASC | |order by=IssueCategory.PrintOrder ASC | ||
|group by=IssueCategory.SectionName | |group by=IssueCategory.SectionName | ||
− | }}__NOCACHE__{{#switch:{{NAMESPACENUMBER}}|620=<span style="font-size:80%">[[{{{Page|}}}|(Link to source)]]</span>|#default=}}</includeonly><noinclude>[[Category:RNAutomation]]</noinclude> | + | }}__NOCACHE__{{#switch:{{NAMESPACENUMBER}}|620=<span style="font-size:80%">[[{{{Page|}}}|(Link to source)]]</span>|#default=}}</includeonly><noinclude>[[Category:RNAutomation]][[Category:ComponentRN.ComponentId cleanup]][[Category:TrackConstants]]</noinclude> |