From d5a43f1aa76c1e0086f08bec9c575d2a41ae9a9b Mon Sep 17 00:00:00 2001 From: Robin Houston Date: Wed, 4 Jul 2012 13:45:29 +0100 Subject: Atom feed of request events We need not only new requests, but new outgoing correspondence of any sort. The idea is that this feed will contain any event that would have triggered an email to be sent to the public body, so can be used as an alternative, equivalent way to stay up-to-date with happenings on WDTK (or the Alaveteli installation of choice). --- app/views/api/new_requests.atom.builder | 22 ---------------------- 1 file changed, 22 deletions(-) delete mode 100644 app/views/api/new_requests.atom.builder (limited to 'app/views/api/new_requests.atom.builder') diff --git a/app/views/api/new_requests.atom.builder b/app/views/api/new_requests.atom.builder deleted file mode 100644 index bd5c2f90e..000000000 --- a/app/views/api/new_requests.atom.builder +++ /dev/null @@ -1,22 +0,0 @@ -atom_feed do |feed| - feed.title("New requests made to #{@public_body.name}") - feed.updated(@requests.first.updated_at) - - puts @requests.inspect - for request in @requests - feed.entry(request) do |entry| - entry.updated(request.updated_at) - entry.published(request.created_at) - entry.title(request.title) - entry.content(request.last_event_forming_initial_request.outgoing_message.body, :type => 'text') - entry.author do |author| - author.name(request.user_name) - if !request.user.nil? - author.uri(main_url(user_url(request.user))) - end - author.email(request.incoming_email) - end - end - end -end - -- cgit v1.2.3