tr8n 3.2.1 → 3.2.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (75) hide show
  1. data/Gemfile.lock +1 -1
  2. data/README.rdoc +19 -13
  3. data/app/controllers/tr8n/base_controller.rb +5 -1
  4. data/app/controllers/tr8n/language_controller.rb +2 -2
  5. data/app/models/tr8n/base_filter.rb +21 -0
  6. data/app/models/tr8n/daily_language_metric.rb +46 -22
  7. data/app/models/tr8n/date_rule.rb +41 -22
  8. data/app/models/tr8n/gender_list_rule.rb +41 -22
  9. data/app/models/tr8n/gender_rule.rb +41 -22
  10. data/app/models/tr8n/glossary.rb +44 -27
  11. data/app/models/tr8n/glossary_filter.rb +56 -33
  12. data/app/models/tr8n/ip_location.rb +23 -0
  13. data/app/models/tr8n/ip_location_filter.rb +57 -34
  14. data/app/models/tr8n/language.rb +28 -0
  15. data/app/models/tr8n/language_case.rb +27 -0
  16. data/app/models/tr8n/language_case_filter.rb +53 -30
  17. data/app/models/tr8n/language_case_rule.rb +24 -0
  18. data/app/models/tr8n/language_case_rule_filter.rb +53 -30
  19. data/app/models/tr8n/language_case_value_map.rb +24 -0
  20. data/app/models/tr8n/language_case_value_map_filter.rb +68 -45
  21. data/app/models/tr8n/language_filter.rb +23 -0
  22. data/app/models/tr8n/language_forum_abuse_report.rb +56 -33
  23. data/app/models/tr8n/language_forum_abuse_report_filter.rb +57 -34
  24. data/app/models/tr8n/language_forum_message.rb +69 -46
  25. data/app/models/tr8n/language_forum_message_filter.rb +61 -38
  26. data/app/models/tr8n/language_forum_topic.rb +62 -41
  27. data/app/models/tr8n/language_forum_topic_filter.rb +61 -38
  28. data/app/models/tr8n/language_metric.rb +28 -1
  29. data/app/models/tr8n/language_metric_filter.rb +23 -0
  30. data/app/models/tr8n/language_rule.rb +23 -0
  31. data/app/models/tr8n/language_rule_filter.rb +72 -49
  32. data/app/models/tr8n/language_user.rb +86 -61
  33. data/app/models/tr8n/language_user_filter.rb +57 -34
  34. data/app/models/tr8n/list_rule.rb +41 -22
  35. data/app/models/tr8n/monthly_language_metric.rb +46 -22
  36. data/app/models/tr8n/numeric_rule.rb +41 -22
  37. data/app/models/tr8n/sync_log.rb +21 -0
  38. data/app/models/tr8n/sync_log_filter.rb +48 -27
  39. data/app/models/tr8n/total_language_metric.rb +46 -22
  40. data/app/models/tr8n/translation.rb +28 -0
  41. data/app/models/tr8n/translation_domain.rb +76 -56
  42. data/app/models/tr8n/translation_domain_filter.rb +49 -26
  43. data/app/models/tr8n/translation_filter.rb +57 -34
  44. data/app/models/tr8n/translation_key.rb +44 -8
  45. data/app/models/tr8n/translation_key_comment.rb +60 -37
  46. data/app/models/tr8n/translation_key_comment_filter.rb +53 -30
  47. data/app/models/tr8n/translation_key_filter.rb +68 -45
  48. data/app/models/tr8n/translation_key_lock.rb +81 -59
  49. data/app/models/tr8n/translation_key_lock_filter.rb +53 -30
  50. data/app/models/tr8n/translation_key_source.rb +22 -0
  51. data/app/models/tr8n/translation_key_source_filter.rb +53 -30
  52. data/app/models/tr8n/translation_source.rb +20 -0
  53. data/app/models/tr8n/translation_source_filter.rb +53 -30
  54. data/app/models/tr8n/translation_source_language.rb +58 -39
  55. data/app/models/tr8n/translation_vote.rb +56 -35
  56. data/app/models/tr8n/translation_vote_filter.rb +57 -34
  57. data/app/models/tr8n/translator.rb +38 -0
  58. data/app/models/tr8n/translator_filter.rb +73 -50
  59. data/app/models/tr8n/translator_following.rb +58 -38
  60. data/app/models/tr8n/translator_following_filter.rb +57 -34
  61. data/app/models/tr8n/translator_log.rb +25 -0
  62. data/app/models/tr8n/translator_log_filter.rb +72 -49
  63. data/app/models/tr8n/translator_metric.rb +27 -0
  64. data/app/models/tr8n/translator_metric_filter.rb +61 -38
  65. data/app/models/tr8n/translator_report.rb +23 -0
  66. data/app/models/tr8n/translator_report_filter.rb +53 -30
  67. data/app/models/tr8n/value_rule.rb +41 -22
  68. data/bin/{tr8n.rb → tr8n} +0 -0
  69. data/file +94 -0
  70. data/lib/tasks/dev.rake +162 -0
  71. data/lib/tr8n/config.rb +5 -1
  72. data/lib/tr8n/version.rb +1 -1
  73. data/local/tr8n_server/config/tr8n/config.yml +2 -1
  74. data/local/tr8n_server/db/schema.rb +0 -2
  75. metadata +45 -43
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- tr8n (3.2.1)
4
+ tr8n (3.2.2)
5
5
  coffee-script
