Allow creation of objects in schemas with special chars in the name. Fixes #1598
This was caused through generation of SQL based on HTML-escaped labels, not the raw versions.pull/3/head
parent
c044af9585
commit
fc5ce22de9
|
@ -73,7 +73,7 @@ function($, _, S, pgAdmin, pgBrowser, alertify) {
|
|||
var schemaInfo = args.node_info.schema;
|
||||
|
||||
this.set({'owner': userInfo.name}, {silent: true});
|
||||
this.set({'schema': schemaInfo.label}, {silent: true});
|
||||
this.set({'schema': schemaInfo._label}, {silent: true});
|
||||
}
|
||||
pgAdmin.Browser.Node.Model.prototype.initialize.apply(this, arguments);
|
||||
},
|
||||
|
|
|
@ -492,7 +492,7 @@ function($, _, S, pgAdmin, pgBrowser, alertify) {
|
|||
var isNew = (_.size(attrs) === 0);
|
||||
if (isNew) {
|
||||
// Set Selected Schema
|
||||
schema = args.node_info.schema.label
|
||||
schema = args.node_info.schema._label
|
||||
this.set({'basensp': schema}, {silent: true});
|
||||
|
||||
// Set Current User
|
||||
|
|
|
@ -114,7 +114,7 @@ function($, _, S, pgAdmin, pgBrowser, alertify) {
|
|||
var schemaInfo = args.node_info.schema;
|
||||
|
||||
this.set({'seqowner': userInfo.name}, {silent: true});
|
||||
this.set({'schema': schemaInfo.label}, {silent: true});
|
||||
this.set({'schema': schemaInfo._label}, {silent: true});
|
||||
}
|
||||
pgBrowser.Node.Model.prototype.initialize.apply(this, arguments);
|
||||
},
|
||||
|
|
|
@ -65,8 +65,8 @@ function($, _, S, pgAdmin, pgBrowser, alertify) {
|
|||
var schemaInfo = args.node_info.schema;
|
||||
this.set({
|
||||
'owner': userInfo.name,
|
||||
'synobjschema': schemaInfo.label,
|
||||
'schema': schemaInfo.label,
|
||||
'synobjschema': schemaInfo._label,
|
||||
'schema': schemaInfo._label,
|
||||
'targettype': 'r'
|
||||
}, {silent: true});
|
||||
} else {
|
||||
|
|
|
@ -284,7 +284,7 @@ function($, _, S, pgAdmin, pgBrowser, alertify) {
|
|||
var schemaInfo = args.node_info.schema;
|
||||
|
||||
this.set({'relowner': userInfo.name}, {silent: true});
|
||||
this.set({'schema': schemaInfo.label}, {silent: true});
|
||||
this.set({'schema': schemaInfo._label}, {silent: true});
|
||||
}
|
||||
pgBrowser.Node.Model.prototype.initialize.apply(this, arguments);
|
||||
|
||||
|
|
|
@ -311,7 +311,7 @@ function($, _, S, pgAdmin, pgBrowser, alertify, Backgrid) {
|
|||
var schemaInfo = args.node_info.schema;
|
||||
|
||||
this.set({'typeowner': userInfo.name}, {silent: true});
|
||||
this.set({'schema': schemaInfo.label}, {silent: true});
|
||||
this.set({'schema': schemaInfo._label}, {silent: true});
|
||||
}
|
||||
pgBrowser.Node.Model.prototype.initialize.apply(this, arguments);
|
||||
},
|
||||
|
|
|
@ -118,7 +118,7 @@ function($, _, S, pgAdmin, alertify, pgBrowser, CodeMirror) {
|
|||
var isNew = (_.size(attrs) === 0);
|
||||
if (isNew) {
|
||||
// Set Selected Schema
|
||||
var schemaLabel = args.node_info.schema.label;
|
||||
var schemaLabel = args.node_info.schema._label;
|
||||
if (schemaLabel == '') {
|
||||
this.set({'schema': 'public'}, {silent: true});
|
||||
} else {
|
||||
|
|
|
@ -92,7 +92,7 @@ function($, _, S, pgAdmin, pgBrowser, CodeMirror) {
|
|||
var isNew = (_.size(attrs) === 0);
|
||||
if (isNew) {
|
||||
// Set Selected Schema
|
||||
var schemaLabel = args.node_info.schema.label;
|
||||
var schemaLabel = args.node_info.schema._label;
|
||||
if (schemaLabel == '') {
|
||||
this.set({'schema': 'public'}, {silent: true});
|
||||
} else {
|
||||
|
|
Loading…
Reference in New Issue