Issue 2772 - projects tab mustn't appear in your profile
parent
e5106c830d
commit
00070ebc24
|
@ -9,6 +9,7 @@ ProfileTabDirective = () ->
|
||||||
scope.tab.icon = attrs.tabIcon
|
scope.tab.icon = attrs.tabIcon
|
||||||
scope.tab.active = !!attrs.tabActive
|
scope.tab.active = !!attrs.tabActive
|
||||||
|
|
||||||
|
if scope.$eval(attrs.tabDisabled) != false
|
||||||
ctrl.addTab(scope.tab)
|
ctrl.addTab(scope.tab)
|
||||||
|
|
||||||
return {
|
return {
|
||||||
|
@ -16,8 +17,7 @@ ProfileTabDirective = () ->
|
||||||
scope: {},
|
scope: {},
|
||||||
require: "^tgProfileTabs",
|
require: "^tgProfileTabs",
|
||||||
link: link,
|
link: link,
|
||||||
transclude: true,
|
transclude: true
|
||||||
replace: true
|
|
||||||
}
|
}
|
||||||
|
|
||||||
angular.module("taigaProfile")
|
angular.module("taigaProfile")
|
||||||
|
|
|
@ -7,6 +7,8 @@ class ProfilePageController extends taiga.Controller
|
||||||
]
|
]
|
||||||
|
|
||||||
constructor: (@appTitle, @currentUserService, @routeParams, @userService) ->
|
constructor: (@appTitle, @currentUserService, @routeParams, @userService) ->
|
||||||
|
@.isCurrentUser = false
|
||||||
|
|
||||||
if @routeParams.slug
|
if @routeParams.slug
|
||||||
@userService
|
@userService
|
||||||
.getUserByUserName(@routeParams.slug)
|
.getUserByUserName(@routeParams.slug)
|
||||||
|
|
|
@ -6,7 +6,7 @@ div.profile.centered(ng-if="vm.user")
|
||||||
div(tg-profile-tab="activity", tab-title="{{'USER.PROFILE.ACTIVITY_TAB' | translate}}", tab-icon="icon-timeline", tab-active)
|
div(tg-profile-tab="activity", tab-title="{{'USER.PROFILE.ACTIVITY_TAB' | translate}}", tab-icon="icon-timeline", tab-active)
|
||||||
div(tg-user-timeline, userId="vm.user.get('id')")
|
div(tg-user-timeline, userId="vm.user.get('id')")
|
||||||
|
|
||||||
div(tg-profile-tab="projects", tab-title="{{'USER.PROFILE.PROJECTS_TAB' | translate}}", tab-icon="icon-project")
|
div(tab-disabled="{{vm.isCurrentUser}}", tg-profile-tab="projects", tab-title="{{'USER.PROFILE.PROJECTS_TAB' | translate}}", tab-icon="icon-project")
|
||||||
div(tg-profile-projects, userId="vm.user.get('id')")
|
div(tg-profile-projects, userId="vm.user.get('id')")
|
||||||
|
|
||||||
div(tg-profile-tab="contacts", tab-title="{{'USER.PROFILE.CONTACTS_TAB' | translate}}", tab-icon="icon-team")
|
div(tg-profile-tab="contacts", tab-title="{{'USER.PROFILE.CONTACTS_TAB' | translate}}", tab-icon="icon-team")
|
||||||
|
|
Loading…
Reference in New Issue