This file contains hidden or 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
define [ | |
"jquery" | |
"react" | |
"mixins/backbone" | |
"mixins/server_error" | |
"models/account" | |
"views/forms" | |
"views/account/account_nav" |
This file contains hidden or 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
module Spree | |
Taxon.class_eval do | |
include Spree::Redirectable | |
has_one :story | |
has_many :images, -> { order(:position) }, as: :viewable, dependent: :destroy, | |
class_name: 'Spree::Image' | |
def self.find_with_products input | |
find_by(permalink: input, taxonomy: Spree::Taxon.find_by(name: "Categories")) |
This file contains hidden or 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
module Spree | |
Order.instance_eval do | |
def find_by_number(number) | |
order = complete.where(number:number).take | |
order ||= where(number:number).take | |
end | |
def find_by_number!(number) | |
find_by_number(number) | |
end |
This file contains hidden or 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
client_header_timeout 600; | |
client_body_timeout 600; | |
send_timeout 600; | |
proxy_read_timeout 600; | |
fastcgi_buffers 8 16k; | |
fastcgi_buffer_size 32k; | |
fastcgi_read_timeout 600; |
This file contains hidden or 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 React = require('react/addons'), | |
Checkout = require('../components/checkout.js'), | |
TestUtils = React.addons.TestUtils; | |
describe('Checkout', function() { | |
var checkoutEl = TestUtils.renderIntoDocument( | |
<Checkout items={[{title: 'test'}, {title: 'test'}]} /> | |
); | |
var items = TestUtils.scryRenderedDOMComponentsWithTag(checkoutEl, 'li'); | |
var count = TestUtils.findRenderedDOMComponentWithTag(checkoutEl, 'span'); |
This file contains hidden or 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 React = require('react'); | |
var Checkout = React.createClass({ | |
render: function () { | |
var listItems = this.props.items.map(function(item, i) { | |
return <li key={"selectedItem" + i}>{item.title}</li> | |
}); | |
var count = listItems.length; | |
return ( | |
<div> |
This file contains hidden or 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
{ div, input, ul, li, span } = React.DOM | |
Checkout = React.createClass | |
render: -> | |
listItems = this.props.items.map ->(item, i) | |
li key={"selectedItem" + i} {item.title} | |
count = listItems.length | |
return ( | |
div, children: [ | |
ul, children: [ | |
{listItems} |
This file contains hidden or 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 Photo = React.createClass({ | |
render: function() { | |
return ( | |
<img src='http://bukk.it/oprahs-bees.gif'/> | |
) | |
} | |
}); |
This file contains hidden or 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
Could not open library 'libgtk-x11-2.0': dlopen(libgtk-x11-2.0, 13): image not found. | |
Could not open library 'libgtk-x11-2.0.dylib': dlopen(libgtk-x11-2.0.dylib, 13): image not found. | |
Could not open library 'libgtk-x11-2.0.so.0': dlopen(libgtk-x11-2.0.so.0, 13): image not found. | |
Could not open library 'libgtk-x11-2.0.so.0.dylib': dlopen(libgtk-x11-2.0.so.0.dylib, 13): image not found. | |
Could not open library 'libgtk-x11-2.0.so': dlopen(libgtk-x11-2.0.so, 13): image not found. | |
Could not open library 'libgtk-x11-2.0.so.dylib': dlopen(libgtk-x11-2.0.so.dylib, 13): image not found. | |
Could not open library 'libgtk-3': dlopen(libgtk-3, 13): image not found. | |
Could not open library 'libgtk-3.dylib': dlopen(libgtk-3.dylib, 13): image not found. | |
Could not open library 'libgtk-3.so.0': dlopen(libgtk-3.so.0, 13): image not found. | |
Could not open library 'libgtk-3.so.0.dylib': dlopen(libgtk-3.so.0.dylib, 13): image not found. |
This file contains hidden or 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
order.user.orders.complete.issues. | |
joins(line_items: {variant: {product: {issue: {}}}}). | |
where('quarterly_issues.plan_id = ?', order.product.subscription_plan.id). | |
map{|o| o.completed_at > order.completed_at}.include?(true) |