Commit Graph

391 Commits

Author SHA1 Message Date
Andy Staudacher
222f6e2e23 Functional l10n_client / server interaction:
- Get / verify API Key from l10n server
 - Submit translations
 - Fetch translations / updates

Reference: Tasks: 75, 76, 55

TODO: Move out of core (and a series of other tasks).
2009-03-18 00:53:44 +00:00
Bharat Mediratta
1ab5a76924 Treat calls to install() with TEST_MODE set to be initial installs. At least for now. 2009-03-17 18:17:55 +00:00
Bharat Mediratta
8458eba279 Switch the locale::$locales data structure to be an array instead of a
stdClass because we're not allowed to asort() stdClass objects in PHP
5.2.6.
2009-03-16 09:08:12 +00:00
Bharat Mediratta
6f0ddb4057 Set the sort_column and sort_order for the root album 2009-03-16 08:48:34 +00:00
Bharat Mediratta
eac4e72a3b Oops, fix a typo. 2009-03-16 08:34:20 +00:00
Bharat Mediratta
54e07d0769 Get rid of the extra robust code we had in here to make the
scaffolding work when the Gallery wasn't installed yet.  Now we force
users through the installer.
2009-03-16 08:05:07 +00:00
Bharat Mediratta
c3e70ecfa6 Initialize $result in get_html() 2009-03-16 08:01:46 +00:00
Bharat Mediratta
144b8f4f47 Don't count on the uri having 3 components; that breaks on newer versions of PHP. 2009-03-16 07:45:32 +00:00
Bharat Mediratta
16b1df4f67 Illegal use of $this in static function site(). Replace with $theme. 2009-03-16 07:40:57 +00:00
Tim Almdal
0bc64efa4a Thin down the scaffolding code so that all that is there is the test
data creation and the packaging code.  The rest ofthe functionality is
either no longer required, or moved to the developer module (MPTT
Tree).
Also provide checking for the active user to be an admin.
2009-03-16 03:50:57 +00:00
Tim Almdal
abdab49aef Move the start/stop translating menu item to the admin menu 2009-03-15 22:45:16 +00:00
Tim Almdal
bf4cd1b813 Move profiling and debugging out of the scaffolding and into the
developer module.
2009-03-15 20:35:24 +00:00
Bharat Mediratta
51a16d38b8 style fixes 2009-03-14 18:43:10 +00:00
Tim Almdal
cb3d39fe62 Invert the check for https vs http. 2009-03-14 01:57:37 +00:00
Tim Almdal
2ad27663cb Remove event handlers that are are no longer called (start_batch and end_batch) 2009-03-12 18:16:13 +00:00
Bharat Mediratta
30239ed302 $task_definitions -> $task_def 2009-03-11 03:29:12 +00:00
Tim Almdal
8da729cfa1 Refine the task api but removing the optional parameters on the
task::create method call
2009-03-11 03:14:52 +00:00
Tim Almdal
2ce44b6b08 Fix the Var_Test by making sure that the cache is cleared or updated
when a variable is set or cleared.
2009-03-11 00:27:17 +00:00
Bharat Mediratta
068c44e201 access::allow/deny/reset functions will now throw an exception if you
don't pass in a Group_Model as the argument.  This prevents us from
setting permissions on the wrong group by accidentally passing in a
User_Model.
2009-03-10 20:34:32 +00:00
Tim Almdal
5342578e6d Minor change to the task api with the addition of two optional
parameters. The first allows the specification of a task name.
Non-maintenance tasks are not defined as part of availabl_tasks so we
can't get the name from the task definitions. The 2nd allows the
specification of a context when the task is completed.
2009-03-10 13:53:59 +00:00
Bharat Mediratta
9d4769da87 Add profiling/debugging switches in the Scaffold menu. 2009-03-10 06:45:55 +00:00
Tim Almdal
c0375db79f Restructure the sort order to maintain the sort column and sort order
as two separate columns in the item table.
2009-03-09 13:30:22 +00:00
Bharat Mediratta
f32f1697c9 Get rid of Task_Definition types: they're not necessary. This
incidentally fixes the the problem that admin/maintenance tasks have
been broken.
2009-03-09 07:02:09 +00:00
Bharat Mediratta
4fed34873a Don't let graphics::resize() upscale images.
Fixes ticket #117.
2009-03-09 06:59:05 +00:00
Bharat Mediratta
2aaf263b9e On second thought, make the description column varchar(2048) instead.
If I understand correctly, this is better for performance.  I could be
wrong here, though.
2009-03-09 03:33:49 +00:00
Bharat Mediratta
1ad7ca639d Make the description a text column so that we can handle much larger
descriptions.
2009-03-09 03:29:22 +00:00
Bharat Mediratta
445f18fb51 Tweak abs_file() and abs_site() to generate https urls as appropriate.
Fixes ticket #125
2009-03-09 02:07:58 +00:00
Bharat Mediratta
198297e0d4 Instead of putting after_install in the url, put it in the session.
This helps us to make sure that we only see the welcome message once.
2009-03-09 00:03:04 +00:00
Bharat Mediratta
72c7fed975 Log the user in as admin after running the web installer, and give
them a nice "Welcome to Gallery 3" dialog.  The text in there needs a
little work but it's a start.

