2sxc 10.27 has some amazing new features you'll love. Toolbar enhancements, new DataSources and more.
Major Features
New Custom Toolbar APIs
Creating custom toolbars used to be very difficult, but now all we need is some simple URL-style parameters. Most customizations like adding a delete-button are now much easier thanks to a new toolbar API #2010 - see specs and how-to. Here's how you would extend the default toolbar with an added delete button:
<div @Edit.TagToolbar(Content, toolbar: toolbar: "%delete&show=true")>
...
</div>
That's it :). Here's a live demo in the DNN Tutorials.
Easier Coding for Sub-Entities
Entity can have properties pointing to other entities - like a blog-post pointing to tag-entities. This was always treated as a list of entities. For lists this was fine, but if we only expected one item (like an author) and needed the name of that, we were forced to check if the list was empty and do some coding to access the name. This wasn't sexy 😟. So in 10.27 we are now making things much, much easier 💪. Now you can write things like
@Content.Author.Name
How cool is that!
The item is still enumerable (IEnumerable<dynamic>), so you can still do things like
foreach(var tag in Content.Tags) { ... }
See also issue #1993, the underlying type in the docs and check out the updated dnn-tutorials.
Important: this change may break some existing code - though it probably won't. The object still supports IEnumerable<dynamic> and IList<dynamic>, but in case you had code that cast it to List<dynamic> that will have to be corrected.
JavaScript Insights
We completely refactored the in-page JavaScript we wanted to improve debugging on the client side. So $2sxc now has an insights()
method to debug what's happening in the JS #2013 - see also the docs for $2sxc.insights.
New DataSource AttributeRename
Sometimes you will have Entities with strange attribute names - for example when loading data from a CSV. In such cases, it's important to rename the attributes for proper use in code. Introducing the new AttributeRename - see docs.
Inner Content can Restrict what Apps are Added
While creating a new landing-page App we needed to use inner content so that editors can add Mobius Forms in certain places. But that meant that the users might also add other apps, which were never optimized to work in that scenario - leading to unhappy users. So inner-content can now restrict what apps are allowed in a Content-Area. See #2007.
Enhancements
- QueryRun DataSource now shows statistics on all streams #1989
- App DataSource now shows statistics on all streams #1990
- App DataSource now optimizes internal preparations (faster) #1991
- Quick-Dialog (the one appearing below) is now using Angular9 and Ivy
- Help-links on DataSources in VisualQuery now point to the new docs.2sxc.org #1994
- The entire in-page javascript responsible for the toolbars etc. was refactored and cleaned up (ca. 2 weeks of work)
- Server-side list-management standardized, to prepare for a future feature #1995
- Internal LookUpEngine got a performance boost #1998
- Enhanced DNN Serach Indexer Logging for Insights #1997
Important Bugfixes
- DataSource Cache-All-Streams didn't respect all parameters #1988
- Entities which were stored as JSON in SQL were missing the Modified and Owner porperty #2005 #2006
- the JS API $2sxc sometimes resolved the wrong path for certain WebAPI calles #2000
- Minor: added contentType param to edit-ui URLs fo the new admin UI we're building #2014
- DNN-Search Index didn't correctly provide all the tokens - so some queries returned different results to search #1999
Enjoy
Git it now on the GitHub releases.
With love from Switzerland,
Daniel