Skip to content
This repository has been archived by the owner on May 4, 2022. It is now read-only.

Commit

Permalink
Merge pull request #364 from UW-Madison-DoIT/utilize-new-app-header-c…
Browse files Browse the repository at this point in the history
…ontroller

MUMUP-2164 : Utilize new app header add to home
  • Loading branch information
Tim Levett committed Dec 29, 2015
2 parents 797370a + 832822a commit 0e23132
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 18 deletions.
6 changes: 5 additions & 1 deletion angularjs-portal-home/src/main/webapp/js/app-config.js
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,11 @@ define(['angular'], function(angular) {
'eventsSearchURL' : 'https://today.wisc.edu/events/search?term=',
'loginURL' : '/portal/Login?profile=bucky',
'logoutURL' : '/portal/Logout',
'rootURL' : '/web'
'rootURL' : '/web',
'addToHomeURLS' : {
'layoutURL' : '/portal/web/layoutDoc?tab=UW Bucky Home',
'addToHomeActionURL' : '/portal/web/layout?tabName=UW Bucky Home&action=addPortlet&fname='
}
})
.constant('FOOTER_URLS', [
{ "url" : "static/myuw-help",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,6 @@
<script type="text/ng-template" id="static-content-options.html">
<div ng-controller="StaticContentController as staticContentCtrl">
<ul>
<li role="presentation" class="fname-{{::portlet.fname}}" ng-hide='inFavorites'>
<a ng-click="staticContentCtrl.addToHome(portlet)" href='javascript:;'><span>Add to home</span></a>
</li>
<li role="presentation">
<a ng-click="openRating('sm',portlet.fname, portlet.title)" href='javascript:;'><span>Rate this App</span></a>
</li>
Expand All @@ -15,7 +12,10 @@
<app-header-two-way-bind
app-title="portlet.title"
app-icon="portlet.faIcon"
app-option-template="'static-content-options.html'"></app-header-two-way-bind>
app-option-template="'static-content-options.html'"
app-fname='portlet.fname'
app-action-link-text="'Add to home'"
app-add-to-home='true'></app-header-two-way-bind>
<div role="main" class="col-xs-12 no-padding portlet-body">
<div data-loading class='loading-gif abs-bottom-right'><img src="img/ajax-loader.gif" alt="Loading content, please wait"></div>
<div ng-bind-html="portlet.exclusiveContent" class="up-portlet-content-wrapper" id="content-{{::portlet.nodeId}}">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,6 @@
<script type="text/ng-template" id="static-content-options.html">
<div ng-controller="StaticContentController as staticContentCtrl">
<ul>
<li role="presentation" class="fname-{{::portlet.fname}}" ng-hide='inFavorites'>
<a ng-click="staticContentCtrl.addToHome(portlet)" href='javascript:;'><span>Add to home</span></a>
</li>
<li role="presentation">
<a ng-click="openRating('sm',portlet.fname, portlet.title)" href='javascript:;'><span>Rate this App</span></a>
</li>
Expand All @@ -15,7 +12,10 @@
<app-header-two-way-bind
app-title="portlet.title"
app-icon="portlet.faIcon"
app-option-template="'static-content-options.html'"></app-header-two-way-bind>
app-option-template="'static-content-options.html'"
app-fname='portlet.fname'
app-action-link-text="'Add to home'"
app-add-to-home='true'></app-header-two-way-bind>

<div role="main" class="col-xs-12 no-padding portlet-body">
<loading-gif data-object='loading'></loading-gif>
Expand Down
14 changes: 5 additions & 9 deletions build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,34 +3,30 @@
if [ "$1" = "master" ]; then
cp angularjs-portal-home/src/main/webapp/js/app-config.js angularjs-portal-home/src/main/webapp/js/app-config.js.bak
cp angularjs-portal-home/src/main/webapp/js/master-app-config.js angularjs-portal-home/src/main/webapp/js/app-config.js

mvn -Djava.awt.headless=true clean install
else

if [ "$#" = "0" ]; then
mvn -Djava.awt.headless=true clean install
else
else
mvn -Djava.awt.headless=true $@
fi

fi

pushd angularjs-portal-frame
mvn -Djava.awt.headless=true tomcat7:redeploy
popd

pushd angularjs-portal-home
mvn -Djava.awt.headless=true tomcat7:redeploy
popd

if [ "$1" = "master" ]; then
mv angularjs-portal-home/src/main/webapp/js/app-config.js.bak angularjs-portal-home/src/main/webapp/js/app-config.js
fi


unamestr=`uname`
if [[ "$unamestr" == 'Linux' ]]; then
notify-send "build complete for angular"
notify-send "build complete for angular"
elif [[ "$unamestr" == 'Darwin' ]]; then
osascript -e 'display notification "angularJSportal build.sh finished" with title "Angular portal deployed" sound name "Hero"'
fi

0 comments on commit 0e23132

Please sign in to comment.