From f66d0e1200ca1f71000ce9a294e20e6f136530e4 Mon Sep 17 00:00:00 2001 From: samuel bonilla Date: Sun, 1 Dec 2013 11:37:29 -0500 Subject: [PATCH] Update buttons.py 'dict' object has no attribute 'is_mobile'" --- applications/admin/models/buttons.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/applications/admin/models/buttons.py b/applications/admin/models/buttons.py index 41c8d7d2..67d9ec92 100644 --- a/applications/admin/models/buttons.py +++ b/applications/admin/models/buttons.py @@ -24,7 +24,7 @@ def button_enable(href, app): return A(label, _class='button btn', _id=id, callback=href, target=id) def sp_button(href, label): - if request.user_agent().is_mobile: + if request.user_agent().get('is_mobile'): ret = A_button(SPAN(label), _href=href) else: ret = A(SPAN(label), _class='button special btn btn-inverse', _href=href) @@ -37,4 +37,4 @@ def searchbox(elementid): return SPAN(LABEL(IMG(_id="search_start", _src=URL('static', 'images/search.png'), _alt=T('filter')), _class='icon', _for=elementid), ' ', INPUT(_id=elementid, _type='text', _size=12, _class="input-medium"), - _class="searchbox") \ No newline at end of file + _class="searchbox")