commented console.log. Added MaxLenght to CQL Filter
This commit is contained in:
parent
0d4428e341
commit
69e5216645
|
@ -87,7 +87,7 @@ public class GeoportalDataViewerConstants {
|
|||
* @param msg the msg
|
||||
*/
|
||||
public static native void printJs(String msg)/*-{
|
||||
console.log("js console: " + msg);
|
||||
//console.log("js console: " + msg);
|
||||
}-*/;
|
||||
|
||||
/**
|
||||
|
@ -96,7 +96,7 @@ public class GeoportalDataViewerConstants {
|
|||
* @param msg the msg
|
||||
*/
|
||||
public static native void printJsObj(Object object)/*-{
|
||||
console.log("js obj: " + JSON.stringify(object, null, 4));
|
||||
//console.log("js obj: " + JSON.stringify(object, null, 4));
|
||||
}-*/;
|
||||
|
||||
/**
|
||||
|
|
|
@ -1344,7 +1344,7 @@ public class LayerManager {
|
|||
* Fire go to layers.
|
||||
*/
|
||||
protected void fireGoToLayers() {
|
||||
int zoomValue = (int) (OLMapManager.LAYER_DETAIL_MAX_RESOLUTION + 1);
|
||||
int zoomValue = (int) (OLMapManager.LAYER_DETAIL_MAX_RESOLUTION + 0.1);
|
||||
olMap.setZoom(zoomValue);
|
||||
try {
|
||||
Element buttonElement = DOM.getElementById("go-to-layers");
|
||||
|
|
|
@ -72,6 +72,8 @@ import ol.source.XyzOptions;
|
|||
*/
|
||||
public abstract class OpenLayerMap {
|
||||
|
||||
private static final int MAX_LENGHT_CQL_FOR_GET_REQUEST = 1600; //1600 characters
|
||||
|
||||
public static final int SET_CENTER_ANIMATED_DURATION = 500;
|
||||
|
||||
public static final int ZOOM_ANIMATED_DURATION = 3000;
|
||||
|
@ -459,7 +461,7 @@ public abstract class OpenLayerMap {
|
|||
ImageWms imageWMSSource = wmsLayer.getSource();
|
||||
ImageWmsParams imageWMSParams = imageWMSSource.getParams();
|
||||
|
||||
if (cqlFilterExpression == null) {
|
||||
if (cqlFilterExpression == null || cqlFilterExpression.length()>MAX_LENGHT_CQL_FOR_GET_REQUEST) {
|
||||
imageWMSParams.delete("CQL_FILTER");
|
||||
} else {
|
||||
imageWMSParams.set("CQL_FILTER", cqlFilterExpression);
|
||||
|
@ -467,8 +469,10 @@ public abstract class OpenLayerMap {
|
|||
|
||||
imageWMSSource.updateParams(imageWMSParams);
|
||||
wmsLayer.setSource(imageWMSSource);
|
||||
|
||||
wmsLayer.changed();
|
||||
|
||||
// map.addLayer(wmsLayer);
|
||||
//map.addLayer(wmsLayer);
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -49,7 +49,7 @@ public class ImagesSectionGallery {
|
|||
*/
|
||||
private native void showGallery(JavaScriptObject json_array_images, String galleryDivId) /*-{
|
||||
|
||||
console.log("showing: " + json_array_images)
|
||||
//console.log("showing: " + json_array_images)
|
||||
var waitForJQuery = setInterval(
|
||||
function() {
|
||||
if (typeof $wnd.$ != 'undefined') {
|
||||
|
|
|
@ -189,7 +189,7 @@ public class LayersSectionViewer extends Composite {
|
|||
*/
|
||||
public static native void downloadMap(ol.Map map, String mapPanelId, String linkId, String filename,
|
||||
String mimeType)/*-{
|
||||
console.log("map: " + map);
|
||||
//console.log("map: " + map);
|
||||
|
||||
map.once('rendercomplete', function() {
|
||||
var mapCanvas = $doc.createElement('canvas');
|
||||
|
|
|
@ -157,19 +157,19 @@ public class TimelineRelationPanel extends Composite {
|
|||
|
||||
public static native String instanceTimeline(String idDivContainer, JSONArray jsonItems,
|
||||
TimelineRelationPanel instance) /*-{
|
||||
console.log('showTimeline_instanceTimeline for json items: '
|
||||
+ jsonItems);
|
||||
console.log('showing timeline');
|
||||
//console.log('showTimeline_instanceTimeline for json items: '+jsonItems);
|
||||
|
||||
console.log("showTimeline_template: " + $wnd.templateHandlebars);
|
||||
//console.log("showTimeline_template: " + $wnd.templateHandlebars);
|
||||
|
||||
// DOM element where the Timeline will be attached
|
||||
var container = $doc.getElementById(idDivContainer);
|
||||
|
||||
console.log("showTimeline_container: " + container);
|
||||
//console.log("showTimeline_container: " + container);
|
||||
|
||||
var myArray = $wnd.JSON.parse(jsonItems);
|
||||
|
||||
console.log("showTimeline_jsonItems: " + myArray);
|
||||
//console.log("showTimeline_jsonItems: " + myArray);
|
||||
|
||||
var container = $doc.getElementById(idDivContainer);
|
||||
|
||||
|
|
|
@ -313,9 +313,9 @@ public class SearchFacilityUI extends Composite {
|
|||
message += ". ";
|
||||
}
|
||||
|
||||
if (returnedItems > 0) {
|
||||
message += "On the map you can see all the projects with a centroid matching the query";
|
||||
}
|
||||
// if (returnedItems > 0) {
|
||||
// message += "On the map you can see all the projects with a centroid matching the query";
|
||||
// }
|
||||
|
||||
HTML resultMessage = new HTML(message);
|
||||
resultMessage.getElement().addClassName("search_result_msg");
|
||||
|
|
|
@ -396,7 +396,7 @@ public class DialogShareableLink extends Composite {
|
|||
private native void copyToClipboard(String myDivId) /*-{
|
||||
|
||||
var copyText = $doc.getElementById(myDivId);
|
||||
console.log("text copied is :" + copyText.value);
|
||||
//console.log("text copied is :" + copyText.value);
|
||||
copyText.select();
|
||||
//For mobile devices
|
||||
copyText.setSelectionRange(0, 99999);
|
||||
|
|
Loading…
Reference in New Issue