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
# Redis is faster than Mysql so it may cause a RecordNotFound to happen if enqueued from after_create | |
before_create :set_recently_opened | |
after_commit :if => :recently_opened? do |record| | |
Resque.enqueue StoreAfterCreate, record.id | |
UserMailer.store_signup(record.owner_user_id, record.id).deliver | |
end | |
def set_recently_opened | |
@recently_opened = true | |
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
... | |
<li class="product" id="products_{{product.id}}"> | |
<a href="{{product.url}}"> | |
<span class="{{ product.css_class }}"> | |
{% if product.on_sale %} | |
<img src="/themes/default/images/label-onsale.png" width="98" height="98" alt="On Sale" /> | |
{% endif %} | |
{% if product.preorder %} | |
<img src="/themes/default/images/label-preorder.png" width="98" height="98" alt="Pre-Order" /> | |
{% endif %} |
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
SELECT orders.id, orders.vanity_id, orders.payment_state, orders.confirmed_at, orders.store_id, store_subdomain from orders WHERE orders.vanity_id < 100000 and orders.confirmed_at > DATE_SUB(NOW(), INTERVAL 5 DAY) AND orders.store_id IN (528222, 18784) order by vanity_id, store_id; |
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
Resque.working.select{|w| DateTime.parse(w.job["run_at"]) < 5.hours.ago }.map do |worker| | |
worker.shutdown | |
worker.unregister_worker | |
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
Verifying my Blockstack ID is secured with the address 1DcoBDY6S7QELM7qvmgqibASxd3jP2L2kB https://explorer.blockstack.org/address/1DcoBDY6S7QELM7qvmgqibASxd3jP2L2kB |
OlderNewer