[AngularJS] Re: Alternatives to recaptcha in project JEE

2014-10-27 Thread jitendra Mishra
Hi There, hope you are well.
I am fairly new to this technology and currently working on a  solution 
using AngularJS.

Can someone please recommend Captcha solution?  suitable for highly secure 
banking industry.

Thanks,
Jit

On Wednesday, 22 October 2014 12:15:30 UTC+11, Candres wrote:
>
> Hi there!
>
> I need to use a captcha in my project AngularJS  + Rest API JEE, I need to 
> find an alternative to Recaptcha, due to security restrictions in servers I 
> can't use ReCaptcha or something that need a internet connection. I know 
> some libraries like SimpleCaptcha or JCaptcha, but I don't know how I can 
> integrate it with AngularJS. 
>
> Thanks for advance.
>

-- 
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 http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


[AngularJS] Re: Directive controler service $http json

2014-10-27 Thread benjamin
Hi Justin,

Thank you for your answer.
It really help me.

I didn't know about this site plnkr until you talk about.
Thank you for the related links

On Monday, October 27, 2014 4:32:20 PM UTC+2, benjamin wrote:
>
> Hi all,
> I'm new to angularjs and I can't see why my code is blocked.
> I have an html page like this:
>
>   
>
> I want a directive named viewProducts to be inserted there
> my app.js:
> var route = '/learn/angularjs/';
> var app = angular.module("table",[]);
>
> app.directive("viewProducts",function(){
>  return{
>  restrict:"E",
>  templateUrl:route+"includes/view.html",
>  controller:['$scope','$http',function($scope,$http){
>  $http.get(route+'includes/view.json').success(function(data){
>  $scope.view = data;
>  });
>  }],
>  controllerAs:"view"
>  };
> });
>
>
> view.html:
>
>  {{view.name}} 
>
> view.json
>
> {name:"view"}
>
> When I open the browser I have a white page,
> don't understand why.
>
> Thank you for your help
> Benjamin
>

-- 
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 http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


[AngularJS] Attaching ng-show in directive

2014-10-27 Thread Sonal Singh
I am new to Angular.I have a custom directive in which i want to attach 
ng-show to the element. However, this does not seem to get reflected at all 
even though when i inspect the element, i see that it has value of 
ng-show="false".

Here is what the directive looks like:

ngular.module('testApp')

.directive('nmUiEditorShowControl', function($document, $rootScope) {

return {

restrict: 'A',

link: function(scope, element, attrs) {

element.attr('ng-show', 'false');

}

};

});

I want to set the value of ng-show to a function. However, for now even 
hardcoding thid to false does not seem to have any effect. The control to 
which i attach this directive (button in this case) is always visible

despite having ng-show set to false in the dom.

Any inputs will be much appreciated. 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 http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


Re: [AngularJS] Re: Preserving Expensive Elements - stashing and moving around DOM nodes

2014-10-27 Thread Ruaidhrí Devery
My use-case was similar to the iOS window management where sub-app view 
state is frozen in time and reestablished as you navigate.

After delving in some more I decided it would be better to take a different 
approach with the UI than invest any more time to solve the feature. 

It hasn't come up since so I'm not aware of any good solutions.





On Monday, 27 October 2014 01:22:22 UTC-7, Dan Dascalescu wrote:
>
> A year later - any updates on the sanctioned way to preserve expensive 
> elements? I have a Google Maps that I want preserved (center, zoom etc.) 
> when navigating among routes, and this seems like a basic enough feature of 
> a routing package that it should already be implemented.
>
> So far I've only found an add-on to ui-router, called ui-router-extras, 
> which didn't work 
>  out of 
> the box.
>
> On Wednesday, October 2, 2013 2:30:53 PM UTC-7, Ruaidhrí Devery wrote:
>>
>> Oh I see, I'll give it a try. If I can get something working how I want 
>> I'll post up a fiddle
>>
>> Thanks for the help!
>>
>> R
>>
>>
>> On 2 Oct 2013, at 12:12, Sebastien Vincent wrote:
>>
>> You don't recompile the template each time, you redraw. Compile is to 
>> bind, not to draw. You can reuse dom element when you redraw, as long as it 
>> reflect the data and it is properly unit tested. If you do thing in order, 
>> it'll be easy to get thing working and only then optimize. 
>>
>> On Thursday, October 3, 2013 2:20:43 AM UTC+8, Ruaidhrí Devery wrote:
>>>
>>> ng-repeat triggers $animate#move 
>>>  to reposition DOM 
>>> elements so as to "reuse the associated scope/element"
>>>
>>> I think that this is as much for usability as it is optimization. 
>>> Re-compiling the template every time the order changes is a real issue for 
>>> UI continuity*.
>>>
>>> What I'm trying to achieve is a similar. I'm hoping to maintain the 
>>> continuity of a list of elements, only my list structure requires elements 
>>> to be moved between root nodes not just within them.
>>>
>>> rur
>>>
>>> * and also for control requiring granular component state to be moved up 
>>> the scope hierarchy.
>>>
>>>
>>>
>>>
>>> On Tuesday, 1 October 2013 20:11:51 UTC-7, Sebastien Vincent wrote:

 I don't think ng-repeat moves DOM around, it keeps data and 
 presentation separated and redraw on change. 
   
 The point of scope is to "maintain the component state for the duration 
 of execution". $compile allows you to create a new scope for your template 
 at the target. Then you need to move data between the old scope and new 
 scope and it will look like the data has moved. 

 On Wednesday, October 2, 2013 8:07:47 AM UTC+8, Ruaidhrí Devery wrote:
>
> Yea I remove and reinsert the element. I did try $compiling the 
> element before reinserting, but as expected it clobbered the state within 
> the include tag.
>
> I'm going to take a closer look at the ng-repeat implementation and 
> see how it moves DOM nodes around. If I find anything useful I will post.
>
> rur
>
>
>
>
> On Tuesday, 1 October 2013 15:35:44 UTC-7, OpenNota wrote:
>>
>> I lose Angular mouse event bindings (at least). 
>>
>>  
>> Do you remove element from DOM and then reinsert it? If so, then you 
>> probably need to $compile it after.
>>
>
>>

-- 
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 http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


[AngularJS] Re: Way to remove $promise and $resolved properties from all resource responses?

