[AngularJS] Angular : How to detect changes made to form automatically

2016-09-15 Thread user12345
Hi All

Is there any way to detect whether the user has made any change to the form 
using angular form .?

example :

Step 1 : Value for name (type = input) will be : "test".(By default, the 
ng-model will be defaulted as value will be retrieved from API Response).
Step 2 : User has changed value to "test1"
Step 3 : User has changed value to "test".

Is there any attribute inside that form where i can check that the user has 
not changed anything ideally for input directive. I think , dirty, 
pristine, touched elements inside the form will not be used for this 
scenario.

Step 4 : User has changed value to "hello". 
Step 5 : User has changes value to "test"'

So what i am looking is , is there any attribute where i can check whether 
the user has made any change to the input, like for
Step 2-->value should be true
Step 3-->value should be false
Step4-->value should be true.

Thanks !

-- 
You received this message because you are subscribed to the Google Groups 
"AngularJS" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to angular+unsubscr...@googlegroups.com.
To post to this group, send email to angular@googlegroups.com.
Visit this group at https://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


[AngularJS] Using C# with Selenium and Integrating Protractor to it for Angular js app

2016-09-15 Thread Rasika Puranik


Hi there!
My issue might be simple for u all , but since I am a beginner , I am using 
C# with Selenium and integrated the Protractor package to it .

Please find the below Angular js code , I am trying to locate the button , 
but the "By " provides Selenium locators and "NgBy" provides Protractor 
locators , and these are very limited , I am not able to use 
NgBy.PartialButtonText in this.

When I used the same in pure Protractor +JavaScript I was able to do it , 
but the demand here is with C# and with C# it's not working , can anyone 
help.


+ Create new Solution


I used By.css and ng -click into it , but it did not work , 

for classname it say - invalid locator ...so cannot use classname too ...no 
id is provided , then how to locate such element.


-- 
You received this message because you are subscribed to the Google Groups 
"AngularJS" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to angular+unsubscr...@googlegroups.com.
To post to this group, send email to angular@googlegroups.com.
Visit this group at https://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


[AngularJS] Re: deploying an angular 2 app

2016-09-15 Thread Richard Perfect

On Thursday, September 15, 2016 at 9:00:06 PM UTC+12, norricorp wrote:
>
> Hi,
> new to angular. I was wondering how to deploy an angular app to a web 
> server? Is there documentation on this.
> I have experience with Java and Tomcat applications but not sure how it 
> works where all of the logic is in the front end.
> Regards,
> John
>

Hi, I'm a Java developer too. There's lots of different ways to do this, 
but the key idea is that an Angular Application is just a bunch of static 
web resource files. From the Java Application Server's point of view 
there's nothing really different Angular Html and JS files than there is 
from any other gif, png, or css file that you might have already been used 
to deploying. Since all of the HTML generation is taken out of the Java 
Application server it just presents REST Services to the Angular App.

You can try and merge Angular 2 code into you main Java application project 
but I find it's easier to keep them separate. Use a technology like 
Angular-CLI to build and develop the Angular App and have the Angular CLI 
web server proxy your requests back to the Java application server. When 
you're ready to deploy into a proper dev/test environment you can either 
keep the Angular stuff separate under it's own web server eg Ngnix/Apache 
or you can merge in the compiled Angular code into you WAR file.


-- 
The information contained in this email is privileged and confidential and 
intended for the addressee only. If you are not the intended recipient, 
please respect that confidentiality and do not disclose, copy or make use 
of its contents. If received in error, please destroy this email and 
contact the sender immediately. Thank you.

-- 
You received this message because you are subscribed to the Google Groups 
"AngularJS" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to angular+unsubscr...@googlegroups.com.
To post to this group, send email to angular@googlegroups.com.
Visit this group at https://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


[AngularJS] Re: lazy loading without router

2016-09-15 Thread Long Field
Lazy loading and bootstrap component are two different thing,two 
separate angular 2 application running  on same browser is another thing, 
which/what do you want to know?

