Skip to content
This repository has been archived by the owner on Apr 18, 2020. It is now read-only.

Commit

Permalink
Merge pull request #9 from linways/#7
Browse files Browse the repository at this point in the history
Multiple merges
  • Loading branch information
rohithb authored Jan 8, 2019
2 parents 8db254f + 1536c82 commit 49e5f09
Show file tree
Hide file tree
Showing 12 changed files with 45,484 additions and 18 deletions.
175 changes: 174 additions & 1 deletion dist/index.html
Original file line number Diff line number Diff line change
@@ -1 +1,174 @@
<html> <head> <style>table,td,th{border:1px solid;border-collapse:collapse}</style> </head> <body> <div id="wrapper"> <table id="simpleTable1" data-cols-width="70,15,10"> <tbody> <tr> <td colspan="5" data-f-sz="25" data-f-color="FFFFAA00" data-a-h="center" data-a-v="middle" data-f-underline="true"> Sample Excel </td> </tr> <tr> <td colspan="5" data-f-italic="true" data-a-h="center" data-f-name="Arial" data-a-v="top"> Italic and horizontal center in Arial </td> </tr> <tr> <th data-a-text-rotation="90">Col 1 (number)</th> <th data-a-text-rotation="vertical">Col 2</th> <th data-a-wrap="true">Wrapped Text</th> <th data-a-text-rotation="-45">Col 4 (date)</th> <th data-a-text-rotation="-90">Col 5</th> </tr> <tr> <td rowspan="1" data-t="n">1</td> <td rowspan="1" data-b-b-s="thick" data-b-l-s="thick" data-b-r-s="thick"> ABC1 </td> <td rowspan="1" data-f-strike="true">Striked Text</td> <td data-t="d">05-20-2018</td> <td data-t="n" data-num-fmt="$ 0.00">2210.00</td> </tr> <tr> <td rowspan="2" data-t="n">2</td> <td rowspan="2" data-fill-color="FFFF0000" data-f-color="FFFFFFFF"> ABC 2 </td> <td rowspan="2" data-a-indent="3">Merged cell</td> <td data-t="d">05-21-2018</td> <td data-t="n" data-b-a-s="dashed" data-num-fmt="$ 0.00">230.00</td> </tr> <tr> <td data-t="d">05-22-2018</td> <td data-t="n" data-num-fmt="$ 0.00">2493.00</td> </tr> <tr> <td colspan="4" align="right" data-f-bold="true" data-a-h="right" data-hyperlink="https://google.com"> <b><a href="https://google.com">Hyperlink</a></b> </td> <td colspan="1" align="right" data-t="n" data-f-bold="true" data-num-fmt="$ 0.00"> <b>4933.00</b> </td> </tr> <tr> <td colspan="4" align="right" data-f-bold="true" data-a-rtl="true"> مرحبا </td> <td colspan="1" align="right" data-t="n" data-f-bold="true" data-num-fmt="$ 0.00"> <b>2009.00</b> </td> </tr> <tr> <td data-b-a-s="dashed" data-b-a-c="FFFF0000">All borders</td> </tr> <tr> <td data-t="b">true</td> <td data-t="b">false</td> <td data-t="b">1</td> <td data-t="b">0</td> <td data-error="#VALUE!">Value Error</td> </tr> <tr> <td data-b-t-s="thick" data-b-l-s="thick" data-b-b-s="thick" data-b-r-s="thick" data-b-t-c="FF00FF00" data-b-l-c="FF00FF00" data-b-b-c="FF00FF00" data-b-r-c="FF00FF00"> All borders separately </td> </tr> <tr data-exclude="true"> <td>Excluded row</td> <td>Something</td> </tr> <tr> <td>Included Cell</td> <td data-exclude="true">Excluded Cell</td> <td>Included Cell</td> </tr> </tbody> </table> <button id="button-excel" onclick="exportExcel()">Create Excel</button> </div> <script src="/tableToExcel.ea9f68b1.js"></script> <script>function $s8z$var$exportExcel(){TableToExcel.convert(document.getElementById("simpleTable1"))}</script> </body> </html>
<html>
<head>
<style>table,
td,
th {
border: 1px solid;
border-collapse: collapse;
}</style>
</head>
<body>
<div id="wrapper">
<table id="simpleTable1" data-cols-width="70,15,10">
<tbody>
<tr>
<td colspan="5" data-f-sz="25" data-f-color="FFFFAA00" data-a-h="center" data-a-v="middle" data-f-underline="true">
Sample Excel
</td>
</tr>
<tr>
<td colspan="5" data-f-italic="true" data-a-h="center" data-f-name="Arial" data-a-v="top">
Italic and horizontal center in Arial
</td>
</tr>
<tr>
<th data-a-text-rotation="90">Col 1 (number)</th>
<th data-a-text-rotation="vertical">Col 2</th>
<th data-a-wrap="true">Wrapped Text</th>
<th data-a-text-rotation="-45">Col 4 (date)</th>
<th data-a-text-rotation="-90">Col 5</th>
</tr>
<tr>
<td rowspan="1" data-t="n">1</td>
<td rowspan="1" data-b-b-s="thick" data-b-l-s="thick" data-b-r-s="thick">
ABC1
</td>
<td rowspan="1" data-f-strike="true">Striked Text</td>
<td data-t="d">05-20-2018</td>
<td data-t="n" data-num-fmt="$ 0.00">2210.00</td>
</tr>

