mirror of
https://github.com/pgadmin-org/pgadmin4.git
synced 2024-11-21 16:27:39 -06:00
Minor tweaks to the dialog code.
This commit is contained in:
parent
65dc4320f1
commit
9d94848af4
@ -20,13 +20,11 @@ function about_show() {
|
||||
setup:function() {
|
||||
return {
|
||||
buttons:[{ text: "OK", key: 27, className: "btn btn-primary" }],
|
||||
focus: { element: 0 },
|
||||
options: { modal: 0, overflow: false, resizable: true }
|
||||
options: { modal: 0, resizable: true }
|
||||
};
|
||||
},
|
||||
build:function() {
|
||||
this.elements.body.style.minHeight = "450px";
|
||||
this.elements.body.style.minWidth = "800px";
|
||||
|
||||
},
|
||||
prepare:function() {
|
||||
this.setContent(this.message);
|
||||
@ -38,8 +36,7 @@ function about_show() {
|
||||
var content = '';
|
||||
$.get("{{ url_for('about.index') }}",
|
||||
function(data) {
|
||||
alertify.aboutDialog('About {{ config.APP_NAME }}', data);
|
||||
alertify.aboutDialog('About {{ config.APP_NAME }}', data).resizeTo(800, 450);
|
||||
}
|
||||
);
|
||||
|
||||
}
|
@ -46,9 +46,10 @@ function test_dialog() {
|
||||
if (!alertify.myAlert) {
|
||||
alertify.dialog('myAlert', function factory() {
|
||||
return {
|
||||
main:function(title, message) {
|
||||
main:function(title, message, data) {
|
||||
this.set('title', title);
|
||||
this.message = message;
|
||||
this.data = data;
|
||||
},
|
||||
setup:function() {
|
||||
return {
|
||||
@ -59,6 +60,9 @@ function test_dialog() {
|
||||
},
|
||||
prepare:function() {
|
||||
this.setContent(this.message);
|
||||
},
|
||||
callback:function(closeEvent) {
|
||||
alertify.alert('Close Event', 'You pressed: ' + closeEvent.button.text + ' on ' + this.data);
|
||||
}
|
||||
}
|
||||
},
|
||||
@ -66,5 +70,8 @@ function test_dialog() {
|
||||
}
|
||||
|
||||
alertify.myAlert('Dialog Test',
|
||||
'This is a test dialog from Alertify!');
|
||||
'This is a test dialog from Alertify!', 'This is dialog 1');
|
||||
|
||||
alertify.myAlert('Dialog Test 2',
|
||||
'This is another test dialog from Alertify!', 'This is dialog 2');
|
||||
}
|
Loading…
Reference in New Issue
Block a user