mirror of
https://github.com/openfoodfoundation/openfoodnetwork
synced 2026-03-13 04:00:21 +00:00
uss oop for nav check
This commit is contained in:
@@ -3,7 +3,7 @@ angular.module("admin.utils").directive "navCheck", (NavigationCheck)->
|
||||
scope:
|
||||
navCallback: '&'
|
||||
link: (scope,element,attributes) ->
|
||||
# Define navigationCallback on a controller in $scope, otherwise this default will be used:
|
||||
# Define navigationCallback on a controller in scope, otherwise this default will be used:
|
||||
scope.navCallback ||= ->
|
||||
"You will lose any unsaved work!"
|
||||
NavigationCheck.register(scope.navCallback)
|
||||
|
||||
Reference in New Issue
Block a user