diff --git a/static/js/pandora/ui/eventsDialog.js b/static/js/pandora/ui/eventsDialog.js index 449696e25..988183ce0 100644 --- a/static/js/pandora/ui/eventsDialog.js +++ b/static/js/pandora/ui/eventsDialog.js @@ -16,7 +16,8 @@ pandora.ui.eventsDialog = function() { {}, Ox.Button({ id: 'done', - title: 'Done' + title: 'Done', + width: 48 }).bindEvent({ click: function() { that.close(); diff --git a/static/js/pandora/ui/namesDialog.js b/static/js/pandora/ui/namesDialog.js index 9dad1b9df..47121f6bb 100644 --- a/static/js/pandora/ui/namesDialog.js +++ b/static/js/pandora/ui/namesDialog.js @@ -87,6 +87,9 @@ pandora.ui.namesDialog = function() { .find('.OxItem.OxSelected > .OxCell.OxColumnSortname') .trigger('mousedown'); }, + select: function(data) { + $findButton.options({disabled: !data.ids.length}); + }, submit: function(data) { Ox.Request.clearCache('findNames'); pandora.api.editName({ @@ -96,10 +99,27 @@ pandora.ui.namesDialog = function() { } }), + $findButton = Ox.Button({ + disabled: true, + title: 'Find', + width: 48, + }).bindEvent({ + click: function() { + that.close(); + pandora.UI.set('find', { + conditions: [{ + key: 'name', + value: $list.value($list.options('selected'), 'name'), + operator: '=' + }], + operator: '&' + }) + } + }), + that = Ox.Dialog({ buttons: [ Ox.Button({ - id: 'manageTitles', title: 'Manage Titles...' }).bindEvent({ click: function() { @@ -107,9 +127,10 @@ pandora.ui.namesDialog = function() { } }), {}, + $findButton, Ox.Button({ - id: 'done', - title: 'Done' + title: 'Done', + width: 48 }).bindEvent({ click: function() { that.close(); diff --git a/static/js/pandora/ui/placesDialog.js b/static/js/pandora/ui/placesDialog.js index 64e677374..2b870b86d 100644 --- a/static/js/pandora/ui/placesDialog.js +++ b/static/js/pandora/ui/placesDialog.js @@ -44,7 +44,8 @@ pandora.ui.placesDialog = function() { {}, Ox.Button({ id: 'done', - title: 'Done' + title: 'Done', + width: 48 }).bindEvent({ click: function() { that.close(); diff --git a/static/js/pandora/ui/titlesDialog.js b/static/js/pandora/ui/titlesDialog.js index 36172a4b8..0b8bf43e7 100644 --- a/static/js/pandora/ui/titlesDialog.js +++ b/static/js/pandora/ui/titlesDialog.js @@ -76,6 +76,9 @@ pandora.ui.titlesDialog = function() { .find('.OxItem.OxSelected > .OxCell.OxColumnSorttitle') .trigger('mousedown'); }, + select: function(data) { + $findButton.options({disabled: !data.ids.length}); + }, submit: function(data) { Ox.Request.clearCache('findTitles'); pandora.api.editTitle({ @@ -85,10 +88,27 @@ pandora.ui.titlesDialog = function() { } }), + $findButton = Ox.Button({ + disabled: true, + title: 'Find', + width: 48, + }).bindEvent({ + click: function() { + that.close(); + pandora.UI.set('find', { + conditions: [{ + key: 'title', + value: $list.value($list.options('selected'), 'title'), + operator: '=' + }], + operator: '&' + }) + } + }), + that = Ox.Dialog({ buttons: [ Ox.Button({ - id: 'manageNames', title: 'Manage Names...' }).bindEvent({ click: function() { @@ -96,9 +116,10 @@ pandora.ui.titlesDialog = function() { } }), {}, + $findButton, Ox.Button({ - id: 'done', - title: 'Done' + title: 'Done', + width: 48 }).bindEvent({ click: function() { that.close(); diff --git a/static/js/pandora/ui/usersDialog.js b/static/js/pandora/ui/usersDialog.js index 959d71992..fcd56b119 100644 --- a/static/js/pandora/ui/usersDialog.js +++ b/static/js/pandora/ui/usersDialog.js @@ -292,7 +292,8 @@ pandora.ui.usersDialog = function() { }), Ox.Button({ id: 'done', - title: 'Done' + title: 'Done', + width: 48 }).bindEvent({ click: function() { that.close();