I'm having a bit of trouble figuring out how to add info to a bootstrap table in a panel, through ajax.This's a phone call register system and I have the following code in the html:
resumoMensal.html <table class="table table-condensed table-striped" style="border-collapse:collapse;"> <tbody> <tr data-toggle="collapse" data-target="#demo3" class="accordion-toggle"> <td><button class="btn btn-default btn-xs"><span class="glyphicon glyphicon-eye-open"></span></button><htext2><b>  Extensions</b></htext2></td> <td></td> </tr> <tr> <td colspan="6" class="hiddenRow"><div class="accordian-body collapse" id="demo3"> <table class="table table-striped"> <thead> {{for x in extension:}} <tr><td></td><td><htext><b>{{=x.Extension}}</b></htext></td></tr> {{pass}} </thead> </table> </div> </td> </tr> <tr data-toggle="collapse" data-target="#demo1" class="accordion-toggle"> <td><button class="btn btn-default btn-xs"><span class="glyphicon glyphicon-eye-open"></span></button><htext2><b>  Total Cost</b></htext2></td> {{if total_cost["_extra"]["SUM(Call.Cost)"]!=None:}} <td><htext2><b>€{{=total_cost["_extra"]["SUM(Call.Cost)"]}}</b></htext2></td> {{else:}} <td><htext2><b>€0</b></htext2></td> {{pass}} </tr> <tr> <td colspan="6" class="hiddenRow"><div class="accordian-body collapse" id="demo1"> <table class="table table-striped"> <thead> {{for x in cost_types:}} <tr><td></td><td></td><td><htext><b>{{=x["Call"]["Type_service"]}}</b></htext></td><td></td><td></td><td></td><td></td><td><htext>€{{=x["_extra"]["SUM(Call.Cost)"]}}</htext></td></tr> {{pass}} </thead> </table> </div> </td> </tr> <tr data-toggle="collapse" data-target="#demo2" class="accordion-toggle"> <td><button class="btn btn-default btn-xs"><span class="glyphicon glyphicon-eye-open"></span></button><htext2><b>  Total (min)</b></htext2></td> {{if min_total["_extra"]["SUM(Call.Duration)"]!=None:}} <td><htext2><b>{{=min_total["_extra"]["SUM(Call.Duration)"]}}</b></htext2></td> {{else:}} <td><htext2><b>0</b></htext2></td> {{pass}} </tr> <tr> <td colspan="6" class="hiddenRow"><div id="demo2" class="accordian-body collapse"> <table class="table table-striped"> <thead> {{for x in cost_type:}} <tr><td></td><td></td><td><htext><b>{{=x["Call"]["Type_service"]}} (min)</b></htext></td><td></td><td></td><td></td><td><htext>{{=x["_extra"]["SUM(Call.Duration)"]}}</htext></td></tr> {{pass}} </thead> </table> </div> </td> </tr> </tbody> </table> When you click a certain link, the username, month and year is passed through as vars.Something along the lines of /resumoMensal?year=2015&month=April&name=John . After that, the What I want to do is exactly this: db is queried for the appropriate info(total cost,call duration,etc.,like represented in the code above) and through ajax I want to add the values retrieved, and display them in each of the td. How can I accomplish this? -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list (Report Issues) --- You received this message because you are subscribed to the Google Groups "web2py-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to web2py+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.