Commit Graph

87 Commits

Author SHA1 Message Date
Bharat Mediratta
fc6bdbbbc8 Grab photo capture date and captions from EXIF/IPTC data.
- Add a "captured" column to the items table.
- Pull the DateTime EXIF field and put it into the captured column
- Pull the Caption EXIF & IPTC fields and put them into the description
  field if there was not already a value there
2009-05-07 01:18:31 +00:00
Bharat Mediratta
c936eebcf7 Don't do graphics detection in core_installer::install() because that
gets run at scaffolding::package() time, not on the target machine.
Instead, create a core module variable to trigger running
graphics::choose_default_toolkit() on the first admin login after install.

Fixes ticket #206.
2009-04-05 20:43:05 +00:00
Tim Almdal
f1eec57221 Add a weight column to the items model. Change the album ordering to
use this as the default instead of id.  This prepares the way for
manual reordering in the organize functionality.
2009-04-05 16:57:51 +00:00
Bharat Mediratta
d432cba2cb change version from "3.0 Alpha 3" to "3.0 pre-beta svn" 2009-03-24 21:09:37 +00:00
Bharat Mediratta
06baa24dd6 Set our version to 3.0 Alpha 3 and add 'logs' as a dir we create at install time 2009-03-20 08:21:43 +00:00
Bharat Mediratta
61d8a143ea Rejigger the way we do reinstalls while Kohana is running.
core_installer::install() now takes an $initial_install param that
allows us to enforce that we're doing a clean install.  Use this in
both the scaffolding and the unit test code.

