Delete some more dead overrides. We are not using spree/checkout (except for /checkout/payment) nor spree/products

This commit is contained in:
luisramos0
2019-03-01 23:52:24 +00:00
parent 88e6fa84a2
commit 93e13742be
14 changed files with 0 additions and 148 deletions

View File

@@ -1872,7 +1872,6 @@ Style/HashSyntax:
- 'app/overrides/remove_search_bar.rb'
- 'app/overrides/remove_side_bar.rb'
- 'app/overrides/replace_checkout_payment_button.rb'
- 'app/overrides/replace_order_details_steps_data.rb'
- 'app/overrides/replace_payment_name_with_description.rb'
- 'app/overrides/replace_shipping_address_form_with_distributor_details.rb'
- 'app/overrides/set_auth_token_in_backend.rb'

View File

@@ -1,5 +0,0 @@
Deface::Override.new(:virtual_path => "spree/shared/_order_details",
:replace => "div.row.steps-data",
:partial => "spree/shared/order_details_steps_data",
:name => "replace_order_details_steps_data",
:original => '1a68aa5db3fee7f7bbb2b6b826749aeb69168cee')

View File

@@ -1,5 +0,0 @@
Deface::Override.new(:virtual_path => "spree/payments/_payment",
:replace => "code[erb-loud]:contains('content_tag(:span, payment.payment_method.name)')",
:text => "<%= content_tag( :span, ( payment.payment_method.description || payment.payment_method.name ).html_safe ) %>",
:name => "replace_payment_name_with_description",
:original => 'dff62efcadc0f9e6513b0f81a51ebbda035f78f6')

View File

@@ -1,18 +0,0 @@
.add-to-cart
- order = current_order(false)
- if product_out_of_stock
= content_tag('strong', t(:out_of_stock))
- elsif !distributor_available_for?(order, @product)
= render 'add_to_cart_distributor_unavailable'
- elsif !order_cycle_available_for?(order, @product)
= render 'add_to_cart_order_cycle_unavailable'
- else
= render 'add_to_cart_quantity_fields', product: @product
%br
= button_tag :class => 'large primary', :id => 'add-to-cart-button', :type => :submit do
= t(:add_to_cart)

View File

@@ -1,3 +0,0 @@
.distributor
= t :products_cart_distributor_choice
= select_tag "distributor_id", options_from_collection_for_select([Enterprise.new]+distributor_collection, "id", "name", current_distributor.andand.id)

View File

@@ -1,7 +0,0 @@
= hidden_field_tag "distributor_id", distributor.id
.distributor-fixed
- if changing_distributor
= t :products_cart_distributor_change, name: distributor.name
- else
= t :products_cart_distributor_is, name: distributor.name

View File

@@ -1,2 +0,0 @@
.error-distributor
= t :products_distributor_error, link: link_to(current_distributor.name, root_path)

View File

@@ -1,3 +0,0 @@
%div
= t :products_oc
= select_tag "order_cycle_id", options_from_collection_for_select([OrderCycle.new(name: t(:none))]+order_cycle_collection, "id", "name", current_order_cycle.andand.id)

View File

@@ -1,7 +0,0 @@
= hidden_field_tag "order_cycle_id", order_cycle.id
.order-cycle-fixed
- if changing_order_cycle
= t :products_oc_change, name: order_cycle.name
- else
= t :products_oc_is, name: order_cycle.name

View File

@@ -1,2 +0,0 @@
.error-distributor
= t :products_oc_error, link: = link_to((current_order_cycle.andand.name || t(:products_oc_current)), root_path)

View File

@@ -1,9 +0,0 @@
%div(class = "columns alpha two")
%div
= t :products_quantity
= number_field_tag (product.has_variants? ? :quantity : "variants[#{product.master.id}]"), 1, :class => 'title', :in => 1..product.on_hand
- if product.group_buy
%div(class = "columns alpha three")
%div
= t :products_max_quantity
= number_field_tag (product.has_variants? ? :max_quantity : "variant_attributes[#{product.master.id}][max_quantity]"), 1, :class => 'title max_quantity', :in => 1..product.on_hand

View File

@@ -1,9 +0,0 @@
%fieldset#product-distributor-details.columns.five.omega
%legend
= t :products_distributor
.distributor-details
- order = current_order(false)
- if order.andand.distributor.present?
= render 'enterprises/distributor_details', :distributor => order.distributor
- else
= t :products_distributor_info

View File

@@ -1,29 +0,0 @@
%div{:data-hook => "product_source"}
%h6.product-section-title= t(:supplier)
%table#product-source.table-display{:width => "100%"}
%tbody
- if @product.supplier
%tr.odd
%td= link_to @product.supplier.name, [main_app, @product.supplier]
- if false
%br/
%h6.product-section-title= t(:distributors)
%table#product-source.table-display{:width => "100%"}
%tbody
- order = current_order(false)
- validator = DistributionChangeValidator.new(order)
- Enterprise.distributing_products(@product).each do |distributor|
- if !order.nil? && distributor == order.distributor
%tr.odd
%td
%b= link_to(distributor.name, [main_app, distributor])
%td
%b= t(:current)
- elsif order.nil? || validator.can_change_to_distributor?(distributor)
%tr.even
%td= link_to distributor.name, [main_app, distributor]
%td= t(:available)
- else
%tr.even
%td= link_to distributor.name, [main_app, distributor]
%td

View File

@@ -1,48 +0,0 @@
<div class="row steps-data">
<% if order.has_step?("address") %>
<div class="columns alpha six">
<h6><%= "Customer Details" %> <%= link_to "(#{t(:edit)})", checkout_state_path(:address) unless @order.completed? %></h6>
<div class="address">
<%= "#{t(:name)}: #{order.bill_address.full_name}" %><br />
<%= "#{t(:address)}: #{order.bill_address.address1}, #{order.bill_address.city}" %>
</div>
<br/>
<div class="row steps-data">
<% order.payments.each do |payment| %>
<div <% if payment.payment_method.name.include? "EFT" %>id="eft-payment-alert"<% end %>>
<h6><%= t(:payment_information) %> <%= link_to "(#{t(:edit)})", checkout_state_path(:payment) unless @order.completed? %></h6>
<div class="payment-info">
<% if payment.payment_method.name.include? "PayPal" %>
<div class="flash notice"><% t(:order_payment_paypal_successful) %></div>
<% elsif payment.payment_method.name.include? "EFT" %>
<span><%= payment.payment_method.description.html_safe %></span>
<% elsif order.credit_cards.empty? == false %>
<span class="cc-type">
<%= image_tag "credit_cards/icons/#{order.credit_cards.first.cc_type}.png" %>
<%= t(:ending_in)%> <%= order.credit_cards.first.last_digits %>
</span>
<br />
<span class="full-name">
<%= order.credit_cards.first.first_name %>
<%= order.credit_cards.first.last_name %>
</span>
<% elsif payment.payment_method.type == "Spree::PaymentMethod::Check" %>
<span><%= payment.payment_method.description %></span>
<% end %>
</div>
</div>
<% end %>
</div>
</div>
<div class="columns alpha six">
<h6><% t(:order_hub_info) %></h6>
<div class="address">
<%= render 'enterprises/distributor_details', :distributor => order.distributor %>
</div>
</div>
<% end %>
</div>