editor works again when is_mobile=True (No tabs when is mobile)

This commit is contained in:
ilvalle
2013-10-17 16:10:53 +02:00
parent c91e6160fe
commit 580bc6fd6e
2 changed files with 42 additions and 46 deletions
+5 -2
View File
@@ -568,7 +568,7 @@ def edit():
section='editor', default_values=editor_defaults)
preferences = config.read()
if not(request.ajax):
if not(request.ajax) and not(is_mobile):
# return the scaffolding, the rest will be through ajax requests
response.title = T('Editing %s') % app
editarea_preferences = {}
@@ -769,7 +769,10 @@ def edit():
force= True if (request.vars.restore or request.vars.revert) else False)
plain_html = response.render('default/edit_js.html', file_details)
file_details['plain_html'] = plain_html
return response.json(file_details)
if is_mobile:
return response.render('default.mobile/edit.html', file_details, editor_settings=preferences)
else:
return response.json(file_details)
def resolve():