Class: SuperGood::SolidusTaxjar::Configuration
- Inherits:
-
Spree::Base
- Object
- Spree::Base
- SuperGood::SolidusTaxjar::Configuration
- Includes:
- Spree::Preferences::Persistable
- Defined in:
- app/models/super_good/solidus_taxjar/configuration.rb
Class Method Summary collapse
Instance Method Summary collapse
Class Method Details
.default ⇒ Object
21 22 23 |
# File 'app/models/super_good/solidus_taxjar/configuration.rb', line 21 def default first || create end |
Instance Method Details
#preferred_reporting_enabled ⇒ Object
11 12 13 14 |
# File 'app/models/super_good/solidus_taxjar/configuration.rb', line 11 def preferred_reporting_enabled preferred_reporting_enabled_at_integer.present? && DateTime.current.after?(preferred_reporting_enabled_at) end |
#preferred_reporting_enabled_at ⇒ Object
16 17 18 |
# File 'app/models/super_good/solidus_taxjar/configuration.rb', line 16 def preferred_reporting_enabled_at Time.at(SuperGood::SolidusTaxjar.configuration.preferred_reporting_enabled_at_integer).to_datetime end |