diff --git a/app/assets/images/foto_perfil.jpg b/app/assets/images/foto_perfil.jpg new file mode 100644 index 0000000..b64eda7 Binary files /dev/null and b/app/assets/images/foto_perfil.jpg differ diff --git a/app/controllers/planet_controller.rb b/app/controllers/planet_controller.rb index be7ac0a..b6c94e5 100644 --- a/app/controllers/planet_controller.rb +++ b/app/controllers/planet_controller.rb @@ -8,4 +8,7 @@ def contact def ejemplo end + def author + end + end diff --git a/app/controllers/types_controller.rb b/app/controllers/types_controller.rb index da826f4..323e892 100644 --- a/app/controllers/types_controller.rb +++ b/app/controllers/types_controller.rb @@ -10,6 +10,17 @@ def index end end + # GET /types/ordered_index + # GET /types/ordered_index.json + def ordered_index + @types = Type.find(:all,:order=>:name) + + respond_to do |format| + format.html # ordered_index.html.erb + format.json { render json: @types } + end + end + # GET /types/1 # GET /types/1.json def show diff --git a/app/views/layouts/application.html.erb b/app/views/layouts/application.html.erb index 062c0a4..3c20170 100644 --- a/app/views/layouts/application.html.erb +++ b/app/views/layouts/application.html.erb @@ -8,7 +8,11 @@ + <%= link_to('Index', planet_index_path) + " " + link_to('Contact', planet_contact_path) + " " + link_to('Ejemplo', planet_ejemplo_path) + " " + link_to('Autor', planet_author_path) + " " + link_to('Types', types_path) + " " + link_to('Ordered Index Types', types_ordered_index_path) %> + <%= yield %> + <%= link_to('Index', planet_index_path) + " " + link_to('Contact', planet_contact_path) + " " + link_to('Ejemplo', planet_ejemplo_path) + " " + link_to('Autor', planet_author_path) + " " + link_to('Types', types_path) + " " + link_to('Ordered Index Types', types_ordered_index_path) %> + diff --git a/app/views/planet/author.html.erb b/app/views/planet/author.html.erb new file mode 100644 index 0000000..aa02ecd --- /dev/null +++ b/app/views/planet/author.html.erb @@ -0,0 +1,10 @@ +

Autor

+ +<%= image_tag('foto_perfil.jpg') %> +