In the process, re-build the install.sql using the scaffolding code.
2009-03-08 21:21:09 +00:00
Tim Almdal
8f1e90d837 Update sort order processing per Bharat's feedback
* Remove mime type and type as sortable fields
* Change the internal representation to serialized array
* Shorten the database field to varchar(64)
2009-03-08 19:10:08 +00:00
Tim Almdal
39954ad0b7 Implement Sortable albums. Current sort fields include (Creation
Date, Update Date, Random Key, Title, Mime Type, Item Type & Number of views)
2009-03-08 16:29:01 +00:00
Bharat Mediratta
3356091b65 Add in-request caching of vars that we've already looked up. We're
still doing too many database queries, but this cuts down some dupes.
2009-03-07 04:44:16 +00:00
Bharat Mediratta
23937ff135 Avoid using default task types. Require task::get_definitions() to
specify a single type and ask for it appropriately in
admin_maintenance.  Specify a type for every existing task.
2009-03-05 06:38:11 +00:00
Bharat Mediratta
898ac3ac35 A little task restructuring 2009-03-05 06:28:23 +00:00
Tim Almdal
7786bb09d3 Implement a Maintenance mode as per ticket: #15 2009-03-05 00:32:33 +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
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
b7a72825af Remove the === false and === true checks
I really mean it this time
2009-03-03 06:26:12 +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
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
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
bd15853708 This implements table prefix for all the queries in core, user, exif,
tag, search, comment and notification modules (Ticket #68)
2009-02-27 21:07:18 +00:00
Tim Almdal
dc4f784558 * Refactor task management methods from admin_maintenance.php to
task.php
* Added a owner_id field to the task database
* Modified the admin maintenace to show the owner of the task
<<**** Requires a reinstallation of core ****>>
2009-02-27 16:28:20 +00:00
Tim Almdal
d097b4fc02 Update to image_block based on bharat's feedback
1) move the rand_key column into core
2) don't do a max rand, just try to a get a random number less than
the current random number if that doesn't successd look the other way
2009-02-26 23:38:17 +00:00
Tim Almdal
95a1842034 Remove the commented line $parent->$movie->parent() as the $parent
object was passed in as a parameter.
2009-02-26 20:23:40 +00:00
Tim Almdal
c3fcd3a79b Fix thumbnail and resize generation for photos. the variable $type had
never been set, so it was never equal to "photo" so no thumbnails were generated.
2009-02-26 16:12:09 +00:00
Tim Almdal
0929d41305 Added a check to insure that the resize or thumbs image files do not
exists. As per ticket #109
2009-02-26 14:53:01 +00:00