tyler-composite_primary_keys 1.1.0 → 1.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (47) hide show
  1. data/History.txt +0 -8
  2. data/Manifest.txt +0 -1
  3. data/Rakefile +65 -0
  4. data/init.rb +2 -0
  5. data/install.rb +30 -0
  6. data/lib/composite_primary_keys/association_preload.rb +2 -19
  7. data/lib/composite_primary_keys/associations.rb +2 -2
  8. data/lib/composite_primary_keys/base.rb +2 -6
  9. data/lib/composite_primary_keys/calculations.rb +1 -2
  10. data/lib/composite_primary_keys/version.rb +3 -3
  11. data/loader.rb +24 -0
  12. data/tmp/test.db +0 -0
  13. data/website/index.html +199 -0
  14. data/website/index.txt +159 -0
  15. data/website/javascripts/rounded_corners_lite.inc.js +285 -0
  16. data/website/stylesheets/screen.css +126 -0
  17. data/website/template.js +3 -0
  18. data/website/template.rhtml +53 -0
  19. data/website/version-raw.js +3 -0
  20. data/website/version-raw.txt +2 -0
  21. data/website/version.js +4 -0
  22. data/website/version.txt +3 -0
  23. metadata +78 -59
  24. data/lib/adapter_helper/oracle_enhanced.rb +0 -12
  25. data/lib/composite_primary_keys/connection_adapters/abstract_adapter.rb +0 -9
  26. data/lib/composite_primary_keys/connection_adapters/oracle_enhanced_adapter.rb +0 -17
  27. data/test/connections/native_oracle_enhanced/connection.rb +0 -20
  28. data/test/fixtures/article_group.rb +0 -4
  29. data/test/fixtures/article_groups.yml +0 -7
  30. data/test/fixtures/dorm.rb +0 -3
  31. data/test/fixtures/dorms.yml +0 -2
  32. data/test/fixtures/kitchen_sink.rb +0 -3
  33. data/test/fixtures/kitchen_sinks.yml +0 -5
  34. data/test/fixtures/restaurant.rb +0 -6
  35. data/test/fixtures/restaurants.yml +0 -5
  36. data/test/fixtures/restaurants_suburbs.yml +0 -11
  37. data/test/fixtures/room.rb +0 -10
  38. data/test/fixtures/room_assignment.rb +0 -4
  39. data/test/fixtures/room_assignments.yml +0 -4
  40. data/test/fixtures/room_attribute.rb +0 -3
  41. data/test/fixtures/room_attribute_assignment.rb +0 -5
  42. data/test/fixtures/room_attribute_assignments.yml +0 -4
  43. data/test/fixtures/room_attributes.yml +0 -3
  44. data/test/fixtures/rooms.yml +0 -3
  45. data/test/fixtures/student.rb +0 -4
  46. data/test/fixtures/students.yml +0 -2
  47. data/test/test_exists.rb +0 -29
