Created
April 26, 2015 15:12
-
-
Save oleglukashev/12561465c1d425f46e94 to your computer and use it in GitHub Desktop.
Пример верстки. Блоки небольшие т.к. разбиваются все на мелкие логические подблоки
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
.tour-organizator | |
.tour-organizator__avatar | |
= image_tag @tour.guide.avatar.thumb | |
.tour-organizator__agent-name= @tour.guide.name | |
.tour-organizator__post Организатор экскурсии | |
= render partial: 'tour_question' | |
.tour-organizator__question{ class: ("auth-reg-link" unless current_user) } | |
= link_to "Задать вопрос", current_user ? "#" : "#auth-reg-popup", class: "btn white" | |
.tour-organizator__border | |
= render partial: 'tour_brone' | |
.tour-organizator__price | |
%p Стоимость экскурсии | |
.tour-organizator__price-items | |
- if @tour.active_price_type == "personal" | |
.tour-organizator__price-item | |
.tour-organizator__price-item__value | |
= pretty_price @tour.min_price.to_s | |
.tour-organizator__price-item__type | |
за человека | |
- elsif @tour.active_price_type == "group" | |
- @tour.group_price.group_price_details.each do |price_detail| | |
.tour-organizator__price-item | |
.tour-organizator__price-item__value | |
= pretty_price price_detail.group_price | |
.tour-organizator__price-item__type | |
= "за группу от #{price_detail.group_min_size} до #{price_detail.group_max_size} человек" | |
- elsif @tour.active_price_type == "dynamic" | |
- dynamic_price = @tour.dynamic_price.dynamic_price_detail | |
.tour-organizator__price-item | |
.tour-organizator__price-item__value | |
= pretty_price dynamic_price.group_price | |
.tour-organizator__price-item__type | |
= "за группу от #{dynamic_price.group_min_size} до #{dynamic_price.group_max_size} человек" | |
.tour-organizator__price-item | |
.tour-organizator__price-item__value | |
= pretty_price dynamic_price.personal_price | |
.tour-organizator__price-item__type | |
за каждого дополнительного участника | |
.tour-organizator__book{ class: ("auth-reg-link" unless current_user) } | |
= link_to "Забронировать экскурсию", current_user ? "#" : "#auth-reg-popup", class: "btn green" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment