提交 6ace6d94 编写于 作者: K Kamil Trzcinski

Use validate and required for environment and project

上级 a4dc5f79
class Deployment < ActiveRecord::Base
include InternalId
belongs_to :project, validate: true
belongs_to :environment, validate: true
belongs_to :project, required: true, validate: true
belongs_to :environment, required: true, validate: true
belongs_to :user
belongs_to :deployable, polymorphic: true
......
class Environment < ActiveRecord::Base
belongs_to :project, required: true
belongs_to :project, required: true, validate: true
has_many :deployments
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册