Reputation: 73
Using 5.2.11 of https://github.com/m-e-conroy/angular-dialog-service/tree/v5.2.11
Angular 1.4.8
I'm adding ui.bootstrap and dialogs.main to my app file:
var FuelTeamworkHelperApp = angular.module( "FuelTeamworkHelperApp", [ "ui.bootstrap", "dialogs.main", "ui.router", "ncy-angular-breadcrumb", "ngResource", "angular-loading-bar", "ngAnimate", "angular-growl", "ngPrettyJson", "angularMoment" ] );
However, I get an error:
Uncaught Error: [$injector:modulerr] http://errors.angularjs.org/1.4.8/$injector/modulerr?p0=FuelTeamworkHelperA…alhost%3A2804%2Fassets%2Fjs%2Fvendor%2Fangular%2Fangular.min.js%3A19%3A463)
Scripts are all definitely in the HTML and browser is loading them.
I tried using 'dialogs.controllers' which works, though according to the documentation that's not how you're meant to use it..!
Not sure how to then get it into my controllers either, which name I should be using? Just 'dialogs' doesn't work.
angular
.module( "FuelTeamworkHelperApp" )
.controller( "AdminSettingsController", AdminSettingsController );
//---
AdminSettingsController.$inject = [ "$scope", "$rootScope", "$state", "$stateParams", "$filter", "$resource", "$q", "growl", "dialogs", "FuelTeamworkHelperConfig", "AppSettings", "SowCustomListSections" ];
function AdminSettingsController ( $scope, $rootScope, $state, $stateParams, $filter, $resource, $q, growl, dialogs, FuelTeamworkHelperConfig, AppSettings, SowCustomListSections ) {
...
Upvotes: 4
Views: 508
Reputation: 73
Answer to this (as commented by Mike) was the need to include the dependancy ngSanitize.
https://code.angularjs.org/1.4.8/angular-sanitize.min.js
docs.angularjs.org/api/ngSanitize
Upvotes: 1