Sha256: 2fe63287ee5e8f798eddb4ab0e0ab75390970984e9d4ca74d08ec4bb977f1c88
Contents?: true
Size: 1.37 KB
Versions: 1
Compression:
Stored size: 1.37 KB
Contents
- values = @lifetimes.map { |i| i.value }.uniq.sort() - @lifetimes.group_by { |l| l.value }.each do |value, items| - title = discount_lifetime_title(items) - notes = discount_lifetime_notes(items, value) .life_time_item .life_time_description span => raw title p = raw notes .life_time_procent span = t :offer_html, scope: [:account, :discounts, :text], offer: pretty_number(value.to_f) / strong / => "#{value.to_i}%" / | off .life_time_use - if (@active_lifetime || 0) < value.to_f span.button.button_disabled[ tooltip-ster="{contentAsHTML: 'true', theme: 'tooltipster-cabinet'}" title="#{discount_progress_title(finance, lifetimes, value)}" ] = t :use_lifetime, scope: [:account, :discounts, :button] - elsif (@active_lifetime || 0) > value.to_f span.button.button_disabled[ tooltip-ster="{contentAsHTML: 'true', theme: 'tooltipster-cabinet'}" title="Offer already achieved" ] = t :use_lifetime, scope: [:account, :discounts, :button] - else = link_to new_order_path(discount: @customer_lifetime.public_token), class: 'button' = t :use_lifetime, scope: [:account, :discounts, :button] .life_time_code span = t :code, scope: [:account, :discounts, :text] strong = @customer_lifetime.public_token
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
translation_cms-0.1.5 | app/views/account/discounts/_lifetime_items.html.slim |