<table class="tree table table-condensed table-hover table-bordered table-responsive" id="treegridTable">
  <thead>
    <tr>
      <th></th>
      <th>Q3 2016</th>
      <th>Q2 2016</th>
      <th>Q1 2016</th>
      <th>Q4 2015</th>
      <th>Q3 2015</th>
      <th>Q2 2015</th>
    </tr>
  </thead>
  <tbody>
    <tr class="treegrid-1 root-node">
      <td>Assets</td>
    </tr>
    <tr class="treegrid-2 treegrid-parent-1 node">
      <td>Current Assets</td>
      <td>72,088</td>
      <td>99,127</td>
      <td>106,744</td>
      <td>209,245</td>
      <td>208,533</td>
      <td>224,877</td>
    </tr>
    <tr class="treegrid-parent-2">
      <td>Cash and cash equivalents</td>
      <td>33,774</td>
      <td>68,896</td>
      <td>53,365</td>
      <td>148,013</td>
      <td></td>
      <td></td>
    </tr>
    <tr class="treegrid-parent-2">
      <td>Revenue receivable</td>
      <td>11,850</td>
      <td>6,452</td>
      <td>7,318</td>
      <td>6,476</td>
      <td></td>
      <td></td>
    </tr>
    <tr class="treegrid-parent-2">
      <td>Joint interest billing receivable</td>
      <td>22,217</td>
      <td>18,560</td>
      <td>38,665</td>
      <td>49,374</td>
      <td></td>
      <td></td>
    </tr>
    <tr class="treegrid-parent-2">
      <td>Derivative asset</td>
      <td></td>
      <td></td>
      <td>1,277</td>
      <td>1,508</td>
      <td></td>
      <td></td>
    </tr>
    <tr class="treegrid-parent-2">
      <td>Other current assets</td>
      <td>4,247</td>
      <td>5,219</td>
      <td>6,119</td>
      <td>3,874</td>
      <td></td>
      <td></td>
    </tr>
    <tr class="treegrid-3 treegrid-parent-1 node">
      <td>Plant and equipment (less depriciation)</td>
      <td>96,735</td>
      <td>102,923</td>
      <td>138,616</td>
      <td>168,444</td>
      <td>223,509</td>
      <td>272,667</td>
    </tr>
    <tr class="treegrid-parent-3">
      <td>Oil and gas properties, net</td>
      <td>95,682</td>
      <td>101,686</td>
      <td>136,289</td>
      <td>165,952</td>
      <td></td>
      <td></td>
    </tr>
    <tr class="treegrid-parent-3">
      <td>Other property and equipment net</td>
      <td>1,053</td>
      <td>1,237</td>
      <td>2,327</td>
      <td>2,492</td>
      <td></td>
      <td></td>
    </tr>
    <tr class="treegrid-4 treegrid-parent-1 node">
      <td>Other assets (less depriciation)</td>
      <td>5,546</td>
      <td>6,674</td>
      <td>1,533</td>
      <td>1,630</td>
      <td>4,929</td>
      <td>4,929</td>
    </tr>
    <tr class="treegrid-parent-1 table-footer">
      <td>Total Assets</td>
      <td>$174,369</td>
      <td>$208,724</td>
      <td>$246,893</td>
      <td>$379,319</td>
      <td>$436,971</td>
      <td>$503,072</td>
    </tr>
    <tr class="treegrid-5 root-node">
      <td>LIABILITIES AND STOCKHOLDERS’ EQUITY</td>
    </tr>
    <tr class="treegrid-6 treegrid-parent-5 node">
      <td>Current liabilities</td>
      <td>85,687</td>
      <td>99,380</td>
      <td>116,422</td>
      <td>158,784</td>
      <td>139,439</td>
      <td>139,439</td>
    </tr>
    <tr class="treegrid-parent-6">
      <td>Accounts payable to vendors</td>
      <td>46,166</td>
      <td>54,379</td>
      <td>76,815</td>
      <td>97,999</td>
      <td></td>
      <td></td>
    </tr>
    <tr class="treegrid-parent-6">
      <td>Advances from co-owners</td>
      <td>377</td>
      <td>577</td>
      <td>4,097</td>
      <td>16,118</td>
      <td></td>
      <td></td>
    </tr>
    <tr class="treegrid-parent-6">
      <td>Oil and gas revenue payable</td>
      <td>29,906</td>
      <td>29,386</td>
      <td>23,108</td>
      <td>18,911</td>
      <td></td>
      <td></td>
    </tr>
    <tr class="treegrid-parent-6">
      <td>Accrued interest and preffered stock divident</td>
      <td>397</td>
      <td>9,938</td>
      <td>2,942</td>
      <td>11,720</td>
      <td></td>
      <td></td>
    </tr>
    <tr class="treegrid-parent-6">
      <td>Asset retirement obligation</td>
      <td>1,132</td>
      <td>1,496</td>
      <td>5,545</td>
      <td>6,015</td>
      <td></td>
      <td></td>
    </tr>
    <tr class="treegrid-parent-6">
      <td>Derivative liability</td>
      <td>228</td>
      <td>473</td>
      <td></td>
      <td></td>
      <td></td>
      <td></td>
    </tr>
    <tr class="treegrid-parent-6">
      <td>Accrued acquisition costs</td>
      <td>5,000</td>
      <td></td>
      <td></td>
      <td></td>
      <td></td>
      <td></td>
    </tr>
    <tr class="treegrid-parent-6">
      <td>Other accrued liabilities</td>
      <td>2,481</td>
      <td>3,131</td>
      <td>3,915</td>
      <td>3,612</td>
      <td></td>
      <td></td>
    </tr>
    <tr class="treegrid-7 treegrid-parent-5 node">
      <td>Long term liabilities (long term debt)</td>
      <td>280,930</td>
      <td>291,290</td>
      <td>291,622</td>
      <td>347,008</td>
      <td>350,000</td>
      <td>350,000</td>
    </tr>
    <tr class="treegrid-parent-7">
      <td>10% Senior Notes due</td>
      <td>280,930</td>
      <td>291,290</td>
      <td>291,622</td>
      <td>347,008</td>
      <td></td>
      <td></td>
    </tr>
    <tr class="treegrid-8 treegrid-parent-5 node">
      <td>Commitments and contingencies</td>
      <td>280,930</td>
      <td>291,290</td>
      <td>291,622</td>
      <td>347,008</td>
      <td></td>
      <td></td>
    </tr>
    <tr class="treegrid-9 treegrid-parent-5 node">
      <td>Other long-term obligations</td>
      <td>44,562</td>
      <td>42,656</td>
      <td>38,504</td>
      <td>36,594</td>
      <td>43,613</td>
      <td>53,728</td>
    </tr>
    <tr class="treegrid-parent-9">
      <td>Asset retirement obligation</td>
      <td>40,593</td>
      <td>39,986</td>
      <td>37,155</td>
      <td>36,541</td>
      <td></td>
      <td></td>
    </tr>
    <tr class="treegrid-parent-9">
      <td>Other long-term liabilities</td>
      <td>3,969</td>
      <td>2,670</td>
      <td>1,349</td>
      <td>53</td>
      <td></td>
      <td></td>
    </tr>
    <tr class="treegrid-10 treegrid-parent-5 node">
      <td>Preferred stock</td>
      <td>1</td>
      <td>1</td>
      <td>1</td>
      <td>1</td>
      <td>1</td>
      <td>1</td>
    </tr>
    <tr class="treegrid-11 treegrid-parent-5 node">
      <td>Common stock</td>
      <td>21</td>
      <td>18</td>
      <td>70</td>
      <td>16</td>
      <td>65</td>
      <td>65</td>
    </tr>
    <tr class="treegrid-12 treegrid-parent-5 node">
      <td>Paid-in capital</td>
      <td>304,445</td>
      <td>293,595</td>
      <td>293,072</td>
      <td>290,432</td>
      <td>290,066</td>
      <td>288,767</td>
    </tr>
    <tr class="treegrid-12 treegrid-parent-5 node">
      <td>Other adjustments</td>
      <td>-541277</td>
      <td>-518216</td>
      <td>-492798</td>
      <td>-453516</td>
      <td>-386213</td>
      <td>-334293</td>
    </tr>
    <tr class="treegrid-parent-5 table-footer">
      <td>Total liabilities and stockholders’ equity</td>
      <td>174,369</td>
      <td>208,724</td>
      <td>246,893</td>
      <td>379,319</td>
      <td>436,971</td>
      <td>503,072</td>
    </tr>
  </tbody>
