dm_panlex 0.2.0 → 0.2.1
Sign up to get free protection for your applications and to get access to all the features.
- data/{panlex.gemspec → dm_panlex.gemspec} +1 -1
- data/lib/dm_panlex/models/ap.rb +2 -4
- data/lib/dm_panlex/models/apli.rb +1 -1
- data/lib/dm_panlex/models/av.rb +0 -2
- data/lib/dm_panlex/models/cp.rb +0 -1
- data/lib/dm_panlex/models/cu.rb +0 -1
- data/lib/dm_panlex/models/df.rb +0 -2
- data/lib/dm_panlex/models/dm.rb +0 -2
- data/lib/dm_panlex/models/dn.rb +2 -5
- data/lib/dm_panlex/models/ex.rb +2 -4
- data/lib/dm_panlex/models/i1.rb +0 -1
- data/lib/dm_panlex/models/lc.rb +2 -2
- data/lib/dm_panlex/models/lv.rb +5 -7
- data/lib/dm_panlex/models/md.rb +0 -1
- data/lib/dm_panlex/models/mi.rb +0 -1
- data/lib/dm_panlex/models/mn.rb +4 -6
- data/lib/dm_panlex/models/wc.rb +0 -2
- data/lib/dm_panlex/models/wcex.rb +1 -1
- data/spec/dm_panlex/models/ap_spec.rb +0 -3
- data/spec/dm_panlex/models/av_spec.rb +0 -6
- data/spec/dm_panlex/models/cp_spec.rb +0 -3
- data/spec/dm_panlex/models/cu_spec.rb +0 -3
- data/spec/dm_panlex/models/df_spec.rb +0 -6
- data/spec/dm_panlex/models/dm_spec.rb +0 -6
- data/spec/dm_panlex/models/dn_spec.rb +0 -6
- data/spec/dm_panlex/models/ex_spec.rb +0 -3
- data/spec/dm_panlex/models/i1_spec.rb +0 -3
- data/spec/dm_panlex/models/lv_spec.rb +0 -3
- data/spec/dm_panlex/models/md_spec.rb +0 -3
- data/spec/dm_panlex/models/mi_spec.rb +0 -3
- data/spec/dm_panlex/models/mn_spec.rb +0 -3
- data/spec/dm_panlex/models/wc_spec.rb +0 -6
- metadata +2 -2
data/lib/dm_panlex/models/ap.rb
CHANGED
@@ -20,9 +20,7 @@ module DmPanlex
|
|
20
20
|
property :co, Text
|
21
21
|
property :ad, Text
|
22
22
|
|
23
|
-
|
24
|
-
|
25
|
-
has n, :avs, :parent_key => :ap, :child_key => :ap, :constraint => :destroy
|
26
|
-
has n, :mns, :parent_key => :ap, :child_key => :ap
|
23
|
+
has n, :avs, :model => 'Av', :child_key => :ap, :constraint => :destroy
|
24
|
+
has n, :mns, :model => 'Mn', :child_key => :ap
|
27
25
|
end
|
28
26
|
end
|
@@ -8,6 +8,6 @@ module DmPanlex
|
|
8
8
|
property :li, String, :length => 2, :required => true, :unique_index => true
|
9
9
|
property :pl, Text, :required => true, :unique_index => true
|
10
10
|
|
11
|
-
has n, :aps, :parent_key => :li, :child_key => :li
|
11
|
+
has n, :aps, :model => 'Ap', :parent_key => :li, :child_key => :li
|
12
12
|
end
|
13
13
|
end
|
data/lib/dm_panlex/models/av.rb
CHANGED
data/lib/dm_panlex/models/cp.rb
CHANGED
data/lib/dm_panlex/models/cu.rb
CHANGED
@@ -11,6 +11,5 @@ module DmPanlex
|
|
11
11
|
property :loc, String, :length => 255, :key => true, :unique_index => [:cu_c0_key, :cu_c1_key]
|
12
12
|
property :vb, String, :length => 255, :key => true, :required => true, :unique_index => [:cu_c0_key, :cu_c1_key]
|
13
13
|
|
14
|
-
belongs_to :lv, :parent_key => :lv, :child_key => :lv
|
15
14
|
end
|
16
15
|
end
|
data/lib/dm_panlex/models/df.rb
CHANGED
@@ -9,7 +9,5 @@ module DmPanlex
|
|
9
9
|
property :lv, Integer, :required => true, :unique_index => :df_mn_key
|
10
10
|
property :tt, Text, :required => true, :unique_index => :df_mn_key
|
11
11
|
|
12
|
-
belongs_to :lv, :parent_key => :lv, :child_key => :lv
|
13
|
-
belongs_to :mn, :parent_key => :mn, :child_key => :mn
|
14
12
|
end
|
15
13
|
end
|
data/lib/dm_panlex/models/dm.rb
CHANGED
@@ -8,7 +8,5 @@ module DmPanlex
|
|
8
8
|
property :mn, Integer, :required => true, :unique_index => :dm_mn_key
|
9
9
|
property :ex, Integer, :required => true, :unique_index => :dm_mn_key
|
10
10
|
|
11
|
-
belongs_to :ex, :parent_key => :ex, :child_key => :ex
|
12
|
-
belongs_to :mn, :parent_key => :mn, :child_key => :mn
|
13
11
|
end
|
14
12
|
end
|
data/lib/dm_panlex/models/dn.rb
CHANGED
@@ -8,10 +8,7 @@ module DmPanlex
|
|
8
8
|
property :mn, Integer, :required => true, :unique_index => :dm_mn_ex_key, :index => true
|
9
9
|
property :ex, Integer, :required => true, :unique_index => :dm_mn_ex_key, :index => true
|
10
10
|
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
has n, :mds, :parent_key => :dn, :child_key => :dn
|
15
|
-
has n, :wcs, :parent_key => :dn, :child_key => :dn
|
11
|
+
has n, :mds, :model => 'Md', :child_key => :dn
|
12
|
+
has n, :wcs, :model => 'Wc', :child_key => :dn
|
16
13
|
end
|
17
14
|
end
|
data/lib/dm_panlex/models/ex.rb
CHANGED
@@ -9,9 +9,7 @@ module DmPanlex
|
|
9
9
|
property :tt, Text, :required => true, :unique_index => :ex_lv_tt_key, :index => true
|
10
10
|
property :td, Text, :required => true, :index => true
|
11
11
|
|
12
|
-
|
13
|
-
|
14
|
-
has n, :dms, :parent_key => :ex, :child_key => :ex
|
15
|
-
has n, :dns, :parent_key => :ex, :child_key => :ex
|
12
|
+
has n, :dms, :model => 'Dm', :child_key => :ex
|
13
|
+
has n, :dns, :model => 'Dn', :child_key => :ex
|
16
14
|
end
|
17
15
|
end
|
data/lib/dm_panlex/models/i1.rb
CHANGED
data/lib/dm_panlex/models/lc.rb
CHANGED
@@ -7,7 +7,7 @@ module DmPanlex
|
|
7
7
|
property :lc, String, :length => 3, :key => true
|
8
8
|
property :tp, String, :length => 1, :required => true
|
9
9
|
|
10
|
-
has n, :i1s, :
|
11
|
-
has n, :lvs, :
|
10
|
+
has n, :i1s, :model => 'I1', :child_key => :iso3
|
11
|
+
has n, :lvs, :model => 'Lv', :child_key => :lc
|
12
12
|
end
|
13
13
|
end
|
data/lib/dm_panlex/models/lv.rb
CHANGED
@@ -11,12 +11,10 @@ module DmPanlex
|
|
11
11
|
property :am, Boolean, :required => true, :default => true
|
12
12
|
property :tt, Text, :required => true
|
13
13
|
|
14
|
-
|
15
|
-
|
16
|
-
has n, :
|
17
|
-
has n, :
|
18
|
-
has n, :
|
19
|
-
has n, :dfs, :parent_key => :lv, :child_key => :lv
|
20
|
-
has n, :exs, :parent_key => :lv, :child_key => :lv
|
14
|
+
has n, :avs, :model => 'Av', :child_key => :lv, :constraint => :destroy
|
15
|
+
has n, :cps, :model => 'Cp', :child_key => :lv
|
16
|
+
has n, :cus, :model => 'Cu', :child_key => :lv
|
17
|
+
has n, :dfs, :model => 'Df', :child_key => :lv
|
18
|
+
has n, :exs, :model => 'Ex', :child_key => :lv
|
21
19
|
end
|
22
20
|
end
|
data/lib/dm_panlex/models/md.rb
CHANGED
data/lib/dm_panlex/models/mi.rb
CHANGED
data/lib/dm_panlex/models/mn.rb
CHANGED
@@ -7,11 +7,9 @@ module DmPanlex
|
|
7
7
|
property :mn, Integer, :key => true
|
8
8
|
property :ap, Integer, :required => true, :index => true
|
9
9
|
|
10
|
-
|
11
|
-
|
12
|
-
has n, :
|
13
|
-
has n, :
|
14
|
-
has n, :dns, :parent_key => :mn, :child_key => :mn
|
15
|
-
has n, :mis, :parent_key => :mn, :child_key => :mn
|
10
|
+
has n, :dfs, :model => 'Df', :child_key => :mn
|
11
|
+
has n, :dms, :model => 'Dm', :child_key => :mn
|
12
|
+
has n, :dns, :model => 'Dn', :child_key => :mn
|
13
|
+
has n, :mis, :model => 'Mi', :child_key => :mn
|
16
14
|
end
|
17
15
|
end
|
data/lib/dm_panlex/models/wc.rb
CHANGED
@@ -8,7 +8,5 @@ module DmPanlex
|
|
8
8
|
property :dn, Integer, :required => true, :unique_index => :wc_dn_key
|
9
9
|
property :ex, Integer, :required => true, :unique_index => :wc_dn_key
|
10
10
|
|
11
|
-
belongs_to :dn, :parent_key => :dn, :child_key => :dn
|
12
|
-
belongs_to :wcex, :parent_key => :ex, :child_key => :ex
|
13
11
|
end
|
14
12
|
end
|
@@ -62,9 +62,6 @@ module DmPanlex
|
|
62
62
|
it "is not valid without a quality in editor's judgement" do
|
63
63
|
should validate_presence_of :uq
|
64
64
|
end
|
65
|
-
it "belongs to an approver license (apli)" do
|
66
|
-
should belong_to :apli
|
67
|
-
end
|
68
65
|
it "has many approver varieties (av)" do
|
69
66
|
should have_many :avs
|
70
67
|
end
|
@@ -14,11 +14,5 @@ module DmPanlex
|
|
14
14
|
it "is not valid without a variety" do
|
15
15
|
should validate_presence_of :lv
|
16
16
|
end
|
17
|
-
it "belongs to an approver (ap)" do
|
18
|
-
should belong_to :ap
|
19
|
-
end
|
20
|
-
it "belongs to a language variety (lv)" do
|
21
|
-
should belong_to :lv
|
22
|
-
end
|
23
17
|
end
|
24
18
|
end
|
@@ -26,11 +26,5 @@ module DmPanlex
|
|
26
26
|
it "is not valid without a text" do
|
27
27
|
should validate_presence_of :tt
|
28
28
|
end
|
29
|
-
it "belongs to a language variety (lv)" do
|
30
|
-
should belong_to :lv
|
31
|
-
end
|
32
|
-
it "belongs to a meaning (mn)" do
|
33
|
-
should belong_to :mn
|
34
|
-
end
|
35
29
|
end
|
36
30
|
end
|
@@ -20,11 +20,5 @@ module DmPanlex
|
|
20
20
|
it "is not valid without an expression" do
|
21
21
|
should validate_presence_of :ex
|
22
22
|
end
|
23
|
-
it "belongs to an expression (ex)" do
|
24
|
-
should belong_to :ex
|
25
|
-
end
|
26
|
-
it "belongs to a meaning (mn)" do
|
27
|
-
should belong_to :mn
|
28
|
-
end
|
29
23
|
end
|
30
24
|
end
|
@@ -20,12 +20,6 @@ module DmPanlex
|
|
20
20
|
it "is not valid without an expression" do
|
21
21
|
should validate_presence_of :ex
|
22
22
|
end
|
23
|
-
it "belongs to an expression (ex)" do
|
24
|
-
should belong_to :ex
|
25
|
-
end
|
26
|
-
it "belongs to a meaning (mn)" do
|
27
|
-
should belong_to :mn
|
28
|
-
end
|
29
23
|
it "has many metadata (md)" do
|
30
24
|
should have_many :mds
|
31
25
|
end
|
@@ -20,11 +20,5 @@ module DmPanlex
|
|
20
20
|
it "is not valid without a Panlex word-class expression" do
|
21
21
|
should validate_presence_of :ex
|
22
22
|
end
|
23
|
-
it "belongs to a denotation (dn)" do
|
24
|
-
should belong_to :dn
|
25
|
-
end
|
26
|
-
it "belongs to a word class expressions (wcex)" do
|
27
|
-
should belong_to :wcex
|
28
|
-
end
|
29
23
|
end
|
30
24
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: dm_panlex
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.1
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -101,6 +101,7 @@ files:
|
|
101
101
|
- .yardopts
|
102
102
|
- COPYING.txt
|
103
103
|
- README.md
|
104
|
+
- dm_panlex.gemspec
|
104
105
|
- lib/dm_panlex.rb
|
105
106
|
- lib/dm_panlex/models/ap.rb
|
106
107
|
- lib/dm_panlex/models/apli.rb
|
@@ -121,7 +122,6 @@ files:
|
|
121
122
|
- lib/dm_panlex/models/wc.rb
|
122
123
|
- lib/dm_panlex/models/wcex.rb
|
123
124
|
- panlex-db-design.pdf
|
124
|
-
- panlex.gemspec
|
125
125
|
- spec/dm_panlex/models/ap_spec.rb
|
126
126
|
- spec/dm_panlex/models/apli_spec.rb
|
127
127
|
- spec/dm_panlex/models/av_spec.rb
|