wco_models 3.1.0.258 → 3.1.0.259
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/app/models/wco_email/message_stub.rb +4 -3
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 223ecc2a00f0a91ac463c96c09c386ded1ce3c6ef6f074283bce68c1be7def91
|
|
4
|
+
data.tar.gz: 7d90b43527a97ebf2411f68c083a4e81729629178d3c7fb7187a8aafabafec46
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: f23a86024790353dfd074f772998705163a303a3dd2187d280b9469886c5664f63fa57dab848c4f3b60b7be97bf65f55a00c4c2dab46fec2e0b1a59c393467bb
|
|
7
|
+
data.tar.gz: 5d1ec8a966e0890c5a1064b6b65c7c7efa2b5d5a2b421d164f622a8d45b8646d022b5ac6b2a60c8e2ec5a1bd7fcef4396f3661f0eba50fb2a494ad97e49886fb
|
|
@@ -74,7 +74,8 @@ class WcoEmail::MessageStub
|
|
|
74
74
|
end
|
|
75
75
|
|
|
76
76
|
## Leadset, Lead
|
|
77
|
-
from = json['mail_from'] || "nobody@unknown-doma.in"
|
|
77
|
+
# from = json['mail_from'] || "nobody@unknown-doma.in"
|
|
78
|
+
from = json['from'][/<([^>]+)>/, 1].downcase rescue json['mail_from']
|
|
78
79
|
@lead = Wco::Lead.find_or_create_by_email( from )
|
|
79
80
|
@conv.leads.push @lead
|
|
80
81
|
@leadset = Wco::Leadset.from_email from
|
|
@@ -146,8 +147,8 @@ class WcoEmail::MessageStub
|
|
|
146
147
|
reason = 'subject_exact'
|
|
147
148
|
end
|
|
148
149
|
|
|
149
|
-
filter.conditions.each do |
|
|
150
|
-
reason ||=
|
|
150
|
+
filter.conditions.each do |cond|
|
|
151
|
+
reason ||= cond.apply(leadset: @leadset, message: @message )
|
|
151
152
|
end
|
|
152
153
|
|
|
153
154
|
if reason
|