draw_smd 0.1.0 → 0.1.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/assets/stylesheets/draw_smd/base.css +2 -2
- data/app/models/draw_smd/diagram.rb +10 -3
- data/lib/draw_smd/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 525eea38659c78efddcca9c94d882e51c8bdcc1b
|
4
|
+
data.tar.gz: 4a0111fbc31b9e95085e76f411a7ed8d17986869
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: fa7f9964ee5e4ceab785cf6fef5f4cee2075a5485b8126d6ed968a0706a3e18fab94a73e2848bc63bdd6d54faae481355b7aa10d9a510be576da12449b2243a2
|
7
|
+
data.tar.gz: 977dc2024881c30cd69dbc6c7be2253afc8a7dcd3b8645c422229a9c1c85fbc7a51b10682f815ea2d8d7b15c8a10f2417f1724de7739736f04282a6e3f0f4fef
|
@@ -5,11 +5,18 @@ module DrawSmd
|
|
5
5
|
schemas = ActiveRecord::Base.connection.tables
|
6
6
|
schemas.delete('schema_migrations')
|
7
7
|
schemas.map! {|schema| schema.singularize.camelize}
|
8
|
-
schemas.
|
9
|
-
|
10
|
-
|
8
|
+
schemas = schemas.inject([]) { |arr, schema|
|
9
|
+
arr << schema if state_machines?(schema)
|
10
|
+
arr
|
11
|
+
}
|
11
12
|
schemas.sort
|
12
13
|
end
|
14
|
+
|
15
|
+
def state_machines?(schema)
|
16
|
+
Object.const_get(schema).respond_to?(:state_machines)
|
17
|
+
rescue
|
18
|
+
false
|
19
|
+
end
|
13
20
|
end
|
14
21
|
|
15
22
|
def initialize(path)
|
data/lib/draw_smd/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: draw_smd
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- ogom
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-09-
|
11
|
+
date: 2014-09-02 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|