Hi everybody!!
I'm using powertable plugin for a simple app I have the following:
(Model)
db.define_table('location',
Field('name','string'),format='%(name)s')
db.define_table('car',
Field('name','string'),
Field('model','string'),
Field('location_id',db.location),
Field('price','string'),
Field('status','string'),
Field('owner','string'),
Field('phone','string'),
Field('comments','text'),,format='%(name)s')
(Controller init/default)
def index():
powerTable = plugins.powerTable
powerTable.datasource = db.car
powerTable.dtfeatures['sScrollY'] = '338'
powerTable.dtfeatures['sScrollX'] = '100%'
powerTable.headers = 'labels'
powerTable.showkeycolumn = False
powerTable.dtfeatures['bJQueryUI'] =
request.vars.get('jqueryui',True)
powerTable.uitheme =
request.vars.get('theme','smoothness')#'smoothness'
powerTable.dtfeatures['sPaginationType'] =
request.vars.get('pager','scrolling') # two_button full_numbers
powerTable.keycolumn = 'car.id'
powerTable.columns = ['car.name',
'car.model',
'car.location_id',
'car.price',
'car.status'
]
powerTable.extrajs = dict(autoresize={},
details={'detailscolumns':'car.owner,\
car.phone,\
car.comments'
})
return dict(table=powerTable.create())
(View init/default/index)
{{extend 'layout.html'}}
<center><h2>Welcome test app</h2></center>
{{=table}}
This is the issue: when I type in the browser 127.0.0.1 the details
"+" button image doesn't work and if I click on the broken image,
nothing happens but if I type 127.0.0.1/init/default/index everything
works fine! How can I solve it?, I need the power table plugin as the
welcome page.
Thanks!