Issue with Tabulator js library working with Column Grouping properties












4














I have this structure of html table



<thead>
<tr>
<th rowspan="2">Type</th>
<th rowspan="2">Name</th>
<th rowspan="2">Iteration ID</th>
<th colspan="2">Script</th>
<th rowspan="2">Action</th>
</tr>
<tr>
<th>Init</th>
<th>Post</th>
</tr>
</thead>


and how it's look like



enter image description here



but should be as:



enter image description here
my js code



$(document).ready(function () {
var table = new Tabulator("#table-test", {});
});


add codepen reference
codepen.io/paulch/pen/MzQYjg










share|improve this question
























  • Can you create a JSFiddle?
    – Lajos Arpad
    Nov 21 '18 at 11:38










  • @LajosArpad add exampe codepen.io/paulch/pen/MzQYjg
    – Paul Chechegov
    Nov 21 '18 at 12:50


















4














I have this structure of html table



<thead>
<tr>
<th rowspan="2">Type</th>
<th rowspan="2">Name</th>
<th rowspan="2">Iteration ID</th>
<th colspan="2">Script</th>
<th rowspan="2">Action</th>
</tr>
<tr>
<th>Init</th>
<th>Post</th>
</tr>
</thead>


and how it's look like



enter image description here



but should be as:



enter image description here
my js code



$(document).ready(function () {
var table = new Tabulator("#table-test", {});
});


add codepen reference
codepen.io/paulch/pen/MzQYjg










share|improve this question
























  • Can you create a JSFiddle?
    – Lajos Arpad
    Nov 21 '18 at 11:38










  • @LajosArpad add exampe codepen.io/paulch/pen/MzQYjg
    – Paul Chechegov
    Nov 21 '18 at 12:50
















4












4








4







I have this structure of html table



<thead>
<tr>
<th rowspan="2">Type</th>
<th rowspan="2">Name</th>
<th rowspan="2">Iteration ID</th>
<th colspan="2">Script</th>
<th rowspan="2">Action</th>
</tr>
<tr>
<th>Init</th>
<th>Post</th>
</tr>
</thead>


and how it's look like



enter image description here



but should be as:



enter image description here
my js code



$(document).ready(function () {
var table = new Tabulator("#table-test", {});
});


add codepen reference
codepen.io/paulch/pen/MzQYjg










share|improve this question















I have this structure of html table



<thead>
<tr>
<th rowspan="2">Type</th>
<th rowspan="2">Name</th>
<th rowspan="2">Iteration ID</th>
<th colspan="2">Script</th>
<th rowspan="2">Action</th>
</tr>
<tr>
<th>Init</th>
<th>Post</th>
</tr>
</thead>


and how it's look like



enter image description here



but should be as:



enter image description here
my js code



$(document).ready(function () {
var table = new Tabulator("#table-test", {});
});


add codepen reference
codepen.io/paulch/pen/MzQYjg







javascript html tabulator






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Nov 21 '18 at 13:31

























asked Nov 21 '18 at 10:28









Paul Chechegov

7918




7918












  • Can you create a JSFiddle?
    – Lajos Arpad
    Nov 21 '18 at 11:38










  • @LajosArpad add exampe codepen.io/paulch/pen/MzQYjg
    – Paul Chechegov
    Nov 21 '18 at 12:50




















  • Can you create a JSFiddle?
    – Lajos Arpad
    Nov 21 '18 at 11:38










  • @LajosArpad add exampe codepen.io/paulch/pen/MzQYjg
    – Paul Chechegov
    Nov 21 '18 at 12:50


















Can you create a JSFiddle?
– Lajos Arpad
Nov 21 '18 at 11:38




Can you create a JSFiddle?
– Lajos Arpad
Nov 21 '18 at 11:38












@LajosArpad add exampe codepen.io/paulch/pen/MzQYjg
– Paul Chechegov
Nov 21 '18 at 12:50






@LajosArpad add exampe codepen.io/paulch/pen/MzQYjg
– Paul Chechegov
Nov 21 '18 at 12:50














1 Answer
1






active

oldest

votes


















0














Tabulator currently cannot interpret grouped columns from HTML, it does not recognise the colspan or rowspan attributes (this is on the roadmap for a future release)



You would need to declare the columns in the constructor object and then parse in the table:



Tabulator("#table-test", {
columns:[
{
title:"",
columns:[
{title:"Type", field:"Type"},
{title:"Name", field:"Name"},
{title:"Iteration ID", field:"Iteration ID"},
],
},
{
title:"Script",
columns:[
{title:"Init", field:"Init"},
{title:"Post", field:"Post"},

],
},
{title:"Action", field:"Action"},
]
});


When taking this approach i would suggest that you then only have one row of headers in your actual HTML table to make it easier for Tabulator to parse in the data






share|improve this answer





















  • yeah, but it's really inconvenient. And I created my html page on java project and send to user as a string, and browser should parse this. And I haven't some UI framework, only js, jquery. I think, maybe, for me to use this framework is bad idea. But thank you for you answer.
    – Paul Chechegov
    Nov 23 '18 at 9:42











Your Answer






StackExchange.ifUsing("editor", function () {
StackExchange.using("externalEditor", function () {
StackExchange.using("snippets", function () {
StackExchange.snippets.init();
});
});
}, "code-snippets");

StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "1"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});

function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});


}
});














draft saved

draft discarded


















StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53410045%2fissue-with-tabulator-js-library-working-with-column-grouping-properties%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown

























1 Answer
1






active

oldest

votes








