200 likes | 405 Views
XBRL & XSLT - 2013S -. Clinton E. White, Jr Professor of Accounting & MIS Lerner College of B&E University of Delaware. Exercise 4-2. Frequent mistakes: Only one context element Each one must start with a letter No total tags Include all financial statement items
E N D
XBRL & XSLT- 2013S - Clinton E. White, Jr Professor of Accounting & MIS Lerner College of B&E University of Delaware
Exercise 4-2 • Frequent mistakes: • Only one context element • Each one must start with a letter • No total tags • Include all financial statement items • Used “duration” in period element • Element found in weird part of taxonomy • ResultsOfOperationsIncomeTaxExpense • In “Extractive Industries” • Instance document not well-formed • Do not turn in an untested xml/xbrl document
Elements • Selecting elements to tag a financial statement item: • What did you use for the income stmt items: • Net sales • Interest income • Income before taxes • Provision for income taxes • Net income
XSLT • The Extensible Stylesheet Language: • A “template matching” language • The “template” element: • Contains “rules/instructions” to apply when an element or node set is matched in the source document • The “match” attribute: • Associates the template with an element/node set • The “value-of” element: • Extracts the value of a selected node • The “select” attribute is an XPath expression • The “for-each” element: • Is used to select every element in a node set • It “loops” through a node set
A UBL Catalogue Node Tree + Provider Party + Receiver Party + Catalogue Line ID Name IssueDate Catalogue
Numeric Functions • “sum( node set )” • “format-number( item , ‘pattern’)” • ‘$#,###’ ‘#,###.00’ etc. • <xsl:value-of select= “sum(//Cost)” /> • <xsl:value-of select= • “format-number(sum(//Cost), ‘$#.00’)” /> • http://www.w3schools.com/xsl/default.asp
For Exercise 5-3 • MyBikes preferred labels: • Each XBRL item has a standard label • All companies have their own preferred labels and extend the XBRL taxonomy by adding them to the Labels linkbase • Create a Labels.xml file containing MyBikes.com’s preferred labels
MyBikesLabels.xml • A standard XBRL instance document • All labels and footnote disclosures are considered to apply for the entire reporting period • Use a duration/period of time in your context element • Add a label attribute with your preferred label to each XBRL element • <us-gaap:ShortTermInvestmentslabel="Short-term investments"contextRef="YearEnded2012"/>
XSLT Code • 2 source documents: • Your XBRL financials instance document • The primary source document (contains the xml-stylesheet instruction) • Your MyBikesLabels.xml instance document • The secondary (remote) source document • For each line item: • <TR> • <TD><xsl:value-ofselect="document('MyBikesLabels.xml') //us-gaap:ShortTermInvestments/@label"/></TD> • <TD align="right"> <xsl:value-of select="format-number (//us-gaap:ShortTermInvestments, '#,##0')"/></TD> • </TR>
XSLT/XBRL Financials XBRL Instance document XML Processor XML Result document XSLT Instructions XBRL Labels linkbase
Footnote/disclosure Tagging • Level 1 • Block tagging • [Text Block] elements • Must be formatted so that when rendered, it appears exactly the same as in the filing
Footnote/disclosure Tagging • Level 2 • Tagging specific policies within the Significant Accounting Policies note • [Policy Text Block] elements • Must be formatted so that when rendered, it appears exactly the same as in the filing
Footnote/disclosure Tagging • Level 3 • Tagging an entire table/schedule • [Table Text Block] elements • Must be formatted so that when rendered, it appears exactly the same as in the filing • Level 4 • Tagging each monetary value, percentage, and number in each footnote as a reported fact
Revenue Recognition • Significant accounting policies: • Trade and accounts receivable policy: • The Company sells a wide range of products to a diversified base of customers around the world and accepts payments in a number of forms. The Current receivables, net reported on the balance sheet includes an adjustment of $6,000 for estimated uncollectable accounts. • Property, plant and equipment depreciation policy: • The Company uses a straight line depreciation methodology for property, plant and equipment. The accumulated depreciation as of 12/31/2012 is $24,000.
Assignment (Due 4/14/2013) • Exercise 5-3 • Start with the posted financials (Ex. 4-2) • Add the level 2 disclosures (Ex. 4-3) • Create the Labels.xml file • Create the XSLT file to do the transformation • Add your name in a comment line • Turn in all 3 files