2014-10-27 Thread Vytautas Barkauskas
Hi,

I also have the same problem. I was wondering perhaps you found solution by 
yourself?


On Thursday, January 9, 2014 10:51:12 AM UTC-8, jonr wrote:
>
> Hi,
>
> I'm upgrading to the latest version of angular and was wondering if there 
> was a way to remove all $resolved and $promise properties from resource 
> responses. I know in the migration guide it says to do this:
>
>
> http://docs.angularjs.org/guide/migration#resource-promises-are-resolved-with-the-resource-instance
>
> The only problem is I have multiple resources with multiple methods where 
> I want this to be removed, which would make it not ideal to have to write 
> the interceptor for every resource request I make. It would be nice if if 
> there was a global resource interceptor like there is for http.
>
> 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 http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


[AngularJS] Problem with html entities in title attribute

2014-10-27 Thread Cim balli
Hi, I have a problem with HTML entities in the title attribute of an anchor 
element.

Here is the snippet :


The output is :

http://127.0.0.1:8080/payenke-reader/#/home1>" 
ng-attr-title="{{'TEXT' | translate}}" title="ètées">


And the translation is :

'TEXT' : 'ètées'


What should I do in order for the browser to display the real characters and 
not the entities ?


Thanks !


Cimballi


-- 
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 http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


[AngularJS] Angular nested resizable views

2014-10-27 Thread mark goldin
I need to create a screen that would have three view areas when all three 
will be getting their templates loaded at the same time I have done that 
before.
But now I need to have these view areas being capable of resizing. So, from 
one hand, it is a single view with splitters, but from the other, it's a 
perfect candidate to use Angular states for.
Can someone suggest an idea?

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 http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


[AngularJS] Re: protractor and/or protractor webdriver hanging when run by Jenkins

2014-10-27 Thread Iain Duncan
Replying to myself in case people find this post in archives:

What I needed to do was the following:
- install the chromedriver package  ( apt-get install chromium-chromedriver 
)
- install the xvfb headless X11 package ( apt-get install xvfb )
- start X11 in the background (  Xvfb :0 -ac -screen 0 1024x768x24 & )
- add an env variable to jenkins settings: key: DISPLAY value: 0:0

then chrome uses xvfb as it's display and all is good.

hth someone! 


On Saturday, October 25, 2014 2:27:53 PM UTC-7, Iain Duncan wrote:
>
> Hi folks, hoping someone can help me figure this out. I have protractor 
> and protractor webdriver working nicely from grunt on my local machine. 
> (Grunt file extracts posted below) The protractor base url is set to 
> localhost:9001, and on my local machine all goes well. Grunt test runs the 
> karma tests, fires up the selenium webdriver, and then runs the protractor 
> tests and exits as "OK".
>
> In the jenkins workspace however (whether fired by jenkins or manually in 
> the workspace) it seems to be ok and then hangs. For debugging I tried 
> taking out the protractor webdriver task and manually turning on webdriver 
> on the CI server, and in that context, instead of hanging on firing up 
> protractor, it hangs on the actual test when the browser is trying to hit 
> the site. I assume I've got something screwed up in my selenium and/or npm 
> install situation. It's running on ubuntu server. 
>
> If anyone can give me tips on how to figure this out, that would be great!
> iain
>
> Jenkins script:
> export npm_config_prefix=.npm/
> export PATH=.npm/bin:$PATH
> npm install -g bower grunt-cli
> bower install
> npm install
> grunt test
>
>
> (gruntfile excerpts)
>
> ...
>  // Load grunt tasks automatically
>   require('load-grunt-tasks')(grunt);
>   
>   grunt.loadNpmTasks("grunt-protractor-runner");
>   grunt.loadNpmTasks("grunt-protractor-webdriver");
>
> ...
>   
> // unit testing with karma
> karma: {
>   unit: {
> configFile: 'test/karma.conf.js',
> singleRun: true
>   }
> },
>
> protractor_webdriver: {
>   start: {
> options: {
>   //path: '/path/to/',
>   command: 'webdriver-manager start',
> },
>   },
> },
>
> // e2e testing with protractor
> protractor: {
>   options: {
> // for some reason this should be true even thought is shuts down
> keepAlive: true,
> configFile: "test/protractor.conf.js"
>   },
>   run: {}
> } 
>
>

-- 
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 http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


[AngularJS] urgent requirement for Sr Java Consultant(with Angular JS)

2014-10-27 Thread anil vasudevan
*Hi*

*Hope you are doing well.*

 We have an urgent requirement for the below positions. Please go through
the job description and send me some matching resumes along with contact
details ASAP. Email:- v...@bigcode.us 


*Position: Sr Java Consultant(with Angular JS)*

*Location: Washington, DC*

*Type: Contract (6 months)*

*Rate: DOE*

*Must Have: Angular JS*


*Description:*

*Responsibilities:*

The Sr. Software Engineer will primarily maintain and enhance existing
suite of Web applications.  Work with customers to assess business needs,
documenting requirements as needed; design solutions and create prototypes
for user acceptance; and work with quality assurance team to ensure that
the code is well tested.  An experienced professional who works on complex
projects with minimal supervision. Performs as technical lead, and assists
with project management responsibilities as needed.



*RESPONSIBILITIES*



   - In collaboration with manager and lead software engineer, performs and
   directs analysis, design, development and unit testing of complex software
   applications; and leads resolution of defects
   - Works with other software engineers to develop project estimates,
   tasks and schedules
   - Provides project status updates to manager and business partners
   - Directs development of system documentation according to established
   standards
   - Participates in structured walkthroughs and technical reviews
   - Assists in reviews of and revisions to AAMC S&P’s
   - Collaborates with business partners, vendors, consultants and manager
   to define service levels
   - Plans, schedules and conducts system tests; monitors test results; and
   directs follow-up
   - Develops restructure process routines; lead efforts to enhance
   performance of existing applications
   - Interfaces regularly with other IT teams and sections, business
   partners and business/requirements