@@ -0,0 +1,3 @@
1
+ // <%= title %>
2
+ var version = <%= version.to_json %>;
3
+ <%= body %>
@@ -0,0 +1,53 @@
1
+ <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
2
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
3
+ <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
4
+ <head>
5
+ <link rel="stylesheet" href="stylesheets/screen.css" type="text/css" media="screen" />
6
+ <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
7
+ <title>
8
+ <%= title %>
9
+ </title>
10
+ <script src="javascripts/rounded_corners_lite.inc.js" type="text/javascript"></script>
11
+ <style>
12
+
13
+ </style>
14
+ <script type="text/javascript">
15
+ window.onload = function() {
16
+ settings = {
17
+ tl: { radius: 10 },
18
+ tr: { radius: 10 },
19
+ bl: { radius: 10 },
20
+ br: { radius: 10 },
21
+ antiAlias: true,
22
+ autoPad: true,
23
+ validTags: ["div"]
24
+ }
25
+ var versionBox = new curvyCorners(settings, document.getElementById("version"));
26
+ versionBox.applyCornersToAll();
27
+ }
28
+ </script>
29
+ </head>
30
+ <body>
31
+ <div id="main">
32
+
33
+ <h1><%= title %></h1>
34
+ <div id="version" class="clickable" onclick='document.location = "<%= download %>"; return false'>
35
+ Get Version
36
+ <a href="<%= download %>" class="numbers"><%= version %></a>
37
+ </div>
38
+ <%= body %>
39
+ <p class="coda">
40
+ <a href="mailto:drnicwilliams@gmail.com">Dr Nic</a>, <%= modified.pretty %><br>
41
+ Theme extended from <a href="http://rb2js.rubyforge.org/">Paul Battley</a>
42
+ </p>
43
+ </div>
44
+
45
+ <script src="http://www.google-analytics.com/urchin.js" type="text/javascript">
46
+ </script>
47
+ <script type="text/javascript">
48
+ _uacct = "UA-567811-2";
49
+ urchinTracker();
50
+ </script>
51
+
52
+ </body>
53
+ </html>
@@ -0,0 +1,3 @@
1
+ // Announcement JS file
2
+ var version = "1.1.0";
3
+ MagicAnnouncement.show('compositekeys', version);
@@ -0,0 +1,2 @@
1
+ h1. Announcement JS file
2
+ MagicAnnouncement.show('compositekeys', version);
@@ -0,0 +1,4 @@
1
+ // Version JS file
2
+ var version = "1.1.0";
3
+
4
+ document.write(" - " + version);
@@ -0,0 +1,3 @@
1
+ h1. Version JS file
2
+
3
+ document.write(" - " + version);
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: tyler-composite_primary_keys
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.0
4
+ version: 1.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Dr Nic Williams
@@ -9,87 +9,99 @@ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
11
 
12
- date: 2009-05-11 00:00:00 -07:00
12
+ date: 2008-10-28 00:00:00 -07:00
13
13
  default_executable:
14
- dependencies: []
15
-
16
- description: Composite key support for ActiveRecord
14
+ dependencies:
15
+ - !ruby/object:Gem::Dependency
16
+ name: activerecord
17
+ type: :runtime
18
+ version_requirement:
19
+ version_requirements: !ruby/object:Gem::Requirement
20
+ requirements:
21
+ - - ">="
22
+ - !ruby/object:Gem::Version
23
+ version: 2.1.2
24
+ version:
25
+ - !ruby/object:Gem::Dependency
26
+ name: hoe
27
+ type: :development
28
+ version_requirement:
29
+ version_requirements: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - ">="
32
+ - !ruby/object:Gem::Version
33
+ version: 1.8.2
34
+ version:
35
+ description: Composite key support for ActiveRecords
17
36
  email: drnicwilliams@gmail.com
18
37
  executables: []
19
38
 
20
39
  extensions: []
21
40
 
22
- extra_rdoc_files: []
23
-
41
+ extra_rdoc_files:
42
+ - History.txt
43
+ - Manifest.txt
44
+ - README.txt
45
+ - README_DB2.txt
46
+ - test/README_tests.txt
47
+ - website/index.txt
48
+ - website/version-raw.txt
49
+ - website/version.txt
24
50
  files:
25
51
  - History.txt
26
52
  - Manifest.txt
27
53
  - README.txt
28
54
  - README_DB2.txt
29
- - lib/adapter_helper
55
+ - Rakefile
56
+ - init.rb
57
+ - install.rb
30
58
  - lib/adapter_helper/base.rb
31
59
  - lib/adapter_helper/mysql.rb
32
60
  - lib/adapter_helper/oracle.rb
33
- - lib/adapter_helper/oracle_enhanced.rb
34
61
  - lib/adapter_helper/postgresql.rb
35
62
  - lib/adapter_helper/sqlite3.rb
36
- - lib/composite_primary_keys
63
+ - lib/composite_primary_keys.rb
37
64
  - lib/composite_primary_keys/association_preload.rb
38
65
  - lib/composite_primary_keys/associations.rb
39
66
  - lib/composite_primary_keys/attribute_methods.rb
40
67
  - lib/composite_primary_keys/base.rb
