aboutsummaryrefslogtreecommitdiffstats
path: root/perllib/FixMyStreet/App/Model/PhotoSet.pm
Commit message (Collapse)AuthorAgeLines
* Fix missing package requirement.Matthew Somerville2019-06-12-1/+0
|
* [Hounslow] Add general enquiries functionalityDave Arter2019-06-06-17/+2
| | | | | | | | | | | | This functionality allows a cobrand to replace the /contact form with a form that creates hidden reports which are sent via Open311. The form also allows file uploads in addition to photos. This functionality is currently enabled for the Hounslow cobrand and others cobrands can enable it by defining setup_general_enquiries_stash which primarily sets up the appropriate categories and default values for the report.
* If report hidden, also purge update photos cache.Matthew Somerville2019-05-07-1/+6
|
* Enforce maximum photo size on upload.Matthew Somerville2018-11-14-0/+1
| | | | (This might well have been done client-side by Dropzone.)
* Factor out ImageMagick wrapper.Matthew Somerville2018-11-14-53/+6
|
* Add option to symlink full size photos.Matthew Somerville2018-11-14-1/+19
|
* Factor out photo storage backend init checksDave Arter2018-09-28-4/+3
|
* Factor out photo storage into PhotoStorage::FileSystem backendDave Arter2018-09-28-45/+20
|
* Do upload_dir check on start up, not each report.Matthew Somerville2017-03-15-8/+1
| | | | | If we're chugging through a list of reports, this save on a lot of pointless statting of the upload directory which we know is there.
* Assume photo ID given in database exists on disk.Matthew Somerville2017-02-28-6/+1
| | | | | | | The list code was checking the photo ID given in the database existed on disk – this shouldn't ever not be the case, and if it was, all that would happen would be a broken image when the full photo code looks for it (this is only for e.g. lists of reports).
* Make UPLOAD_DIR/GEO_CACHE relative to project rootMatthew Somerville2016-08-10-1/+1
| | | | | If they are absolute already, do nothing. Switch a couple of uses to Path::Tiny as well.
* Test for Image::Magick installation better.Matthew Somerville2016-08-01-4/+10
| | | | (VERSION disappears in some recent version.)
* Remove specific files rather than glob.Matthew Somerville2016-05-18-4/+15
| | | | This should improve performance when there are a lot of cached photos.
* Fix removal of cached update photos.Matthew Somerville2016-05-18-2/+4
| | | | | It was possible that rotating an update photo did not remove its cached copy.
* Switch external jhead call to use IPC::Open3.Matthew Somerville2016-05-03-1/+8
|
* Don't warn on bad photo hashes.Matthew Somerville2016-04-22-2/+2
|
* If admin removes all images, set db field to null.Matthew Somerville2016-04-20-2/+4
|
* Add PNG image support.Matthew Somerville2016-04-08-32/+47
| | | | | | | Store image type along with hash in photo column, and use that when outputting images / generating URLs. Make sure all public photo URL generation goes through appropriate functions, and change temp URLs so the filename can be output directly from the list.
* Only load images from disk when needed.Matthew Somerville2016-02-23-36/+36
| | | | Fixes #1337.
* Factor multiple photo details into nicer function.Matthew Somerville2016-01-12-5/+0
| | | | | Remove get_photo_params, which only looked at the first photo, make explicit when we're doing that using `.first`.
* Remove most passing of Catalyst to PhotoSet.Matthew Somerville2016-01-12-3/+1
|
* Handle multiple photo rotation/removal in admin.Matthew Somerville2016-01-08-0/+22
|
* Remove risk of infinite loop in PhotoSet.Matthew Somerville2015-12-16-8/+12
| | | | | | Use a separate attribute for data direct from a database row when creating a PhotoSet, so that data will always contain one or more photo IDs.
* Reduce use of FixMyStreet::App.Matthew Somerville2015-12-02-1/+1
| | | | Command line scripts don't need a full blown app, just database.
* Base 64 decode uploaded images if requiredSteven Day2015-10-06-1/+20
| | | | | | | | | | | The new Zurich app has to base64 encode some images into a multipart request so that it can (ab)use Phonegap's FileTransfer plugin to send more than one image in a single request to /report/new/mobile. Catalyst's Request::Upload module doesn't look at the Content-Transfer-Encoding header inside multipart requests to do this automatically, so we perform the decoding manually when we process the images in the PhotoSet model.
* Allow attachment of emails in email_sendHakim Cassimally2015-10-06-1/+19
| | | | Required by Zurich for mysociety/FixMyStreet-Commercial#675
* Add support for multiple photos per report.Hakim Cassimally2015-10-06-0/+269
For Zurich, see mysociety/FixMyStreet-Commercial#664. This commit includes a new PhotoSet class (NB: called Model:: though not really a model), should handle binary data (e.g. old style photos in database), fileids (40-char hash), and Catalyst::Upload objects.