summaryrefslogtreecommitdiff
path: root/modules/server_add
AgeCommit message (Collapse)Author
2009-08-18Fix for ticket #590. The gallery.dialog.js looks for an element "#dialog ↵Tim Almdal
#gProgress" and if it finds it assumes that it is a progress dialog and removes the title. This pathc changes the name of the div containing the progress bar to gServerAddProgress and avoids the issue. Signed-off-by: Tim Almdal <tnalmdal@shaw.ca>
2009-08-08Refactor the gallery dialog into a jQuery widgetTim Almdal
Signed-off-by: Bharat Mediratta <bharat@menalto.com>
2009-08-05Chain some jQuery calls together to reduce lines of code.Bharat Mediratta
2009-08-05Revert "Allow a theme to override the page refresh mechanism. Create a new"Tim Almdal
This reverts commit 1f014aae6c16bbda62d8f5937180f11ccb0eb1b1.
2009-08-05Merge branch 'master' of git@github.com:gallery/gallery3Tim Almdal
2009-08-04Skip empty files, since we know they're broken. Fixes ticket #610.Bharat Mediratta
2009-07-28Merge branch 'master' of git@github.com:gallery/gallery3Tim Almdal
2009-07-28Use events to generate menus, instead of having xxx_menu helpers.Bharat Mediratta
This is the first step towards having a simple, lightweight and unified API for module interaction.
2009-07-27Allow a theme to override the page refresh mechanism. Create a newTim Almdal
javascript lib (gallery.reload.js) which defines the functions gallery_reload() and gallery_location(new_location). They just do a window.location.reload() and window.location = new_location. This change breaks the assumption that all themes will handle page reloads the same and allows the theme to customize the page refresh.
2009-07-23Don't escape & in JS text; it triggers the "Disallowed key charactersBharat Mediratta
in global data." check in the Input library.
2009-07-22Use the Kohana cascading filesystem to locate resources loaded by theBharat Mediratta
theme. Because the theme comes first, this means that themes can override any module resources, at the cost that we no longer have namespacing for JS and CSS files. The only file getting used outside of this model is themes/default/screen.css which is used in the admin theme. I fixed that by copying screen.css into admin_default and renaming its screen.css to admin_screen.css. I also copied over all the images that it was referencing. Fixes tickets #48 and #539. Theme API changes: - theme_script(), theme_url() and theme_css() are no longer needed - script(), url() and css() now refer to the first matching asset in the module load path, where gallery3/lib is at the end of the path
2009-07-21Escape bare & symbols so that we use valid entities. Fixes ticket #577.Bharat Mediratta
2009-07-21Fix some consistency in text.Shai Ben-Naphtali
This fixes ticket #546 Signed-off-by: Bharat Mediratta <bharat@menalto.com>
2009-07-19Fix l10n message inconsistency, ticket 546Andy Staudacher
2009-07-14Don't use "else" clauses in upgrade() -- it prevents multiple version bumps ↵Bharat Mediratta
at once.
2009-07-13Add quotes around all values that contain spaces in them, and add aBharat Mediratta
test to make sure that we continue to do so. This makes sure that we don't have problems with 5.3 which treats the literal "on" as a boolean.
2009-07-11Get rid of the form from server_add, we're not using it.Bharat Mediratta
Turn the cancel link into a themed close button which triggers a page reload. Add some padding to the left of the tree.
2009-07-11Add a "close" button.Bharat Mediratta
2009-07-11Forgot to bump the version up to 3Bharat Mediratta
2009-07-11Further simplify server_add (and bump it to version 3).Bharat Mediratta
Now we don't have checkboxes, but instead we restrict you to selecting directories and albums from only one level in the hierarchy. This makes it easier for us to make sure that we properly create the hierarchy that you want and avoid confusion about what's going to wind up where. Modify Server_Add_File_Model to have a parent_id and item_id and then modify them as we go so that we can build up a tree structure there *before* we create any items. This makes it much easier to figure out where a new item is going to go and get rid of a bunch of probably buggy code in the main task.
2009-07-10Remove debug code.Bharat Mediratta
2009-07-10Fix a bug where we were not properly locating the parent album whenBharat Mediratta
adding a new album or photo. Simplify the data structure that we pass down to server_add_tree.html.php so that we just pass a file list and let it do whatever it wants with it.
2009-07-09Avoid blowing the task data column by only adding directories to the queue ↵Bharat Mediratta
instead of directories and files.
2009-07-09Add status output to make it clearer what's happening when you add files.Bharat Mediratta
2009-07-09Use p::purify instead of p::cleanBharat Mediratta
2009-07-07Rework server_add. It's smaller and leaner now, storing the list ofBharat Mediratta
files out in a separate model for scalability. Removed the "pause" functionality. - Server_Add_Controller extends Admin_Controller so that we don't have to check for admin every time. - Task completion time now factors in the time it takes to walk the arbitrarily deep trees - Moved checkbox management entirely into JS using jQuery - Simplified the JS considerably
2009-07-02Merge branch 'master' of git@github.com:/gallery/gallery3Bharat Mediratta
Conflicts: modules/server_add/controllers/admin_server_add.php
2009-07-02Temporary version add() that just dumps out the values for now.Bharat Mediratta
2009-07-02@todo if we uncheck all the children for a parent, we should uncheck theBharat Mediratta
parent itself, otherwise in the code we'll add the entire parent since if we find an album as a leaf, we assume that it's never been expanded in the UI.
2009-07-02Properly manage disabled state for the [add] button.Bharat Mediratta
2009-07-02Only enable the [add] button when boxes are checked.Bharat Mediratta
2009-07-02Add some jsDoc.Bharat Mediratta
2009-07-02Partial pass of server_add cleanup. It's broken at this stage sinceBharat Mediratta
I've redone the browsing code but I have not implemented the adding code. 1) Rename index() to browse() since index is too generic. 2) Simplify the data that we pass to _dialog and _tree 3) Change _tree to return list items only, so that the outer dialog can be a <ul> for consistency. 4) Simplify the data structures so that we're not tracking checked vs. unchecked status in the PHP code, it's all done in jquery where we can do it with just a line or two of JS 5) use glob() which pretty much entirely replaces _get_children
2009-07-02Eliminate temporary variables by passing the $item into the view andBharat Mediratta
making API calls on the item.
2009-07-02Remove empty <script> block.Bharat Mediratta
2009-07-02In remove_path(), if the path is invalid don't echo it back in the UI.Bharat Mediratta
2009-07-01Fix a bunch of XSS vulnerabilities turned up by manual inspectionBharat Mediratta
using the checklist in ticket #385.
2009-06-29Temporary checkin to allow merge with trunk... don't integrateTim Almdal
2009-06-28Use $theme->script() method to render module javascript filesTim Almdal
2009-06-23Merge branch 'master' of git@github.com:gallery/gallery3Chad Kieffer
2009-06-23Use gMessage for "no paths defined" status message.Chad Kieffer
2009-06-23Refactor the install/upgrade code to be more flexible.Bharat Mediratta
Add xxx_installer::upgrade($version) method so that upgrade stanzas are separate from install stanzas. In the old code, to do an upgrade meant that you had to re-evolve everything from the initial install because we'd step through each version's changes. But what we really want is for the initial install to start off in the perfect initial state, and the upgrades to do the work behind the scenes. So now the install() function gets things set up properly the first time, and the upgrade() function does any work to catch you up to the latest code. See gallery_installer.php for a good example.
2009-06-12Convert the filename to a sensible title to match the way that the simple ↵Bharat Mediratta
uploader works.
2009-06-10Changed how directories are processed when the parent directory is selected andTim Almdal
the branch was never opened on the client. This should fix some of the issues with the server_add as I was able to select the staging directory and then add over 400 images in a multi-tier structure. Signed-off-by: Tim Almdal <tnalmdal@shaw.ca>
2009-06-04Only request the server_add js if the user is an adminBharat Mediratta
2009-06-05Rewrite the server_add to have the server format the selection when a branch ↵Tim Almdal
is opened. Sub trees re only retrieved when the branch is opened. Changed the start task processing to fill in any subtrees that are selected, but were never expanded on the client. Added the loading icon. Signed-off-by: Bharat Mediratta <bharat@menalto.com>
2009-06-03Guard against pages with no items.Bharat Mediratta
2009-06-03Minor tweaks to the way that we turn the add photos item into a menuBharat Mediratta
to make it a little more robust.
2009-06-02made "Add photos" its own site menu itemjhilden
* open for suggestions on the submenu item labels * @bharat: not sure about the add photos menu item id in the dropdown case
2009-06-02Have server_add turn the "Add Photo" menu option into a dropdown andBharat Mediratta
make "Add from Server" a 2nd option there. This requires adding the Menu::remove() API function.