From ccf1ea198cf3be8ccbc07dd71a74255d58deb525 Mon Sep 17 00:00:00 2001 From: Artur Beljajev Date: Fri, 15 Jun 2018 08:42:32 +0300 Subject: [PATCH 1/4] Do not send `TotalVAT` and `VATCode` params to Directo Partly reverts 169c67839e37a77e6a8dc584f31ab54e6bd46647 --- app/models/directo.rb | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/app/models/directo.rb b/app/models/directo.rb index 3e4e93e2c..1269e7033 100644 --- a/app/models/directo.rb +++ b/app/models/directo.rb @@ -29,14 +29,12 @@ class Directo < ActiveRecord::Base "InvoiceDate" => invoice.created_at.strftime("%Y-%m-%dT%H:%M:%S"), "PaymentTerm" => Setting.directo_receipt_payment_term, "Currency" => invoice.currency, - "CustomerCode"=> invoice.buyer.accounting_customer_code, - 'TotalVAT' => ActionController::Base.helpers.number_with_precision(invoice.vat_amount, precision: 2, separator: '.') + "CustomerCode"=> invoice.buyer.accounting_customer_code ){ xml.line( "ProductID" => Setting.directo_receipt_product_name, "Quantity" => 1, - "UnitPriceWoVAT" => ActionController::Base.helpers.number_with_precision(invoice.subtotal, precision: 2, separator: '.'), - 'VATCode' => invoice.buyer_vat_no, + "UnitPriceWoVAT" => ActionController::Base.helpers.number_with_precision(invoice.subtotal, precision: 2, separator: "."), "ProductName" => invoice.order ) } From 843dc8edcbaabae87dd040f6715352ca3ee92f21 Mon Sep 17 00:00:00 2001 From: Maciej Szlosarczyk Date: Mon, 18 Jun 2018 10:30:23 +0300 Subject: [PATCH 2/4] Add new links to registrant page layout --- app/controllers/registrant/whois_controller.rb | 11 ----------- .../layouts/registrant/application.html.erb | 16 +++++++++------- test/integration/registrant/layout_test.rb | 5 +++-- 3 files changed, 12 insertions(+), 20 deletions(-) delete mode 100644 app/controllers/registrant/whois_controller.rb diff --git a/app/controllers/registrant/whois_controller.rb b/app/controllers/registrant/whois_controller.rb deleted file mode 100644 index 2936477eb..000000000 --- a/app/controllers/registrant/whois_controller.rb +++ /dev/null @@ -1,11 +0,0 @@ -# As non-GDPR compliant, this controller is deprecated. Needs to be replaced with one that relies -# on the REST WHOIS API. -class Registrant::WhoisController < RegistrantController - def index - authorize! :view, :registrant_whois - - if params[:domain_name].present? - @domain = WhoisRecord.find_by(name: params[:domain_name]); - end - end -end diff --git a/app/views/layouts/registrant/application.html.erb b/app/views/layouts/registrant/application.html.erb index f38f8fcea..f8108d0e0 100644 --- a/app/views/layouts/registrant/application.html.erb +++ b/app/views/layouts/registrant/application.html.erb @@ -42,14 +42,16 @@