Commit Graph
2082 Commits
Author SHA1 Message Date
Tim Almdal 46b752cbc7 Change how the urls are built in the java script 2009-03-05 01:22:27 +00:00
Tim Almdal 1fa05f1093 Clean up no authorized directoriesmessage 2009-03-05 00:50:11 +00:00
Tim Almdal 7786bb09d3 Implement a Maintenance mode as per ticket: #15 2009-03-05 00:32:33 +00:00
Tim Almdal 514e6658f6 Correct typo 2009-03-05 00:05:21 +00:00
Tim Almdal 2b9795ebf5 Remove addition options to the autocomplete call. No point in sending
csrf if we are not verifying it.  Remove the must match flag so
non-existent paths don't cause the input box to empty
2009-03-04 20:59:16 +00:00
Tim Almdal 705e6d62b7 Last of changes required from Bharat's 2nd review pass 2009-03-04 20:09:53 +00:00
Tim Almdal 8575e2b0d1 Continuation of the rename of jquery.autocomplete.pack.js 2009-03-04 19:50:08 +00:00
Tim Almdal 6d7fa5875a rename jquery.autocomplete.pack.js 2009-03-04 19:46:55 +00:00
Tim Almdal d477ffd575 Annotate local fix for Kohana ticket #1156 2009-03-04 18:58:32 +00:00
Bharat Mediratta 014999758e Updated Kohana to r4033 2009-03-04 18:15:56 +00:00
Tim Almdal c0e65b2029 move server_add styles into the theme screen.css files 2009-03-04 16:36:41 +00:00
Tim Almdal ef8c71417a Move the autocomplete js and css files to lib 2009-03-04 16:10:03 +00:00
Tim Almdal fbc650bddb Changed $uid to $tree_id, so not to confuse anyone between and acroynm
for unique identifier as opposed to user id. :-)
2009-03-04 16:01:18 +00:00
Tim Almdal f7d82ec52f Rename local_import module to server_add 2009-03-04 15:46:10 +00:00
Tim Almdal f16224ae82 Work around for Kohana ticket #1156
http://dev.kohanaphp.com/ticket/1156
2009-03-04 14:52:47 +00:00
Bharat Mediratta 234aa2b31d Implement batch support in a simple fashion to avoid having to change the swf file for now 2009-03-04 08:56:16 +00:00
Bharat Mediratta bc13659d37 Remove cruft from API 2009-03-04 08:55:41 +00:00
Bharat Mediratta 23b0abb974 Redefine the batch API to be very very simple. You call
batch::start() before starting a series of events, and batch::stop()
when you're done.

In batch mode, the notification module will store up pending
notifications.  When the batch job is complete, it'll send a single
digested email to each user for all of her notifications.

Updated the scaffold and local_import to use this.  Haven't modified
SimpleUploader yet.
2009-03-04 08:51:49 +00:00
Bharat Mediratta b493a534f2 A variety of cleanups:
* Allow for the "movie" type in all of our text
* Try to follow the pattern of mainly only passing ORM objects
  to the view and let it generate its own text (this becomes
  even more important when 3rd parties want to customize notification
  messages)
* Rename _send_message to be _notify_subscribers to be more acccurate
  and have it explicitly take a subject in the API
* Use Item_Model::url() in the views instead of hand crafting URLs
* Reformat HTML in views
* Use $comment->author_xxx() functions instead of replicating that code
* Fix several places where we were encoding data by doing ucfirst($item->type)
  with conditionals where we form the text properly.  We should *never*
  be showing data types to the end user!  This is not localizable!

Note that this probably breaks the existing batch processing code.  I
am going to redo that in a subsequent pass.
2009-03-04 06:25:55 +00:00
Bharat Mediratta 83e12961b1 Allow url() to return absolute urls 2009-03-04 06:25:25 +00:00
Bharat Mediratta 69cb19aad2 Delete test(), it should never have been checked in. 2009-03-04 06:25:04 +00:00
Bharat Mediratta 3600e73282 Simplify logic a bit and tweak the visible text. 2009-03-04 05:22:42 +00:00
Bharat Mediratta 302ee07acb Indentation and whitespace tweaks. 2009-03-04 04:55:23 +00:00
Bharat Mediratta 3c015b4d5f Fix indentation. 2009-03-04 04:49:00 +00:00
Bharat Mediratta f71cbc8a71 remove unnecessary render() 2009-03-04 04:46:49 +00:00
Bharat Mediratta c487443860 Move <label> outside of <?= ?> block 2009-03-04 04:28:04 +00:00
Tim Almdal 81a6dc26cb Send 1 items added notification per batch of items 2009-03-04 03:31:01 +00:00
Tim Almdal e33ad56b99 Forgot to remove a debugging statement 2009-03-04 03:08:23 +00:00
Tim Almdal 4a5b005931 Use Directory Iterator 2009-03-04 02:03:05 +00:00
Tim Almdal 328a982546 * Validate that the source path is authorized.
* Add site warning message if local_import is installed an there is no
  authorized directories