41
68
  - lib/composite_primary_keys/calculations.rb
42
69
  - lib/composite_primary_keys/composite_arrays.rb
43
- - lib/composite_primary_keys/connection_adapters
44
- - lib/composite_primary_keys/connection_adapters/abstract_adapter.rb
45
70
  - lib/composite_primary_keys/connection_adapters/ibm_db_adapter.rb
46
71
  - lib/composite_primary_keys/connection_adapters/oracle_adapter.rb
47
- - lib/composite_primary_keys/connection_adapters/oracle_enhanced_adapter.rb
48
72
  - lib/composite_primary_keys/connection_adapters/postgresql_adapter.rb
49
73
  - lib/composite_primary_keys/connection_adapters/sqlite3_adapter.rb
50
74
  - lib/composite_primary_keys/fixtures.rb
51
75
  - lib/composite_primary_keys/migration.rb
52
76
  - lib/composite_primary_keys/reflection.rb
53
77
  - lib/composite_primary_keys/version.rb
54
- - lib/composite_primary_keys.rb
78
+ - loader.rb
55
79
  - local/database_connections.rb.sample
56
80
  - local/paths.rb.sample
57
81
  - local/tasks.rb.sample
82
+ - scripts/console.rb
83
+ - scripts/txt2html
84
+ - scripts/txt2js
58
85
  - tasks/activerecord_selection.rake
59
- - tasks/databases
86
+ - tasks/databases.rake
60
87
  - tasks/databases/mysql.rake
61
88
  - tasks/databases/oracle.rake
62
89
  - tasks/databases/postgresql.rake
63
90
  - tasks/databases/sqlite3.rake
64
- - tasks/databases.rake
65
91
  - tasks/deployment.rake
66
92
  - tasks/local_setup.rake
67
93
  - tasks/website.rake
68
- - scripts/console.rb
69
- - scripts/txt2html
70
- - scripts/txt2js
94
+ - test/README_tests.txt
71
95
  - test/abstract_unit.rb
72
- - test/connections
73
- - test/connections/native_ibm_db
74
96
  - test/connections/native_ibm_db/connection.rb
75
- - test/connections/native_mysql
76
97
  - test/connections/native_mysql/connection.rb
77
- - test/connections/native_oracle
78
98
  - test/connections/native_oracle/connection.rb
79
- - test/connections/native_oracle_enhanced
80
- - test/connections/native_oracle_enhanced/connection.rb
81
- - test/connections/native_postgresql
82
99
  - test/connections/native_postgresql/connection.rb
83
- - test/connections/native_sqlite
84
100
  - test/connections/native_sqlite/connection.rb
85
- - test/fixtures
86
101
  - test/fixtures/article.rb
87
- - test/fixtures/article_group.rb
88
- - test/fixtures/article_groups.yml
89
102
  - test/fixtures/articles.yml
90
103
  - test/fixtures/comment.rb
91
104
  - test/fixtures/comments.yml
92
- - test/fixtures/db_definitions
93
105
  - test/fixtures/db_definitions/db2-create-tables.sql
94
106
  - test/fixtures/db_definitions/db2-drop-tables.sql
95
107
  - test/fixtures/db_definitions/mysql.sql
@@ -99,16 +111,12 @@ files:
99
111
  - test/fixtures/db_definitions/sqlite.sql
100
112
  - test/fixtures/department.rb
101
113
  - test/fixtures/departments.yml
102
- - test/fixtures/dorm.rb
103
- - test/fixtures/dorms.yml
104
114
  - test/fixtures/employee.rb
105
115
  - test/fixtures/employees.yml
106
116
  - test/fixtures/group.rb
107
117
  - test/fixtures/groups.yml
108
118
  - test/fixtures/hack.rb
109
119
  - test/fixtures/hacks.yml
110
- - test/fixtures/kitchen_sink.rb
111
- - test/fixtures/kitchen_sinks.yml
112
120
  - test/fixtures/membership.rb
113
121
  - test/fixtures/membership_status.rb
114
122
  - test/fixtures/membership_statuses.yml