</table>
.root-node, .node, .table-footer {
  font-weight: bold;
}

.button-default{
  display: none;
}
/* Defaults */
$("table").tableExport({
    headings: true,                    // (Boolean), display table headings (th/td elements) in the <thead>
    footers: true,                     // (Boolean), display table footers (th/td elements) in the <tfoot>
    formats: ["xls", "csv", "txt"],    // (String[]), filetypes for the export
    fileName: "id",                    // (id, String), filename for the downloaded file
    bootstrap: true,                   // (Boolean), style buttons using bootstrap
    position: "bottom",                 // (top, bottom), position of the caption element relative to table
    ignoreRows: null,                  // (Number, Number[]), row indices to exclude from the exported files
    ignoreCols: null,                  // (Number, Number[]), column indices to exclude from the exported file(s)
    ignoreCSS: ".tableexport-ignore",  // (selector, selector[]), selector(s) to exclude from the exported file(s)
    emptyCSS: ".tableexport-empty",    // (selector, selector[]), selector(s) to replace cells with an empty string in the exported file(s)
    trimWhitespace: false              // (Boolean), remove all leading/trailing newlines, spaces, and tabs from cell text in the exported file(s)
});

External CSS

  1. https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css
  2. https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/4.0.0-alpha.6/css/bootstrap.min.css
  3. https://unpkg.com/tableexport@5.1.0/dist/css/tableexport.min.css

External JavaScript

  1. https://cdnjs.cloudflare.com/ajax/libs/jquery/3.1.1/jquery.min.js
  2. https://fastcdn.org/FileSaver.js/1.1.20151003/FileSaver.min.js
  3. https://unpkg.com/tableexport@5.1.0/dist/js/tableexport.min.js