mirror of
https://github.com/HabitRPG/habitica.git
synced 2025-12-18 15:17:25 +01:00
Fix member modal on static/front
This commit is contained in:
@@ -6,11 +6,12 @@ window.habitrpg = angular.module('habitrpg', ['chieffancypants.loadingBar', 'ui.
|
||||
.constant("STORAGE_SETTINGS_ID", 'habit-mobile-settings')
|
||||
.constant("MOBILE_APP", false)
|
||||
|
||||
.controller("RootCtrl", ['$scope', '$location', '$modal', '$http', function($scope, $location, $modal, $http){
|
||||
.controller("RootCtrl", ['$scope', '$location', '$modal', '$http', 'Stats', function($scope, $location, $modal, $http, Stats){
|
||||
var memberId = $location.search()['memberId'];
|
||||
if (memberId) {
|
||||
$http.get('/api/v2/members/'+memberId).success(function(data, status, headers, config){
|
||||
$scope.profile = data;
|
||||
$scope.profile = window.habitrpgShared.wrap(data, false);
|
||||
$scope.statCalc = Stats;
|
||||
$scope.Content = window.habitrpgShared.content;
|
||||
$modal.open({
|
||||
templateUrl: 'modals/member.html',
|
||||
@@ -18,8 +19,6 @@ window.habitrpg = angular.module('habitrpg', ['chieffancypants.loadingBar', 'ui.
|
||||
});
|
||||
})
|
||||
}
|
||||
|
||||
$scope.Math = window.Math;
|
||||
}])
|
||||
|
||||
.controller("PlansCtrl", ['$rootScope','Analytics',
|
||||
|
||||
Reference in New Issue
Block a user