*QUALIFICATIONS*



   - Bachelor’s degree in computer science, information systems,
   mathematics, engineering or related discipline required (Post-graduate
   degree desired)
   - Professional certification(s) desired
   - Minimum of 5 years of experience
   - 2+ years of Java and J2EE experience required.
   - Demonstrated knowledge of current programming languages and the
   ability to lead their use in solving complex business problems.. Experience
   in object-oriented design, model-view-controller pattern; and iterative
   development methodologies required. Knowledge of Java, J2EE, Spring
   framework, and RAD desired.
   - Advanced experience in Javascript/DHTML preferred
   - Advanced knowledge of SQL
   - Oracle experience and PL/SQL knowledge
   - Strong teambuilding and interpersonal skills.
   - Demonstrated proficiency at following accepted software development
   life cycles and associated standards and procedures.
   - Demonstrated experience in Object-Oriented Design
   - Understands the concepts, practices and procedures of common software
   development methodologies and associated artifacts, and can apply them to
   complex projects
   - Demonstrated ability to effectively adapt to changing technology and
   apply it to business needs
   - Demonstrated ability to establish and maintain a high level of trust
   and confidence with customers
   - Ability to work with minimal supervision
   - Ability to work effectively in a deadline-driven environment
   - Work experience with SOA is desired
   - Experience with Ajax technology desired
   - Working knowledge of Web services
   - Working knowledge of design patterns, continuous integration,
   automated unit test and test driven development
   - Ability to optimize queries and perform PL/SQL code profiling.
   - 4 + years with Oracle SQL, optimizer, and query plan
   - SQL Development, Tuning, Application Performance, Optimization is
   highly desired


-- 
Thanks and Regards,
Anil Vasudevan
IT Recruiter
Bigcode LLC
1 Farr View Dr Cranbury, NJ 08512 USA
Tell:  609 632 0190
Email: v...@bigcode.us 
www.bigcode.us

-- 
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 http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


[AngularJS] urgent requirement for Sr Java Consultant(with Oracle ADF)

2014-10-27 Thread anil vasudevan
*Hi*

*Hope you are doing well.*

 We have an urgent requirement for the below positions. Please go through
the job description and send me some matching resumes along with contact
details ASAP. Email:- v...@bigcode.us 


*Position: Sr Java Consultant(with Oracle ADF)*

*Location: Herndon, VA*


*Type: Contract (1 year)*


*Our Rate: DOE*

*Description:*

*Responsibilities:*

· Experience with jQuery (2+ yrs) to the requirements for the
position. (angularjs would be a plus).

· Minimum 3+ years of Java user-interface application development
experience

· 5+ years of experience developing applications with J2EE
technologies (JSP, Servlets, JDBC)

· Experience with developing applications using Oracle ADF

· Expertise with Java (OOPS Concepts, Error handling, etc.),
Object-Oriented Design, and Java Application Servers such as WebLogic or
WebSphere, and relational databases such as Oracle or DB2

· Experience with Linux, Web Services, XML, SOA and database
development using Oracle.

· Experience with jQuery (2+ years)  (angularjs a plus)

· Moderate experience of  Java Frameworks (JSF, SpringMVC, Struts,
etc.).

· Experience with Ant and Maven build tools.

· Strong knowledge of interface development and experience with
HTML, JavaScript, CSS, and AJAX

· Expertise in software engineering practices (e.g.,
reading/generating software specs, design patterns, continuous integration)

· Ability to think critically and creatively to develop innovative
solutions to software problems

· Service Oriented Architecture design and development experience a
plus

· Agile development experience a plus


-- 
Thanks and Regards,
Anil Vasudevan
IT Recruiter
Bigcode LLC
1 Farr View Dr Cranbury, NJ 08512 USA
Tell:  609 632 0190
Email: v...@bigcode.us 
www.bigcode.us

-- 
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 http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


[AngularJS] Urgent Requirement for Configuration Analyst Position

2014-10-27 Thread anil vasudevan
*Hi*

*Hope you are doing well.*

 We have an urgent requirement for the below positions. Please go through
the job description and send me some matching resumes along with contact
details ASAP. Email:- v...@bigcode.us 


*Location: Baton Rouge, LA*
*Duration: minimum 6 months (can be extended depending on project)*

*BE Configuration Analyst Position @ Baton Rouge, LA*


POSITION PURPOSE:
Under minimal supervision, this position is primarily responsible for the
identification and implementation of solutions which result in efficient,
accurate, and quality configuration of the company’s core and integrated
systems. This position takes a lead role in consulting with assigned
operations areas and guiding the decision-making process for identifying,
selecting, and modeling solutions to meet operations-identified needs,
goals, and metrics. This position ensures the timely configuration and
implementation of selected solutions either by directly completing the
solution or providing specifications and/or instructions for completion of
the solution and directing the efforts of others.

This position is accountable for complying with all laws and regulations
that are associated with assigned duties and responsibilities.

JD:

Acts as a liaison between the Business Engineering development group and
business units for the development and implementation of new systems and
enhancement of existing systems.
• Performs systematic analysis and determination of business requirements
to address specific business needs
• Analyzes business needs to determine optimal means of meeting those needs
• Translation of basic business needs into formal business, process, and
system requirements
• Represents team in project meetings for projects of small to medium
complexity, answering questions regarding the current system configuration
and capabilities
• Serves as the primary resource for gathering and documenting appropriate
business requirements and clearly communicates them back to internal staff
within Departmental and Team Leadership meetings
Provides support for software configuration testing and quality assurance
to ensure smooth, stable and timely implementation of new software
configuration or updates to installed configuration.
• Develops and executes detailed test cases ensuring the quality of
configuration
• Performs analysis of testing results
• Resolves configuration defects
• Ensures proper controls are established and maintained over test and
production systems to ensure quality of system configuration and processing
Provides Technical Leadership to ensure accurate and quality configuration
and maintenance of the company’s core and integrated systems.
• Works at the highest technical level of most phases of systems analysis
while considering the business implications of the application of
technology to the current and future business environment
• Works as the primary configuration analyst or leads a small team of
analysts on small to medium sized projects or complex configuration
implementations
• Without direction, handles all aspects of the development lifecycle for
all assigned work – requirements, analysis, build, unit test, defect
resolution, implementation
• Participates and contributes technical expertise in new configuration
design discussions and decisions
• Assists with development of training, best practices and processes to
ensure efficient, quality configuration of the core systems.
• Provides mentoring to lesser experienced analysts and technical design
reviews for peers to ensure consistent, accurate, quality configuration of
core systems
• Oversees and manages key controls throughout the configuration
development lifecycle including:
o Validating configuration for best practices and standards
o Managing the coordination, migration, and data integrity of configuration
between development, test, and production environments.
o Ensuring proper documentation for recordkeeping, change control, and
configuration maintenance
• Utilizes database and custom tools to assist with rapid implementation of
configuration
Responsible for managing or assisting with projects.
• Act as lead resource for configuration team on projects of small to
medium complexity
• Work with PMs to develop accurate realistic project schedules
• Participate in tracking/reporting activities to ensure project progress
• Identify risks to the project and work with PMs to develop responses and
mitigation strategies
• Communicate to Business Engineering Team on status of project
• Escalate Issues to Project Managers and Management when necessary to
prevent project delays and quality issues
Provides leadership to the team.
• Manages the work inventory of a small team of resources to ensure timely
completion of work while ensuring the efficiency and quality of
configuration
• Provides status reports to management on work inventory and advises on
resources needs
• Works with management to develop metrics to evaluate team member
performance
• Capt

