Questions tagged as 'angularjs'

2
answers

AngularJs - Organization of files for large project

My question is not about codes properly, but about how to better organize project files. I know this is an issue that does not have a right answer, nor does it have the best answer. But as I am developing a project now where I am encountering...
asked by 11.11.2015 / 01:03
2
answers

Lock button until function is completed AngularJs

I need a way to lock a button until the ng-click is completed, to prevent the user from clicking the button again, thinking that nothing happened or anything. Is there any good way to do this, using directives to something like this?...
asked by 30.08.2018 / 15:09
1
answer

Why variable increment function does not work in AngularJS? Am I not accessing the variable correctly?

Hello. I need to change the value of a variable in angularJS but I'm encountering the following problem: "Can not set property 'quantity' of undefined". When I click the add button, I need the quantity variable contained in commodity1 t...
asked by 22.09.2017 / 18:47
2
answers

ng-repeat in an array within an array of objects

I'm trying to list all of my product sizes once, eg 38, 39, 40, 41 based on the sizes of my array, to mount a filter bar. $scope.listaProdutos = [ { id: 1, nome: "Lorem ipsum dolor 1", preco: 129.90, foto: "...
asked by 07.01.2017 / 04:30
2
answers

How to store AJAX return to use as a parameter of another function

Main function, which will return the value chave = data.chave : var chave = ''; $scope.submitForm = function() { $http({ method : 'POST', url : 'validar.php', dataType: 'json', data :...
asked by 10.01.2017 / 03:44
2
answers

How to solve JSON.parse problem using Ionic and AngularJS

I have the following error and can not solve: Error: Uncaught SyntaxError: Unexpected token ] in JSON at position 142 at JSON.parse (<anonymous>) at XMLHttpRequest.xmlhttp.onreadystatechange (forma_pag_cad_controller.js:24) The str...
asked by 10.02.2017 / 13:10
1
answer

How to display message in AngularJS? [closed]

I'm working with angular and need to add a message on the screen when pressing the check code button. An error message or success. Angle Controller angular.module().controller(){ vm.validarProtocolo = function(){...
asked by 09.02.2017 / 19:06
3
answers

How to read a .json file in the module.config () of the Angular?

I have a config.json file in the root of my project with some information that can be changed: folder path, etc. I can not create constants (angular.constant) in the code, as I said the values of the file can be changed in production. But...
asked by 28.11.2016 / 12:32
1
answer

Requested angularjs being executed first incorrectly

In a controller, I have two HTTP requests: function findProfessionalEmail(professional) { EmailHunter.findProfessionalEmail(professional.company_name, professional.first_name, professionalLastName).then(function (da...
asked by 20.09.2016 / 22:10
1
answer

How to insert arrays inside angular objects?

Let's say I have a vehicle object that has the following attributes converting my C # class to Json: { "UsuarioId": 0, "TipoId": 0, "MarcaId": 0, "ModeloId": 0, "VersaoId": 0, "Quilometragem": 0, "AnoFabricacao": 0, "AnoModelo...
asked by 26.01.2017 / 02:14