@@ -123,21 +131,8 @@ files:
123
131
  - test/fixtures/reference_codes.yml
124
132
  - test/fixtures/reference_type.rb
125
133
  - test/fixtures/reference_types.yml
126
- - test/fixtures/restaurant.rb
127
- - test/fixtures/restaurants.yml
128
- - test/fixtures/restaurants_suburbs.yml
129
- - test/fixtures/room.rb
130
- - test/fixtures/room_assignment.rb
131
- - test/fixtures/room_assignments.yml
132
- - test/fixtures/room_attribute.rb
133
- - test/fixtures/room_attribute_assignment.rb
134
- - test/fixtures/room_attribute_assignments.yml
135
- - test/fixtures/room_attributes.yml
136
- - test/fixtures/rooms.yml
137
134
  - test/fixtures/street.rb
138
135
  - test/fixtures/streets.yml
139
- - test/fixtures/student.rb
140
- - test/fixtures/students.yml
141
136
  - test/fixtures/suburb.rb
142
137
  - test/fixtures/suburbs.yml
143
138
  - test/fixtures/tariff.rb
@@ -145,10 +140,8 @@ files:
145
140
  - test/fixtures/user.rb
146
141
  - test/fixtures/users.yml
147
142
  - test/hash_tricks.rb
148
- - test/plugins
149
143
  - test/plugins/pagination.rb
150
144
  - test/plugins/pagination_helper.rb
151
- - test/README_tests.txt
152
145
  - test/test_associations.rb
153
146
  - test/test_attribute_methods.rb
154
147
  - test/test_attributes.rb
@@ -157,7 +150,6 @@ files:
157
150
  - test/test_create.rb
158
151
  - test/test_delete.rb
159
152
  - test/test_dummy.rb
160
- - test/test_exists.rb
161
153
  - test/test_find.rb
162
154
  - test/test_ids.rb
163
155
  - test/test_miscellaneous.rb
@@ -166,11 +158,23 @@ files:
166
158
  - test/test_santiago.rb
167
159
  - test/test_tutorial_examle.rb
168
160
  - test/test_update.rb
169
- has_rdoc: false
170
- homepage: http://github.com/drnicwilliams/composite_primary_keys
161
+ - tmp/test.db
162
+ - website/index.html
163
+ - website/index.txt
164
+ - website/javascripts/rounded_corners_lite.inc.js
165
+ - website/stylesheets/screen.css
166
+ - website/template.js
167
+ - website/template.rhtml
168
+ - website/version-raw.js
169
+ - website/version-raw.txt
170
+ - website/version.js
171
+ - website/version.txt
172
+ has_rdoc: true
173
+ homepage: http://compositekeys.rubyforge.org
171
174
  post_install_message:
172
- rdoc_options: []
173
-
175
+ rdoc_options:
176
+ - --main
177
+ - README.txt
174
178
  require_paths:
175
179
  - lib
176
180
  required_ruby_version: !ruby/object:Gem::Requirement
@@ -187,10 +191,25 @@ required_rubygems_version: !ruby/object:Gem::Requirement
187
191
  version:
188
192
  requirements: []
189
193
 
190
- rubyforge_project:
194
+ rubyforge_project: compositekeys
191
195
  rubygems_version: 1.2.0
192
196
  signing_key:
193
197
  specification_version: 2
