修复:悬赏金额可以为空
This commit is contained in:
parent
b44ab1e39e
commit
75d74f80ca
|
@ -11,7 +11,7 @@ class Api::V1::Issues::CreateService < ApplicationService
|
|||
validates :subject, presence: true
|
||||
validates :status_id, :priority_id, presence: true
|
||||
validates :project, :current_user, presence: true
|
||||
validates :blockchain_token_num, numericality: {greater_than: 0}
|
||||
validates :blockchain_token_num, numericality: {greater_than: 0}, allow_blank: true
|
||||
|
||||
def initialize(project, params, current_user = nil)
|
||||
@project = project
|
||||
|
|
|
@ -9,7 +9,7 @@ class Api::V1::Issues::UpdateService < ApplicationService
|
|||
attr_accessor :add_assigner_ids, :previous_issue_changes, :updated_issue, :atme_receivers
|
||||
|
||||
validates :project, :issue, :current_user, presence: true
|
||||
validates :blockchain_token_num, numericality: {greater_than: 0}
|
||||
validates :blockchain_token_num, numericality: {greater_than: 0}, allow_blank: true
|
||||
|
||||
def initialize(project, issue, params, current_user = nil)
|
||||
@project = project
|
||||
|
|
Loading…
Reference in New Issue