Closed marwenlandoulsi closed 7 years ago
In client/components/modal/modal.service.js
, after this line:
export function Modal($rootScope, $uibModal) {
add this:
'ngInject';
It might be easier to use the ui-bootstrap modal directly, though.
same problem :(
Please fix the code formatting in your OP so I can read it
done i fix it
The placement of your /*@ngInject*/
directive is incorrect. See https://github.com/huston007/ng-annotate-loader & https://github.com/olov/ng-annotate#library-api
thinks it's work :)
I need help : when i use the modal.service.js, i got this bug. any solution please.
this is my Admin.controller.js :
and the app. js :
finnaly this is the bug :
Error: [$injector:strictdi] Modal is not using explicit annotation and cannot be invoked in strict mode http://errors.angularjs.org/1.5.8/$injector/strictdi?p0=Modal at http://localhost:8086/vendor.bundle.js:195:13 at Function.annotate [as $$annotate] (http://localhost:8086/vendor.bundle.js:4079:18) at injectionArgs (http://localhost:8086/vendor.bundle.js:4806:37) at Object.invoke (http://localhost:8086/vendor.bundle.js:4837:19) at Object.enforcedReturnValue [as $get] (http://localhost:8086/vendor.bundle.js:4684:38) at Object.invoke (http://localhost:8086/vendor.bundle.js:4845:20) at http://localhost:8086/vendor.bundle.js:4644:38 at getService (http://localhost:8086/vendor.bundle.js:4791:40) at injectionArgs (http://localhost:8086/vendor.bundle.js:4815:59) at Object.instantiate (http://localhost:8086/vendor.bundle.js:4857:19) at $controller (http://localhost:8086/vendor.bundle.js:10496:29) at Object. (http://localhost:8086/vendor.bundle.js:38077:29)
at http://localhost:8086/vendor.bundle.js:1374:19
at invokeLinkFn (http://localhost:8086/vendor.bundle.js:10061:10)
at nodeLinkFn (http://localhost:8086/vendor.bundle.js:9462:12)
at compositeLinkFn (http://localhost:8086/vendor.bundle.js:8747:14)
at publicLinkFn (http://localhost:8086/vendor.bundle.js:8627:31)
at lazyCompilation (http://localhost:8086/vendor.bundle.js:8971:26)
at updateView (http://localhost:8086/vendor.bundle.js:38005:24)
at http://localhost:8086/vendor.bundle.js:37954:12
at Scope.$broadcast (http://localhost:8086/vendor.bundle.js:18132:29)
at http://localhost:8086/vendor.bundle.js:37335:23
at processQueue (http://localhost:8086/vendor.bundle.js:16510:29)
at http://localhost:8086/vendor.bundle.js:16526:28
at Scope.$eval (http://localhost:8086/vendor.bundle.js:17809:29)
at Scope.$digest (http://localhost:8086/vendor.bundle.js:17622:32)
at Scope.$apply (http://localhost:8086/vendor.bundle.js:17917:25)
at bootstrapApply (http://localhost:8086/vendor.bundle.js:1888:16)
at Object.invoke (http://localhost:8086/vendor.bundle.js:4845:20)
at doBootstrap (http://localhost:8086/vendor.bundle.js:1886:15)
at Object.bootstrap (http://localhost:8086/vendor.bundle.js:1906:13)
at http://localhost:8086/app.bundle.js:100:22
at HTMLDocument.trigger (http://localhost:8086/vendor.bundle.js:3334:8)
at defaultHandlerWrapper (http://localhost:8086/vendor.bundle.js:3624:12)
at HTMLDocument.eventHandler (http://localhost:8086/vendor.bundle.js:3612:10)