2018-08-03 03:15:25 -04:00
|
|
|
# frozen_string_literal: true
|
|
|
|
|
2018-03-05 12:51:40 -05:00
|
|
|
class ProjectBadge < Badge
|
|
|
|
belongs_to :project
|
|
|
|
|
|
|
|
validates :project, presence: true
|
|
|
|
|
|
|
|
def rendered_link_url(project = nil)
|
|
|
|
project ||= self.project
|
|
|
|
super
|
|
|
|
end
|
|
|
|
|
|
|
|
def rendered_image_url(project = nil)
|
|
|
|
project ||= self.project
|
|
|
|
super
|
|
|
|
end
|
|
|
|
end
|