diff --git a/app/controllers/registrar/account_activities_controller.rb b/app/controllers/registrar/account_activities_controller.rb
deleted file mode 100644
index 0ad8c3d5a..000000000
--- a/app/controllers/registrar/account_activities_controller.rb
+++ /dev/null
@@ -1,31 +0,0 @@
-class Registrar
- class AccountActivitiesController < BaseController
- load_and_authorize_resource
-
- def index
- params[:q] ||= {}
- account = current_registrar_user.registrar.cash_account
-
- ca_cache = params[:q][:created_at_lteq]
- begin
- end_time = params[:q][:created_at_lteq].try(:to_date)
- params[:q][:created_at_lteq] = end_time.try(:end_of_day)
- rescue
- logger.warn('Invalid date')
- end
-
- @q = account.activities.includes(:invoice).ransack(params[:q])
- @q.sorts = 'id desc' if @q.sorts.empty?
-
- respond_to do |format|
- format.html { @account_activities = @q.result.page(params[:page]) }
- format.csv do
- raw_csv = CsvGenerator.generate_csv(@q.result)
- send_data raw_csv, filename: "account_activities_#{Time.zone.now.to_formatted_s(:number)}.csv"
- end
- end
-
- params[:q][:created_at_lteq] = ca_cache
- end
- end
-end
diff --git a/app/controllers/registrar/account_controller.rb b/app/controllers/registrar/account_controller.rb
deleted file mode 100644
index a7d135659..000000000
--- a/app/controllers/registrar/account_controller.rb
+++ /dev/null
@@ -1,34 +0,0 @@
-class Registrar
- class AccountController < BaseController
- skip_authorization_check
- helper_method :iban_max_length
- helper_method :balance_auto_reload_setting
-
- def show; end
-
- def edit
- @registrar = current_registrar_user.registrar
- end
-
- def update
- @registrar = current_registrar_user.registrar
- @registrar.update!(registrar_params)
-
- redirect_to registrar_account_path, notice: t('.saved')
- end
-
- private
-
- def registrar_params
- params.require(:registrar).permit(:billing_email, :iban)
- end
-
- def iban_max_length
- Iban.max_length
- end
-
- def balance_auto_reload_setting
- current_registrar_user.registrar.settings['balance_auto_reload']
- end
- end
-end
diff --git a/app/controllers/registrar/admin_contacts_controller.rb b/app/controllers/registrar/admin_contacts_controller.rb
deleted file mode 100644
index 378f490a9..000000000
--- a/app/controllers/registrar/admin_contacts_controller.rb
+++ /dev/null
@@ -1,21 +0,0 @@
-class Registrar
- class AdminContactsController < BulkChangeController
- BASE_URL = URI.parse("#{ENV['repp_url']}domains/admin_contacts").freeze
- ACTIVE_TAB = :admin_contact
-
- def update
- authorize! :manage, :repp
- uri = BASE_URL
- request = form_request(uri)
-
- action = Actions::DoRequest.new(request, uri)
- response = action.call
-
- start_notice = t('.replaced')
-
- process_response(response: response,
- start_notice: start_notice,
- active_tab: ACTIVE_TAB)
- end
- end
-end
diff --git a/app/controllers/registrar/base_controller.rb b/app/controllers/registrar/base_controller.rb
deleted file mode 100644
index 2aad861b8..000000000
--- a/app/controllers/registrar/base_controller.rb
+++ /dev/null
@@ -1,43 +0,0 @@
-class Registrar
- class BaseController < ApplicationController
- include Registrar::ApplicationHelper
-
- before_action :authenticate_registrar_user!
- before_action :check_ip_restriction
- helper_method :depp_controller?
- helper_method :head_title_sufix
- before_action :set_paper_trail_whodunnit
-
- protected
-
- def current_ability
- @current_ability ||= Ability.new(current_registrar_user, request.remote_ip)
- end
-
- private
-
- def check_ip_restriction
- ip_restriction = Authorization::RestrictedIp.new(request.ip)
- allowed = ip_restriction.can_access_registrar_area?(current_registrar_user.registrar)
-
- return if allowed
-
- sign_out current_registrar_user
-
- flash[:alert] = t('registrar.authorization.ip_not_allowed', ip: request.ip)
- redirect_to new_registrar_user_session_url
- end
-
- def depp_controller?
- false
- end
-
- def head_title_sufix
- t(:registrar_head_title_sufix)
- end
-
- def user_for_paper_trail
- current_registrar_user ? current_registrar_user.id_role_username : 'anonymous'
- end
- end
-end
diff --git a/app/controllers/registrar/bulk_change_controller.rb b/app/controllers/registrar/bulk_change_controller.rb
deleted file mode 100644
index 9cd00e6cc..000000000
--- a/app/controllers/registrar/bulk_change_controller.rb
+++ /dev/null
@@ -1,105 +0,0 @@
-class Registrar
- class BulkChangeController < DeppController
- helper_method :available_contacts
-
- def new
- authorize! :manage, :repp
- @expire_date = Time.zone.now.to_date
- render 'registrar/bulk_change/new', locals: { active_tab: default_tab }
- end
-
- def bulk_renew
- authorize! :manage, :repp
- set_form_data
-
- if ready_to_renew?
- res = ReppApi.bulk_renew(domain_ids_for_bulk_renew, params[:period],
- current_registrar_user)
-
- flash_message(JSON.parse(res))
- else
- flash[:notice] = nil
- end
-
- render 'registrar/bulk_change/new', locals: { active_tab: :bulk_renew }
- end
-
- private
-
- def form_request(uri)
- request = Net::HTTP::Patch.new(uri)
- request.set_form_data(current_contact_id: params[:current_contact_id],
- new_contact_id: params[:new_contact_id])
- request.basic_auth(current_registrar_user.username,
- current_registrar_user.plain_text_password)
- request
- end
-
- def process_response(response:, start_notice: '', active_tab:)
- parsed_response = JSON.parse(response.body, symbolize_names: true)
-
- if response.code == '200'
- notices = success_notices(parsed_response, start_notice)
-
- flash[:notice] = notices.join(', ')
- redirect_to registrar_domains_url
- else
- @error = response.code == '404' ? 'Contact(s) not found' : parsed_response[:message]
- render 'registrar/bulk_change/new', locals: { active_tab: active_tab }
- end
- end
-
- def success_notices(parsed_response, start_notice)
- notices = [start_notice]
-
- notices << "#{t('.affected_domains')}: " \
- "#{parsed_response[:data][:affected_domains].join(', ')}"
-
- if parsed_response[:data][:skipped_domains]
- notices << "#{t('.skipped_domains')}: " \
- "#{parsed_response[:data][:skipped_domains].join(', ')}"
- end
- notices
- end
-
- def ready_to_renew?
- domain_ids_for_bulk_renew.present? && params[:renew].present?
- end
-
- def set_form_data
- @expire_date = params[:expire_date].to_date
- @domains = domains_by_date(@expire_date)
- @period = params[:period]
- end
-
- def available_contacts
- current_registrar_user.registrar.contacts.order(:name).pluck(:name, :code)
- end
-
- def default_tab
- :technical_contact
- end
-
- def domains_scope
- current_registrar_user.registrar.domains
- end
-
- def domains_by_date(date)
- domains_scope.where('valid_to <= ?', date)
- end
-
- def domain_ids_for_bulk_renew
- params['domain_ids']&.reject { |id| id.blank? }
- end
-
- def renew_task(domains)
- Domains::BulkRenew::Start.run(domains: domains,
- period_element: @period,
- registrar: current_registrar_user.registrar)
- end
-
- def flash_message(res)
- flash[:notice] = res['code'] == 1000 ? t(:bulk_renew_completed) : res['message']
- end
- end
-end
diff --git a/app/controllers/registrar/contacts_controller.rb b/app/controllers/registrar/contacts_controller.rb
deleted file mode 100644
index 812e278e5..000000000
--- a/app/controllers/registrar/contacts_controller.rb
+++ /dev/null
@@ -1,163 +0,0 @@
-class Registrar
- class ContactsController < DeppController
- before_action :init_epp_contact
- helper_method :address_processing?
- helper_method :ident_types
- helper_method :domain_filter_params
-
- def index
- authorize! :view, Depp::Contact
-
- params[:q] ||= {}
- params[:q].delete_if { |_k, v| v.blank? }
-
- search_params = params[:q].deep_dup
-
- if search_params[:domain_contacts_type_in].is_a?(Array) &&
- search_params[:domain_contacts_type_in].delete('registrant')
- search_params[:registrant_domains_id_not_null] = 1
- end
-
- contacts = current_registrar_user.registrar.contacts.includes(:registrar)
- status_list = params[:statuses_contains]
-
- if status_list
- contacts_ids = contacts.select { |c| (c.statuses & status_list.to_a) == status_list.to_a }
- .map(&:id)
- contacts = contacts.where(id: contacts_ids)
- end
-
- normalize_search_parameters do
- @q = contacts.ransack(search_params)
- end
-
- contacts = @q.result
-
- respond_to do |format|
- format.html do
- contacts_per_page = params[:results_per_page].to_i
- @contacts = contacts.page(params[:page])
- @contacts = @contacts.per(contacts_per_page) if contacts_per_page.positive?
- end
- format.csv do
- raw_csv = CsvGenerator.generate_csv(contacts)
- send_data raw_csv, filename: 'contacts.csv', type: "#{Mime[:csv]}; charset=utf-8"
- end
- format.pdf do
- raw_html = ApplicationController.render(
- template: 'registrar/contacts/list_pdf',
- assigns: { contacts: contacts },
- formats: [:html]
- )
- raw_pdf = contacts.pdf(raw_html)
-
- send_data raw_pdf, filename: 'contacts.pdf'
- end
- end
- end
-
- def new
- authorize! :create, Depp::Contact
- @contact = Depp::Contact.new
- end
-
- def show
- authorize! :view, Depp::Contact
- @contact = Depp::Contact.find_by_id(params[:id])
- end
-
- def edit
- authorize! :edit, Depp::Contact
- @contact = Depp::Contact.find_by_id(params[:id])
- end
-
- def create
- authorize! :create, Depp::Contact
- @contact = Depp::Contact.new(contact_params)
-
- if @contact.save
- redirect_to registrar_contact_url(@contact.id)
- else
- render 'new'
- end
- end
-
- def update
- authorize! :edit, Depp::Contact
- @contact = Depp::Contact.new(contact_params)
-
- if @contact.update_attributes(contact_params)
- redirect_to registrar_contact_url(@contact.id)
- else
- render 'edit'
- end
- end
-
- def delete
- authorize! :delete, Depp::Contact
- @contact = Depp::Contact.find_by_id(params[:id])
- end
-
- def destroy
- authorize! :delete, Depp::Contact
- @contact = Depp::Contact.new(contact_params_for_delete)
-
- if @contact.delete
- redirect_to registrar_contacts_url, notice: t(:destroyed)
- else
- render 'delete'
- end
- end
-
- protected
-
- def domain_filter_params
- params.permit(:domain_filter)
- end
-
- private
-
- def init_epp_contact
- Depp::Contact.user = depp_current_user
- end
-
- def normalize_search_parameters
- ca_cache = params[:q][:valid_to_lteq]
- begin
- end_time = params[:q][:valid_to_lteq].try(:to_date)
- params[:q][:valid_to_lteq] = end_time.try(:end_of_day)
- rescue
- logger.warn('Invalid date')
- end
-
- yield
-
- params[:q][:valid_to_lteq] = ca_cache
- end
-
- def address_processing?
- Contact.address_processing?
- end
-
- def ident_types
- Contact::Ident.types
- end
-
- def contact_params
- params.require(:depp_contact).permit(:id,
- :name,
- :email,
- :phone,
- :org_name,
- :ident, :ident_type, :ident_country_code,
- :street, :city, :zip, :state, :country_code,
- :password,
- :legal_document,
- :code)
- end
-
- def contact_params_for_delete
- params.require(:depp_contact).permit(:id, :password, :legal_document)
- end
- end
-end
diff --git a/app/controllers/registrar/current_user_controller.rb b/app/controllers/registrar/current_user_controller.rb
deleted file mode 100644
index 3a214322c..000000000
--- a/app/controllers/registrar/current_user_controller.rb
+++ /dev/null
@@ -1,18 +0,0 @@
-class Registrar
- class CurrentUserController < BaseController
- skip_authorization_check
-
- def switch
- raise 'Cannot switch to unlinked user' unless current_registrar_user.linked_with?(new_user)
-
- sign_in(:registrar_user, new_user)
- redirect_back(fallback_location: root_path, notice: t('.switched', new_user: new_user))
- end
-
- private
-
- def new_user
- @new_user ||= ApiUser.find(params[:new_user_id])
- end
- end
-end
diff --git a/app/controllers/registrar/deposits_controller.rb b/app/controllers/registrar/deposits_controller.rb
deleted file mode 100644
index 0dcaf6830..000000000
--- a/app/controllers/registrar/deposits_controller.rb
+++ /dev/null
@@ -1,28 +0,0 @@
-class Registrar
- class DepositsController < BaseController
- authorize_resource class: false
-
- def new
- @deposit = Deposit.new
- end
-
- def create
- @deposit = Deposit.new(deposit_params.merge(registrar: current_registrar_user.registrar))
- @invoice = @deposit.issue_prepayment_invoice
-
- if @invoice
- flash[:notice] = t(:please_pay_the_following_invoice)
- redirect_to [:registrar, @invoice]
- else
- flash[:alert] = @deposit.errors.full_messages.join(', ')
- redirect_to new_registrar_deposit_path
- end
- end
-
- private
-
- def deposit_params
- params.require(:deposit).permit(:amount, :description)
- end
- end
-end
diff --git a/app/controllers/registrar/depp_controller.rb b/app/controllers/registrar/depp_controller.rb
deleted file mode 100644
index 70fb01c4a..000000000
--- a/app/controllers/registrar/depp_controller.rb
+++ /dev/null
@@ -1,37 +0,0 @@
-class Registrar
- class DeppController < BaseController
- helper_method :depp_current_user
-
- rescue_from(Errno::ECONNRESET, Errno::ECONNREFUSED) do |exception|
- logger.error 'COULD NOT CONNECT TO REGISTRY'
- logger.error exception.backtrace.join("\n")
- redirect_to new_registrar_user_session_url, alert: t(:no_connection_to_registry)
- end
-
- before_action :authenticate_user
-
- def authenticate_user
- redirect_to new_registrar_user_session_url and return unless depp_current_user
- end
-
- def depp_controller?
- true
- end
-
- def depp_current_user
- return nil unless current_registrar_user
- @depp_current_user ||= Depp::User.new(
- tag: current_registrar_user.username,
- password: current_registrar_user.plain_text_password
- )
- end
-
- def response_ok?
- @data.css('result').each do |x|
- success_codes = %(1000, 1001, 1300, 1301)
- return false unless success_codes.include?(x['code'])
- end
- true
- end
- end
-end
diff --git a/app/controllers/registrar/domain_transfers_controller.rb b/app/controllers/registrar/domain_transfers_controller.rb
deleted file mode 100644
index 57e06d010..000000000
--- a/app/controllers/registrar/domain_transfers_controller.rb
+++ /dev/null
@@ -1,49 +0,0 @@
-class Registrar
- class DomainTransfersController < BulkChangeController
- before_action do
- authorize! :transfer, Depp::Domain
- end
-
- def new
- end
-
- def create
- if params[:batch_file].present?
- csv = CSV.read(params[:batch_file].path, headers: true)
- domain_transfers = []
-
- csv.each do |row|
- domain_name = row['Domain']
- transfer_code = row['Transfer code']
- domain_transfers << { 'domain_name' => domain_name, 'transfer_code' => transfer_code }
- end
-
- uri = URI.parse("#{ENV['repp_url']}domains/transfer")
- request = Net::HTTP::Post.new(uri, 'Content-Type' => 'application/json')
- request.body = { data: { domain_transfers: domain_transfers } }.to_json
- request.basic_auth(current_registrar_user.username,
- current_registrar_user.plain_text_password)
-
- action = Actions::DoRequest.new(request, uri)
- response = action.call
-
- parsed_response = JSON.parse(response.body, symbolize_names: true)
-
- if response.code == '200'
- failed = parsed_response[:data][:failed].pluck(:domain_name).join(', ')
- flash[:notice] = t('.transferred', count: parsed_response[:data][:success].size,
- failed: failed)
- redirect_to registrar_domains_url
- else
- @api_errors = parsed_response[:message]
- render 'registrar/bulk_change/new', locals: { active_tab: :bulk_transfer }
- end
- else
- params[:request] = true # EPP domain:transfer "op" attribute
- domain = Depp::Domain.new(current_user: depp_current_user)
- @data = domain.transfer(params)
- render :new unless response_ok?
- end
- end
- end
-end
diff --git a/app/controllers/registrar/domains_controller.rb b/app/controllers/registrar/domains_controller.rb
deleted file mode 100644
index 3347f5d38..000000000
--- a/app/controllers/registrar/domains_controller.rb
+++ /dev/null
@@ -1,229 +0,0 @@
-class Registrar
- class DomainsController < DeppController
- before_action :init_domain, except: :new
- helper_method :contacts
- helper_method :search_params
-
- def index
- authorize! :view, Depp::Domain
-
- if search_params.to_h.delete_if { |_key, value| value.blank? }.length == 1 &&
- search_params[:name_matches].present?
- domain = Domain.find_by(name: search_params[:name_matches])
-
- redirect_to info_registrar_domains_url(domain_name: domain.name) and return if domain
- end
-
- domains = if params[:statuses_contains]
- current_domain_scope.where('domains.statuses @> ?::varchar[]',
- "{#{params[:statuses_contains].join(',')}}")
- else
- current_domain_scope
- end
-
- domains = domains.where(contacts: { ident: params[:contacts_ident_eq] }) if params[:contacts_ident_eq]
-
- normalize_search_parameters do
- @q = domains.ransack(search_params.except(:contacts_ident_eq))
- @domains = @q.result.page(params[:page])
-
- # if we do not get any results, add wildcards to the name field and search again
- if @domains.count == 0 && search_params[:name_matches] !~ /^%.+%$/
- new_search_params = search_params.to_h.except(:contacts_ident_eq)
- new_search_params[:name_matches] = "%#{new_search_params[:name_matches]}%"
- @q = domains.ransack(new_search_params)
- @domains = @q.result.page(params[:page])
- end
- end
-
- @domains = @domains.per(params[:results_per_page]) if params[:results_per_page].to_i.positive?
-
- respond_to do |format|
- format.html
- format.csv do
- domain_presenters = []
-
- @domains.find_each do |domain|
- domain_presenters << ::DomainPresenter.new(domain: domain, view: view_context)
- end
-
- raw_csv = Registrar::DomainListCsvPresenter.new(domains: domain_presenters,
- view: view_context).to_s
- filename = "Domains_#{l(Time.zone.now, format: :filename)}.csv"
- send_data raw_csv, filename: filename, type: "#{Mime[:csv]}; charset=utf-8"
- end
- end
- end
-
- def current_domain_scope
- current_registrar_user.registrar.domains.includes(:registrar, :registrant)
- end
-
- def info
- authorize! :info, Depp::Domain
- @data = @domain.info(params[:domain_name]) if params[:domain_name]
- @pending_delete = domain_delete_pending(@data)
- @client_holded = client_holded(@data)
- if response_ok?
- render 'info'
- else
- flash[:alert] = @data.css('msg').text
- redirect_to registrar_domains_url and return
- end
- end
-
- def check
- authorize! :check, Depp::Domain
- if params[:domain_name]
- @data = @domain.check(params[:domain_name])
- render 'check_index' and return unless response_ok?
- else
- render 'check_index'
- end
- end
-
- def new
- authorize! :create, Depp::Domain
- @domain_params = Depp::Domain.default_params
- @domain_params[:period] = Depp::Domain.default_period
- end
-
- # rubocop:disable Metrics/CognitiveComplexity
- def create
- authorize! :create, Depp::Domain
- @domain_params = domain_params.to_h
- @data = @domain.create(@domain_params)
-
- if @data && response_ok?
- redirect_to info_registrar_domains_url(domain_name: @domain_params[:name])
- else
- flash[:alert] = t('.email_error_message') unless @emails_check_result
- render 'new'
- end
- end
-
- def edit
- authorize! :update, Depp::Domain
- @data = @domain.info(params[:domain_name])
- @domain_params = Depp::Domain.construct_params_from_server_data(@data)
- @dispute = Dispute.active.find_by(domain_name: params[:domain_name])
- end
-
- def update
- authorize! :update, Depp::Domain
- @domain_params = params[:domain]
- @data = @domain.update(@domain_params)
- @dispute = Dispute.active.find_by(domain_name: @domain_params[:name])
-
- if @data && response_ok?
- redirect_to info_registrar_domains_url(domain_name: @domain_params[:name])
- else
- flash[:alert] = t('.email_error_message') unless @emails_check_result
- params[:domain_name] = @domain_params[:name]
- render 'new'
- end
- end
- # rubocop:enable Metrics/CognitiveComplexity
-
- def delete
- authorize! :delete, Depp::Domain
- end
-
- def destroy
- authorize! :delete, Depp::Domain
- @data = @domain.delete(params[:domain])
- @results = @data.css('result')
- if response_ok?
- flash[:notice] = t('.deleting_request')
- redirect_to info_registrar_domains_url(domain_name: params[:domain][:name])
- else
- params[:domain_name] = params[:domain][:name]
- render 'delete'
- end
- end
-
- def renew
- authorize! :renew, Depp::Domain
- if params[:domain_name] && params[:cur_exp_date]
- @data = @domain.renew(params)
- render 'renew_index' and return unless response_ok?
- else
- params[:period] = Depp::Domain.default_period
- render 'renew_index'
- end
- end
-
- def search_contacts
- authorize! :create, Depp::Domain
-
- scope = current_registrar_user.registrar.contacts.limit(10)
- if params[:query].present?
- escaped_str = ActiveRecord::Base.connection.quote_string params[:query]
- scope = scope.where("name ilike '%#{escaped_str}%' OR code ilike '%#{escaped_str}%' ")
- end
-
- render json: scope.pluck(:name, :code).map { |c| { display_key: "#{c.second} #{c.first}", value: c.second } }
- end
-
- def remove_hold
- authorize! :remove_hold, Depp::Domain
- return unless params[:domain_name]
-
- @data = @domain.remove_hold(params)
-
- flash[:alert] = @data.css('msg').text unless response_ok?
- redirect_to info_registrar_domains_url(domain_name: params[:domain_name])
- end
-
- private
-
- def init_domain
- @domain = Depp::Domain.new(current_user: depp_current_user)
- end
-
- def client_holded(data)
- data.css('status')&.map { |element| element.attribute('s').value }
- &.any? { |status| status == DomainStatus::CLIENT_HOLD }
- end
-
- def domain_delete_pending(data)
- data.css('status')&.map { |element| element.attribute('s').value }
- &.any? { |status| status.include?(DomainStatus::PENDING_DELETE) }
- end
-
- def contacts
- current_registrar_user.registrar.contacts
- end
-
- def normalize_search_parameters
- ca_cache = search_params[:valid_to_lteq]
- begin
- end_time = search_params[:valid_to_lteq].try(:to_date)
- search_params[:valid_to_lteq] = end_time.try(:end_of_day)
- rescue
- logger.warn('Invalid date')
- end
-
- yield
-
- search_params[:valid_to_lteq] = ca_cache
- end
-
- def search_params
- params.fetch(:q, {}).permit(:name_matches,
- :registrant_ident_eq,
- :contacts_ident_eq,
- :nameservers_hostname_eq,
- :valid_to_gteq,
- :valid_to_lteq,
- :s)
- end
-
- def domain_params
- params.require(:domain).permit(:name, :period, :registrant, :registrant_helper, :reserved_pw,
- :verified, :legal_document, contacts_attributes: {},
- nameservers_attributes: {},
- dnskeys_attributes: {})
- end
- end
-end
diff --git a/app/controllers/registrar/invoices/delivery_controller.rb b/app/controllers/registrar/invoices/delivery_controller.rb
deleted file mode 100644
index 8cdbb9196..000000000
--- a/app/controllers/registrar/invoices/delivery_controller.rb
+++ /dev/null
@@ -1,13 +0,0 @@
-class Registrar
- module Invoices
- class DeliveryController < BaseController
- include Deliverable
-
- private
-
- def redirect_url
- registrar_invoice_path(@invoice)
- end
- end
- end
-end
diff --git a/app/controllers/registrar/invoices_controller.rb b/app/controllers/registrar/invoices_controller.rb
deleted file mode 100644
index 2a17b72b0..000000000
--- a/app/controllers/registrar/invoices_controller.rb
+++ /dev/null
@@ -1,38 +0,0 @@
-class Registrar
- class InvoicesController < BaseController
- load_and_authorize_resource
-
- def index
- params[:q] ||= {}
- invoices = current_registrar_user.registrar.invoices.includes(:items, :account_activity)
-
- normalize_search_parameters do
- @q = invoices.ransack(params[:q])
- @q.sorts = 'id desc' if @q.sorts.empty?
- @invoices = @q.result.page(params[:page])
- end
- end
-
- def show; end
-
- def cancel
- @invoice.cancel
- EisBilling::SendInvoiceStatus.send_info(invoice_number: @invoice.number, status: 'cancelled')
-
- redirect_to [:registrar, @invoice], notice: t('.cancelled')
- end
-
- def download
- filename = "invoice-#{@invoice.number}.pdf"
- send_data @invoice.as_pdf, filename: filename
- end
-
- private
-
- def normalize_search_parameters
- params[:q][:total_gteq].gsub!(',', '.') if params[:q][:total_gteq]
- params[:q][:total_lteq].gsub!(',', '.') if params[:q][:total_lteq]
- yield
- end
- end
-end
diff --git a/app/controllers/registrar/nameservers_controller.rb b/app/controllers/registrar/nameservers_controller.rb
deleted file mode 100644
index 9bf31d1d7..000000000
--- a/app/controllers/registrar/nameservers_controller.rb
+++ /dev/null
@@ -1,65 +0,0 @@
-class Registrar
- class NameserversController < BulkChangeController
- def update
- authorize! :manage, :repp
-
- ipv4 = params[:ipv4].split("\r\n")
- ipv6 = params[:ipv6].split("\r\n")
-
- uri = URI.parse("#{ENV['repp_url']}registrar/nameservers")
-
- domains = domain_list_from_csv
-
- return csv_list_empty_guard if domains == []
-
- options = {
- uri: uri,
- ipv4: ipv4,
- ipv6: ipv6,
- }
- action = Actions::BulkNameserversChange.new(params, domains, current_registrar_user, options)
- response = action.call
-
- parsed_response = JSON.parse(response.body, symbolize_names: true)
-
- if response.code == '200'
- redirect_to(registrar_domains_url,
- flash: { notice: compose_notice_message(parsed_response) })
- else
- @api_errors = parsed_response[:message]
- render 'registrar/bulk_change/new', locals: { active_tab: :nameserver }
- end
- end
-
- def compose_notice_message(res)
- action_text = params[:old_hostname].blank? ? t('.added') : t('.replaced')
- notices = ["#{action_text}. #{t('.affected_domains')}: " \
- "#{res[:data][:affected_domains].join(', ')}"]
-
- notices << "#{t('.skipped_domains')}: #{res[:data][:skipped_domains].join(', ')}" if res[:data][:skipped_domains]
-
- notices.join(', ')
- end
-
- def csv_list_empty_guard
- notice = 'CSV scoped domain list seems empty. Make sure that domains are added and ' \
- '"Domain" header is present.'
- redirect_to(registrar_domains_url, flash: { notice: notice })
- end
-
- def domain_list_from_csv
- return if params[:puny_file].blank?
-
- domains = []
- csv = CSV.read(params[:puny_file].path, headers: true)
-
- return [] if csv['Domain'].blank?
-
- csv.map { |b| domains << b['Domain'] }
-
- domains.compact
- rescue CSV::MalformedCSVError
- []
- end
- end
-end
diff --git a/app/controllers/registrar/payments_controller.rb b/app/controllers/registrar/payments_controller.rb
deleted file mode 100644
index 598d13446..000000000
--- a/app/controllers/registrar/payments_controller.rb
+++ /dev/null
@@ -1,66 +0,0 @@
-class Registrar
- class PaymentsController < BaseController
- protect_from_forgery except: [:back, :callback]
-
- skip_authorization_check # actually anyone can pay, no problems at all
- skip_before_action :authenticate_registrar_user!, :check_ip_restriction,
- only: [:back, :callback]
-
- before_action :check_supported_payment_method, only: [:pay]
-
- def pay
- invoice = Invoice.find(params[:invoice_id])
- channel = params[:bank]
-
- @payment_order = PaymentOrder.new_with_type(type: channel, invoice: invoice)
- @payment_order.save
- @payment_order.reload
-
- @payment_order.return_url = registrar_return_payment_with_url(@payment_order)
- @payment_order.response_url = registrar_response_payment_with_url(@payment_order)
-
- @payment_order.save
- @payment_order.reload
- end
-
- def back
- @payment_order = PaymentOrder.find_by!(id: params[:payment_order])
- @payment_order.update!(response: params.to_unsafe_h)
-
- if @payment_order.payment_received?
- @payment_order.complete_transaction
-
- if @payment_order.invoice.paid?
- flash[:notice] = t('.payment_successful')
- else
- flash[:alert] = t('.successful_payment_backend_error')
- end
- else
- @payment_order.create_failure_report
- flash[:alert] = t('.payment_not_received')
- end
- redirect_to registrar_invoice_path(@payment_order.invoice)
- end
-
- def callback
- @payment_order = PaymentOrder.find_by!(id: params[:payment_order])
- @payment_order.update!(response: params.to_unsafe_h)
-
- if @payment_order.payment_received?
- @payment_order.complete_transaction
- else
- @payment_order.create_failure_report
- end
-
- render status: 200, json: { status: 'ok' }
- end
-
- private
-
- def check_supported_payment_method
- return if PaymentOrder.supported_method?(params[:bank], shortname: true)
-
- raise(StandardError, 'Not supported payment method')
- end
- end
-end
diff --git a/app/controllers/registrar/polls_controller.rb b/app/controllers/registrar/polls_controller.rb
deleted file mode 100644
index dde4bb8ea..000000000
--- a/app/controllers/registrar/polls_controller.rb
+++ /dev/null
@@ -1,44 +0,0 @@
-class Registrar
- class PollsController < DeppController
- authorize_resource class: false
- before_action :init_epp_xml
-
- def show
- if Rails.env.test? # Stub for depp server request
- @data = Object.new
-
- def @data.css(key)
- ; [];
- end
- else
- @data = depp_current_user.request(@ex.poll)
- end
- end
-
- def destroy
- @data = depp_current_user.request(@ex.poll(poll: { value: '', attrs: { op: 'ack', msgID: params[:id] } }))
-
- @results = @data.css('result')
-
- @data = depp_current_user.request(@ex.poll)
- render 'show'
- end
-
- def confirm_transfer
- domain_params = params[:domain]
- @data = @domain.confirm_transfer(domain_params)
-
- @results = @data.css('result')
- @data = depp_current_user.request(@ex.poll)
-
- render 'show'
- end
-
- private
-
- def init_epp_xml
- @ex = EppXml::Session.new(cl_trid_prefix: depp_current_user.tag)
- @domain = Depp::Domain.new(current_user: depp_current_user)
- end
- end
-end
diff --git a/app/controllers/registrar/sessions_controller.rb b/app/controllers/registrar/sessions_controller.rb
deleted file mode 100644
index c73ed799b..000000000
--- a/app/controllers/registrar/sessions_controller.rb
+++ /dev/null
@@ -1,108 +0,0 @@
-class Registrar
- class SessionsController < Devise::SessionsController
- before_action :check_ip_restriction
- helper_method :depp_controller?
-
- def create
- @depp_user = Depp::User.new(depp_user_params)
-
- if @depp_user.pki && request.env['HTTP_SSL_CLIENT_S_DN_CN'].blank?
- @depp_user.errors.add(:base, :webserver_missing_user_name_directive)
- end
-
- if @depp_user.pki && request.env['HTTP_SSL_CLIENT_CERT'].blank?
- @depp_user.errors.add(:base, :webserver_missing_client_cert_directive)
- end
-
- if @depp_user.pki && request.env['HTTP_SSL_CLIENT_S_DN_CN'] == '(null)'
- @depp_user.errors.add(:base, :webserver_user_name_directive_should_be_required)
- end
-
- if @depp_user.pki && request.env['HTTP_SSL_CLIENT_CERT'] == '(null)'
- @depp_user.errors.add(:base, :webserver_client_cert_directive_should_be_required)
- end
-
- @api_user = ApiUser.find_by(username: sign_in_params[:username],
- plain_text_password: sign_in_params[:password])
-
- unless @api_user
- @depp_user.errors.add(:base, t(:no_such_user))
- show_error and return
- end
-
- if @depp_user.pki && !@api_user.pki_ok?(request.env['HTTP_SSL_CLIENT_CERT'],
- request.env['HTTP_SSL_CLIENT_S_DN_CN'], api: false)
- @depp_user.errors.add(:base, :invalid_cert)
- end
-
- show_error and return unless @depp_user.errors.none?
-
- if @api_user.active?
- sign_in_and_redirect(:registrar_user, @api_user)
- else
- @depp_user.errors.add(:base, :not_active)
- show_error
- end
- end
-
- private
-
- def depp_controller?
- false
- end
-
- def find_user_by_idc(idc)
- return User.new unless idc
- ApiUser.find_by(identity_code: idc) || User.new
- end
-
- def find_user_by_idc_and_allowed(idc)
- return User.new unless idc
-
- possible_users = ApiUser.where(identity_code: idc) || User.new
- possible_users.each do |selected_user|
- return selected_user if selected_user.registrar.white_ips.registrar_area.include_ip?(request.ip)
- end
- end
-
- def check_ip_restriction
- ip_restriction = Authorization::RestrictedIp.new(request.ip)
- allowed = ip_restriction.can_access_registrar_area_sign_in_page?
-
- return if allowed
-
- render plain: t('registrar.authorization.ip_not_allowed', ip: request.ip)
- end
-
- def current_ability
- @current_ability ||= Ability.new(current_registrar_user, request.remote_ip)
- end
-
- def after_sign_in_path_for(_resource_or_scope)
- if can?(:show, :poll)
- registrar_root_path
- else
- registrar_account_path
- end
- end
-
- def after_sign_out_path_for(_resource_or_scope)
- new_registrar_user_session_path
- end
-
- def user_for_paper_trail
- current_registrar_user ? current_registrar_user.id_role_username : 'anonymous'
- end
-
- def depp_user_params
- params = sign_in_params
- params[:tag] = params.delete(:username)
- params.merge!(pki: !(Rails.env.development? || Rails.env.test?))
- params
- end
-
- def show_error
- redirect_to new_registrar_user_session_url, alert: @depp_user.errors.full_messages.first
- end
- end
-end
diff --git a/app/controllers/registrar/settings/balance_auto_reload_controller.rb b/app/controllers/registrar/settings/balance_auto_reload_controller.rb
deleted file mode 100644
index d6ace12ef..000000000
--- a/app/controllers/registrar/settings/balance_auto_reload_controller.rb
+++ /dev/null
@@ -1,52 +0,0 @@
-class Registrar
- module Settings
- class BalanceAutoReloadController < BaseController
- before_action :authorize
-
- def edit
- @type = if current_registrar.settings['balance_auto_reload']
- type_params = current_registrar.settings['balance_auto_reload']['type']
- .except('name')
- BalanceAutoReloadTypes::Threshold.new(type_params)
- else
- BalanceAutoReloadTypes::Threshold.new
- end
- end
-
- def update
- type = BalanceAutoReloadTypes::Threshold.new(type_params)
- current_registrar.update!(settings: { balance_auto_reload: { type: type } })
-
- redirect_to registrar_account_path, notice: t('.saved')
- end
-
- def destroy
- current_registrar.settings.delete('balance_auto_reload')
- current_registrar.save!
-
- redirect_to registrar_account_path, notice: t('.disabled')
- end
-
- private
-
- def type_params
- permitted_params = params.require(:type).permit(:amount, :threshold)
- normalize_params(permitted_params)
- end
-
- def normalize_params(params)
- params[:amount] = params[:amount].to_f
- params[:threshold] = params[:threshold].to_f
- params
- end
-
- def authorize
- authorize!(:manage, :balance_auto_reload)
- end
-
- def current_registrar
- current_registrar_user.registrar
- end
- end
- end
-end
diff --git a/app/controllers/registrar/tech_contacts_controller.rb b/app/controllers/registrar/tech_contacts_controller.rb
deleted file mode 100644
index 9a5631abf..000000000
--- a/app/controllers/registrar/tech_contacts_controller.rb
+++ /dev/null
@@ -1,22 +0,0 @@
-class Registrar
- class TechContactsController < BulkChangeController
- BASE_URL = URI.parse("#{ENV['repp_url']}domains/contacts").freeze
- ACTIVE_TAB = :technical_contact
-
- def update
- authorize! :manage, :repp
-
- uri = BASE_URL
- request = form_request(uri)
-
- action = Actions::DoRequest.new(request, uri)
- response = action.call
-
- start_notice = t('.replaced')
-
- process_response(response: response,
- start_notice: start_notice,
- active_tab: ACTIVE_TAB)
- end
- end
-end
diff --git a/app/controllers/registrar/xml_consoles_controller.rb b/app/controllers/registrar/xml_consoles_controller.rb
deleted file mode 100644
index a27e3e3ee..000000000
--- a/app/controllers/registrar/xml_consoles_controller.rb
+++ /dev/null
@@ -1,62 +0,0 @@
-class Registrar
- class XmlConsolesController < DeppController
- PREFS = %w[
- domain-ee
- contact-ee
- eis
- epp-ee
- ].freeze
-
- authorize_resource class: false
-
- def show; end
-
- def create
- begin
- @result = depp_current_user.server.request(params[:payload])
- rescue StandardError
- @result = 'CONNECTION ERROR - Is the EPP server running?'
- end
- render :show
- end
-
- def load_xml
- cl_trid = "#{depp_current_user.tag}-#{Time.zone.now.to_i}"
- xml_dir_path = Rails.root.join('app/views/registrar/xml_consoles/epp_requests').to_s
- xml = File.read("#{xml_dir_path}/#{params[:obj]}/#{params[:epp_action]}.xml")
- xml = prepare_payload(xml, cl_trid)
-
- render plain: xml
- end
-
- private
-
- def prepare_payload(xml, cl_trid)
- PREFS.map do |pref|
- xml = load_schema_by_prefix(pref, xml)
- end
-
- xml.gsub!('ABC-12345 ', "#{cl_trid} ")
- xml
- end
-
- def load_schema_by_prefix(pref, xml)
- case pref
- when 'epp-ee'
- insert_prefix_and_version(xml, pref, '1.0')
- when 'eis'
- insert_prefix_and_version(xml, pref, '1.0')
- when 'contact-ee'
- insert_prefix_and_version(xml, pref, '1.1')
- else
- insert_prefix_and_version(xml, pref, '1.2')
- end
- end
-
- def insert_prefix_and_version(xml, pref, version)
- xml.gsub!("\"#{pref}\"",
- "\"#{Xsd::Schema.filename(for_prefix: pref.to_s, for_version: version)}\"")
- xml
- end
- end
-end
diff --git a/app/views/layouts/registrar/base.html.erb b/app/views/layouts/registrar/base.html.erb
deleted file mode 100644
index 5881dd400..000000000
--- a/app/views/layouts/registrar/base.html.erb
+++ /dev/null
@@ -1,64 +0,0 @@
-
-
-
-
-
- <% if content_for? :head_title %>
- <%= yield :head_title %>
- <% else %>
-
- <%= t(:registrar_head_title) %>
-
- <% end %>
- <%= csrf_meta_tags %>
- <%= stylesheet_link_tag 'registrar-manifest', media: 'all' %>
- <%= favicon_link_tag 'favicon.ico' %>
-
-
-
-
-
- <%= render 'navbar' %>
-
-
-
- <%= render 'flash_messages' %>
- <% if depp_controller? %>
- <%= render 'registrar/shared/epp_results' %>
- <% end %>
- <%= yield %>
-
-
- <%= javascript_include_tag 'registrar-manifest', async: true %>
-
-
diff --git a/app/views/layouts/registrar/sessions.html.erb b/app/views/layouts/registrar/sessions.html.erb
deleted file mode 100644
index ace645199..000000000
--- a/app/views/layouts/registrar/sessions.html.erb
+++ /dev/null
@@ -1,53 +0,0 @@
-
-
-
-
- <% if content_for? :head_title %>
- <%= yield :head_title %>
- <% else %>
-
- <%= t(:registrar_head_title) %>
-
- <% end %>
- <%= csrf_meta_tags %>
- <%= stylesheet_link_tag 'registrar-manifest', media: 'all' %>
- <%= javascript_include_tag 'registrar-manifest' %>
-
-
-
-
-
-
-
-
-
- <%= render 'flash_messages' %>
- <%= yield %>
-
-
-
-
-
diff --git a/app/views/registrar/account/_balance_auto_reload.html.erb b/app/views/registrar/account/_balance_auto_reload.html.erb
deleted file mode 100644
index 9b6f2791a..000000000
--- a/app/views/registrar/account/_balance_auto_reload.html.erb
+++ /dev/null
@@ -1,30 +0,0 @@
-
-
- <%= t '.header' %>
-
-
-
- <% if setting %>
- <%= t '.enabled' %>
- <%= t '.enabled_state_details', amount: number_to_currency(setting['type']['amount']),
- threshold: number_to_currency(setting['type']['threshold']) %>
- <% else %>
- <%= t '.disabled' %>
- <% end %>
-
-
-
-
\ No newline at end of file
diff --git a/app/views/registrar/account/_details.html.erb b/app/views/registrar/account/_details.html.erb
deleted file mode 100644
index 185b046c8..000000000
--- a/app/views/registrar/account/_details.html.erb
+++ /dev/null
@@ -1,19 +0,0 @@
-
-
- <%= t '.header' %>
-
-
-
-
- <%= Registrar.human_attribute_name :billing_email %>
- <%= registrar.billing_email %>
-
- <%= Registrar.human_attribute_name :iban %>
- <%= registrar.iban %>
-
-
-
-
-
diff --git a/app/views/registrar/account/_form.html.erb b/app/views/registrar/account/_form.html.erb
deleted file mode 100644
index ab1fb0294..000000000
--- a/app/views/registrar/account/_form.html.erb
+++ /dev/null
@@ -1,32 +0,0 @@
-<%= form_for @registrar, url: registrar_account_path, method: :patch, html: { class: 'form-horizontal' } do |f| %>
- <%= render 'form_errors', target: @registrar %>
-
-
-
-
-
-
-
-
-
- <%= f.submit t('.submit_btn'), class: 'btn btn-success' %>
-
-
-<% end %>
\ No newline at end of file
diff --git a/app/views/registrar/account/_linked_users.html.erb b/app/views/registrar/account/_linked_users.html.erb
deleted file mode 100644
index fa8d868b4..000000000
--- a/app/views/registrar/account/_linked_users.html.erb
+++ /dev/null
@@ -1,18 +0,0 @@
-
-
<%= t '.header' %>
-
-
- <% linked_users.each do |user| %>
- <% user_presenter = UserPresenter.new(user: user, view: self) %>
- <%= user_presenter.login_with_role %>
- <%= link_to t('.switch_btn'),
- registrar_switch_current_user_path(user),
- method: :put,
- id: "switch-current-user-#{user.id}-btn",
- class: 'btn btn-primary btn-xs' %>
-
- <% end %>
-
-
-
-
diff --git a/app/views/registrar/account/edit.html.erb b/app/views/registrar/account/edit.html.erb
deleted file mode 100644
index 20aa88d2d..000000000
--- a/app/views/registrar/account/edit.html.erb
+++ /dev/null
@@ -1,10 +0,0 @@
-
- <%= link_to t('registrar.account.show.header'), registrar_account_path %>
- <%= t '.header' %>
-
-
-
-
-<%= render 'form' %>
\ No newline at end of file
diff --git a/app/views/registrar/account/show.html.erb b/app/views/registrar/account/show.html.erb
deleted file mode 100644
index 75d0ce400..000000000
--- a/app/views/registrar/account/show.html.erb
+++ /dev/null
@@ -1,23 +0,0 @@
-
-
-
-
- <%= render 'details', registrar: current_registrar_user.registrar %>
-
-
-
-
-
- <%= render 'linked_users', linked_users: current_registrar_user.linked_users %>
-
-
-
-<% if can?(:manage, :balance_auto_reload) %>
-
-
- <%= render 'balance_auto_reload', setting: balance_auto_reload_setting %>
-
-
-<% end %>
\ No newline at end of file
diff --git a/app/views/registrar/account_activities/_search_form.html.erb b/app/views/registrar/account_activities/_search_form.html.erb
deleted file mode 100644
index 92a715096..000000000
--- a/app/views/registrar/account_activities/_search_form.html.erb
+++ /dev/null
@@ -1,49 +0,0 @@
-
-
- <%= search_form_for @q, url: [:registrar, :account_activities], html: { style: 'margin-bottom: 0;' } do |f| %>
-
-
-
- <%= f.label t(:activity_type) %>
- <%= f.select :activity_type_in, AccountActivity.types_for_select, {}, class: 'form-control js-combobox', placeholder: t(:choose), multiple: true %>
-
-
-
-
-
- <%= f.label t(:description) %>
- <%= f.search_field :description_cont, class: 'form-control', placeholder: t(:description), autocomplete: 'off' %>
-
-
-
-
-
-
-
- <%= f.label t(:receipt_date_from) %>
- <%= f.search_field :created_at_gteq, value: params[:q][:created_at_gteq], class: 'form-control js-datepicker', placeholder: t(:receipt_date_from) %>
-
-
-
-
-
- <%= f.label t(:receipt_date_until) %>
- <%= f.search_field :created_at_lteq, value: params[:q][:created_at_lteq], class: 'form-control js-datepicker', placeholder: t(:receipt_date_until) %>
-
-
-
-
-
-
-
-
-
- <%= button_tag t('.download_btn'),
- formaction: registrar_account_activities_path(format: 'csv'),
- class: 'btn btn-default' %>
- <%= link_to(t('.reset_btn'), registrar_account_activities_path, class: 'btn btn-default') %>
-
-
- <% end %>
-
-
diff --git a/app/views/registrar/account_activities/index.html.erb b/app/views/registrar/account_activities/index.html.erb
deleted file mode 100644
index aefcdd47f..000000000
--- a/app/views/registrar/account_activities/index.html.erb
+++ /dev/null
@@ -1,66 +0,0 @@
-<% content_for :actions do %>
- <%= link_to(t(:back_to_billing), registrar_invoices_path, class: 'btn btn-default') %>
-<% end %>
-
-<%= render 'shared/title', name: t(:account_activity) %>
-
-<%= render 'search_form' %>
-
-
-
-
-
-
-
-
-
-
- <%= sort_link(@q, 'description') %>
-
-
- <%= sort_link(@q, 'activity_type') %>
-
-
- <%= sort_link(@q, 'created_at', AccountActivity.human_attribute_name(:created_at)) %>
-
-
- <%= sort_link(@q, 'sum') %>
-
-
- <%= sort_link(@q, 'new_balance', 'New balance') %>
-
-
-
-
- <% @account_activities.each do |x| %>
-
-
- <%= x.description.present? ? x.description : '-' %>
-
-
- <%= x.activity_type ? t(x.activity_type) : '' %>
-
-
- <%= l(x.created_at) %>
-
- <% c = x.sum > 0.0 ? 'text-success' : 'text-danger' %>
- <% s = x.sum > 0.0 ? "+#{x.sum} #{x.currency}" : "#{x.sum} #{x.currency}" %>
-
- <%= s %>
-
-
- <%= x.new_balance.present? ? "#{currency(x.new_balance)} EUR" : 'N/A' %>
-
-
- <% end %>
-
-
-
-
-
-
-
-
- <%= paginate @account_activities %>
-
-
diff --git a/app/views/registrar/base/_current_user.html.erb b/app/views/registrar/base/_current_user.html.erb
deleted file mode 100644
index a21792b3c..000000000
--- a/app/views/registrar/base/_current_user.html.erb
+++ /dev/null
@@ -1,4 +0,0 @@
-<% current_user_presenter = UserPresenter.new(user: current_registrar_user, view: self) %>
-<%= link_to current_user_presenter.login_with_role, registrar_account_path, class: 'navbar-link' %>
-|
-<%= link_to t('.sign_out'), destroy_registrar_user_session_path, method: :delete, class: 'navbar-link' %>
diff --git a/app/views/registrar/base/_form_errors.html.erb b/app/views/registrar/base/_form_errors.html.erb
deleted file mode 100644
index 0f898c81d..000000000
--- a/app/views/registrar/base/_form_errors.html.erb
+++ /dev/null
@@ -1,11 +0,0 @@
-<% if target.errors.any? %>
-
-
<%= pluralize(target.errors.count, 'error') %> prohibited this <%= target.model_name.human.downcase %> from being saved:
-
-
- <% target.errors.full_messages.each do |message| %>
- <%= message %>
- <% end %>
-
-
-<% end %>
diff --git a/app/views/registrar/base/_navbar.haml b/app/views/registrar/base/_navbar.haml
deleted file mode 100644
index 4361e8b31..000000000
--- a/app/views/registrar/base/_navbar.haml
+++ /dev/null
@@ -1,20 +0,0 @@
-.navbar-collapse.collapse
- %ul.nav.navbar-nav
- - if can? :view, Depp::Domain
- - active_class = %w(registrar/domains registrar/check registrar/renew registrar/tranfer).include?(params[:controller]) ? 'active' :nil
- %li{class: active_class}= link_to t(:domains), registrar_domains_path
-
- - if can? :view, Depp::Contact
- - active_class = ['registrar/contacts'].include?(params[:controller]) ? 'active' :nil
- %li{class: active_class}= link_to t(:contacts), registrar_contacts_path
-
- - if can? :show, Invoice
- - active_class = ['registrar/invoices'].include?(params[:controller]) ? 'active' :nil
- %li{class: active_class}= link_to t(:billing), registrar_invoices_path
-
- - if !Rails.env.production? && can?(:manage, :xml_console)
- - active_class = ['registrar/xml_consoles'].include?(params[:controller]) ? 'active' :nil
- %li{class: active_class}= link_to t(:xml_console), registrar_xml_console_path
-
- %div.navbar-text.navbar-right
- = render 'current_user'
diff --git a/app/views/registrar/bulk_change/_admin_contact_form.html.erb b/app/views/registrar/bulk_change/_admin_contact_form.html.erb
deleted file mode 100644
index 77734e872..000000000
--- a/app/views/registrar/bulk_change/_admin_contact_form.html.erb
+++ /dev/null
@@ -1,65 +0,0 @@
-<%= form_tag registrar_admin_contacts_path, method: :patch, class: 'form-horizontal' do %>
- <% if @error %>
-
- <%= @error %>
-
- <% end %>
-
-
-
-
-
-
-
-
-<% end %>
-
-
- <% available_contacts.each do |data| %>
- <%= data.first %>
- <% end %>
-
diff --git a/app/views/registrar/bulk_change/_api_errors.html.erb b/app/views/registrar/bulk_change/_api_errors.html.erb
deleted file mode 100644
index 8d8862959..000000000
--- a/app/views/registrar/bulk_change/_api_errors.html.erb
+++ /dev/null
@@ -1,13 +0,0 @@
-<% if @api_errors %>
-
-
- <% if @api_errors.is_a?(String) %>
- <%= @api_errors %>
- <% else %>
- <% @api_errors.each do |error| %>
- <%= error[:title] %>
- <% end %>
- <% end %>
-
-
-<% end %>
diff --git a/app/views/registrar/bulk_change/_bulk_renew_form.html.erb b/app/views/registrar/bulk_change/_bulk_renew_form.html.erb
deleted file mode 100644
index 5db40365f..000000000
--- a/app/views/registrar/bulk_change/_bulk_renew_form.html.erb
+++ /dev/null
@@ -1,57 +0,0 @@
-<%= form_with url: registrar_bulk_renew_path, multipart: true, class: 'form-horizontal' do |f|%>
- <%= render 'api_errors' %>
-
-
-
-
-
-
-
-
- <% if @domains.present? %>
-
- <% end %>
-
-
- <%= f.submit "#{t '.filter_btn'}", name: 'filter', class: 'btn btn-warning' %>
- <% if @domains.present? %>
- <%= f.submit "#{t '.renew_btn'}", name: 'renew', class: 'btn btn-primary' %>
- <% end %>
-
-<% end %>
diff --git a/app/views/registrar/bulk_change/_bulk_transfer_form.html.erb b/app/views/registrar/bulk_change/_bulk_transfer_form.html.erb
deleted file mode 100644
index 0a953845b..000000000
--- a/app/views/registrar/bulk_change/_bulk_transfer_form.html.erb
+++ /dev/null
@@ -1,34 +0,0 @@
-<%= form_tag registrar_domain_transfers_path, multipart: true, class: 'form-horizontal' do %>
- <%= render 'registrar/domain_transfers/form/api_errors' %>
-
-
-
-
-
-
-<% end %>
diff --git a/app/views/registrar/bulk_change/_nameserver_form.html.erb b/app/views/registrar/bulk_change/_nameserver_form.html.erb
deleted file mode 100644
index 45ae6a7dd..000000000
--- a/app/views/registrar/bulk_change/_nameserver_form.html.erb
+++ /dev/null
@@ -1,77 +0,0 @@
-<%= form_tag registrar_nameservers_path, multipart: true, method: :patch, class: 'form-horizontal' do %>
- <%= render 'registrar/domain_transfers/form/api_errors' %>
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-<% end %>
diff --git a/app/views/registrar/bulk_change/_tech_contact_form.html.erb b/app/views/registrar/bulk_change/_tech_contact_form.html.erb
deleted file mode 100644
index 789db92ba..000000000
--- a/app/views/registrar/bulk_change/_tech_contact_form.html.erb
+++ /dev/null
@@ -1,60 +0,0 @@
-<%= form_tag registrar_tech_contacts_path, method: :patch, class: 'form-horizontal' do %>
- <% if @error %>
-
- <%= @error %>
-
- <% end %>
-
-
-
-
-
-
-
-
-<% end %>
-
-
- <% available_contacts.each do |data| %>
- <%= data.first %>
- <% end %>
-
diff --git a/app/views/registrar/bulk_change/new.html.erb b/app/views/registrar/bulk_change/new.html.erb
deleted file mode 100644
index f3095a53d..000000000
--- a/app/views/registrar/bulk_change/new.html.erb
+++ /dev/null
@@ -1,54 +0,0 @@
-
- <%= link_to t('registrar.domains.index.header'), registrar_domains_path %>
-
-
-
-
-
-
-
-
-
- <%= render 'tech_contact_form', available_contacts: available_contacts %>
-
-
-
- <%= render 'admin_contact_form', available_contacts: available_contacts %>
-
-
-
- <%= render 'nameserver_form' %>
-
-
-
- <%= render 'bulk_transfer_form' %>
-
-
-
- <%= render 'bulk_renew_form' %>
-
-
diff --git a/app/views/registrar/contacts/_form.haml b/app/views/registrar/contacts/_form.haml
deleted file mode 100644
index 953c502e5..000000000
--- a/app/views/registrar/contacts/_form.haml
+++ /dev/null
@@ -1,26 +0,0 @@
-= render 'registrar/shared/error_messages', f: f
-= f.hidden_field :id
-= f.hidden_field :password
-.row
- .col-md-8
- = render 'registrar/contacts/form/general', f: f
-
-- if Contact.address_processing?
- .row
- .col-md-8
- = render 'registrar/contacts/form/address', f: f
-
-- if !@contact.persisted?
- .row
- .col-md-8
- = render 'registrar/contacts/form/code', f: f
-.row
- .col-md-8
- = render 'registrar/contacts/form/legal_document', f: f
-
-.row
- .col-md-8.text-right
- - if @contact.persisted?
- = button_tag t(:save), class: 'btn btn-warning'
- - else
- = button_tag t(:create), class: 'btn btn-warning'
diff --git a/app/views/registrar/contacts/_search_form.html.erb b/app/views/registrar/contacts/_search_form.html.erb
deleted file mode 100644
index 73c1281e0..000000000
--- a/app/views/registrar/contacts/_search_form.html.erb
+++ /dev/null
@@ -1,117 +0,0 @@
-<%= search_form_for [:registrar, @q], html: { style: 'margin-bottom: 0;', class: 'js-form', autocomplete: 'off' } do |f| %>
-
-
-
- <%= f.label :name %>
- <%= f.search_field :name_matches, value: params[:q][:name_matches], class: 'form-control', placeholder: t(:name) %>
-
-
-
-
-
- <%= f.label t(:id) %>
- <%= f.search_field :code_eq, class: 'form-control', placeholder: t(:id) %>
-
-
-
-
-
- <%= f.label t(:ident) %>
- <%= f.search_field :ident_matches, class: 'form-control', placeholder: t(:ident) %>
-
-
-
-
-
- <%= label_tag t(:ident_type) %>
- <%= select_tag '[q][ident_type_eq]', options_for_select(ident_types, params[:q][:ident_type_eq]), { include_blank: true, placeholder: t(:choose), class: 'form-control selectize' } %>
-
-
-
-
-
-
-
- <%= f.label t(:email) %>
- <%= f.search_field :email_matches, class: 'form-control', placeholder: t(:email) %>
-
-
-
-
-
- <%= label_tag t(:country) %>
- <%= select_tag '[q][country_code_eq]', ApplicationController.helpers.all_country_options(params[:q][:country_code_eq]), { include_blank: true, placeholder: t(:choose), class: 'form-control selectize' } %>
-
-
-
-
-
- <%= label_tag t(:contact_type) %>
- <%= select_tag '[q][domain_contacts_type_in]', options_for_select([['admin', 'AdminDomainContact'], ['tech', 'TechDomainContact'], ['registrant', 'registrant']], params[:q][:domain_contacts_type_in]), { multiple: true, placeholder: t(:choose), class: 'form-control js-combobox' } %>
-
-
-
-
-
-
-
- <%= f.label t(:registrar_name) %>
- <%= f.select :registrar_id_eq, Registrar.all.map { |x| [x, x.id] }, { include_blank: true }, class: 'form-control selectize', placeholder: t(:choose) %>
-
-
-
-
-
- <%= f.label t(:created_at_from) %>
- <%= f.search_field :created_at_gteq, value: params[:q][:created_at_gteq], class: 'form-control js-datepicker', placeholder: t(:created_at_from) %>
-
-
-
-
-
- <%= f.label t(:created_at_until) %>
- <%= f.search_field :created_at_lteq, value: params[:q][:created_at_lteq], class: 'form-control js-datepicker', placeholder: t(:created_at_until) %>
-
-
-
-
-
- <%= f.label t(:updated_at) %>
- <%= f.search_field :updated_at_gteq, value: params[:q][:updated_at_gteq], class: 'form-control js-datepicker', placeholder: t(:updated_at) %>
-
-
-
-
-
-
-
- <%= label_tag t(:status) %>
- <%= select_tag :statuses_contains, options_for_select(Contact::STATUSES, params[:statuses_contains]), { multiple: true, placeholder: t(:choose), class: 'form-control js-combobox' } %>
-
-
-
-
-
- <%= label_tag t(:results_per_page) %>
- <%= text_field_tag :results_per_page, params[:results_per_page], class: 'form-control', placeholder: t(:results_per_page) %>
-
-
-
-
-
-
-
-
-
- <%= button_tag t('.download_pdf_btn'),
- formaction: registrar_contacts_path(format: :pdf),
- name: nil,
- class: 'btn btn-default' %>
- <%= button_tag t('.download_csv_btn'),
- formaction: registrar_contacts_path(format: :csv),
- name: nil,
- class: 'btn btn-default' %>
- <%= link_to(t('.reset_btn'), registrar_contacts_path, class: 'btn btn-default') %>
-
-
-<% end %>
diff --git a/app/views/registrar/contacts/delete.haml b/app/views/registrar/contacts/delete.haml
deleted file mode 100644
index 8662b738c..000000000
--- a/app/views/registrar/contacts/delete.haml
+++ /dev/null
@@ -1,20 +0,0 @@
-- if @contact.persisted?
- = render 'shared/title', name: "#{t(:delete)}: #{@contact.name}"
-
- = form_for(@contact, url: registrar_contact_path(@contact),
- class: 'form-horizontal', multipart: true, method: :delete) do |f|
-
- = render 'registrar/shared/error_messages', f: f
- = f.hidden_field :id
- = f.hidden_field :password
-
- .row
- .col-md-8
- = render 'registrar/contacts/form/legal_document', f: f
-
- %hr
- .row
- .col-md-8.text-right
- = button_tag t(:delete), class: 'btn btn-danger'
-- else
- %h2= "#{t(:delete)}: #{t(:not_found)}"
diff --git a/app/views/registrar/contacts/edit.haml b/app/views/registrar/contacts/edit.haml
deleted file mode 100644
index bfbcf21e9..000000000
--- a/app/views/registrar/contacts/edit.haml
+++ /dev/null
@@ -1,5 +0,0 @@
-= render 'shared/title', name: "#{t(:edit)}: #{@contact.name}"
-
-= form_for(@contact, url: registrar_contact_path(@contact),
- html: {class: 'form-horizontal js-contact-form'}) do |f|
- - render 'form', f: f
diff --git a/app/views/registrar/contacts/form/_address.haml b/app/views/registrar/contacts/form/_address.haml
deleted file mode 100644
index e70d00cd8..000000000
--- a/app/views/registrar/contacts/form/_address.haml
+++ /dev/null
@@ -1,36 +0,0 @@
-.panel.panel-default
- .panel-heading.clearfix
- .pull-left= t(:address)
- .panel-body
- .form-group
- .col-md-3.control-label
- = f.label :street, t(:street) + '*'
- .col-md-7
- = f.text_field :street, class: 'form-control', required: true
-
- .form-group
- .col-md-3.control-label
- = f.label :city, t(:city) + '*'
- .col-md-7
- = f.text_field :city, class: 'form-control', required: true
-
- .form-group
- .col-md-3.control-label
- = f.label :zip, t(:zip) + '*'
- .col-md-7
- = f.text_field :zip, class: 'form-control', required: true
-
- .form-group
- .col-md-3.control-label
- = f.label :state, t(:state)
- .col-md-7
- = f.text_field :state, class: 'form-control'
-
- .form-group
- .col-md-3.control-label
- = f.label :country_code, t(:country) + '*'
- .col-md-7
- - country_selected = f.object.persisted? ? f.object.country_code : 'EE'
- = f.select(:country_code, ApplicationController.helpers.all_country_options(country_selected),
- { include_blank: true }, required: true)
-
diff --git a/app/views/registrar/contacts/form/_code.haml b/app/views/registrar/contacts/form/_code.haml
deleted file mode 100644
index f4bc2733f..000000000
--- a/app/views/registrar/contacts/form/_code.haml
+++ /dev/null
@@ -1,9 +0,0 @@
-.panel.panel-default
- .panel-heading.clearfix
- .pull-left= t(:id)
- .panel-body
- .form-group
- .col-md-2.control-label
- = f.label :code, t(:id)
- .col-md-10
- = f.text_field :code, class: 'form-control'
diff --git a/app/views/registrar/contacts/form/_general.haml b/app/views/registrar/contacts/form/_general.haml
deleted file mode 100644
index 5f1c90098..000000000
--- a/app/views/registrar/contacts/form/_general.haml
+++ /dev/null
@@ -1,67 +0,0 @@
-- ident_complete = f.object.ident_country_code.present? && f.object.ident_type.present? && f.object.ident.present?
-- if @contact.persisted?
- - country_selected = f.object.ident_country_code || (params[:depp_contact].try(:[], :ident_country_code))
- - type_selected = f.object.ident_type || (params[:depp_contact].try(:[], :ident_type))
-- else
- - country_selected = (params[:depp_contact].try(:[], :ident_country_code) || 'EE')
- - type_selected = (params[:depp_contact].try(:[], :ident_type) || 'org')
-
-.panel.panel-default
- .panel-heading.clearfix
- .pull-left= t(:ident)
- .panel-body
- .form-group
- .col-md-3.control-label
- = f.label :ident_country_code, t(:country) + '*'
- .col-md-7
- - if ident_complete && @contact.persisted? && f.object.ident_country_code.present?
- = f.text_field :ident_country_code, value: f.object.ident_country_code, :readonly => true
- - else
- = f.select(:ident_country_code, ApplicationController.helpers.all_country_options(country_selected), {},
- class: 'js-ident-country-code', required: true)
-
- .form-group
- .col-md-3.control-label
- = f.label :ident_type, t(:type) + '*'
- .col-md-7
- - if ident_complete && @contact.persisted? && f.object.ident_type.present?
- = f.text_field :ident_type, value: f.object.ident_type, :readonly => true
- - else
- = f.select(:ident_type, Depp::Contact::SELECTION_TYPES, { selected: type_selected },
- class: 'js-ident-type', required: true)
-
- .form-group
- .col-md-3.control-label
- = f.label :ident, t(:ident) + '*'
- .col-md-7
- - if ident_complete && @contact.persisted? && f.object.ident.present?
- = f.text_field :ident, value: f.object.ident, :readonly => true
- - else
- = f.text_field :ident, class: 'form-control', required: true
- - tip_visibility = f.object.ident_type == 'birthday' ? '' : 'display: none'
- .js-ident-tip{ style: tip_visibility }
- = t(:birthday_format)
-
-.panel.panel-default
- .panel-heading.clearfix
- .pull-left= t(:general)
- .panel-body
- .form-group
- .col-md-3.control-label
- = f.label :name, t(:name) + '*'
- .col-md-7
- = f.text_field :name, class: 'form-control', required: true
-
- .form-group
- .col-md-3.control-label
- = f.label :email, t(:email) + '*'
- .col-md-7
- = f.email_field :email, class: 'form-control', required: true,
- pattern: "[a-z0-9._%+-]+@[a-z0-9.-]+\.[a-z]{2,4}$"
-
- .form-group
- .col-md-3.control-label
- = f.label :phone, t(:phone) + '*'
- .col-md-7
- = f.text_field :phone, class: 'form-control',
- placeholder: '+372.12323344', required: true
diff --git a/app/views/registrar/contacts/form/_legal_document.haml b/app/views/registrar/contacts/form/_legal_document.haml
deleted file mode 100644
index 6507da1d9..000000000
--- a/app/views/registrar/contacts/form/_legal_document.haml
+++ /dev/null
@@ -1,13 +0,0 @@
-.form-group
- .col-md-10
-
-.panel.panel-default
- .panel-heading.clearfix
- .pull-left= t(:legal_document)
- .panel-body
- .form-group
- .col-md-3.control-label
- = f.label :legal_document, t(:legal_document)
- %p.help-block= t(:legal_document_max_size)
- .col-md-7
- = f.legal_document_field :legal_document
diff --git a/app/views/registrar/contacts/index.html.erb b/app/views/registrar/contacts/index.html.erb
deleted file mode 100644
index 4a7e8759a..000000000
--- a/app/views/registrar/contacts/index.html.erb
+++ /dev/null
@@ -1,77 +0,0 @@
-<% content_for :actions do %>
- <%= link_to(t(:new), new_registrar_contact_path, class: 'btn btn-primary') %>
-<% end %>
-<%= render 'shared/title', name: t(:contacts) %>
-
-
- <%= render 'search_form' %>
-
-
-
-
-
-
- <%= paginate @contacts %>
-
-
-
-
-
diff --git a/app/views/registrar/contacts/info_index.haml b/app/views/registrar/contacts/info_index.haml
deleted file mode 100644
index 8bec10ee0..000000000
--- a/app/views/registrar/contacts/info_index.haml
+++ /dev/null
@@ -1,19 +0,0 @@
-= render 'shared/title', name: t(:contacts_info)
-
-.row
- .col-md-12
- = form_tag registrar_contact_path, class: 'form-horizontal', method: :get do
- .form-group
- = label_tag :contact_id, t(:contact_id), class: 'col-md-2 control-label'
- .col-md-10
- = text_field_tag :contact_id, params[:contact_id], class: 'form-control', autocomplete: 'off'
- .form-group
- = label_tag :password, t(:password), class: 'col-md-2 control-label'
- .col-md-10
- = text_field_tag :password, params[:password], class: 'form-control', autocomplete: 'off'
- .form-group
- .col-md-offset-2.col-md-10
- %button.btn.btn-primary
-
- %span.glyphicon.glyphicon-search
-
diff --git a/app/views/registrar/contacts/list_pdf.html.erb b/app/views/registrar/contacts/list_pdf.html.erb
deleted file mode 100644
index b9bbb1c0e..000000000
--- a/app/views/registrar/contacts/list_pdf.html.erb
+++ /dev/null
@@ -1,34 +0,0 @@
-
-
-
-
-
-
-
-
-
- <%= Contact.human_attribute_name :name %>
- <%= Contact.human_attribute_name :code %>
- <%= Contact.human_attribute_name :ident %>
- <%= Contact.human_attribute_name :created_at %>
- <%= Registrar.model_name.human %>
-
-
-
-
- <% @contacts.each do |contact| %>
-
- <%= contact %>
- <%= contact.code %>
- <%= ident_for(contact) %>
- <%= l(contact.created_at, format: :short) %>
- <%= contact.registrar %>
-
- <% end %>
-
-
-
-
-
-
-
diff --git a/app/views/registrar/contacts/new.haml b/app/views/registrar/contacts/new.haml
deleted file mode 100644
index d554da015..000000000
--- a/app/views/registrar/contacts/new.haml
+++ /dev/null
@@ -1,5 +0,0 @@
-= render 'shared/title', name: t(:new_contact)
-
-= form_for(@contact, url: registrar_contacts_path,
- html: {class: 'form-horizontal js-contact-form'}) do |f|
- - render 'form', f: f
diff --git a/app/views/registrar/contacts/partials/_address.haml b/app/views/registrar/contacts/partials/_address.haml
deleted file mode 100644
index ce26b5667..000000000
--- a/app/views/registrar/contacts/partials/_address.haml
+++ /dev/null
@@ -1,23 +0,0 @@
-.panel.panel-default
- .panel-heading
- %h3.panel-title= t(:address)
- .panel-body
- %dl.dl-horizontal
- - if @contact.org_name.present?
- %dt= t(:org_name)
- %dd= @contact.org_name
-
- %dt= t(:street)
- %dd= @contact.street
-
- %dt= t(:city)
- %dd= @contact.city
-
- %dt= t(:zip)
- %dd= @contact.zip
-
- %dt= t(:state)
- %dd= @contact.state
-
- %dt= t(:country)
- %dd= @contact.country_name
diff --git a/app/views/registrar/contacts/partials/_domains.haml b/app/views/registrar/contacts/partials/_domains.haml
deleted file mode 100644
index cf721cb86..000000000
--- a/app/views/registrar/contacts/partials/_domains.haml
+++ /dev/null
@@ -1,31 +0,0 @@
-- domains = contact.all_domains(page: params[:domain_page], per: 20,
- params: domain_filter_params.to_h)
-.panel.panel-default
- .panel-heading
- .pull-left
- = t(:domains)
- .pull-right
- = form_tag request.path, method: :get do
- = select_tag :domain_filter, options_for_select(%w(Registrant AdminDomainContact TechDomainContact), selected: params[:domain_filter]),
- include_blank: true, class: 'form-control2 selectize2'
- %button.btn.btn-primary
- %span.glyphicon.glyphicon-search
- .clearfix
-
- .table-responsive
- %table.table.table-hover.table-bordered.table-condensed
- %thead
- %tr
- %th{class: 'col-xs-3'}=custom_sort_link t(:domain_name), :name
- %th{class: 'col-xs-3'}=custom_sort_link t(:registrar_name), :registrar_name
- %th{class: 'col-xs-3'}=custom_sort_link t(:valid_to), :valid_to
- %th{class: 'col-xs-3'}= t('.roles')
- %tbody
- - domains.each do |x|
- %tr
- %td= link_to(x.name, info_registrar_domains_path(domain_name: x.name))
- %td= x.registrar.name
- %td= l(x.valid_to, format: :short)
- %td= x.roles.join(", ")
-
-= paginate domains, param_name: :domain_page
diff --git a/app/views/registrar/contacts/partials/_general.haml b/app/views/registrar/contacts/partials/_general.haml
deleted file mode 100644
index 5fc8ec027..000000000
--- a/app/views/registrar/contacts/partials/_general.haml
+++ /dev/null
@@ -1,23 +0,0 @@
-.panel.panel-default
- .panel-heading
- %h3.panel-title= t(:general)
- .panel-body
- %dl.dl-horizontal
- %dt= t(:id)
- %dd= @contact.id
-
- %dt= Contact.human_attribute_name :auth_info
- %dd
- = tag :input, type: 'text', value: @contact.password, readonly: true,
- class: 'form-control input-sm'
-
- %br
-
- %dt= t(:ident)
- %dd= ident_for(@contact)
-
- %dt= t(:email)
- %dd= @contact.email
-
- %dt= t(:phone)
- %dd= @contact.phone
diff --git a/app/views/registrar/contacts/partials/_statuses.haml b/app/views/registrar/contacts/partials/_statuses.haml
deleted file mode 100644
index c926c04cf..000000000
--- a/app/views/registrar/contacts/partials/_statuses.haml
+++ /dev/null
@@ -1,14 +0,0 @@
-.panel.panel-default
- .panel-heading
- %h3.panel-title= t(:statuses)
- .table-responsive
- %table.table.table-hover.table-bordered.table-condensed
- %thead
- %tr
- %th{class: 'col-xs-6'}= t(:status)
- %th{class: 'col-xs-6'}= t(:description)
- %tbody
- - statuses.each do |s|
- %tr
- %td= s.first
- %td= s.second
diff --git a/app/views/registrar/contacts/show.haml b/app/views/registrar/contacts/show.haml
deleted file mode 100644
index 9fb23182d..000000000
--- a/app/views/registrar/contacts/show.haml
+++ /dev/null
@@ -1,19 +0,0 @@
-- if @contact.id.present?
- - content_for :actions do
- = link_to(t(:edit), edit_registrar_contact_path(@contact.id), class: 'btn btn-primary')
- = link_to(t(:delete), delete_registrar_contact_path(@contact.id), class: 'btn btn-default')
- = render 'shared/title', name: @contact.name
-
- .row
- .col-md-6= render 'registrar/contacts/partials/general'
- .col-md-6= render 'registrar/contacts/partials/address' if Contact.address_processing?
- .row
- .col-md-12= render 'registrar/contacts/partials/statuses', statuses: @contact.statuses
- .row
- - if @contact.ident.present?
- .col-md-12= render 'registrar/contacts/partials/domains', contact: Contact.find_by(code: params[:id])
-
-- else
- .row
- .col-sm-6
- %h1= t(:not_found)
diff --git a/app/views/registrar/deposits/new.haml b/app/views/registrar/deposits/new.haml
deleted file mode 100644
index abb04f916..000000000
--- a/app/views/registrar/deposits/new.haml
+++ /dev/null
@@ -1,28 +0,0 @@
-- content_for :actions do
- = link_to(t(:back_to_billing), registrar_invoices_path, class: 'btn btn-default')
-= render 'shared/title', name: t(:add_deposit)
-
-= form_for([:registrar, @deposit], method: :post, html: { class: 'form-horizontal' }) do |f|
- = render 'shared/full_errors', object: @deposit
-
- .row
- .col-md-8
- .form-group
- .col-md-4.control-label
- = f.label :amount, class: 'required'
- .col-md-7
- .input-group
- = f.text_field :amount, class: 'form-control', required: true
- .input-group-addon
- EUR
-
- .form-group
- .col-md-4.control-label
- = f.label :description
- .col-md-7
- = f.text_area :description, class: 'form-control'
-
- %hr
- .row
- .col-md-8.text-right
- = button_tag(t(:add), class: 'btn btn-warning')
diff --git a/app/views/registrar/domain_transfers/_form.html.erb b/app/views/registrar/domain_transfers/_form.html.erb
deleted file mode 100644
index 52dcca468..000000000
--- a/app/views/registrar/domain_transfers/_form.html.erb
+++ /dev/null
@@ -1,39 +0,0 @@
-<%= form_tag registrar_domain_transfers_path, multipart: true, class: 'form-horizontal' do %>
- <%= render 'registrar/domain_transfers/form/api_errors' %>
-
-
-
-
-
-
-
-
-<% end %>
diff --git a/app/views/registrar/domain_transfers/create.html.erb b/app/views/registrar/domain_transfers/create.html.erb
deleted file mode 100644
index bf258e476..000000000
--- a/app/views/registrar/domain_transfers/create.html.erb
+++ /dev/null
@@ -1,27 +0,0 @@
-
-
-
-
-
-
-
- <%= t(:result) %>
-
-
-
-
- <%= t(:domain_name) %>
- <%= @data.css('name').text %>
-
- <% @data.css('trnData').children.each do |x| %>
- <% next if x.blank? %>
- <%= t(x.name) %>
- <%= x.text %>
- <% end %>
-
-
-
-
-
diff --git a/app/views/registrar/domain_transfers/form/_api_errors.html.erb b/app/views/registrar/domain_transfers/form/_api_errors.html.erb
deleted file mode 100644
index 8d8862959..000000000
--- a/app/views/registrar/domain_transfers/form/_api_errors.html.erb
+++ /dev/null
@@ -1,13 +0,0 @@
-<% if @api_errors %>
-
-
- <% if @api_errors.is_a?(String) %>
- <%= @api_errors %>
- <% else %>
- <% @api_errors.each do |error| %>
- <%= error[:title] %>
- <% end %>
- <% end %>
-
-
-<% end %>
diff --git a/app/views/registrar/domain_transfers/new.html.erb b/app/views/registrar/domain_transfers/new.html.erb
deleted file mode 100644
index 52dd3f900..000000000
--- a/app/views/registrar/domain_transfers/new.html.erb
+++ /dev/null
@@ -1,11 +0,0 @@
-
-
-<%= render 'registrar/domain_transfers/form/api_errors' %>
-
-
-
- <%= render 'form' %>
-
-
diff --git a/app/views/registrar/domains/_check_form.haml b/app/views/registrar/domains/_check_form.haml
deleted file mode 100644
index 2468fa69a..000000000
--- a/app/views/registrar/domains/_check_form.haml
+++ /dev/null
@@ -1,10 +0,0 @@
-= form_tag check_registrar_domains_path, class: 'form-horizontal', method: :get do
- .col-md-11
- .form-group
- = text_field_tag :domain_name, params[:domain_name], class: 'form-control', placeholder: t(:domain_name), autocomplete: 'off'
- .col-md-1.text-right.text-center-xs
- .form-group
- %button.btn.btn-primary
-
- %span.glyphicon.glyphicon-search
-
diff --git a/app/views/registrar/domains/_domain.html.erb b/app/views/registrar/domains/_domain.html.erb
deleted file mode 100644
index 8cc6da6f7..000000000
--- a/app/views/registrar/domains/_domain.html.erb
+++ /dev/null
@@ -1,15 +0,0 @@
-
- <%= link_to truncate(domain.name), info_registrar_domains_path(domain_name: domain.name) %>
- <%= link_to domain.registrant, registrar_contact_path(id: domain.registrant.code) %>
- <%= l domain.expire_time %>
-
- <%= link_to t('.edit_btn'), edit_registrar_domains_path(domain_name: domain.name),
- class: 'btn btn-primary btn-xs' %>
- <%= link_to t('.renew_btn'), renew_registrar_domains_path(domain_name: domain.name),
- class: 'btn btn-default btn-xs' %>
- <% unless (domain.statuses & %w[pendingDelete pendingDeleteConfirmation]).any? %>
- <%= link_to t('.delete_btn'), delete_registrar_domains_path(domain_name: domain.name),
- class: 'btn btn-default btn-xs' %>
- <% end %>
-
-
diff --git a/app/views/registrar/domains/_form.haml b/app/views/registrar/domains/_form.haml
deleted file mode 100644
index 690d0ee06..000000000
--- a/app/views/registrar/domains/_form.haml
+++ /dev/null
@@ -1,30 +0,0 @@
-- path = (params[:domain_name]) ? update_registrar_domains_path : registrar_domains_path
-- legaldoc_mandatory = params[:domain_name].blank? && current_registrar_user.legaldoc_mandatory?
-= form_tag(path, class: 'form-horizontal', multipart: true) do
- .row
- .col-md-8
- #general-tab.tab-pane.active
- = render 'registrar/domains/form/general'
- = render 'registrar/domains/form/contacts'
- = render 'registrar/domains/form/nameservers'
- = render 'registrar/domains/form/dnskeys'
-
- .panel.panel-default
- .panel-heading.clearfix
- .pull-left= t(:legal_document)
- .panel-body
- .form-group
- .col-md-3.control-label
- - c, fr = 'required', true if legaldoc_mandatory
- = label_tag 'domain[legal_document]', t(:legal_document), class: c
- %p.help-block= t(:legal_document_max_size)
- .col-md-7
- = legal_document_field_tag 'domain[legal_document]', required: fr
- .col-md-4
- %p.domain-general-help= t(:domain_general_help).html_safe
- %p.domain-admin-contact-help= t(:domain_admin_contact_help).html_safe
- %p.domain-tech-contact-help= t(:domain_tech_contact_help).html_safe
-
- .row
- .col-md-8.text-right
- = button_tag(t('.save_btn'), class: 'btn btn-warning')
diff --git a/app/views/registrar/domains/_search_form.html.erb b/app/views/registrar/domains/_search_form.html.erb
deleted file mode 100644
index 584b15ba1..000000000
--- a/app/views/registrar/domains/_search_form.html.erb
+++ /dev/null
@@ -1,89 +0,0 @@
-<%= search_form_for [:registrar, @q], html: { class: 'search-form', autocomplete: 'off' } do |f| %>
-
-
-
- <%= f.label :name, for: nil %>
- <%= f.search_field :name_matches, value: search_params[:name_matches], class: 'form-control',
- placeholder: t(:name) %>
-
-
-
-
-
- <%= f.label :registrant_ident, for: nil %>
- <%= f.search_field :registrant_ident_eq, class: 'form-control', placeholder: t(:registrant_ident) %>
-
-
-
-
-
- <%= f.label :contact_ident, for: nil %>
- <%= f.search_field :contacts_ident_eq, value: search_params[:contacts_ident_eq],
- class: 'form-control', placeholder: t(:contact_ident) %>
-
-
-
-
-
- <%= f.label :nameserver_hostname, for: nil %>
- <%= f.search_field :nameservers_hostname_eq, class: 'form-control',
- placeholder: t(:nameserver_hostname) %>
-
-
-
-
-
-
-
- <%= label_tag :status, nil, for: nil %>
- <%= select_tag :statuses_contains,
- options_for_select(DomainStatus::STATUSES, params[:statuses_contains]),
- { multiple: true, class: 'form-control js-combobox' } %>
-
-
-
-
-
- <%= f.label :valid_to_gteq, for: nil %>
- <%= f.search_field :valid_to_gteq, value: search_params[:valid_to_gteq],
- class: 'form-control js-datepicker',
- placeholder: t(:valid_to_from) %>
-
-
-
-
-
- <%= f.label :valid_to_lteq, for: nil %>
- <%= f.search_field :valid_to_lteq, value: search_params[:valid_to_lteq],
- class: 'form-control js-datepicker',
- placeholder: t(:valid_to_until) %>
-
-
-
-
-
-
- <%= label_tag :results_per_page, nil, for: nil %>
-
-
-
-
-
-
- <%= text_field_tag :results_per_page, params[:results_per_page], class: 'form-control',
- placeholder: t(:results_per_page) %>
-
-
-
-
-
-
-
-
-
- <%= button_tag t('.download_btn'), formaction: registrar_domains_path(format: 'csv'),
- class: 'btn btn-default' %>
- <%= link_to t('.reset_btn'), registrar_domains_path, class: 'btn btn-default' %>
-
-
-<% end %>
diff --git a/app/views/registrar/domains/check.haml b/app/views/registrar/domains/check.haml
deleted file mode 100644
index f8ebfeaca..000000000
--- a/app/views/registrar/domains/check.haml
+++ /dev/null
@@ -1,25 +0,0 @@
-= render 'shared/title', name: t(:check_domain)
-
-.row
- .col-md-12
- = render 'check_form'
-
-%hr
-
-.row
- .col-md-12
- .panel.panel-default
- .panel-heading
- %h3.panel-title= t(:result)
- .panel-body
- %dl.dl-horizontal
- %dt= t(:name)
- %dd= @data.css('name').text
-
- - name = @data.css('name').first
- %dt= t(:available)
- %dd= name['avail']
-
- - if @data.css('reason').text.present?
- %dt= t(:reason)
- %dd= @data.css('reason').text
diff --git a/app/views/registrar/domains/check_index.haml b/app/views/registrar/domains/check_index.haml
deleted file mode 100644
index ee4bf074b..000000000
--- a/app/views/registrar/domains/check_index.haml
+++ /dev/null
@@ -1,5 +0,0 @@
-= render 'shared/title', name: t(:check_domain)
-
-.row
- .col-md-12
- = render 'check_form'
diff --git a/app/views/registrar/domains/delete.haml b/app/views/registrar/domains/delete.haml
deleted file mode 100644
index bea9ed118..000000000
--- a/app/views/registrar/domains/delete.haml
+++ /dev/null
@@ -1,25 +0,0 @@
-= render 'shared/title', name: "#{t(:delete)}: #{params[:domain_name]}"
-
-= form_tag(destroy_registrar_domains_path, class: 'form-horizontal', multipart: true, method: :delete) do
- .col-md-8
- .panel.panel-default
- .panel-heading.clearfix
- = t(:legal_document)
- .panel-body
- .form-group
- .col-md-4.control-label
- = label_tag 'domain[verified]', t(:verified)
- .col-md-6
- = check_box_tag 'domain[verified]', '1', params[:verified].eql?('1'), onclick: ("return (confirm('#{t(:verified_confirm)}') ? true : false);" if current_registrar_user.legaldoc_mandatory?)
-
- .form-group
- .col-md-4.control-label
- = label_tag 'domain[legal_document]', t(:legal_document)
- %p.help-block= t(:legal_document_max_size)
- .col-md-6
- = file_field_tag 'domain[legal_document]'
- = hidden_field_tag 'domain[name]', params[:domain_name]
- %hr
- .row
- .col-md-8.text-right
- = button_tag t(:delete), class: 'btn btn-danger'
diff --git a/app/views/registrar/domains/edit.haml b/app/views/registrar/domains/edit.haml
deleted file mode 100644
index 4b8d5db6b..000000000
--- a/app/views/registrar/domains/edit.haml
+++ /dev/null
@@ -1,3 +0,0 @@
-= render 'shared/title', name: "#{t(:edit)}: #{params[:domain_name]}"
-
-= render 'form'
diff --git a/app/views/registrar/domains/form/_contacts.haml b/app/views/registrar/domains/form/_contacts.haml
deleted file mode 100644
index 8e01ffda3..000000000
--- a/app/views/registrar/domains/form/_contacts.haml
+++ /dev/null
@@ -1,44 +0,0 @@
-#js-domain-contacts
- - @domain_params['contacts_attributes'].each do |k, v|
- .js-contact
- .panel.panel-default
- .panel-heading.clearfix
- .pull-left= t(:contact)
- .pull-right
- = link_to(t(:add_another), '#', class: 'btn btn-default btn-xs add-domain-contact')
- = link_to(t(:delete), '#', class: 'btn btn-default btn-xs destroy')
- .panel-body
- .form-group
- .col-md-3.control-label
- = label_tag "domain_contacts_attributes_#{k}_type", t(:contact_type), class: 'required'
- .col-md-7
- = select_tag "domain[contacts_attributes][#{k}][type]", options_for_select(['admin', 'tech'], v['type']), {class: 'form-control js-contact-type'}
-
- .form-group
- .col-md-3.control-label
- = label_tag "domain_contacts_attributes_#{k}_code", t(:id), class: 'required'
- .col-md-7.has-feedback
- = text_field_tag "domain[contacts_attributes][#{k}][code]", v['code'], class: "hidden"
- = text_field_tag "domain[contacts_attributes][#{k}][code_helper]", contacts.find_by(code: v['code']).try(:search_name), class: 'form-control', data: {autocomplete: search_contacts_registrar_domains_path}, required: true
-
-:coffee
- load_listener = ->
- clone = $('.js-contact:first').clone()
- $("#js-domain-contacts").nestedAttributes
- bindAddTo: $(".add-domain-contact")
- afterAdd: (item) ->
- # preselect type
- item.find('select.js-contact-type').each (k, v) ->
- $(v).val($(v).find('option:last-child').val())
- # add combobex
- item.find('select.js-contact-code').each (k, v) ->
- $(v).select2
- width: "100%"
- selectOnBlur: true
- dropdownAutoWidth: if self==top then true else false
- # remove link for temp
- item.find('a.add-domain-contact').each (k, v) ->
- $(v).hide()
- new Autocomplete()
- $clone: clone
- window.addEventListener 'load', load_listener
diff --git a/app/views/registrar/domains/form/_dnskeys.haml b/app/views/registrar/domains/form/_dnskeys.haml
deleted file mode 100644
index 630e16303..000000000
--- a/app/views/registrar/domains/form/_dnskeys.haml
+++ /dev/null
@@ -1,77 +0,0 @@
-#dnskeys
- - @domain_params['dnskeys_attributes'].each do |k, v|
- .panel.panel-default
- .panel-heading.clearfix
- .pull-left= t(:dnskey)
- .pull-right
- = link_to(t(:add_another), '#', class: 'btn btn-default btn-xs add-dnskey')
- = link_to(t(:delete), '#', class: 'btn btn-default btn-xs destroy')
- .panel-body
- - if ENV['show_ds_data_fields'] == 'true'
- .form-group
- .col-md-3.control-label
- = label_tag "domain_dnskeys_attributes_#{k}_ds_key_tag", t(:ds_key_tag)
- .col-md-7
- = text_field_tag "domain[dnskeys_attributes][#{k}][ds_key_tag]", v['ds_key_tag'],
- {class: 'form-control'}
-
- .form-group
- .col-md-3.control-label
- = label_tag "domain_dnskeys_attributes_#{k}_ds_alg", t(:ds_algorithm)
- .col-md-7
- = select_tag "domain[dnskeys_attributes][#{k}][ds_alg]",
- options_for_select(Depp::Dnskey::ALGORITHMS, v['ds_alg']), {class: 'form-control'}
-
- .form-group
- .col-md-3.control-label
- = label_tag "domain_dnskeys_attributes_#{k}_ds_digest_type", t(:ds_digest_type)
- .col-md-7
- = select_tag "domain[dnskeys_attributes][#{k}][ds_digest_type]",
- options_for_select(Depp::Dnskey::DS_DIGEST_TYPES, v['ds_digest_type']),
- {class: 'form-control'}
-
- .form-group
- .col-md-3.control-label
- = label_tag "domain_dnskeys_attributes_#{k}_ds_digest", t(:ds_digest)
- .col-md-7
- = text_field_tag "domain[dnskeys_attributes][#{k}][ds_digest]", v['ds_digest'],
- {class: 'form-control'}
-
- .form-group
- .col-md-3.control-label
- = label_tag "domain_dnskeys_attributes_#{k}_flags", t('.flags')
- .col-md-7
- = select_tag "domain[dnskeys_attributes][#{k}][flags]",
- options_for_select(Depp::Dnskey::FLAGS, v['flags']),
- { class: 'form-control' }
-
- .form-group
- .col-md-3.control-label
- = label_tag "domain_dnskeys_attributes_#{k}_protocol", t(:protocol)
- .col-md-7
- = select_tag "domain[dnskeys_attributes][#{k}][protocol]",
- options_for_select(Depp::Dnskey::PROTOCOLS, v['protocol']),
- { class: 'form-control' }
-
- .form-group
- .col-md-3.control-label
- = label_tag "domain_dnskeys_attributes_#{k}_alg", t('.alg')
- .col-md-7
- = select_tag "domain[dnskeys_attributes][#{k}][alg]",
- options_for_select(Depp::Dnskey::ALGORITHMS, v['alg']), { class: 'form-control' }
-
- .form-group
- .col-md-3.control-label
- = label_tag "domain_dnskeys_attributes_#{k}_public_key", t(:public_key)
- .col-md-7
- = text_field_tag "domain[dnskeys_attributes][#{k}][public_key]", v['public_key'],
- class: 'form-control'
-
-:coffee
- load_listener = ->
- $("#dnskeys").nestedAttributes
- bindAddTo: $(".add-dnskey")
- afterAdd: (item) ->
- item.find('select').each (k, v) ->
- $(v).val($(v).find('option:first-child').val())
- window.addEventListener 'load', load_listener
diff --git a/app/views/registrar/domains/form/_general.haml b/app/views/registrar/domains/form/_general.haml
deleted file mode 100644
index 5fa4d2a89..000000000
--- a/app/views/registrar/domains/form/_general.haml
+++ /dev/null
@@ -1,39 +0,0 @@
-.general-tab.panel.panel-default
- .panel-body
- .form-group
- .col-md-3.control-label
- = label_tag :domain_name, t(:name), class: 'required'
- .col-md-7
- - readonly = params[:domain_name] ? true : false
- = text_field_tag('domain[name]', @domain_params[:name],
- class: 'form-control', readonly: readonly, required: true)
-
- - unless params[:domain_name]
- .form-group
- .col-md-3.control-label
- = label_tag :domain_period, t(:period), class: 'required'
- .col-md-7
- = select_tag 'domain[period]',
- options_for_select(Depp::Domain::PERIODS, @domain_params[:period]), { class: 'form-control' }
-
- .form-group
- .col-md-3.control-label
- = label_tag :domain_registrant, t('.registrant'), class: 'required'
- .col-md-7
- = text_field_tag 'domain[registrant]', @domain_params[:registrant], class: "hidden"
- = text_field_tag 'domain[registrant_helper]', contacts.find_by(code: @domain_params[:registrant]).try(:search_name),
- class: 'form-control', data: {autocomplete: search_contacts_registrar_domains_path}, required: true
-
- - if params[:domain_name]
- .form-group
- .col-md-3.control-label
- = label_tag :verified, t(:verified)
- .col-md-7
- = check_box_tag 'domain[verified]', '1', @domain_params[:verified].eql?('1'), onclick: "return (confirm('#{t(:verified_confirm)}') ? true : false);"
-
- - if !params[:domain_name] || @dispute.present?
- .form-group
- .col-md-3.control-label
- = label_tag :domain_reserved_pw, t(:reserved_pw)
- .col-md-7
- = text_field_tag('domain[reserved_pw]', @domain_params[:reserved_pw], class: 'form-control')
diff --git a/app/views/registrar/domains/form/_nameservers.haml b/app/views/registrar/domains/form/_nameservers.haml
deleted file mode 100644
index 75d34b924..000000000
--- a/app/views/registrar/domains/form/_nameservers.haml
+++ /dev/null
@@ -1,33 +0,0 @@
-#nameservers
- - @domain_params['nameservers_attributes'].each do |k, v|
- .panel.panel-default
- .panel-heading.clearfix
- .pull-left= t(:nameserver)
- .pull-right
- = link_to(t(:add_another), '#', class: 'btn btn-default btn-xs add-nameserver')
- = link_to(t(:delete), '#', class: 'btn btn-default btn-xs destroy')
- .panel-body
- .form-group
- .col-md-3.control-label
- = label_tag "domain_nameservers_attributes_#{k}_hostname", t(:hostname),
- class: Domain.nameserver_required? ? 'required' : nil
- .col-md-7
- = text_field_tag "domain[nameservers_attributes][#{k}][hostname]", v['hostname'],
- class: 'form-control', required: Domain.nameserver_required?
- .form-group
- .col-md-3.control-label
- = label_tag "domain_nameservers_attributes_#{k}_ipv4", t(:ipv4)
- .col-md-7
- = text_field_tag "domain[nameservers_attributes][#{k}][ipv4]", v['ipv4'],
- class: 'form-control'#, ipv4: true
- .form-group
- .col-md-3.control-label
- = label_tag "domain_nameservers_attributes_#{k}_ipv6", t(:ipv6)
- .col-md-7
- = text_field_tag "domain[nameservers_attributes][#{k}][ipv6]", v['ipv6'],
- class: 'form-control'#, ipv6: true
-:coffee
- load_listener = ->
- $("#nameservers").nestedAttributes
- bindAddTo: $(".add-nameserver")
- window.addEventListener 'load', load_listener
diff --git a/app/views/registrar/domains/index.html.erb b/app/views/registrar/domains/index.html.erb
deleted file mode 100644
index c643fd613..000000000
--- a/app/views/registrar/domains/index.html.erb
+++ /dev/null
@@ -1,59 +0,0 @@
-
-
-
-
- <%= render 'search_form' %>
-
-
-
-
-
-
-
-
-
-
- <%= sort_link(@q, 'name') %>
-
-
- <%= sort_link @q, 'registrant_name', Registrant.model_name.human %>
-
-
- <%= sort_link @q, 'valid_to', Domain.human_attribute_name(:expire_time) %>
-
-
-
-
-
-
- <%= render partial: 'domain', collection: @domains %>
-
-
-
-
-
-
-
-
- <%= paginate @domains %>
-
-
-
-
-
-
diff --git a/app/views/registrar/domains/info.html.erb b/app/views/registrar/domains/info.html.erb
deleted file mode 100644
index c2f219bf9..000000000
--- a/app/views/registrar/domains/info.html.erb
+++ /dev/null
@@ -1,59 +0,0 @@
-<% content_for :actions do %>
- <% if @data.css('pw').text.present? %>
- <%= link_to(t(:edit), edit_registrar_domains_path(domain_name: params[:domain_name]),
- class: 'btn btn-default') %>
- <%= link_to(t(:renew), renew_registrar_domains_path(domain_name: params[:domain_name]),
- class: 'btn btn-default') %>
- <% unless @pending_delete %>
- <%= link_to(t(:delete), delete_registrar_domains_path(domain_name: params[:domain_name]),
- class: 'btn btn-default') %>
- <% end %>
- <% if @client_holded %>
- <%= link_to(t(:remove_client_hold), remove_hold_registrar_domains_path(domain_name: params[:domain_name]),
- class: 'btn btn-default') %>
- <% end %>
- <% else %>
- <%= link_to t('.transfer_btn'), new_registrar_domain_transfer_path(domain_name: params[:domain_name]),
- class: 'btn btn-default' %>
- <% end %>
-<% end %>
-<%= render 'shared/title', name: truncate(@data.css('name').text) %>
-
-
- <% if @data.css('result').first['code'] == '1000' %>
-
-
- <%= render 'registrar/domains/partials/general' %>
-
-
-
-
- <%= render 'registrar/domains/partials/contacts' %>
-
-
-
-
- <%= render 'registrar/domains/partials/statuses' %>
-
-
-
-
- <%= render 'registrar/domains/partials/nameservers' %>
-
-
-
-
- <%= render 'registrar/domains/partials/dnskeys' %>
-
-
- <% else %>
-
-
-
- <%= t(:not_found) %>
-
-
-
- <% end %>
-
-
diff --git a/app/views/registrar/domains/new.haml b/app/views/registrar/domains/new.haml
deleted file mode 100644
index 50808df22..000000000
--- a/app/views/registrar/domains/new.haml
+++ /dev/null
@@ -1,3 +0,0 @@
-= render 'shared/title', name: t(:new_domain)
-
-= render 'form'
diff --git a/app/views/registrar/domains/partials/_contacts.haml b/app/views/registrar/domains/partials/_contacts.haml
deleted file mode 100644
index e6ef9aa8f..000000000
--- a/app/views/registrar/domains/partials/_contacts.haml
+++ /dev/null
@@ -1,17 +0,0 @@
-.panel.panel-default
- .panel-heading.clearfix
- %h3.panel-title= t(:contacts)
- .table-responsive
- %table.table.table-hover.table-bordered.table-condensed
- %thead
- %tr
- %th{class: 'col-xs-4'}= t(:type)
- %th{class: 'col-xs-4'}= t(:name)
- %th{class: 'col-xs-4'}= t(:id)
- %tbody
- - @data.css('contact').each do |x|
- - registrant = Contact.find_by_code(x.text)
- %tr
- %td= x['type']
- %td= registrant.registrar == current_registrar_user.registrar ? registrant.name : 'N/A'
- %td= x.text
diff --git a/app/views/registrar/domains/partials/_dnskeys.haml b/app/views/registrar/domains/partials/_dnskeys.haml
deleted file mode 100644
index 7e8e5b940..000000000
--- a/app/views/registrar/domains/partials/_dnskeys.haml
+++ /dev/null
@@ -1,66 +0,0 @@
-.panel.panel-default
- .panel-heading
- %h3.panel-title= t(:dnskeys)
- .panel-body{style: 'word-wrap: break-word;'}
- .table-responsive
- %table.table.table-hover.table-condensed
- %tbody
- - @data.css('dsData').each_with_index do |x, index|
- - if x.css('digest').text.present?
- %tr
- %td
- %b= "#{t(:ds_key_tag)}:"
- = x.css('keyTag').text
- %tr
- %td
- %b= "#{t(:ds_algorithm)}:"
- = x.css('alg').first.text
- %tr
- %td
- %b= "#{t(:ds_digest_type)}:"
- = x.css('digestType').text
- %tr
- %td
- %b= "#{t(:ds_digest)}:"
- = x.css('digest').text
- %tr
- %td
- %b= "#{t(:flag)}:"
- = x.css('keyData').css('flags').text
- %tr
- %td
- %b= "#{t(:protocol)}:"
- = x.css('keyData').css('protocol').text
- %tr
- %td
- %b= "#{t(:algorithm)}:"
- = x.css('alg').last.text
- %tr
- %td{:colspan => "3"}
- %b= "#{t(:public_key)}:"
- = x.css('keyData').css('pubKey').text
- - if index != @data.css('keyData').size - 1
- %tr
- %td{:colspan => "3"}
- = " ".html_safe
-
- - if @data.css('dsData').empty?
- - @data.css('keyData').each_with_index do |x, index|
- %tr
- %td
- %b= "#{t(:flag)}:"
- = x.css('flags').text
- %td
- %b= "#{t(:protocol)}:"
- = x.css('protocol').text
- %td
- %b= "#{t(:algorithm)}:"
- = x.css('alg').text
- %tr
- %td{:colspan => "3"}
- %b= "#{t(:public_key)}:"
- = x.css('pubKey').text
- - if index != @data.css('keyData').size - 1
- %tr
- %td{:colspan => "3"}
- = " ".html_safe
\ No newline at end of file
diff --git a/app/views/registrar/domains/partials/_general.html.erb b/app/views/registrar/domains/partials/_general.html.erb
deleted file mode 100644
index ff064857c..000000000
--- a/app/views/registrar/domains/partials/_general.html.erb
+++ /dev/null
@@ -1,41 +0,0 @@
-
-
-
- <%= t(:general) %>
-
-
-
-
-
- <%= Domain.human_attribute_name :transfer_code %>
-
- <% if @data.css('pw').text.present? %>
- <%= tag(:input, type: 'text', value: @data.css('pw').text, readonly: true,
- class: 'form-control input-sm') %>
- <% end %>
-
-
-
- <% if @data.css('pw').text.blank? %>
- <%= t(:registrar_name) %>
- <%= @data.css('clID').text %>
- <% end %>
-
- <% registrant = Contact.find_by_code(@data.css('registrant').text) %>
- <%= t('.registrant') %>
- <%= registrant.registrar == current_registrar_user.registrar ? "#{registrant.name} (#{@data.css('registrant').text})" : @data.css('registrant').text %>
-
- <%= t('.registered') %>
- <%= @data.css('crDate').text %>
-
- <%= t(:valid_to) %>
- <%= @data.css('exDate').text %>
-
- <%= t('.created') %>
- <%= @data.css('crDate').text %>
-
- <%= t('.updated') %>
- <%= @data.css('upDate').text %>
-
-
-
diff --git a/app/views/registrar/domains/partials/_nameservers.haml b/app/views/registrar/domains/partials/_nameservers.haml
deleted file mode 100644
index 69f147bc4..000000000
--- a/app/views/registrar/domains/partials/_nameservers.haml
+++ /dev/null
@@ -1,17 +0,0 @@
-.panel.panel-default
- .panel-heading.clearfix
- %h3.panel-title= t(:nameservers)
- .table-responsive
- %table.table.table-hover.table-bordered.table-condensed
- %thead
- %tr
- %th{class: 'col-xs-4'}= t(:hostname)
- %th{class: 'col-xs-4'}= t(:ipv4)
- %th{class: 'col-xs-4'}= t(:ipv6)
- %tbody
- - @data.css('hostAttr').each do |x|
- %tr
- %td= x.css('hostName').text
- %td= Array(x.css('hostAddr[ip="v4"]')).map(&:text).join(", ")
- %td= Array(x.css('hostAddr[ip="v6"]')).map(&:text).join(", ")
-
diff --git a/app/views/registrar/domains/partials/_statuses.haml b/app/views/registrar/domains/partials/_statuses.haml
deleted file mode 100644
index 125309caf..000000000
--- a/app/views/registrar/domains/partials/_statuses.haml
+++ /dev/null
@@ -1,14 +0,0 @@
-#domain_statuses.panel.panel-default
- .panel-heading.clearfix
- %h3.panel-title= t(:statuses)
- .table-responsive
- %table.table.table-hover.table-bordered.table-condensed
- %thead
- %tr
- %th{class: 'col-xs-6'}= t(:status)
- %th{class: 'col-xs-6'}= t(:notes)
- %tbody
- - @data.css('status').each do |x|
- %tr
- %td= x['s']
- %td= x.text
diff --git a/app/views/registrar/domains/renew.haml b/app/views/registrar/domains/renew.haml
deleted file mode 100644
index aebcac4b4..000000000
--- a/app/views/registrar/domains/renew.haml
+++ /dev/null
@@ -1,14 +0,0 @@
-= render 'shared/title', name: t(:renew_domain)
-
-.row
- .col-md-8
- .panel.panel-default
- .panel-heading
- %h3.panel-title= t(:result)
- .panel-body
- %dl.dl-horizontal
- %dt= t(:domain_name)
- %dd= @data.css('name').text
-
- %dt= t(:valid_to)
- %dd= @data.css('exDate').text
diff --git a/app/views/registrar/domains/renew_index.haml b/app/views/registrar/domains/renew_index.haml
deleted file mode 100644
index 92f7a8108..000000000
--- a/app/views/registrar/domains/renew_index.haml
+++ /dev/null
@@ -1,30 +0,0 @@
-= render 'shared/title', name: t(:renew_domain)
-
-.row
- .col-md-8
- = form_tag renew_registrar_domains_path, class: 'form-horizontal', method: :get do
- .form-group
- .col-md-3.control-label
- = label_tag :domain_name, t(:name), class: 'required'
- .col-md-7
- = text_field_tag :domain_name, params[:domain_name],
- class: 'form-control', placeholder: t(:domain_name), autocomplete: 'off', required: true
-
- .form-group
- .col-md-3.control-label
- = label_tag :cur_exp_date, t(:cur_exp_date), class: 'required'
- .col-md-7
- = text_field_tag :cur_exp_date, params[:cur_exp_date],
- class: 'form-control', placeholder: 'yyyy-mm-dd', autocomplete: 'off', required: true
-
- .form-group
- .col-md-3.control-label
- = label_tag :domain_period, t(:period), class: 'required'
- .col-md-7
- = select_tag :period,
- options_for_select(Depp::Domain::PERIODS, params[:period]), { class: 'form-control' }
-
- %hr
- .form-group
- .col-md-10.text-right
- %button.btn.btn-warning= t(:renew)
diff --git a/app/views/registrar/invoices/delivery/new.html.erb b/app/views/registrar/invoices/delivery/new.html.erb
deleted file mode 100644
index 20db81418..000000000
--- a/app/views/registrar/invoices/delivery/new.html.erb
+++ /dev/null
@@ -1,25 +0,0 @@
-
- <%= link_to t('registrar.invoices.index.header'), registrar_invoices_path %>
- <%= link_to @invoice, registrar_invoice_path(@invoice) %>
-
-
-
-
-<%= form_tag(registrar_invoice_delivery_path(@invoice)) do %>
-
-
-
- <%= label_tag :recipient %>
- <%= email_field_tag :recipient, @recipient, required: true, autofocus: true,
- class: 'form-control' %>
-
-
-
- <%= submit_tag t('.submit_btn'), class: 'btn btn-warning' %>
-
-
-
-
-<% end %>
\ No newline at end of file
diff --git a/app/views/registrar/invoices/index.haml b/app/views/registrar/invoices/index.haml
deleted file mode 100644
index cc15beeb8..000000000
--- a/app/views/registrar/invoices/index.haml
+++ /dev/null
@@ -1,73 +0,0 @@
-- content_for :actions do
- = link_to(t(:add_deposit), new_registrar_deposit_path, class: 'btn btn-primary')
- = link_to(t(:account_activity), registrar_account_activities_path, class: 'btn btn-default')
-= render 'shared/title', name: t(:your_account)
-
-= t(:your_current_account_balance_is,
- balance: currency(current_registrar_user.registrar.cash_account.balance),
- currency: current_registrar_user.registrar.cash_account.currency)
-
-%h1= t(:invoices)
-.row
- .col-md-12
- %hr
- = search_form_for @q, url: [:registrar, :invoices], html: { style: 'margin-bottom: 0;' } do |f|
- .row
- .col-md-3
- .form-group
- = f.label t(:minimum_invoice_no)
- = f.search_field :number_gteq, class: 'form-control', placeholder: t(:minimum_invoice_no), autocomplete: 'off'
- .col-md-3
- .form-group
- = f.label t(:maximum_invoice_no)
- = f.search_field :number_lteq, class: 'form-control', placeholder: t(:maximum_invoice_no), autocomplete: 'off'
- .col-md-3
- .form-group
- = f.label t(:due_date_from)
- = f.search_field :due_date_gteq, value: params[:q][:due_date_gteq], class: 'form-control js-datepicker', placeholder: t(:due_date_from)
- .col-md-3
- .form-group
- = f.label t(:due_date_until)
- = f.search_field :due_date_lteq, value: params[:q][:due_date_lteq], class: 'form-control js-datepicker', placeholder: t(:due_date_until)
- .row
- .col-md-3
- .form-group
- = f.label t(:minimum_total)
- = f.search_field :total_gteq, class: 'form-control', placeholder: t(:minimum_total), autocomplete: 'off'
- .col-md-3
- .form-group
- = f.label t(:maximum_total)
- = f.search_field :total_lteq, class: 'form-control', placeholder: t(:maximum_total), autocomplete: 'off'
- .col-md-3{style: 'padding-top: 25px;'}
- %button.btn.btn-default
-
- %span.glyphicon.glyphicon-search
-
- = link_to(t('.reset_btn'), registrar_invoices_path, class: 'btn btn-default')
-%hr
-.row
- .col-md-12
- .table-responsive
- %table.table.table-hover.table-condensed
- %thead
- %tr
- %th{class: 'col-xs-3'}= t('invoice.title')
- %th{class: 'col-xs-3'}= Invoice.human_attribute_name :receipt_date
- %th{class: 'col-xs-3'}= t(:due_date)
- %th{class: 'col-xs-3'}= t(:total)
- %tbody
- - @invoices.each do |invoice|
- %tr
- %td= link_to(invoice, [:registrar, invoice])
- - if invoice.paid?
- %td= l invoice.receipt_date
- - elsif invoice.cancelled?
- %td.text-grey= t(:cancelled)
- - else
- %td{class: 'text-danger'}= t(:unpaid)
-
- %td= l invoice.due_date
- %td= currency(invoice.total)
-.row
- .col-md-12
- = paginate @invoices
diff --git a/app/views/registrar/invoices/partials/_banklinks.haml b/app/views/registrar/invoices/partials/_banklinks.haml
deleted file mode 100644
index 339ae4705..000000000
--- a/app/views/registrar/invoices/partials/_banklinks.haml
+++ /dev/null
@@ -1,8 +0,0 @@
-%h4= t('registrar.invoices.pay_invoice')
-%hr
-
- - if @invoice.payment_link.present?
- = link_to @invoice.payment_link, target: :_blank do
- = image_tag("everypay.png", class: 'everypay', style: "width: 100px; height: 20px;")
- - else
- = "No everypay link"
diff --git a/app/views/registrar/invoices/partials/_buyer.haml b/app/views/registrar/invoices/partials/_buyer.haml
deleted file mode 100644
index 30824ff01..000000000
--- a/app/views/registrar/invoices/partials/_buyer.haml
+++ /dev/null
@@ -1,23 +0,0 @@
-%h4= t(:buyer)
-%hr
-%dl.dl-horizontal
- %dt= t(:name)
- %dd= @invoice.buyer_name
-
- %dt= t(:reg_no)
- %dd= @invoice.buyer_reg_no
-
- %dt= t(:address)
- %dd= @invoice.buyer_address
-
- %dt= t(:country)
- %dd= @invoice.buyer_country
-
- %dt= t(:phone)
- %dd= @invoice.buyer_phone
-
- %dt= t(:url)
- %dd= @invoice.buyer_url
-
- %dt= t(:email)
- %dd= @invoice.buyer_email
diff --git a/app/views/registrar/invoices/partials/_details.haml b/app/views/registrar/invoices/partials/_details.haml
deleted file mode 100644
index c5e6193a4..000000000
--- a/app/views/registrar/invoices/partials/_details.haml
+++ /dev/null
@@ -1,36 +0,0 @@
-%h4= t(:details)
-%hr
-%dl.dl-horizontal
- %dt= t(:issue_date)
- %dd= l @invoice.issue_date
-
- - if @invoice.cancelled?
- %dt= Invoice.human_attribute_name :cancelled_at
- %dd= l @invoice.cancelled_at
-
- %dt= t(:due_date)
- - if @invoice.cancelled?
- %dd.text-grey= t(:cancelled)
- - else
- %dd= l @invoice.due_date
-
- %dt= Invoice.human_attribute_name :receipt_date
- - if @invoice.paid?
- %dd= l @invoice.receipt_date
- - elsif @invoice.cancelled?
- %dd.text-grey= t(:cancelled)
- - else
- %dd{class: 'text-danger'}= t(:unpaid)
-
- %dt= t(:payment_term)
- %dd Prepayment
-
- %dt= t(:invoice_number)
- %dd= @invoice.number
-
- - if @invoice.description.present?
- %dt= t(:description)
- %dd=@invoice.description
-
- %dt= Invoice.human_attribute_name :reference_no
- %dd= @invoice.reference_no
diff --git a/app/views/registrar/invoices/partials/_items.haml b/app/views/registrar/invoices/partials/_items.haml
deleted file mode 100644
index 26985b1c1..000000000
--- a/app/views/registrar/invoices/partials/_items.haml
+++ /dev/null
@@ -1,32 +0,0 @@
-%h4= t(:items)
-%hr
-.table-responsive
- %table.table.table-hover.table-condensed
- %thead
- %tr
- %th{class: 'col-xs-4'}= t(:description)
- %th{class: 'col-xs-2'}= t(:unit)
- %th{class: 'col-xs-2'}= InvoiceItem.human_attribute_name :quantity
- %th{class: 'col-xs-2'}= t(:price)
- %th{class: 'col-xs-2'}= t(:total)
- %tbody
- - @invoice.each do |invoice_item|
- %tr
- %td= invoice_item.description
- %td= invoice_item.unit
- %td= invoice_item.quantity
- %td= currency(invoice_item.price)
- %td= currency(invoice_item.item_sum_without_vat)
- %tfoot
- %tr
- %th{colspan: 3}
- %th= Invoice.human_attribute_name :subtotal
- %td= number_to_currency @invoice.subtotal
- %tr
- %th.no-border{colspan: 3}
- %th= "VAT #{number_to_percentage(@invoice.vat_rate, precision: 1)}"
- %td= number_to_currency @invoice.vat_amount
- %tr
- %th.no-border{colspan: 3}
- %th= t(:total)
- %td= number_to_currency @invoice.total
diff --git a/app/views/registrar/invoices/partials/_payment_orders.haml b/app/views/registrar/invoices/partials/_payment_orders.haml
deleted file mode 100644
index d418ea1ac..000000000
--- a/app/views/registrar/invoices/partials/_payment_orders.haml
+++ /dev/null
@@ -1,19 +0,0 @@
-%h4= "Payment Orders"
-%hr
-.table-responsive
- %table.table.table-hover.table-condensed
- %thead
- %tr
- %th{class: 'col-xs-1'}= "#"
- %th{class: 'col-xs-1'}= "Channel"
- %th{class: 'col-xs-2'}= "Status"
- %th{class: 'col-xs-3'}= "Initiated"
- %th{class: 'col-xs-4'}= "Notes"
- %tbody
- - @invoice.payment_orders.each do |payment_order|
- %tr
- %td= payment_order.id
- %td= payment_order.channel
- %td= payment_order.status
- %td= payment_order.created_at
- %td= payment_order.notes
diff --git a/app/views/registrar/invoices/partials/_seller.haml b/app/views/registrar/invoices/partials/_seller.haml
deleted file mode 100644
index 30f27bcef..000000000
--- a/app/views/registrar/invoices/partials/_seller.haml
+++ /dev/null
@@ -1,38 +0,0 @@
-%h4= t(:seller)
-%hr
-%dl.dl-horizontal
- %dt= t(:name)
- %dd= @invoice.seller_name
-
- %dt= Registrar.human_attribute_name :reg_no
- %dd= @invoice.seller_reg_no
-
- %dt= t(:iban)
- %dd= @invoice.seller_iban
-
- %dt= t(:bank)
- %dd= @invoice.seller_bank
-
- %dt= t(:swift)
- %dd= @invoice.seller_swift
-
- %dt= Registrar.human_attribute_name :vat_no
- %dd= @invoice.seller_vat_no
-
- %dt= t(:address)
- %dd= @invoice.seller_address
-
- %dt= t(:country)
- %dd= @invoice.seller_country
-
- %dt= t(:phone)
- %dd= @invoice.seller_phone
-
- %dt= t(:url)
- %dd= @invoice.seller_url
-
- %dt= t(:email)
- %dd= @invoice.seller_email
-
- %dt= t(:issuer)
- %dd= @invoice.seller_contact_name
diff --git a/app/views/registrar/invoices/show.haml b/app/views/registrar/invoices/show.haml
deleted file mode 100644
index 5e6104091..000000000
--- a/app/views/registrar/invoices/show.haml
+++ /dev/null
@@ -1,20 +0,0 @@
-- content_for :actions do
- = link_to(t('.download_btn'), download_registrar_invoice_path(@invoice), class: 'btn btn-default')
- = link_to(t('.deliver_btn'), new_registrar_invoice_delivery_path(@invoice), class: 'btn btn-default')
- - if @invoice.cancellable?
- = link_to(t(:cancel), cancel_registrar_invoice_path(@invoice), method: :patch, class: 'btn btn-warning')
- = link_to(t(:back), registrar_invoices_path, class: 'btn btn-default')
-= render 'shared/title', name: @invoice.to_s
-= render 'shared/full_errors', object: @invoice
-
-.row
- .col-md-6= render 'registrar/invoices/partials/details'
-.row
- .col-md-6= render 'registrar/invoices/partials/seller'
- .col-md-6= render 'registrar/invoices/partials/buyer'
-.row
- .col-md-12= render 'registrar/invoices/partials/items'
-
-- if @invoice.payable?
- .row.semifooter
- .col-md-6-offset-6.text-right= render 'registrar/invoices/partials/banklinks', locals: { payment_channels: PaymentOrder::CUSTOMER_PAYMENT_METHODS }
diff --git a/app/views/registrar/payments/pay.html.haml b/app/views/registrar/payments/pay.html.haml
deleted file mode 100644
index dd3fc982f..000000000
--- a/app/views/registrar/payments/pay.html.haml
+++ /dev/null
@@ -1,14 +0,0 @@
-.h3
- = t('registrar.invoices.redirected_to_intermediary')
-
-.payment-form
- = form_tag @payment_order.form_url, method: :post do
- - @payment_order.form_fields.each do |k, v|
- = hidden_field_tag k, v
- = submit_tag t('registrar.invoices.go_to_intermediary')
-
-:javascript
- function load_listener() {
- $('.payment-form form').submit();
- }
- window.addEventListener('load', load_listener)
diff --git a/app/views/registrar/polls/show.haml b/app/views/registrar/polls/show.haml
deleted file mode 100644
index c97d7a5d5..000000000
--- a/app/views/registrar/polls/show.haml
+++ /dev/null
@@ -1,48 +0,0 @@
-- if @data.css('msgQ').any?
- - msg_q = @data.css('msgQ').first
- .row
- .col-sm-12
- %h2= t '.header', count: msg_q['count']
- %hr
- .row
- .col-md-12
- .panel.panel-default
- .panel-heading.clearfix
- .pull-left= t('message_no', id: msg_q['id'])
- .pull-right
- - if @data.css('trnData trStatus').any? # this is a transfer request
- - unless ['serverApproved', 'clientApproved'].include?(@data.css('trStatus').first.text)
- = link_to(t(:confirm), 'javascript: void(0);', class: 'btn btn-warning btn-xs js-transfer-confirm')
- = link_to(t(:dequeue), registrar_poll_path(id: msg_q['id']), method: :delete, class: 'btn btn-primary btn-xs')
- .panel-body
- %dl.dl-horizontal
- %dt= t(:message)
- %dd= msg_q.css('msg').text
-
- %dt= t(:queue_date)
- %dd= @data.css('qDate').text
-
- %dl.dl-horizontal
- - if @data.css('trnData trStatus').any? # this is a transfer request
- = form_tag confirm_transfer_registrar_poll_path, class: 'js-transfer-form' do
- = hidden_field_tag 'domain[name]', @data.css('name').text
-
- - @data.css('trnData').children.each do |x|
- - next if x.blank?
- %dt= t(x.name)
- %dd= x.text
-
-- else
- .row
- .col-sm-12
- %h2= t '.header', count: 0
- %hr
- .row
- .col-md-12
- %p.bg-info{style: 'padding: 15px;'}= t(:you_have_no_new_messages)
-
-:coffee
- load_listener = ->
- $(".js-transfer-confirm").on "click", ->
- $(".js-transfer-form").submit()
- window.addEventListener 'load', load_listener
diff --git a/app/views/registrar/sessions/new.html.erb b/app/views/registrar/sessions/new.html.erb
deleted file mode 100644
index 2ce0b0f1a..000000000
--- a/app/views/registrar/sessions/new.html.erb
+++ /dev/null
@@ -1,28 +0,0 @@
-
-
-
<%= t '.header_html' %>
-
-
-
- <%= form_for resource, as: resource_name, url: session_path(resource_name) do |f| %>
- <%= f.text_field :username, placeholder: ApiUser.human_attribute_name(:username),
- autofocus: true,
- required: true,
- class: 'form-control' %>
- <%= f.password_field :password,
- placeholder: ApiUser.human_attribute_name(:password),
- required: true,
- class: 'form-control' %>
-
- <%= f.submit t('.submit_btn'), class: 'btn btn-lg btn-primary btn-block' %>
- <% end %>
-
-
-
-
-
<%= t('.sign_in_with_identity_document') %>
-
<%= t('.identity_document_text')%>
- <%= link_to t(:sign_in), "/auth/tara", method: :post, class: 'btn btn-lg btn-primary btn-block' %>
-
-
-
diff --git a/app/views/registrar/settings/balance_auto_reload/_form.html.erb b/app/views/registrar/settings/balance_auto_reload/_form.html.erb
deleted file mode 100644
index ecd34980e..000000000
--- a/app/views/registrar/settings/balance_auto_reload/_form.html.erb
+++ /dev/null
@@ -1 +0,0 @@
-<%= render 'registrar/settings/balance_auto_reload/form/types/threshold', type: @type %>
\ No newline at end of file
diff --git a/app/views/registrar/settings/balance_auto_reload/edit.html.erb b/app/views/registrar/settings/balance_auto_reload/edit.html.erb
deleted file mode 100644
index 20aa88d2d..000000000
--- a/app/views/registrar/settings/balance_auto_reload/edit.html.erb
+++ /dev/null
@@ -1,10 +0,0 @@
-
- <%= link_to t('registrar.account.show.header'), registrar_account_path %>
- <%= t '.header' %>
-
-
-
-
-<%= render 'form' %>
\ No newline at end of file
diff --git a/app/views/registrar/settings/balance_auto_reload/form/types/_threshold.erb b/app/views/registrar/settings/balance_auto_reload/form/types/_threshold.erb
deleted file mode 100644
index bcb649421..000000000
--- a/app/views/registrar/settings/balance_auto_reload/form/types/_threshold.erb
+++ /dev/null
@@ -1,40 +0,0 @@
-<%= t '.description' %>
-
-<%= form_for type, as: :type, url: registrar_settings_balance_auto_reload_path, method: :patch,
- html: { class: 'form-horizontal' } do |f| %>
- <%= render 'form_errors', target: type %>
-
-
-
-
-
-
-
-
-<% end %>
\ No newline at end of file
diff --git a/app/views/registrar/shared/_epp_results.haml b/app/views/registrar/shared/_epp_results.haml
deleted file mode 100644
index 4dfaadaed..000000000
--- a/app/views/registrar/shared/_epp_results.haml
+++ /dev/null
@@ -1,31 +0,0 @@
-- if @data && @data.css('result')
- - @results ||= @data.css('result')
-
-- if @results || flash[:epp_results]
- - success_codes = %(1000, 1300, 1301, 200)
-
- - if @results
- - @results.each do |x|
- - next if success_codes.include?(x['code'])
- .row
- .col-md-12
- %p{class: "alert alert-danger"}
- = x.css('msg').text.split('[').first
- - if x.css('value').text.present?
- = " - #{x.css('value').text}"
- %span.pull-right
- = "[code: #{x['code']}]"
-
- - if flash[:epp_results]
- - flash[:epp_results].each do |x|
- - next if success_codes.include?(x['code']) && x['show'] != true
- - c = 'alert-danger'
- - c = 'alert-success' if success_codes.include?(x['code'])
- .row
- .col-md-12
- %p{class: "alert #{c}"}
- = x['msg'].split('[').first
- - if x['value'].present?
- = " - #{x['value']}"
- %span.pull-right
- = "[code: #{x['code']}]"
diff --git a/app/views/registrar/shared/_error_messages.haml b/app/views/registrar/shared/_error_messages.haml
deleted file mode 100644
index fd9b5bfbc..000000000
--- a/app/views/registrar/shared/_error_messages.haml
+++ /dev/null
@@ -1,5 +0,0 @@
-- if f.object.errors.present?
- .alert.alert-warning
- %ul
- - f.object.errors.messages.each do |message|
- %li= message.second.first.split('[').first
diff --git a/app/views/registrar/tara/callback.html.erb b/app/views/registrar/tara/callback.html.erb
deleted file mode 100644
index e69de29bb..000000000
diff --git a/app/views/registrar/xml_consoles/epp_requests/contact/check.xml b/app/views/registrar/xml_consoles/epp_requests/contact/check.xml
deleted file mode 100644
index f4c10d8bd..000000000
--- a/app/views/registrar/xml_consoles/epp_requests/contact/check.xml
+++ /dev/null
@@ -1,12 +0,0 @@
-
-
-
-
-
- sh8013
-
-
- ABC-12345
-
-
diff --git a/app/views/registrar/xml_consoles/epp_requests/contact/check_multiple.xml b/app/views/registrar/xml_consoles/epp_requests/contact/check_multiple.xml
deleted file mode 100644
index bdcff03dd..000000000
--- a/app/views/registrar/xml_consoles/epp_requests/contact/check_multiple.xml
+++ /dev/null
@@ -1,14 +0,0 @@
-
-
-
-
-
- sh8013
- sh13
- vsdfvq
-
-
- ABC-12345
-
-
diff --git a/app/views/registrar/xml_consoles/epp_requests/contact/create.xml b/app/views/registrar/xml_consoles/epp_requests/contact/create.xml
deleted file mode 100644
index fc60b8311..000000000
--- a/app/views/registrar/xml_consoles/epp_requests/contact/create.xml
+++ /dev/null
@@ -1,32 +0,0 @@
-
-
-
-
-
-
- Sillius Soddus
-
- 123 Example Dr.
- Suite 100
-
- Megaton
- F3
- 201-33
- EE
-
-
- +372.1234567
- example@test.example
-
-
-
-
- 123
-
- dGVzdCBmYWlsCg==
-
-
-
- ABC-12345
-
-
diff --git a/app/views/registrar/xml_consoles/epp_requests/contact/delete.xml b/app/views/registrar/xml_consoles/epp_requests/contact/delete.xml
deleted file mode 100644
index 28b50af64..000000000
--- a/app/views/registrar/xml_consoles/epp_requests/contact/delete.xml
+++ /dev/null
@@ -1,22 +0,0 @@
-
-
-
-
-
- sh8013
-
- wrong-one
-
-
-
-
-
-
- dGVzdCBmYWlsCg==
-
-
-
- ABC-12345
-
-
diff --git a/app/views/registrar/xml_consoles/epp_requests/contact/info.xml b/app/views/registrar/xml_consoles/epp_requests/contact/info.xml
deleted file mode 100644
index 44e5d5a1e..000000000
--- a/app/views/registrar/xml_consoles/epp_requests/contact/info.xml
+++ /dev/null
@@ -1,14 +0,0 @@
-
-
-
-
-
- sh8013
-
- Aas34fq
-
-
-
- ABC-12345
-
-
diff --git a/app/views/registrar/xml_consoles/epp_requests/contact/update_chg.xml b/app/views/registrar/xml_consoles/epp_requests/contact/update_chg.xml
deleted file mode 100644
index 61ea43202..000000000
--- a/app/views/registrar/xml_consoles/epp_requests/contact/update_chg.xml
+++ /dev/null
@@ -1,36 +0,0 @@
-
-
-
-
-
- sh8013
-
-
- John Doe
-
- 123 Example Dr.
- Suite 100
- Dulles
- VA
- 20166-6503
- EE
-
-
- +123.7035555555
- jdoe@example.com
-
- 2fooBAR
-
-
-
-
-
-
-
- dGVzdCBmYWlsCg==
-
-
-
- ABC-12345
-
-
diff --git a/app/views/registrar/xml_consoles/epp_requests/domain/check.xml b/app/views/registrar/xml_consoles/epp_requests/domain/check.xml
deleted file mode 100644
index 06492bcfe..000000000
--- a/app/views/registrar/xml_consoles/epp_requests/domain/check.xml
+++ /dev/null
@@ -1,12 +0,0 @@
-
-
-
-
-
- example.ee
-
-
- ABC-12345
-
-
diff --git a/app/views/registrar/xml_consoles/epp_requests/domain/client_hold.xml b/app/views/registrar/xml_consoles/epp_requests/domain/client_hold.xml
deleted file mode 100644
index 68f0b778e..000000000
--- a/app/views/registrar/xml_consoles/epp_requests/domain/client_hold.xml
+++ /dev/null
@@ -1,15 +0,0 @@
-
-
-
-
-
- example.ee
-
-
-
-
-
- timo-1579351654
-
-
diff --git a/app/views/registrar/xml_consoles/epp_requests/domain/create.xml b/app/views/registrar/xml_consoles/epp_requests/domain/create.xml
deleted file mode 100644
index f57fcfe30..000000000
--- a/app/views/registrar/xml_consoles/epp_requests/domain/create.xml
+++ /dev/null
@@ -1,42 +0,0 @@
-
-
-
-
-
- example.ee
- 1
-
-
- ns1.example.net
-
-
- ns2.example.net
- 192.0.2.2
- 1080:0:0:0:8:800:200C:417A
-
-
- jd1234
- sh8013
- sh8013
- sh801333
-
-
-
-
-
- 257
- 3
- 8
- AwEAAddt2AkLfYGKgiEZB5SmIF8EvrjxNMH6HtxWEA4RJ9Ao6LCWheg8
-
-
-
-
- dGVzdCBmYWlsCg==
-
-
-
- ABC-12345
-
-
diff --git a/app/views/registrar/xml_consoles/epp_requests/domain/delete.xml b/app/views/registrar/xml_consoles/epp_requests/domain/delete.xml
deleted file mode 100644
index f47bb79eb..000000000
--- a/app/views/registrar/xml_consoles/epp_requests/domain/delete.xml
+++ /dev/null
@@ -1,19 +0,0 @@
-
-
-
-
-
- example.ee
-
-
-
-
-
- dGVzdCBmYWlsCg==
-
-
-
- ABC-12345
-
-
diff --git a/app/views/registrar/xml_consoles/epp_requests/domain/info.xml b/app/views/registrar/xml_consoles/epp_requests/domain/info.xml
deleted file mode 100644
index 210396c3b..000000000
--- a/app/views/registrar/xml_consoles/epp_requests/domain/info.xml
+++ /dev/null
@@ -1,15 +0,0 @@
-
-
-
-
-
- example.ee
-
- 2fooBAR
-
-
-
- ABC-12345
-
-
diff --git a/app/views/registrar/xml_consoles/epp_requests/domain/renew.xml b/app/views/registrar/xml_consoles/epp_requests/domain/renew.xml
deleted file mode 100644
index 6ef479468..000000000
--- a/app/views/registrar/xml_consoles/epp_requests/domain/renew.xml
+++ /dev/null
@@ -1,14 +0,0 @@
-
-
-
-
-
- example.ee
- 2014-08-07
- 1
-
-
- ABC-12345
-
-
diff --git a/app/views/registrar/xml_consoles/epp_requests/domain/transfer.xml b/app/views/registrar/xml_consoles/epp_requests/domain/transfer.xml
deleted file mode 100644
index f6ee87b79..000000000
--- a/app/views/registrar/xml_consoles/epp_requests/domain/transfer.xml
+++ /dev/null
@@ -1,22 +0,0 @@
-
-
-
-
-
- example.ee
-
- 2BARfoo
-
-
-
-
-
-
- dGVzdCBmYWlsCg==
-
-
-
- ABC-12345
-
-
diff --git a/app/views/registrar/xml_consoles/epp_requests/domain/update.xml b/app/views/registrar/xml_consoles/epp_requests/domain/update.xml
deleted file mode 100644
index c087245e7..000000000
--- a/app/views/registrar/xml_consoles/epp_requests/domain/update.xml
+++ /dev/null
@@ -1,54 +0,0 @@
-
-
-
-
-
- example.ee
-
-
-
- ns1.example.com
-
-
- ns2.example.com
-
-
- mak21
-
-
-
-
- ns1.example.net
-
-
- mak21
-
-
- mak21
-
- newpw
-
-
-
-
-
-
-
-
- 257
- 3
- 8
- 700b97b591ed27ec2590d19f06f88bba700b97b591ed27ec2590d19f
-
-
-
-
-
- dGVzdCBmYWlsCg==
-
-
-
- ABC-12345
-
-
diff --git a/app/views/registrar/xml_consoles/epp_requests/poll/poll.xml b/app/views/registrar/xml_consoles/epp_requests/poll/poll.xml
deleted file mode 100644
index 5ffed010e..000000000
--- a/app/views/registrar/xml_consoles/epp_requests/poll/poll.xml
+++ /dev/null
@@ -1,7 +0,0 @@
-
-
-
-
- ABC-12345
-
-
diff --git a/app/views/registrar/xml_consoles/show.haml b/app/views/registrar/xml_consoles/show.haml
deleted file mode 100644
index bb66116ee..000000000
--- a/app/views/registrar/xml_consoles/show.haml
+++ /dev/null
@@ -1,73 +0,0 @@
-= render 'shared/title', name: t(:xml_console)
-
-.row
- .col-md-8
- = form_tag(registrar_xml_console_path) do
- .form-group
- = text_area_tag(:payload, params[:payload], class: 'form-control', rows: 15, style: 'font-family:monospace; font-size: 11px;')
-
- = button_tag t(:send_epp_request), class: 'btn btn-default'
- .col-md-4
- %h4 Domain
- %a.js-load-xml{href: 'javascript:void(0)', data: {obj: 'domain', epp_action: 'create'}}
- Create
- ,
- %a.js-load-xml{href: 'javascript:void(0)', data: {obj: 'domain', epp_action: 'update'}}
- Update
- ,
- %a.js-load-xml{href: 'javascript:void(0)', data: {obj: 'domain', epp_action: 'info'}}
- Info
- ,
- %a.js-load-xml{href: 'javascript:void(0)', data: {obj: 'domain', epp_action: 'renew'}}
- Renew
- ,
- %a.js-load-xml{href: 'javascript:void(0)', data: {obj: 'domain', epp_action: 'check'}}
- Check
- ,
- %a.js-load-xml{href: 'javascript:void(0)', data: {obj: 'domain', epp_action: 'transfer'}}
- Transfer
- ,
- %a.js-load-xml{href: 'javascript:void(0)', data: {obj: 'domain', epp_action: 'delete'}}
- Delete
- ,
- %a.js-load-xml{href: 'javascript:void(0)', data: {obj: 'domain', epp_action: 'client_hold'}}
- Remove Client Hold
-
- %h4 Poll
- %a.js-load-xml{href: 'javascript:void(0)', data: {obj: 'poll', epp_action: 'poll'}}
- Poll
-
- %h4 Contact
- %a.js-load-xml{href: 'javascript:void(0)', data: {obj: 'contact', epp_action: 'create'}}
- Create
- ,
- %a.js-load-xml{href: 'javascript:void(0)', data: {obj: 'contact', epp_action: 'check'}}
- Check
- ,
- %a.js-load-xml{href: 'javascript:void(0)', data: {obj: 'contact', epp_action: 'check_multiple'}}
- Check(multiple)
- ,
- %a.js-load-xml{href: 'javascript:void(0)', data: {obj: 'contact', epp_action: 'delete'}}
- Delete
- ,
- %a.js-load-xml{href: 'javascript:void(0)', data: {obj: 'contact', epp_action: 'info'}}
- Info
- ,
- %a.js-load-xml{href: 'javascript:void(0)', data: {obj: 'contact', epp_action: 'update_chg'}}
- Update(chg)
-
-- if @result
- %hr
- .row
- .col-md-12
- = preserve do
- = CodeRay.scan(@result.to_s.force_encoding("UTF-8"), :xml).div().html_safe
-
-:javascript
- window.addEventListener('load',
- function(){
- $('.js-load-xml').click(function() {
- $.get('xml_console/load_xml', {obj: $(this).data('obj'), epp_action: $(this).data('epp-action')}, function(data) {
- $('textarea[name="payload"]').html(data);
- });
- });});