6
6
  kaminari
7
7
  rails (>= 3.1.0)
@@ -1,16 +1,16 @@
1
1
  = Welcome to Tr8n Translation Engine
2
2
 
3
- Tr8n Translation Engine is a Rails Engine Plugin/Gem that provides a framework for crowd-sourced translation of any Rails based application.
3
+ Tr8n Translation Engine is a Rails Engine Plugin/Gem that provides a framework for crowd-sourced translations of your Rails application.
4
4
  The power of the engine comes from its simple and friendly user interface that allows site users as well as professional translators to rapidly
5
- translate the site into hundreds of languages. The flexible and robust rules engine that powers Tr8n allows for any combination of language
6
- specific rules in any translatable sentence. Users can provide information on what sentences depend on gender rules, number rules or other rules configured for each language.
7
- The language specific context and case rules can be registered and managed for any language in the advanced user interface. The engine
8
- provides a set of powerful administration tools that allow admins to manage any aspect of the engine; enabling and disabling its features
5
+ translate the site into hundreds of languages.
6
+
7
+ The rules engine that powers Tr8n allows translators to indicate whether sentences depend on gender rules, number rules or other rules configured for each language. The language specific context and case rules can be registered and managed for any language in the advanced user interface. The engine
8
+ provides a set of powerful administration tools that allow admins to configure any aspect of the engine; enabling and disabling its features
9
9
  and monitoring translation progress.
10
10
 
11
11
  http://img507.imageshack.us/img507/2876/tr8nlogo.png
12
12
 
13
- The Tr8n engine itself is based on a very robust and flexible pluggable architecture where rule types and the syntax of the "tr" tokens
13
+ The Tr8n engine is based on a robust and flexible pluggable architecture where rule types and even the syntax of the "tr" tokens
14
14
  can be configured or extended for any application deployment.
15
15
 
16
16
  Tr8n translation engine has been successfully deployed by the following companies:
@@ -21,8 +21,18 @@ Yammer Inc, http://www.yammer.com
21
21
 
22
22
  You can visit their web sites and see how it is being used. If your company is using Tr8n, please let me know and you will be added to the list.
23
23
 
24
+
24
25
  = Documentation
25
26
 
27
+ Please look through the following slides to get familiar with Tr8n concepts and features:
28
+
29
+ http://wiki.tr8n.org/slides
30
+
31
+ Once you are done, you can try out Tr8n features yourself by following the deployement instructions from one of the examples:
32
+
33
+ https://github.com/tr8n
34
+
35
+
26
36
  Configuration Guide
27
37
 
28
38
  https://github.com/berk/tr8n/wiki/4.-Configuration-Instructions
