Skip to content

Commit

Permalink
Mobile version can create projects
Browse files Browse the repository at this point in the history
  • Loading branch information
orbanbotond committed Nov 29, 2011
1 parent 4ba54e7 commit a51659b
Show file tree
Hide file tree
Showing 4 changed files with 64 additions and 0 deletions.
8 changes: 8 additions & 0 deletions app/views/proiects/_form.mobile.haml
@@ -0,0 +1,8 @@
#forms
= simple_form_for(@proiect) do |f|
= f.error_notification
%ul.edit.rounded
%li= f.input :title
%li= f.input :description
%li= f.association :users
%a.submit.blueButton.new_project{ :href => '#' } Submit
30 changes: 30 additions & 0 deletions app/views/proiects/index.mobile.haml
@@ -0,0 +1,30 @@
!!! XML
!!!
%html
%head
%title= h(yield(:title) || "Hazifeladat")
= stylesheet_link_tag "/jqtouch/jqtouch.css", "/jqtouch/themes/apple/theme.css"
= javascript_include_tag "/jqtouch/jquery.min.js", "/jqtouch/jqtouch.js", "mobile"
= stylesheet_link_tag 'mobile' if mobile_device?
= csrf_meta_tags

%body
#jqt
#main
.toolbar
%h1 Project management

- unless flash.empty?
.info
- flash.each do |name, msg|
= content_tag :div, msg, :id => "flash_#{name}"
%ul
- for project in @proiects
%li.arrow
= link_to project.title, project
%ul
%li.arrow
= link_to "New Project", new_proiect_path

.info
maximus
6 changes: 6 additions & 0 deletions app/views/proiects/new.mobile.haml
@@ -0,0 +1,6 @@
%div{ :id => "projectsnew"}
.toolbar
= link_to "Back", "#", :class => "back"
%h1 New project
.content
= render 'form'
20 changes: 20 additions & 0 deletions app/views/proiects/show.mobile.haml
@@ -0,0 +1,20 @@
%div{ :id => "projects#{@proiect.id}" }
.toolbar
= link_to "Back", "#", :class => "back"
%h1 Project management
.content
%p#notice= notice

%p
%b Title:
= @proiect.title

%p
%b Desription:
= @proiect.description

%p
%b Participants:
%ul
- @proiect.users.each do |user|
%li= link_to user.name, user_url(user)

0 comments on commit a51659b

Please sign in to comment.