[Mobile] Go to editing mode from toolbar
This commit is contained in:
parent
8cb2861691
commit
291128cad7
|
@ -34,6 +34,9 @@
|
|||
<a href="#" id="toolbar-add" class="link icon-only" style="display: none;">
|
||||
<i class="icon icon-plus"></i>
|
||||
</a>
|
||||
<a href="#" id="toolbar-edit-document" class="link icon-only" style="display: none;">
|
||||
<i class="icon icon-edit"></i>
|
||||
</a>
|
||||
<% if (!phone) { %>
|
||||
<a href="#" id="toolbar-search" class="link icon-only">
|
||||
<i class="icon icon-search"></i>
|
||||
|
|
|
@ -62,7 +62,8 @@ define([
|
|||
"click #toolbar-search" : "searchToggle",
|
||||
"click #toolbar-edit" : "showEdition",
|
||||
"click #toolbar-add" : "showInserts",
|
||||
"click #toolbar-settings" : "showSettings"
|
||||
"click #toolbar-settings" : "showSettings",
|
||||
"click #toolbar-edit-document": "editDocument"
|
||||
},
|
||||
|
||||
// Set innerHTML and get the references to the DOM elements
|
||||
|
@ -100,6 +101,8 @@ define([
|
|||
setMode: function (mode) {
|
||||
if (mode.isEdit) {
|
||||
$('#toolbar-edit, #toolbar-add, #toolbar-undo, #toolbar-redo').show();
|
||||
} else if (mode.canEdit && mode.canRequestEditRights){
|
||||
$('#toolbar-edit-document').show();
|
||||
}
|
||||
},
|
||||
|
||||
|
@ -147,6 +150,10 @@ define([
|
|||
DE.getController('Settings').showModal();
|
||||
},
|
||||
|
||||
editDocument: function () {
|
||||
Common.Gateway.requestEditRights();
|
||||
},
|
||||
|
||||
textBack: 'Back'
|
||||
}
|
||||
})(), DE.Views.Toolbar || {}))
|
||||
|
|
|
@ -37,6 +37,9 @@
|
|||
<a href="#" id="toolbar-add" class="link icon-only" style="display: none;">
|
||||
<i class="icon icon-plus"></i>
|
||||
</a>
|
||||
<a href="#" id="toolbar-edit-document" class="link icon-only" style="display: none;">
|
||||
<i class="icon icon-edit"></i>
|
||||
</a>
|
||||
<% if (!phone) { %>
|
||||
<a href="#" id="toolbar-search" class="link icon-only">
|
||||
<i class="icon icon-search"></i>
|
||||
|
|
|
@ -63,7 +63,8 @@ define([
|
|||
"click #toolbar-edit" : "showEdition",
|
||||
"click #toolbar-add" : "showInserts",
|
||||
"click #toolbar-settings" : "showSettings",
|
||||
"click #toolbar-preview" : "showPreview"
|
||||
"click #toolbar-preview" : "showPreview",
|
||||
"click #toolbar-edit-document": "editDocument"
|
||||
},
|
||||
|
||||
// Set innerHTML and get the references to the DOM elements
|
||||
|
@ -101,6 +102,8 @@ define([
|
|||
setMode: function (mode) {
|
||||
if (mode.isEdit) {
|
||||
$('#toolbar-edit, #toolbar-add, #toolbar-undo, #toolbar-redo').show();
|
||||
} else if (mode.canEdit && mode.canRequestEditRights){
|
||||
$('#toolbar-edit-document').show();
|
||||
}
|
||||
},
|
||||
|
||||
|
@ -152,6 +155,10 @@ define([
|
|||
PE.getController('DocumentPreview').show();
|
||||
},
|
||||
|
||||
editDocument: function () {
|
||||
Common.Gateway.requestEditRights();
|
||||
},
|
||||
|
||||
textBack: 'Back'
|
||||
}
|
||||
})(), PE.Views.Toolbar || {}))
|
||||
|
|
|
@ -34,6 +34,9 @@
|
|||
<a href="#" id="toolbar-add" class="link icon-only" style="display: none;">
|
||||
<i class="icon icon-plus"></i>
|
||||
</a>
|
||||
<a href="#" id="toolbar-edit-document" class="link icon-only" style="display: none;">
|
||||
<i class="icon icon-edit"></i>
|
||||
</a>
|
||||
<% if (!phone) { %>
|
||||
<a href="#" id="toolbar-search" class="link icon-only">
|
||||
<i class="icon icon-search"></i>
|
||||
|
|
|
@ -62,7 +62,8 @@ define([
|
|||
"click #toolbar-search" : "searchToggle",
|
||||
"click #toolbar-edit" : "showEdition",
|
||||
"click #toolbar-add" : "showInserts",
|
||||
"click #toolbar-settings" : "showSettings"
|
||||
"click #toolbar-settings" : "showSettings",
|
||||
"click #toolbar-edit-document": "editDocument"
|
||||
},
|
||||
|
||||
// Set innerHTML and get the references to the DOM elements
|
||||
|
@ -93,6 +94,8 @@ define([
|
|||
setMode: function (mode) {
|
||||
if (mode.isEdit) {
|
||||
$('#toolbar-edit, #toolbar-add, #toolbar-undo, #toolbar-redo').show();
|
||||
} else if (mode.canEdit && mode.canRequestEditRights){
|
||||
$('#toolbar-edit-document').show();
|
||||
}
|
||||
},
|
||||
|
||||
|
@ -148,6 +151,10 @@ define([
|
|||
this.$btnEdit.toggleClass('disabled', val);
|
||||
},
|
||||
|
||||
editDocument: function () {
|
||||
Common.Gateway.requestEditRights();
|
||||
},
|
||||
|
||||
textBack: 'Back'
|
||||
}
|
||||
})(), SSE.Views.Toolbar || {}))
|
||||
|
|
Loading…
Reference in a new issue