Changeset 746
- Timestamp:
- 01/23/13 18:00:59 (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
ether_iasi/trunk/web/project/quicklook_script.jsp
r745 r746 82 82 this.selectSpecies = new Select( paramSelect ); 83 83 this.selectSpecies.add( "CO", 'CO' ); 84 this.selectSpecies.add( "H2O", 'H2O' );85 this.selectSpecies.add( "TS", '<spring:message code="label.surftemp"/>' );84 this.selectSpecies.add( "H2O", 'H2O' ); 85 this.selectSpecies.add( "TS", '<spring:message code="label.surftemp"/>' ); 86 86 this.selectSpecies.selectFirst(); 87 87 }, … … 101 101 } ); 102 102 103 $( "#beginDate" ).val( formatDate( removeDaysToDate( new Date(), 1 ), "%Y-%m-%d" ) );103 $( "#beginDate" ).val( formatDate( removeDaysToDate( new Date(), 1 ), "%Y-%m-%d" ) ); 104 104 this.beginDate = this.calendarConverter.parse( $( "#beginDate" ).val() ).getTime(); 105 105 }, … … 109 109 { 110 110 $.ajax( { 111 url: "project?methodName=getQuicklookByValues&satellite=" + this.selectSatellites.getValue()+"&projection="+this.selectProjections.getValue()+"&species="+this.selectSpecies.getValue()+"&date="+this.beginDate,111 url: "project?methodName=getQuicklookByValues&satellite=" + this.selectSatellites.getValue() + "&projection=" + this.selectProjections.getValue() + "&species=" + this.selectSpecies.getValue() + "&date=" + this.beginDate, 112 112 success:jQuery.proxy( this.handleQuickLooksBySelectValues, this ), 113 113 error: jQuery.proxy( this.showErrors, this ) … … 125 125 var plotNameD = jQuery.parseJSON( result ).plotNameResultD; 126 126 127 if (plotNameA) 128 { 127 if( plotNameA ) 128 this.containerResultA.html( "<center>MetOp-A</center><center><img src='resources/img/" + plotNameA + "' width='430px' height='350px' onerror='javascript:displayNoImage()'><img src='resources/img/" + plotNameC + "' width='430px' height='350px'></center>" ); 129 130 if( plotNameB ) 131 this.containerResultA.html( "<center>MetOp-B</center><center><img src='resources/img/" + plotNameB + "' width='430px' height='350px'><img src='resources/img/" + plotNameD + "' width='430px' height='350px'></center>" ); 129 132 130 133 131 this.containerResultA.html("<center>MetOp-A</center><center><img src='resources/img/"+plotNameA+"' width='430px' height='350px' onerror='"+this.bob+"'><img src='resources/img/"+plotNameC+"' width='430px' height='350px'></center>"); 132 134 if( plotNameA && plotNameB ) 135 { 136 this.containerResultA.html( plotNameA + plotNameC ); 137 this.containerResultB.html( plotNameB + plotNameD ); 133 138 } 134 if (plotNameB)135 this.containerResultA.html("<center>MetOp-B</center><center><img src='resources/img/"+plotNameB+"' width='430px' height='350px'><img src='resources/img/"+plotNameD+"' width='430px' height='350px'></center>");136 137 138 if (plotNameA && plotNameB )139 {140 this.containerResultA.html(plotNameA + plotNameC);141 this.containerResultB.html(plotNameB + plotNameD);142 }143 139 144 140 … … 166 162 this.containerErrors.show(); 167 163 this.containerErrors.html( result ); 168 }, 169 170 bob:function() 171 { 172 alert("pif"); 173 } 164 } 174 165 } ); 175 166 167 function displayNoImage() 168 { 169 $( "#containerQuickLookA" ).html("No image"); 170 } 176 171 </script>
Note: See TracChangeset
for help on using the changeset viewer.