Author: erinnp
Date: Thu Aug 15 20:45:28 2013
New Revision: 1514483

URL: http://svn.apache.org/r1514483
Log:
Fixing opensocial thing

Modified:
    
rave/branches/angular/rave-portal-resources/src/main/webapp/WEB-INF/jsp/views/angular.jsp
    
rave/branches/angular/rave-portal-resources/src/main/webapp/static/script/common/directives/Base.js
    
rave/branches/angular/rave-portal-resources/src/main/webapp/static/script/common/directives/index.js
    
rave/branches/angular/rave-portal-resources/src/main/webapp/static/script/common/services/Context.js
    
rave/branches/angular/rave-portal-resources/src/main/webapp/static/script/common/services/index.js

Modified: 
rave/branches/angular/rave-portal-resources/src/main/webapp/WEB-INF/jsp/views/angular.jsp
URL: 
http://svn.apache.org/viewvc/rave/branches/angular/rave-portal-resources/src/main/webapp/WEB-INF/jsp/views/angular.jsp?rev=1514483&r1=1514482&r2=1514483&view=diff
==============================================================================
--- 
rave/branches/angular/rave-portal-resources/src/main/webapp/WEB-INF/jsp/views/angular.jsp
 (original)
+++ 
rave/branches/angular/rave-portal-resources/src/main/webapp/WEB-INF/jsp/views/angular.jsp
 Thu Aug 15 20:45:28 2013
@@ -29,25 +29,30 @@
     <link 
href="//netdna.bootstrapcdn.com/twitter-bootstrap/2.2.2/css/bootstrap-combined.min.css"
 rel="stylesheet">
     <link 
href="http://code.jquery.com/ui/1.10.2/themes/smoothness/jquery-ui.css"; 
rel="stylesheet">
     <link rel="stylesheet" href="<spring:url value="/static/css/rave.css"/>"/>
-
-    <%--
+    <script>
+        require = {
+            paths: {}
+        };
+    </script>>
+<%--
     check to see if the javaScriptDebugMode is on, if so render the individual 
JS files,
     otherwise render the minified single file
     --%>
     <c:choose>
         <c:when test="${jsDebugMode == '1'}">
             <script>
-                require = { baseUrl: '<spring:url value="/static/script/"/>' };
+                require.baseUrl = '<spring:url value="/static/script/"/>';
             </script>
         </c:when>
         <c:otherwise>
             <script>
-                require = { baseUrl: '<spring:url 
value="/static/script-built/"/>' };
+                require.baseUrl = '<spring:url 
value="/static/script-built/"/>';
             </script>
         </c:otherwise>
     </c:choose>
     <script data-main="${context}/main.js"
             
src="//cdnjs.cloudflare.com/ajax/libs/require.js/2.1.5/require.min.js"></script>
+
 </head>
 <body>
 <div class="wrapper" ng-include="'/portal/static/html/${context}/index.html'" 
ng-cloak>

Modified: 
rave/branches/angular/rave-portal-resources/src/main/webapp/static/script/common/directives/Base.js
URL: 
http://svn.apache.org/viewvc/rave/branches/angular/rave-portal-resources/src/main/webapp/static/script/common/directives/Base.js?rev=1514483&r1=1514482&r2=1514483&view=diff
==============================================================================
--- 
rave/branches/angular/rave-portal-resources/src/main/webapp/static/script/common/directives/Base.js
 (original)
+++ 
rave/branches/angular/rave-portal-resources/src/main/webapp/static/script/common/directives/Base.js
 Thu Aug 15 20:45:28 2013
@@ -17,14 +17,17 @@
  * under the License.
  */
 
-define(['rave'], function (rave) {
+define([], function (rave) {
     return [ 'Context',
-        function(context){
-            return function link(scope, el, attrs) {
-                var href = attrs.href;
+        function (context) {
+            return {
+                restrict: 'E',
+                link: function link(scope, el, attrs) {
+                    var href = attrs.href;
 
-                context.setContext(href);
+                    context.setContext(href);
+                }
             }
         }
-    ];
+    ]
 });
\ No newline at end of file

Modified: 
rave/branches/angular/rave-portal-resources/src/main/webapp/static/script/common/directives/index.js
URL: 
http://svn.apache.org/viewvc/rave/branches/angular/rave-portal-resources/src/main/webapp/static/script/common/directives/index.js?rev=1514483&r1=1514482&r2=1514483&view=diff
==============================================================================
--- 
rave/branches/angular/rave-portal-resources/src/main/webapp/static/script/common/directives/index.js
 (original)
+++ 
rave/branches/angular/rave-portal-resources/src/main/webapp/static/script/common/directives/index.js
 Thu Aug 15 20:45:28 2013
@@ -17,8 +17,8 @@
  * under the License.
  */
 
-define(['./Base'],
-    function (base) {
+define(['angular', './Base'],
+    function (angular, base) {
         var directives = angular.module('common.directives', []);
 
         directives.directive('base', base);

Modified: 
rave/branches/angular/rave-portal-resources/src/main/webapp/static/script/common/services/Context.js
URL: 
http://svn.apache.org/viewvc/rave/branches/angular/rave-portal-resources/src/main/webapp/static/script/common/services/Context.js?rev=1514483&r1=1514482&r2=1514483&view=diff
==============================================================================
--- 
rave/branches/angular/rave-portal-resources/src/main/webapp/static/script/common/services/Context.js
 (original)
+++ 
rave/branches/angular/rave-portal-resources/src/main/webapp/static/script/common/services/Context.js
 Thu Aug 15 20:45:28 2013
@@ -20,7 +20,7 @@
 define([], function () {
     return [
         function Context(){
-            var context = '';
+            var context = '/portal';
 
             return {
                 getContext: function(){

Modified: 
rave/branches/angular/rave-portal-resources/src/main/webapp/static/script/common/services/index.js
URL: 
http://svn.apache.org/viewvc/rave/branches/angular/rave-portal-resources/src/main/webapp/static/script/common/services/index.js?rev=1514483&r1=1514482&r2=1514483&view=diff
==============================================================================
--- 
rave/branches/angular/rave-portal-resources/src/main/webapp/static/script/common/services/index.js
 (original)
+++ 
rave/branches/angular/rave-portal-resources/src/main/webapp/static/script/common/services/index.js
 Thu Aug 15 20:45:28 2013
@@ -17,7 +17,7 @@
  * under the License.
  */
 
-define(['angular', './Context', '../directives/index'], function (angular, 
context) {
+define(['angular', 'common/services/Context', 'common/directives/index'], 
function (angular, context) {
     var services = angular.module('common.services', ['common.directives']);
 
     services.service('Context', context);


Reply via email to