diff options
author | lresende <lresende@13f79535-47bb-0310-9956-ffa450edef68> | 2011-11-11 00:52:57 +0000 |
---|---|---|
committer | lresende <lresende@13f79535-47bb-0310-9956-ffa450edef68> | 2011-11-11 00:52:57 +0000 |
commit | c607b0cf671eda11eff333748e4ce3a75ce941d1 (patch) | |
tree | 944b27984facf8245ed40c4b635258544f367234 /sca-java-2.x/trunk/modules/web-javascript-dojo/src/main/java | |
parent | a9bdf283e49022d34d485702f2e907d3aa7a554e (diff) |
Adding dojox and dijit to web-javascript-dojo
git-svn-id: http://svn.us.apache.org/repos/asf/tuscany@1200668 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'sca-java-2.x/trunk/modules/web-javascript-dojo/src/main/java')
-rw-r--r-- | sca-java-2.x/trunk/modules/web-javascript-dojo/src/main/java/org/apache/tuscany/sca/web/javascript/dojo/DojoResourceServlet.java | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/sca-java-2.x/trunk/modules/web-javascript-dojo/src/main/java/org/apache/tuscany/sca/web/javascript/dojo/DojoResourceServlet.java b/sca-java-2.x/trunk/modules/web-javascript-dojo/src/main/java/org/apache/tuscany/sca/web/javascript/dojo/DojoResourceServlet.java index f3021b3c63..8218baa438 100644 --- a/sca-java-2.x/trunk/modules/web-javascript-dojo/src/main/java/org/apache/tuscany/sca/web/javascript/dojo/DojoResourceServlet.java +++ b/sca-java-2.x/trunk/modules/web-javascript-dojo/src/main/java/org/apache/tuscany/sca/web/javascript/dojo/DojoResourceServlet.java @@ -50,15 +50,21 @@ public class DojoResourceServlet extends HttpServlet { String contextRoot = URLDecoder.decode(HTTPUtils.getContextRoot(request), HTTPConstants.CHARACTER_ENCODING_UTF8); String path = URLDecoder.decode(request.getRequestURI(), HTTPConstants.CHARACTER_ENCODING_UTF8); - if( path.startsWith(contextRoot + "/dojo")|| - path.startsWith(contextRoot + "/dojox")|| + if( path.startsWith(contextRoot + "/dojo") || + path.startsWith(contextRoot + "/dojox") || path.startsWith(contextRoot + "/dijit")) { - if( ! path.contains("tuscany/")) { + //is they are dojo modules + + if( (! path.contains("tuscany/AtomService.js")) && + (! path.contains("tuscany/RestService.js")) ) { + //this is a workaround where we need to have dojo files in its own folder //to avoid clean target to clean other non dojo resources path = path.substring(contextRoot.length()); path = "/dojo" + path; } + + System.out.println(">>>Path :" + path); } else if (path.startsWith(contextRoot)) { path = path.substring(contextRoot.length() + 1); } else if( path.startsWith("/")) { |