32 lines
1.3 KiB
JavaScript
32 lines
1.3 KiB
JavaScript
// Minimal configuration_workflow. Its only job is to make saltcorn-idp show the
|
|
// standard "Configure" cog on the Settings -> Plugins list, consistent with
|
|
// other plugins (the cog renders iff the module exports configuration_workflow
|
|
// -- see server/routes/plugins.js cfg_link). saltcorn-idp is actually configured
|
|
// from its own admin dashboard under ADMIN_BASE_PATH (/admin/idp), so the single
|
|
// step just links there.
|
|
|
|
const Workflow = require("@saltcorn/data/models/workflow");
|
|
const Form = require("@saltcorn/data/models/form");
|
|
const { ADMIN_BASE_PATH } = require("./constants");
|
|
|
|
|
|
const configurationWorkflow = () =>
|
|
new Workflow({
|
|
steps: [
|
|
{
|
|
name: "saltcorn-idp",
|
|
form: async () =>
|
|
new Form({
|
|
blurb:
|
|
"saltcorn-idp is configured from its own admin dashboard " +
|
|
"(OIDC clients, groups, SAML SPs, LDAP, signing-key rotation).<br><br>" +
|
|
`<a class="btn btn-primary" role="button" href="${ADMIN_BASE_PATH}">` +
|
|
"Open the saltcorn-idp dashboard</a>",
|
|
fields: []
|
|
})
|
|
}
|
|
]
|
|
});
|
|
|
|
|
|
module.exports = { configurationWorkflow };
|