Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update data.PrintProvider for XYZ layer support and form.recordToField for CouchDB support #88

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions lib/GeoExt/data/PrintProvider.js
Original file line number Diff line number Diff line change
Expand Up @@ -666,6 +666,15 @@ GeoExt.data.PrintProvider = Ext.extend(Ext.util.Observable, {
extension: "png"
});
},
"XYZ": function (layer) {
var enc = this.encoders.layers.TileCache.call(this, layer);
return Ext.apply(enc, {
type: 'XYZ',
baseURL: enc.baseURL.substr(0, enc.baseURL.indexOf("$")),
extension: enc.baseURL.substr(enc.baseURL.lastIndexOf("$")).split(".").pop(),
tileOriginCorner: layer.tileOriginCorner
});
},
"TMS": function(layer) {
var enc = this.encoders.layers.TileCache.call(this, layer);
return Ext.apply(enc, {
Expand Down
4 changes: 2 additions & 2 deletions lib/GeoExt/widgets/form.js
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,7 @@ GeoExt.form.recordToField = function(record, options) {
// field, just return it
return type;
}
type = type.split(":").pop(); // remove ns prefix
type = type.split(":").length > 1 ? type.split(":").pop() : type; // optionally remove ns prefix

var field;
var name = record.get("name");
Expand Down Expand Up @@ -243,7 +243,7 @@ GeoExt.form.recordToField.REGEXES = {
"^(text|string)$", "i"
),
"number": new RegExp(
"^(number|float|decimal|double|int|long|integer|short)$", "i"
"^(number|float|decimal|double|real|int|long|integer|short)$", "i"
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This change is obsolete with geoext/geoext@814f6d5

),
"boolean": new RegExp(
"^(boolean)$", "i"
Expand Down