Questions tagged as 'angularjs'

1
answer

timeout for $ http request (fetch for 5 seconds, if not, return 'error')

I'm setting a $ http request for zip code, so sometimes it takes too long for the API to return a response, and the user is stuck with continuing to checkout. The function worked, but when I tried to add the timeout it stopped. FUNCTION:...
asked by 13.08.2015 / 16:27
1
answer

How to reset form state with model data?

I have a model in which I fill in the fields of a form (use asp.net mvc and the view is typed), that is, I load the fields of this form according to the data of the database for the user to change on the screen What I want to do is a "undo" bu...
asked by 07.08.2015 / 15:10
2
answers

Extract certain data from the array of a Json

I've got a Json from an API that returns this result: [ { "marca_id": 4, "modelo_id": 2708, "versao_id": 65344, "cor": "Azul", "opcionais": [ { "opcional_id": 6, "opcional_nome": "Airb...
asked by 14.07.2015 / 23:15
2
answers

How to extract only 1 image from Json?

Hello, I need to extract only 1 image of this Json. Here is my angled code to pull the records from api via get. var app = angular.module('myApp', []); app.controller('carrosCtrl', function($scope, $http) { $http.get("http://www...
asked by 13.07.2015 / 17:03
1
answer

Component select2 with AngularJS

Good afternoon Does anyone use the select2 component ( link ) to create dropdown components? I'm going through the following problem, I have two components in a javascript that are placed on the screen as the user adds new lines. And in th...
asked by 23.06.2015 / 19:42
1
answer

How to do a search in a list of Ionic Framework Angularjs

I have an ionic application, however I need to do a search or filter on the contacts that appear on the screen but I can not and the worst that does not return any errors: My control: .controller('ContatosCtrl', function($scope, $timeout, $...
asked by 08.06.2015 / 17:07
1
answer

I need to change the onclick button to angular.js

Good evening. I'm using Bootstrap pagination with Angular.js. I can get the bank details and list it, it looks beautiful, etc ... the way I needed it. However, I need to open a modal window and this worked when I was using the javascript func...
asked by 17.05.2015 / 07:43
1
answer

Problems with JSON parse in AngularJS

I have a controller that returns a JSON object in the following format: [ {"idCliente":1, "nomeFantasia":"Flores", "razaoSocial":"Transportes Flores Ltda.", "contatosClientes": [ {"idContatoCliente":1, "dddCelular":21,...
asked by 06.07.2015 / 20:43
1
answer

Modifying Material Angularjs Start creating new module / controller

I got the code from Material Angularjs Start to see how it works, I removed the User controller and I'm trying to program my own Controller, but it's giving a bad error and the layout does not load, I'd like to know what I'm doing wrong, follow...
asked by 17.07.2015 / 21:48
1
answer

Problems with ngModel required in policy

I have a problem with my directive, it gets a ngModel to insert a value in a text field inside it, but when this model comes with some value it just disappears with it. Basically I want to pass ngModel to my directive, if there...
asked by 14.05.2015 / 16:31