module Sidekiq::WebHelpers

Direct including types

Defined in:

sidekiq/web_helpers.cr

Constant Summary

LANGS = ["cs", "da", "de", "el", "en", "es", "fr", "hi", "it", "ja", "ko", "nb", "nl", "pl", "pt-br", "pt", "ru", "sv", "ta", "uk", "zh-cn", "zh-tw"] of ::String
LOCALE_PATHS = ["../web/locales"]
SAFE_QPARAMS = ["page", "poll"] of ::String

Instance Method Summary

Instance Method Detail

def csrf_tag #

[View source]
def current_path #

[View source]
def current_status #

[View source]
def display_args(args, truncate_after_chars = 2000) #

[View source]
def environment_title_prefix #

[View source]
def filtering(*args) #

This is a hook for a Sidekiq Pro feature. Please don"t touch.


[View source]
def get_locale #

[View source]
def h(text) #

[View source]
def job_params(job, score) #

[View source]
def list_page(key, pageidx = 1, page_size = 25) #

[View source]
def locale #

Given a browser request Accept-Language header like "fr-FR,fr;q=0.8,en-US;q=0.6,en;q=0.4,ru;q=0.2", this function will return "fr" since that"s the first code with a matching locale in web/locales


[View source]
def number_with_delimiter(number) #

[View source]
def page(key, pageidx = 1, page_size = 25, opts = nil) #

[View source]
def parse_params(params) #

[View source]
def processes #

[View source]
def product_version #

[View source]
def qparams(newparams) #

Merge options with current params, filter safe params, and stringify to query string


[View source]
def redis_info #

[View source]
def redis_location #

[View source]
def relative_time(time) #

[View source]
def retries_with_score(score) #

[View source]
def root_path #

[View source]
def stats #

[View source]
def t(msg, options = {} of String => String) #

[View source]
def truncate(text, truncate_after_chars = 2000) #

[View source]
def url_with_query(ctx, url) #

Any paginated list that performs an action needs to redirect back to the proper page after performing that action.


[View source]
def workers #

[View source]
def zpage(key, pageidx = 1, page_size = 25, opts = nil) #

[View source]