[GeoNode-users] Custom background layers not in Thumbnail

John, Steffen s.john at atenekom.eu
Thu Mar 16 01:43:35 PDT 2017

I created custom map base layers, which are added to every newly
created map. When saving this map, the thumbnail is created without the
basemap on it.

To define the basemaps, i added a gxp plugin, correspondingly to the
BingSource, based on a WMS. May be I missed something? 
Do you have any idea, what I have done wrong?

Thank you so much for your help.

Here is the code:

gxp.plugins.WebAtlasFarbeSource = Ext.extend(gxp.plugins.LayerSource, {

    ptype: "gxp_webatlasfarbesource",

    title: "WebAtlasDE Farbe",
    webAtlasFarbeTitle: "WebAtlasDEFarbe",
    url: "https://sg.geodatenzentrum.de/wms_webatlasde__UUID",
    attribution: "© GeoBasis-DE / <b>BKG</b> ("+year+")",
    createStore: function() {
        var layers = [
             new OpenLayers.Layer.WMS(this.webAtlasFarbeTitle,
                                   {layers: ["webatlasde"],
                                   tiled: true
                                       attribution : this.attribution

        this.store = new GeoExt.data.LayerStore({
            layers: layers,
            fields: [
                {name: "source", type: "string"},
                {name: "name", type: "string", defaultValue:
                {name: "abstract", type: "string", mapping:
                {name: "group", type: "string", defaultValue:
                {name: "fixed", type: "boolean", defaultValue: true},
                {name: "selected", type: "boolean"}
        this.store.each(function(l) {
            l.set("group", "background");
        this.fireEvent("ready", this);

    createLayerRecord: function(config) {
        var record;
        var index = this.store.findExact("name", config.name);
        if (index > -1) {

            record =
            var layer = record.getLayer().clone();
            // set layer title from config
            if (config.title) {
                 * Because the layer title data is duplicated, we have
                 * to set it in both places.  After records have been
                 * added to the store, the store handles this
                 * synchronization.
                record.set("title", config.title);

            // set visibility from config
            if ("visibility" in config) {
                layer.visibility = config.visibility;
            record.set("selected", config.selected || false);
            record.set("source", config.source);
            record.set("name", config.name);
            if ("group" in config) {
                record.set("group", config.group);

            record.data.layer = layer;
        return record;



More information about the geonode-users mailing list