bitsoffreedom / w0bw0b

Tool for keeping track of multiple simultaneous Dutch FoIA-requests.
https://www.bof.nl/
2 stars 1 forks source link

new use case: overview of cases that have been started in a given time window #19

Open rejozenger opened 11 years ago

rejozenger commented 11 years ago

A use case that hasn't been thought of when started: we sometimes need to have an overview of all the case that are created in, say, Q2. We need such a listing for the reports to financial supporters.

The interface should allow the user to provide a start and end date. The system should consider the field "request-date-sent" to determine whether the case should be included in the listing for the user. Ideally the listing is easy to export to, for example, plain text.

rejozenger commented 11 years ago

Previously we have this manually using the mysql query:

select field_revision_field_request_id.field_request_id_value, node_revision.title, taxonomy_term_data.name, field_revision_field_request_date_sent.field_request_date_sent_value from field_revision_field_request_id, taxonomy_term_data,node_revision,field_data_field_organisation_term, field_revision_field_request_date_sent WHERE field_data_field_organisation_term.entity_id = node_revision.nid AND field_revision_field_request_date_sent.entity_id = node_revision.nid AND field_data_field_organisation_term.field_organisation_term_tid = taxonomy_term_data.tid AND field_revision_field_request_id.entity_id = node_revision.nid and QUARTER(field_revision_field_request_date_sent.field_request_date_sent_value) = '2';
rejozenger commented 11 years ago

The year should be a limitation as well. Add:

QUARTER(field_revision_field_request_date_sent.field_request_date_sent_value) = '2013'