This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#config/initializers/redis.rb | |
require 'redis' | |
require 'redis/objects' | |
REDIS_CONFIG = YAML.load( File.open( Rails.root.join("config/redis.yml") ) ).symbolize_keys | |
dflt = REDIS_CONFIG[:default].symbolize_keys | |
cnfg = dflt.merge(REDIS_CONFIG[Rails.env.to_sym].symbolize_keys) if REDIS_CONFIG[Rails.env.to_sym] | |
$redis = Redis.new(cnfg) | |
Redis::Objects.redis = $redis |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
c# DIFF REPORT:# 18-07-2019 11:50:08 | |
# dif number 1 | |
--- | |
:title: Filter products by collection | |
:dates: | |
:generated_at: 18.18.2019 - 11:50:08 | |
:post_date: July 17, 2019 | |
:meta: | |
:tag: Products |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# DIFF REPORT:# 27-06-2019 20:23:16 | |
# dif number 1 | |
--- | |
:title: All of your discounts in one place | |
:dates: | |
:generated_at: 27.27.2019 - 20:23:16 | |
:post_date: June 27, 2019 | |
:meta: | |
:tag: Discounts |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# 1. Clear retry set | |
Sidekiq::RetrySet.new.clear | |
# 2. Clear scheduled jobs | |
Sidekiq::ScheduledSet.new.clear | |
# 3. Clear 'Processed' and 'Failed' jobs |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
jQuery('.single-option-selector').selectize({ | |
{% if shop.currency_code == "EUR" %} | |
{% assign money_symbol = "€" %} | |
{% endif %} | |
{% if shop.currency_code == "USD" %} | |
{% assign money_symbol = "$" %} | |
{% endif %} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# DIFF REPORT:# 12-05-2019 16:02:20 | |
# dif number 1 | |
--- | |
:title: "New slideshow options for Boundless theme \U0001F3DE️\U0001F306" | |
:dates: | |
:generated_at: 12.12.2019 - 16:02:20 | |
:post_date: March 27, 2019 | |
:meta: | |
:tag: Themes |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// SETTINGS | |
slider_settings = { | |
verbose: true, | |
verbose_name: "DOBBY", | |
navigation: true, | |
bullets: true | |
} | |
// post DOM load stuff | |
$(document).ready(function(){ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var earth_radius_km = 6371.0; | |
function deg_to_rad(deg) { | |
return (deg * Math.PI / 180.0); | |
} | |
function haversine_distance(latitude1, longitude1, latitude2, longitude2) { | |
var lat1 = deg_to_rad(latitude1); | |
var lng1 = deg_to_rad(longitude1); | |
var lat2 = deg_to_rad(latitude2); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# this file should be into "/controllers/" | |
# We call RegistrationsController extending Devise Registrations controller for starters | |
class RegistrationsController < Devise::RegistrationsController | |
# we override the method to define whatever we want here. | |
def after_update_path_for(resource) | |
edit_registration_path(resource) | |
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html lang="en" dir="ltr"> | |
<head> | |
<meta charset="utf-8"> | |
<title>Bootstrap Grid</title> | |
<!-- bs call --> | |
<link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.2.1/css/bootstrap.min.css" integrity="sha384-GJzZqFGwb1QTTN6wy59ffF1BuGJpLSa9DkKMp0DgiMDm4iYMj70gZWKYbI706tWS" crossorigin="anonymous"> | |
</head> |