Greatly simplify the scaffolding uninstall/reinstall code.
2009-03-19 02:35:51 +00:00
Tim Almdal
9d65379160 Remove semi-colons from single sql statements and correct anoter
instance of {items` which won't get prefixed properly
2009-03-18 03:36:18 +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
6f0ddb4057 Set the sort_column and sort_order for the root album 2009-03-16 08:48:34 +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
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
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
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
Andy Staudacher
c5964c74cd Fix i18n create table sql (forgot to change core_install.php) 2009-02-24 06:10:40 +00:00
Andy Staudacher
c2eee47465 Move site default_locale into DB (vars) and add a per user locale preference.
There's no UI to select the locale yet.
2009-02-10 02:37:16 +00:00
Andy Staudacher
dce6548431 Add local localization functionality. Local = no means to upload / download translations to a translation server yet.
- Added an outgoing_translations table to store translations from the local translation UI.
 - I18n class is checking incoming_ and outgoing_translations for translations, giving the latter priority.
 - Not handling plural strings in the translations UI yet.
2009-02-09 08:42:13 +00:00
Tim Almdal
1fc2307fab rollback r20001-r19998, r19995. This may require a reinstall 2009-02-08 02:21:28 +00:00
Tim Almdal
4e107dac41 Implement fix for ticket #35. *** Requires reinstall of core ***
* Added new field in items table (path) which is sanitized version of
name.
* Added __set method on Items_module to set the path field whenever
the name field is changed.
* Made some changes to the scaffolding so missing the path column
would not kill the scaffolding.
* Changed MY_url::site so not having a 3rd parameter won't throw an error.
2009-02-06 16:39:18 +00:00
Bharat Mediratta
d97308ffe7 Put the <a> element inside the internationalized text. 2009-01-19 05:24:47 +00:00
Bharat Mediratta
8ec0e8471f Drag and drop in the admin dashboard now saves the location.
* Make block_adder a real block
* Suppress the "close" link on block_adder
* Move the drag/drop JS into the core code out of the admin theme
2009-01-18 09:06:46 +00:00
Bharat Mediratta
7b68ca9946 Refactor dashboard -> block_manager since it'll manage blocks site
wide, not just in the dashboard.
2009-01-18 06:55:04 +00:00
Andy Staudacher
e4a9b19bf9 Changing t() placeholder syntax from {{replace_me}} to %replace_me. 2009-01-15 10:02:41 +00:00
Bharat Mediratta
f3ba69c1d6 Make sure that helper functions are all static. Add new
File_Structure_Test to make sure we don't regress.

According to the PHP docs, the "public" keyword is implied on static
functions, so remove it.  Also, require private static functions to
start with an _.

http://php.net/manual/en/language.oop5.visibility.php
2009-01-14 04:12:02 +00:00
Bharat Mediratta
35a529cd86 Change admin/themes to show both styles of themes side by side. This
eliminates the menu, which is kind of clunky.

While I'm at it, let's call the "regular" themes a "site theme" so we
have "site" and "admin" themes.
2009-01-13 10:53:06 +00:00
Bharat Mediratta
ff6791f576 Models should be named in adjective_noun form to make pluralizatoin
more intuitive.

Renamed Translations_Incoming to Incoming_Translation to suit.
2009-01-13 01:05:11 +00:00
Bharat Mediratta
c5f77510a7 Refactor dashboard block handling out into a dashboard helper so that
module installers don't have to know the grotty details of how it works.
2009-01-12 08:51:54 +00:00
Bharat Mediratta
bc421a615a Implement deleting dashboard blocks.
* Refactor blocks so that they have a separate id vs css_id.  This way
  we can have a unique identifier for each visual block.

* Store blocks with a random id as their unique identifier

* Add Admin_Dashboard::remove_block() and modify
  themes/admin_default/views/block.html.php to call it when you click the
  remove box.
2009-01-12 08:26:38 +00:00
Bharat Mediratta
b19729435c Dashboard blocks are now data driven, and you can add new blocks to
both the sidebar and the center content area from a dropdown at the
top of the dashboard sidebar.
2009-01-12 07:39:53 +00:00
Felix Rabinovich
b647aa0f74 Theme Administration v. 2. Doesn't distinguish between regular and admin themes yet 2009-01-09 23:31:46 +00:00
Andy Staudacher
a631fe29f3 i18n refactoring: Rename all _() (reserved by gettext) calls to t().
- And refactor printf to our string interpolation / pluralization syntax
- Also, a slight change to the translations_incomings table, using binary(16) instead of char(32) as message key.
2009-01-08 17:13:06 +00:00
Andy Staudacher
2917740ba6 First step of i18n refactoring:
- Using DB table translations_incomings as translations storage (file cache to be added)
- Removed overly complex i18n code which will be unnecessary with the future compiled cache files
- Added t() as a translation function (global refactoring from _() to t() to follow)
2009-01-08 06:52:18 +00:00
Bharat Mediratta
1579494ec4 Preliminary "Edit Permissions" dialog. You can't change permissions
yet, but it shows you which items have locked view perms.
2008-12-31 04:05:41 +00:00
Bharat Mediratta
06188ad813 Oops, this got left out of r19497 2008-12-30 20:19:32 +00:00
Bharat Mediratta
a481a684b6 Add a "Graphics Settings" page that lets admins choose which graphics
toolkit we use.  We only allow users to use one toolkit.  The UI needs
work!
2008-12-30 04:14:57 +00:00
Bharat Mediratta
f29aad03a6 Make some columns smaller so that multi-column keys don't exceed 1024
bytes on some systems.
2008-12-30 01:37:09 +00:00
Bharat Mediratta
ef4ec6d513 Oops, my last change broke the default resize dimensions 2008-12-29 21:25:51 +00:00
Bharat Mediratta
2bfddc4c87 Make graphics rules take named parameters. This will give us some
flexibility in the future.
2008-12-29 20:20:10 +00:00
Bharat Mediratta
ed8689f768 Expand on the maintenance code to make it more robust and give the
admin more control.  You can now track running tasks, resume stalled
tasks, cancel running tasks, and remove finished tasks.

Added graphics::compose() as a placeholder for future watermark
operations.

Added CSRF protection to maintenance urls.
2008-12-28 23:48:15 +00:00
Bharat Mediratta
74d4e7d505 First round of a task framework. Tasks are job definitions stored in
the database.  They're started with admin/maintenance/start/[task_name]
which sends down some JS/HTML which regularly pings the task at
admin/maintenance/start/[task_id] until its done.

The UI is still very rough.  It works, though!
2008-12-28 10:12:41 +00:00
Bharat Mediratta
dee20ed6a2 Added the concept of "permanent" messages that we show to admins. Use
this to show a "your thumbs/resizes are out of date" message whenever
we change the graphics rules.  Tweak watermark module to add graphics
rules whenever we make a change, which triggers the graphics module to
add the permanent message.
2008-12-26 05:43:06 +00:00
Bharat Mediratta
2502240ce4 Add very simple graphics toolkits.
Track a set of rules in Graphics_Rule_Model which specify how we turn
original images into thumbnails and resizes.  There's one set of rules
that applies to every image in the Gallery.

Track the state of thumbs and resizes with a "dirty" bit.  The new
graphics helper manages the rules and can rebuild the thumbs and
resizes for any images that are considered "dirty".

Introduce the concept of an "album cover" which is an item that an
album points to.  We'll use that item as the source for the album's
thumbnail/resize.

Conflated with this change (sorry!) I also changed the Var table to
use module_name instead of module_id.  This may be marginally less
efficient, but it's much easier to follow in the database.
2008-12-23 04:14:07 +00:00
Bharat Mediratta
ddcf10dfce Allow the site admin to upload watermark images. Can't do much with them yet. 2008-12-23 01:29:17 +00:00
Bharat Mediratta
3ce32dab55 Report actual log entries in the "log entries" admin block. 2008-12-21 03:56:53 +00:00
Bharat Mediratta
f0b6333344 Add a logging facility, and instrument login/logout to use it. 2008-12-21 03:50:11 +00:00