Connecting the Router with a ControllerAsk Questions

 Posted on 14/07/2018 8:13:30 AM

I am learning AngularJS for an interview (so I'm a noob to this) I'm following a tutorial on Udemy it only addresses 1.5. I even looked at the docs and have tried the wiring they have presented. The customer view is now broken and I am having a prior problem again which I referred back to my old StackOverflow question why the data for orders isn't dynamically displayed. What am I doing wrong and an explanation would be appreciated so I can learn the right way of AngularJS for the interview? Any help is much appreciated I'm using the latest version of AngularJS 1.7. I know the customers variable is repeated code in the controller that can be refactored into a factory, but I'm just taking it a step at time :).

I've added a plunker in the app.js the commented code I don't see any error, but with the uncommented code I get two errors the first is a little convoluted with semi-colons and the second I read the angular docs on the error and can't see the mistake still. I feel like I need a second pair of eyes.

Error 1:

app.js:33 Uncaught TypeError: (intermediate value)(intermediate value).controller is not a function
    at app.js:33

Error 2:

angular.js:15018 Error: [$controller:ctrlreg]$controller/ctrlreg?p0=MainCtrl
    at angular.js:99
    at angular.js:11133
    at aa (angular.js:10215)
    at p (angular.js:10007)
    at g (angular.js:9370)
    at g (angular.js:9373)
    at angular.js:9235
    at angular.js:1941
    at m.$eval (angular.js:18838)
    at m.$apply (angular.js:18937)
Share On: facebook gplus twitter
Asked by ketan Linbachiya on 14/07/2018 8:13:30 AM Score: 269 points
Add Comment:


0 Answer

0 Corrected Answers

Post Your Answer


Existing Members

Sign in to your account
Email Address
...or Join us
Download, Vote, Comment, Publish.
Full Name
Email Address
I have read and agree to the Terms of Service and Privacy Policy
Please subscribe me to the StoodQ newsletters
Guideline to answer a question:

Useful tips to submit your answer
Please read below guidelines before you submit your answer for question.

  • Read and understand question for which you are submitting your answer.
  • Try to avoid grammatical and spell mistake while answering.
  • Do not post any irrelevant information in your answer.
  • Explain your answer with example or any reference link to help who posted question.
  • If you find irrelevant question, please report it to support. Click here to contact support.
  • You agree to the privacy policy and terms of use to submit any contents.

Note: StoodQ is online developers community which helps developer for their difficulty, lets help them with your value contribution.