[AngularJS] Re: Directive controler service $http json

2014-10-27 Thread Justin Walsh
Hi Benjamin, 

I plnkr is always recommended to illustrate your problem.  Questions with 
embedded code are not recommended and often ignored.
A good starting point is this template created by Sander: 
http://plnkr.co/edit/xLdPUYN36w1gjiBmZWTX?p=info

I'm feeling generous today, so here is a plnkr 
with code, slightly modified so that 
it works.

Two things:
1) Use the developer console of your browser to look for errors

2) The following is not valid JSON
{name:"view"}

Yes, its a valid JavaScript Object Literal 

 
and the two are often confused.  JSON is a interchange format (with its own 
set of rules).  This is valid JSON:

{"name":"view"}

Also:

   - 
   
http://stackoverflow.com/questions/2904131/what-is-the-difference-between-json-and-object-literal-notation
   - http://stackoverflow.com/questions/8294088/javascript-object-vs-json

Regards
Justin


On Monday, October 27, 2014 4:32:20 PM UTC+2, benjamin wrote:
>
> Hi all,
> I'm new to angularjs and I can't see why my code is blocked.
> I have an html page like this:
>
>   
>
> I want a directive named viewProducts to be inserted there
> my app.js:
> var route = '/learn/angularjs/';
> var app = angular.module("table",[]);
>
> app.directive("viewProducts",function(){
>  return{
>  restrict:"E",
>  templateUrl:route+"includes/view.html",
>  controller:['$scope','$http',function($scope,$http){
>  $http.get(route+'includes/view.json').success(function(data){
>  $scope.view = data;
>  });
>  }],
>  controllerAs:"view"
>  };
> });
>
>
> view.html:
>
>  {{view.name}} 
>
> view.json
>
> {name:"view"}
>
> When I open the browser I have a white page,
> don't understand why.
>
> Thank you for your help
> Benjamin
>

-- 
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 http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


[AngularJS] Re: [protractor] [e2e] Disabling animations in the tests

2014-10-27 Thread 'Michael Bielski' via AngularJS
You put it in your Protractor config file.

-- 
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 http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


[AngularJS] Directive controler service $http json

2014-10-27 Thread benjamin


Hi all,
I'm new to angularjs and I can't see why my code is blocked.
I have an html page like this:

  

I want a directive named viewProducts to be inserted there
my app.js:
var route = '/learn/angularjs/';
var app = angular.module("table",[]);

app.directive("viewProducts",function(){
 return{
 restrict:"E",
 templateUrl:route+"includes/view.html",
 controller:['$scope','$http',function($scope,$http){
 $http.get(route+'includes/view.json').success(function(data){
 $scope.view = data;
 });
 }],
 controllerAs:"view"
 };
});


view.html:

 {{view.name}} 

view.json

{name:"view"}

When I open the browser I have a white page,
don't understand why.

Thank you for your help
Benjamin

-- 
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 http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


Re: [AngularJS] Route interpolation

2014-10-27 Thread Marc Fallows
My next step is filing an issue on github to see if this is something they
would consider.

My first step was posting here to ensure that there wasn't an existing way
to do this. I thought I missed it in the AngularJS ngRoute documentation.

The thread keeps diverging from the original question of if the
interpolation is exposed in ngRoute. I'm going to assume "no" and I'll look
to continue this on github.

Thanks,

Marc Fallows
m...@marcfallows.com

On Mon, Oct 27, 2014 at 1:12 PM, Sander Elias  wrote:

> Hi Marc,
>
> I could also write my own forEach and isUndefined in plain javascript. But
>> since AngularJS already does this they expose it through an API, and I
>> don't have to write it.
>>
> The core team has on a number of occasions  put out, that they where
> unhappy with this decision. They do regret putting those utility functions
> in the core.
> and for that matter you don't need to program your own forEach
> ,
> it's available in ES5. As goes for quite some other utility functions.
>
>
>
>> I want to pass one of the paths that I original passed to
>> $routeProvider.when(path, {...}) along with an object of parameters and get
>> a resulting URL which I could set in $location.path().
>>
>
> Well, If you really want something like this in AngualrJS, file issue on
> github. If you accompany it with an Pull Request, with fully tested code,
> there is a fair change
> it will get included in one of the next 1.3.x versions.
>
> Regards
> Sander
>
> --
> You received this message because you are subscribed to a topic in the
> Google Groups "AngularJS" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/angular/bEX5Ateee98/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to
> angular+unsubscr...@googlegroups.com.
> To post to this group, send email to angular@googlegroups.com.
> Visit this group at http://groups.google.com/group/angular.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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 http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


[AngularJS] Re: isolate scope $destroy event

2014-10-27 Thread Sander Elias
Hi Per,

That's the spirit! :-)
BTW, I do agree that the documentation on this a a tiny bit scarce ;)

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 http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


[AngularJS] Re: isolate scope $destroy event

2014-10-27 Thread Per Rovegård
Hi,

I'd argue that prototypical scope inheritance and destruction of scopes can 
be seen as two different things, meaning that the text you refer to doesn't 
really help.

Also, I think a documentation update would be useful for people that will 
remain on Angular 1.x for a while (since I suppose migration will be 
non-trivial due to the big architectural changes).

I guess I should be a good citizen and submit a documentation PR. :-)

