aboutsummaryrefslogtreecommitdiff
path: root/src/main/webapp/apps
diff options
context:
space:
mode:
authorTrygve Laugstøl <trygvis@inamo.no>2013-01-05 22:39:18 +0100
committerTrygve Laugstøl <trygvis@inamo.no>2013-01-05 22:39:18 +0100
commit12606726c11efbbf7213b05284c94e28a1ae4b8e (patch)
tree415a400218f3bbaac4f13a43461446f64f74028c /src/main/webapp/apps
parentabf160e56be50781b0f78f3f938513ab6102809b (diff)
downloadesper-testing-12606726c11efbbf7213b05284c94e28a1ae4b8e.tar.gz
esper-testing-12606726c11efbbf7213b05284c94e28a1ae4b8e.tar.bz2
esper-testing-12606726c11efbbf7213b05284c94e28a1ae4b8e.tar.xz
esper-testing-12606726c11efbbf7213b05284c94e28a1ae4b8e.zip
o Including state in both badge and badge progress.
o Removing count from badge, inserting one badge per badge received.
Diffstat (limited to 'src/main/webapp/apps')
-rwxr-xr-xsrc/main/webapp/apps/frontPageApp/frontPageApp.js6
-rwxr-xr-xsrc/main/webapp/apps/frontPageApp/person.html77
2 files changed, 54 insertions, 29 deletions
diff --git a/src/main/webapp/apps/frontPageApp/frontPageApp.js b/src/main/webapp/apps/frontPageApp/frontPageApp.js
index 7678f0d..ef0de81 100755
--- a/src/main/webapp/apps/frontPageApp/frontPageApp.js
+++ b/src/main/webapp/apps/frontPageApp/frontPageApp.js
@@ -40,7 +40,7 @@ function PersonCtrl($scope, $routeParams, Person, Badge, Build, PagingTableServi
$scope.recentBuilds = builds;
});
- Badge.query({person: personUuid}, function (badges) {
- $scope.badges = badges;
- });
+// Badge.query({person: personUuid}, function (badges) {
+// $scope.badges = badges;
+// });
}
diff --git a/src/main/webapp/apps/frontPageApp/person.html b/src/main/webapp/apps/frontPageApp/person.html
index 3544221..8573afe 100755
--- a/src/main/webapp/apps/frontPageApp/person.html
+++ b/src/main/webapp/apps/frontPageApp/person.html
@@ -3,7 +3,7 @@
<navbar/>
<div class="page-header">
- <h1>{{person.name}}</h1>
+ <h1>{{person.person.name}}</h1>
</div>
<ul class="nav nav-tabs">
@@ -12,35 +12,60 @@
</ul>
<div id="overview" ng-show="mode == 'overview'">
- <h3>Badges</h3>
+ <div class="row">
+ <div class="span6">
+ <h3>Upcoming</h3>
+ <table>
+ <tr ng-repeat="badge in person.badgesInProgress">
+ <td style="padding-right: 1em">{{badge.name}}</td>
+ <td style="width: 100%">
+ <div class="progress" style="margin-bottom: 0;" title="Progress: {{badge.progress}} of {{badge.goal}}">
+ <div class="bar" style="width: {{badge.progress / badge.goal * 100}}%;"></div>
+ </div>
+ </td>
+ </tr>
+ </table>
- <p ng-repeat="badge in person.badges">
- <span class="badge-level-{{badge.level}} badge">{{badge.name}}</span><span ng-show="badge.count > 1"> x {{badge.count}}</span>
- </p>
+ <h3>Badges</h3>
+ <ul class="unstyled">
+ <li ng-repeat="badge in person.badges">
+<!--
+ <span class="badge-level-{{badge.level}} badge">{{badge.name}}</span>
+-->
+ <strong>{{badge.name}}</strong>
+<!--
+ <i class="icon-user ng-class: {{{1: 'badge-level-1', 2: 'badge-level-2', 3: 'badge-level-3'}[badge.level]}}"></i>
+-->
+ <span class="badge-level-{{badge.level}} badge">
+ <i class="icon-user"></i>
+ </span>
- <div ng-repeat="badge in person.badgesInProgress">
- <div class="progress">
- <div class="bar" style="width: {{badge.progress / badge.goal * 100}}%;">{{badge.name}}</div>
+ {{badge.createdDate | date:'medium'}}
+ </li>
+ </ul>
+ </div>
+ <div class="span6">
+ <h3>Recent builds</h3>
+ <table class="table">
+ <thead>
+<!--
+ <tr>
+ <th>Date</th>
+ <th>Success</th>
+ <th></th>
+ </tr>
+-->
+ </thead>
+ <tbody>
+ <tr ng-repeat="build in recentBuilds" class="{{{true: 'success', false: 'error'}[build.success]}}">
+ <td>{{build.timestamp | date:'medium'}}</td>
+ <td>{{{true: 'Success', false: 'Failure'}[build.success]}}</td>
+ <td><a href="/build/{{build.uuid}}">Details</a></td>
+ </tr>
+ </tbody>
+ </table>
</div>
</div>
-
- <h3>Recent builds</h3>
- <table class="table">
- <thead>
- <tr>
- <th>Date</th>
- <th>Success</th>
- <th></th>
- </tr>
- </thead>
- <tbody>
- <tr ng-repeat="build in recentBuilds" class="{{{true: 'success', false: 'error'}[build.success]}}">
- <td>{{build.timestamp | date:'medium'}}</td>
- <td>{{build.success}}</td>
- <td><a href="/build/{{build.uuid}}">Details</a></td>
- </tr>
- </tbody>
- </table>
</div>
<div id="builds" ng-show="mode == 'builds'">