Changeset 6
- Timestamp:
- Jan 19, 2011, 2:19:10 PM (12 years ago)
- Location:
- trunk
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/application.properties
r2 r6 1 1 #Grails Metadata file 2 # Thu Dec 23 09:39:58 CET 20102 #Wed Jan 19 09:55:04 CET 2011 3 3 app.build.display.info=0 4 4 app.grails.version=1.3.6 … … 6 6 app.servlet.version=2.4 7 7 app.version=0.1 8 plugins.db-util=0.4 8 9 plugins.famfamfam=1.0.1 9 plugins.db-util=0.410 10 plugins.hibernate=1.3.6 11 plugins.jquery=1.4.4.1 12 plugins.jquery-ui=1.8.7 11 13 plugins.tomcat=1.3.6 12 plugins.jquery=1.4.413 plugins.jquery-ui=1.8.7 -
trunk/grails-app/conf/BaseFilters.groovy
r4 r6 100 100 before = { 101 101 // Never perform full synchronization on rest call when the synchronize controller is used 102 if( controllerName == "rest" || controllerName == "synchronize" ) {102 if( controllerName == "rest" || controllerName == "synchronize" || controllerName == "dbUtil" ) { 103 103 return true; 104 104 } -
trunk/grails-app/services/nl/tno/metagenomics/integration/GscfService.groovy
r4 r6 120 120 * @return ArrayList 121 121 */ 122 public ArrayList getAssays(String sessionToken, String studyToken) {122 public ArrayList getAssays(String sessionToken, String studyToken) throws NotAuthorizedException, ResourceNotFoundException { 123 123 try { 124 124 return this.callGSCF(sessionToken, "getAssays", ["studyToken": studyToken]) … … 139 139 * @return ArrayList 140 140 */ 141 public def getAssay(String sessionToken, String studyToken, String assayToken ) {141 public def getAssay(String sessionToken, String studyToken, String assayToken ) throws NotAuthorizedException, ResourceNotFoundException { 142 142 def list 143 143 try { … … 165 165 * @return ArrayList 166 166 */ 167 public ArrayList getSamples(String sessionToken, String assayToken) {167 public ArrayList getSamples(String sessionToken, String assayToken) throws NotAuthorizedException, ResourceNotFoundException { 168 168 // Samples of a Study limited to a single Assay 169 169 try { … … 186 186 * @return ArrayList 187 187 */ 188 public def getSample(String sessionToken, String assayToken, String sampleToken) {188 public def getSample(String sessionToken, String assayToken, String sampleToken) throws NotAuthorizedException, ResourceNotFoundException { 189 189 def list 190 190 … … 262 262 if( parameter.value instanceof Collection ) { 263 263 parameter.value.each { value -> 264 addr += "&${parameter.key}= ${value}"264 addr += "&${parameter.key}=" + value.toString().encodeAsURL() 265 265 } 266 266 } else { 267 addr += "&${parameter.key}= ${parameter.value}"267 addr += "&${parameter.key}=" + parameter.value.toString().encodeAsURL() 268 268 } 269 269 } -
trunk/grails-app/services/nl/tno/metagenomics/integration/SynchronizationService.groovy
r4 r6 103 103 def studies 104 104 if( eager ) { 105 studies = Study.list().findAll { !it.trashcan };106 log.trace "Eager synchronization : " + studies.size();105 studies = [] 106 log.trace "Eager synchronization"; 107 107 } else { 108 108 studies = Study.findAllWhere( [isDirty: true] ); 109 109 log.trace "Default synchronization: " + studies.size() 110 111 // Perform no synchronization if no studies have to be synchronized 112 if( studies.size() == 0 ) 113 return [] 110 114 } 111 115 112 // Perform no synchronization if no studies have to be synchronized113 116 // Perform synchronization on only one study directly, because otherwise 114 117 // the getStudies method could throw a ResourceNotFoundException or NotAuthorizedException 115 118 // that can better be handled by synchronizeStudy 116 if( studies.size() == 0 ) { 117 return [] 118 } else if( studies.size() == 1 ) { 119 println "Study: " + studies[ 0] 119 if( studies.size() == 1 ) { 120 120 def newStudy = synchronizeStudy( studies[0] ); 121 121 if( newStudy ) -
trunk/grails-app/views/synchronize/full.gsp
r3 r6 22 22 url: "<g:createLink controller="synchronize" action="perform" />", 23 23 success: function(data) { window.location.replace( "${url.encodeAsJavaScript()}" ); }, 24 error: function(xhr, textStatus, errorThrown) { alert( "Error " + xhr.responseCode + ": " + textStatus ); window.location.replace( "${url.encodeAsJavaScript()}" ); } 24 error: function(xhr, textStatus, errorThrown) { 25 if( confirm( "Error " + xhr.responseCode + ": " + xhr.responseText + ". Would you like to try again?" ) ) { 26 window.location.refresh(); 27 } else { 28 if( confirm( "Would you like to continue to the original page?") ) { 29 window.location.replace( "${url.encodeAsJavaScript()}" ); 30 } else { 31 $( "#wait_dialog").dialog( "close" ); 32 } 33 } 34 } 25 35 }); 26 36 });
Note: See TracChangeset
for help on using the changeset viewer.