TapeTrack Documentation

Because there is more to tape management than you ever realized

User Tools

Site Tools


billing:stylesheet

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
billing:stylesheet [2026/08/18 02:47] – [File Location] Scott Cunliffebilling:stylesheet [2026/08/18 02:56] (current) – [XML Displays as Unformatted Text] Scott Cunliffe
Line 40: Line 40:
 ===== File Location ===== ===== File Location =====
  
-The ''tapetrack.xslt'' file can be stored in any directory accessible to the account running the billing process and the application displaying the XML. +The ''tapetrack.xslt'' file can be stored in any directory accessible to the account running the billing process and the application displaying the XML.  For ease of administration, it is recommended that the stylesheet is stored with the other approved billing configuration files.
- +
-For ease of administration, it is recommended that the stylesheet is stored with the other approved billing configuration files.+
  
 Example Windows location: Example Windows location:
Line 52: Line 50:
   /etc/tapetrack/billing/tapetrack.xslt   /etc/tapetrack/billing/tapetrack.xslt
  
-The location of the stylesheet can be supplied to ''[[cli:tmss10logstatsprocess|TMSS10LogStatsProcess]]'' using the ''-X'' argument.+The location of the stylesheet can be supplied to ''[[cli:tmss10logstatsprocess|TMSS10LogStatsProcess]]'' using the ''-X'' argument. Omitting the -X argument when running ''[[cli:tmss10logstatsprocess|TMSS10LogStatsProcess]]'', the program will default to tapetrack.xslt.
  
-If the ''-X'' argument is not supplied, the default stylesheet name is: 
  
-  tapetrack.xslt 
  
  
 ===== File Format ===== ===== File Format =====
  
-The TapeTrack stylesheet is an XSLT file containing XML-formatted transformation instructions. +The TapeTrack stylesheet is an XSLT file containing XML-formatted transformation instructions.  The file normally uses the ''.xslt'' extension.  A billing XML file references the stylesheet using an XML processing instruction.
- +
-The file normally uses the ''.xslt'' extension. +
- +
-A billing XML file references the stylesheet using an XML processing instruction.+
  
 Example: Example:
Line 131: Line 123:
 The stylesheet reads each ''item'' element within ''tapetrack_data'' and displays its values as a table row. The stylesheet reads each ''item'' element within ''tapetrack_data'' and displays its values as a table row.
  