194
- summary: Composite key support for ActiveRecord
195
- test_files: []
196
-
198
+ summary: Composite key support for ActiveRecords
199
+ test_files:
200
+ - test/test_associations.rb
201
+ - test/test_attribute_methods.rb
202
+ - test/test_attributes.rb
203
+ - test/test_clone.rb
204
+ - test/test_composite_arrays.rb
205
+ - test/test_create.rb
206
+ - test/test_delete.rb
207
+ - test/test_dummy.rb
208
+ - test/test_find.rb
209
+ - test/test_ids.rb
210
+ - test/test_miscellaneous.rb
211
+ - test/test_pagination.rb
212
+ - test/test_polymorphic.rb
213
+ - test/test_santiago.rb
214
+ - test/test_tutorial_examle.rb
215
+ - test/test_update.rb
@@ -1,12 +0,0 @@
1
- require File.join(File.dirname(__FILE__), 'base')
2
-
3
- module AdapterHelper
4
- class OracleEnhanced < Base
5
- class << self
6
- def load_connection_from_env
7
- spec = super('oracle_enhanced')
8
- spec
9
- end
10
- end
11
- end
12
- end
@@ -1,9 +0,0 @@
1
- module ActiveRecord
2
- module ConnectionAdapters # :nodoc:
3
- class AbstractAdapter
4
- def concat(*columns)
5
- "CONCAT(#{columns.join(',')})"
6
- end
7
- end
8
- end
9
- end
@@ -1,17 +0,0 @@
1
- # Added to OracleEnhancedAdapter version 1.1.4
2
- #
3
- # module ActiveRecord
4
- # module ConnectionAdapters
5
- # class OracleEnhancedAdapter < AbstractAdapter
6
- #
7
- # # This mightn't be in Core, but count(distinct x,y) doesn't work for me
8
- # def supports_count_distinct? #:nodoc:
9
- # false
10
- # end
11
- #
12
- # def concat(*columns)
13
- # "(#{columns.join('||')})"
14
- # end
15
- # end
16
- # end
17
- # end
@@ -1,20 +0,0 @@
1
- print "Using native Oracle Enhanced\n"
2
- require 'fileutils'
3
- require 'logger'
4
- require 'adapter_helper/oracle_enhanced'
5
-
6
- log_path = File.expand_path(File.join(File.dirname(__FILE__), %w[.. .. .. log]))
7
- FileUtils.mkdir_p log_path
8
- puts "Logging to #{log_path}/debug.log"
9
- ActiveRecord::Base.logger = Logger.new("#{log_path}/debug.log")
10
- ActiveRecord::Base.logger.level = Logger::DEBUG
11
-
12
- # Adapter config setup in locals/database_connections.rb
13
- connection_options = AdapterHelper::OracleEnhanced.load_connection_from_env
14
- puts connection_options.inspect
15
- ActiveRecord::Base.establish_connection(connection_options)
16
-
17
- # Change default options for Oracle Enhanced adapter
18
- ActiveRecord::ConnectionAdapters::OracleEnhancedAdapter.emulate_dates_by_column_name = true
19
- # Change NLS_DATE_FORMAT to non-default format to verify that all tests should pass
20
- ActiveRecord::Base.connection.execute %q{alter session set nls_date_format = 'DD-MON-YYYY HH24:MI:SS'}
@@ -1,4 +0,0 @@
1
- class ArticleGroup < ActiveRecord::Base
2
- belongs_to :article
3
- belongs_to :group
4
- end
@@ -1,7 +0,0 @@
1
- cpk:
2
- article_id: 1
3
- group_id: 1
4
-
5
- transformers:
6
- article_id: 1
7
- group_id: 2
@@ -1,3 +0,0 @@
1
- class Dorm < ActiveRecord::Base
2
- has_many :rooms, :include => :room_attributes
3
- end
@@ -1,2 +0,0 @@
1
- jacksons_dorm:
2
- id: 1
@@ -1,3 +0,0 @@
1
- class KitchenSink < ActiveRecord::Base
2
- set_primary_keys :id_1, :id_2
3
- end
@@ -1,5 +0,0 @@
1
- first:
2
- id_1: 1
3
- id_2: 2
4
- a_date: <%= Date.today.to_s(:db) %>
5
- a_string: 'string'
@@ -1,6 +0,0 @@
1
- class Restaurant < ActiveRecord::Base
2
- set_primary_keys :franchise_id, :store_id
3
- has_and_belongs_to_many :suburbs,
4
- :foreign_key => [:franchise_id, :store_id],
5
- :association_foreign_key => [:city_id, :suburb_id]
6
- end
@@ -1,5 +0,0 @@
1
- mcdonalds:
2
- franchise_id: 1
3
- store_id: 1
4
- name: McDonalds
5
-