From: Tom Hughes Date: Wed, 29 May 2019 10:05:21 +0000 (+0100) Subject: Merge remote-tracking branch 'upstream/pull/2236' X-Git-Tag: live~2598 X-Git-Url: https://git.openstreetmap.org/rails.git/commitdiff_plain/21bf5d79d680f7dc0447b1b5980ad5ce0a4b830c?hp=ea68ac865ba4df5686ac111d4bd8679dc2a643a8 Merge remote-tracking branch 'upstream/pull/2236' --- diff --git a/app/models/acl.rb b/app/models/acl.rb index ea19c74b0..cf83e673c 100644 --- a/app/models/acl.rb +++ b/app/models/acl.rb @@ -2,7 +2,7 @@ # # Table name: acls # -# id :integer not null, primary key +# id :bigint(8) not null, primary key # address :inet # k :string not null # v :string diff --git a/app/models/changeset.rb b/app/models/changeset.rb index b98d213c7..d57086a8e 100644 --- a/app/models/changeset.rb +++ b/app/models/changeset.rb @@ -2,8 +2,8 @@ # # Table name: changesets # -# id :integer not null, primary key -# user_id :integer not null +# id :bigint(8) not null, primary key +# user_id :bigint(8) not null # created_at :datetime not null # min_lat :integer # max_lat :integer @@ -14,7 +14,7 @@ # # Indexes # -# changesets_bbox_idx (min_lat,max_lat,min_lon,max_lon) +# changesets_bbox_idx (min_lat,max_lat,min_lon,max_lon) USING gist # changesets_closed_at_idx (closed_at) # changesets_created_at_idx (created_at) # changesets_user_id_created_at_idx (user_id,created_at) diff --git a/app/models/changeset_comment.rb b/app/models/changeset_comment.rb index a0ad6f2ea..529641c7e 100644 --- a/app/models/changeset_comment.rb +++ b/app/models/changeset_comment.rb @@ -3,8 +3,8 @@ # Table name: changeset_comments # # id :integer not null, primary key -# changeset_id :integer not null -# author_id :integer not null +# changeset_id :bigint(8) not null +# author_id :bigint(8) not null # body :text not null # created_at :datetime not null # visible :boolean not null diff --git a/app/models/changeset_tag.rb b/app/models/changeset_tag.rb index 942fafb2a..751029e03 100644 --- a/app/models/changeset_tag.rb +++ b/app/models/changeset_tag.rb @@ -2,7 +2,7 @@ # # Table name: changeset_tags # -# changeset_id :integer not null, primary key +# changeset_id :bigint(8) not null, primary key # k :string default(""), not null, primary key # v :string default(""), not null # diff --git a/app/models/diary_comment.rb b/app/models/diary_comment.rb index ade7a64ea..4ae21be88 100644 --- a/app/models/diary_comment.rb +++ b/app/models/diary_comment.rb @@ -2,9 +2,9 @@ # # Table name: diary_comments # -# id :integer not null, primary key -# diary_entry_id :integer not null -# user_id :integer not null +# id :bigint(8) not null, primary key +# diary_entry_id :bigint(8) not null +# user_id :bigint(8) not null # body :text not null # created_at :datetime not null # updated_at :datetime not null diff --git a/app/models/diary_entry.rb b/app/models/diary_entry.rb index d61241993..4affe8b59 100644 --- a/app/models/diary_entry.rb +++ b/app/models/diary_entry.rb @@ -2,8 +2,8 @@ # # Table name: diary_entries # -# id :integer not null, primary key -# user_id :integer not null +# id :bigint(8) not null, primary key +# user_id :bigint(8) not null # title :string not null # body :text not null # created_at :datetime not null diff --git a/app/models/diary_entry_subscription.rb b/app/models/diary_entry_subscription.rb index 6d24c4598..6e9a103ad 100644 --- a/app/models/diary_entry_subscription.rb +++ b/app/models/diary_entry_subscription.rb @@ -2,8 +2,8 @@ # # Table name: diary_entry_subscriptions # -# user_id :integer not null, primary key -# diary_entry_id :integer not null, primary key +# user_id :bigint(8) not null, primary key +# diary_entry_id :bigint(8) not null, primary key # # Indexes # diff --git a/app/models/friend.rb b/app/models/friend.rb index 86da87b93..615da1076 100644 --- a/app/models/friend.rb +++ b/app/models/friend.rb @@ -2,9 +2,9 @@ # # Table name: friends # -# id :integer not null, primary key -# user_id :integer not null -# friend_user_id :integer not null +# id :bigint(8) not null, primary key +# user_id :bigint(8) not null +# friend_user_id :bigint(8) not null # # Indexes # diff --git a/app/models/message.rb b/app/models/message.rb index e3a3ec921..4ab129e91 100644 --- a/app/models/message.rb +++ b/app/models/message.rb @@ -2,13 +2,13 @@ # # Table name: messages # -# id :integer not null, primary key -# from_user_id :integer not null +# id :bigint(8) not null, primary key +# from_user_id :bigint(8) not null # title :string not null # body :text not null # sent_on :datetime not null # message_read :boolean default(FALSE), not null -# to_user_id :integer not null +# to_user_id :bigint(8) not null # to_user_visible :boolean default(TRUE), not null # from_user_visible :boolean default(TRUE), not null # body_format :enum default("markdown"), not null diff --git a/app/models/node.rb b/app/models/node.rb index be561fb5d..91a1dbc41 100644 --- a/app/models/node.rb +++ b/app/models/node.rb @@ -2,14 +2,14 @@ # # Table name: current_nodes # -# id :integer not null, primary key +# id :bigint(8) not null, primary key # latitude :integer not null # longitude :integer not null -# changeset_id :integer not null +# changeset_id :bigint(8) not null # visible :boolean not null # timestamp :datetime not null -# tile :integer not null -# version :integer not null +# tile :bigint(8) not null +# version :bigint(8) not null # # Indexes # diff --git a/app/models/node_tag.rb b/app/models/node_tag.rb index 43915bc12..86404599b 100644 --- a/app/models/node_tag.rb +++ b/app/models/node_tag.rb @@ -2,7 +2,7 @@ # # Table name: current_node_tags # -# node_id :integer not null, primary key +# node_id :bigint(8) not null, primary key # k :string default(""), not null, primary key # v :string default(""), not null # diff --git a/app/models/note.rb b/app/models/note.rb index d96addbe7..d4f9a801f 100644 --- a/app/models/note.rb +++ b/app/models/note.rb @@ -2,10 +2,10 @@ # # Table name: notes # -# id :integer not null, primary key +# id :bigint(8) not null, primary key # latitude :integer not null # longitude :integer not null -# tile :integer not null +# tile :bigint(8) not null # updated_at :datetime not null # created_at :datetime not null # status :enum not null diff --git a/app/models/note_comment.rb b/app/models/note_comment.rb index f94032e1e..388f890a6 100644 --- a/app/models/note_comment.rb +++ b/app/models/note_comment.rb @@ -2,18 +2,18 @@ # # Table name: note_comments # -# id :integer not null, primary key -# note_id :integer not null +# id :bigint(8) not null, primary key +# note_id :bigint(8) not null # visible :boolean not null # created_at :datetime not null # author_ip :inet -# author_id :integer +# author_id :bigint(8) # body :text # event :enum # # Indexes # -# index_note_comments_on_body (to_tsvector('english'::regconfig, body)) +# index_note_comments_on_body (to_tsvector('english'::regconfig, body)) USING gin # index_note_comments_on_created_at (created_at) # note_comments_note_id_idx (note_id) # diff --git a/app/models/old_node.rb b/app/models/old_node.rb index 9690dc46c..cc2327d08 100644 --- a/app/models/old_node.rb +++ b/app/models/old_node.rb @@ -2,14 +2,14 @@ # # Table name: nodes # -# node_id :integer not null, primary key +# node_id :bigint(8) not null, primary key # latitude :integer not null # longitude :integer not null -# changeset_id :integer not null +# changeset_id :bigint(8) not null # visible :boolean not null # timestamp :datetime not null -# tile :integer not null -# version :integer not null, primary key +# tile :bigint(8) not null +# version :bigint(8) not null, primary key # redaction_id :integer # # Indexes diff --git a/app/models/old_node_tag.rb b/app/models/old_node_tag.rb index 77b78751b..a3e1c3aaf 100644 --- a/app/models/old_node_tag.rb +++ b/app/models/old_node_tag.rb @@ -2,8 +2,8 @@ # # Table name: node_tags # -# node_id :integer not null, primary key -# version :integer not null, primary key +# node_id :bigint(8) not null, primary key +# version :bigint(8) not null, primary key # k :string default(""), not null, primary key # v :string default(""), not null # diff --git a/app/models/old_relation.rb b/app/models/old_relation.rb index 3470561ce..109f7d968 100644 --- a/app/models/old_relation.rb +++ b/app/models/old_relation.rb @@ -2,10 +2,10 @@ # # Table name: relations # -# relation_id :integer default(0), not null, primary key -# changeset_id :integer not null +# relation_id :bigint(8) default(0), not null, primary key +# changeset_id :bigint(8) not null # timestamp :datetime not null -# version :integer not null, primary key +# version :bigint(8) not null, primary key # visible :boolean default(TRUE), not null # redaction_id :integer # diff --git a/app/models/old_relation_member.rb b/app/models/old_relation_member.rb index a74637435..f8d4a359f 100644 --- a/app/models/old_relation_member.rb +++ b/app/models/old_relation_member.rb @@ -2,11 +2,11 @@ # # Table name: relation_members # -# relation_id :integer default(0), not null, primary key +# relation_id :bigint(8) default(0), not null, primary key # member_type :enum not null -# member_id :integer not null +# member_id :bigint(8) not null # member_role :string not null -# version :integer default(0), not null, primary key +# version :bigint(8) default(0), not null, primary key # sequence_id :integer default(0), not null, primary key # # Indexes diff --git a/app/models/old_relation_tag.rb b/app/models/old_relation_tag.rb index 4a247949c..c674f708b 100644 --- a/app/models/old_relation_tag.rb +++ b/app/models/old_relation_tag.rb @@ -2,10 +2,10 @@ # # Table name: relation_tags # -# relation_id :integer default(0), not null, primary key +# relation_id :bigint(8) default(0), not null, primary key # k :string default(""), not null, primary key # v :string default(""), not null -# version :integer not null, primary key +# version :bigint(8) not null, primary key # # Foreign Keys # diff --git a/app/models/old_way.rb b/app/models/old_way.rb index baca05d33..31e230c38 100644 --- a/app/models/old_way.rb +++ b/app/models/old_way.rb @@ -2,10 +2,10 @@ # # Table name: ways # -# way_id :integer default(0), not null, primary key -# changeset_id :integer not null +# way_id :bigint(8) default(0), not null, primary key +# changeset_id :bigint(8) not null # timestamp :datetime not null -# version :integer not null, primary key +# version :bigint(8) not null, primary key # visible :boolean default(TRUE), not null # redaction_id :integer # diff --git a/app/models/old_way_node.rb b/app/models/old_way_node.rb index e1627d3fa..836e76e47 100644 --- a/app/models/old_way_node.rb +++ b/app/models/old_way_node.rb @@ -2,10 +2,10 @@ # # Table name: way_nodes # -# way_id :integer not null, primary key -# node_id :integer not null -# version :integer not null, primary key -# sequence_id :integer not null, primary key +# way_id :bigint(8) not null, primary key +# node_id :bigint(8) not null +# version :bigint(8) not null, primary key +# sequence_id :bigint(8) not null, primary key # # Indexes # diff --git a/app/models/old_way_tag.rb b/app/models/old_way_tag.rb index 5832f6d4f..ae4ad605e 100644 --- a/app/models/old_way_tag.rb +++ b/app/models/old_way_tag.rb @@ -2,10 +2,10 @@ # # Table name: way_tags # -# way_id :integer default(0), not null, primary key +# way_id :bigint(8) default(0), not null, primary key # k :string not null, primary key # v :string not null -# version :integer not null, primary key +# version :bigint(8) not null, primary key # # Foreign Keys # diff --git a/app/models/redaction.rb b/app/models/redaction.rb index e6d748706..d9b2a5579 100644 --- a/app/models/redaction.rb +++ b/app/models/redaction.rb @@ -7,7 +7,7 @@ # description :text # created_at :datetime # updated_at :datetime -# user_id :integer not null +# user_id :bigint(8) not null # description_format :enum default("markdown"), not null # # Foreign Keys diff --git a/app/models/relation.rb b/app/models/relation.rb index 884e96ed7..bcac9d04b 100644 --- a/app/models/relation.rb +++ b/app/models/relation.rb @@ -2,11 +2,11 @@ # # Table name: current_relations # -# id :integer not null, primary key -# changeset_id :integer not null +# id :bigint(8) not null, primary key +# changeset_id :bigint(8) not null # timestamp :datetime not null # visible :boolean not null -# version :integer not null +# version :bigint(8) not null # # Indexes # diff --git a/app/models/relation_member.rb b/app/models/relation_member.rb index 3e5cdfca2..7c399c3a8 100644 --- a/app/models/relation_member.rb +++ b/app/models/relation_member.rb @@ -2,9 +2,9 @@ # # Table name: current_relation_members # -# relation_id :integer not null, primary key +# relation_id :bigint(8) not null, primary key # member_type :enum not null -# member_id :integer not null +# member_id :bigint(8) not null # member_role :string not null # sequence_id :integer default(0), not null, primary key # diff --git a/app/models/relation_tag.rb b/app/models/relation_tag.rb index 151615f72..b186f505d 100644 --- a/app/models/relation_tag.rb +++ b/app/models/relation_tag.rb @@ -2,7 +2,7 @@ # # Table name: current_relation_tags # -# relation_id :integer not null, primary key +# relation_id :bigint(8) not null, primary key # k :string default(""), not null, primary key # v :string default(""), not null # diff --git a/app/models/trace.rb b/app/models/trace.rb index 1a2dfc9e4..af2c0af3b 100644 --- a/app/models/trace.rb +++ b/app/models/trace.rb @@ -2,11 +2,11 @@ # # Table name: gpx_files # -# id :integer not null, primary key -# user_id :integer not null +# id :bigint(8) not null, primary key +# user_id :bigint(8) not null # visible :boolean default(TRUE), not null # name :string default(""), not null -# size :integer +# size :bigint(8) # latitude :float # longitude :float # timestamp :datetime not null diff --git a/app/models/tracepoint.rb b/app/models/tracepoint.rb index 445688c55..6473c9430 100644 --- a/app/models/tracepoint.rb +++ b/app/models/tracepoint.rb @@ -6,9 +6,9 @@ # trackid :integer not null # latitude :integer not null # longitude :integer not null -# gpx_id :integer not null +# gpx_id :bigint(8) not null # timestamp :datetime -# tile :integer +# tile :bigint(8) # # Indexes # diff --git a/app/models/tracetag.rb b/app/models/tracetag.rb index 84b6c6dfa..8d2f4fffa 100644 --- a/app/models/tracetag.rb +++ b/app/models/tracetag.rb @@ -2,9 +2,9 @@ # # Table name: gpx_file_tags # -# gpx_id :integer default(0), not null +# gpx_id :bigint(8) default(0), not null # tag :string not null -# id :integer not null, primary key +# id :bigint(8) not null, primary key # # Indexes # diff --git a/app/models/user.rb b/app/models/user.rb index dbe91ab0f..2979b13d7 100644 --- a/app/models/user.rb +++ b/app/models/user.rb @@ -3,7 +3,7 @@ # Table name: users # # email :string not null -# id :integer not null, primary key +# id :bigint(8) not null, primary key # pass_crypt :string not null # creation_time :datetime not null # display_name :string default(""), not null @@ -33,7 +33,7 @@ # image_use_gravatar :boolean default(FALSE), not null # image_content_type :string # auth_provider :string -# home_tile :integer +# home_tile :bigint(8) # tou_agreed :datetime # # Indexes diff --git a/app/models/user_block.rb b/app/models/user_block.rb index 27bc40498..92cee16cd 100644 --- a/app/models/user_block.rb +++ b/app/models/user_block.rb @@ -3,12 +3,12 @@ # Table name: user_blocks # # id :integer not null, primary key -# user_id :integer not null -# creator_id :integer not null +# user_id :bigint(8) not null +# creator_id :bigint(8) not null # reason :text not null # ends_at :datetime not null # needs_view :boolean default(FALSE), not null -# revoker_id :integer +# revoker_id :bigint(8) # created_at :datetime # updated_at :datetime # reason_format :enum default("markdown"), not null diff --git a/app/models/user_preference.rb b/app/models/user_preference.rb index 3963bd02a..583ced3c5 100644 --- a/app/models/user_preference.rb +++ b/app/models/user_preference.rb @@ -2,7 +2,7 @@ # # Table name: user_preferences # -# user_id :integer not null, primary key +# user_id :bigint(8) not null, primary key # k :string not null, primary key # v :string not null # diff --git a/app/models/user_role.rb b/app/models/user_role.rb index adf569a03..f3d48cade 100644 --- a/app/models/user_role.rb +++ b/app/models/user_role.rb @@ -3,11 +3,11 @@ # Table name: user_roles # # id :integer not null, primary key -# user_id :integer not null +# user_id :bigint(8) not null # role :enum not null # created_at :datetime # updated_at :datetime -# granter_id :integer not null +# granter_id :bigint(8) not null # # Indexes # diff --git a/app/models/user_token.rb b/app/models/user_token.rb index 0d1e16e8a..844357d8d 100644 --- a/app/models/user_token.rb +++ b/app/models/user_token.rb @@ -2,8 +2,8 @@ # # Table name: user_tokens # -# id :integer not null, primary key -# user_id :integer not null +# id :bigint(8) not null, primary key +# user_id :bigint(8) not null # token :string not null # expiry :datetime not null # referer :text diff --git a/app/models/way.rb b/app/models/way.rb index ddb82ed1e..6fcaf39cc 100644 --- a/app/models/way.rb +++ b/app/models/way.rb @@ -2,11 +2,11 @@ # # Table name: current_ways # -# id :integer not null, primary key -# changeset_id :integer not null +# id :bigint(8) not null, primary key +# changeset_id :bigint(8) not null # timestamp :datetime not null # visible :boolean not null -# version :integer not null +# version :bigint(8) not null # # Indexes # diff --git a/app/models/way_node.rb b/app/models/way_node.rb index 5c09cd740..0788a631c 100644 --- a/app/models/way_node.rb +++ b/app/models/way_node.rb @@ -2,9 +2,9 @@ # # Table name: current_way_nodes # -# way_id :integer not null, primary key -# node_id :integer not null -# sequence_id :integer not null, primary key +# way_id :bigint(8) not null, primary key +# node_id :bigint(8) not null +# sequence_id :bigint(8) not null, primary key # # Indexes # diff --git a/app/models/way_tag.rb b/app/models/way_tag.rb index c4df0abb5..6637c1585 100644 --- a/app/models/way_tag.rb +++ b/app/models/way_tag.rb @@ -2,7 +2,7 @@ # # Table name: current_way_tags # -# way_id :integer not null, primary key +# way_id :bigint(8) not null, primary key # k :string default(""), not null, primary key # v :string default(""), not null #