Per

On Monday, October 27, 2014 1:55:13 PM UTC+1, Sander Elias wrote:
>
> Hi Per,
>
> From the docs:
>
> Scope:
> If set to {} (object hash), then a new "isolate" scope is created. The 
> 'isolate' scope differs from normal scope in that it does not 
> prototypically inherit from the parent scope.
>
> That tells you that an isolate scope is an object that does not inherit 
> from its parent, and in turn not from $rootScope. This means that the 
> functions you want to refer to are also not available. I agree that this 
> might be better documented. 
>
> However, from Angular 2.x, there will be no $scope anymore, so this is an 
> temporary issue ;)
>
> 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 http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


[AngularJS] Re: Angularjs issue - $http.get not working and changed into OPTIONS - Cross domain

2014-10-27 Thread Sander Elias
Hi Amadese,

If you open the developer tools in your browser, what is the error you are 
getting?

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 http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


Re: [AngularJS] Route interpolation

2014-10-27 Thread Sander Elias
Hi Marc,

I could also write my own forEach and isUndefined in plain javascript. But 
> since AngularJS already does this they expose it through an API, and I 
> don't have to write it.
>
The core team has on a number of occasions  put out, that they where 
unhappy with this decision. They do regret putting those utility functions 
in the core.
and for that matter you don't need to program your own forEach 
,
 
it's available in ES5. As goes for quite some other utility functions.

 

> I want to pass one of the paths that I original passed to 
> $routeProvider.when(path, {...}) along with an object of parameters and get 
> a resulting URL which I could set in $location.path().
>
 
Well, If you really want something like this in AngualrJS, file issue on 
github. If you accompany it with an Pull Request, with fully tested code, 
there is a fair change
it will get included in one of the next 1.3.x versions.

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 http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


[AngularJS] Re: Angularjs issue - $http.get not working and changed into OPTIONS - Cross domain

2014-10-27 Thread amadese
Thanks for the link. I have tried it, but the problem is always present. I 
have tried server side Coldfusion and/or client side. :-( 

Le lundi 27 octobre 2014 12:42:55 UTC+1, Sander Elias a écrit :
>
> Hi Amadese,
>
> CORS is mainly a server side problem . Have a 
> look at the site I just linked. Probably the answer for your server is 
> right there.
>
> 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 http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


[AngularJS] Data retrieval with jsp using angular js

2014-10-27 Thread bcsf11m023
 

May be it is not a worthy question but i am new at angular js that is why 
going to ask this ! I have a small portal which has forms develop in jsp. 
Now my requirement is to display data from db on page by not moving to next 
page using Angular JS. Can i do this easily using jsp? or I should use c#? 
But transferring from jsp to c# will be quite daunting task! I shall be 
very great full if someone suggest a way using jsp. 

Kind Regards. 

-- 
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 http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


[AngularJS] Re: isolate scope $destroy event

2014-10-27 Thread Sander Elias
Hi Per,

>From the docs:

Scope:
If set to {} (object hash), then a new "isolate" scope is created. The 
'isolate' scope differs from normal scope in that it does not 
prototypically inherit from the parent scope.

That tells you that an isolate scope is an object that does not inherit 
from its parent, and in turn not from $rootScope. This means that the 
functions you want to refer to are also not available. I agree that this 
might be better documented. 

However, from Angular 2.x, there will be no $scope anymore, so this is an 
temporary issue ;)

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 http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


Re: [AngularJS] Route interpolation

2014-10-27 Thread Marc Fallows
Hi Sander,

I could also write my own forEach and isUndefined in plain javascript. But
since AngularJS already does this they expose it through an API, and I
don't have to write it.

Given the test I mentioned slightly modified below, how would I use the
URLUtils inside the *someFunction *method to pass? It doesn't seem to have
any concept of route style parameters.

