Switch some unnecessary button calls over to links.

This commit is contained in:
yackob03 2013-10-29 13:41:26 -04:00
parent e8cbc9c864
commit a313a77a6b
4 changed files with 7 additions and 19 deletions

View file

@ -229,14 +229,6 @@ function LandingCtrl($scope, $timeout, $location, Restangular, UserService, KeyS
return getMarkedDown(getFirstTextLine(commentString));
};
$scope.browseRepos = function() {
$location.path('/repository/');
};
$scope.createRepo = function() {
$location.path('/new/');
};
$scope.register = function() {
$('.form-signup').popover('hide');
$scope.registering = true;
@ -896,10 +888,6 @@ function V1Ctrl($scope, $location, UserService) {
$scope.$watch( function () { return UserService.currentUser(); }, function (currentUser) {
$scope.user = currentUser;
}, true);
$scope.browseRepos = function() {
$location.path('/repository/');
};
}
function NewRepoCtrl($scope, $location, $http, UserService, Restangular, PlanService) {

View file

@ -61,8 +61,8 @@
<div ng-show="!user.anonymous" class="user-welcome">
<img class="gravatar" src="//www.gravatar.com/avatar/{{ user.gravatar }}?s=128&d=identicon" />
<div class="sub-message">Welcome <b>{{ user.username }}</b>!</div>
<button ng-show="myrepos" class="btn btn-primary" ng-click="browseRepos()">Browse all repositories</button>
<button ng-show="myrepos" class="btn btn-success" ng-click="createRepo()">Create a new repository</button>
<a ng-show="myrepos" class="btn btn-primary" href="/repository/">Browse all repositories</a>
<a ng-show="myrepos" class="btn btn-success" href="/new/">Create a new repository</a>
</div>
</div> <!-- col -->
</div> <!-- row -->

View file

@ -3,7 +3,7 @@
<h3>Welcome <b>{{ user.username }}</b>. Your account is fully activated!</h3>
<div style="margin-top: 20px;">
<button class="btn btn-lg btn-primary" ng-click="browseRepos()">Browse all repositories</button>
<a class="btn btn-lg btn-primary" hred="/repository/">Browse all repositories</a>
</div>
</div>
<div ng-show="!user.anonymous && !user.verified">

View file

@ -75,7 +75,7 @@
<div class="panel panel-default">
<div class="panel-heading">
<!-- Tag dropdown -->
<span class="tag-dropdown dropdown" title="Tags">
<div class="tag-dropdown dropdown" title="Tags">
<i class="fa fa-tag"><span class="tag-count">{{getTagCount(repo)}}</span></i>
<a href="javascript:void(0)" class="dropdown-toggle" data-toggle="dropdown">{{currentTag.name}} <b class="caret"></b></a>
<ul class="dropdown-menu">
@ -83,7 +83,7 @@
<a href="javascript:void(0)" ng-click="setTag(tag.name)">{{tag.name}}</a>
</li>
</ul>
</span>
</div>
<span class="right-title">Tags</span>
</div>
@ -103,7 +103,7 @@
<div class="panel panel-default">
<div class="panel-heading">
<!-- Image dropdown -->
<span class="tag-dropdown dropdown" title="Images">
<div class="tag-dropdown dropdown" title="Images">
<i class="fa fa-archive"><span class="tag-count">{{imageHistory.length}}</span></i>
<a href="javascript:void(0)" class="dropdown-toggle" data-toggle="dropdown">{{currentImage.id.substr(0, 12)}} <b class="caret"></b></a>
<ul class="dropdown-menu">
@ -111,7 +111,7 @@
<a href="javascript:void(0)" ng-click="setImage(image)">{{image.id.substr(0, 12)}}</a>
</li>
</ul>
</span>
</div>
<span class="right-title">Image</span>
</div>