Commit Graph

364 Commits

Author SHA1 Message Date
Bharat Mediratta
526859d960 Do simple transliteration when converting filenames to slugs, but check
to see if the transliteration module is available and use a more complex
transliteration if possible.  Fixes #1668.
2011-04-22 13:57:46 -07:00
Bharat Mediratta
bc49680938 Update XSS golden file 2011-01-21 23:09:27 -08:00
Bharat Mediratta
423daa52d5 Update copyright to 2011. 2011-01-21 23:01:06 -08:00
Bharat Mediratta
44da46abd4 Golden file updates for xss and controller authentication. 2011-01-15 15:11:37 -08:00
Bharat Mediratta
f0dd16efc4 Revive the code from Cache_Driver::exists and put it into a helper
function in the test so that we can keep our tests functioning.
Follow on to 66fd8c7518 for #1559.
2011-01-15 14:59:25 -08:00
Bharat Mediratta
b42fcb9cda Use db::expr instead of "new Database_Expression". Resolves #1560. 2010-12-28 23:10:05 -08:00
Bharat Mediratta
9f3c6e4bee Update test to match change in Item_Model::as_restful_array made in
7e31f97b4c for #1536.
2010-12-28 22:00:25 -08:00
Bharat Mediratta
5d37d529b0 Update golden file to reflect the change in
c989981041 for #1520.
2010-12-28 21:56:31 -08:00
Bharat Mediratta
98fd1e9957 Implement item::find_by_relative_url with tests. 2010-12-21 20:47:07 -08:00
Bharat Mediratta
d9299f3b3f Change item::find_by_path() to check the relative_path_cache first,
and only fall back the name/level comparison if there's no cached
entry.  Update tests accordingly.
2010-12-21 19:33:47 -08:00
Bharat Mediratta
2a08cbf76d Return an empty Item_Model when item::find_by_path fails 2010-12-21 16:58:54 -08:00
Bharat Mediratta
f493130e59 Tighten up item::find_by_path slightly. Augment the tests to cover
special characters in the file name ("+" is an edge case differentiator
between rawurlencode and urlencode).
2010-12-21 16:55:01 -08:00
Bharat Mediratta
c7096cc9eb Fix assertion order to be (expected,actual)
Change strinct concatenation to be variable interpolation to tighten it up.
2010-12-21 16:32:02 -08:00
Kriss Andsten
addd384bbd Minor changes to satisfy the G3 code standards. 2010-12-22 08:22:25 +08:00
Kriss Andsten
48640005a4 Packaging + tests of Bharat's find_by_path routine. 2010-12-22 08:22:25 +08:00
Bharat Mediratta
cd48b89f31 Consolidate all the random code into a random helper that offers:
random::hash()
  random::string()
  random::percent()
  random::int()

So that we don't have lots of different ways to get random values all
over the code.  Follow-on to #1527.
2010-12-15 14:57:00 -08:00
Bharat Mediratta
45c63f4d11 Use mt_rand() instead of rand() since it provides better portability.
Fixes #1527.
2010-12-15 12:48:56 -08:00
Bharat Mediratta
6fb0eb4e97 Follow on to d2be26e407 to update the
unit tests to reflect the proper type filtering for #1503.
2010-12-15 12:24:31 -08:00
Bharat Mediratta
ff4c930338 Clean up golden file as a follow-on to
3c523bcac6 for #1499.
2010-12-15 12:08:56 -08:00
Bharat Mediratta
18470a6001 Clean up xss golden file as a follow-on to
945e79b171 for #1478.
2010-12-15 12:07:02 -08:00
Bharat Mediratta
79740a2c77 Move photo/movie file extension validation into the model. Fixes #1524. 2010-12-14 21:19:25 -08:00
Bharat Mediratta
13cc0087ec I don't run these, I doubt anybody does. Deleting 2010-11-20 20:43:18 -08:00
Bharat Mediratta
e87c502ede Tie the image cachebuster to the file mtime instead of
Item_Model::$updated since we want the url to be stable whenever
possible.  Fixes #1482.
2010-11-09 12:48:07 -08:00
Bharat Mediratta
853a3acc9b Implement module::clear_all_vars($module_name)
Also switch from using ORM to Database_Builder for the SQL because it's
cleaner, and clean up the test.  Fixes #1479.
2010-11-08 11:45:14 -08:00
Bharat Mediratta
3c40476b34 Not sure why digibug::close_window() changed in the listing, but it looks fine here. 2010-10-04 23:42:07 -07:00
Bharat Mediratta
fad1f05203 The Kohana folks removed the cache cleanup code back in
http://dev.kohanaframework.org/projects/kohana2/repository/revisions/4605

