rework a few more dialogs to use App.dialogOf()
This commit is contained in:
parent
d466284fab
commit
72e38bfe1f
|
@ -184,7 +184,7 @@ class Article extends Handler_Protected {
|
|||
print "<button dojoType='dijit.form.Button'
|
||||
type='submit' class='alt-primary'>".__('Save')."</button> ";
|
||||
print "<button dojoType='dijit.form.Button'
|
||||
onclick=\"dijit.byId('editTagsDlg').hide()\">".__('Cancel')."</button>";
|
||||
onclick='App.dialogOf(this).hide()'>".__('Cancel')."</button>";
|
||||
print "</footer>";
|
||||
|
||||
}
|
||||
|
|
|
@ -83,8 +83,7 @@ class Backend extends Handler_Protected {
|
|||
}
|
||||
|
||||
print "<footer class='text-center'>";
|
||||
print "<button dojoType='dijit.form.Button'
|
||||
onclick=\"return dijit.byId('helpDlg').hide()\">".__('Close this window')."</button>";
|
||||
print "<button dojoType='dijit.form.Button' class='alt-primary' type='submit'>".__('Close this window')."</button>";
|
||||
print "</footer>";
|
||||
|
||||
}
|
||||
|
|
|
@ -730,9 +730,9 @@ class Feeds extends Handler_Protected {
|
|||
|
||||
print "<footer>";
|
||||
print "<button dojoType='dijit.form.Button' class='alt-primary' type='submit'
|
||||
onclick=\"return dijit.byId('feedAddDlg').execute()\">".__('Subscribe')."</button>";
|
||||
onclick=\"App.dialogOf(this).execute()\">".__('Subscribe')."</button>";
|
||||
|
||||
print "<button dojoType='dijit.form.Button' onclick=\"return dijit.byId('feedAddDlg').hide()\">".__('Cancel')."</button>";
|
||||
print "<button dojoType='dijit.form.Button' onclick=\"App.dialogOf(this).hide()\">".__('Cancel')."</button>";
|
||||
print "</footer>";
|
||||
|
||||
print "</form>";
|
||||
|
@ -744,7 +744,7 @@ class Feeds extends Handler_Protected {
|
|||
$active_feed_id = sprintf("%d", $this->params[0]);
|
||||
$is_cat = $this->params[1] != "false";
|
||||
|
||||
print "<form onsubmit='return false;'>";
|
||||
print "<form onsubmit='return false'>";
|
||||
|
||||
print "<section>";
|
||||
|
||||
|
@ -772,8 +772,9 @@ class Feeds extends Handler_Protected {
|
|||
<i class='material-icons'>help</i> ".__("Search syntax")."</button>";
|
||||
}
|
||||
|
||||
print "<button dojoType='dijit.form.Button' type='submit' class='alt-primary' onclick=\"dijit.byId('searchDlg').execute()\">".__('Search')."</button>
|
||||
<button dojoType='dijit.form.Button' onclick=\"dijit.byId('searchDlg').hide()\">".__('Cancel')."</button>";
|
||||
print "<button dojoType='dijit.form.Button' class='alt-primary'
|
||||
type='submit' onclick='App.dialogOf(this).execute()'>".__('Search')."</button>
|
||||
<button dojoType='dijit.form.Button' onclick='App.dialogOf(this).hide()'>".__('Cancel')."</button>";
|
||||
|
||||
print "</footer>";
|
||||
|
||||
|
|
|
@ -809,8 +809,8 @@ class Pref_Feeds extends Handler_Protected {
|
|||
print "<footer>
|
||||
<button style='float : left' class='alt-danger' dojoType='dijit.form.Button' onclick='return CommonDialogs.unsubscribeFeed($feed_id, \"$title\")'>".
|
||||
__('Unsubscribe')."</button>
|
||||
<button dojoType='dijit.form.Button' class='alt-primary' onclick=\"return dijit.byId('feedEditDlg').execute()\">".__('Save')."</button>
|
||||
<button dojoType='dijit.form.Button' onclick=\"return dijit.byId('feedEditDlg').hide()\">".__('Cancel')."</button>
|
||||
<button dojoType='dijit.form.Button' class='alt-primary' type='submit'>".__('Save')."</button>
|
||||
<button dojoType='dijit.form.Button' onclick='App.dialogOf(this).hide()'>".__('Cancel')."</button>
|
||||
</footer>";
|
||||
}
|
||||
}
|
||||
|
@ -972,11 +972,10 @@ class Pref_Feeds extends Handler_Protected {
|
|||
print "</section>";
|
||||
|
||||
print "<footer>
|
||||
<button dojoType='dijit.form.Button' type='submit' class='alt-primary'
|
||||
onclick=\"return dijit.byId('feedEditDlg').execute()\">".
|
||||
<button dojoType='dijit.form.Button' type='submit' class='alt-primary' type='submit'>".
|
||||
__('Save')."</button>
|
||||
<button dojoType='dijit.form.Button'
|
||||
onclick=\"return dijit.byId('feedEditDlg').hide()\">".
|
||||
onclick=\"App.dialogOf(this).hide()\">".
|
||||
__('Cancel')."</button>
|
||||
</footer>";
|
||||
|
||||
|
|
|
@ -594,13 +594,12 @@ const Feeds = {
|
|||
return tree.model.store.getValue(nuf, 'bare_id');
|
||||
},
|
||||
search: function() {
|
||||
if (dijit.byId("searchDlg"))
|
||||
dijit.byId("searchDlg").destroyRecursive();
|
||||
|
||||
xhrPost("backend.php",
|
||||
{op: "feeds", method: "search",
|
||||
param: Feeds.getActive() + ":" + Feeds.activeIsCat()},
|
||||
(transport) => {
|
||||
if (dijit.byId("searchDlg"))
|
||||
dijit.byId("searchDlg").destroyRecursive();
|
||||
|
||||
const dialog = new dijit.Dialog({
|
||||
id: "searchDlg",
|
||||
|
|
Loading…
Reference in New Issue