1 Answer
1






active

oldest

votes









active

oldest

votes






active

oldest

votes









0














Tabulator currently cannot interpret grouped columns from HTML, it does not recognise the colspan or rowspan attributes (this is on the roadmap for a future release)



You would need to declare the columns in the constructor object and then parse in the table:



Tabulator("#table-test", {
columns:[
{
title:"",
columns:[
{title:"Type", field:"Type"},
{title:"Name", field:"Name"},
{title:"Iteration ID", field:"Iteration ID"},
],
},
{
title:"Script",
columns:[
{title:"Init", field:"Init"},
{title:"Post", field:"Post"},

],
},
{title:"Action", field:"Action"},
]
});


When taking this approach i would suggest that you then only have one row of headers in your actual HTML table to make it easier for Tabulator to parse in the data






share|improve this answer





















  • yeah, but it's really inconvenient. And I created my html page on java project and send to user as a string, and browser should parse this. And I haven't some UI framework, only js, jquery. I think, maybe, for me to use this framework is bad idea. But thank you for you answer.
    – Paul Chechegov
    Nov 23 '18 at 9:42
















0














Tabulator currently cannot interpret grouped columns from HTML, it does not recognise the colspan or rowspan attributes (this is on the roadmap for a future release)



You would need to declare the columns in the constructor object and then parse in the table:



Tabulator("#table-test", {
columns:[
{
title:"",
columns:[
{title:"Type", field:"Type"},
{title:"Name", field:"Name"},
{title:"Iteration ID", field:"Iteration ID"},
],
},
{
title:"Script",
columns:[
{title:"Init", field:"Init"},
{title:"Post", field:"Post"},

],
},
{title:"Action", field:"Action"},
]
});


When taking this approach i would suggest that you then only have one row of headers in your actual HTML table to make it easier for Tabulator to parse in the data






share|improve this answer





















  • yeah, but it's really inconvenient. And I created my html page on java project and send to user as a string, and browser should parse this. And I haven't some UI framework, only js, jquery. I think, maybe, for me to use this framework is bad idea. But thank you for you answer.
    – Paul Chechegov
    Nov 23 '18 at 9:42














0












0








0






Tabulator currently cannot interpret grouped columns from HTML, it does not recognise the colspan or rowspan attributes (this is on the roadmap for a future release)



You would need to declare the columns in the constructor object and then parse in the table:



Tabulator("#table-test", {
columns:[
{
title:"",
columns:[
{title:"Type", field:"Type"},
{title:"Name", field:"Name"},
{title:"Iteration ID", field:"Iteration ID"},
],
},
{
title:"Script",
columns:[
{title:"Init", field:"Init"},
{title:"Post", field:"Post"},

],
},
{title:"Action", field:"Action"},
]
});


When taking this approach i would suggest that you then only have one row of headers in your actual HTML table to make it easier for Tabulator to parse in the data






share|improve this answer












Tabulator currently cannot interpret grouped columns from HTML, it does not recognise the colspan or rowspan attributes (this is on the roadmap for a future release)



You would need to declare the columns in the constructor object and then parse in the table:



Tabulator("#table-test", {
columns:[
{
title:"",
columns:[
{title:"Type", field:"Type"},
{title:"Name", field:"Name"},
{title:"Iteration ID", field:"Iteration ID"},
],
},
{
title:"Script",
columns:[
{title:"Init", field:"Init"},
{title:"Post", field:"Post"},

],
},
{title:"Action", field:"Action"},
]
});


When taking this approach i would suggest that you then only have one row of headers in your actual HTML table to make it easier for Tabulator to parse in the data







share|improve this answer












share|improve this answer



share|improve this answer










answered Nov 22 '18 at 22:07









Oli Folkerd

1,09211115




1,09211115












  • yeah, but it's really inconvenient. And I created my html page on java project and send to user as a string, and browser should parse this. And I haven't some UI framework, only js, jquery. I think, maybe, for me to use this framework is bad idea. But thank you for you answer.
    – Paul Chechegov
    Nov 23 '18 at 9:42


















  • yeah, but it's really inconvenient. And I created my html page on java project and send to user as a string, and browser should parse this. And I haven't some UI framework, only js, jquery. I think, maybe, for me to use this framework is bad idea. But thank you for you answer.
    – Paul Chechegov
    Nov 23 '18 at 9:42
















yeah, but it's really inconvenient. And I created my html page on java project and send to user as a string, and browser should parse this. And I haven't some UI framework, only js, jquery. I think, maybe, for me to use this framework is bad idea. But thank you for you answer.
– Paul Chechegov
Nov 23 '18 at 9:42




yeah, but it's really inconvenient. And I created my html page on java project and send to user as a string, and browser should parse this. And I haven't some UI framework, only js, jquery. I think, maybe, for me to use this framework is bad idea. But thank you for you answer.
– Paul Chechegov
Nov 23 '18 at 9:42


















draft saved

draft discarded




















































Thanks for contributing an answer to Stack Overflow!


  • Please be sure to answer the question. Provide details and share your research!

But avoid



  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.


To learn more, see our tips on writing great answers.





Some of your past answers have not been well-received, and you're in danger of being blocked from answering.


Please pay close attention to the following guidance:


  • Please be sure to answer the question. Provide details and share your research!

But avoid



  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.


To learn more, see our tips on writing great answers.




draft saved


draft discarded














StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53410045%2fissue-with-tabulator-js-library-working-with-column-grouping-properties%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown







Popular posts from this blog

Wiesbaden

Marschland

Dieringhausen