So now our cache entries don't expire.  For now, do cache expiration
whenever we render Admin > Maintenance, since that's the type of place
that users will go when they want their cache to expire anyway.
2010-09-18 17:46:28 -07:00
Bharat Mediratta
8135429430 Checkpoint. 2010-09-17 13:39:48 -07:00
Bharat Mediratta
1a0d76c43e When moving a single item, just copy its permissions from its parent
album.  This is totally legal since an items permissions must be the
same as its parent's, and it's much faster for large installs where
a complete recalculation can be very costly.  Should fix #1360.
2010-09-13 22:23:09 -07:00
Bharat Mediratta
f84c4a6192 Uniqify the name and slug when we move an item to a new location with
a conflict.  This fixes #1364.
2010-09-11 23:37:12 -07:00
Bharat Mediratta
34a71e7cd3 Verified. 2010-09-11 01:48:44 -07:00
Bharat Mediratta
509b647c65 upgrader/index does not require CSRF 2010-09-11 01:48:26 -07:00
Bharat Mediratta
8fed0fb2e2 Updated for b6fa33faf7 2010-09-07 22:42:01 -07:00
Bharat Mediratta
ec2c9dad64 Verified checkpoint. 2010-09-06 15:20:04 -07:00
Tim Almdal
4a7fc1a981 Fix up the test so it works with the changes for ticket #1216. Also note the name change to the first test. Form a php reflection point of view Sendmail_Test (class name) == sendmail_test (method name) so the method gets treated as a constructor instead of a test method. 2010-09-01 23:21:56 -07:00
Tim Almdal
e09c6dbd5e Patch for ticket #1216. Move the values that were in the sendmail config file and store them as gallery module variables. Requires a version number bump to 37. 2010-08-31 20:45:09 -07:00
Bharat Mediratta
545c069786 Delete old SWFupload code. We replaced it with uploadify ages ago. 2010-08-24 21:27:34 -07:00
Bharat Mediratta
ff1d8aea2f We use UTF-8 everywhere. Fixes ticket #1285. 2010-08-15 01:59:54 -07:00
Bharat Mediratta
a1be33f6ab Verified. 2010-08-15 00:46:02 -07:00
Bharat Mediratta
2dda8e22a7 Use the gallery helper date/time functions wherever we format date
time for the browser.  Fixes ticket #1278.
2010-08-08 16:54:31 -07:00
Bharat Mediratta
8da37d595c Verified. 2010-08-08 15:25:21 -07:00
Bharat Mediratta
f5b7e207c8 Verified. 2010-08-08 15:02:58 -07:00
Bharat Mediratta
ab2e2d2d77 Add the $max_level param to all calls to _sanitize_for_dump() 2010-08-08 15:00:23 -07:00
Bharat Mediratta
dfb095a262 Add the ability to replace the source data file in Item_Model::save().
Refactor the rotate code in Quick_Controller to replace the data file,
and then have gallery_event::item_updated_data_file() pick up after
the change is saved, rebuild the image and handle album covers.  This
is much more portable than before and it will allow any mechanism (eg:
REST) to replace the source image.
2010-08-07 22:18:28 -07:00
Bharat Mediratta
bf1e1d3d1f Verified 2010-07-27 11:19:48 -07:00
Bharat Mediratta
f9137c756e Updated 2010-07-27 10:53:31 -07:00
Tim Almdal
dbf3199e46 Fix for ticket #1181. Use $.getJSON to retrieve the json contents of the dialog. Convert all the controllers
that create the data to go into a dialog to return the html as part of a json object.
2010-07-06 14:12:01 -07:00
Tim Almdal
9d66783f47 Update the xss golden file 2010-07-06 09:48:37 -07:00
Tim Almdal
eee8c27f26 Correct the controller auth golden file from when the simple_uploader was renamed to flash_uploader 2010-07-06 08:43:02 -07:00
Bharat Mediratta
0d424a635d When we delete an item, make sure that we scrub it from any other
items that may have it in the album_cover_item_id column.  Fixes ticket #1172.
2010-07-03 14:25:33 -07:00
Bharat Mediratta
6ebbb4fbf5 Updated golden files. 2010-06-20 09:51:39 -07:00