Commit graph

16909 commits

Author SHA1 Message Date
Scott Walters
176b6297dd deal with Package::Stash changing its API 2014-01-07 17:08:06 -06:00
Scott Walters
0bfb836ec9 New Content in Tree view needed to use showView() instead of gotoAsset(). 2013-09-27 12:32:46 -05:00
Scott Walters
fd2d82835a Revert "AdminToggle Macro is blank when in admin mode"
apparently, $session->isAdminOn is meaningless in wG8.  this is a poor situation that it exists but is busted.  have to do this same thing another way.
This reverts commit 1e22418757.
2013-09-27 12:32:46 -05:00
Colin Kuskie
30e8a28012 options subroutines have to return something optionable. 2013-09-27 08:33:09 -07:00
david delikat
cc7c041242 added label and hover help attributes to parser property so it will be editable in forms 2013-09-27 09:21:03 -05:00
Scott Walters
a72f61dffb WebGUI::Asset->getHelpers entries specifiying a url field were breaking the Tree view when selected from the drop down.
WebGUI.Admin.prototype.getHelperHandler was using gotoAsset(), which calls tree.goto(), which mangles the URL into being a request for
the data needed to draw the Tree view of that asset, or tries to.  that works fine when navigating to an asset, but foo?func=edit is
not an asset, and the mangled URL is garbled.  all of the urls (okay, the one attached to the 'edit' and 'view' entries) aren't
trying to direct the admin to an asset but instead are trying to direct it to an admin screen, which, again, cannot be shown in the
data table in Tree view.  so edit and view were fixed by changing that to instead do a showView(), which flops over to the View mode
and then loads the URL without trying to mangle it.
at this point, nothing is blowing up in Doug's JS admin when testing the asset helper menu items in View or Tree mode, though
there are still some problems.
2013-09-27 00:44:59 -05:00
Scott Walters
d32d452efe change WebGUI.Admin.prototype.processPlugin, which handles messages back from calls to AssetHelper classes, to do any number of little chores according to the message contents rather than just the first one it tests for.
change the Lock AssetHelper to both refresh and display a message indicating that the asset is locked.  the refresh is needed for tree view which displays a little icon.
2013-09-26 21:23:05 -05:00
Scott Walters
d8ccdecff5 Save button in Export as HTML has bad style (#12424):
Heh.  Actually, the save button is a YUI styled button, and it is perfectly rendered.  It also happens to have a background color exactly matching the dialog's background's.  Since these buttons are usually unstyled HTML buttons, I swapped the YUI one out for that.
I also got distracted with the form rendering half way down the page and creeping down further as the hoverhelp tips come and go so I opened http://www.webgui.org/community/webgui-8/issues/12433 and then temporarily vanquished them in this form.
2013-09-26 20:03:12 -05:00
Scott Walters
b8923426e2 ucfirst the name as it comes back from i18n in our Form::Cancel control 2013-09-26 19:34:40 -05:00
Scott Walters
15e71bf39b Create Shortcut - Admin bar clipboard display (#12432): all menu operations/AssetHelper calls now trigger a clipboard refresh 2013-09-26 18:36:58 -05:00
Scott Walters
69ea5b10ee a few improvements to error reporting/handling 2013-09-26 18:01:41 -05:00
Scott Walters
da37116d71 fix up Operation::User (op=editUser) some more for the new admin: give it Save and Cancel buttons, and template it into the style with $session->style->process() so that it gets the headers that it needs for pulling in YUI and stuff like that as well as so that it is styled to look nice. 2013-09-26 17:32:32 -05:00
Scott Walters
0b5a77515f make Form::Cancel better; make WebGUI::TabForm use it. so, logic migrated from TabForm to Form::Cancel where it's re-usable and fixed up for this new Doug admin. 2013-09-26 17:32:32 -05:00
Scott Walters
7b7f3be628 Create a Form::Cancel; FormBuilder doesn't automatically add Save/Cancel buttons so this can serve as a Cancel button for it; it attempts to correctly handle either closing the modal pop-up dialog or else going back in history/going back to the page that linked to this one. needs tests. the Cancel button in TabSet needs to use this logic. 2013-09-26 17:32:32 -05:00
david delikat
1e22418757 AdminToggle Macro is blank when in admin mode
webgui 8 does not require a 'turn admin off' switch.
2013-09-25 19:23:40 -05:00
Scott Walters
7900cec5e8 finish the "Upload Files" implementation; the AssetHelper had some bugs and needed to close the pop-up dialog that it created. 2013-09-25 15:00:46 -05:00
Scott Walters
690d87a668 $session->asset is not defined if we're running from a Content Handler or the like. make reporting it conditional so that we don't get error output from our error output. 2013-09-25 15:00:46 -05:00
Scott Walters
fbb143116e don't reload the Tree/View pane after a Copy Branch operation; Copy Branch doesn't mutate the asset tree being viewed so not needed 2013-09-25 15:00:45 -05:00
Scott Walters
b3714e6560 refactor WebGUI.Admin.prototype.gotoAsset slightly to avoid code duplication
WebGUI.Admin.prototype.addPasteHandler: guessing but fix use of 'this' vs 'self'
currentTabName() to avoid code duplication for figuring out which context we're running in (Tree/View)
WebGUI.Admin.prototype.pasteAsset:  handle pasting in the Tree view by flopping over to the View view first
WebGUI.Admin.Tree.prototype.goto: better error handling/debugging
added this FIXME to WebGUI.Admin.prototype.gotoAsset:
a lot of Tree view operations fail after this point.  where the View version just directly goes to the URL, the Tree view tries to modify the URL to pass the extjs-st
2013-09-25 15:00:45 -05:00
Scott Walters
22cf93600f Revert "refactor WebGUI.Admin.prototype.gotoAsset slightly to avoid code duplication"
... oops, dead code may not be dead afterall

This reverts commit aeb26ab0f7262b26c1d8225cff2555df0cd43f09.

Conflicts:
	www/extras/admin/admin.js
2013-09-25 15:00:45 -05:00
Scott Walters
b962b03848 Making the "Copy Branch" menu option work was a treat.
requestHelper() invokes an asset helper via AJAX.  processPlugin() handles the JSON responses, which in this case is to open a dialog box and show
a given URL in it (openDialog key in the JSON hash).  that pop-up is open and the page loaded, and that displays a form.  that form submits
to an asset helper (uh oh) which also returns JSON (actually, it was failing to do even that and was stringifying a hash).  even if it returned
JSON, it would just get shown to the user in the pop-up.  so the form that gets loaded into the pop-up has to, onsubmit, after it has config
details from the user, run JS to make the AJAX request to the asset helper to start the actual copy operation, call into the admin's JS to
pop up the dialog that polls on a forked process, and then call into the admin to close itself.  this is a nasty hack that daisy chains
together two possible replies to processPlugin(), one after the other.
2013-09-25 15:00:45 -05:00
Colin Kuskie
26ae70190f Remove extra call to old tree updating code. 2013-09-25 15:00:44 -05:00
Scott Walters
58911e3026 WebGUI.Admin.prototype.reload: fix a lot of Tree view operations by doing a this.tree.goto on location.pathname rather than href to drop incidental
query parameters.  the view frame grows query parameters when it shows various edit and admin screens.
add comments about safe/unsafe uses of goto with respect to Tree's URL mangling
made updating the status message in the Fork progress dialog optional so the 'undefined' message should be gone now.
2013-09-25 15:00:44 -05:00
Colin Kuskie
a503e72cfc Update CopyBranch for newest fork code. 2013-09-25 15:00:44 -05:00
Colin Kuskie
cf28121885 Fix label, remove debug. 2013-09-25 15:00:44 -05:00
Colin Kuskie
4b97ce9a55 Call the right sub to update the Fork status. 2013-09-25 15:00:44 -05:00
Colin Kuskie
11c9a80814 Need at least one call to the sub that updates the Fork status. 2013-09-25 15:00:43 -05:00
Colin Kuskie
7766c43821 Remove debug code from Delete and Copy 2013-09-25 15:00:43 -05:00
Colin Kuskie
0363101e43 update Delete AssetHelper for the new admin JS 2013-09-25 15:00:43 -05:00
Colin Kuskie
e6d26369ed Fix progress bar display for copy. 2013-09-25 15:00:43 -05:00
Scott Walters
3aaa72f12c don't let non-priviledged users turn on the admin; additional logic to kick them out of admin when they're no longer logged in would be nice too. 2013-09-24 12:28:51 -05:00
Scott Walters
1ac133d955 refactor WebGUI.Admin.prototype.gotoAsset slightly to avoid code duplication
WebGUI.Admin.prototype.addPasteHandler: guessing but fix use of 'this' vs 'self'
currentTabName() to avoid code duplication for figuring out which context we're running in (Tree/View)
WebGUI.Admin.prototype.pasteAsset:  handle pasting in the Tree view by flopping over to the View view first
removed WebGUI.Admin.Tree.prototype.runHelperForSelected and relatedly WebGUI.Admin.Tree.prototype.cut, copy, shortcut, duplicate, delete; these are dead code
WebGUI.Admin.Tree.prototype.goto: better error handling/debugging
added this FIXME to WebGUI.Admin.prototype.gotoAsset:
a lot of Tree view operations fail after this point.  where the View version just directly goes to the URL, the Tree view tries to modify the URL to pass the extjs-style grid's parameters back.  this winds up creating unworkable URLs that try to do two things at once, with two '?'s, two 'op='s, etc.  there are two ways to fix this:  if we're trying to go to an asset (gotoAsset) and we're in Tree view, flop back to View mode first; or else two distinct requests, one for the remote request (which might generate additional requests to draw in dialog boxes, progress bars, forms, etc) and then when that's all done, refresh the grid view.  WebGUI.Admin.prototype.pasteAsset takes the route of flopping to Tree view first.
2013-09-24 12:28:51 -05:00
Scott Walters
8be9ed7d59 the 'cut' drop down (AssetHelper) operation basically worked, but the screen wasn't redrawn after the change, and the JSON returned during Fork polling in WebGUI::AssetHelper::Cut didn't match what the YAHOO.WebGUI.Fork.poll callback in WebGUI.Admin.prototype.openForkDialog was expecting so status communication had to be wired up. wG::ProgressTree exposes 'flat' now too for the sake of computing a progress bar. looking at only the roots nodes is ineffective; in this case, the number of root nodes would only ever be 1 though the number of child nodes to be processed could be much higher. WebGUI.Admin.prototype.openForkDialog's callback to YAHOO.WebGUI.Fork.poll handles a status JSON message (JSON inside of JSON, ugh) of "reload" and there's an admin.reload() method now. that's also callable from WebGUI.Admin.prototype.processPlugin and was done in the style of its handlers. 2013-09-24 12:28:51 -05:00
Colin Kuskie
3061626753 Fix i18n label for tab in DataTable edit form 2013-09-16 09:43:29 -07:00
Colin Kuskie
651c7c8982 Save the Navigation fields that are drawn custom. 2013-09-13 15:11:12 -07:00
Colin Kuskie
e42ca6b870 Merge branch 'wg8-nav'. Fix rendering and JS issues with the nav asset. 2013-09-13 13:36:23 -07:00
Colin Kuskie
69e3b22daf Assign the content to the right place. 2013-09-13 13:36:06 -07:00
Colin Kuskie
6123dd276b fix many issues with the JS for the nav in wg8. still has initialization problems. 2013-09-13 12:42:19 -07:00
Colin Kuskie
950dd349db Fix the display of revision dates in the asset helper screen. 2013-09-13 12:20:34 -07:00
Scott Walters
5736fdf4d1 when flipping between Tree and View tabs with edit on, clear out the containers for the toolbars before re-adding the toolbars -- this time in YUI -- and this time doing the same for the drag and drop bar 2013-09-12 13:32:29 -05:00
Scott Walters
9d047a788d Revert "when flipping between Tree and View tabs with edit on, clear out the containers for the toolbars before re-adding the toolbars -- this time in YUI"
... committeed too much stuff. ack

This reverts commit c19c3503d4.
2013-09-12 13:02:01 -05:00
Scott Walters
c19c3503d4 when flipping between Tree and View tabs with edit on, clear out the containers for the toolbars before re-adding the toolbars -- this time in YUI 2013-09-12 12:03:41 -05:00
Scott Walters
6dbc6697c5 Revert "when flipping between Tree and View tabs with edit on, clear out the containers for the toolbars before re-adding the toolbars"
... jquery isn't reliably available; trying to do this with YUI instead

This reverts commit 1ef7460815.
2013-09-12 12:02:22 -05:00
Scott Walters
1ef7460815 when flipping between Tree and View tabs with edit on, clear out the containers for the toolbars before re-adding the toolbars 2013-09-12 10:03:22 -05:00
Colin Kuskie
85e09c41d6 Remove admin console off link since it's trapped by the admin console and does nothing. 2013-09-11 09:54:32 -07:00
Colin Kuskie
67e446aead Update to modern SQL syntax 2013-09-10 09:58:44 -07:00
Scott Walters
460e29b93d spectre.pl requires Devel::Size; wasn't tested for in testEnvironment.pl 2013-02-24 19:45:09 -05:00
Scott Walters
af18f5a7be add Imager::File::PNG to the list of deps since, according to one report, Imager considers it an optional dep and it may not be installed automatically with Imager 2013-02-17 15:13:45 -05:00
Scott Walters
0edd58f848 add a getProperty to WebGUI::Definition::Role::Object as Asset.pm's www_add wants this for picking out noFormPost data from the property definition in assets. fixes a fatal error when trying to add the Request Tracker and perhaps other assets. 2013-02-17 15:02:16 -05:00
Scott Walters
e27f200856 remove Moose::Deprecated deprecation for updateProfileFields and remove the last remaining use of it from the code; Moose::Deprecated is failing on 5.10, which is still the default for CentOS and probably will be for a few more epochs 2013-02-17 12:54:03 -05:00