Skip to content

Instantly share code, notes, and snippets.

= javascript_tag do
handler = Gmaps.build('Google');
handler.buildMap({ provider: {}, internal: {id: 'map'}}, function(){
markers = handler.addMarkers([
- @properties.each do |prop|
{
"lat": 36.112590,
"lng": -95.934744,
"picture": {
"url": "#{asset_path("kc-marker-2.png")}",
:javascript
handler = Gmaps.build('Google');
handler.buildMap({ provider: {}, internal: {id: 'map'}}, function(){
markers = handler.addMarkers([
// @properties.each do
{
"lat": 36.112590,
"lng": -95.934744,
"picture": {
"url": "#{asset_path("kc-marker-2.png")}",
-----> Creating a temporary build path
-----> Using RVM environment "ruby-2.5.0@kace"
Using /home/deployer/.rvm/gems/ruby-2.5.0 with gemset kace
-----> Fetching new git commits
-----> Using git branch 'master'
Cloning into '.'...
done.
-----> Using this git commit
Gustavo Pares (06ba99d):
> feat: added correct investmnet prices
get '/:shorten_url', to: 'posts#shorten', constraints: { #if its an image dont do it if its a string then do it}
{
"error": {
"code": "resource_missing",
"doc_url": "https://stripe.com/docs/error-codes/resource-missing",
"message": "No such sku: sku_F4ujPS739gxnA",
"param": "items[0]",
"type": "invalid_request_error"
}
}
%p
Thank you so much for donating to Jews for Judaism. We have created a donor account for you which enables you to browse articles as well as save them for further reference. You also have access to a donations area where you can view all your donations and at the end of the year you can download an invoice with all of your donations which are tax deductable.
%p
Once again I would like to personally thank you in making a difference in teaching Jews about Judaism.
%p
Rabbi Kravitz
@staycreativedesign
staycreativedesign / create_order_service.rb
Last active May 10, 2019 22:19
How come my SKU description does not appear in the order? Jews for Judaism Charity Poker Tournament appears instead of Bar Sponsor
class CreateOrderService
def initialize(current_user, params)
@customer = current_user
@params = params
@single_player_qty = params[:single_player_quantity]
@double_stack_qty = params[:double_stack_quantity]
@non_player_qty = params[:non_player_quantity]
@sponsor = params[:sponsor]
end
class Search < ApplicationRecord
def self.search_posts(keywords)
posts = Post.all
posts = posts.where(["title LIKE ?", "%#{keywords}%"]) if keywords.present?
return posts
end
end
@customer = Stripe::Customer.create({
name: @name,
email: @email,
source: @source,
phone:@phone
address: {
"addresss.line1": 'foobar',
"addresss.city": 'foobar',
"addresss.line2": 'foobar',
"postal_code": 'foobar',
%form#payment-form{:action => "/charge", :method => "post"}
.form-row
%label{:for => "card-element"}
Credit or debit card
#card-element
/ A Stripe Element will be inserted here.
/ Used to display Element errors.
#card-errors{:role => "alert"}
%button Submit Payment
%script{:src => "https://js.stripe.com/v3/"}