mirror of
https://github.com/internetee/registry.git
synced 2025-05-18 02:09:39 +02:00
Merge branch '108869472-objects_archive' into staging
This commit is contained in:
commit
eb24f17a30
2 changed files with 0 additions and 153 deletions
|
@ -1,109 +0,0 @@
|
|||
- statuses_link ||= false
|
||||
- version ||= false
|
||||
- domain ||= false
|
||||
- pending_user ||= false
|
||||
|
||||
- if domain.present?
|
||||
- if version # normal history
|
||||
- children = HashWithIndifferentAccess.new(version.children)
|
||||
- nameservers = Nameserver.where(id: children[:nameservers])
|
||||
- tech_contacts = Contact.where(id: children[:tech_contacts])
|
||||
- admin_contacts = Contact.where(id: children[:admin_contacts])
|
||||
- registrant = Contact.where(id: children[:registrant])
|
||||
- event = version.event
|
||||
- creator = plain_username(version.terminator)
|
||||
- else # pending history
|
||||
- nameservers = domain.nameservers
|
||||
- tech_contacts = domain.tech_contacts
|
||||
- admin_contacts = domain.admin_contacts
|
||||
- registrant = [domain.registrant]
|
||||
- creator = pending_user.try(:username)
|
||||
- event = 'pending'
|
||||
|
||||
%td
|
||||
%p.nowrap
|
||||
= l(domain.updated_at, format: :shorts)
|
||||
- if statuses_link
|
||||
%br= link_to t(:edit_statuses), edit_admin_domain_path(params[:domain_id])
|
||||
|
||||
%p.text-right
|
||||
= event
|
||||
%br
|
||||
= creator
|
||||
|
||||
%td
|
||||
%p
|
||||
- if domain.statuses.present?
|
||||
- domain.statuses.each do |s|
|
||||
= s
|
||||
- if domain.status_notes.present?
|
||||
- notes = domain.status_notes[s]
|
||||
- if notes
|
||||
%br
|
||||
%i= notes
|
||||
%br
|
||||
- if domain.pending_json.present?
|
||||
%p
|
||||
= link_to t(:pending_epp), '#', class: 'js-pending-toggle'
|
||||
|
||||
%td
|
||||
%p
|
||||
= "#{domain.period}#{domain.period_unit}"
|
||||
%br
|
||||
= "#{l(domain.valid_from, format: :date)}"
|
||||
%br
|
||||
= "#{l(domain.valid_to, format: :date)}"
|
||||
|
||||
%td
|
||||
- if registrant
|
||||
- registrant.each do |r|
|
||||
%p
|
||||
= r[:name]
|
||||
= r[:phone]
|
||||
= r[:email]
|
||||
%p
|
||||
= r[:code]
|
||||
|
||||
%td
|
||||
- if admin_contacts
|
||||
- admin_contacts.each do |ac|
|
||||
%p
|
||||
= ac[:name]
|
||||
= ac[:phone]
|
||||
= ac[:email]
|
||||
%p
|
||||
= ac[:code]
|
||||
|
||||
%td
|
||||
- if tech_contacts
|
||||
- tech_contacts.each do |tc|
|
||||
%p
|
||||
= tc[:name]
|
||||
= tc[:phone]
|
||||
= tc[:email]
|
||||
%p
|
||||
= tc[:code]
|
||||
|
||||
%td
|
||||
%p
|
||||
- if nameservers
|
||||
- nameservers.each do |ns|
|
||||
= ns[:hostname]
|
||||
%br
|
||||
= ns[:ipv4]
|
||||
= ns[:ipv6]
|
||||
|
||||
%td
|
||||
%p
|
||||
= domain.registrar.name if domain.registrar
|
||||
|
||||
- if domain.pending_json.present?
|
||||
%tr.js-pending{ style: 'display: none;' }
|
||||
%td{colspan: 8}
|
||||
= preserve do
|
||||
%pre
|
||||
- formatted_req = Nokogiri::XML(domain.pending_json['frame'])
|
||||
- if formatted_req.errors.none?
|
||||
= formatted_req
|
||||
- else
|
||||
= domain.pending_json['frame']
|
|
@ -1,44 +0,0 @@
|
|||
- content_for :actions do
|
||||
= link_to(t(:back_to_domain), [:admin, @domain], class: 'btn btn-default')
|
||||
= render 'shared/title', name: "#{t(:history)}: #{@domain.name}"
|
||||
|
||||
.row
|
||||
.col-md-12
|
||||
.table-responsive
|
||||
%table.table-hover.table-bordered.table-condensed
|
||||
%thead
|
||||
%tr
|
||||
%th{class: 'col-xs-1'}= t(:timestap)
|
||||
%th{class: 'col-xs-2'}= t(:statuses)
|
||||
%th{class: 'col-xs-1'}= t(:period)
|
||||
%th{class: 'col-xs-2'}= t(:registrant)
|
||||
%th{class: 'col-xs-2'}= t(:admin)
|
||||
%th{class: 'col-xs-2'}= t(:tech)
|
||||
%th{class: 'col-xs-2'}= t(:nameservers)
|
||||
%th{class: 'col-xs-2'}= t(:registrar)
|
||||
|
||||
%tbody
|
||||
- if @pending_domain.present?
|
||||
%tr.small
|
||||
= render 'admin/domain_versions/version',
|
||||
domain: @pending_domain, pending_user: @pending_user, statuses_link: true
|
||||
|
||||
-# current version
|
||||
- if @domain.versions.present?
|
||||
%tr.small
|
||||
= render 'admin/domain_versions/version',
|
||||
domain: @domain, version: @domain.versions.last
|
||||
|
||||
-# all other older versions
|
||||
- @domain.versions.not_creates.reverse.each do |version|
|
||||
%tr.small
|
||||
= render 'admin/domain_versions/version',
|
||||
domain: version.reify, version: version.previous
|
||||
|
||||
:coffee
|
||||
$(document).on 'click', '.js-pending-toggle', (e) ->
|
||||
e.preventDefault()
|
||||
|
||||
$(document).on 'mousedown', '.js-pending-toggle', (e) ->
|
||||
target = $(e.target)
|
||||
target.parents('tr').next('tr.js-pending').toggle()
|
Loading…
Add table
Add a link
Reference in a new issue