Sha256: 0f5d6124f761c37f8486d36da1ee585c8787d84e2c8756db12d7bc1cabe91d2e

Contents?: true

Size: 1.22 KB

Versions: 20

Compression:

Stored size: 1.22 KB

Contents

.card
  .card-body
    %h2 Admin: Purchase Delayed Order

    - raise('unexpected purchased order') if order.purchased?
    - raise('expected a deferred delayed order') unless order.delayed? && order.deferred?
    - raise('expecting a payment intent') unless order.delayed_payment_intent.present?
    - raise('expecting a payment method') unless order.delayed_payment_method.present?

    %p 
      = succeed('.') do
        - distance = distance_of_time_in_words(Time.zone.now, order.delayed_payment_date)

        The payment date for this order

        - if order.delayed_payment_date_upcoming?
          is in #{distance} from now on #{order.delayed_payment_date.strftime('%F')}
        - elsif order.delayed_payment_date_today?
          was today
        - else
          was #{distance} ago on #{order.delayed_payment_date.strftime('%F')}

    %p The #{order.delayed_payment_method} on file will be charged automatically on the payment date.

    %p You can also charge it right now.

    - provider_locals = { order: order, purchased_url: purchased_url, declined_url: declined_url }

    - EffectiveOrders.delayed_providers.each do |provider|
      = render partial: "/effective/orders/#{provider}/form_purchase", locals: provider_locals

Version data entries

20 entries across 20 versions & 1 rubygems

Version Path
effective_orders-6.17.1 app/views/effective/orders/delayed/_form_purchase.html.haml
effective_orders-6.17.0 app/views/effective/orders/delayed/_form_purchase.html.haml
effective_orders-6.16.4 app/views/effective/orders/delayed/_form_purchase.html.haml
effective_orders-6.16.3 app/views/effective/orders/delayed/_form_purchase.html.haml
effective_orders-6.16.2 app/views/effective/orders/delayed/_form_purchase.html.haml
effective_orders-6.16.1 app/views/effective/orders/delayed/_form_purchase.html.haml
effective_orders-6.16.0 app/views/effective/orders/delayed/_form_purchase.html.haml
effective_orders-6.15.0 app/views/effective/orders/delayed/_form_purchase.html.haml
effective_orders-6.14.6 app/views/effective/orders/delayed/_form_purchase.html.haml
effective_orders-6.14.5 app/views/effective/orders/delayed/_form_purchase.html.haml
effective_orders-6.14.4 app/views/effective/orders/delayed/_form_purchase.html.haml
effective_orders-6.14.3 app/views/effective/orders/delayed/_form_purchase.html.haml
effective_orders-6.14.2 app/views/effective/orders/delayed/_form_purchase.html.haml
effective_orders-6.14.1 app/views/effective/orders/delayed/_form_purchase.html.haml
effective_orders-6.14.0 app/views/effective/orders/delayed/_form_purchase.html.haml
effective_orders-6.13.3 app/views/effective/orders/delayed/_form_purchase.html.haml
effective_orders-6.13.2 app/views/effective/orders/delayed/_form_purchase.html.haml
effective_orders-6.13.1 app/views/effective/orders/delayed/_form_purchase.html.haml
effective_orders-6.13.0 app/views/effective/orders/delayed/_form_purchase.html.haml
effective_orders-6.12.4 app/views/effective/orders/delayed/_form_purchase.html.haml