new

Stack Overflow for Teams

A private, secure home for your team's questions and answers.

Learn more
0
votes
0answers
18 views

Unable to bind controller $scope to directive modal [duplicate]

I have created a directive of bootstrap modal. I have binded $scope.reaso,$scope.modalHeader ,$scope.activity, $scope.myLeftButton from parent controll to the directive.I am changing the $scope.reason ...
-1
votes
0answers
13 views

Not able to create new folder in angular through terminal command

I want to create a new component (folder) in Angular 2 through Terminal I used command ng g c foldername but command is not found
1
vote
0answers
49 views

$scope of abstract state controller is not being destroyed upon leaving - AngularJS

I have an abstract state app, a child state app.dashboard, and a login state login in ionic1 application. Each state has its template and controller, except for app state; it only has a controller, ...
0
votes
1answer
19 views

How to send my data in headers in post request .?

I want to send my data in headers, so I converted my data into base64 and I'm getting the output in $http.defaults.headers.common['Authorization']. But how to post the basic auth data in headers in ...
0
votes
1answer
35 views

some params dont pass value when changing state angularjs

I have weird problem, I cant pass value of some params to other state in angular js. I tried to assign value to params for search params before doing http request .state('tab.box', { url: '/...
0
votes
1answer
15 views

How can i make user access control in my existing Angularjs app

I build a login auth application using Angularjs. I want to make changes to that application to make it user access control app. How can I achieve that? Any suggestions would help me to move forward ...
0
votes
1answer
28 views

How to load multiple components in one place but data should not change which user has entered

I have 3 components PersonalInfoComponent , EducationalInfoComponent and ExperienceComponent. I am loading all these components in ResumeComponent. When user enters some info using form in ...
0
votes
0answers
13 views

Header scope and relative controller not re-executed after location search

I am currently trying to solve if there is a best practice to manage the situation on subject. I have some info (like page label, menu items) stored in the scope of the Header component, and when in ...
-1
votes
1answer
46 views

ng-click is not giving any response while hitting web api

The html page is here with the whole code. <body ng-app="mymodule"> <label>Search:</label><input type="text" placeholder="Search Here" ng-model="search" /> <table ...
0
votes
2answers
93 views

Angular Filter Shows Not Matched Values When Search On List Of Elements

actually I have been trying to implement some custom drop-down search functionality in my application. And this drop-down contains a number of versions in this format. Please don't consider this ...
0
votes
1answer
81 views

Angularjs url is being changed when using $http.get().then()

I have the following code: First I log the url and I get desired url: variants/images/30808708?ssl=true var myUrl = self.baseUrl + 'images/' + self.currentItem.variants[variant].imageId + '?ssl=...
1
vote
1answer
52 views

Error: Unknown provider: PopupProvider <- Popup

how to resovle the error when I use the angular-popup.js Plug-ins? as the following error log the angularjs code as the following var app = angular.module('app', ['angular-popups']); ...
-1
votes
1answer
57 views

Is It possible to call angularjs app by post request?

Is it possible to open angular application from another application as widget or as post request? (I did it as get request)
0
votes
0answers
79 views

angular custom directive inside ng-repeat not perform on second load

(function() { 'use strict'; angular.module('app.core').directive('abrRecText', abrRecText); function abrRecText() { return { restrict: 'E', scope: { details: '=' },...
0
votes
2answers
260 views

Angular routing to redirect on new server with query string

Can someone help me understand how I can redirect an Angular state to a new URL with the query string parameters same as old ones? Example If my Angular application is on http://example.com, then ...
1
vote
1answer
332 views

AngularJS module.controller vs $controllerProvider.register

I'm trying to add controller dynamically in my AngularJS application. On sub-domain, I have anotherController.js file. Here's anotherController.js content: function anotherControllerWrapper() { ...
1
vote
1answer
78 views

Changing value of $scope on ng-click with ui-sref

This is absolutely killing me. This is where I'm at: And when I arrive to this page it prints this into the console: Then I click on lorem2 which as a ng-click thats supposed to change the ...
-7
votes
1answer
34 views

How can convert script coding into angularJS coding

this is my script coding for left side menu slide left and right. I want to convert it into angularJS, I copied it from other website and unable to understand. <script> var menuLeft = ...
3
votes
1answer
105 views

angular components not refreshing on route change (in ui router)

i have described my states like `.state('community.messaging', { template: '<ui-view></ui-view>', url: '/messaging', abstract: true }) .state('...
-1
votes
1answer
39 views

Calling reset function with variables for multiple form is not working in angularJs

This is reset function to reset form: $scope.resetForm = function(formData,formName) { $scope.formData = {}; $scope....
1
vote
0answers
38 views

Unable to load child states in angular

I am facing a very peculiar problem in angular1 and it might need a lot context to understand for someone to answer. I have been working on angular for around 4 weeks now but a very strange problem ...
0
votes
2answers
80 views

Angularjs keep data on form submit to use in other page [duplicate]

I have a submit function in a controller and I need to keep the data entered in the form to make available it to show in another page of my web (I am using ui-router). Can anyone please give me a ...
0
votes
2answers
22 views

Angularjs calling a service function from the controller

I've been searching the web but I can't find why I get this error "checkDishService.checkDish is not a function" in the console when calling a service function from my controller. Please, help! ...
0
votes
0answers
29 views

How do you call controller injections called again when changing from child route?

I want to parent controller to resolve its injection again when state changes from child to parent. .state('settings.billing', { url: '/billing', controller: 'BillingCtrl as vm', ...
0
votes
0answers
186 views

Dynamic URL routing angular js with $location

Note: sorry for any confusion i am new to angular can't find any related answer on web. Question: To manager auth of user during login and logout i have set its login details in $cookieStore which ...
0
votes
0answers
13 views

why data is not getting from database to table?

My controller Code is: $scope.getRegistration=function(){ $http.get('/api').success(function(data) { $scope.registration=data; }).error(function(status) { console.log('...
0
votes
1answer
68 views

How to optimize AngularJS config function

I have following config functions and run functions in my app.js file. What is the best way to optimize these function method ? can we move these into one single config function ? Or Can we move these ...
-1
votes
1answer
136 views

How to preserve the old values of a form after changing the view in AngularJS

I have some input fields like radio buttons, text box, dropdown, text fields which is filled up by user and on click of a button a new view page opens. Now on back button press I want to show those ...
0
votes
1answer
226 views

Upon a input change event, scope variable in controller and Interpolated value of same variable on template are different

I have an app with two routes/templates login and main. The login template's user input values are bound to two scope variables username and isAdmin. The scope variables are initialized with 'abc' and ...
0
votes
1answer
55 views

View is not rendering

Below is my angular code MDIApp.controller("loginCtrl", function ($scope, $http,$location,$sce) { $scope.toTrustedHTML = function (html) { return $sce.trustAsHtml(html); }...
0
votes
1answer
171 views

how to pass object in child component to the parents in angularJS

i'm looking to make a mulit step from in angularJS 1.5x and here is my file format -events --events.component.js --events.controller.js -form.component.js -form.controller.js in my form.component.js ...
0
votes
0answers
172 views

Angular.js + ui-router wrong controller

I'm using angular 1.6.1 and angular-ui-router 0.3.2. I have basic routes set-up as follow: { state: 'home', config: { url: '/home', templateUrl: '...', title: 'home' } }, { state:...
0
votes
1answer
127 views

Ng-Repeat showing irregular behavior with one time binding

I am having a ng-repeat directive that is running on the array on object. I am facing a specific scenario in which, When I Bind my object properties with one time binding they are now getting ...
1
vote
2answers
206 views

AngularJS - How to keep the scope variables live even after going to another state and coming back?

I my angular app, I have a list of items shown in one page and on clicking continue button, the app will move to another state. In that page there is a "Back" button which has the code $state.go('...
0
votes
1answer
132 views

Access-Control-Allow-Origin in angularjs production

In my angularjs application im trying to get some information, in my case longtude and latitude from a rest service online, but is giving me a error of XMLHttpRequest cannot load http://iatageo.com/...
0
votes
1answer
119 views

TypeError: Cannot read property 'go' of undefined with injected $state

i already checked on stackoverflow and i see there are duplicate posts, but none of them resolved my issue. The issue with most of the cases is the injection of the $state. But i already injected in ...
0
votes
1answer
39 views

$rootScope is not updated in SPA

My first controller: angular.module('application') .controller('FirstController',['$rootScope',function($rootScope) { var data=[0,1,2]; $rootScope.items=data; }...
2
votes
1answer
187 views

AngularJS ui.router won't load template

I'm still learning AngularJS and having trouble with UI Router. It just won't load the template. Here's my code: <body class="top-navigation" ng-app="mixcontainer"> <div id="wrapper"&...
0
votes
2answers
2k views

Give URL with ID in Angular UI Router

I have a problem, when I edited data, my url not showing id example : /answer/1 or /answer/2 or /answer/3 etc. Im confused because Im using UI ROUTER I'm a beginner use UI ROUTER angularjs. Can you ...
1
vote
1answer
175 views

Angularjs error, Module 'testApp' is not available

<html> <head> <script type="text/javascript" src="js/angular/angular.js"></script> <script type="text/javascript" src="js/angular/angular-route.js"></script> <...
1
vote
2answers
207 views

Make two layouts share the same $scope

I want to propose two layouts (ie, horizontal and vertical) for my contents. So switching in the selector will lead automatically to the corresponding layout. Here is the JSBin: <html ng-app="...
0
votes
1answer
50 views

I have 2 app.run method.how to halt in first method until promise is resolved?

angular.module('app', [ ... ]) .constant('AppConstants', constants) .config(appConfig) .run((UserService, User) => { 'ngInject'; console.log('apprun') UserService.acl() ...
1
vote
3answers
186 views

Angular JS : Post call is going in Success as well as Error Method

I know I amy look like foolish while asking this, but I am not able to figure this out. I have written a service which handles the post call to the server. $q service is returning the promise back ...
0
votes
1answer
314 views

Can a $rootScope variable be passed in state file - AngularJS

I'm working on an Angular project and currently am working on making the entire project configurable. I have an object which contains an array of elements, each element being an object with the ...
1
vote
0answers
301 views

Using Resolve In AngularJS Routes to get Json data

I'm trying to get Json data in AngularJS Routes and then inject it to the controller. A resolve contains one or more promises that must resolve successfully before the route will change. This means ...
0
votes
1answer
60 views

reload the angularjs after update , date not updated

i am working in angularjs 1.i am trying to make CRUD in angularjs and laravel.i have successfully make the CRUD and CRUD is working fine , in my application their is child and parent routing present ...
0
votes
1answer
169 views

Duplicates in a repeater are not allowed?Use 'track by' expression to specify unique keys.?

I have created notification service globally for the application, while sending the db call, capturing the error code in interceptors and show alert. how to avoid the duplicated Error mesage in ...
1
vote
3answers
47 views

why the factory is not able to access inside the controller

I have created notification factory and pass inside controller,Inside controller when assign the factory to the scope getting error. alertsManager MyApp.factory('alertsManager', function() { ...
0
votes
1answer
278 views

Notification alert service not working in controller getting typeError: Cannot read property 'alerts' of undefined

I have capturing the application response error ,while capturing the error, i am getting the error. In Interceptor ,according to the response code , have assign the rootscope broadcast and show the ...
1
vote
1answer
41 views

Access a child state from a child state

I want to access a child state from a child state but I get : angular.js:14195 Error: Could not resolve '#/projects/detailProject' from state 'projects.list these are the states : function ...