2009-03-03 23:07:07 +00:00
Tim Almdal e291e88110 Remove csrf verification from autocomplete handler 2009-03-03 22:27:27 +00:00
Tim Almdal c864f23f2e Only show local_import head stuff (css and js) when the local_import
admin page is shown
2009-03-03 22:25:22 +00:00
Tim Almdal 08c47f28f2 Inline the admin view creation that was in helpers/local_import.php
and remove it.  Cleanup unused variables. Rename the method remove()
to remove_path()
2009-03-03 22:19:46 +00:00
Tim Almdal 6596682c90 Use the gallery root directory on the batch::operation call when
generating random albums and images
2009-03-03 21:48:13 +00:00
Tim Almdal f58bbe0610 Improve the comment about why we skip the first path.
Change to use access::required
2009-03-03 21:43:59 +00:00
Bharat Mediratta 9775cb69e2 Fix indentation, remove unnnecessary csrf check. 2009-03-03 21:19:31 +00:00
Tim Almdal acf28e47cb Create a proxy event (gallery_event) which is called when the request
is completing.
2009-03-03 18:57:16 +00:00
Tim Almdal 9b68fd46b2 Add the ability for modules to define hooks. The challenge is that
when the hooks are run, we haven't added all the installed modules to
the path, So if a module defines a hook it will never be run.

This change runs any module defined hooks as part of the gallery initialization.
2009-03-03 16:09:23 +00:00
Tim Almdal 0408a0096a Undo r20234 2009-03-03 06:29:16 +00:00
Tim Almdal b7a72825af Remove the === false and === true checks
I really mean it this time
2009-03-03 06:26:12 +00:00
Tim Almdal 1c6384f823 Removed the === false and === true checks 2009-03-03 06:18:18 +00:00
Tim Almdal 7cadb4b21b Refactored the batch Api: 1) created a small batch helper class:
Starting a batch call batch::operation(name, item). In the case of
adding photos name = add and item is the parent of the new items.
When the operation is finished the batch::end_operation(name) is
called.
operation and end_operation events are called.  Handlers
(i.e. item_created) can call batch::in_progress(name) to determine if
a batch is being processed.
2009-03-03 05:59:38 +00:00
Tim Almdal 1d5cca34ef If backticks (`) are used to delimit the name of the table in
database, Kohana gets confused an appends the prefix outside of the
back ticks
2009-03-03 04:17:55 +00:00
Tim Almdal 7bcab31f5d Fix issue identified by security review... some table names where not
being translated.
2009-03-03 03:52:21 +00:00
Tim Almdal 14c1f45578 Forgot to update the install.sql when i changed the [] to {} to
identify table names that need substitution.
2009-03-02 01:53:26 +00:00
Tim Almdal 512a532650 Simplify the batch api by having the core event handlers for
start_batch and end_batch add and remove the batch id from the
session.  Modules wishing to do batch processing, just need to fire
the start_batch and end_batch events.  Other modules that need to be
aware of batches (i.e. notifications) just check the session for "batch_id".
2009-03-01 19:11:01 +00:00
Tim Almdal bed1bb48f3 The scaffolding, simple_uploader and local_import now call two new
events: start_add_batch and end_add_batch.  The parameter is a batch
id which is generated on the first add request.  The protocol is call
the add_photo as many times as required and then call finish when
done.
Also renamed the add method in local_import to add_photo so it is
consistent with simple_uploader
2009-02-28 20:12:54 +00:00
Tim Almdal c04ff8e02f Change the pattern to identify tables that need prefix substitution to
mirror the drupal pattern of using braces {}.
2009-02-28 06:37:28 +00:00
Tim Almdal ad56995baf Correct a type and missed a table name 2009-02-28 03:34:03 +00:00
Tim Almdal 1328755b11 This implement table prefix for the watermark notification modules (Ticket #68) 2009-02-27 21:15:13 +00:00