Difference between revisions of "Widget:RAPID-Transclude"

From Open Energy Information

(add hydro project type filter functions)
(adding canadian abbr)
Line 230: Line 230:
 
   overviewAbbr = "WY"
 
   overviewAbbr = "WY"
 
};
 
};
 +
if(locationMapper == "Canada"){
 +
  overviewAbbr = "CAN"
 +
};
 +
if(locationMapper == "Alberta"){
 +
  overviewAbbr = "AB"
 +
};
 +
if(locationMapper == "British_Columbia"){
 +
  overviewAbbr = "BC"
 +
};
 +
if(locationMapper == "Manitoba"){
 +
  overviewAbbr = "MB"
 +
};
 +
if(locationMapper == "New_Brunswick"){
 +
  overviewAbbr = "NB"
 +
};
 +
if(locationMapper == "Ontaria"){
 +
  overviewAbbr = "ON"
 +
};
 +
if(locationMapper == "Quebec"){
 +
  overviewAbbr = "QC"
 +
};
 +
if(locationMapper == "Saskatchewan"){
 +
  overviewAbbr = "SK"
 +
};
 +
if(locationMapper == "Yukon"){
 +
  overviewAbbr = "YT"
 +
};
 +
 +
  
 
//mediawiki api query
 
//mediawiki api query

Revision as of 15:48, 19 August 2019

This template performs an ajax request for RAPID Tech/Jurisdiction/Topic pages, based on their related Roadmap Overview page. It is called by [[:Template:RAPID-Overview(Tech-Jurisdiction-Topic). See RAPID/Geothermal/California/Land Use as an example.

The template "[transcludes]" information from the right column, the overview and the narrative from pages like RAPID/Roadmap/3 and imports it to the page using the above template (such as RAPID/Geothermal/California/Land Use). It also removes any links/buttons that are not related to the current page's jurisdiction.