summaryrefslogtreecommitdiff
path: root/core/controllers
AgeCommit message (Collapse)Author
2009-01-10Display theme detailsFelix Rabinovich
2009-01-10style cleanup.Bharat Mediratta
2009-01-10Split themes into two tabs for regular and admin themesFelix Rabinovich
2009-01-10Big set of changes to comments, with related changes to akismet andBharat Mediratta
user modules. * Don't delete vars when we delete a module. This makes reinstalling a module a lot easier. * Add user::lookup() as the preferred way to load a user, so that other modules don't delve into the user module (that'd be a problem when we swap out user modules) * Notify site admins if Akismet is not fully configured * Bundle all server variables into the comment so that if/when we re-check the comment, we are not using the server info from the site admin's request. * Update Akismet to grab request context data from the comment * Pre-seed comment fields if we have a logged in user. Update comment::create() API to clarify it for this. * Delete comment::update(), that's a controller function. * Add url to User_Model * Add author_name() author_email() and author_url() to Comment_Model. It'll return the appropriate values depending on whether the comment was left by a logged in user or a guest. * Use resetForm() instead of clearForm() when we reload the comment form after ajax submit, this way we preserve the pre-seeded values. * In the user profile page, ignore blank passwords.
2009-01-09Theme Administration cleanup initializationFelix Rabinovich
2009-01-09Theme Administration v. 2. Doesn't distinguish between regular and admin ↵Felix Rabinovich
themes yet
2009-01-08i18n refactoring: Rename all _() (reserved by gettext) calls to t().Andy Staudacher
- 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-08Don't toggle akismet::test_mode if akismet isn't installed.Bharat Mediratta
2009-01-08Add akismet::$test_mode, initialize it to TEST_MODE and don't contactBharat Mediratta
akismet if it's on. Force it on in the scaffolding so that we don't try to run all comments we add from there through Akismet.
2009-01-08Update event calls to take the orig and new models so that event listeners ↵Bharat Mediratta
can do comparisons
2009-01-05Add "quick edit" which lets you edit a photo's details from the albumsBharat Mediratta
page.
2009-01-04Fix message line so that uploads workBharat Mediratta
2009-01-04Require CSRF for any non-"get" action.Bharat Mediratta
2009-01-03Stay on the right page when we navigate up in the breadcrumb.Bharat Mediratta
Introduce a "show" parameter which contains the id of the item that we want to show when we go to the parent's page.
2009-01-03Propagate rotation up to the parent album, if we're rotating the album cover.Bharat Mediratta
2009-01-03Add a new quick-edit mode for editing photos when viewing albums.Bharat Mediratta
Implement image rotation this way.
2009-01-02trim() the path in add_photosBharat Mediratta
2009-01-01Theme Administration implementationFelix Rabinovich
2009-01-01Add deepest album linkBharat Mediratta
2008-12-31Extend permissions interface to allow resetting to the parental default.Bharat Mediratta
2008-12-31Rename permissions_edit to permissions_browse for consistencyBharat Mediratta
2008-12-31Ajaxify the permissions browsing dialog. It only does allow/denyBharat Mediratta
right now, it doesn't allow you to reset to inherited values. That's next.
2008-12-31Rename permission_xxx to permissions_xxx for consistencyBharat Mediratta
2008-12-31Turn permission dialog into a browser where you can look at permissions back ↵Bharat Mediratta
up the tree
2008-12-31Simplify the next/previous logic in the theme by passing in a nullBharat Mediratta
next/prev sib if one didn't exist. (that's what we were supposed to be doing in the first place, anyway)
2008-12-31Add Item_Model::url() and use it where appropriate. Cleans up someBharat Mediratta
grotty looking stuff in themes.
2008-12-31Add sibling information on photo pages and a very simple next/previous ↵Bharat Mediratta
interface.
2008-12-31change single to double quotes.Bharat Mediratta
2008-12-31Preliminary "Edit Permissions" dialog. You can't change permissionsBharat Mediratta
yet, but it shows you which items have locked view perms.
2008-12-31Fully implement the view_full permission.Bharat Mediratta
2008-12-30Update user::create() scaffolding for changes in the user module: can't set ↵Andy Staudacher
the isAdmin bit at creation time.
2008-12-30Add a "Graphics Settings" page that lets admins choose which graphicsBharat Mediratta
toolkit we use. We only allow users to use one toolkit. The UI needs work!
2008-12-29Remove rest::JSON content type; it's causing lots of problems and it doesn't ↵Bharat Mediratta
directly help since text/html works just as well for our JSON communications
2008-12-29Return the task on success so that our UI can show it at 100%Bharat Mediratta
2008-12-29Don't set the document type to JSON when uploading photos.Bharat Mediratta
2008-12-28Expand on the maintenance code to make it more robust and give theBharat Mediratta
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-28First round of a task framework. Tasks are job definitions stored inBharat Mediratta
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-26Added content type to JSON output functionsFelix Rabinovich
2008-12-26Fix a typo.Bharat Mediratta
2008-12-25Rework log and message helpers to be parallel, but separate.Bharat Mediratta
1) they now have their own matching severity constants 2) they both have convenience functions success(), info(), warning() and error() 3) they both have severity_class()
2008-12-25Make sure admin method exist before we call them, else we'll just recurse ↵Bharat Mediratta
into Admin_Controller::__call() again
2008-12-25Reload the parent before using when adding albums/photos since it may have ↵Bharat Mediratta
invalid left/right pointers.
2008-12-25Big round of normalization of the way that our controllersBharat Mediratta
communicate. Almost all controllers now use JSON to speak to the theme when we're dealing with form processing. This means tht we only send the form back and forth, but we use a JSON protocol to tell the browser success/error status as well as the location of any newly created resources, or where the browser should redirect the user. Lots of small changes: 1) Admin -> Edit Profile is gone. Instead I fixed the "Modify Profile" link in the top right corner to be a modal dialog 2) We use json_encode everywhere. No more Atom/XML for now. We can bring those back later, though. For now there's a lot of code duplication but that'll be easy to clean up. 3) REST_Controller is no longer abstract. All methods its subclasses should create throw exceptions, which means that subclasses don't have to implement stubs for those methods. 4) New pattern: helper method get_add_form calls take an Item_Model, not an id since we have to load the Item_Model in the controller anyway to check permissions. 5) User/Groups REST resources are separate from User/Group in the site admin. They do different things, we should avoid confusing overlap.
2008-12-25Rest_Controller -> REST_Controller everywhere, for consistency.Bharat Mediratta
2008-12-24Normalize our Admin controllers so that functions always print outBharat Mediratta
their results, as opposed to having them return their view back upstream. This is a little more code in every controller, but it's much less magical and more consistent. Look up the active_theme and active_admin_theme inside the view itself, no need to do that in the controllers. This makes view initialization easier in the controllers.
2008-12-24Lots of deltas rolled up into a bigger change. Sorry for the mess.Bharat Mediratta
1) Deleted in-place-editing. We'll be replacing this with a real edit system that groups settings together and is more coherent. 2) Tweaked the way that dialog boxes work to get the ajax stuff working again. It's imperfect and does not work properly for uploading images. This is going to get redone also, but this is a good resting point. 3) Created edit forms for albums and photos. Moved _update and _create out of Items_Controller and into the individual subclasses. 4) Created access::required which is a shorthand for: if (!access::can(...)) { access::forbidden(); } 5) Added validation rules to Items_Model 6) Converted login to use the regular modal dialog approach in the theme.
2008-12-23Clean up the way that we upload via dialogs:Bharat Mediratta
1) If the create request is Ajax, then return a 201 Created response code 2) If we receive back a 201 response, then switch to the new page. 3) Display a status message when we do an upload.
2008-12-23Update to reflect change in album::create APIBharat Mediratta
2008-12-23Change photo::create() and album::create() to take ORM instancesBharat Mediratta
instead of ids.
2008-12-23Add very simple graphics toolkits.Bharat Mediratta
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.