Module: QAT::Web::Screen::AutoLoad

Includes:
Logger
Defined in:
lib/qat/web/screen/autoload.rb

Overview

Helper methods for configuration auto-loading

Since:

  • 1.0.0

Class Method Summary collapse

Class Method Details

.load_screens!Object

Loads all screens from QAT cconfiguration cache

Since:

  • 1.0.0



11
12
13
14
15
16
17
18
# File 'lib/qat/web/screen/autoload.rb', line 11

def self.load_screens!
  if QAT.respond_to?(:configuration) && QAT.configuration[:screens]
    QAT::Web::Screen::Loader.load_config(QAT.configuration[:screens])
    log.debug { "Screens loaded in cache: [#{QAT::Web::Screen::Loader.screens.keys.join(', ')}]" }
  else
    log.debug { "Screens aren't loaded in cache, load screens manually from file using QAT::Web::Screen::Loader#load" }
  end
end