Skip to content

Commit

Permalink
Merge pull request #59 from Gustry/typo-console
Browse files Browse the repository at this point in the history
Remove some console.log, use propre console.warn or console.error, fix typo
  • Loading branch information
Gustry authored Oct 1, 2024
2 parents 61fb708 + e79ad8e commit eb3e32c
Showing 1 changed file with 11 additions and 11 deletions.
22 changes: 11 additions & 11 deletions wps/www/wps.js
Original file line number Diff line number Diff line change
Expand Up @@ -468,7 +468,7 @@ var Petra = function() {

container.appendChild(control);
addValueHandlers(field, function() {
// parse field value: number,number,number,number ESPG:integer
// parse field value: number,number,number,number EPSG:integer
var reg = /(-?\d+\.?\d*) *, *(-?\d+\.?\d*) *, *(-?\d+\.?\d*) *, *(-?\d+\.?\d*) *\((EPSG:\d+)\)/gi;
var matches = reg.exec(field.value);
if (matches === undefined) {
Expand Down Expand Up @@ -607,7 +607,7 @@ var Petra = function() {
container.insertBefore(field, previousSibling.nextSibling) :
container.appendChild(control);

console.log(name+' "'+dataType+'" "'+qgisType+'" '+(dataType == 'string' && !anyValue)+' '+(qgisType=='source'));
// console.log(name+' "'+dataType+'" "'+qgisType+'" '+(dataType == 'string' && !anyValue)+' '+(qgisType=='source'));
if ( qgisType == 'vector' || qgisType == 'source' ) {
var option;
option = document.createElement("option");
Expand Down Expand Up @@ -1084,8 +1084,8 @@ var Petra = function() {
{},
function(json){
if( 'errors' in json ){
console.log('Dataviz configuration error');
console.log(json.errors);
console.error('Dataviz configuration error');
console.error(json.errors);
return false;
}
if( !json.data || json.data.length < 1)
Expand Down Expand Up @@ -1207,7 +1207,7 @@ var Petra = function() {
}
}
// Add process inputs
// Fisrt the header
// First the header
divResults.find('table.processing-results-detail-table tr:first th:last')
.after('<th class="'+uuid+'">'+(new Date(processExecuted.startTime)).toLocaleString()+'</th>');
// Then the data
Expand Down Expand Up @@ -1251,7 +1251,7 @@ var Petra = function() {
}
}
// Add process literal results
// Fisrt the header
// First the header
divResults.find('table.processing-results-literal-table tr:first th:last')
.after('<th class="'+uuid+'">'+(new Date(processExecuted.startTime)).toLocaleString()+'</th>');
// Then the data
Expand Down Expand Up @@ -1293,7 +1293,7 @@ var Petra = function() {
}
}
// Add process layer results
// Fisrt the header
// First the header
divResults.find('table.processing-results-layer-table tr:first th:last')
.after('<th class="'+uuid+'">'+(new Date(processExecuted.startTime)).toLocaleString()+'</th>');
// Then the data
Expand All @@ -1314,7 +1314,7 @@ var Petra = function() {
continue;
// Create a layer name for the map
var layerName = uuid+'-'+output.identifier.replaceAll(':', '_').replaceAll(' ', '_');
console.log(layerName);
// console.log(layerName);
// Create the base url
var serviceUrl = OpenLayers.Util.urlAppend( url.substring(0, url.indexOf('?') + 1)
,OpenLayers.Util.getParameterString({map:mapParam})
Expand Down Expand Up @@ -1434,7 +1434,7 @@ var Petra = function() {
}
}
// Add process file results
// Fisrt the header
// First the header
divResults.find('table.processing-results-file-table tr:first th:last')
.after('<th class="'+uuid+'">'+(new Date(processExecuted.startTime)).toLocaleString()+'</th>');
// Then the data
Expand Down Expand Up @@ -1511,7 +1511,7 @@ var Petra = function() {
// From the layer tree
for (const extLayer of extGroupMapState.getChildren()) {
const wpsLayerName = extLayer.olLayer.get('wpsLayerName');
console.log(wpsLayerName+' '+uuid+' '+wpsLayerName.startsWith(uuid));
// console.log(wpsLayerName+' '+uuid+' '+wpsLayerName.startsWith(uuid));
if (wpsLayerName.startsWith(uuid)) {
extGroupMapState.removeOlLayer(extLayer.name);
}
Expand Down Expand Up @@ -1737,7 +1737,7 @@ var Petra = function() {

}
else
console.log('unknown uuid');
console.warn('unknown uuid');
});
}

Expand Down

0 comments on commit eb3e32c

Please sign in to comment.