-===== Running TMSS10LogStatsProcess ===== 
- 
-Use the ''-X'' argument to specify the stylesheet used by [[cli:tmss10logstatsprocess|TMSS10LogStatsProcess]]. 
- 
-Example: 
- 
-  TMSS10LogStatsProcess -i US01.ttstats -M customer_map.txt -P package_map.txt -c default.ttsdef -X tapetrack.xslt > Billing_US01.xml 
- 
-Where: 
- 
-^ Argument ^ Value ^ Description ^ 
-| ''-i'' | ''US01.ttstats'' | Specifies the TapeTrack statistics input file. | 
-| ''-M'' | ''customer_map.txt'' | Specifies the Customer Description Map. | 
-| ''-P'' | ''package_map.txt'' | Specifies the Package Map. | 
-| ''-c'' | ''default.ttsdef'' | Specifies the Billing Rules. | 
-| ''-X'' | ''tapetrack.xslt'' | Specifies the XML stylesheet. | 
-| Standard output | ''Billing_US01.xml'' | Receives the calculated billing XML. | 
- 
-The resulting XML contains a reference similar to: 
- 
-<code xml> 
-<?xml-stylesheet type="text/xsl" href="tapetrack.xslt"?> 
-</code> 
- 
-If the stylesheet is not stored in the current directory, specify the required path. 
- 
-Example: 
- 
-  TMSS10LogStatsProcess ^ 
-  -i "C:\TapeTrack\Billing\Input\US01.ttstats" ^ 
-  -M "C:\TapeTrack\Billing\Config\customer_map.txt" ^ 
-  -P "C:\TapeTrack\Billing\Config\package_map.txt" ^ 
-  -c "C:\TapeTrack\Billing\Config\default.ttsdef" ^ 
-  -X "C:\TapeTrack\Billing\Config\tapetrack.xslt" ^ 
-  > "C:\TapeTrack\Billing\Output\Billing_US01.xml" 
- 
-===== Relationship to Billing XML ===== 
- 
-The billing XML contains the calculated values. 
- 
-Example: 
- 
-<code xml> 
-<tapetrack_data> 
-  <item> 
-    <customer>US01</customer> 
-    <itemcode>New York STORAGE_OFFSITE</itemcode> 
-    <description>LTO Vault Storage Charge</description> 
-    <count>60</count> 
-    <cost>0.01</cost> 
-    <total>0.60</total> 
-  </item> 
-</tapetrack_data> 
-</code> 
- 
-The stylesheet determines how these values are displayed. 
- 
-^ XML Element ^ Displayed Value ^ 
-| ''customer'' | US01 | 
-| ''itemcode'' | New York STORAGE_OFFSITE | 
-| ''description'' | LTO Vault Storage Charge | 
-| ''count'' | 60 | 
-| ''cost'' | 0.01 | 
-| ''total'' | 0.60 | 
- 
-Changing the stylesheet may change headings, colors, number formatting or layout. It does not change the values stored in the XML. 
- 
-<WRAP note> 
-The billing XML remains the authoritative billing output. The stylesheet is only a presentation layer. 
-</WRAP> 
  
 ===== Troubleshooting ===== ===== Troubleshooting =====
  
-==== XML Displays as Unformatted Text ==== 
  
-Check that: 
- 
-  * The XML contains an ''xml-stylesheet'' processing instruction. 
-  * The stylesheet filename is spelled correctly. 
-  * The stylesheet exists at the referenced location. 
-  * The Desktop UI or browser has permission to read the stylesheet. 
-  * The stylesheet is valid XML. 
-  * The stylesheet uses the correct XSLT namespace. 
-  * The application supports XSLT processing. 
  
 ==== Stylesheet Cannot Be Found ==== ==== Stylesheet Cannot Be Found ====
Line 227: Line 139:
   * The billing process is not referencing an old stylesheet location.   * The billing process is not referencing an old stylesheet location.
  
-==== Billing Information Is Missing From the Display ==== 
- 
-The information may exist in the XML but not be selected by the stylesheet. 
- 
-Check that: 
- 
-  * The expected elements exist in the billing XML. 
-  * The stylesheet uses the correct element names. 
-  * The ''xsl:for-each'' path matches the XML structure. 
-  * The ''xsl:value-of'' expressions match the required fields. 
-  * The stylesheet was designed for the current billing XML format. 
- 
-Example selection path: 
- 
-<code xml> 
-<xsl:for-each select="tapetrack_data/item"> 
-</code> 
- 
-==== Billing Values Are Incorrect ==== 
- 
-The stylesheet does not calculate billing values. 
- 
-Check the following billing inputs instead: 
  
-  * The ''.ttstats'' file. 
-  * The Customer Description Map. 
-  * The Package Map. 
-  * The Billing Rules. 
-  * The selected billing date range. 
  
-<WRAP important> 
-Changing ''tapetrack.xslt'' will not correct an incorrect quantity, unit cost or total stored in the billing XML. 
-</WRAP> 
  
-==== Desktop UI Does Not Load the XML ==== 
  
-Check that: 
  
-  * The billing XML is complete and valid. 
-  * The XML file has not been truncated. 
-  * The stylesheet is accessible. 
-  * The XML encoding is supported. 
-  * The XMLQuickBooks mapping matches the XML elements. 
-  * The Desktop UI has permission to read both files. 
  
 ===== Recommended Practices ===== ===== Recommended Practices =====
billing/stylesheet.1787021274.txt.gz · Last modified: 2026/08/18 02:47 by Scott Cunliffe