約1,020件1ページ目

日本語のみで絞り込む

条件を指定して検索しています。すべての条件を解除する

  • 最終更新日:1週間以内
  • 1日前 -The Numericality Validator should not accept 'abc' as valid number, even when the attribute was normalized. Actual behavior. Given the normalizer. normalizes : ...

    3日前 -I've got a child model that has an end_date attribute and a validation which ensures only one record can leave this attribute blank (this is also enforced ...

    3日前 -I've got a child model that has an end_date attribute and a validation which ensures only one record can leave this attribute blank (this is also enforced ...

    4日前 -Common validations include `presence` (`validates :name, presence: true`), `length` (`validates :password, length: { minimum: 6 }`), and `numericality` (` ...

    3日前 -How do you handle validations in Rails? Validations are added to models using methods like validates. For example: class User < ApplicationRecord.

    1日前 -Is it a best practise to repeat the database constraints in model validation in Rails? DB level vs App level? or both? Best Practice: Use BOTH. Why both ...

    A.回答を一意にするUserなのかどうかを判別するフラグを新たに持たせて、それをwith_optionsメソッドで判定すればいいです。 以下を参考にしてください。 Railsで特定の条件下で走る...

    A.validates は ActiveModel::Validations モジュールで 定義されてる特異メソッドで ActiveRecord::Base などの フィールドをチェックします。 今...

    A.データベースより前に、フロントエンドの脆弱性対策が先だと思います。 まずは、無料のツールを使ってみてはいかがですか。 https://yun-craft.com/admin-blog/tomiz...

    2日前 -Join the GoRails community forum to discuss Ruby on Rails, get help, share tips, and connect with fellow developers.

    5日前 -This Ruby style guide recommends best practices so that real-world Ruby programmers can write code that can be maintained by other real-world Ruby programmers.

    3日前 -Constraint validation is done through the Constraint Validation API either on a single form element or at the form level, on the <form> element itself.

    5日前 -最後に validates メソッドでどのようにバリデーターを読み込んでいるのか紹介します。 validates メソッドは ActiveModel::Validations::ClassMethods に定義されています ...