@@ -60,7 +60,6 @@ export function NavigationController (Text, Navigation, Session, API_BASE, Shopp
60
60
helpMenu : RBAC . hasAny ( [ 'about' , 'product' , 'documentation' ] )
61
61
}
62
62
EventNotifications . setToastDisplay ( vm . permissions . suiNotifications )
63
- const appBasePath = process . env . NODE_ENV === 'production' ? '' : 'assets/'
64
63
angular . extend ( vm , {
65
64
state : Navigation . state ,
66
65
text : Text . app ,
@@ -72,9 +71,10 @@ export function NavigationController (Text, Navigation, Session, API_BASE, Shopp
72
71
notificationsDrawerShown : false ,
73
72
newNotifications : false ,
74
73
html : {
75
- heading : `${ appBasePath } html/heading.html` ,
76
- notificationBody : `${ appBasePath } html/notification-body.html` ,
77
- notificationFooter : `${ appBasePath } html/notification-footer.html` ,
74
+ // injected into templateCache by navigationInit
75
+ heading : 'notifications/heading.html' ,
76
+ notificationBody : 'notifications/notification-body.html' ,
77
+ notificationFooter : 'notifications/notification-footer.html' ,
78
78
} ,
79
79
handleItemClick : handleItemClick ,
80
80
toggleNotificationsList : ( ) => { vm . notificationsDrawerShown = ! vm . notificationsDrawerShown } ,
@@ -250,3 +250,9 @@ export function NavigationController (Text, Navigation, Session, API_BASE, Shopp
250
250
}
251
251
}
252
252
253
+ /** @ngInject */
254
+ export const navigationInit = function ( $templateCache ) {
255
+ $templateCache . put ( 'notifications/heading.html' , require ( '../../components/notifications/heading.html' ) ) ;
256
+ $templateCache . put ( 'notifications/notification-body.html' , require ( '../../components/notifications/notification-body.html' ) ) ;
257
+ $templateCache . put ( 'notifications/notification-footer.html' , require ( '../../components/notifications/notification-footer.html' ) ) ;
258
+ } ;
0 commit comments