2016-08-22 2 views
0

jicester 프로젝트에서 "oi.select"를 가져 오는 데 문제가 있습니다. 내 컨트롤러 JS 파일 :Jhipster와 Angular JS의 인젝터 오류

(function() { 
     'use strict'; 

     angular 
      .module('myApp') 
      .controller('UserProfileDialogController', UserProfileDialogController); 

     UserProfileDialogController.$inject = ['$timeout', '$scope', '$stateParams', '$uibModalInstance', 'entity', 'UserProfile', 'MdmEnumeration','oi.select']; 

     function UserProfileDialogController ($timeout, $scope, $stateParams, $uibModalInstance, entity, UserProfile, MdmEnumeration,oiSelect) { 

} .... 

나는 이미 내 index.html을에 주입 한 :

  • <script src="bower_components/oi.select/dist/select-tpls.min.js"></script>

  • <link rel="stylesheet" href="bower_components/oi.select/dist/select.min.css"> 내가 따라와 오류가 발생합니다 :

    angular.js : 13550 오류 : [$ 주입기 : unpr] 알 수없는 제공 : oi.selectProvider < - oi.select < - UserProfileDialogController

    어떤 아이디어?

+0

oi.select 문서에서 본 것부터 지시문입니다. 컨트롤러 대신 모듈에 종속성을 추가하려고 했습니까? https://github.com/tamtakoe/oi.select'angular.module ('myApp', [ 'oi.select']); ' –

+0

예 시도했는데 다음과 같은 오류가 발생했습니다 : '잡히지 않은 오류 : [ $ injector : modulerr] 오류 : [$ injector : unpr] 알 수없는 공급자 : $ stateProvider' – DyM

+0

ui-router와 관련된 다른 문제로 보입니다. 모듈 eProductApp를 인스턴스화하지 못했습니다. 그걸 사용 하시나요? https://github.com/angular-ui/ui-router –

답변

0

이 문제가 해결되었습니다. 나는 app.module.js 파일을 가지고 있는데이 모듈은 앱에 삽입 할 모든 모듈을 포함하고있다. "oi.select"를 추가하면 작동합니다. 도움을 주셔서 감사합니다

관련 문제