Zyring Day 3 – adding views and controllers, and getting confused

[Note: These are more in-depth (read: tedious) write-ups of my experience with each section of the Zyring project, leading on from my intro post on Zyring. This is mostly for my own benefit but could conceivably be of use to someone doing the project.]

Creating a new view and controller

I found this tutorial confusing and would have appreciated a little more guidance in exactly I was supposed to do. Of course, I’m expecting to struggle more with the Angular parts as it is new to me, but I’m not sure that was the whole problem. As far as I can make out I was supposed to create some kind of new view and controller, but it wasn’t very clear what they should do. I interpreted the task as making a view and controller for each city. I had no idea how to automate this, so I manually created an html page for each city (which currently just says ‘BANANAS!!!’) and a corresponding controller, and then individually linked each controller on the index.html page.

This worked, in that clicking on Seattle or whatever took me to an exciting ‘BANANAS!!!’ page, but it’s not really very clever. It looks like the next tutorial will explain how to do things properly.

Nothing else to report for Day 3 though as I spent most of it writing the big old intro post.


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s