mirror of
https://gitlink.org.cn/Gitlink/forgeplus.git
synced 2026-05-16 01:35:56 +08:00
竞赛配置子赛项
This commit is contained in:
@@ -15,7 +15,7 @@ class Site < ApplicationRecord
|
||||
# add: 添加类链接
|
||||
# personal: 个人名下类链接,
|
||||
# common: 普通链接
|
||||
enum site_type: { add: 0, personal: 1, common: 2 }
|
||||
enum site_type: { add: 0, personal: 1, common: 2, competition: 3 }
|
||||
|
||||
scope :by_search, -> (keyword){ where("name LIKE :keyword OR url LIKE :keyword", keyword: "%#{strip_param(keyword)}%") unless strip_param(keyword).blank? }
|
||||
scope :by_site_type, -> (site_type){ where(site_type: strip_param(site_type)) unless strip_param(site_type).blank? }
|
||||
|
||||
Reference in New Issue
Block a user