-
Type:
Bug
-
Status: Done
-
Resolution: Done
-
Affects Version/s: 5.0
-
Fix Version/s: None
-
Component/s: Aikau, Web Scripts and Surf
-
Labels:None
-
Story Points:3
Create an Aikau page using a POST webscript. On loading the page, you'll see a stack trace similar to this: http://pastebin.com/XegZJqAA
This is caused because there's a hardcoded "GET" when looking up the webscript.
ProcessJsonModelDirective.java
// Get the ID of the WebScript being executed, this is done for debugging purposes... String url = this.getModelObject().getProperty("url"); if (url != null && this.webScriptsContainer != null && this.webScriptsContainer.getRegistry() != null) { Match match = this.webScriptsContainer.getRegistry().findWebScript("GET", url); String wsId = match.getWebScript().getDescription().getId(); if (wsId != null) { content.append(",webScriptId:\""); content.append(wsId); content.append("\""); } }
See here for context: https://github.com/Alfresco/community-edition/blob/master/projects/surf/spring-surf/spring-surf/src/main/java/org/springframework/extensions/directives/ProcessJsonModelDirective.java#L569
Raised by Ole Hejlskov on IRC