Skip to content
This repository has been archived by the owner on May 18, 2021. It is now read-only.

Commit

Permalink
Merge branch 'release/v19.2'
Browse files Browse the repository at this point in the history
  • Loading branch information
PanfilovDenis committed Mar 29, 2013
2 parents ce4cd0b + f43b5d1 commit f6b7f5b
Show file tree
Hide file tree
Showing 3 changed files with 68 additions and 74 deletions.
36 changes: 17 additions & 19 deletions app/views/web/lectors/index.html.haml
Original file line number Diff line number Diff line change
Expand Up @@ -3,23 +3,21 @@
.row.workshop
.span3
%ul.nav.nav-list.b-affix
- cache(:action_suffix => 'lectors_workshops', :expires_in => configus.cache.expires_in) do
- workshops.each do |workshop|
= item :li, workshop, lectors_path(lectures_workshop_id_eq: workshop.id)
- workshops.each do |workshop|
= item :li, workshop, lectors_path(lectures_workshop_id_eq: workshop.id)
.span9
- cache(:action_suffix => 'lectors', :expires_in => configus.cache.expires_in) do
- @lectors.each do |lector|
%div{ id: "#{lector.id}" }
.row-fluid
.span4.s-info
.col-l
.pic
- if lector.photo.url
= image_tag(lector.photo.url)
.span8
%h5= lector.full_name
%h6
%strong= lector.company
%p= lector.about
.clearfix
%hr
- @lectors.each do |lector|
%div{ id: "#{lector.id}" }
.row-fluid
.span4.s-info
.col-l
.pic
- if lector.photo.url
= image_tag(lector.photo.url)
.span8
%h5= lector.full_name
%h6
%strong= lector.company
%p= lector.about
.clearfix
%hr
52 changes: 25 additions & 27 deletions app/views/web/lectures/index.html.haml
Original file line number Diff line number Diff line change
Expand Up @@ -3,33 +3,31 @@
.row.workshop
.span3
%ul.nav.nav-list.b-affix
- cache(:action_suffix => 'lectures_workshops', :expires_in => configus.cache.expires_in) do
- workshops.each do |workshop|
= item :li, workshop, lectures_path(workshop_id_eq: workshop.id)
- workshops.each do |workshop|
= item :li, workshop, lectures_path(workshop_id_eq: workshop.id)

.span9
- cache(:action_suffix => 'lectures', :expires_in => configus.cache.expires_in) do
- @lectures.each do |lecture|
.row-fluid.event-item
.span4.sinfo
.col-l
%h5= link_to lecture.user.reverse_full_name, lectors_path(anchor: lecture.user)
%h6
%strong= lecture.user.company
.pic
- if lecture.user.photo.url
= image_tag(lecture.user.photo.url)
.buttons-group{ data: { success: t('.already_going') } }
- if signed_in?
- if lecture.listener_votings.voted_by?(current_user)
.btn.btn-no-clickable= t('.already_going')
- else
= link_to t('.i_am_going'), api_lecture_listener_votings_path(lecture), remote: true, method: :post, class: 'vote-event btn btn-shine'
- @lectures.each do |lecture|
.row-fluid.event-item
.span4.sinfo
.col-l
%h5= link_to lecture.user.reverse_full_name, lectors_path(anchor: lecture.user)
%h6
%strong= lecture.user.company
.pic
- if lecture.user.photo.url
= image_tag(lecture.user.photo.url)
.buttons-group{ data: { success: t('.already_going') } }
- if signed_in?
- if lecture.listener_votings.voted_by?(current_user)
.btn.btn-no-clickable= t('.already_going')
- else
.btn.btn-no-clickable= t('.they_going')
%span.btn.votings-count.btn-no-clickable
= lecture.listener_votings.size
.span8
%h4= lecture.title
%p.ainfo= nl2br lecture.thesises
.clearfix
= link_to t('.i_am_going'), api_lecture_listener_votings_path(lecture), remote: true, method: :post, class: 'vote-event btn btn-shine'
- else
.btn.btn-no-clickable= t('.they_going')
%span.btn.votings-count.btn-no-clickable
= lecture.listener_votings.size
.span8
%h4= lecture.title
%p.ainfo= nl2br lecture.thesises
.clearfix
54 changes: 26 additions & 28 deletions app/views/web/user_lectures/index.html.haml
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,8 @@
.row.workshop
.span3
%ul.nav.nav-list.b-affix
- cache(:action_suffix => 'user_lectures_workshops', :expires_in => configus.cache.expires_in) do
- workshops.each do |workshop|
= item :li, workshop, user_lectures_path(s: params[:s], workshop_id_eq: workshop.id)
- workshops.each do |workshop|
= item :li, workshop, user_lectures_path(s: params[:s], workshop_id_eq: workshop.id)

.span9
- if @lectures.empty?
Expand All @@ -25,28 +24,27 @@
.clearfix
.row

- cache(:action_suffix => 'user_lectures', :expires_in => configus.cache.expires_in) do
- @lectures.each do |lecture|
.row-fluid.event-item
.span4.sinfo
.col-l
%h5= lecture.user.full_name
%h6
%strong= lecture.user.company
.pic
- if lecture.user.photo.url
= image_tag(lecture.user.photo.url)
.buttons-group{ data: { success: t('.already_voted') } }
-if signed_in?
- if lecture.lecture_votings.voted_by?(current_user)
.btn.btn-no-clickable= t('.already_voted')
- else
= link_to t('.vote_this_lecture'), api_lecture_lecture_votings_path(lecture), remote: true, method: :post, class: 'vote-event btn btn-shine'
-else
.btn.btn-no-clickable= t('.they_voted')
%span.btn.votings-count.btn-no-clickable
= lecture.lecture_votings.size
.span8
%h4= lecture.title
%P.ainfo= nl2br lecture.thesises
.clearfix
- @lectures.each do |lecture|
.row-fluid.event-item
.span4.sinfo
.col-l
%h5= lecture.user.full_name
%h6
%strong= lecture.user.company
.pic
- if lecture.user.photo.url
= image_tag(lecture.user.photo.url)
.buttons-group{ data: { success: t('.already_voted') } }
-if signed_in?
- if lecture.lecture_votings.voted_by?(current_user)
.btn.btn-no-clickable= t('.already_voted')
- else
= link_to t('.vote_this_lecture'), api_lecture_lecture_votings_path(lecture), remote: true, method: :post, class: 'vote-event btn btn-shine'
-else
.btn.btn-no-clickable= t('.they_voted')
%span.btn.votings-count.btn-no-clickable
= lecture.lecture_votings.size
.span8
%h4= lecture.title
%P.ainfo= nl2br lecture.thesises
.clearfix

0 comments on commit f6b7f5b

Please sign in to comment.