meteor-tabular
meteor-tabular copied to clipboard
Different selectors on same template
Hi, on my template i'm rendering my table two times but with different selectors
<template name="ferias">
{{> tabular table=TabularTables.Ferias selector=coletiva class="table table-striped table-bordered table-hover" id="feriasColetivasDT" width="100%"}}
{{> tabular table=TabularTables.Ferias selector=pessoal class="table table-striped table-bordered table-hover" id="feriasPessoaisDT" width="100%"}}
</template>
Template.ferias.helpers({
coletiva: function(){
return {tipo:'coletiva'};
},
pessoal:function(){
return {tipo:'pessoal'};
}
})
Both tables are using the 'coletiva' selector for a strange reason...
I intended to support rendering two instances at once but I've never tested it. I will have to test and fix.
So the workaround for now would be declaring 2 different tabular instances?
Yes probably. I will leave this issue open to investigate a fix.
I'd throw a +1 in the ring for this too. I need to support multiple levels of drilldown all against the same datasource (unknown # of levels). It sounds like it won't be possible right now though. Thanks for a great product!
I am also having issues with this, any recommendation?
+1 would be very useful to be able to show multiple instances with different selectors in a template.
+1
+1
+1
+1
Same problem also with two different tabular instances (with same collection), but my error was to use the same name for the two different instances of Tabular.Table, with two different names now it works well:
TabularTables.Projects = new Tabular.Table({
name: "MyProjects",