Jump to content

Template:Printer

From Swarthmore Knowledge Base

Description

This template displays information about a campus printer in a standardized table. It also stores printer details as Semantic MediaWiki properties, automatically assigns categories based on printer access, and displays printer instructions using the Module:PrinterInstructionsLookup Lua module.

Usage

Add the following code to a printer page and replace the example values with the appropriate information.

{{Printer
|Department=Library
|Location=First Floor
|Queue Name=library-printer
|Printer Model=HP LaserJet
|Access=Employees
|Print Release Station=true
}}

The Print Release Station parameter is optional. If omitted or left blank, the corresponding row will not appear in the table.

Parameters

Parameter Description Required Semantic Property
Department Department associated with the printer. Yes Department
Location Physical location of the printer. Yes Location
Queue Name Name of the printer queue used to connect to the printer. Yes Queue Name
Printer Model Manufacturer and model of the printer. Yes Printer Model
Access Comma-separated list of groups permitted to use the printer. Recognized values for automatic categorization are Employees and Students. Yes Access
Print Release Station Boolean for wehether a print release station is enabled. The row is hidden when this parameter is empty. No Print Release Station

Automatic categorization

The template automatically assigns printer pages to categories based on the Access parameter:

A printer with both values is added to both categories.

All printer pages using this template are also added to Category:NoFS. This means the page is not automatically added to Freshservice Solutions articles.

Printer instructions

The template invokes Module:PrinterInstructionsLookup using the getInstructions function to display printer instructions.

The instructions are generated by the Lua module rather than entered directly as template parameters.

Notes

  • Multiple access groups must be separated by commas.
  • The Access values must match Employees and Students exactly for automatic categorization.
  • The print release station row is displayed only when a nonempty value is provided.
  • Printer details are stored as Semantic MediaWiki properties for use in queries and reports.