Skip to content
This repository
Browse code

Replace broken Pittwater scraper

  • Loading branch information...
commit 6071359873f4783284943b1daacf6b039f5b271c 1 parent 1ee92c1
Henare Degan henare authored

Showing 2 changed files with 1 addition and 30 deletions. Show diff stats Hide diff stats

  1. +1 1  scraper_factory.rb
  2. +0 29 scrapers/pittwater_scraper.rb
2  scraper_factory.rb
@@ -97,7 +97,7 @@ def self.scrapers
97 97 WaggaWaggaScraper.new("City of Wagga Wagga", "Wagga Wagga", "NSW"),
98 98 GriffithScraper.new("Griffith City Council", "Griffith", "NSW"),
99 99 PenrithScraper.new("Penrith City Council", "Penrith", "NSW"),
100   - PittwaterScraper.new("Pittwater Council", "Pittwater", "NSW"),
  100 + ScraperWikiScraper.new("Pittwater Council", "Pittwater", "NSW", "pittwater_council_development_applications"),
101 101 WyongScraper.new("Wyong Shire Council", "Wyong", "NSW"),
102 102 NorthSydneyScraper.new("North Sydney Council", "North Sydney", "NSW"),
103 103 HawkesburyScraper.new("Hawkesbury City Council", "Hawkesbury", "NSW"),
29 scrapers/pittwater_scraper.rb
... ... @@ -1,29 +0,0 @@
1   -require 'info_master_scraper'
2   -
3   -class PittwaterScraper < InfoMasterScraper
4   - def applications(date)
5   - base_path = "http://portal.pittwater.nsw.gov.au/internet/modules/TrackingDA/"
6   - base_url = base_path + "default.aspx"
7   - raw_table_values(date, "#{base_url}?page=search", 1).map do |values|
8   -
9   - #Example description column in applications listing:
10   - #NUM ROAD, SUBURB
11   - #DESCRIPTION TEXT
12   - #Applicant: ...
13   -
14   - da = DevelopmentApplication.new(
15   - :application_id => extract_application_id(values[1]),
16   - :date_received => extract_date_received(values[2]),
17   - :address => extract_address(values[3]),
18   - :description => extract_description(values[3],1..1)
19   - )
20   -
21   - application_number = da.application_id
22   - application_year=""
23   -
24   - da.info_url = URI.escape(base_path + extract_info_url(values[0]))
25   - da.comment_url = da.info_url
26   - da
27   - end
28   - end
29   -end

0 comments on commit 6071359

Please sign in to comment.
Something went wrong with that request. Please try again.