On Monday, September 12, 2016 at 11:29:07 AM UTC+10, Muthu Raja wrote:
>
> i have two component in my project (alert and notification). one 
> component(alert) is bootstrapped initially, i want to bootstrap another 
> component later point of the time.
>
> this is kind of two separate angular 2 application running  on same 
> browser.  is that possible to bootstrap another module while one module is 
> in running?
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"AngularJS" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to angular+unsubscr...@googlegroups.com.
To post to this group, send email to angular@googlegroups.com.
Visit this group at https://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


[AngularJS] Re: Angular 2 RC6+ How to dynamically load a template using 1 class?

2016-09-15 Thread Long Field
Hope this can help you: https://github.com/Longfld/DynamicalRouter

On Tuesday, September 13, 2016 at 6:14:05 PM UTC+10, Roland Slegers wrote:
>
> Hi there,
>
>
> I have seen examples, tried stuff, yet I failed to do the following: 
> Dynamic Component Loading...
>
>- I looked at and tried out examples using the DynamicComponentLoader, 
>but that became deprecated, before I was even finished. 
>- I looked at and tried out examples using the ComponentResolver, but 
>that became deprecated, before I was even finished. 
>- I have seen the ComponentFactory, but I am not yet experienced 
>enough to fully understand this... It seems to be usable for small 
>additions to the DOM. I need a complete new DOM... Yet I feel that this 
>could be part of the answer...
>
> Now I am starting to feel a little bit frustrated...
>
>
> What I would like to be able to do is to use different templates using the 
> same class.
>
>
> Let's say we are building a CMS: I would like to have 1 class to be able 
> to display many different articles. Rather than having to rebuild/rename 
> the same class for each article over and over again. My OO hairs would 
> start pulling themselves out... We just want to be ale to have different 
> views at the same data...
>
>
> Ideally I would like to pass the name of the template as a parameter to 
> the class somehow just before it renders itself.
>
>
> We are now using RC6, but I have not yet seen many examples for something 
> like this for RC6. There are examples for RC5 (and lower) but these have 
> become deprecated...
>
>
> Who can help me out here...
>
>
> I have no code to share... It either did not work, or was deprecated  
> reaching RC6... Other examples are build on RC4, yet now we have the 
> magical RC6 and these no longer work... :-(
>

-- 
You received this message because you are subscribed to the Google Groups 
"AngularJS" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to angular+unsubscr...@googlegroups.com.
To post to this group, send email to angular@googlegroups.com.
Visit this group at https://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


[AngularJS] How select control works under ReactiveForms?

2016-09-15 Thread Long Field
Anyone knows how to select control for ReactiveForms? any http://plnkr.co/?

 
  {{opt.Text}} 
 

-- 
You received this message because you are subscribed to the Google Groups 
"AngularJS" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to angular+unsubscr...@googlegroups.com.
To post to this group, send email to angular@googlegroups.com.
Visit this group at https://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


[AngularJS] Re: Get current windows user name and domain information ?

2016-09-15 Thread Sander Elias
Hi Prayag,

Unless MS has something specially arranged for this in IE/EDGE that I don't 
know of, it's impossible to get this data from withing the browsers 
sandbox. Browser vendors went to extreme length to prevent this (and any 
other kind) off access to system resources. Google for browser sandbox if 
you want more detailed information.

This is a security measure. We don't want that to be changed. Think about 
it, do you want a browser that makes private system resources available on 
the internet?

Regards
Sander

-- 
You received this message because you are subscribed to the Google Groups 
"AngularJS" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to angular+unsubscr...@googlegroups.com.
To post to this group, send email to angular@googlegroups.com.
Visit this group at https://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


[AngularJS] Get current windows user name and domain information ?

2016-09-15 Thread Prayag Ganoje
I need Windows *userName and Domain* information on the landing page 
developed using AngularJS.

Is there any way to get Windows userName and Domain name ?



In ASP.NET MVC there is *HttpContext.Current.User.Identity.Name* to get 
this kind of information.

Looking how to achieve similar thing using AngularJS ?

-- 
You received this message because you are subscribed to the Google Groups 
"AngularJS" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to angular+unsubscr...@googlegroups.com.
To post to this group, send email to angular@googlegroups.com.
Visit this group at https://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


[AngularJS] How to: CRUD Using AngularJS and MVC Web API.

2016-09-15 Thread Alejandro Nava-Gomez


I would like to use AngularJS and MVC Web API to create a form and its CRUD 
operations (see image below)


The form is constituted of three tables: Page, Preamble, Sections. It also 
has 3 drop down lists that will need to be populated from the database.  


This is my first attempt to create a project like this one, and I am 
finding lots of examples and most of them use only one table. 


Do anybody has an example in which more than one table is used? 







-- 
You received this message because you are subscribed to the Google Groups 
"AngularJS" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to angular+unsubscr...@googlegroups.com.
To post to this group, send email to angular@googlegroups.com.
Visit this group at https://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


[AngularJS] Re: Getting error using ng2 charts with Angular 2 RC 6.

2016-09-15 Thread Santosh Pillai

Hi

Thanks for your time. Yes, created this project with angular2-cli tool.
It works fine now with RC 6, I'm able to use Ng 2 charts. Now, I would try 
this out with latest (Released) version of Angular2.

Thanks.

On Monday, 12 September 2016 12:51:03 UTC+5:30, Zlatko Đurić wrote:
>
> Did you create this project with angular2-cli tool? Did you change the 
> System.js config default stuff? Because the  ` *const map: any = { 
> **'ng2-charts': 
> 'vendor/ng2-charts'**  };` *part should, by default, be done in 
> `src/app/system-config.ts`. You already have a System.config({ map, 
> packages }) there. Try simply adding ng2-charts there instead of 
> index.html, it could work.
>
> Also, a side note, you can install chart.js with npm too, to avoid the 
> extra CDN link.
>

-- 
You received this message because you are subscribed to the Google Groups 
"AngularJS" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to angular+unsubscr...@googlegroups.com.
To post to this group, send email to angular@googlegroups.com.
Visit this group at https://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


[AngularJS] $windows couldn't inject in in controller using /*@ngInject*/

2016-09-15 Thread John Kanathon
Hi 

I am trying to inject $window using ecma script 6 constructor.

/*@ngInject*/
constructor($window) {
this.$window = $window;
}

when I am trying to access windows object using this.$windows getting 
windows is undefined.


-- 
You received this message because you are subscribed to the Google Groups 
"AngularJS" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to angular+unsubscr...@googlegroups.com.
To post to this group, send email to angular@googlegroups.com.
Visit this group at https://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


Re: [AngularJS] Re: Angular2 - one route, multiple components

2016-09-15 Thread 'Lucas Lacroix' via AngularJS
Yeah. That's what I was thinking.

On Thu, Sep 15, 2016, 05:15 Luke  wrote:

> Thanks, that's actually a great idea ! Just to make sure - in template of
> the parent component, I have an ngSwitch on let's say a  [ngSwitch]="type">, in it there are two child components  *ngSwitchCase="'P'">.. and .. also these two
> components are two-way and have @input properties of slug?
>
> --
> You received this message because you are subscribed to the Google Groups
> "AngularJS" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to angular+unsubscr...@googlegroups.com.
> To post to this group, send email to angular@googlegroups.com.
> Visit this group at https://groups.google.com/group/angular.
> For more options, visit https://groups.google.com/d/optout.
>
-- 
Lucas Lacroix
Computer Scientist
Advanced Technology Division, MEDITECH 
781-774-2293

-- 
You received this message because you are subscribed to the Google Groups 
"AngularJS" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to angular+unsubscr...@googlegroups.com.
To post to this group, send email to angular@googlegroups.com.
Visit this group at https://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


[AngularJS] Angular2 custom button component (EventEmitter)

2016-09-15 Thread N Dzhil
Hello, I'm trying to implement a custom button component with Angular 
2(rc-6) which has 2 important features:
- prevent a second click(the user clicks the button twice)
- show a spinning icon until the associated action is complete

So, after reading some of the Angular 2 docs I saw that I can use 
the EventEmitter like this:

-- usage of the button component


and in my button component have the following

--button component 
  @Output()
  btnClick: EventEmitter = new EventEmitter();

  clickHandler($event) {
$event.preventDefault();
this.btnClick.emit($event);
  }


--button component template


Everything looks good, but the emit method only fires an event and does not 
know whether func has finished its execution.

Is there a way to call a function on a parent component from a child 
component and get the result from that invocation?
Something like:
  @Output()
  btnClick: EventEmitter = new EventEmitter();

  clickHandler($event) {
$event.preventDefault();
let result = this.btnClick.emit($event);
//check if the result is an observable and wait for it to be resolved
  }




I know I can pass a function to the emit method, and then in the parent 
component to call that function whenever I decide in  func, so I can know 
when the execution has stopped and stop spinning and allow a second click.
But I don't want that decision to be taken by the parent component.

Thank you very much!

-- 
You received this message because you are subscribed to the Google Groups 
"AngularJS" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to angular+unsubscr...@googlegroups.com.
To post to this group, send email to angular@googlegroups.com.
Visit this group at https://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


[AngularJS] Re: Angular2 - one route, multiple components

2016-09-15 Thread Luke
Thanks, that's actually a great idea ! Just to make sure - in template of 
the parent component, I have an ngSwitch on let's say a , in it there are two child components .. and .. also these two 
components are two-way and have @input properties of slug?

-- 
You received this message because you are subscribed to the Google Groups 
"AngularJS" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to angular+unsubscr...@googlegroups.com.
To post to this group, send email to angular@googlegroups.com.
Visit this group at https://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


[AngularJS] angular 2 tutorial - http

2016-09-15 Thread norricorp
Hi,
going through the tutorial. If I wanted to use a real web server to supply 
data (rather than the InMemoryDataService), would all I have to do is 
change the heroesURL value to something like fred dot com?
Regards,
John

-- 
You received this message because you are subscribed to the Google Groups 
"AngularJS" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to angular+unsubscr...@googlegroups.com.
To post to this group, send email to angular@googlegroups.com.
Visit this group at https://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


[AngularJS] deploying an angular 2 app

2016-09-15 Thread norricorp
Hi,
new to angular. I was wondering how to deploy an angular app to a web 
server? Is there documentation on this.
I have experience with Java and Tomcat applications but not sure how it 
works where all of the logic is in the front end.
Regards,
John

-- 
You received this message because you are subscribed to the Google Groups 
"AngularJS" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to angular+unsubscr...@googlegroups.com.
To post to this group, send email to angular@googlegroups.com.
Visit this group at https://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


[AngularJS] Yeoman build + wampserver ?

2016-09-15 Thread jeremylacombe
Hi there, 

I made a build with Yeoman : Angular 1, webpack with npm, pure old 
javascript,SASS, and ui-router.

*When i build the app* (npm run build),* i can deploy it on an IIS server 
without problem*. But i would like to devellop it without doing the npm run 
serve ( and i think it is pretty weird to do on a server a npm run serve ).

When i put the app on the server without build, the app does not work. I 
just have my landing page with the bracekts {{ }} I think that no other 
files except the index.html is loaded. 

So i tried to do a simple *app with same configuration, on wampserver*. And 
here we go, *it does not work too *when i put it on. ( and of course the 
builded app works ! )

My qestion is : what i have to do to make the app work without launching 
the command : npm run serve and then go on the localhost:3000 made by npm.



-- 
You received this message because you are subscribed to the Google Groups 
"AngularJS" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to angular+unsubscr...@googlegroups.com.
To post to this group, send email to angular@googlegroups.com.
Visit this group at https://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


[AngularJS] Re: NON html component element DOM properties

2016-09-15 Thread Jan Kozak
hello Sander, I do want. as wrote: hint would be appreciated. anyways, is 
it something like $attrs?

On Tuesday, September 13, 2016 at 2:01:50 PM UTC+2, Sander Elias wrote:
>
> Hi Jan,
>
> Well, if you don't want to solve it using angular, you will need to re-ask 
> the question on a place where the jQuery experts are. I don't know why your 
> solution doesn't answer your question, that seems related to jQuery. 
>
> Regards
> Sander
>

-- 
You received this message because you are subscribed to the Google Groups 
"AngularJS" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to angular+unsubscr...@googlegroups.com.
To post to this group, send email to angular@googlegroups.com.
Visit this group at https://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.