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 Buy | |
| include Mongoid::Document | |
| include Mongoid::Timestamps | |
| include Mongoid::MongoTranslation | |
| has_many_related :criterias | |
| field :contact_id, :type => Integer, :index => true | |
| field :offer_type_id, :type => Integer, :index => true |
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
| http://staging.psspy.se/dagens/widget?id=25411&widget[agent_font]=Arial%2CHelvetica%2Csans-serif%3B&widget[agent_font_size]=11&widget[article_chunk_color]=%23847B7B&widget[article_chunk_font]=Verdana%2CArial%2CHelvetica%2Csans-serif%3B&widget[article_chunk_font_size]=12&widget[article_title_color]=%23847B7B&widget[article_title_font]=Verdana%2CArial%2CHelvetica%2Csans-serif%3B&widget[article_title_font_size]=12&widget[box_title]=Nyheter+om+R%C3%A4ttvik&widget[box_title_color]=%23000000&widget[box_title_font]=Verdana%2CArial%2CHelvetica%2Csans-serif%3B&widget[box_title_font_size]=16&widget[chunk_font]=Arial%2CHelvetica%2Csans-serif%3B&widget[chunk_font_size]=11&widget[chunk_size]=250&widget[copyright_color]=%23847B7B&widget[copyright_link_color]=%23000000&widget[height]=700px&widget[iframe_link]=&widget[link_target]=_top&widget[max_results]=5&widget[result_title_font]=Arial%2CHelvetica%2Csans-serif%3B&widget[result_title_font_size]=11&widget[show_more]=%23847B7B&widget[source_name_color]=%231352B9&widget[tab_n |
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
| http://staging.psspy.se/dagens/widget?id=25411&widget[agent_font]=Arial%2CHelvetica%2Csans-serif%3B&widget[agent_font_size]=11&widget[article_chunk_color]=%23847B7B&widget[article_chunk_font]=Verdana%2CArial%2CHelvetica%2Csans-serif%3B&widget[article_chunk_font_size]=12&widget[article_title_color]=%23847B7B&widget[article_title_font]=Verdana%2CArial%2CHelvetica%2Csans-serif%3B&widget[article_title_font_size]=12&widget[box_title]=Nyheter+om+Rättvik&widget[box_title_color]=%23000000&widget[box_title_font]=Verdana%2CArial%2CHelvetica%2Csans-serif%3B&widget[box_title_font_size]=16&widget[chunk_font]=Arial%2CHelvetica%2Csans-serif%3B&widget[chunk_font_size]=11&widget[chunk_size]=250&widget[copyright_color]=%23847B7B&widget[copyright_link_color]=%23000000&widget[height]=700px&widget[iframe_link]=&widget[link_target]=_top&widget[max_results]=5&widget[result_title_font]=Arial%2CHelvetica%2Csans-serif%3B&widget[result_title_font_size]=11&widget[show_more]=%23847B7B&widget[source_name_color]=%231352B9&widget[tab_name_b |
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
| mysql> select id, name, query, id from agents where user_id = 7814; | |
| +-------+-------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+-------+ | |
| | id | name | query |
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
| require 'spec_helper' | |
| require "machinist/mongoid" | |
| describe Mongo do | |
| context "Working with Buy" do | |
| before(:each) do | |
| @buy = Buy.make | |
| @apartment = PropertyType.make(:apartment) |
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 Contact < ActiveRecord::Base | |
| has_many :internet_comunicators | |
| accepts_nested_attributes_for :internet_comunicators, :allow_destroy => 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
| # unicorn_rails -c /data/github/current/config/unicorn.rb -E production -D | |
| rails_env = ENV['RAILS_ENV'] || 'production' | |
| # 16 workers and 1 master | |
| worker_processes (rails_env == 'production' ? 16 : 4) | |
| # Load rails+github.git into the master before forking workers | |
| # for super-fast worker spawn times | |
| preload_app true |
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 OfferObserver < ActiveRecord::Observer | |
| observe :sell, :project, :buy | |
| # we have to do this manually in Buy - ugly but true | |
| def after_save record | |
| record.contact.make_contact_client(record, true) | |
| record.contact.calc_offers(record) | |
| end |
OlderNewer