it('should interpolate a route with optional parameter excluded',
function(){
   var searchRoute = "/search/:query/:limit?";
   var url = *someFunction*(searchRoute, {query: 'foo'});
   expect(url).toBe("/search/foo");
}

AngularJS's ngRoute does this work already (
https://github.com/angular/angular.js/blob/master/src/ngRoute/route.js#L631).
I was wondering if I could save myself writing the parser and interpolator
and the unit tests since they already have a working implementation
covering all the edge cases.

I want to pass one of the paths that I original passed to
$routeProvider.when(path, {...}) along with an object of parameters and get
a resulting URL which I could set in $location.path().

I have no problems on how to write the plain javascript to parse everything
the same way AngularJS does. But I was wondering if AngularJS exposed that
in any way, so I could just use theirs (and get test coverage, edge cases
and future improvements along with it for free).

Cheers,

Marc Fallows
m...@marcfallows.com

On Mon, Oct 27, 2014 at 11:38 AM, Sander Elias 
wrote:

> Hi Marc,
>
> You can build an url using plain javascript
> , no need for
> angular to provide sugar over that.
>
> Regards
> Sander
>
> --
> You received this message because you are subscribed to a topic in the
> Google Groups "AngularJS" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/angular/bEX5Ateee98/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to
> angular+unsubscr...@googlegroups.com.
> To post to this group, send email to angular@googlegroups.com.
> Visit this group at http://groups.google.com/group/angular.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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 http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


[AngularJS] Re: isolate scope $destroy event

2014-10-27 Thread Per Rovegård
Hi Sander,

Thank you for the clarification. Is this documented? I skimmed the docs and 
found a best practice regarding this but for transcluded scopes 
(https://docs.angularjs.org/api/ng/service/$compile#transclusion). Perhaps 
the best practice should be repeated under isolate scopes as well?

Per

On Monday, October 27, 2014 10:26:00 AM UTC+1, Sander Elias wrote:
>
> Hi Chrisopher, Per,
>
> Yes, this is expected behavior. An isolate scope is indeed well isolated. 
> For good reasons.
> There are a couple of things you can do.
> Firstly, you can do what Per suggested in his msg.
> Secondly, you can listen do something like 
> $scope.$parent.$on('$destroy',function 
> () {...})
>
> 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 http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


[AngularJS] Re: [angular.js] Angular.js + Sencha Touch

2014-10-27 Thread Saranya M
 Hi,

   I am new to AngularJs. I want to combine sencha Touch with AngularJs 
using sencha touch angular adapter. The example in 
http://jsfiddle.net/tigbro/xVBRE/3/  is not executed as the server is 
temporarily not enabled. Can u execute the code.

Thanks,
Saranya

-- 
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 http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


[AngularJS] Re: Angularjs issue - $http.get not working and changed into OPTIONS - Cross domain

2014-10-27 Thread Sander Elias
Hi Amadese,

CORS is mainly a server side problem . Have a look 
at the site I just linked. Probably the answer for your server is right 
there.

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 http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


Re: [AngularJS] Route interpolation

2014-10-27 Thread Sander Elias
Hi Marc,

You can build an url using plain javascript 
, no need for angular 
to provide sugar over that.

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 http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


[AngularJS] Angularjs issue - $http.get not working and changed into OPTIONS - Cross domain

2014-10-27 Thread amadese


I am a novice to Angularjs and tried to create a remote service (located on 
"http://dev.testmyserver2";) for using in various applications (located on "
http://dev.testmyserver";).

This service retrieves various data about a user by using Colfusion and an 
Oracle database. It works perfectly when I launch the application directly 
in the browser. Nevertheless when I tried to call the function of this 
service (defined in the factory) from another application (thanks to a 
dependency called in the main module of this application), the http GET is 
modified in OPTIONS (visible in firebug) and I cannot retrieve the data 
(the status code of the http request is O). The function is correctly 
called (an alert "Function correctly called" or console.log from this 
function is correctly called), but no data of the person is retrieved.

I think that it's *a problem of Cross domain*. But I do not know how to 
solve it.

Here a little code:

   - *THE REMOTE SERVICE* with functions for retrieving data from a database


   - MODULE - appRemoteService.js:
   
var app=angular.module('RemoteService', ['ngRoute', 'ui.bootstrap']);

app.config(function($routeProvider, $httpProvider, ngDialogProvider){

// disable IE ajax request caching
$httpProvider.defaults.cache = false;
if (!$httpProvider.defaults.headers.get) {
$httpProvider.defaults.headers.get = {};
}
$httpProvider.defaults.headers.get['If-Modified-Since'] = '0';

// Create the routes
$routeProvider.when('/home',
{
  templateUrl: 'template/allPersons.html',
  controller: 'ctrlPersons'

})

.when('/documentation',
{
  templateUrl: 'template/documentation.html',
  controller: 'ctrlDocumentation'
})  

.otherwise({redirectTo:'/home'});  
});

app.controller('ctrlPersons', function ($scope, FactoryRemoteService){
FactoryRemoteService.getUserFromLogin("test").success(function(personInfo){
alert(personInfo["VALUES"][0]["FIRSTNAME"]);
}); 
});



   - FACTORY - appFactoryRemoteService.js:
   
app.factory('FactoryRemoteService', function($http){
var factory={};
factory.getUserFromLogin=function(uid){
Alert("Function correctly called");
return 
$http.get('http://dev.testmyserver2/myapp.cfc?method=getUserFromLogin&login=' + 
uid);
};

return factory; 
})



   - *MY APPLICATION*:


   - MAIN FILE - index.html:
   
 My app





  








MY APP


All contacts
Add contacts






  

  
   


  
  

   

  
  

  http://dev.testmyserver2/app/appRemoteService.js";>
  http://dev.testmyserver2/app/appFactoryRemoteService.js";> 





   - MODULE - app.js:
   
var app=angular.module('ContactsApp', ['ngRoute', 'ui.bootstrap', 
'RemoteService']);

// register the interceptor as a service
app.factory('HttpInterceptor', ['$q', '$rootScope', function($q, $rootScope) {
   return {
// On request success
request : function(config) {
// Return the config or wrap it in a promise if blank.
return config || $q.when(config);
},

// On request failure
requestError : function(rejection) {
//console.log(rejection); // Contains the data about the error on the 
request.  
// Return the promise rejection.
return $q.reject(rejection);
},

// On response success
response : function(response) {
//console.log(response); // Contains the data from the response.
// Return the response or promise.
return response || $q.when(response);
},

// On response failure
responseError : function(rejection) {
//console.log(rejection); // Contains the data about the error.
//Check whether the intercept param is set in the config array. 
//If the intercept param is missing or set to true, we display a modal 
containing the error
if (typeof rejection.config.intercept === 'undefined' || 
rejection.config.intercept)
{
//emitting an event to draw a modal using angular bootstrap
$rootScope.$emit('errorModal', rejection.data);
}
// Return the promise rejection.
return $q.reject(rejection);
}
};
}]);

app.config(function($routeProvider, $httpProvider){
// disable IE ajax request caching
$httpProvider.defaults.cache = false;
if (!$httpProvider.defaults.headers.get) {
$httpProvider.defaults.headers.get = {};
}   
$httpProvider.defaults.headers.get['If-Modified-Since'] = '0';

// Add the interceptor to the $httpProvider to intercept http calls
$httpProvider.interceptors.push('HttpInterceptor');

$routeProvider.when('/all-contacts',
{
  templateUrl: 'template/allContacts.html',
  controller: 'ctrlContacts'

})
.when('/view-contacts/:contactId',
{
  templateUrl: 'template/viewContact.html',
  controller: 'ctrlViewContacts'
})
.otherwise({redirectTo:'/all-contacts'});  

});


app.controller('NavbarController', function($scope, $location){
$s

[AngularJS] Re: Videos from ng-europe

2014-10-27 Thread Eduardo Teixeira
Let's wait...

Thank you very much!


Em segunda-feira, 27 de outubro de 2014 03h52min42s UTC-2, Sander Elias 
escreveu:
>
> Hi Eduardo,
>
> They will become available within 2 weeks. I will put them here as soon as 
> they become available.
>
> Regards
> Sander Elias
>

-- 
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 http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


Re: [AngularJS] Re: How to coopt ng-repeat ?

2014-10-27 Thread Gary M
Hi Sander

I'm sure there are going to be plenty of edge cases.. That's why I wanted
>> something simple at first. I'm hoping to get 90% case coverage with 10%
>> effort ?
>>
> I'm afraid that in this case the numbers will be more like 75% coverage
> with 40% effort. But don't let me talk you out of it. If you get this
> running it will be an enormous help to
> a fair number of developers.
>

Well, we can see how it goes.. . If I append the inject property defined in
scope to $attr in ng-repeat's compile, it looks like it should work fairly
cleanly. ng-repeat evaluates the $attrs properly, so if I'm careful to keep
it simple, it should work.

>
> I haven't really explored angular 2.0, I'm not on the inside track, so
>> I'll have to wait until its solid.. I believe this project will be
>> significantly easier with 2.x and will require a ground up redesign.
>>
> Well, I keep my eye on 2.x and yes and yes ;)
>
>
>> I do like the annotation driven compiler, specifically the ability to
>> inject arbitrary annotations to specific objects.  Annotations support
>> becomes increasingly important in interpreted languages to easily create
>> new features. I do recommend compile on the fly to reconfigure execution
>> orders as lazy and on-demand modules are required. The documentation
>> alludes to this, but its unclear whether the hierarchy just supports lazy
>> compile or dynamic/modifiable configuration   . Also, I see nothing wrong
>> with the global state, other than static configuration.
>>
> Hi, If you are talking about the annotations from 2.0, those are part of
> ATscript. ATscript compiles to  ES5. As it is an language that does
> compiling you can't use in the browser to do on the fly compilation(not in
> a well performing way anyhow)
>

If the compile is done in the background in a private node which is then
moved to the proper location in the DOM, it may work fairly transparently
to the user. A wrapper around the compiler could perform those operations..


> Lazy loading will be supported, but this will be largely part of the new
> router. And of course when ES6 modules become readily available, those will
> be usable too.
>

Hmmm interesting

b/r gary

>
> Regards
> Sander
>
> --
> You received this message because you are subscribed to a topic in the
> Google Groups "AngularJS" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/angular/ZNiEC50si2o/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to
> angular+unsubscr...@googlegroups.com.
> To post to this group, send email to angular@googlegroups.com.
> Visit this group at http://groups.google.com/group/angular.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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 http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


[AngularJS] Re: Dynamically loaded compiled tooltip

2014-10-27 Thread Aviad Pineles
Hi, thanks for the reply, I am relatively new to AngularJS and I am not 
quite sure how to do what you suggest. Can you provide a plunker example or 
something to help me start on this?

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 http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


Re: [AngularJS] Route interpolation

2014-10-27 Thread Marc Fallows
I may be missing what you guys are suggesting. What I want is to be able to
build the route, not find out the route parameters on the current route.

If $route.interpolate existed I would expect the tests below to pass.
Angular already has an interpolate in ngRoute. I can copy theirs, or write
my own, but ideally I would use their existing one. As far as I can tell
it's not exposed, but I'm hoping I'm wrong.

it('should interpolate a route', function(){
   var searchRoute = "/search/:query/:limit?";
   var url = $route.interpolate(searchRoute, {query: 'foo', limit: 10});
   expect(url).toBe("/search/foo/10");
}

it('should interpolate a route with optional parameter excluded',
function(){
   var searchRoute = "/search/:query/:limit?";
   var url = $route.interpolate(searchRoute, {query: 'foo'});
   expect(url).toBe("/search/foo");
}

Cheers,

Marc Fallows
m...@marcfallows.com

On Mon, Oct 27, 2014 at 1:03 AM, Witold Szczerba 
wrote:

> As Sander said, the $routeParams is the missing service :-)
>
> Regards,
> Witold Szczerba
> 25 paź 2014 07:30 "Sander Elias"  napisał(a):
>
>> Hi Marc,
>>
>> As I just said somewhere else, I'm still a bit groggy from ngEurope. So I
>> might have missed a point in your question.
>> can't you just inject $routeParams
>>  into your
>> controller/whatever where you need this?
>>
>> 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 http://groups.google.com/group/angular.
>> For more options, visit https://groups.google.com/d/optout.
>>
>  --
> You received this message because you are subscribed to a topic in the
> Google Groups "AngularJS" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/angular/bEX5Ateee98/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to
> angular+unsubscr...@googlegroups.com.
> To post to this group, send email to angular@googlegroups.com.
> Visit this group at http://groups.google.com/group/angular.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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 http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


[AngularJS] Re: isolate scope $destroy event

2014-10-27 Thread Sander Elias


Hi Chrisopher, Per,

Yes, this is expected behavior. An isolate scope is indeed well isolated. 
For good reasons.
There are a couple of things you can do.
Firstly, you can do what Per suggested in his msg.
Secondly, you can listen do something like 
$scope.$parent.$on('$destroy',function 
() {...})

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 http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


Re: [AngularJS] Re: Preserving Expensive Elements - stashing and moving around DOM nodes

2014-10-27 Thread Sander Elias
Hi Dan,

Can you provide a plunker that illustrates your problem? With a couple of 
directives it should not be that hard to cache some elements.

Regards
Sander Elias

-- 
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 http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


Re: [AngularJS] Re: How to coopt ng-repeat ?

2014-10-27 Thread Sander Elias
Hi Garys

I'm sure there are going to be plenty of edge cases.. That's why I wanted 
> something simple at first. I'm hoping to get 90% case coverage with 10% 
> effort ?
>
I'm afraid that in this case the numbers will be more like 75% coverage 
with 40% effort. But don't let me talk you out of it. If you get this 
running it will be an enormous help to 
a fair number of developers.

I haven't really explored angular 2.0, I'm not on the inside track, so I'll 
> have to wait until its solid.. I believe this project will be significantly 
> easier with 2.x and will require a ground up redesign.
>
Well, I keep my eye on 2.x and yes and yes ;)
 

> I do like the annotation driven compiler, specifically the ability to 
> inject arbitrary annotations to specific objects.  Annotations support 
> becomes increasingly important in interpreted languages to easily create 
> new features. I do recommend compile on the fly to reconfigure execution 
> orders as lazy and on-demand modules are required. The documentation 
> alludes to this, but its unclear whether the hierarchy just supports lazy 
> compile or dynamic/modifiable configuration   . Also, I see nothing wrong 
> with the global state, other than static configuration.  
>
Hi, If you are talking about the annotations from 2.0, those are part of 
ATscript. ATscript compiles to  ES5. As it is an language that does 
compiling you can't use in the browser to do on the fly compilation(not in 
a well performing way anyhow)
Lazy loading will be supported, but this will be largely part of the new 
router. And of course when ES6 modules become readily available, those will 
be usable too.

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 http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


[AngularJS] Re: isolate scope $destroy event

2014-10-27 Thread Per Rovegård
+1

I came here with the same question. Is the non-destruction of isolated 
scopes intentional?

To manually destroy the isolate scope, we can act on the element $destroy 
event:

element.on('$destroy', function () {
  scope.$destroy();
});

But my assumption/hope/expectation was that Angular took care of this...

On Tuesday, July 8, 2014 1:52:16 PM UTC+2, Christopher Ng wrote:
>
> sorry, i know that's why it isn't working.  my question is, is this 
> expected behaviour?  if so, is it possible to be notified when the element 
> that the scope 'belongs' to is destroyed?
>
> On Monday, July 7, 2014 6:42:45 PM UTC+1, Sander Elias wrote:
>>
>> Hi Christopher,
>>
>> Your directive has an empty isolate scope, the isolation prevents it from 
>> receiving the destruction event.
>> if you remove the scope, or make in an new scope in stead of an isolate, 
>> it will work.
>>
>> 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 http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


Re: [AngularJS] Re: Preserving Expensive Elements - stashing and moving around DOM nodes

2014-10-27 Thread Dan Dascalescu
A year later - any updates on the sanctioned way to preserve expensive 
elements? I have a Google Maps that I want preserved (center, zoom etc.) 
when navigating among routes, and this seems like a basic enough feature of 
a routing package that it should already be implemented.

So far I've only found an add-on to ui-router, called ui-router-extras, 
which didn't work 
 out of 
the box.

On Wednesday, October 2, 2013 2:30:53 PM UTC-7, Ruaidhrí Devery wrote:
>
> Oh I see, I'll give it a try. If I can get something working how I want 
> I'll post up a fiddle
>
> Thanks for the help!
>
> R
>
>
> On 2 Oct 2013, at 12:12, Sebastien Vincent wrote:
>
> You don't recompile the template each time, you redraw. Compile is to 
> bind, not to draw. You can reuse dom element when you redraw, as long as it 
> reflect the data and it is properly unit tested. If you do thing in order, 
> it'll be easy to get thing working and only then optimize. 
>
> On Thursday, October 3, 2013 2:20:43 AM UTC+8, Ruaidhrí Devery wrote:
>>
>> ng-repeat triggers $animate#move 
>>  to reposition DOM 
>> elements so as to "reuse the associated scope/element"
>>
>> I think that this is as much for usability as it is optimization. 
>> Re-compiling the template every time the order changes is a real issue for 
>> UI continuity*.
>>
>> What I'm trying to achieve is a similar. I'm hoping to maintain the 
>> continuity of a list of elements, only my list structure requires elements 
>> to be moved between root nodes not just within them.
>>
>> rur
>>
>> * and also for control requiring granular component state to be moved up 
>> the scope hierarchy.
>>
>>
>>
>>
>> On Tuesday, 1 October 2013 20:11:51 UTC-7, Sebastien Vincent wrote:
>>>
>>> I don't think ng-repeat moves DOM around, it keeps data and presentation 
>>> separated and redraw on change. 
>>>   
>>> The point of scope is to "maintain the component state for the duration 
>>> of execution". $compile allows you to create a new scope for your template 
>>> at the target. Then you need to move data between the old scope and new 
>>> scope and it will look like the data has moved. 
>>>
>>> On Wednesday, October 2, 2013 8:07:47 AM UTC+8, Ruaidhrí Devery wrote:

 Yea I remove and reinsert the element. I did try $compiling the element 
 before reinserting, but as expected it clobbered the state within the 
 include tag.

 I'm going to take a closer look at the ng-repeat implementation and see 
 how it moves DOM nodes around. If I find anything useful I will post.

 rur




 On Tuesday, 1 October 2013 15:35:44 UTC-7, OpenNota wrote:
>
> I lose Angular mouse event bindings (at least). 
>
>  
> Do you remove element from DOM and then reinsert it? If so, then you 
> probably need to $compile it after.
>

>

-- 
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 http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


[AngularJS] Re: [protractor] [e2e] Disabling animations in the tests

2014-10-27 Thread Shobha Joshi
Can you please suggest me, how to use this script, what you have written 
here. 

I mean where to put this? I copied as it is in my describe block before any 
of the test case (it block), and I see syntax errors in this.

On Thursday, November 14, 2013 2:06:20 AM UTC+11, OpenNota wrote:
>
> I've found one way to disable angular animations in E2E tests:
>
> browser.driver.executeScript "
>>   var $injector = 
>> angular.element(document.documentElement).data('$injector');
>>   var $animate = $injector.get('$animate');
>>   $animate.enabled(false);
>>   "
>
>
> Is there a more elegant solution?
>
>

-- 
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 http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.


[AngularJS] Re: Dynamically loaded compiled tooltip

2014-10-27 Thread system
I would add callback function for directive ('loadData'), that user specify 
in html, and it will be used to make request. And then specify another 
scope object in html ('data'), that will be used to populate data from http 
request. Http call and resolve will be done completely in that specified 
callback function 'loadData' (this allow to use any http provider) and 
promise is resolved to scope object specified in 'data'.



On Sunday, October 26, 2014 7:56:51 PM UTC+2, Aviad Pineles wrote:
>
> Hello folks, I'm trying to achieve something that's apparently not so 
> easy. I want to be able to load data dynamically when the user hovers for 
> over 500 msec over an element. Once that data is loaded I want to create a 
> suitable scope and compile a template, then I want the result to be 
> displayed as a tooltip using ui.bootstrap's tooltip module.
>
> I've designed a plunker that does exactly that, but it's extremely tightly 
> coupled with the specific controller and view. I want to be able to turn it 
> into a directive.
>
> The plunker simulates a real world situation where I wait for 500msec 
> after mouse-enter, then initiate an asynchronous load (which takes 5 
> seconds), and then the tooltip is updated. The tooltip has 3 states: 
> waiting (the first 500 msec when i'm not sure the user actually wants to 
> see the tooltip, and I don't want to initiate the ajax request just yet), 
> loading and loaded, it is evident from the plunker.
>
> Please have a look at the plunker 
>  to see the details.
>
> Again, my goal is to convert this into something reusable, a module, a 
> directive or both.
>
> 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 http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.