mirror of
https://gitlink.org.cn/Gitlink/forgeplus.git
synced 2026-05-17 02:05:58 +08:00
fix: merge from hh_develop
This commit is contained in:
@@ -17,7 +17,7 @@
|
||||
# disk_directory :string(255)
|
||||
# attachtype :integer default("1")
|
||||
# is_public :integer default("1")
|
||||
# copy_from :string(255)
|
||||
# copy_from :integer
|
||||
# quotes :integer default("0")
|
||||
# is_publish :integer default("1")
|
||||
# publish_time :datetime
|
||||
@@ -26,15 +26,15 @@
|
||||
# cloud_url :string(255) default("")
|
||||
# course_second_category_id :integer default("0")
|
||||
# delay_publish :boolean default("0")
|
||||
# link :string(255)
|
||||
# clone_id :integer
|
||||
#
|
||||
# Indexes
|
||||
#
|
||||
# index_attachments_on_author_id (author_id)
|
||||
# index_attachments_on_clone_id (clone_id)
|
||||
# index_attachments_on_container_id_and_container_type (container_id,container_type)
|
||||
# index_attachments_on_course_second_category_id (course_second_category_id)
|
||||
# index_attachments_on_created_on (created_on)
|
||||
# index_attachments_on_is_public (is_public)
|
||||
# index_attachments_on_quotes (quotes)
|
||||
#
|
||||
|
||||
class Attachment < ApplicationRecord
|
||||
|
||||
@@ -39,15 +39,13 @@
|
||||
# business :boolean default("0")
|
||||
# profile_completed :boolean default("0")
|
||||
# laboratory_id :integer
|
||||
# is_shixun_marker :boolean default("0")
|
||||
# admin_visitable :boolean default("0")
|
||||
# collaborator :boolean default("0")
|
||||
# platform :string(255) default("0")
|
||||
# gitea_token :string(255)
|
||||
# gitea_uid :integer
|
||||
# is_shixun_marker :boolean default("0")
|
||||
# is_sync_pwd :boolean default("1")
|
||||
# watchers_count :integer default("0")
|
||||
# devops_step :integer default("0")
|
||||
# gitea_token :string(255)
|
||||
# platform :string(255)
|
||||
#
|
||||
# Indexes
|
||||
#
|
||||
@@ -55,9 +53,8 @@
|
||||
# index_users_on_homepage_engineer (homepage_engineer)
|
||||
# index_users_on_homepage_teacher (homepage_teacher)
|
||||
# index_users_on_laboratory_id (laboratory_id)
|
||||
# index_users_on_login (login) UNIQUE
|
||||
# index_users_on_mail (mail) UNIQUE
|
||||
# index_users_on_phone (phone) UNIQUE
|
||||
# index_users_on_login (login)
|
||||
# index_users_on_mail (mail)
|
||||
# index_users_on_type (type)
|
||||
#
|
||||
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
# tracker_id :integer not null
|
||||
# project_id :integer not null
|
||||
# subject :string(255) default(""), not null
|
||||
# description :text(4294967295)
|
||||
# description :text(65535)
|
||||
# due_date :date
|
||||
# category_id :integer
|
||||
# status_id :integer not null
|
||||
@@ -14,6 +14,7 @@
|
||||
# priority_id :integer not null
|
||||
# fixed_version_id :integer
|
||||
# author_id :integer not null
|
||||
# lock_version :integer default("0"), not null
|
||||
# created_on :datetime
|
||||
# updated_on :datetime
|
||||
# start_date :date
|
||||
@@ -27,7 +28,7 @@
|
||||
# closed_on :datetime
|
||||
# project_issues_index :integer
|
||||
# issue_type :string(255)
|
||||
# token :integer default("0")
|
||||
# token :string(255)
|
||||
# issue_tags_value :string(255)
|
||||
# is_lock :boolean default("0")
|
||||
# issue_classify :string(255)
|
||||
@@ -50,7 +51,7 @@
|
||||
|
||||
class Issue < ApplicationRecord
|
||||
#issue_type 1为普通,2为悬赏
|
||||
belongs_to :project, :counter_cache => true
|
||||
belongs_to :project, counter_cache: true, touch: true
|
||||
belongs_to :tracker,optional: true
|
||||
has_many :project_trends, as: :trend, dependent: :destroy
|
||||
has_one :pull_request
|
||||
|
||||
@@ -10,7 +10,6 @@
|
||||
# sync_course :boolean default("0")
|
||||
# sync_subject :boolean default("0")
|
||||
# sync_shixun :boolean default("0")
|
||||
# is_local :boolean default("0")
|
||||
#
|
||||
# Indexes
|
||||
#
|
||||
|
||||
@@ -39,15 +39,13 @@
|
||||
# business :boolean default("0")
|
||||
# profile_completed :boolean default("0")
|
||||
# laboratory_id :integer
|
||||
# is_shixun_marker :boolean default("0")
|
||||
# admin_visitable :boolean default("0")
|
||||
# collaborator :boolean default("0")
|
||||
# platform :string(255) default("0")
|
||||
# gitea_token :string(255)
|
||||
# gitea_uid :integer
|
||||
# is_shixun_marker :boolean default("0")
|
||||
# is_sync_pwd :boolean default("1")
|
||||
# watchers_count :integer default("0")
|
||||
# devops_step :integer default("0")
|
||||
# gitea_token :string(255)
|
||||
# platform :string(255)
|
||||
#
|
||||
# Indexes
|
||||
#
|
||||
@@ -55,9 +53,8 @@
|
||||
# index_users_on_homepage_engineer (homepage_engineer)
|
||||
# index_users_on_homepage_teacher (homepage_teacher)
|
||||
# index_users_on_laboratory_id (laboratory_id)
|
||||
# index_users_on_login (login) UNIQUE
|
||||
# index_users_on_mail (mail) UNIQUE
|
||||
# index_users_on_phone (phone) UNIQUE
|
||||
# index_users_on_login (login)
|
||||
# index_users_on_mail (mail)
|
||||
# index_users_on_type (type)
|
||||
#
|
||||
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
<<<<<<< HEAD
|
||||
# == Schema Information
|
||||
#
|
||||
# Table name: projects
|
||||
@@ -71,6 +72,70 @@
|
||||
# index_projects_on_updated_on (updated_on)
|
||||
#
|
||||
|
||||
=======
|
||||
# == Schema Information
|
||||
#
|
||||
# Table name: projects
|
||||
#
|
||||
# id :integer not null, primary key
|
||||
# name :string(255) default(""), not null
|
||||
# description :text(65535)
|
||||
# homepage :string(255) default("")
|
||||
# is_public :boolean default("1"), not null
|
||||
# parent_id :integer
|
||||
# created_on :datetime
|
||||
# updated_on :datetime
|
||||
# identifier :string(255)
|
||||
# status :integer default("1"), not null
|
||||
# lft :integer
|
||||
# rgt :integer
|
||||
# inherit_members :boolean default("0"), not null
|
||||
# project_type :integer default("0")
|
||||
# hidden_repo :boolean default("0"), not null
|
||||
# attachmenttype :integer default("1")
|
||||
# user_id :integer
|
||||
# dts_test :integer default("0")
|
||||
# enterprise_name :string(255)
|
||||
# organization_id :integer
|
||||
# project_new_type :integer
|
||||
# gpid :integer
|
||||
# forked_from_project_id :integer
|
||||
# forked_count :integer default("0")
|
||||
# publish_resource :integer default("0")
|
||||
# visits :integer default("0")
|
||||
# hot :integer default("0")
|
||||
# invite_code :string(255)
|
||||
# qrcode :string(255)
|
||||
# qrcode_expiretime :integer default("0")
|
||||
# script :text(65535)
|
||||
# training_status :integer default("0")
|
||||
# rep_identifier :string(255)
|
||||
# project_category_id :integer
|
||||
# project_language_id :integer
|
||||
# license_id :integer
|
||||
# ignore_id :integer
|
||||
# praises_count :integer default("0")
|
||||
# watchers_count :integer default("0")
|
||||
# issues_count :integer default("0")
|
||||
# pull_requests_count :integer default("0")
|
||||
#
|
||||
# Indexes
|
||||
#
|
||||
# index_projects_on_forked_from_project_id (forked_from_project_id)
|
||||
# index_projects_on_identifier (identifier)
|
||||
# index_projects_on_is_public (is_public)
|
||||
# index_projects_on_lft (lft)
|
||||
# index_projects_on_name (name)
|
||||
# index_projects_on_platform (platform)
|
||||
# index_projects_on_project_type (project_type)
|
||||
# index_projects_on_recommend (recommend)
|
||||
# index_projects_on_rgt (rgt)
|
||||
# index_projects_on_status (status)
|
||||
# index_projects_on_updated_on (updated_on)
|
||||
#
|
||||
|
||||
>>>>>>> ed8d646d479bdcd84784909a024949bb8e4f093f
|
||||
|
||||
|
||||
class Project < ApplicationRecord
|
||||
include Matchable
|
||||
|
||||
@@ -8,6 +8,11 @@
|
||||
# projects_count :integer default("0")
|
||||
# created_at :datetime not null
|
||||
# updated_at :datetime not null
|
||||
# ancestry :string(255)
|
||||
#
|
||||
# Indexes
|
||||
#
|
||||
# index_project_categories_on_ancestry (ancestry)
|
||||
#
|
||||
|
||||
class ProjectCategory < ApplicationRecord
|
||||
|
||||
@@ -16,11 +16,6 @@
|
||||
# head :string(255)
|
||||
# base :string(255)
|
||||
# issue_id :integer
|
||||
# fork_project_id :integer
|
||||
# is_original :boolean default("0")
|
||||
# comments_count :integer default("0")
|
||||
# commits_count :integer default("0")
|
||||
# files_count :integer default("0")
|
||||
#
|
||||
|
||||
class PullRequest < ApplicationRecord
|
||||
@@ -31,7 +26,7 @@ class PullRequest < ApplicationRecord
|
||||
|
||||
belongs_to :issue
|
||||
belongs_to :user
|
||||
belongs_to :project, :counter_cache => true
|
||||
belongs_to :project, counter_cache: true, touch: true
|
||||
# belongs_to :fork_project, foreign_key: :fork_project_id
|
||||
has_many :pull_request_assigns, foreign_key: :pull_request_id
|
||||
has_many :pull_request_tags, foreign_key: :pull_request_id
|
||||
|
||||
@@ -27,6 +27,7 @@
|
||||
#
|
||||
# Indexes
|
||||
#
|
||||
# index_repositories_on_identifier (identifier)
|
||||
# index_repositories_on_project_id (project_id)
|
||||
# index_repositories_on_user_id (user_id)
|
||||
#
|
||||
|
||||
@@ -39,15 +39,13 @@
|
||||
# business :boolean default("0")
|
||||
# profile_completed :boolean default("0")
|
||||
# laboratory_id :integer
|
||||
# is_shixun_marker :boolean default("0")
|
||||
# admin_visitable :boolean default("0")
|
||||
# collaborator :boolean default("0")
|
||||
# platform :string(255) default("0")
|
||||
# gitea_token :string(255)
|
||||
# gitea_uid :integer
|
||||
# is_shixun_marker :boolean default("0")
|
||||
# is_sync_pwd :boolean default("1")
|
||||
# watchers_count :integer default("0")
|
||||
# devops_step :integer default("0")
|
||||
# gitea_token :string(255)
|
||||
# platform :string(255)
|
||||
#
|
||||
# Indexes
|
||||
#
|
||||
@@ -55,9 +53,8 @@
|
||||
# index_users_on_homepage_engineer (homepage_engineer)
|
||||
# index_users_on_homepage_teacher (homepage_teacher)
|
||||
# index_users_on_laboratory_id (laboratory_id)
|
||||
# index_users_on_login (login) UNIQUE
|
||||
# index_users_on_mail (mail) UNIQUE
|
||||
# index_users_on_phone (phone) UNIQUE
|
||||
# index_users_on_login (login)
|
||||
# index_users_on_mail (mail)
|
||||
# index_users_on_type (type)
|
||||
#
|
||||
|
||||
|
||||
@@ -12,9 +12,7 @@
|
||||
#
|
||||
# Indexes
|
||||
#
|
||||
# index_user_actions_on_ip (ip)
|
||||
# index_user_actions_on_user_id (user_id)
|
||||
# index_user_actions_on_user_id_and_action_type (user_id,action_type)
|
||||
# index_user_actions_on_ip (ip)
|
||||
#
|
||||
|
||||
class UserAction < ApplicationRecord
|
||||
|
||||
@@ -10,13 +10,10 @@
|
||||
# updated_at :datetime not null
|
||||
# register_status :integer default("0")
|
||||
# action_status :integer default("0")
|
||||
# is_delete :boolean default("0")
|
||||
# user_id :integer
|
||||
#
|
||||
# Indexes
|
||||
#
|
||||
# index_user_agents_on_ip (ip)
|
||||
# index_user_agents_on_user_id (user_id)
|
||||
# index_user_agents_on_ip (ip) UNIQUE
|
||||
#
|
||||
|
||||
class UserAgent < ApplicationRecord
|
||||
|
||||
@@ -22,12 +22,15 @@
|
||||
# school_id :integer
|
||||
# description :string(255) default("")
|
||||
# department_id :integer
|
||||
<<<<<<< HEAD
|
||||
# province :string(255)
|
||||
# city :string(255)
|
||||
# custom_department :string(255)
|
||||
# show_email :boolean default("0")
|
||||
# show_location :boolean default("0")
|
||||
# show_department :boolean default("0")
|
||||
=======
|
||||
>>>>>>> ed8d646d479bdcd84784909a024949bb8e4f093f
|
||||
#
|
||||
# Indexes
|
||||
#
|
||||
|
||||
@@ -24,7 +24,7 @@
|
||||
#
|
||||
|
||||
class Version < ApplicationRecord
|
||||
belongs_to :project, counter_cache: true
|
||||
belongs_to :project, counter_cache: true, touch: true
|
||||
has_many :issues, class_name: "Issue", foreign_key: "fixed_version_id"
|
||||
belongs_to :user, optional: true
|
||||
|
||||
|
||||
Reference in New Issue
Block a user