ecfs 0.3.4 → 0.3.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/ecfs/solr_scrape_query.rb +22 -3
- data/lib/ecfs/version.rb +1 -1
- data/test/test_solr_scrape.rb +1 -0
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c08bb2a43f4344571816d8fb05cf966526ec72c6
|
4
|
+
data.tar.gz: d82aa4e5cee3a3f8cae3112b6af79f5d5a3ef139
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 841852ed074e68f27784e77d386ec6bc9f774547846bd892b8ecc4628f6b6478f83496c7241a0c7b4df6dcfab0ba6948fbb1b96ba0032115130493dd1540cd57
|
7
|
+
data.tar.gz: 89c133a984efddf1d04f65b2bc1a603b5d1ff8bd16f71af7640ef7dac1fa34002e1d07ac5b0cb75142d2a0606933afce7ded7a8439717d96ddb761c4386dd220
|
@@ -47,7 +47,26 @@ module ECFS
|
|
47
47
|
return filings, total
|
48
48
|
end
|
49
49
|
|
50
|
-
def
|
50
|
+
def filing_to_citation(filing)
|
51
|
+
patterns = {
|
52
|
+
"COMMENT" => "Comments",
|
53
|
+
"REPLY TO COMMENTS" => "Reply Comments",
|
54
|
+
"NOTICE OF EXPARTE" => "Ex Parte Letter"
|
55
|
+
}
|
56
|
+
|
57
|
+
case filing["type_of_filing"]
|
58
|
+
when "COMMENT"
|
59
|
+
return "Comments of #{filing['name_of_filer']}"
|
60
|
+
when "REPLY TO COMMENTS"
|
61
|
+
return "Reply Comments of #{filing['name_of_filer']}"
|
62
|
+
when "NOTICE OF EXPARTE"
|
63
|
+
return "#{filing['name_of_filer']} Ex Parte Letter"
|
64
|
+
else
|
65
|
+
return "#{filing["type_of_filing"].downcase.capitalize} of #{filing['name_of_filer']}"
|
66
|
+
end
|
67
|
+
end
|
68
|
+
|
69
|
+
def get
|
51
70
|
url = "http://apps.fcc.gov/ecfs/solr/search?sort=dateRcpt&proceeding=#{@docket_number}&dir=asc&start=0"
|
52
71
|
filings = []
|
53
72
|
|
@@ -62,8 +81,8 @@ module ECFS
|
|
62
81
|
filings.concat filings_from_docket_number(@docket_number, page)[0]
|
63
82
|
end
|
64
83
|
|
65
|
-
|
66
|
-
|
84
|
+
filings.each do |filing|
|
85
|
+
filing['citation'] = filing_to_citation(filing)
|
67
86
|
end
|
68
87
|
|
69
88
|
filings
|
data/lib/ecfs/version.rb
CHANGED
data/test/test_solr_scrape.rb
CHANGED