voyager 0.0.2 → 0.0.3

Sign up to get free protection for your applications and to get access to all the features.
@@ -3,10 +3,15 @@ require 'active_record'
3
3
  require 'voyager/activerecord/base'
4
4
  require 'voyager/activerecord/bib/text'
5
5
  require 'voyager/activerecord/bib/item'
6
+
6
7
  require 'voyager/activerecord/circ/transaction'
8
+
7
9
  require 'voyager/activerecord/item'
8
10
  require 'voyager/activerecord/item/barcode'
9
11
 
12
+ require 'voyager/activerecord/patron'
13
+ require 'voyager/activerecord/patron/barcode'
14
+
10
15
  # SIP Client
11
16
  require 'socket'
12
17
  require 'voyager/sip/basic_client'
@@ -0,0 +1,13 @@
1
+ module Voyager
2
+ module AR
3
+ class Patron < Voyager::AR::Base
4
+ # ActiveRecord Configuration
5
+ set_table_name 'patron'
6
+ set_primary_key 'patron_id'
7
+
8
+ # Associations
9
+ has_one :barcode, :foreign_key => 'patron_id', :class_name => 'Voyager::AR::Patron::Barcode'
10
+ has_many :circ_transactions, :class_name => 'Voyager::AR::Circ::Transaction'
11
+ end
12
+ end
13
+ end
@@ -0,0 +1,12 @@
1
+ module Voyager
2
+ module AR
3
+ class Patron
4
+ class Barcode < Voyager::AR::Base
5
+ set_table_name 'patron_barcode'
6
+ set_primary_key 'patron_barcode_id'
7
+
8
+ belongs_to :patron, :class_name => 'Voyager::AR::Patron'
9
+ end
10
+ end
11
+ end
12
+ end
@@ -1,3 +1,3 @@
1
1
  module Voyager
2
- VERSION = "0.0.2"
2
+ VERSION = "0.0.3"
3
3
  end
metadata CHANGED
@@ -2,7 +2,7 @@
2
2
  name: voyager
3
3
  version: !ruby/object:Gem::Version
4
4
  prerelease:
5
- version: 0.0.2
5
+ version: 0.0.3
6
6
  platform: ruby
7
7
  authors:
8
8
  - Brice Stacey
@@ -10,7 +10,7 @@ autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
12
 
13
- date: 2011-04-15 00:00:00 Z
13
+ date: 2011-05-12 00:00:00 Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  name: activerecord
@@ -65,6 +65,8 @@ files:
65
65
  - lib/voyager/activerecord/circ/transaction.rb
66
66
  - lib/voyager/activerecord/item.rb
67
67
  - lib/voyager/activerecord/item/barcode.rb
68
+ - lib/voyager/activerecord/patron.rb
69
+ - lib/voyager/activerecord/patron/barcode.rb
68
70
  - lib/voyager/sip/basic_client.rb
69
71
  - lib/voyager/sip/client.rb
70
72
  - lib/voyager/version.rb