Inspired by the new Container Document Type that is part of Umbraco 7, I created this package for v6.
It offers some similar things to the v7 implementation:
- Hide all child nodes under a certain document type in the umbraco content tree
- Provides a DataType that you can use on the above "Parent Document Type" to show a grid of nodes that are sortable, pageable and filterable
Take a look at a quick demo on how this package solves an issue on a typical Blog or News site that has 1000's of articles/entries, making it much simpler for the CMS admin to filter and sort rapidly:
Basic Install/Setup Instructions (these look complex but it's quite simple)
These instructions are also shown in the demo video above from step 2 onwards.
- Install the Package
- In the Developer section, create a new Data Type (not Document Type) and select the Property Editor as "rbcContainerDocumentType-DataType" - name your Property something like "News Listing"
- Hit Save to show the Settings
- For List DocType select the Document Type that you wish to hide all child nodes of in the content tree (e.g News)
- For Item DocType select the Document Type that you want displayed in the grid (likely a child of News - maybe News Item)
- For Aliases enter a comma delimited list of the Item DocType's properties you want in the grid - keep this list to <=4 entries for the best performance - you can also use built in umbraco properties of text and updateDate. So as an example you might enter "text, articleDate, updateDate" which will show the News Item's Text (built in umbraco property), Article Date (custom property on the Document Type) and Last Updated Date (built in umbraco property)
- For Titles enter a comma delimited list of what you want the Titles to be in the grid for each of the above Aliases - so for the above example you might have "Title, Article Date, Updated"
- Hit Save to save the values in the two dropdowns and two textboxes
- In the Settings section go to the Document Type you selected in step 4 above
- [Optional] Create a Tab called something like "News Items" or "News"
- Create a Property that uses the Data Type you created in steps 2-8 above ("News Listing") and the Tab you created in Step 10. You can give your property any Name and Alias as they are never used.
- Hit save to save your new property
- Important: Reopen/expand the same property and remove the Name value - this will make our grid "full width"
- Hit save to save your property
- Go to your content tree in the Content Section where you've already created a content node for the Document Type you selected in step 4 and check out your new grid in the tab you created in step 9-14.
- Note that the child nodes in the tree will still display until you restart umbraco so that the initialise events can run again - you can also toggle the hide/show of these child nodes via the right click menu
- When settings up the datatype the Aliases/Titles text boxes could be more dynamic and pull data from the db based on teh selected Item DocType, preventing incorrect values from being entered
- Any other suggestions?
Note 1: This is my first contribution to the Umbraco community - feedback is welcomed in the forums.
Note 2: This package does not contian any Document Types, only a Property Editor Data Type and supporting code - it was named "rbcContainerDocumentType" due to its similar feature set to the Container Document Type in v7 and rbc (Redback Consulting) is my company name :-).
Note 3: Tested on 6.0.2 and 6.1.6
- You can now have multiple (different) grids on the same document type
- Fixed empty date issue
- Package Files
- Archived Files