Skip to content

Commit

Permalink
Merge pull request #1183 from internetee/remove-html5-validators-gem
Browse files Browse the repository at this point in the history
Remove `html5_validators` gem
  • Loading branch information
vohmar authored May 7, 2019
2 parents bec24b4 + 450d208 commit 020abc1
Show file tree
Hide file tree
Showing 12 changed files with 2 additions and 25 deletions.
1 change: 0 additions & 1 deletion Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,6 @@ gem 'selectize-rails', '0.12.1' # include selectize.js for select
# view helpers
gem 'kaminari', '0.16.3' # pagination
gem 'coderay', '1.1.0' # xml console visualize
gem 'html5_validators', '1.2.2' # model requements now automatically on html form
gem 'select2-rails', '3.5.9.3' # for autocomplete
gem 'liquid', '3.0.6' # for email templates

Expand Down
2 changes: 0 additions & 2 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -205,7 +205,6 @@ GEM
haml (~> 4.0)
nokogiri (>= 1.6.0)
ruby_parser (~> 3.5)
html5_validators (1.2.2)
http-cookie (1.0.3)
domain_name (~> 0.5)
httpclient (2.8.3)
Expand Down Expand Up @@ -467,7 +466,6 @@ DEPENDENCIES
grape
haml-rails (= 0.9.0)
html2haml (= 2.1.0)
html5_validators (= 1.2.2)
isikukood
iso8601 (= 0.8.6)
jbuilder (= 2.2.16)
Expand Down
2 changes: 0 additions & 2 deletions app/models/billing/price.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@ module Billing
class Price < ActiveRecord::Base
include Concerns::Billing::Price::Expirable

self.auto_html5_validation = false

belongs_to :zone, class_name: 'DNS::Zone', required: true
has_many :account_activities

Expand Down
9 changes: 0 additions & 9 deletions app/models/concerns/disable_html5_validation.rb

This file was deleted.

1 change: 0 additions & 1 deletion app/models/deposit.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ class Deposit
include ActiveModel::Validations
include ActiveModel::Conversion
extend ActiveModel::Naming
include DisableHtml5Validation

attr_accessor :description, :registrar, :registrar_id
attr_writer :amount
Expand Down
1 change: 0 additions & 1 deletion app/models/depp/contact.rb
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
module Depp
class Contact
include ActiveModel::Model
include DisableHtml5Validation

attr_accessor :id, :name, :email, :phone, :org_name,
:ident, :ident_type, :ident_country_code,
Expand Down
1 change: 0 additions & 1 deletion app/models/depp/domain.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ module Depp
class Domain
include ActiveModel::Conversion
extend ActiveModel::Naming
include DisableHtml5Validation

attr_accessor :name, :current_user, :epp_xml

Expand Down
1 change: 0 additions & 1 deletion app/models/depp/keyrelay.rb
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
module Depp
class Keyrelay
include DisableHtml5Validation
attr_accessor :current_user, :epp_xml

def initialize(args = {})
Expand Down
1 change: 0 additions & 1 deletion app/models/depp/user.rb
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ class User
include ActiveModel::Validations
include ActiveModel::Conversion
extend ActiveModel::Naming
include DisableHtml5Validation

attr_accessor :tag, :password, :pki

Expand Down
2 changes: 0 additions & 2 deletions app/models/dns/zone.rb
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
module DNS
class Zone < ActiveRecord::Base
self.auto_html5_validation = false

validates :origin, :ttl, :refresh, :retry, :expire, :minimum_ttl, :email, :master_nameserver, presence: true
validates :ttl, :refresh, :retry, :expire, :minimum_ttl, numericality: { only_integer: true }
validates :origin, uniqueness: true
Expand Down
3 changes: 1 addition & 2 deletions app/views/registrant/sessions/login_mid.haml
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,7 @@
.form-signin.col-md-4.center-block.text-center
%h2.form-signin-heading.text-center= t '.header'
%hr
= form_for @user, url: registrant_mid_path, auto_html5_validation: false,
html: {class: 'form-signin'} do |f|
= form_for @user, url: registrant_mid_path, html: {class: 'form-signin'} do |f|
= f.text_field :phone, class: 'form-control',
placeholder: t(:phone_no), autocomplete: 'off', required: true
%button.btn.btn-lg.btn-primary.btn-block.js-login{:type => 'submit'}= t '.submit_btn'
Expand Down
3 changes: 1 addition & 2 deletions app/views/registrar/sessions/login_mid.haml
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,7 @@
.form-signin.col-md-4.center-block.text-center
%h2.form-signin-heading.text-center= t '.header'
%hr
= form_for @user, url: registrar_mid_path, auto_html5_validation: false,
html: {class: 'form-signin'} do |f|
= form_for @user, url: registrar_mid_path, html: {class: 'form-signin'} do |f|
= f.text_field :phone, class: 'form-control',
placeholder: t(:phone_no), autocomplete: 'off', required: true
%button.btn.btn-lg.btn-primary.btn-block.js-login{:type => 'submit'}= t '.submit_btn'
Expand Down

0 comments on commit 020abc1

Please sign in to comment.