activerecord-lookml 0.2.0 → 0.2.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.
- checksums.yaml +4 -4
- data/CHANGELOG.md +9 -1
- data/bin/console +1 -1
- data/lib/active_record/lookml.rb +0 -5
- data/lib/active_record/lookml/core.rb +4 -4
- data/lib/active_record/lookml/version.rb +1 -1
- data/lib/activerecord-lookml.rb +7 -0
- metadata +3 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 51994f9cd3d936cd0d7df51d8ba8a9a0bf99aad22f03405fb9fc975d35263a11
|
|
4
|
+
data.tar.gz: 1e239e2f8f1474e2e340ac16df097dd6a78d6a500ab9614eae93990413e6fd80
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: dc3a73dfb0cbe15db67b7a025c6591bd3a92e6b98b671755e3ae4a09d396ddb45453f697d7edf7276ec8845c10c9d2e14f8b2f7c259cdeec4325c40d0701d2ef
|
|
7
|
+
data.tar.gz: 5c16904267407519928811f499c69f86dc62af8d0ecbc9415c874938a7787f9cfb46984be2ad8e47a479d69bee3b815d082af7bf13ad0962179d4a961a47fc43
|
data/CHANGELOG.md
CHANGED
|
@@ -1,7 +1,15 @@
|
|
|
1
1
|
## Unreleased
|
|
2
2
|
|
|
3
|
+
## 0.2.1
|
|
4
|
+
|
|
5
|
+
Bug fixes and minor improvements.
|
|
6
|
+
|
|
7
|
+
## 0.2.0
|
|
8
|
+
|
|
9
|
+
- Feature: LookML view generation from ActiveRecord class
|
|
10
|
+
|
|
3
11
|
## 0.1.0
|
|
4
12
|
|
|
5
13
|
Initial version
|
|
6
14
|
|
|
7
|
-
-
|
|
15
|
+
- Feature: LookML dimension generation from ActiveRecord::Enum definitions
|
data/bin/console
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
#!/usr/bin/env ruby
|
|
2
2
|
|
|
3
3
|
require "bundler/setup"
|
|
4
|
-
require "
|
|
4
|
+
require "active_record/lookml"
|
|
5
5
|
|
|
6
6
|
# You can add fixtures and/or initialization code here to make experimenting
|
|
7
7
|
# with your gem easier. You can also use a different console, if you like.
|
data/lib/active_record/lookml.rb
CHANGED
|
@@ -130,7 +130,7 @@ view: pulse_onboarding_statuses {
|
|
|
130
130
|
sql: ${TABLE}.#{attribute} ;;
|
|
131
131
|
}
|
|
132
132
|
LOOKML
|
|
133
|
-
when ActiveRecord::Type::DateTime
|
|
133
|
+
when ActiveRecord::Type::DateTime, ActiveRecord::AttributeMethods::TimeZoneConversion::TimeZoneConverter
|
|
134
134
|
<<-LOOKML
|
|
135
135
|
dimension_group: #{attribute} {
|
|
136
136
|
type: time
|
|
@@ -156,7 +156,7 @@ view: pulse_onboarding_statuses {
|
|
|
156
156
|
}
|
|
157
157
|
LOOKML
|
|
158
158
|
else
|
|
159
|
-
raise "Unknown attribute type: #{type.class}"
|
|
159
|
+
raise "Unknown attribute type: #{attribute} #{type.class}"
|
|
160
160
|
end
|
|
161
161
|
end
|
|
162
162
|
|
|
@@ -164,10 +164,10 @@ view: pulse_onboarding_statuses {
|
|
|
164
164
|
case type
|
|
165
165
|
when ActiveModel::Type::Integer, ActiveModel::Type::Boolean, ActiveRecord::Enum::EnumType
|
|
166
166
|
attribute
|
|
167
|
-
when ActiveRecord::Type::DateTime
|
|
167
|
+
when ActiveRecord::Type::DateTime, ActiveRecord::AttributeMethods::TimeZoneConversion::TimeZoneConverter
|
|
168
168
|
"#{attribute}_time"
|
|
169
169
|
else
|
|
170
|
-
raise "Unknown attribute type: #{type.class}"
|
|
170
|
+
raise "Unknown attribute type: #{attribute} #{type.class}"
|
|
171
171
|
end
|
|
172
172
|
end
|
|
173
173
|
end
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: activerecord-lookml
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.2.
|
|
4
|
+
version: 0.2.1
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Yoshinori Kawasaki
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: exe
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2021-05-
|
|
11
|
+
date: 2021-05-28 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: activesupport
|
|
@@ -88,6 +88,7 @@ files:
|
|
|
88
88
|
- lib/active_record/lookml.rb
|
|
89
89
|
- lib/active_record/lookml/core.rb
|
|
90
90
|
- lib/active_record/lookml/version.rb
|
|
91
|
+
- lib/activerecord-lookml.rb
|
|
91
92
|
homepage: https://github.com/wantedly/activerecord-lookml
|
|
92
93
|
licenses:
|
|
93
94
|
- MIT
|