<tr>
<td rowspan="2" data-t="n">2</td>
<td rowspan="2" data-fill-color="FFFF0000" data-f-color="FFFFFFFF">
ABC 2
</td>
<td rowspan="2" data-a-indent="3">Merged cell</td>
<td data-t="d">05-21-2018</td>
<td data-t="n" data-b-a-s="dashed" data-num-fmt="$ 0.00">230.00</td>
</tr>
<tr>
<td data-t="d">05-22-2018</td>

<td data-t="n" data-num-fmt="$ 0.00">2493.00</td>
</tr>

<tr>
<td colspan="4" align="right" data-f-bold="true" data-a-h="right" data-hyperlink="https://google.com">
<b><a href="https://google.com">Hyperlink</a></b>
</td>
<td colspan="1" align="right" data-t="n" data-f-bold="true" data-num-fmt="$ 0.00">
<b>4933.00</b>
</td>
</tr>
<tr>
<td colspan="4" align="right" data-f-bold="true" data-a-rtl="true">
مرحبا
</td>
<td colspan="1" align="right" data-t="n" data-f-bold="true" data-num-fmt="$ 0.00">
<b>2009.00</b>
</td>
</tr>
<tr>
<td data-b-a-s="dashed" data-b-a-c="FFFF0000">All borders</td>
</tr>
<tr>
<td data-t="b">true</td>
<td data-t="b">false</td>
<td data-t="b">1</td>
<td data-t="b">0</td>
<td data-error="#VALUE!">Value Error</td>
</tr>
<tr>
<td data-b-t-s="thick" data-b-l-s="thick" data-b-b-s="thick" data-b-r-s="thick" data-b-t-c="FF00FF00" data-b-l-c="FF00FF00" data-b-b-c="FF00FF00" data-b-r-c="FF00FF00">
All borders separately
</td>
</tr>
<tr data-exclude="true">
<td>Excluded row</td>
<td>Something</td>
</tr>
<tr>
<td>Included Cell</td>
<td data-exclude="true">Excluded Cell</td>
<td>Included Cell</td>
</tr>
</tbody>
</table>

<button id="button-excel" onclick="exportExcel()">Create Excel</button>

<table id="sampletable2" border="1">
<tr>
<th colspan="6" data-b-a-s="thin" data-a-h="center" data-f-bold="true">
Things
</th>
</tr>
<tr>
<th colspan="2">Letters</th>
<th colspan="2">Numbers</th>
<th colspan="2">Sp chars</th>
</tr>
<tr>
<td rowspan="2">A</td>
<td>B</td>
<td>1</td>
<td>2</td>
<td>*</td>
<td>#</td>
</tr>
<tr>
<td>Y</td>
<td>3</td>
<td>4</td>
<td>$</td>
<td>%</td>
</tr>
<tr>
<td rowspan="2">C</td>
<td>B</td>
<td>1</td>
<td>2</td>
<td>*</td>
<td>#</td>
</tr>
<tr>
<td>Y</td>
<td>3</td>
<td>4</td>
<td>$</td>
<td>%</td>
</tr>
<tr>
<td rowspan="2">D</td>
<td>B</td>
<td>1</td>
<td>2</td>
<td>*</td>
<td>#</td>
</tr>
<tr>
<td>Y</td>
<td>3</td>
<td>4</td>
<td>$</td>
<td>%</td>
</tr>
</table>

<br>
<button id="toExcel">Convert to Excel table 2</button>
</div>
<script src="/tableToExcel.517b1af9.js"></script>

<script>function exportExcel() {
TableToExcel.convert(document.getElementById("simpleTable1"));
}

var button = document.querySelector("#toExcel");
button.addEventListener("click", function (e) {
var table = document.querySelector("#sampletable2");
TableToExcel.convert(table);
});</script>
</body>
</html>
Loading

0 comments on commit 49e5f09

Please sign in to comment.