New in Softadmin® 7.34.0

New UX Features

Radio Cards

The new control, Radio Cards, functions like Radio Buttons but with much larger options. Cards can have a label, an additional description, and optionally a system icon or SVG icon.

Picture of radio cards, displaying three options, each with a title and body

The Radio Cards control is not intended to replace every instance of radio buttons but is useful for drawing special attention to and providing extra explanation for the most important choices in a menu item.

Bar and Line Charts in InfoSQL

The pie charts that were released in the previous version have now been joined by line charts and vertical bar charts. Horizontal bar charts will come in a future version.

As before, you use the Chart column in InfoSQL

Line Chart

linechart.png

SELECT
(
	SELECT
		'Ice Cream Sales Daily' AS [heading],
		'xy' AS [type],
		'date' AS [xAxis.scale],
		'linear' AS [yAxis.scale],
		'SEK' AS [yAxis.label],
		(
			SELECT
				F.IceCreamFlavor AS [label],
				(
					SELECT
						S.SalesDate AS xValue,
						S.SalesAmount AS yValue
					FROM
						Example.IceCreamSales S
					WHERE
						S.IceCreamFlavorId = F.IceCreamFlavorId AND
						S.SalesDate BETWEEN @FromDate AND @ToDate
					FOR JSON PATH
				) AS [values]
			FROM
				Example.IceCreamFlavor F
			FOR JSON PATH
		) AS [lines.series]
	FOR JSON PATH, WITHOUT_ARRAY_WRAPPER
) AS Chart

Bar Chart

barchart.png

SELECT
	DI.IntervalId,
	DI.DescriptionShort,
	DI.IntervalStart,
	DI.IntervalStop
INTO
	#XAxis
FROM
	SoftadminUtil.DatePeriod_Intervals('week', @FromDate, @ToDate, NULL) DI

SELECT
(
	SELECT
		'Ice Cream Sales Weekly' AS [heading],
		'xy' AS [type],
		'ordinal' AS [xAxis.scale],
		(
			SELECT
				X.IntervalId AS value,
				X.DescriptionShort AS label
			FROM
				#XAxis X
			FOR JSON PATH
		) AS [xAxis.values],
		'linear' AS [yAxis.scale],
		'SEK' AS [yAxis.label],
		(
			SELECT
				F.IceCreamFlavor AS [label],
				(
					SELECT
						X.IntervalId AS xValue,
						SUM(S.SalesAmount) AS yValue
					FROM
						#XAxis X
						LEFT JOIN Example.IceCreamSales S
							ON S.SalesDate BETWEEN X.IntervalStart AND X.IntervalStop
					WHERE
						S.IceCreamFlavorId = F.IceCreamFlavorId
					GROUP BY
						X.IntervalId
					FOR JSON PATH
				) AS [values]
			FROM
				Example.IceCreamFlavor F
			FOR JSON PATH
		) AS [bars.series]
	FOR JSON PATH, WITHOUT_ARRAY_WRAPPER
) AS Chart

Custom Dialogs with Custom Buttons

You can use the new Dialog concept to declare custom dialogs, optionally with custom buttons. Custom buttons can have custom text, send a custom string to the procedure, or both.

dialog.png

edit_dialog.png

IF @ButtonAction IS NULL
BEGIN
	SELECT 'Sales.AssignedLeadsHandled' AS ADMIN_Dialog;
END
ELSE IF @ButtonAction = 'Claim1'
BEGIN
	-- Handle
END
ELSE IF @ButtonAction = 'Claim3'
BEGIN
	-- Handle
END

See also: Standard API Dialogs

Columns in Textbox with Autosearch

The Textbox with Autosearch control was always intended to replace the Textbox with Popup control. However, Textbox with Popup had support for formatting its options using multiple columns.

In this version, Textbox with Autosearch has also received support for columns, using the same column name as Textbox with Popup, that is, ListColumn_<xxx>.

autosearch_with_columns.png

You can now configure a node link to be triggered by double-clicking the node. For example, in the System overview menu item, double-clicking a schema node will trigger the View schema link.

Label Connections in Node Graph

You can now optionally add label text to the connections between nodes in the node graph.

nodegraph_label.png

Improvements to Accessibility

Various improvements have been made to increase the accessibility of Softadmin. Most have been omitted from this document, but the major ones are listed below.

Tooltips Open on Keyboard Navigation

When the user navigates the interface using the keyboard, for example by using the tab key to jump between links, an element's tooltip will open when it receives focus.

Configure Autocomplete for Textboxes

You can now configure the autocomplete attribute for textbox controls. It's worth noting that browser support for this attribute is limited, and its primary utility lies in passing accessibility evaluations.

Add Text Description in to Images the HTML Editor

Users can now add a textual description (or "alt text") to images they add in the HTML control.

Maintenance Warnings

Maintenance Warnings are used to warn users before performing a deploy or restarting a server during work hours.

This feature is still under development. Future versions will gain the ability to prevent users from signing in using SSO while maintenance is under way, and the ability to forcibly log out all active users once maintenance starts.

How They Are Used

You start by logging in to the target system and registering a date and time when the maintenance will start, how many minutes in advance users should be warned, and how many minutes the maintenance is expected to take.

Before the maintenance starts, users will be shown a banner warning them how many minutes there are left. The banner is shown above all menu items, and on the login page.

Maintenance banner saying there are x minutes left before maintenance.

Once maintenance has started (unless you chose 0 minutes as maintenance time) the banner instead warns that a maintenance is underway. Meanwhile, new users will be prevented from logging into the system as the username and password fields are hidden on the login page.

Should the maintenance time run out before you have marked the maintenance as finished, users will be informed that maintenance is taking longer than expected.

Server Sent Events

When Server Sent Events are enabled for the system, users will see the warning banners immediately. When Server Sent Events are not enabled, users will see not maintenance warnings until they open a new menu item.

However, SSE support is immature, and for now it is recommended that you do not enable it for systems with many concurrent users due to the strain it can put on the server.

Developer features

Standard API dialogs

While you can build your own dialogs, a few standard dialogs also ship with Softadmin.

  • SoftadminApi.Success
  • SoftadminApi.Info
  • SoftadminApi.Error
  • SoftadminApi.ConfirmDelete
  • SoftadminApi.ConfirmQuestion
  • SoftadminApi.ConfirmWarning

Example: Confirm Question

Specify your own title and message.

SELECT
    'SoftadminApi.ConfirmQuestion' AS ADMIN_Dialog,
    'Are you that hungry?' AS Title,
    'Do you really want to order 128 pizzas?' AS Message;

confirmquestion.png

Example: Confirm Delete

Has a fixed question and title (with translations) but allows you to describe what is about to be deleted and give additional information.

SELECT
    'SoftadminApi.ConfirmDelete' AS ADMIN_Dialog,
    'the event Bakery.BreadIsReady' AS Item,
    'It has 12 listeners.' AS ExtraMessage;

confirmdelete.png

ImageProcess: maxSize command

The size command in the Image Process component will shrink images that are too large, but also grow images that are too small. The new maxSize command only shrinks images to fit in the specified rectangle and simply returns images that are too small as is.

PKCE Support in OpenID SSO

OpenID Single Sign-on has gained support for Proof Key of Code Exchange (PKCE). Although the original SSO implementation was secure enough to not require PKCE, this should enable integration with servers that demand it is enabled.