45. Building a simple app table from “Ruby on Rails Tutorial: Learn Rails by Example”
available at http://ruby.railstutorial.org/
§ Correspondence between pages and URLs
46. Building a simple app diagram from “Ruby on Rails Tutorial: Learn Rails by Example”
available at http://ruby.railstutorial.org/
§ MVC in Rails
47. Building a simple app diagram from “Ruby on Rails Tutorial: Learn Rails by Example”
available at http://ruby.railstutorial.org/
§ MVC in Rails
The browser
issues a request
for the
URL
48. Building a simple app diagram from “Ruby on Rails Tutorial: Learn Rails by Example”
available at http://ruby.railstutorial.org/
§ MVC in Rails
Rails routes
to the index
action in the
49. Building a simple app diagram from “Ruby on Rails Tutorial: Learn Rails by Example”
available at http://ruby.railstutorial.org/
§ MVC in Rails
the !
50. Building a simple app diagram from “Ruby on Rails Tutorial: Learn Rails by Example”
available at http://ruby.railstutorial.org/
§ MVC in Rails
51. Building a simple app diagram from “Ruby on Rails Tutorial: Learn Rails by Example”
available at http://ruby.railstutorial.org/
§ MVC in Rails The index action asks
the Key model to retrieve
all keys ( )
52. Building a simple app diagram from “Ruby on Rails Tutorial: Learn Rails by Example”
available at http://ruby.railstutorial.org/
§ MVC in Rails
The Key model
pulls all the keys
from the database
53. Building a simple app diagram from “Ruby on Rails Tutorial: Learn Rails by Example”
available at http://ruby.railstutorial.org/
§ MVC in Rails
The Key model returns the list
of keys to the controller
54. Building a simple app diagram from “Ruby on Rails Tutorial: Learn Rails by Example”
available at http://ruby.railstutorial.org/
§ MVC in Rails
The controller captures
the keys in the @keys
variable, which is passed
to the
55. Building a simple app diagram from “Ruby on Rails Tutorial: Learn Rails by Example”
available at http://ruby.railstutorial.org/
§ MVC in Rails
The controller captures
the keys in the @users
variable, which is passed
to the
56. Building a simple app diagram from “Ruby on Rails Tutorial: Learn Rails by Example”
available at http://ruby.railstutorial.org/
§ MVC in Rails
The controller captures
the keys in the @users
variable, which is passed
to the
57. Building a simple app diagram from “Ruby on Rails Tutorial: Learn Rails by Example”
available at http://ruby.railstutorial.org/
§ MVC in Rails The view uses embedded Ruby
to render the page as HTML
58. Building a simple app diagram from “Ruby on Rails Tutorial: Learn Rails by Example”
available at http://ruby.railstutorial.org/
§ MVC in Rails
The controller passes the
HTML back to the browser