Bharat Mediratta
b878ed174d
Refactor Menu code to create allow you to create menus using a
...
chainable factory interface and retrieve them by ids. Streamlined the
HTML creation code a little bit in the process, moved the basic menu
functionality into Theme_View and created the option to have different
menus other than site_navigation().
2008-12-08 06:14:34 +00:00
Bharat Mediratta
736829490a
Minor cleanups.
2008-12-08 04:50:56 +00:00
Bharat Mediratta
528a48a96e
Minor cleanups.
2008-12-08 04:47:31 +00:00
Bharat Mediratta
73496de94f
Tighten up head()
2008-12-08 04:39:21 +00:00
Tim Almdal
ee2299d6d0
Restructure Menu processing to respect the differnent types of menu items (Menu's, Menu_Link, Menu_Dialog)
2008-12-08 00:23:33 +00:00
Tim Almdal
3449827c5a
Change the menu processing to add the gDialogLink class if the url starts with a #. this results in a modal dialog box being opened. At this point the url is not retrieved and the text just shows up in the dialog box... need to look at that
2008-12-07 22:10:23 +00:00
Tim Almdal
954fcf0342
Merge gallery3/branches/menus back into gallery3/trunk
2008-12-07 19:45:46 +00:00
Tim Almdal
b409a376f3
1) Change the photo description field to a text area
...
2) Added a 'type' data element to both forge/Form_Textarea and forge/Form_Upload
The second change allows the drawForm to correctly render both of these elements enclosed in a <li>...</li> html blocl
2008-12-07 17:09:21 +00:00
Bharat Mediratta
5d23a6515d
Finish writing unit tests for Access. No bugs found!
2008-12-07 10:56:44 +00:00
Bharat Mediratta
bf7ab8904a
Change ORM_MPTT::add_to_parent() to take an ORM instead of an id so
...
that it's consistent with ORM_MPTT::move_to()
2008-12-07 08:46:44 +00:00
Tim Almdal
fb6e22e145
Implemented photo::_get_photo_add(). You need to create the var/uploads directory and make it writable by the server. The location of the temporary upload directory is specified in config/upload.php
2008-12-06 21:14:36 +00:00
Tim Almdal
8d1790a0b4
* Add a moveTo unit test
...
* Pass the module::event(..., $data) by reference to the handlers
2008-12-05 04:56:33 +00:00
Bharat Mediratta
9ba9f7bf27
Change the startup code to only put installed modules on the autoload
...
path. This breaks a bunch of places where we had hardcoded
dependencies, so guard all of those cases. Restructure
module::available() a bit and the way that we do install/uninstall in
the scaffolding.
2008-12-04 07:44:28 +00:00
Bharat Mediratta
bae905a4cb
Improvements to access helper.
...
o Rename access::remove_group() to access::delete_group() for
consistency.
o Wrote more unit tests
o Tests found a bug in access::remove_item() .. yay!
2008-12-04 06:40:35 +00:00
Bharat Mediratta
e8cf2a3e67
Fix internationalized string.
2008-12-03 23:32:29 +00:00
Bharat Mediratta
ccee9854c2
Rename file::unlink() to dir::unlink(). This creates an API that is
...
clearer about its actions, otherwise we may accidentally blow away an
entire hierarchy when we think we're deleting a single file (there's a
reason why rm won't let you delete dirs that aren't empty!)
Name it "dir" instead of "directory" because apparently "directory" is
already reserved.
Move the delete call out of Items_Controller and into the model. The
model is responsible for keeping state integrity, not the controller.
2008-12-03 23:31:10 +00:00
Tim Almdal
76196be483
Remove @todo
2008-12-03 22:48:23 +00:00
Tim Almdal
7bb4b6029d
Add a MY_file class that extends the file helper by creating an unlink method that deletes a file or an album directory.
...
Modify Items_Controller::_delete to call this new helper method when deleting an item
2008-12-03 22:39:57 +00:00
Bharat Mediratta
c3478675cd
Fix a bug where we weren't actually deleting permissions (hooray for unit tests!)
2008-12-03 19:09:56 +00:00
Tim Almdal
27a9c14d27
If the the post and get arrays don't contain a _method parameter, then use the request::method() to determine the actual request method (i.e. delete doesn't show up in either places)
2008-12-03 17:33:18 +00:00
Bharat Mediratta
e03bb0f7c3
Re-enable access_cache propagation now that we've patched the MySQL driver.
2008-12-03 04:28:14 +00:00
Bharat Mediratta
718ac67a02
get rid of a stray space that was breaking the File_Structure_Test
2008-12-03 04:17:02 +00:00
Bharat Mediratta
c1886aab88
Temporarily disable some code to get tests to pass.
2008-12-03 04:05:24 +00:00
Bharat Mediratta
37758d15de
Drop the right tables at uninstall time
2008-12-03 03:43:50 +00:00
Bharat Mediratta
db5bc20500
Fix a bad copy/pasted comment
2008-12-03 03:18:43 +00:00
Tim Almdal
2e42a5ea8c
Remove the variable from inside _()
2008-12-02 21:37:06 +00:00
Tim Almdal
3953dde2c6
The rearrange module will now add an album if you drag the "new album" onto the album tree. I haven't had a chance to figure out why the form does get any styling or why a textarea is no included as a list item.
2008-12-02 21:25:15 +00:00
Bharat Mediratta
ea11562e32
Oops, this was missing from the last fix.
2008-12-02 04:54:37 +00:00
Bharat Mediratta
ae4c828b06
Fix a problem in _update_access_cache() where if the intent is
...
default, we weren't properly propagating ALLOW where necessary.
2008-12-02 04:38:45 +00:00
Bharat Mediratta
5c303aa07b
Add access::reset() so that you can specify your intent to use the
...
parent's permissions.
Update scaffolding to demonstrate that it works.
2008-12-01 09:57:03 +00:00
Bharat Mediratta
e3d7877d79
Add @todos
2008-12-01 09:01:10 +00:00
Bharat Mediratta
91c4bda1ec
Prototype access control model. There's much left to do, but it's a
...
working implementation.
2008-12-01 08:50:00 +00:00
Bharat Mediratta
4271f7702a
Add access model (not fully baked yet).
...
Update scaffolding to allow addition of just albums (helpful for testing permissions)
2008-11-29 22:47:15 +00:00
Tim Almdal
4c2d4abb1c
Remove debugging statements
2008-11-28 21:55:26 +00:00
Tim Almdal
6a76d6f747
Dynamically create the list of available modules. This permits new modules to be added without having to update the config.php file
2008-11-28 21:22:34 +00:00
Bharat Mediratta
8b6ed6c477
Create module::event() which runs Gallery events. It works by
...
convention. To respond to the "photo_created" event in the gmaps
module, you create modules/gmaps/helpers/gmaps_event.php containing
class gmaps_event which has function photo_created.
Renamed all events from gallery.foo.bar to foo_bar
Updated tag module to use new convention.
2008-11-28 19:37:01 +00:00
Bharat Mediratta
89c4dadec2
Rename module::get_list() to module::installed()
2008-11-28 18:39:18 +00:00
Tim Almdal
3fa12655dd
Correct parameter on gallery.album.created event firing
2008-11-28 04:26:18 +00:00
Bharat Mediratta
1239e38e45
Move the form drawing code back into form.html.php -- I'm going to
...
take a shot at fixing it up in the view file so that it's mostly HTML,
not mostly PHP. If that fails, I'll move it back into a helper.
2008-11-28 03:09:18 +00:00
Tim Almdal
828f23896f
Rename item events and create events for comment create, login, logout, user creation. I probably forgot some, but its a start.
2008-11-28 00:51:38 +00:00
Tim Almdal
3ad9b6174a
Add event plumbing to allow the tag module to be notified when a photo is created. Eventually this will be used to parse the image meta data and extract tags;
2008-11-28 00:19:08 +00:00
Bharat Mediratta
bc210a708e
Set resize to 640x480 for now to avoid breaking the default theme layout
2008-11-27 22:08:00 +00:00
Tim Almdal
6bc9c5868b
Create a form_helper class containing the function Draw_Form so we don't have to always check to see if the DrawForm method is already defined in pages that could have multiple forms.
2008-11-27 16:33:41 +00:00
Bharat Mediratta
723eb2f611
Move the ADMIN global nav option into the core module and only show it if we're logged in as an admin user
2008-11-27 11:43:48 +00:00
Bharat Mediratta
c95c17b133
Centralize logging around installing/uninstalling modules.
2008-11-27 09:45:26 +00:00
Tim Almdal
25b0dff45c
Add a thumbnail to the root directory, in case it gets displayed in a tag dynamic album
2008-11-26 18:49:20 +00:00
Tim Almdal
38a260b1d7
Rename get_absolute_url to abs_current
2008-11-25 16:50:29 +00:00
Tim Almdal
102f0f566b
Normalize atom url generation
2008-11-25 15:54:45 +00:00
Bharat Mediratta
b22494a4ea
Move the in-place-edit JS into the page_footer callback and out of
...
Theme.php.
2008-11-25 04:37:21 +00:00
Bharat Mediratta
b79ce414de
Detect browsers that prefer XHTML (Chrome!) and normalize it to HTML
...
so that we don't ship XML down to Chrome.
2008-11-24 07:50:20 +00:00