@@ -31,9 +41,9 @@ Integration Guide
31
41
 
32
42
  https://github.com/berk/tr8n/wiki/5.-Integration-Instructions
33
43
 
34
- Label Internationalization
44
+ Translation Markup Language (TML)
35
45
 
36
- https://github.com/berk/tr8n/wiki/6.-Tr8n-Syntax
46
+ https://github.com/berk/tr8n/wiki/6.-Tr8n-Syntax-and-Translation-Markup-Language
37
47
 
38
48
  Rules Engine
39
49
 
@@ -56,12 +66,8 @@ https://github.com/berk/tr8n/wiki/9.-Supported-Languages
56
66
 
57
67
  Add the following gems to your Gemfile:
58
68
 
59
- gem 'kaminari'
60
69
  gem 'will_filter', "~> 3.1.2"
61
- gem 'tr8n', "~> 3.1.1"
62
- gem 'sass'
63
- gem 'coffee-script'
64
-
70
+ gem 'tr8n', "~> 3.2.1"
65
71
 
66
72
  And run:
67
73
 
@@ -108,7 +108,11 @@ module Tr8n
108
108
  helper_method :tr8n_features_tabs
109
109
 
110
110
  def redirect_to_source
111
- return redirect_to(params[:source_url]) unless params[:source_url].blank?
111
+ # Do not allow redirects to external websites
112
+ escaped_origin_host = Regexp.escape("#{request.protocol}#{request.host}")
113
+ if(!params[:source_url].blank? && params[:source_url] =~ /^#{escaped_origin_host}/)
114
+ return redirect_to(params[:source_url])
115
+ end
112
116
  return redirect_to(request.env['HTTP_REFERER']) unless request.env['HTTP_REFERER'].blank?
113
117
  redirect_to_site_default_url
114
118
  end
@@ -209,7 +209,7 @@ module Tr8n
209
209
  def lists
210
210
  if request.post?
211
211
  if params[:language_action] == "remove"
212
- lu = Tr8n::LanguageUser.find(:first, :conditions => ["language_id = ? and user_id = ?", params[:language_id], tr8n_current_user.id])
212
+ lu = Tr8n::LanguageUser.find(:first, :conditions => ["language_id = ? and user_id = ?", params[:language_id].to_i, tr8n_current_user.id])
213
213
  lu.destroy
214
214
  end
215
215
  end
@@ -220,7 +220,7 @@ module Tr8n
220
220
  end
221
221
 
222
222
  def remove
223
- lu = Tr8n::LanguageUser.find(:first, :conditions => ["language_id = ? and user_id = ?", params[:language_id], tr8n_current_user.id])
223
+ lu = Tr8n::LanguageUser.find(:first, :conditions => ["language_id = ? and user_id = ?", params[:language_id].to_i, tr8n_current_user.id])
224
224
  lu.destroy if lu
225
225
  redirect_to_source
226
226
  end
@@ -20,11 +20,32 @@
20
20
  # OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
21
21
  # WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
22
22
  #++
23
+ #
24
+ #-- Tr8n::BaseFilter Schema Information
25
+ #
26
+ # Table name: will_filter_filters
27
+ #
28
+ # id INTEGER not null, primary key
29
+ # type varchar(255)
30
+ # name varchar(255)
31
+ # data text
32
+ # user_id integer
33
+ # model_class_name varchar(255)
34
+ # created_at datetime
35
+ # updated_at datetime
36
+ #
37
+ # Indexes
38
+ #
39
+ # index_will_filter_filters_on_user_id (user_id)
40
+ #
41
+ #++
23
42
 
24
43
  require 'will_filter'
25
44
 
26
45
  class Tr8n::BaseFilter < WillFilter::Filter
27
46
 
47
+ attr_accessible :name, :data, :user, :user_id, :model_class_name
48
+
28
49
  def definition
29
50
  meta = super
30
51
  meta.keys.each do |key|
@@ -1,25 +1,49 @@
1
- #--
2
- # Copyright (c) 2010-2012 Michael Berkovich, tr8n.net
3
- #
4
- # Permission is hereby granted, free of charge, to any person obtaining
5
- # a copy of this software and associated documentation files (the
6
- # "Software"), to deal in the Software without restriction, including
7
- # without limitation the rights to use, copy, modify, merge, publish,
8
- # distribute, sublicense, and/or sell copies of the Software, and to
9
- # permit persons to whom the Software is furnished to do so, subject to
10
- # the following conditions:
11
- #
12
- # The above copyright notice and this permission notice shall be
13
- # included in all copies or substantial portions of the Software.
14
- #
15
- # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
16
- # EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
17
- # MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
18
- # NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
19
- # LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
20
- # OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
21
- # WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
22
- #++
1
+ #--
2
+ # Copyright (c) 2010-2012 Michael Berkovich, tr8n.net
3
+ #
4
+ # Permission is hereby granted, free of charge, to any person obtaining
5
+ # a copy of this software and associated documentation files (the
6
+ # "Software"), to deal in the Software without restriction, including
7
+ # without limitation the rights to use, copy, modify, merge, publish,
8
+ # distribute, sublicense, and/or sell copies of the Software, and to
9
+ # permit persons to whom the Software is furnished to do so, subject to
10
+ # the following conditions:
11
+ #
12
+ # The above copyright notice and this permission notice shall be
13
+ # included in all copies or substantial portions of the Software.
14
+ #
15
+ # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
16
+ # EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
17
+ # MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
18
+ # NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
19
+ # LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
20
+ # OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
21
+ # WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
22
+ #++
23
+ #
24
+ #-- Tr8n::DailyLanguageMetric Schema Information
25
+ #
26
+ # Table name: tr8n_language_metrics
27
+ #
28
+ # id INTEGER not null, primary key
29
+ # type varchar(255)
30
+ # language_id integer not null
31
+ # metric_date date
32
+ # user_count integer default = 0
33
+ # translator_count integer default = 0
34
+ # translation_count integer default = 0
35
+ # key_count integer default = 0
36
+ # locked_key_count integer default = 0
37
+ # translated_key_count integer default = 0
38
+ # created_at datetime
39
+ # updated_at datetime
40
+ #
41
+ # Indexes
42
+ #
43
+ # index_tr8n_language_metrics_on_created_at (created_at)
44
+ # index_tr8n_language_metrics_on_language_id (language_id)
45
+ #
46
+ #++
23
47
 
24
48
  class Tr8n::DailyLanguageMetric < Tr8n::LanguageMetric
25
49
 
@@ -1,25 +1,44 @@
1
- #--
2
- # Copyright (c) 2010-2012 Michael Berkovich, tr8n.net
3
- #
4
- # Permission is hereby granted, free of charge, to any person obtaining
5
- # a copy of this software and associated documentation files (the
6
- # "Software"), to deal in the Software without restriction, including
7
- # without limitation the rights to use, copy, modify, merge, publish,
8
- # distribute, sublicense, and/or sell copies of the Software, and to
9
- # permit persons to whom the Software is furnished to do so, subject to
10
- # the following conditions:
11
- #
12
- # The above copyright notice and this permission notice shall be
13
- # included in all copies or substantial portions of the Software.
14
- #
15
- # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
16
- # EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
17
- # MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
18
- # NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
19
- # LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
20
- # OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
21
- # WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
22
- #++
1
+ #--
2
+ # Copyright (c) 2010-2012 Michael Berkovich, tr8n.net
3
+ #
4
+ # Permission is hereby granted, free of charge, to any person obtaining
5
+ # a copy of this software and associated documentation files (the
6
+ # "Software"), to deal in the Software without restriction, including
7
+ # without limitation the rights to use, copy, modify, merge, publish,
8
+ # distribute, sublicense, and/or sell copies of the Software, and to
9
+ # permit persons to whom the Software is furnished to do so, subject to
10
+ # the following conditions:
11
+ #
12
+ # The above copyright notice and this permission notice shall be
13
+ # included in all copies or substantial portions of the Software.
14
+ #
15
+ # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
16
+ # EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
17
+ # MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
18
+ # NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
19
+ # LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
20
+ # OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
21
+ # WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
22
+ #++
23
+ #
24
+ #-- Tr8n::DateRule Schema Information
25
+ #
26
+ # Table name: tr8n_language_rules
27
+ #
28
+ # id INTEGER not null, primary key
29
+ # language_id integer not null
30
+ # translator_id integer
31
+ # type varchar(255)
32
+ # definition text
33
+ # created_at datetime
34
+ # updated_at datetime
35
+ #
36
+ # Indexes
37
+ #
38
+ # index_tr8n_language_rules_on_language_id_and_translator_id (language_id, translator_id)
39
+ # index_tr8n_language_rules_on_language_id (language_id)
40
+ #
41
+ #++
23
42
 
24
43
  class Tr8n::DateRule < Tr8n::LanguageRule
25
44
 
@@ -1,25 +1,44 @@
1
- #--
2
- # Copyright (c) 2010-2012 Michael Berkovich, tr8n.net
3
- #
4
- # Permission is hereby granted, free of charge, to any person obtaining
5
- # a copy of this software and associated documentation files (the
6
- # "Software"), to deal in the Software without restriction, including
7
- # without limitation the rights to use, copy, modify, merge, publish,
8
- # distribute, sublicense, and/or sell copies of the Software, and to
9
- # permit persons to whom the Software is furnished to do so, subject to
10
- # the following conditions:
11
- #
12
- # The above copyright notice and this permission notice shall be
13
- # included in all copies or substantial portions of the Software.
14
- #
15
- # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
16
- # EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
17
- # MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
18
- # NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
19
- # LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
20
- # OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
21
- # WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
22
- #++
1
+ #--
2
+ # Copyright (c) 2010-2012 Michael Berkovich, tr8n.net
3
+ #
4
+ # Permission is hereby granted, free of charge, to any person obtaining
5
+ # a copy of this software and associated documentation files (the
6
+ # "Software"), to deal in the Software without restriction, including
7
+ # without limitation the rights to use, copy, modify, merge, publish,
8
+ # distribute, sublicense, and/or sell copies of the Software, and to
9
+ # permit persons to whom the Software is furnished to do so, subject to
10
+ # the following conditions:
11
+ #
12
+ # The above copyright notice and this permission notice shall be
13
+ # included in all copies or substantial portions of the Software.
14
+ #
15
+ # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
16
+ # EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
17
+ # MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
18
+ # NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
19
+ # LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
20
+ # OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
21
+ # WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
22
+ #++
23
+ #
24
+ #-- Tr8n::GenderListRule Schema Information
25
+ #
26
+ # Table name: tr8n_language_rules
27
+ #
28
+ # id INTEGER not null, primary key
29
+ # language_id integer not null
30
+ # translator_id integer
31
+ # type varchar(255)
32
+ # definition text
33
+ # created_at datetime
34
+ # updated_at datetime
35
+ #
36
+ # Indexes
37
+ #
38
+ # index_tr8n_language_rules_on_language_id_and_translator_id (language_id, translator_id)
39
+ # index_tr8n_language_rules_on_language_id (language_id)
40
+ #
41
+ #++
23
42
 
24
43
  class Tr8n::GenderListRule < Tr8n::LanguageRule
25
44
 
@@ -1,25 +1,44 @@
1
- #--
2
- # Copyright (c) 2010-2012 Michael Berkovich, tr8n.net
3
- #
4
- # Permission is hereby granted, free of charge, to any person obtaining
5
- # a copy of this software and associated documentation files (the
6
- # "Software"), to deal in the Software without restriction, including
7
- # without limitation the rights to use, copy, modify, merge, publish,
8
- # distribute, sublicense, and/or sell copies of the Software, and to
9
- # permit persons to whom the Software is furnished to do so, subject to
10
- # the following conditions:
11
- #
12
- # The above copyright notice and this permission notice shall be
13
- # included in all copies or substantial portions of the Software.
14
- #
15
- # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
16
- # EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
17
- # MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
18
- # NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
19
- # LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
20
- # OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
21
- # WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
22
- #++
1
+ #--
2
+ # Copyright (c) 2010-2012 Michael Berkovich, tr8n.net
3
+ #
4
+ # Permission is hereby granted, free of charge, to any person obtaining
5
+ # a copy of this software and associated documentation files (the
6
+ # "Software"), to deal in the Software without restriction, including
7
+ # without limitation the rights to use, copy, modify, merge, publish,
8
+ # distribute, sublicense, and/or sell copies of the Software, and to
9
+ # permit persons to whom the Software is furnished to do so, subject to
10
+ # the following conditions:
11
+ #
12
+ # The above copyright notice and this permission notice shall be
13
+ # included in all copies or substantial portions of the Software.
14
+ #
15
+ # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
16
+ # EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
17
+ # MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
18
+ # NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
19
+ # LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
20
+ # OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
21
+ # WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
22
+ #++
23
+ #
24
+ #-- Tr8n::GenderRule Schema Information
25
+ #
26
+ # Table name: tr8n_language_rules
27
+ #
28
+ # id INTEGER not null, primary key
29
+ # language_id integer not null
30
+ # translator_id integer
31
+ # type varchar(255)
32
+ # definition text
33
+ # created_at datetime
34
+ # updated_at datetime
35
+ #
36
+ # Indexes
37
+ #
38
+ # index_tr8n_language_rules_on_language_id_and_translator_id (language_id, translator_id)
39
+ # index_tr8n_language_rules_on_language_id (language_id)
40
+ #
41
+ #++
23
42
 
24
43
  class Tr8n::GenderRule < Tr8n::LanguageRule
25
44
 
@@ -1,27 +1,44 @@
1
- #--
2
- # Copyright (c) 2010-2012 Michael Berkovich, tr8n.net
3
- #
4
- # Permission is hereby granted, free of charge, to any person obtaining
5
- # a copy of this software and associated documentation files (the
6
- # "Software"), to deal in the Software without restriction, including
7
- # without limitation the rights to use, copy, modify, merge, publish,
8
- # distribute, sublicense, and/or sell copies of the Software, and to
9
- # permit persons to whom the Software is furnished to do so, subject to
10
- # the following conditions:
11
- #
12
- # The above copyright notice and this permission notice shall be
13
- # included in all copies or substantial portions of the Software.
14
- #
15
- # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
16
- # EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
17
- # MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
18
- # NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
19
- # LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
20
- # OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
21
- # WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
22
- #++
23
-
24
- class Tr8n::Glossary < ActiveRecord::Base
25
- set_table_name :tr8n_glossary
26
-
27
- end
1
+ #--
2
+ # Copyright (c) 2010-2012 Michael Berkovich, tr8n.net
3
+ #
4
+ # Permission is hereby granted, free of charge, to any person obtaining
5
+ # a copy of this software and associated documentation files (the
6
+ # "Software"), to deal in the Software without restriction, including
7
+ # without limitation the rights to use, copy, modify, merge, publish,
8
+ # distribute, sublicense, and/or sell copies of the Software, and to
9
+ # permit persons to whom the Software is furnished to do so, subject to
10
+ # the following conditions:
11
+ #
12
+ # The above copyright notice and this permission notice shall be
13
+ # included in all copies or substantial portions of the Software.
14
+ #
15
+ # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
16
+ # EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
17
+ # MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
18
+ # NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
19
+ # LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
20
+ # OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
21
+ # WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
22
+ #++
23
+ #
24
+ #-- Tr8n::Glossary Schema Information
25
+ #
26
+ # Table name: tr8n_glossary
27
+ #
28
+ # id INTEGER not null, primary key
29
+ # keyword varchar(255)
30
+ # description text
31
+ # created_at datetime
32
+ # updated_at datetime
33
+ #
34
+ # Indexes
35
+ #
36
+ # index_tr8n_glossary_on_keyword (keyword)
37
+ #
38
+ #++
39
+
40
+ class Tr8n::Glossary < ActiveRecord::Base
41
+ set_table_name :tr8n_glossary
42
+ attr_accessible :keyword, :description
43
+
44
+ end