We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 34162
    • 1 Posts
    This is an auto-generated topic for <a href="http://modxcms.com/extras/package/255">ManagerManager 0.3.4-Release</a> by ncrossland.

    Brief Description:
    ManagerManager (MM) is a powerful plugin that allows you to change the names, visibility, and layout of document fields within the Manager, new editing widgets - and lots more!

    This version supports ModX 1.0.0. For older versions of ModX, please download version 0.3.2.
      • 16034
      • 107 Posts
      Hey, thanks for this great plugin!

      Just wanted to let you know that you forgot to remove the .svn-dirs from the release...
        MODx snippet-glossary 101:
        Ditto = Content Lister -- Wayfinder == Menu Builder -- Jot = Comment Control
        • 25663 MODX Staff
        • 12,272 Posts
        Hey Nick great work here. One small issue I’ve seen:

        When installed in a 1.0.0 release version and the remove deprecated types is enabled for TVs, they’re not in fact removed and there’s extra code output on the bottom of the frame. Same thing happens when saving the document on the update screen that flashes quickly:

        \n \n

        \n \n
        ’; var boxHtml = new MooPrompt(’System Alert’, sysAlert, { buttons: 1, button1: ’Ok’, width: 500 }); });

        Which comes from the sysalert.display.inc.php
          Ryan Thrash, MODX Co-Founder
          Follow me on Twitter at @rthrash or catch my occasional unofficial thoughts at thrash.me
          • 25663 MODX Staff
          • 12,272 Posts
          Actually, ignore that, though it does point out an area that might could be tweaked on error checking. With the default config I had the color picker turned on, but not installed. It was causing all sorts of interesting things to occur. Probably could use a bit more error checking or more likely the sysalert.php file needs to be updated. Anyway, working now. smiley

          However, it appears the tagging widget is a bit wonky with the demo content. When clicking the first or second tag, it works as expected. After clicking the third tag, it inserts two spaces that are never removed. The fourth click inserts four spaces, fifth click eight spaces and so on. I got this to work by altering the join(delimeter+’ ’) tidbit in the addTag function in tags.js, once again proving even a blind squirrel occasionally finds a nut.

          I don’t know how this impacts other delimiters, though, like comma separated lists. The demo content is space separated (which is silly, but that’s another discussion for another thread).

          Originally (non-working, lines 50-54, tags.js):
          					$j(theEntry).val( oldTags.join(delimiter+' ') );
          				} else { // Not in the list, so add it
          					oldTags.push(newTag);
          					$j(theEntry).val(  oldTags.join(delimiter+' ') );
          				}


          Works:
          					$j(theEntry).val( oldTags.join(delimiter) );
          				} else { // Not in the list, so add it
          					oldTags.push(newTag);
          					$j(theEntry).val( oldTags.join(delimiter) );
          				}


            Ryan Thrash, MODX Co-Founder
            Follow me on Twitter at @rthrash or catch my occasional unofficial thoughts at thrash.me
            • 25663 MODX Staff
            • 12,272 Posts
            Actually I think I fixed it to where it will work with comma separated and space separated values, though it doesn’t address odd cases where someone might set the delimeter to a double space or a comma-space. In those cases it will insert an extra space. (Maybe there shouldn’t be a spacer after the delimiter at all?) But I digress, the new function:
            			// Add the tag that has been clicked to the field
            			var addTag = function (e) {
            				var newTag = $j.trim($j(e.target).text());
            				var oldTags = getTags();
            
            				// Mark the document as dirty for Modx by triggering a "change" event
            				$j(theEntry).trigger("change");
            
            				// Is the tag already in the list? If so, remove it
            				var thePos = $j.inArray(newTag, oldTags);
            				var tagSpacer = (delimiter == ' ') ? '': ' ';
            				if (thePos != -1) {
            					oldTags.splice(thePos, 1);
            					$j(theEntry).val(oldTags.join(delimiter+tagSpacer));
            				} else { // Not in the list, so add it
            					oldTags.push(newTag);
            					$j(theEntry).val(oldTags.join(delimiter+tagSpacer));
            				}
            
            				addHilights();
            			};
            


            Question: would you expect manually entered (new) tags to get pushed down into the list as well? That’d be pretty neat I think.
              Ryan Thrash, MODX Co-Founder
              Follow me on Twitter at @rthrash or catch my occasional unofficial thoughts at thrash.me