summaryrefslogtreecommitdiff
path: root/billing/app/views/subscriptions
diff options
context:
space:
mode:
authorAzul <azul@leap.se>2014-04-11 10:03:19 +0200
committerAzul <azul@leap.se>2014-04-11 10:07:23 +0200
commit636692f9921bd695d726695d2d46c91f5a6e56f3 (patch)
treea7cc0b89007bd273ae7719f31c16e052a141fec7 /billing/app/views/subscriptions
parent32136605ddd405a0bf47f3b795b22fd4b49465b5 (diff)
move engines into engines directory
Also renamed help to support so it's harder to confuse it with documentation
Diffstat (limited to 'billing/app/views/subscriptions')
-rw-r--r--billing/app/views/subscriptions/_subscription_details.html.haml26
-rw-r--r--billing/app/views/subscriptions/create.html.haml9
-rw-r--r--billing/app/views/subscriptions/destroy.html.haml7
-rw-r--r--billing/app/views/subscriptions/index.html.haml8
-rw-r--r--billing/app/views/subscriptions/new.html.haml15
-rw-r--r--billing/app/views/subscriptions/show.html.haml6
6 files changed, 0 insertions, 71 deletions
diff --git a/billing/app/views/subscriptions/_subscription_details.html.haml b/billing/app/views/subscriptions/_subscription_details.html.haml
deleted file mode 100644
index 6145c95..0000000
--- a/billing/app/views/subscriptions/_subscription_details.html.haml
+++ /dev/null
@@ -1,26 +0,0 @@
-%p
- - if local_assigns[:show_user]
- User:
- - user_to_show = user_for_subscription(subscription)
- = link_to user_to_show.login, user_overview_path(user_to_show)
- ID:
- = link_to subscription.id, user_subscription_path(@user, subscription.id)
- Balance:
- - color = (subscription.balance > 0) ? "red" : ""
- %font{:color => color}
- = number_to_currency(subscription.balance)
- Bill on:
- = subscription.billing_day_of_month
- Start date:
- = subscription.first_billing_date
- Paid through:
- = subscription.paid_through_date
- Plan:
- = subscription.plan_id
- Price:
- = number_to_currency(subscription.price)
- - color = (subscription.status == 'Active') ? "green" : "red"
- Status:
- %font{:color => color}
- = subscription.status
- - # would be good to get plan name but not sure if that is possible? \ No newline at end of file
diff --git a/billing/app/views/subscriptions/create.html.haml b/billing/app/views/subscriptions/create.html.haml
deleted file mode 100644
index 2b6c5e9..0000000
--- a/billing/app/views/subscriptions/create.html.haml
+++ /dev/null
@@ -1,9 +0,0 @@
-- if @result.success?
- %h1
- Subscription Status
- = @result.subscription.status
- = render :partial => "subscription_details", :locals => {:subscription => @result.subscription}
-- else
- %h1
- Error:
- = @result.message \ No newline at end of file
diff --git a/billing/app/views/subscriptions/destroy.html.haml b/billing/app/views/subscriptions/destroy.html.haml
deleted file mode 100644
index 44b4333..0000000
--- a/billing/app/views/subscriptions/destroy.html.haml
+++ /dev/null
@@ -1,7 +0,0 @@
-- if @result.success?
- Subscription destroyed
-- else
- Error:
- = @result.message
-%p
- = link_to 'Customer Information', show_customer_path(@user), :class=> :btn \ No newline at end of file
diff --git a/billing/app/views/subscriptions/index.html.haml b/billing/app/views/subscriptions/index.html.haml
deleted file mode 100644
index 3d4e8fd..0000000
--- a/billing/app/views/subscriptions/index.html.haml
+++ /dev/null
@@ -1,8 +0,0 @@
-%h2=t :all_subscriptions
-- pending_active_pastdue = false
-- @subscriptions.each do |s|
- - if ['Pending', 'Active','Past Due'].include? s.status
- - pending_active_pastdue = true
- = render :partial => "subscription_details", :locals => {:subscription => s}
-- if !pending_active_pastdue and @user == current_user
- = link_to 'subscribe to plan', new_subscription_path, :class => :btn \ No newline at end of file
diff --git a/billing/app/views/subscriptions/new.html.haml b/billing/app/views/subscriptions/new.html.haml
deleted file mode 100644
index 4183458..0000000
--- a/billing/app/views/subscriptions/new.html.haml
+++ /dev/null
@@ -1,15 +0,0 @@
-- if @payment_method_token
- %h1
- Subscribe to plan
- = #currently just one plan
- = @plans[0].name
- = number_to_currency(@plans[0].price)
- = simple_form_for :subscription, :url => :subscriptions do |f|
- = hidden_field_tag :payment_method_token, @payment_method_token
- = hidden_field_tag :plan_id, @plans[0].id
- .form-actions
- = f.submit t(:subscribe), :class => 'btn btn-primary'
-- else
- = t(:must_create_customer)
- %p
- = link_to t(:create_new_customer), new_customer_path
diff --git a/billing/app/views/subscriptions/show.html.haml b/billing/app/views/subscriptions/show.html.haml
deleted file mode 100644
index 2699db9..0000000
--- a/billing/app/views/subscriptions/show.html.haml
+++ /dev/null
@@ -1,6 +0,0 @@
-%h1
- - if @subscription.status == 'Active'
- Current
- Subscription
-= render :partial => "subscription_details", :locals => {:subscription => @subscription}
-= link_to t(:cancel_subscription), user_subscription_path(@user, @subscription.id), :confirm => t(:are_you_sure), :method => :delete, :class => 'btn btn-danger' if allow_cancel_subscription(@subscription)