mls 1.1.2 → 1.1.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 04c7eecf5f527a902375f9a296b61c8e0a538b4e
4
- data.tar.gz: 5ef89b440f2e2765ddc10ba63f3c413c72a7fe42
3
+ metadata.gz: a0d57c55dc66886c12c685651d70a12e6dd89826
4
+ data.tar.gz: d9cbe37f44ecce10b3188a916123bdd662bf45d6
5
5
  SHA512:
6
- metadata.gz: a60c8cdf94a51713178a87a18dd7361afd2b19f888fc0122376dd79c4b0449fb6741eec9e9b33c2879b29f1cc479b11faed6ff13f1121d6395051b3e0898903d
7
- data.tar.gz: 77cc16a7c5d705a13770b4e460e8800a95fb95a865fdd684b94152bebba7a1a737128004822b610a3d285dbf90103e8f43b5af4e4b796a0192eedc55b5d4f5e8
6
+ metadata.gz: 3023a15fa2e01080ceea8f95f0cf818e3fe97a6aa3dca1ba4019daf8d3dcca394048bf317d5d168a24e8feaadc9eba111c8f5b4edf8c5bf75d2fbabd7b12b7a1
7
+ data.tar.gz: 95593869037f36ebe3656a64886ad110e0852524b09f237b9306ef2aae94ab1c2969e5eac4041cf8b070813e86d470c9557d45c0d1a26de30142b7fa186a45a8
data/lib/mls.rb CHANGED
@@ -96,6 +96,8 @@ require 'mls/lease'
96
96
  require 'mls/sublease'
97
97
  require 'mls/space'
98
98
  require 'mls/lead'
99
+ require 'mls/lead_listing'
100
+ require 'mls/lead_property'
99
101
  require 'mls/sale'
100
102
  require 'mls/coworking_space'
101
103
  require 'mls/address'
@@ -1,5 +1,9 @@
1
1
  class Lead < MLS::Model
2
2
 
3
3
  belongs_to :account
4
+ belongs_to :agent, class_name: "Account"
4
5
 
6
+ has_many :lead_properties
7
+ has_many :lead_listings
8
+
5
9
  end
@@ -0,0 +1,7 @@
1
+ class LeadListing < MLS::Model
2
+
3
+ belongs_to :listing
4
+ belongs_to :lead_property
5
+ belongs_to :lead
6
+
7
+ end
@@ -0,0 +1,10 @@
1
+ class LeadProperty < MLS::Model
2
+
3
+ belongs_to :lead
4
+ belongs_to :property
5
+ belongs_to :creator, class_name: "Account"
6
+
7
+ has_many :lead_listings
8
+ has_many :listings, through: :lead_listings
9
+
10
+ end
@@ -38,7 +38,7 @@ class Listing < MLS::Model
38
38
  # has_many :agents, -> { order('agencies.order') }, :through => :agencies, :inverse_of => :listings, :source => :agent
39
39
  # has_many :email_proxies, :as => :subject, :inverse_of => :subject
40
40
  # has_many :lead_listings, :dependent => :delete_all
41
- #
41
+
42
42
  has_and_belongs_to_many :uses
43
43
 
44
44
  def contact
@@ -3,7 +3,7 @@ $:.push File.expand_path("../lib", __FILE__)
3
3
 
4
4
  Gem::Specification.new do |s|
5
5
  s.name = "mls"
6
- s.version = '1.1.2'
6
+ s.version = '1.1.3'
7
7
  s.authors = ["Jon Bracy", "James R. Bracy"]
8
8
  s.email = ["jon@42floors.com", "james@42floors.com"]
9
9
  s.homepage = "http://mls.42floors.com"
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: mls
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.2
4
+ version: 1.1.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jon Bracy
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2014-09-16 00:00:00.000000000 Z
12
+ date: 2014-09-18 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: rake
@@ -200,6 +200,8 @@ files:
200
200
  - lib/mls/flyer.rb
201
201
  - lib/mls/inquiry.rb
202
202
  - lib/mls/lead.rb
203
+ - lib/mls/lead_listing.rb
204
+ - lib/mls/lead_property.rb
203
205
  - lib/mls/lease.rb
204
206
  - lib/mls/listing.rb
205
207
  - lib/mls/locality.rb