From: Tom Hughes Date: Wed, 25 Oct 2017 07:16:33 +0000 (+0100) Subject: Merge remote-tracking branch 'upstream/pull/1652' X-Git-Tag: live~3286 X-Git-Url: https://git.openstreetmap.org/rails.git/commitdiff_plain/38640e0253e8984974d275f2c232eb057ba86c84?hp=29a780eb1af9ca5f8b55e53cf89701b297707607 Merge remote-tracking branch 'upstream/pull/1652' --- diff --git a/Gemfile b/Gemfile index 772e6f300..79bc0d10e 100644 --- a/Gemfile +++ b/Gemfile @@ -104,6 +104,7 @@ gem "logstasher" # Gems useful for development group :development do + gem "annotate" gem "listen" gem "vendorer" end diff --git a/Gemfile.lock b/Gemfile.lock index e4b521c1a..653098e8e 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -43,6 +43,9 @@ GEM tzinfo (~> 1.1) addressable (2.5.2) public_suffix (>= 2.0.2, < 4.0) + annotate (2.7.2) + activerecord (>= 3.2, < 6.0) + rake (>= 10.4, < 13.0) arel (8.0.0) ast (2.3.0) autoprefixer-rails (7.1.5) @@ -351,6 +354,7 @@ PLATFORMS DEPENDENCIES SystemTimer (>= 1.1.3) actionpack-page_caching + annotate autoprefixer-rails bigdecimal (~> 1.1.0) canonical-rails @@ -408,4 +412,4 @@ DEPENDENCIES webmock BUNDLED WITH - 1.13.7 + 1.15.4 diff --git a/app/assets/javascripts/index.js b/app/assets/javascripts/index.js index b30564a1a..00e6a9d32 100644 --- a/app/assets/javascripts/index.js +++ b/app/assets/javascripts/index.js @@ -114,6 +114,7 @@ $(document).ready(function () { .removeClass('leaflet-control-locate leaflet-bar') .addClass('control-locate') .children("a") + .attr('href', '#') .removeClass('leaflet-bar-part leaflet-bar-part-single') .addClass('control-button'); diff --git a/app/assets/javascripts/user.js b/app/assets/javascripts/user.js index 44872a78c..1c73d3430 100644 --- a/app/assets/javascripts/user.js +++ b/app/assets/javascripts/user.js @@ -28,6 +28,7 @@ $(document).ready(function () { .removeClass('leaflet-control-locate leaflet-bar') .addClass('control-locate') .children("a") + .attr('href', '#') .removeClass('leaflet-bar-part leaflet-bar-part-single') .addClass('control-button'); diff --git a/app/controllers/changeset_controller.rb b/app/controllers/changeset_controller.rb index 531ec17ee..fbd4417d0 100644 --- a/app/controllers/changeset_controller.rb +++ b/app/controllers/changeset_controller.rb @@ -28,7 +28,7 @@ class ChangesetController < ApplicationController cs = Changeset.from_xml(request.raw_post, true) # Assume that Changeset.from_xml has thrown an exception if there is an error parsing the xml - cs.user_id = current_user.id + cs.user = current_user cs.save_with_tags! # Subscribe user to changeset comments @@ -496,7 +496,7 @@ class ChangesetController < ApplicationController # changesets if they're non-public setup_user_auth - raise OSM::APINotFoundError if current_user.nil? || current_user.id != u.id + raise OSM::APINotFoundError if current_user.nil? || current_user != u end changesets.where(:user_id => u.id) diff --git a/app/controllers/message_controller.rb b/app/controllers/message_controller.rb index 9b39f1c05..29b74c848 100644 --- a/app/controllers/message_controller.rb +++ b/app/controllers/message_controller.rb @@ -18,8 +18,8 @@ class MessageController < ApplicationController flash[:error] = t "message.new.limit_exceeded" else @message = Message.new(message_params) - @message.to_user_id = @this_user.id - @message.from_user_id = current_user.id + @message.recipient = @this_user + @message.sender = current_user @message.sent_on = Time.now.getutc if @message.save @@ -38,7 +38,7 @@ class MessageController < ApplicationController def reply message = Message.find(params[:message_id]) - if message.to_user_id == current_user.id + if message.recipient == current_user message.update(:message_read => true) @message = Message.new( @@ -64,8 +64,8 @@ class MessageController < ApplicationController @title = t "message.read.title" @message = Message.find(params[:message_id]) - if @message.to_user_id == current_user.id || @message.from_user_id == current_user.id - @message.message_read = true if @message.to_user_id == current_user.id + if @message.recipient == current_user || @message.sender == current_user + @message.message_read = true if @message.recipient == current_user @message.save else flash[:notice] = t "message.read.wrong_user", :user => current_user.display_name diff --git a/app/controllers/user_blocks_controller.rb b/app/controllers/user_blocks_controller.rb index 45cd53728..d5820568e 100644 --- a/app/controllers/user_blocks_controller.rb +++ b/app/controllers/user_blocks_controller.rb @@ -20,7 +20,7 @@ class UserBlocksController < ApplicationController end def show - if current_user && current_user.id == @user_block.user_id + if current_user && current_user == @user_block.user @user_block.needs_view = false @user_block.save! end @@ -37,8 +37,8 @@ class UserBlocksController < ApplicationController def create if @valid_params @user_block = UserBlock.new( - :user_id => @this_user.id, - :creator_id => current_user.id, + :user => @this_user, + :creator => current_user, :reason => params[:user_block][:reason], :ends_at => Time.now.getutc + @block_period.hours, :needs_view => params[:user_block][:needs_view] @@ -57,7 +57,7 @@ class UserBlocksController < ApplicationController def update if @valid_params - if @user_block.creator_id != current_user.id + if @user_block.creator != current_user flash[:error] = t("user_block.update.only_creator_can_edit") redirect_to :action => "edit" elsif @user_block.update_attributes( diff --git a/app/controllers/user_controller.rb b/app/controllers/user_controller.rb index e418e103f..e25d3c8b6 100644 --- a/app/controllers/user_controller.rb +++ b/app/controllers/user_controller.rb @@ -411,8 +411,8 @@ class UserController < ApplicationController if @new_friend if request.post? friend = Friend.new - friend.user_id = current_user.id - friend.friend_user_id = @new_friend.id + friend.befriender = current_user + friend.befriendee = @new_friend if current_user.is_friends_with?(@new_friend) flash[:warning] = t "user.make_friend.already_a_friend", :name => @new_friend.display_name elsif friend.save diff --git a/app/controllers/user_roles_controller.rb b/app/controllers/user_roles_controller.rb index 2f5b5a84c..536790dc5 100644 --- a/app/controllers/user_roles_controller.rb +++ b/app/controllers/user_roles_controller.rb @@ -10,7 +10,7 @@ class UserRolesController < ApplicationController before_action :in_role, :only => [:revoke] def grant - @this_user.roles.create(:role => @role, :granter_id => current_user.id) + @this_user.roles.create(:role => @role, :granter => current_user) redirect_to :controller => "user", :action => "view", :display_name => @this_user.display_name end diff --git a/app/models/access_token.rb b/app/models/access_token.rb index f690c9754..e5ba2e240 100644 --- a/app/models/access_token.rb +++ b/app/models/access_token.rb @@ -1,3 +1,40 @@ +# == Schema Information +# +# Table name: oauth_tokens +# +# id :integer not null, primary key +# user_id :integer +# type :string(20) +# client_application_id :integer +# token :string(50) +# secret :string(50) +# authorized_at :datetime +# invalidated_at :datetime +# created_at :datetime +# updated_at :datetime +# allow_read_prefs :boolean default(FALSE), not null +# allow_write_prefs :boolean default(FALSE), not null +# allow_write_diary :boolean default(FALSE), not null +# allow_write_api :boolean default(FALSE), not null +# allow_read_gpx :boolean default(FALSE), not null +# allow_write_gpx :boolean default(FALSE), not null +# callback_url :string +# verifier :string(20) +# scope :string +# valid_to :datetime +# allow_write_notes :boolean default(FALSE), not null +# +# Indexes +# +# index_oauth_tokens_on_token (token) UNIQUE +# index_oauth_tokens_on_user_id (user_id) +# +# Foreign Keys +# +# oauth_tokens_client_application_id_fkey (client_application_id => client_applications.id) +# oauth_tokens_user_id_fkey (user_id => users.id) +# + class AccessToken < OauthToken belongs_to :user belongs_to :client_application diff --git a/app/models/acl.rb b/app/models/acl.rb index 529ccbe3b..095bad89b 100644 --- a/app/models/acl.rb +++ b/app/models/acl.rb @@ -1,3 +1,18 @@ +# == Schema Information +# +# Table name: acls +# +# id :integer not null, primary key +# address :inet +# k :string not null +# v :string +# domain :string +# +# Indexes +# +# acls_k_idx (k) +# + class Acl < ActiveRecord::Base validates :k, :presence => true diff --git a/app/models/changeset.rb b/app/models/changeset.rb index a4daab801..37d26e0a7 100644 --- a/app/models/changeset.rb +++ b/app/models/changeset.rb @@ -1,3 +1,30 @@ +# == Schema Information +# +# Table name: changesets +# +# id :integer not null, primary key +# user_id :integer not null +# created_at :datetime not null +# min_lat :integer +# max_lat :integer +# min_lon :integer +# max_lon :integer +# closed_at :datetime not null +# num_changes :integer default(0), not null +# +# Indexes +# +# changesets_bbox_idx (min_lat,max_lat,min_lon,max_lon) +# changesets_closed_at_idx (closed_at) +# changesets_created_at_idx (created_at) +# changesets_user_id_created_at_idx (user_id,created_at) +# changesets_user_id_id_idx (user_id,id) +# +# Foreign Keys +# +# changesets_user_id_fkey (user_id => users.id) +# + class Changeset < ActiveRecord::Base require "xml/libxml" diff --git a/app/models/changeset_comment.rb b/app/models/changeset_comment.rb index 2fedadff0..756fda14c 100644 --- a/app/models/changeset_comment.rb +++ b/app/models/changeset_comment.rb @@ -1,3 +1,24 @@ +# == Schema Information +# +# Table name: changeset_comments +# +# id :integer not null, primary key +# changeset_id :integer not null +# author_id :integer not null +# body :text not null +# created_at :datetime not null +# visible :boolean not null +# +# Indexes +# +# index_changeset_comments_on_created_at (created_at) +# +# Foreign Keys +# +# changeset_comments_author_id_fkey (author_id => users.id) +# changeset_comments_changeset_id_fkey (changeset_id => changesets.id) +# + class ChangesetComment < ActiveRecord::Base belongs_to :changeset belongs_to :author, :class_name => "User" diff --git a/app/models/changeset_tag.rb b/app/models/changeset_tag.rb index 7ffba0dc3..8d6cd45ac 100644 --- a/app/models/changeset_tag.rb +++ b/app/models/changeset_tag.rb @@ -1,3 +1,20 @@ +# == Schema Information +# +# Table name: changeset_tags +# +# changeset_id :integer not null, primary key +# k :string default(""), not null, primary key +# v :string default(""), not null +# +# Indexes +# +# changeset_tags_id_idx (changeset_id) +# +# Foreign Keys +# +# changeset_tags_id_fkey (changeset_id => changesets.id) +# + class ChangesetTag < ActiveRecord::Base self.primary_keys = "changeset_id", "k" diff --git a/app/models/client_application.rb b/app/models/client_application.rb index 85b6ba68a..90523a265 100644 --- a/app/models/client_application.rb +++ b/app/models/client_application.rb @@ -1,3 +1,35 @@ +# == Schema Information +# +# Table name: client_applications +# +# id :integer not null, primary key +# name :string +# url :string +# support_url :string +# callback_url :string +# key :string(50) +# secret :string(50) +# user_id :integer +# created_at :datetime +# updated_at :datetime +# allow_read_prefs :boolean default(FALSE), not null +# allow_write_prefs :boolean default(FALSE), not null +# allow_write_diary :boolean default(FALSE), not null +# allow_write_api :boolean default(FALSE), not null +# allow_read_gpx :boolean default(FALSE), not null +# allow_write_gpx :boolean default(FALSE), not null +# allow_write_notes :boolean default(FALSE), not null +# +# Indexes +# +# index_client_applications_on_key (key) UNIQUE +# index_client_applications_on_user_id (user_id) +# +# Foreign Keys +# +# client_applications_user_id_fkey (user_id => users.id) +# + require "oauth" class ClientApplication < ActiveRecord::Base diff --git a/app/models/diary_comment.rb b/app/models/diary_comment.rb index 2796eb612..8a99c7b2c 100644 --- a/app/models/diary_comment.rb +++ b/app/models/diary_comment.rb @@ -1,3 +1,27 @@ +# == Schema Information +# +# Table name: diary_comments +# +# id :integer not null, primary key +# diary_entry_id :integer not null +# user_id :integer not null +# body :text not null +# created_at :datetime not null +# updated_at :datetime not null +# visible :boolean default(TRUE), not null +# body_format :enum default("markdown"), not null +# +# Indexes +# +# diary_comment_user_id_created_at_index (user_id,created_at) +# diary_comments_entry_id_idx (diary_entry_id,id) UNIQUE +# +# Foreign Keys +# +# diary_comments_diary_entry_id_fkey (diary_entry_id => diary_entries.id) +# diary_comments_user_id_fkey (user_id => users.id) +# + class DiaryComment < ActiveRecord::Base belongs_to :user belongs_to :diary_entry diff --git a/app/models/diary_entry.rb b/app/models/diary_entry.rb index 143ddc1dc..2a24d8002 100644 --- a/app/models/diary_entry.rb +++ b/app/models/diary_entry.rb @@ -1,3 +1,31 @@ +# == Schema Information +# +# Table name: diary_entries +# +# id :integer not null, primary key +# user_id :integer not null +# title :string not null +# body :text not null +# created_at :datetime not null +# updated_at :datetime not null +# latitude :float +# longitude :float +# language_code :string default("en"), not null +# visible :boolean default(TRUE), not null +# body_format :enum default("markdown"), not null +# +# Indexes +# +# diary_entry_created_at_index (created_at) +# diary_entry_language_code_created_at_index (language_code,created_at) +# diary_entry_user_id_created_at_index (user_id,created_at) +# +# Foreign Keys +# +# diary_entries_language_code_fkey (language_code => languages.code) +# diary_entries_user_id_fkey (user_id => users.id) +# + class DiaryEntry < ActiveRecord::Base belongs_to :user, :counter_cache => true belongs_to :language, :foreign_key => "language_code" diff --git a/app/models/diary_entry_subscription.rb b/app/models/diary_entry_subscription.rb index 8b96f6074..6d24c4598 100644 --- a/app/models/diary_entry_subscription.rb +++ b/app/models/diary_entry_subscription.rb @@ -1,3 +1,20 @@ +# == Schema Information +# +# Table name: diary_entry_subscriptions +# +# user_id :integer not null, primary key +# diary_entry_id :integer not null, primary key +# +# Indexes +# +# index_diary_entry_subscriptions_on_diary_entry_id (diary_entry_id) +# +# Foreign Keys +# +# diary_entry_subscriptions_diary_entry_id_fkey (diary_entry_id => diary_entries.id) +# diary_entry_subscriptions_user_id_fkey (user_id => users.id) +# + class DiaryEntrySubscription < ActiveRecord::Base self.primary_keys = "user_id", "diary_entry_id" diff --git a/app/models/friend.rb b/app/models/friend.rb index d740a711c..86da87b93 100644 --- a/app/models/friend.rb +++ b/app/models/friend.rb @@ -1,3 +1,22 @@ +# == Schema Information +# +# Table name: friends +# +# id :integer not null, primary key +# user_id :integer not null +# friend_user_id :integer not null +# +# Indexes +# +# friends_user_id_idx (user_id) +# user_id_idx (friend_user_id) +# +# Foreign Keys +# +# friends_friend_user_id_fkey (friend_user_id => users.id) +# friends_user_id_fkey (user_id => users.id) +# + class Friend < ActiveRecord::Base belongs_to :befriender, :class_name => "User", :foreign_key => :user_id belongs_to :befriendee, :class_name => "User", :foreign_key => :friend_user_id diff --git a/app/models/language.rb b/app/models/language.rb index 776182e63..67e98569b 100644 --- a/app/models/language.rb +++ b/app/models/language.rb @@ -1,3 +1,12 @@ +# == Schema Information +# +# Table name: languages +# +# code :string not null, primary key +# english_name :string not null +# native_name :string +# + class Language < ActiveRecord::Base self.primary_key = "code" diff --git a/app/models/message.rb b/app/models/message.rb index 2a0cea4a1..aff628e03 100644 --- a/app/models/message.rb +++ b/app/models/message.rb @@ -1,3 +1,29 @@ +# == Schema Information +# +# Table name: messages +# +# id :integer not null, primary key +# from_user_id :integer 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_visible :boolean default(TRUE), not null +# from_user_visible :boolean default(TRUE), not null +# body_format :enum default("markdown"), not null +# +# Indexes +# +# messages_from_user_id_idx (from_user_id) +# messages_to_user_id_idx (to_user_id) +# +# Foreign Keys +# +# messages_from_user_id_fkey (from_user_id => users.id) +# messages_to_user_id_fkey (to_user_id => users.id) +# + require "validators" class Message < ActiveRecord::Base diff --git a/app/models/node.rb b/app/models/node.rb index edbbbc251..c09fcbd67 100644 --- a/app/models/node.rb +++ b/app/models/node.rb @@ -1,3 +1,26 @@ +# == Schema Information +# +# Table name: current_nodes +# +# id :integer not null, primary key +# latitude :integer not null +# longitude :integer not null +# changeset_id :integer not null +# visible :boolean not null +# timestamp :datetime not null +# tile :integer not null +# version :integer not null +# +# Indexes +# +# current_nodes_tile_idx (tile) +# current_nodes_timestamp_idx (timestamp) +# +# Foreign Keys +# +# current_nodes_changeset_id_fkey (changeset_id => changesets.id) +# + class Node < ActiveRecord::Base require "xml/libxml" diff --git a/app/models/node_tag.rb b/app/models/node_tag.rb index 5f2f9efc9..20065b993 100644 --- a/app/models/node_tag.rb +++ b/app/models/node_tag.rb @@ -1,3 +1,16 @@ +# == Schema Information +# +# Table name: current_node_tags +# +# node_id :integer not null, primary key +# k :string default(""), not null, primary key +# v :string default(""), not null +# +# Foreign Keys +# +# current_node_tags_id_fkey (node_id => current_nodes.id) +# + class NodeTag < ActiveRecord::Base self.table_name = "current_node_tags" self.primary_keys = "node_id", "k" diff --git a/app/models/note.rb b/app/models/note.rb index d2c36071d..b7f6928b8 100644 --- a/app/models/note.rb +++ b/app/models/note.rb @@ -1,3 +1,23 @@ +# == Schema Information +# +# Table name: notes +# +# id :integer not null, primary key +# latitude :integer not null +# longitude :integer not null +# tile :integer not null +# updated_at :datetime not null +# created_at :datetime not null +# status :enum not null +# closed_at :datetime +# +# Indexes +# +# notes_created_at_idx (created_at) +# notes_tile_status_idx (tile,status) +# notes_updated_at_idx (updated_at) +# + class Note < ActiveRecord::Base include GeoRecord diff --git a/app/models/note_comment.rb b/app/models/note_comment.rb index aa8635aad..f8450d0a3 100644 --- a/app/models/note_comment.rb +++ b/app/models/note_comment.rb @@ -1,3 +1,28 @@ +# == Schema Information +# +# Table name: note_comments +# +# id :integer not null, primary key +# note_id :integer not null +# visible :boolean not null +# created_at :datetime not null +# author_ip :inet +# author_id :integer +# body :text +# event :enum +# +# Indexes +# +# index_note_comments_on_body (to_tsvector('english'::regconfig, body)) +# index_note_comments_on_created_at (created_at) +# note_comments_note_id_idx (note_id) +# +# Foreign Keys +# +# note_comments_author_id_fkey (author_id => users.id) +# note_comments_note_id_fkey (note_id => notes.id) +# + class NoteComment < ActiveRecord::Base belongs_to :note, :foreign_key => :note_id, :touch => true belongs_to :author, :class_name => "User", :foreign_key => :author_id diff --git a/app/models/oauth2_token.rb b/app/models/oauth2_token.rb index 2c0b1f508..3435b25a3 100644 --- a/app/models/oauth2_token.rb +++ b/app/models/oauth2_token.rb @@ -1,3 +1,40 @@ +# == Schema Information +# +# Table name: oauth_tokens +# +# id :integer not null, primary key +# user_id :integer +# type :string(20) +# client_application_id :integer +# token :string(50) +# secret :string(50) +# authorized_at :datetime +# invalidated_at :datetime +# created_at :datetime +# updated_at :datetime +# allow_read_prefs :boolean default(FALSE), not null +# allow_write_prefs :boolean default(FALSE), not null +# allow_write_diary :boolean default(FALSE), not null +# allow_write_api :boolean default(FALSE), not null +# allow_read_gpx :boolean default(FALSE), not null +# allow_write_gpx :boolean default(FALSE), not null +# callback_url :string +# verifier :string(20) +# scope :string +# valid_to :datetime +# allow_write_notes :boolean default(FALSE), not null +# +# Indexes +# +# index_oauth_tokens_on_token (token) UNIQUE +# index_oauth_tokens_on_user_id (user_id) +# +# Foreign Keys +# +# oauth_tokens_client_application_id_fkey (client_application_id => client_applications.id) +# oauth_tokens_user_id_fkey (user_id => users.id) +# + class Oauth2Token < AccessToken attr_accessor :state diff --git a/app/models/oauth2_verifier.rb b/app/models/oauth2_verifier.rb index 1568cac99..3eca1038c 100644 --- a/app/models/oauth2_verifier.rb +++ b/app/models/oauth2_verifier.rb @@ -1,3 +1,40 @@ +# == Schema Information +# +# Table name: oauth_tokens +# +# id :integer not null, primary key +# user_id :integer +# type :string(20) +# client_application_id :integer +# token :string(50) +# secret :string(50) +# authorized_at :datetime +# invalidated_at :datetime +# created_at :datetime +# updated_at :datetime +# allow_read_prefs :boolean default(FALSE), not null +# allow_write_prefs :boolean default(FALSE), not null +# allow_write_diary :boolean default(FALSE), not null +# allow_write_api :boolean default(FALSE), not null +# allow_read_gpx :boolean default(FALSE), not null +# allow_write_gpx :boolean default(FALSE), not null +# callback_url :string +# verifier :string(20) +# scope :string +# valid_to :datetime +# allow_write_notes :boolean default(FALSE), not null +# +# Indexes +# +# index_oauth_tokens_on_token (token) UNIQUE +# index_oauth_tokens_on_user_id (user_id) +# +# Foreign Keys +# +# oauth_tokens_client_application_id_fkey (client_application_id => client_applications.id) +# oauth_tokens_user_id_fkey (user_id => users.id) +# + class Oauth2Verifier < OauthToken validates :user, :presence => true, :associated => true diff --git a/app/models/oauth_nonce.rb b/app/models/oauth_nonce.rb index e0510dcbf..0952f068e 100644 --- a/app/models/oauth_nonce.rb +++ b/app/models/oauth_nonce.rb @@ -1,3 +1,18 @@ +# == Schema Information +# +# Table name: oauth_nonces +# +# id :integer not null, primary key +# nonce :string +# timestamp :integer +# created_at :datetime +# updated_at :datetime +# +# Indexes +# +# index_oauth_nonces_on_nonce_and_timestamp (nonce,timestamp) UNIQUE +# + # Simple store of nonces. The OAuth Spec requires that any given pair of nonce and timestamps are unique. # Thus you can use the same nonce with a different timestamp and viceversa. class OauthNonce < ActiveRecord::Base diff --git a/app/models/oauth_token.rb b/app/models/oauth_token.rb index 9a3e7de9e..fd332723f 100644 --- a/app/models/oauth_token.rb +++ b/app/models/oauth_token.rb @@ -1,3 +1,40 @@ +# == Schema Information +# +# Table name: oauth_tokens +# +# id :integer not null, primary key +# user_id :integer +# type :string(20) +# client_application_id :integer +# token :string(50) +# secret :string(50) +# authorized_at :datetime +# invalidated_at :datetime +# created_at :datetime +# updated_at :datetime +# allow_read_prefs :boolean default(FALSE), not null +# allow_write_prefs :boolean default(FALSE), not null +# allow_write_diary :boolean default(FALSE), not null +# allow_write_api :boolean default(FALSE), not null +# allow_read_gpx :boolean default(FALSE), not null +# allow_write_gpx :boolean default(FALSE), not null +# callback_url :string +# verifier :string(20) +# scope :string +# valid_to :datetime +# allow_write_notes :boolean default(FALSE), not null +# +# Indexes +# +# index_oauth_tokens_on_token (token) UNIQUE +# index_oauth_tokens_on_user_id (user_id) +# +# Foreign Keys +# +# oauth_tokens_client_application_id_fkey (client_application_id => client_applications.id) +# oauth_tokens_user_id_fkey (user_id => users.id) +# + class OauthToken < ActiveRecord::Base belongs_to :client_application belongs_to :user diff --git a/app/models/old_node.rb b/app/models/old_node.rb index b103e5c73..9690dc46c 100644 --- a/app/models/old_node.rb +++ b/app/models/old_node.rb @@ -1,3 +1,29 @@ +# == Schema Information +# +# Table name: nodes +# +# node_id :integer not null, primary key +# latitude :integer not null +# longitude :integer not null +# changeset_id :integer not null +# visible :boolean not null +# timestamp :datetime not null +# tile :integer not null +# version :integer not null, primary key +# redaction_id :integer +# +# Indexes +# +# nodes_changeset_id_idx (changeset_id) +# nodes_tile_idx (tile) +# nodes_timestamp_idx (timestamp) +# +# Foreign Keys +# +# nodes_changeset_id_fkey (changeset_id => changesets.id) +# nodes_redaction_id_fkey (redaction_id => redactions.id) +# + class OldNode < ActiveRecord::Base include GeoRecord include ConsistencyValidations diff --git a/app/models/old_node_tag.rb b/app/models/old_node_tag.rb index f1df02c84..9e03d34f9 100644 --- a/app/models/old_node_tag.rb +++ b/app/models/old_node_tag.rb @@ -1,3 +1,17 @@ +# == Schema Information +# +# Table name: node_tags +# +# node_id :integer not null, primary key +# version :integer not null, primary key +# k :string default(""), not null, primary key +# v :string default(""), not null +# +# Foreign Keys +# +# node_tags_id_fkey (node_id => nodes.node_id) +# + class OldNodeTag < ActiveRecord::Base self.table_name = "node_tags" self.primary_keys = "node_id", "version", "k" diff --git a/app/models/old_relation.rb b/app/models/old_relation.rb index 0e85122a4..3470561ce 100644 --- a/app/models/old_relation.rb +++ b/app/models/old_relation.rb @@ -1,3 +1,25 @@ +# == Schema Information +# +# Table name: relations +# +# relation_id :integer default(0), not null, primary key +# changeset_id :integer not null +# timestamp :datetime not null +# version :integer not null, primary key +# visible :boolean default(TRUE), not null +# redaction_id :integer +# +# Indexes +# +# relations_changeset_id_idx (changeset_id) +# relations_timestamp_idx (timestamp) +# +# Foreign Keys +# +# relations_changeset_id_fkey (changeset_id => changesets.id) +# relations_redaction_id_fkey (redaction_id => redactions.id) +# + class OldRelation < ActiveRecord::Base include ConsistencyValidations include ObjectMetadata diff --git a/app/models/old_relation_member.rb b/app/models/old_relation_member.rb index 77a5a3786..a74637435 100644 --- a/app/models/old_relation_member.rb +++ b/app/models/old_relation_member.rb @@ -1,3 +1,23 @@ +# == Schema Information +# +# Table name: relation_members +# +# relation_id :integer default(0), not null, primary key +# member_type :enum not null +# member_id :integer not null +# member_role :string not null +# version :integer default(0), not null, primary key +# sequence_id :integer default(0), not null, primary key +# +# Indexes +# +# relation_members_member_idx (member_type,member_id) +# +# Foreign Keys +# +# relation_members_id_fkey (relation_id => relations.relation_id) +# + class OldRelationMember < ActiveRecord::Base self.table_name = "relation_members" self.primary_keys = "relation_id", "version", "sequence_id" diff --git a/app/models/old_relation_tag.rb b/app/models/old_relation_tag.rb index ad3b72734..052b60853 100644 --- a/app/models/old_relation_tag.rb +++ b/app/models/old_relation_tag.rb @@ -1,3 +1,17 @@ +# == Schema Information +# +# Table name: relation_tags +# +# relation_id :integer default(0), not null, primary key +# k :string default(""), not null, primary key +# v :string default(""), not null +# version :integer not null, primary key +# +# Foreign Keys +# +# relation_tags_id_fkey (relation_id => relations.relation_id) +# + class OldRelationTag < ActiveRecord::Base self.table_name = "relation_tags" self.primary_keys = "relation_id", "version", "k" diff --git a/app/models/old_way.rb b/app/models/old_way.rb index 63c4d8b65..baca05d33 100644 --- a/app/models/old_way.rb +++ b/app/models/old_way.rb @@ -1,3 +1,25 @@ +# == Schema Information +# +# Table name: ways +# +# way_id :integer default(0), not null, primary key +# changeset_id :integer not null +# timestamp :datetime not null +# version :integer not null, primary key +# visible :boolean default(TRUE), not null +# redaction_id :integer +# +# Indexes +# +# ways_changeset_id_idx (changeset_id) +# ways_timestamp_idx (timestamp) +# +# Foreign Keys +# +# ways_changeset_id_fkey (changeset_id => changesets.id) +# ways_redaction_id_fkey (redaction_id => redactions.id) +# + class OldWay < ActiveRecord::Base include ConsistencyValidations include ObjectMetadata diff --git a/app/models/old_way_node.rb b/app/models/old_way_node.rb index 23ff503ed..e1627d3fa 100644 --- a/app/models/old_way_node.rb +++ b/app/models/old_way_node.rb @@ -1,3 +1,21 @@ +# == Schema Information +# +# 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 +# +# Indexes +# +# way_nodes_node_idx (node_id) +# +# Foreign Keys +# +# way_nodes_id_fkey (way_id => ways.way_id) +# + class OldWayNode < ActiveRecord::Base self.table_name = "way_nodes" self.primary_keys = "way_id", "version", "sequence_id" diff --git a/app/models/old_way_tag.rb b/app/models/old_way_tag.rb index 69bd2b186..8fffebc25 100644 --- a/app/models/old_way_tag.rb +++ b/app/models/old_way_tag.rb @@ -1,3 +1,17 @@ +# == Schema Information +# +# Table name: way_tags +# +# way_id :integer default(0), not null, primary key +# k :string not null, primary key +# v :string not null +# version :integer not null, primary key +# +# Foreign Keys +# +# way_tags_id_fkey (way_id => ways.way_id) +# + class OldWayTag < ActiveRecord::Base self.table_name = "way_tags" self.primary_keys = "way_id", "version", "k" diff --git a/app/models/redaction.rb b/app/models/redaction.rb index 04f002e36..b835864db 100644 --- a/app/models/redaction.rb +++ b/app/models/redaction.rb @@ -1,3 +1,20 @@ +# == Schema Information +# +# Table name: redactions +# +# id :integer not null, primary key +# title :string +# description :text +# created_at :datetime +# updated_at :datetime +# user_id :integer not null +# description_format :enum default("markdown"), not null +# +# Foreign Keys +# +# redactions_user_id_fkey (user_id => users.id) +# + ## # Redaction represents a record associated with a particular # action on the database to hide revisions from the history diff --git a/app/models/relation.rb b/app/models/relation.rb index 545336793..275cafec2 100644 --- a/app/models/relation.rb +++ b/app/models/relation.rb @@ -1,3 +1,22 @@ +# == Schema Information +# +# Table name: current_relations +# +# id :integer not null, primary key +# changeset_id :integer not null +# timestamp :datetime not null +# visible :boolean not null +# version :integer not null +# +# Indexes +# +# current_relations_timestamp_idx (timestamp) +# +# Foreign Keys +# +# current_relations_changeset_id_fkey (changeset_id => changesets.id) +# + class Relation < ActiveRecord::Base require "xml/libxml" diff --git a/app/models/relation_member.rb b/app/models/relation_member.rb index e5c783f5c..3e5cdfca2 100644 --- a/app/models/relation_member.rb +++ b/app/models/relation_member.rb @@ -1,3 +1,22 @@ +# == Schema Information +# +# Table name: current_relation_members +# +# relation_id :integer not null, primary key +# member_type :enum not null +# member_id :integer not null +# member_role :string not null +# sequence_id :integer default(0), not null, primary key +# +# Indexes +# +# current_relation_members_member_idx (member_type,member_id) +# +# Foreign Keys +# +# current_relation_members_id_fkey (relation_id => current_relations.id) +# + class RelationMember < ActiveRecord::Base self.table_name = "current_relation_members" self.primary_keys = "relation_id", "sequence_id" diff --git a/app/models/relation_tag.rb b/app/models/relation_tag.rb index 382606795..5dc609987 100644 --- a/app/models/relation_tag.rb +++ b/app/models/relation_tag.rb @@ -1,3 +1,16 @@ +# == Schema Information +# +# Table name: current_relation_tags +# +# relation_id :integer not null, primary key +# k :string default(""), not null, primary key +# v :string default(""), not null +# +# Foreign Keys +# +# current_relation_tags_id_fkey (relation_id => current_relations.id) +# + class RelationTag < ActiveRecord::Base self.table_name = "current_relation_tags" self.primary_keys = "relation_id", "k" diff --git a/app/models/request_token.rb b/app/models/request_token.rb index c0f019486..335a735bc 100644 --- a/app/models/request_token.rb +++ b/app/models/request_token.rb @@ -1,3 +1,40 @@ +# == Schema Information +# +# Table name: oauth_tokens +# +# id :integer not null, primary key +# user_id :integer +# type :string(20) +# client_application_id :integer +# token :string(50) +# secret :string(50) +# authorized_at :datetime +# invalidated_at :datetime +# created_at :datetime +# updated_at :datetime +# allow_read_prefs :boolean default(FALSE), not null +# allow_write_prefs :boolean default(FALSE), not null +# allow_write_diary :boolean default(FALSE), not null +# allow_write_api :boolean default(FALSE), not null +# allow_read_gpx :boolean default(FALSE), not null +# allow_write_gpx :boolean default(FALSE), not null +# callback_url :string +# verifier :string(20) +# scope :string +# valid_to :datetime +# allow_write_notes :boolean default(FALSE), not null +# +# Indexes +# +# index_oauth_tokens_on_token (token) UNIQUE +# index_oauth_tokens_on_user_id (user_id) +# +# Foreign Keys +# +# oauth_tokens_client_application_id_fkey (client_application_id => client_applications.id) +# oauth_tokens_user_id_fkey (user_id => users.id) +# + class RequestToken < OauthToken attr_accessor :provided_oauth_verifier diff --git a/app/models/trace.rb b/app/models/trace.rb index a2c1b79a7..214b0b647 100644 --- a/app/models/trace.rb +++ b/app/models/trace.rb @@ -1,3 +1,30 @@ +# == Schema Information +# +# Table name: gpx_files +# +# id :integer not null, primary key +# user_id :integer not null +# visible :boolean default(TRUE), not null +# name :string default(""), not null +# size :integer +# latitude :float +# longitude :float +# timestamp :datetime not null +# description :string default(""), not null +# inserted :boolean not null +# visibility :enum default("public"), not null +# +# Indexes +# +# gpx_files_timestamp_idx (timestamp) +# gpx_files_user_id_idx (user_id) +# gpx_files_visible_visibility_idx (visible,visibility) +# +# Foreign Keys +# +# gpx_files_user_id_fkey (user_id => users.id) +# + class Trace < ActiveRecord::Base self.table_name = "gpx_files" diff --git a/app/models/tracepoint.rb b/app/models/tracepoint.rb index 9485b8a14..445688c55 100644 --- a/app/models/tracepoint.rb +++ b/app/models/tracepoint.rb @@ -1,3 +1,25 @@ +# == Schema Information +# +# Table name: gps_points +# +# altitude :float +# trackid :integer not null +# latitude :integer not null +# longitude :integer not null +# gpx_id :integer not null +# timestamp :datetime +# tile :integer +# +# Indexes +# +# points_gpxid_idx (gpx_id) +# points_tile_idx (tile) +# +# Foreign Keys +# +# gps_points_gpx_id_fkey (gpx_id => gpx_files.id) +# + class Tracepoint < ActiveRecord::Base include GeoRecord diff --git a/app/models/tracetag.rb b/app/models/tracetag.rb index 9d2195920..1a4fbd398 100644 --- a/app/models/tracetag.rb +++ b/app/models/tracetag.rb @@ -1,3 +1,21 @@ +# == Schema Information +# +# Table name: gpx_file_tags +# +# gpx_id :integer default(0), not null +# tag :string not null +# id :integer not null, primary key +# +# Indexes +# +# gpx_file_tags_gpxid_idx (gpx_id) +# gpx_file_tags_tag_idx (tag) +# +# Foreign Keys +# +# gpx_file_tags_gpx_id_fkey (gpx_id => gpx_files.id) +# + class Tracetag < ActiveRecord::Base self.table_name = "gpx_file_tags" diff --git a/app/models/user.rb b/app/models/user.rb index 3ce48e7cd..7a8414ec0 100644 --- a/app/models/user.rb +++ b/app/models/user.rb @@ -1,3 +1,48 @@ +# == Schema Information +# +# Table name: users +# +# email :string not null +# id :integer not null, primary key +# pass_crypt :string not null +# creation_time :datetime not null +# display_name :string default(""), not null +# data_public :boolean default(FALSE), not null +# description :text default(""), not null +# home_lat :float +# home_lon :float +# home_zoom :integer default(3) +# nearby :integer default(50) +# pass_salt :string +# image_file_name :text +# email_valid :boolean default(FALSE), not null +# new_email :string +# creation_ip :string +# languages :string +# status :enum default("pending"), not null +# terms_agreed :datetime +# consider_pd :boolean default(FALSE), not null +# auth_uid :string +# preferred_editor :string +# terms_seen :boolean default(FALSE), not null +# description_format :enum default("markdown"), not null +# image_fingerprint :string +# changesets_count :integer default(0), not null +# traces_count :integer default(0), not null +# diary_entries_count :integer default(0), not null +# image_use_gravatar :boolean default(FALSE), not null +# image_content_type :string +# auth_provider :string +# +# Indexes +# +# users_auth_idx (auth_provider,auth_uid) UNIQUE +# users_display_name_idx (display_name) UNIQUE +# users_display_name_lower_idx (lower((display_name)::text)) +# users_email_idx (email) UNIQUE +# users_email_lower_idx (lower((email)::text)) +# + class User < ActiveRecord::Base require "xml/libxml" diff --git a/app/models/user_block.rb b/app/models/user_block.rb index eb0daba65..4f9cf1128 100644 --- a/app/models/user_block.rb +++ b/app/models/user_block.rb @@ -1,3 +1,29 @@ +# == Schema Information +# +# Table name: user_blocks +# +# id :integer not null, primary key +# user_id :integer not null +# creator_id :integer not null +# reason :text not null +# ends_at :datetime not null +# needs_view :boolean default(FALSE), not null +# revoker_id :integer +# created_at :datetime +# updated_at :datetime +# reason_format :enum default("markdown"), not null +# +# Indexes +# +# index_user_blocks_on_user_id (user_id) +# +# Foreign Keys +# +# user_blocks_moderator_id_fkey (creator_id => users.id) +# user_blocks_revoker_id_fkey (revoker_id => users.id) +# user_blocks_user_id_fkey (user_id => users.id) +# + class UserBlock < ActiveRecord::Base validate :moderator_permissions diff --git a/app/models/user_preference.rb b/app/models/user_preference.rb index 7c65a5899..69b0e9dde 100644 --- a/app/models/user_preference.rb +++ b/app/models/user_preference.rb @@ -1,3 +1,16 @@ +# == Schema Information +# +# Table name: user_preferences +# +# user_id :integer not null, primary key +# k :string not null, primary key +# v :string not null +# +# Foreign Keys +# +# user_preferences_user_id_fkey (user_id => users.id) +# + class UserPreference < ActiveRecord::Base self.primary_keys = "user_id", "k" diff --git a/app/models/user_role.rb b/app/models/user_role.rb index 967850145..adf569a03 100644 --- a/app/models/user_role.rb +++ b/app/models/user_role.rb @@ -1,3 +1,24 @@ +# == Schema Information +# +# Table name: user_roles +# +# id :integer not null, primary key +# user_id :integer not null +# role :enum not null +# created_at :datetime +# updated_at :datetime +# granter_id :integer not null +# +# Indexes +# +# user_roles_id_role_unique (user_id,role) UNIQUE +# +# Foreign Keys +# +# user_roles_granter_id_fkey (granter_id => users.id) +# user_roles_user_id_fkey (user_id => users.id) +# + class UserRole < ActiveRecord::Base belongs_to :user belongs_to :granter, :class_name => "User" diff --git a/app/models/user_token.rb b/app/models/user_token.rb index faa540e67..0d1e16e8a 100644 --- a/app/models/user_token.rb +++ b/app/models/user_token.rb @@ -1,3 +1,23 @@ +# == Schema Information +# +# Table name: user_tokens +# +# id :integer not null, primary key +# user_id :integer not null +# token :string not null +# expiry :datetime not null +# referer :text +# +# Indexes +# +# user_tokens_token_idx (token) UNIQUE +# user_tokens_user_id_idx (user_id) +# +# Foreign Keys +# +# user_tokens_user_id_fkey (user_id => users.id) +# + class UserToken < ActiveRecord::Base belongs_to :user diff --git a/app/models/way.rb b/app/models/way.rb index 212998ccc..1954f744c 100644 --- a/app/models/way.rb +++ b/app/models/way.rb @@ -1,3 +1,22 @@ +# == Schema Information +# +# Table name: current_ways +# +# id :integer not null, primary key +# changeset_id :integer not null +# timestamp :datetime not null +# visible :boolean not null +# version :integer not null +# +# Indexes +# +# current_ways_timestamp_idx (timestamp) +# +# Foreign Keys +# +# current_ways_changeset_id_fkey (changeset_id => changesets.id) +# + class Way < ActiveRecord::Base require "xml/libxml" diff --git a/app/models/way_node.rb b/app/models/way_node.rb index 30d901356..5c09cd740 100644 --- a/app/models/way_node.rb +++ b/app/models/way_node.rb @@ -1,3 +1,21 @@ +# == Schema Information +# +# Table name: current_way_nodes +# +# way_id :integer not null, primary key +# node_id :integer not null +# sequence_id :integer not null, primary key +# +# Indexes +# +# current_way_nodes_node_idx (node_id) +# +# Foreign Keys +# +# current_way_nodes_id_fkey (way_id => current_ways.id) +# current_way_nodes_node_id_fkey (node_id => current_nodes.id) +# + class WayNode < ActiveRecord::Base self.table_name = "current_way_nodes" self.primary_keys = "way_id", "sequence_id" diff --git a/app/models/way_tag.rb b/app/models/way_tag.rb index 99d435d33..8ef75f38e 100644 --- a/app/models/way_tag.rb +++ b/app/models/way_tag.rb @@ -1,3 +1,16 @@ +# == Schema Information +# +# Table name: current_way_tags +# +# way_id :integer not null, primary key +# k :string default(""), not null, primary key +# v :string default(""), not null +# +# Foreign Keys +# +# current_way_tags_id_fkey (way_id => current_ways.id) +# + class WayTag < ActiveRecord::Base self.table_name = "current_way_tags" self.primary_keys = "way_id", "k" diff --git a/config/locales/he.yml b/config/locales/he.yml index 97b949145..67ec865e5 100644 --- a/config/locales/he.yml +++ b/config/locales/he.yml @@ -1837,11 +1837,10 @@ he: התרומה. email address: 'כתובת דוא״ל:' confirm email address: 'אימות כתובת דוא״ל:' - not displayed publicly: הכתובת שלף לא מוצגת בפומבי, ר׳ את מידיניות - פרטיות למידע נוסף - display name: 'שם התצוגה:' - display name description: שם המשתמש שלך, שמוצג בפומבי. אפשר לשנות את זה בהעפות + not displayed publicly: הכתובת שלך לא מוצגת בפומבי, למידע נוסף ראה מדיניות פרטיות + display name: 'שם להצגה:' + display name description: שם המשתמש שלך, שמוצג בפומבי. אפשר לשנות את זה בהעדפות שלך. external auth: 'אימות עם צד שלישי:' password: 'סיסמה:' diff --git a/config/locales/kab.yml b/config/locales/kab.yml index 4c10058b3..328a70c92 100644 --- a/config/locales/kab.yml +++ b/config/locales/kab.yml @@ -509,6 +509,7 @@ kab: census: Talast taddadant bridge: swing: Tillegwit yeddawaren + viaduct: Tiqená¹­aṛt "yes": Tiqená¹­ert building: "yes": Akerrus @@ -531,6 +532,7 @@ kab: primary: Abrid agejdan primary_link: Abrid agejdan raceway: Amnenniḍ + rest_area: Amḍiq n ustaεfu road: Abrid secondary: Abrid asnawan secondary_link: Abrid asnawan diff --git a/config/locales/ko.yml b/config/locales/ko.yml index 2b25f7f5d..e7434ac97 100644 --- a/config/locales/ko.yml +++ b/config/locales/ko.yml @@ -1266,11 +1266,11 @@ ko: email_confirm_plain: greeting: 안녕하세요, hopefully_you: 누군가가 아마 자신이 %{server_url} 에 %{new_address} (으)로 이메일 주소를 바꾸고 싶습니다. - click_the_link: 만약 당신이라면 바뀜을 확인하기 위해 아래 링크를 클릭하세요. + click_the_link: 만약 당신이라면 바뀐 내용을 확인하기 위해 아래의 링크를 클릭하세요. email_confirm_html: greeting: 안녕하세요, hopefully_you: 누군가가 아마 자신이 %{server_url} 에 %{new_address} (으)로 이메일 주소를 바꾸고 싶습니다. - click_the_link: 만약 당신이라면 바뀜을 확인하기 위해 아래 링크를 클릭하세요. + click_the_link: 만약 당신이라면 바뀐 내용을 확인하기 위해 아래 링크를 클릭하세요. lost_password: subject: '[OpenStreetMap] 비밀번호 재설정 요청' lost_password_plain: @@ -1408,10 +1408,10 @@ ko: Adobe.com에서 플래시 플레이어를 다운로드할 수 있습니다. 몇 가지 다른 설정 또한 OpenStreetMap 편집을 위해 사용할 수 있습니다. - potlatch_unsaved_changes: 바뀜을 저장하지 않았습니다. (Potlatch에 저장하려면 라이브 모드에서 편집하는 경우, - 현재 길이나 점을 선택을 해제하거나 저장 버튼이 있다면 저장을 클릭해야 합니다.) + potlatch_unsaved_changes: 바뀐 내용을 저장하지 않았습니다. (Potlatch에 저장하려면 라이브 모드에서 편집하는 + 경우 현재 길이나 점의 선택을 해제하시고, 저장 버튼이 있다면 저장을 클릭해야 합니다.) potlatch2_not_configured: Potlatch 2가 설정되지 않았습니다 - 자세한 정보는 http://wiki.openstreetmap.org/wiki/The_Rails_Port - potlatch2_unsaved_changes: 바뀜을 저장하지 않았습니다. (Potlatch 2에서 저장하려면 저장을 클릭해야 합니다.) + potlatch2_unsaved_changes: 바뀐 내용을 저장하지 않았습니다. (Potlatch 2에서 저장하려면 저장을 클릭해야 합니다.) id_not_configured: iD가 설정되지 않았습니다 no_iframe_support: 브라우저가 이 기능에 필요한 HTML iframe을 지원하지 않습니다. sidebar: diff --git a/config/locales/tl.yml b/config/locales/tl.yml index 008482441..10ca57196 100644 --- a/config/locales/tl.yml +++ b/config/locales/tl.yml @@ -126,6 +126,9 @@ tl: changeset: title: 'Pangkat ng pagbabago: %{id}' belongs_to: May-akda + comment: Mga puna (%{count}) + hidden_commented_by: Nakatagong puna mula kay %{user} %{when} + ang nakaraan changesetxml: XML ng pangkat ng pagbabago osmchangexml: XML ng osmChange feed: @@ -177,8 +180,12 @@ tl: key: Ang pahina ng paglalarawan ng wiki para sa tatak na %{key} tag: Ang pahina ng paglalarawan ng wiki para sa tatak na %{key}=%{value} wikipedia_link: Ang %{page} ng artikulo sa Wikipedia + telephone_link: Tawagan %{phone_number} note: description: Paglalarawan + commented_by: Puna mula kay %{user} %{when} ang + nakaraan + hidden_by: Itinago ni %{user} %{when} ang nakaraan changeset: changeset_paging_nav: showing_page: Ika-%{page} na pahina @@ -200,12 +207,17 @@ tl: title_friend: Mga pangkat ng pagbabago ng mga kaibigan mo title_nearby: Mga pangkat ng pagbabago ng kalapit na mga tagagamit empty: Walang natagpuang mga aparato/gadyet. + empty_area: Walang pangkat ng pagbabago sa lugar na ito. empty_user: Walang pangkat ng pagbabago mula sa tagagamit na ito. - no_more_area: Walang pangkat ng pagbabago sa lugar na ito. + no_more: Wala nang mga pangkat ng pagbabago ang nakita. + no_more_area: Wala nang mga pangkat ng pagbabago sa lugar na ito. + no_more_user: Wala nang mga pangkat ng pagbabago mula sa tagagamit na ito. load_more: Magkarga pa timeout: sorry: Paumanhin, ang talaan ng mga pangkat ng pagbabagong hiniling mo ay naging napakatagal bago nakuhang muli. + rss: + comment: 'Bagong puna sa pangkat ng pagbabago #%{changeset_id} ni %{author}' diary_entry: new: title: Bagong Pagpapasok sa Talaarawan @@ -287,6 +299,7 @@ tl: newer_comments: Mas Bagong mga Pagpuna older_comments: Mas Lumang mga Puna export: + title: Iluwas start: area_to_export: Pook na Iluluwas manually_select: Kinakamay na pumili ng ibang lugar @@ -449,6 +462,7 @@ tl: building: "yes": Gusali craft: + brewery: Serbeserya carpenter: Anluwage gardener: Hardinero painter: Pintor @@ -576,6 +590,7 @@ tl: water_park: Liwasang Tubigan "yes": Pampalipas oras man_made: + lighthouse: Parola pipeline: Linya ng tubo tower: Tore works: Pabrika @@ -826,7 +841,7 @@ tl: edit: Baguhin history: Kasaysayan export: Iluwas - export_data: Iluwas ang Data + export_data: Iluwas ang Datos gps_traces: Mga Bakas ng GPS gps_traces_tooltip: Pamahalaan ang mga Bakas ng GPS user_diaries: Mga Talaarawan ng mga Tagagamit @@ -834,6 +849,8 @@ tl: edit_with: Mamatnugot sa pamamagitan ng %{editor} tag_line: Ang Malayang Mapa sa Daigdig ng Wiki intro_header: Maligayang pagdating sa OpenStreetMap! + intro_text: Ang OpenStreetMap ay isang mapa ng mundo na nilikha ng mga taong katulad + mo at malayang gamitin sa ilalim ng isang bukas na lisensya. intro_2_create_account: Lumikha ng isang akawnt ng tagagamit partners_html: Ang pagpapasinaya ay sinusuportahan ng %{ucl}, %{ic} at %{bytemark}, at iba pang %{partners}. @@ -947,7 +964,7 @@ tl: ng paglalathala ng Estado." contributors_gb_html: "Nagkakasiang mga Kaharian: Naglalaman ng Ordinansiya \nsa dato ng Pagsisiyasat © Karapatan sa Paglalathala - ng Korona at karapatan \nsa kalipunan ng dato 2010." + ng Korona at karapatan \nsa kalipunan ng dato 2010-12." contributors_footer_1_html: "Para sa karagdagang mga detalye ng mga ito, at iba pang pinanggalingan na ginamit \nupang mapainam ang OpenStreetMap, paki tingnan ang Pahina @@ -956,13 +973,21 @@ tl: ay hindi nagpapahiwatig na ang orihinal \nna tagapagbigay ng dato ay tumatangkilik sa OpenStreetMap, nagbibigay ng anumang garantiya, o \ntumatanggap ng anumang pananagutan." + infringement_title_html: Paglabag sa karapatang-ari + infringement_1_html: Ang mga tagapag-ambag ng OSM ay pinaalalahanan na huwag + magdagdag ng datos mula sa anumang mapagkukunan na may karapatang-ari na nakalaan + (halimbawa, Google Maps o naka-print na mga mapa) nang walang pahintulot mula + sa mga may hawak ng karapatang-ari. trademarks_title_html: Mga Trademark welcome_page: title: Maligayang pagdating! whats_on_the_map: title: Anong nasa Mapa + rules: + title: Mga Patakaran! questions: title: May mga tanong? + start_mapping: Simulan ang Pagmamapa fixthemap: title: Mag-ulat ng problema/ Ayusin ang mapa how_to_help: @@ -970,15 +995,37 @@ tl: help_page: welcome: title: Maligayang pagdating sa OSM + irc: + title: IRC about_page: next: Kasunod + copyright_html: ©Mga tagapag-ambag
ng OpenStreetMap + used_by: Ang %{name} ay nagpapatakbo ng dato ng mapa sa libu-libong mga website, + mga mobile na app, at aparatong hardware + lede_text: Ang OpenStreetMap ay nilikha ng isang komunidad ng mga nagmamapa na + nag-aambag at nagpapanatili ng dato tungkol sa mga kalsada, mga daanan, mga + kapihan, mga istasyon ng tren, at iba pa, sa buong mundo. + community_driven_html: |- + Ang komunidad ng OpenStreetMap ay iba-iba, masigasig, at lumalaki araw-araw. Ang aming mga tagapag-ambag ay binubuo ng mga tagahanga ng mapa, mga propesyonal ng GIS, mga inhinyero na nagpapatakbo sa mga server ng OSM, mga boluntaryo sa pagmamapa ng mga lugar na apektado ng kalamidad, at higit pa. + Upang matuto nang higit pa, tignan ang mga talaarawan ng mga tagagamit, mga blog ng komunidad, at ang websayt ng OSM Foundation. + open_data_title: Bukas na Dato + open_data_html: 'Ang OpenStreetMap ay bukas na datos: malaya kang gamitin + ito para sa anumang layunin hangga''t nagbigay ka ng kredito sa OpenStreetMap + at ang mga tagapag-ambag nito. Kung babaguhin mo o binuo mula sa data sa ilang + mga paraan, maaari mong ipamahagi ang mga resulta sa ilalim lamang ng parehong + lisensya. Tingnan ang pahina ng Karapatang-ari + at Lisensya para sa mga detalye.' + legal_html: |- + Ang site na ito at maraming iba pang mga kaugnay na serbisyo ay opisyal na pinatatakbo ng OpenStreetMap Foundation (OSMF) sa ngalan ng komunidad. Ang paggamit ng lahat ng mga serbisyo na pinatatakbo ng OSMF ay napapailalim sa aming Patakaran sa Tanggapang Paggamit at Patakaran sa Pagkapribado +
+ Mangyaring makipag-ugnay sa OSMF kung mayroon kang mga katanungan tungkol sa paglilisensya, karapatang-ari, o iba pang mga legal na isyu at katanungan. + partners_title: Mga Kawaksi notifier: diary_comment_notification: - subject: Si %{user} ng [OpenStreetMap] ay nagbigay ng puna sa ipinasok mo sa - talaarawan + subject: '[OpenStreetMap] Si %{user} ay nagbigay ng puna sa ipinasok mo sa talaarawan' hi: Kumusta %{to_user}, - header: 'Pinuna ni %{from_user} ang iyong kamakailang pagpapasok sa talaarawan - ng OpenStreetMap na may paksang %{subject}:' + header: 'Pinuna ni %{from_user} ang isang pagpapasok sa talaarawan ng OpenStreetMap + na may paksang %{subject}:' footer: Mababasa mo rin ang puna roon sa %{readurl} at maaari kang pumuna roon sa %{commenturl} o tumugon doon sa %{replyurl} message_notification: @@ -1041,7 +1088,10 @@ tl: anonymous: Isang di-nagpakilalang tagagamit greeting: Kumusta, changeset_comment_notification: + hi: Kumusta %{to_user}, greeting: Kumusta, + commented: + partial_changeset_without_comment: walang puna message: inbox: title: Kahon ng pumapasok @@ -1124,6 +1174,9 @@ tl: js_2: Ang OpenStreetMap ay gumagamit ng JavaScript para sa madulas nitong mapa. permalink: Permalink shortlink: Maikling kawing + license: + copyright: Karapatang-sipi ng OpenStreetMap at mga tagapag-ambag nito, sa + ilalim ng isang bukas na lisensya remote_failed: Nabigo ang pamamatnugot - tiyaking naikarga ang JOSM or Merkaartor at kung gumagana ang pagpipilian ng malayong pantaban edit: @@ -1363,6 +1416,8 @@ tl: not_a_moderator: Kailangan mong maging isang tagapamagitan upang maisagawa ang galaw na iyan. setup_user_auth: + blocked_zero_hour: Mayroon kang isang kagyat na mensahe sa websayt ng OpenStreetMap. + Kailangan mong basahin ang mensahe bago mo sagipin ang iyong mga pagbabago. blocked: Hinadlangan ang pagpunta mo sa API. Mangyaring lumagda sa ugnayang-mukha ng web upang makaalam ng marami pa. need_to_see_terms: Pansamantalang inantala ang pagpunta mo sa API. Mangyaring @@ -1397,8 +1452,8 @@ tl: url: 'URL ng Kahalip ng Kahilingan:' access_url: 'URL ng Kahalip ng Pagpapapunta:' authorize_url: 'Payagan ang URL:' - support_notice: Tinatangkilik namin ang HMAC-SHA1 (iminumungkahi) pati na ang - tekstong lantad na nasa pamamaraang ssl. + support_notice: Sinusuportahan namin ang mga lagda ng HMAC-SHA1 (iminumungkahi) + at RSA-SHA1. edit: Baguhin ang mga Detalye delete: Burahin ang Kliyente confirm: Natitiyak mo ba? @@ -1578,9 +1633,8 @@ tl: spam score: 'Puntos ng Basurang Liham:' description: Paglalarawan user location: Kinalalagyan ng tagagamit - if set location: Kapat itinakda mo ang kinalalagyan mo, isang marilag na mapa - at mga abubot ang lilitaw dito. Maitatakda mo ang iyong kinalalagyan ng tahanan - sa iyong pahina ng %{settings_link}. + if set location: Itakda ang iyong lokasyon ng bahay sa pahinang %{settings_link} + upang makita ang mga kalapit na tagagamit. settings_link_text: mga pagtatakda your friends: Mga kaibigan mo no friends: Hindi ka pa nagdaragdag ng sinumang mga kaibigan. @@ -1604,15 +1658,14 @@ tl: activate_user: Pasiglahin ang tagagamit na ito deactivate_user: Tanggalin ang prebelehiyo ng 'User' confirm_user: Tiyakin ang tagagamit na ito - hide_user: itago ang tagagamit na ito + hide_user: Itago ang Tagagamit na ito unhide_user: Huwag itago ang Tagagamit na ito delete_user: Burahin ang Tagagamit na ito confirm: Tiyakin friends_changesets: mga pagbabago ng mga kaibigan friends_diaries: mga lahok ng mga kaibigan nearby_changesets: mga pagtatakda ng pagbabago mula sa kalapit na mga tagagamit - nearby_diaries: Tumingin-tingin sa lahat ng mga inilahok sa talaarawan ng kanugnog - na mga tagagamit + nearby_diaries: mga inilahok sa talaarawan ng kalapit na mga tagagamit popup: your location: Kinalalagyan mo nearby mapper: Malapit na tagapagmapa @@ -1623,6 +1676,7 @@ tl: current email address: 'Pangkasalukuyang Tirahan ng E-liham:' new email address: 'Bagong Tirahan ng E-liham:' email never displayed publicly: (hindi kailanman ipinapakita sa madla) + external auth: 'Panlabas na Pagpapatunay:' openid: link: http://wiki.openstreetmap.org/wiki/OpenID link text: ano ba ito? @@ -1663,6 +1717,8 @@ tl: gravatar: gravatar: Gamitin ang Gravatar link text: ano ba ito? + disabled: Hindi na pinagana ang Gravatar. + enabled: Pinagana ang pagpapakita ng iyong Gravatar. new image: Magdagdag ng isang larawan keep image: Panatilihin ang kasalukuyang larawan delete image: Tanggalin ang pangkasalukuyang larawan @@ -1689,7 +1745,7 @@ tl: button: Tiyakin success: Natiyak ang akawnt mo, salamat sa pagpapatala! already active: Natiyak na ang akawnt na ito. - unknown token: Tila hindi yata umiiral ang kahalip na iyan. + unknown token: Tila lumipas o hindi umiiral ang kahalip na iyan. confirm_resend: success: Nagpadala kami ng isang paunawa ng pagtitiyak sa %{email} at kapag tiniyak mo nang iyong akawnt sa lalong madaling panahon maaari ka nang magsimula @@ -1717,7 +1773,7 @@ tl: failed: Paumanhin, nabigong maidagdag si %{name} bilang isang kaibigan. already_a_friend: Kaibigan ka na ni %{name}. remove_friend: - heading: Tanggalin si %{user} bilang isang kaibigan? + heading: Tanggalin bilang isang kaibigan si %{user}? button: Tanggalin bilang kaibigan success: Si %{name} ay tinanggal mula sa mga kaibigan mo. not_a_friend: Si %{name} ay hindi isa sa mga kaibigan mo. @@ -1874,6 +1930,7 @@ tl: heading: '%{block_on} hinadlangan ni %{block_by}' time_future: Magwawakas sa %{time} time_past: Nagwakas noong %{time} na ang nakalilipas + ago: '%{time} ang nakaraan' status: Kalagayan show: Ipakita edit: Baguhin @@ -1885,26 +1942,42 @@ tl: needs_view: Ang tagagamit ay kailangang lumagda muna bago mahawi ang hadlang na ito. note: + rss: + commented: bagong puna (malapit sa %{place}) mine: + id: Id description: Paglalarawan created_at: Nilikha Noong + last_changed: Huling binago + ago_html: '%{when} ang nakaraan' javascripts: close: Isara share: title: Ibahagi cancel: Huwag ituloy short_url: Maiksing URL + paste_html: Idikit ang HTML na ibabaon sa websayt map: + zoom: + in: Lumapit base: standard: Pamantayan cycle_map: Mapa ng Pagbibisikleta transport_map: Mapa ng Transportasyon + layers: + data: Dato ng Mapa + copyright: © Mga tagapag-ambag ng OpenStreetMap site: edit_tooltip: Baguhin ang mapa edit_disabled_tooltip: Lumapit upang baguhin ang mapa + map_data_zoom_in_tooltip: Lumapit upang makita ang datos ng mapa notes: show: hide: Itago + resolve: Lutasin + comment_and_resolve: Pumuna at Lutasin + query: + relation: Kaugnayan redaction: edit: description: Paglalarawan diff --git a/lib/tasks/auto_annotate_models.rake b/lib/tasks/auto_annotate_models.rake new file mode 100644 index 000000000..53252b769 --- /dev/null +++ b/lib/tasks/auto_annotate_models.rake @@ -0,0 +1,48 @@ +# NOTE: only doing this in development as some production environments (Heroku) +# NOTE: are sensitive to local FS writes, and besides -- it's just not proper +# NOTE: to have a dev-mode tool do its thing in production. +if Rails.env.development? + task :set_annotation_options do + # You can override any of these by setting an environment variable of the + # same name. + Annotate.set_defaults( + "routes" => "false", + "position_in_routes" => "before", + "position_in_class" => "before", + "position_in_test" => "before", + "position_in_fixture" => "before", + "position_in_factory" => "before", + "position_in_serializer" => "before", + "show_foreign_keys" => "true", + "show_indexes" => "true", + "simple_indexes" => "false", + "model_dir" => "app/models", + "root_dir" => "", + "include_version" => "false", + "require" => "", + "exclude_tests" => "true", + "exclude_fixtures" => "true", + "exclude_factories" => "true", + "exclude_serializers" => "true", + "exclude_scaffolds" => "true", + "exclude_controllers" => "true", + "exclude_helpers" => "true", + "ignore_model_sub_dir" => "false", + "ignore_columns" => nil, + "ignore_routes" => nil, + "ignore_unknown_models" => "false", + "hide_limit_column_types" => "integer,boolean", + "skip_on_db_migrate" => "false", + "format_bare" => "true", + "format_rdoc" => "false", + "format_markdown" => "false", + "sort" => "false", + "force" => "false", + "trace" => "false", + "wrapper_open" => nil, + "wrapper_close" => nil + ) + end + + Annotate.load_tasks +end