forked from Trustie/forgeplus
项目推荐增加属性
This commit is contained in:
parent
7c6d73f45a
commit
02b99cf35c
|
|
@ -147,7 +147,7 @@ class Project < ApplicationRecord
|
|||
after_destroy :decre_user_statistic, :decre_platform_statistic
|
||||
scope :project_statics_select, -> {select(:id,:name, :is_public, :identifier, :status, :project_type, :user_id, :forked_count, :description, :visits, :project_category_id, :project_language_id, :license_id, :ignore_id, :watchers_count, :created_on)}
|
||||
scope :no_anomory_projects, -> {where("projects.user_id is not null and projects.user_id != ?", 2)}
|
||||
scope :recommend, -> { visible.project_statics_select.where(recommend: true) }
|
||||
scope :recommend, -> { visible.where(recommend: true) }
|
||||
scope :pinned, -> {where(is_pinned: true)}
|
||||
|
||||
scope :like, lambda { |keywords|
|
||||
|
|
|
|||
Loading…
Reference in New Issue