module Para

This is a simple ActiveSupport::Cache::Store implementation, borrowed from activesupport-db-cache gem (github.com/sergio-fry/activesupport-db-cache), simplified.

It also adds RequestStore.store caching, avoiding same key reads to hit ActiveRecord multiple times in a single request

This is primarily meant to manage jobs status storing in Para::Job::Base through the ActiveJob::Status gem. It allows not to add external storage systems dependency (redis, memcache) to the app when not needed (when using default ActiveJob 5 AsyncAdapter or SuckerPunchAdapter).

Since it’s quite slow, it’s advised to replace it with faster cache stores like Redis or Memcache when used in large production systems.

This class serves as a basic superclass for tabular data specific exports, which are organized as tables : a header row and several rows of data.

This allows to only define the ‘#fields` method in the subclass and let the exporter work alone

This extension is needed because of Para’s params input parsing which creates empty placeholder records for nested attributes before their params are assigned.

This patch hooks into Rails nested attributes logic to clean all placeholder data during the params assignation process.

Allows constraining routing to components that explicitly declares to use a given controller to manage their resources.

It’s mainly used to allow users to override the default controller for the resources of a given Crud or Form components without having to subclass the component and declare all the routes again

Allows constraining routing to components that explicitly declares to use a given component to manage their resources.

It’s mainly used to allow users to override the default component for the resources of a given Crud or Form components without having to subclass the component and declare all the routes again

This class allows to unify search results and avoid duplicates, avoiding SQL DISTINCT errors by adding ORDER BY fields to the DISTINCT selection automatically

This fixes a previous issue when trying to order search results with Ransack sorting feature, when implying associated models

Default simple form bootstrap initializer mechanism

Constants

VERSION

Public Class Methods

components() click to toggle source
# File lib/para.rb, line 58
def self.components
  Para::Component.config
end
config(&block) click to toggle source
# File lib/para.rb, line 50
def self.config(&block)
  if block
    block.call(Para::Config)
  else
    Para::Config
  end
end
store() click to toggle source
# File lib/para.rb, line 62
def self.store
  RequestStore.store
end
table_name_prefix() click to toggle source
# File lib/para.rb, line 66
def self.table_name_prefix
  'para_'
end