Questions tagged as 'angularjs'

2
answers

Check if Array is empty Ng-Switch

I check a parameter with an array that can have values it or not. I have a Ng-Switch does a check in this array. I would like it when it had no value to display a Message. I've done ng-switch-when="" but it did not work and I do not kn...
asked by 20.04.2016 / 16:46
1
answer

Should we avoid circular dependencies?

When working with AngularJS it is very common to have applications where services contain only HTTP calls to the server that will store the data. However, in an application where we will not have a server our service can be responsible for many...
asked by 03.05.2016 / 16:48
1
answer

Show Description instead of non-angular value

Hello, I'm learning AngularJs and in my exercises I came across the following question: How do I show a description in place of a code. For example $scope.aeronaves = [ cod_anv: '1', fabricante: '1' ]; $scope.fabricantes = [ cod_fab: '1', nome...
asked by 21.01.2016 / 21:30
1
answer

Doubt in AngularJS! (Factory, Controller, View) Why is 'identity' not updated in VIEW?

I have a question in AngularJS! The source code is at link In the factory I have a property named identity , which is mirrored to the controller and displayed in the view. When adding a new message this property is incremented corr...
asked by 25.01.2016 / 21:05
1
answer

Directive not being called, custom validator AngularJS

I have the following directive: .directive('validateCPF', function () { return { require: 'ngModel', link: function (scope, element, attrs, ctrl) { ctrl.$validators.cpf = function (modelValue, viewValue) {...
asked by 25.01.2016 / 12:59
1
answer

Page .html does not want to appear

I'm making an application with angularJS. I have pages being called, but a single one does not appear. Here are my codes: app.js var app = angular.module("vc", ["ui.router"]); app.config(function($stateProvider){ $stateProvider .sta...
asked by 08.01.2016 / 22:03
3
answers

Stop running a JavaScript function to perform another function

I'm developing a system using angular and have the following function: function drawLatLong(i, arrayIdColetor) { ..... (não exibi o código por ser grande e achar desnecessário que vcs o analisem) ..... }); This function...
asked by 14.12.2015 / 18:02
2
answers

Doubt with ng-pattern entry number with 2 decimal places - angularjs

I am trying to format a decimal value so that it is always sent in this format: 00.00, I have an example in this site link If you enter 20.10 = 20.1 (you want it to look like 20.10) if you enter 15.00 = 15 (you want it to stay 15.00) &...
asked by 31.12.2015 / 05:44
1
answer

How to read a MapString return, String Java in javascript?

When making a request to a java control that returns a key map and value "String": @ControllerSupport public Map< String, String > teste() { Map< String, String > teste = new HashMap< String, String >(); teste.put( "T...
asked by 02.02.2016 / 21:06
1
answer

Get return from angular-file-upload

I'm using the angular file upload , it works great, but I need the feedback that the server me available. I'm using the following code: $scope.uploader = new FileUploader({ url: 'https://api.imgur.com/3/image', alias: 'image', h...
asked by 30.01.2016 / 23:13