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
| app/views/layouts/application.html.erb | |
| <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" | |
| "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> | |
| <html> | |
| <head> | |
| <title><%= @title || "Título" %></title> | |
| <%= stylesheet_link_tag 'site' %> | |
| <%= javascript_include_tag 'application', 'prototype', 'effects' %> |
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
| Processing OrdersController#fire (for xxx.xxx.xxx.xxx at 2008-11-19 09:06:43) [PUT] | |
| Session ID: BAh7CjoOcmV0dXJuX3RvMDoMY3NyZl9pZCIlZmI0NGUxYzQxMTY0NWRhNDBh | |
| YWVlZmM2ZmNhYTY3NzI6DHVzZXJfaWRpBiIKZmxhc2hJQzonQWN0aW9uQ29u | |
| dHJvbGxlcjo6Rmxhc2g6OkZsYXNoSGFzaHsABjoKQHVzZWR7ADoNb3JkZXJf | |
| aWQw--8ec59532c83eef92f2e1cdaada63121ecce91fdc | |
| Parameters: {"action"=>"fire", "_method"=>"put", "authenticity_token"=>"f26f6ddcc8db30ba2a504002fb01883e1bfeb4b4", "id"=>"685019094", "e"=>"capture", "controller"=>"admin/orders"} | |
| Gateway Error ... | |
| Redirected to http://xxxxx.com/admin/orders | |
| Completed in 0.65447 (1 reqs/sec) | DB: 0.04395 (6%) | 302 Found [http://xxxxxx.com/admin/orders/685019094/fire?e=capture] | |
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
| Useful Rails plugins | |
| jrails | |
| paperclip | |
| resource_controller | |
| restful-authentication | |
| restful-authorization | |
| shoulda | |
| tlsmail | |
| ultrasphinx |
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
| <% calendar :year => 2009, :month => 1, :events => @events, :field => :happens_on do |date, events| %> | |
| <% for event in events %> | |
| <%= link_to event.name, event_path(event) %> | |
| <% end %> | |
| <% 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
| class ImageModelsController < ApplicationController | |
| before_filter :find_image_model, :only => [:update] | |
| def update | |
| if @image_model.update_attributes(params[:image_model]) | |
| @image_model.image.reprocess! | |
| end | |
| end | |
| protected |
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
| Letícia: Olá Ricardo, em que posso ajudar ? | |
| Ricardo: Olá, fiz um pedido no dia 2/7 e até hoje ele está em ´análise´ | |
| Ricardo: O número do pedido é XXXXX | |
| Letícia : Sr.,infelizmente houve um erro no sistema, | |
| sob o qual seu pedido se encontra. Pedimos | |
| desculpas pelo transtorno, mas caso ainda | |
| deseje adquirir este produto,pedimos para |
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
| # | |
| # Generates the migration and opens it in TextMate | |
| # | |
| # ex.: | |
| # mig AddNewColumnToModel new_column:integer | |
| # | |
| function mig { | |
| mate `script/generate migration $@ | tail -n1 | sed 's/.*create //'` | |
| } |
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
| class PageSweeper < ActionController::Caching::Sweeper | |
| observe Page | |
| def after_save(page) | |
| clear_page_cache | |
| end | |
| def after_destroy(page) | |
| clear_page_cache | |
| 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
| module ActionController | |
| module Caching | |
| class Sweeper | |
| def sweep_directory(dirs) | |
| dirs.each do |dir| | |
| cache_dir = RAILS_ROOT + "/public/#{dir}" | |
| FileUtils.rm_r(Dir.glob(cache_dir+"/*")) rescue Errno::ENOENT | |
| RAILS_DEFAULT_LOGGER.info("Cache directory '#{cache_dir}' fully swept.") |
OlderNewer