Skip to content

Instantly share code, notes, and snippets.

View guipdutra's full-sized avatar

Guilherme Dutra guipdutra

View GitHub Profile
# ~/.bashrc: executed by bash(1) for non-login shells.
# see /usr/share/doc/bash/examples/startup-files (in the package bash-doc)
# for examples
# If not running interactively, don't do anything
[ -z "$PS1" ] && return
# don't put duplicate lines in the history. See bash(1) for more options
# ... or force ignoredups and ignorespace
HISTCONTROL=ignoredups:ignorespace
# SCREENSHOT EXAMPLE: http://grab.by/bzg3
##############################
# _
# | |_ _ __ ___ _ ___ __
# | __| '_ ` _ \| | | \ \/ /
# | |_| | | | | | |_| |> <
# \__|_| |_| |_|\__,_/_/\_\
#
#############################
"avoiding annoying CSApprox warning message
let g:CSApprox_verbose_level = 0
" Required Vundle setup
set nocompatible
filetype off
set rtp+=~/.vim/bundle/Vundle.vim
call vundle#begin()
Bundle 'gmarik/Vundle.vim'
"avoiding annoying CSApprox warning message
let g:CSApprox_verbose_level = 0
" Required Vundle setup
set nocompatible
filetype off
set rtp+=~/.vim/bundle/Vundle.vim
call vundle#begin()
Bundle 'gmarik/Vundle.vim'
# SCREENSHOT EXAMPLE: http://grab.by/bzg3
##############################
# _
# | |_ _ __ ___ _ ___ __
# | __| '_ ` _ \| | | \ \/ /
# | |_| | | | | | |_| |> <
# \__|_| |_| |_|\__,_/_/\_\
#
#############################
diff --git a/Gemfile b/Gemfile
index aaa4ce3..af8d414 100644
--- a/Gemfile
+++ b/Gemfile
@@ -1,7 +1,8 @@
source 'https://rubygems.org'
-ruby "1.9.3"
-gem 'rails', '4.0.2'
-gem 'pg', '0.14.1'
+ruby "2.1.2"
diff --git a/Gemfile b/Gemfile
index aaa4ce3..4ab92a5 100644
--- a/Gemfile
+++ b/Gemfile
@@ -1,7 +1,8 @@
source 'https://rubygems.org'
-ruby "1.9.3"
-gem 'rails', '4.0.2'
-gem 'pg', '0.14.1'
+#ruby "2.1.2"
def generate_fields(f, rand, data_type, column, operator)
out = ''
if ["Date", "DateTime"].include?(data_type)
out << f.select(:operator, hash_to_options(FilterConstants::DATE_OPERATOR), { :selected => operator }, { :class => "text mini o_#{rand}" })
out << f.text_field(:condition, :value => (f.object.condition.to_date.to_s_br rescue nil), :class => "text mini js c_#{rand} format[date]")
elsif data_type == "Month"
out << f.select(:operator, hash_to_options(FilterConstants::DATE_OPERATOR), { :selected => operator }, { :class => "text mini o_#{rand}" })
out << f.text_field(:condition, :value => (I18n.l(f.object.condition.to_date, :format => :small_month_and_year) rescue nil), :class => "text mini js c_#{rand} format[competence]")
elsif data_type == "Match"
text = if column.include?("cpf") || column.include?('cnpj')
commit 3501c0d5b6937ade2adc43e2c3997ccc9c280743
Author: Guilherme Dutra <guipereira07@gmail.com>
Date: Wed Jul 2 09:51:19 2014 -0300
22568 - Add iss_value to underwriting alerts
diff --git a/lib/to_mongo/updaters/underwriting_divergence_updater.rb b/lib/to_mongo/updaters/underwriting_divergence_updater.rb
index 9acb948..1ee77fb 100755
--- a/lib/to_mongo/updaters/underwriting_divergence_updater.rb
+++ b/lib/to_mongo/updaters/underwriting_divergence_updater.rb
# encoding: utf-8
class Stub < ActiveRecord::Base
extend EnumerateIt
has_paper_trail
PAYMENT_METHODS = {
:manual => 1,
:bank_return => 2,
:national_simple => 3,
:internal => 4,