Fixed projects-nav.
parent
d99c7bb5cc
commit
94750d8358
|
@ -46,6 +46,13 @@ class ProjectsNavigationController extends taiga.Controller
|
||||||
|
|
||||||
ProjectsNavigationDirective = ->
|
ProjectsNavigationDirective = ->
|
||||||
link = ($scope, $el, $attrs, $ctrl) ->
|
link = ($scope, $el, $attrs, $ctrl) ->
|
||||||
|
body = angular.element("body")
|
||||||
|
|
||||||
|
$scope.$on "nav:projects-list:open", ->
|
||||||
|
body.toggleClass("open-projects-nav")
|
||||||
|
|
||||||
|
$el.on "click", ".projects-list > li > a", (event) ->
|
||||||
|
$el.toggleClass("open-projects-nav")
|
||||||
|
|
||||||
return {
|
return {
|
||||||
link: link
|
link: link
|
||||||
|
@ -147,6 +154,10 @@ ProjectMenuDirective = ($log, $compile, $rootscope) ->
|
||||||
link = ($scope, $el, $attrs, $ctrl) ->
|
link = ($scope, $el, $attrs, $ctrl) ->
|
||||||
renderMainMenu($el)
|
renderMainMenu($el)
|
||||||
|
|
||||||
|
$el.on "click", ".logo > a", (event) ->
|
||||||
|
event.preventDefault()
|
||||||
|
$rootscope.$broadcast("nav:projects-list:open")
|
||||||
|
|
||||||
$scope.$on "$viewContentLoaded", (ctx) ->
|
$scope.$on "$viewContentLoaded", (ctx) ->
|
||||||
if ctx.targetScope.$$childHead is null
|
if ctx.targetScope.$$childHead is null
|
||||||
$log.error "No scope found for render menu."
|
$log.error "No scope found for render menu."
|
||||||
|
|
Loading…
Reference in New Issue