Class: LesliAdmin::Dashboard
- Inherits:
-
Lesli::Shared::Dashboard
- Object
- Lesli::Shared::Dashboard
- LesliAdmin::Dashboard
- Defined in:
- app/models/lesli_admin/dashboard.rb
Defined Under Namespace
Classes: Component, ComponentsController
Class Method Summary collapse
Class Method Details
.initialize_account(account) ⇒ Object
41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 |
# File 'app/models/lesli_admin/dashboard.rb', line 41 def self.initialize_account(account) self.create_with( default: true, main: false, components_attributes: [{ name: "Lesli version", component_id: "admin-lesli-version", layout: 3, query_configuration: {}, custom_configuration: {} }] ).find_or_create_by!( account: account, name: "Admin Default Dashboard" ) end |