Customization & Branding

Many of the core SanteDB applets allow for easy customization of their default look and feel, routes, etc. This customization is done by giving your assets a higher priority than the built in assets in SanteDB.

Overriding Default UI Text

You can override any textual elements in SanteDB by setting the priority on the string you'd like to override. For example, if you'd like to change the title of the default landing page you can use:
<strings lang="en">
<string key="ui.title" priority="1">My Custom SanteDB App</string>
When using a strings.xml file (as with Mozilla Pontoon) it is not possible to override the priority of the translation.

Overriding UI Elements

You can override certain portions of the default user interface by setting a priority on your state with the same route name. For example, if you want to provide a custom login screen you merely need to override the login route
<div xmlns="" xmlns:sdb=""
ng-init="login = { grant_type: 'password', forbidPin: true, welcomeMessage: undefined, noSession: false }">
<sdb:style static="false">/org.santedb.admin/css/admin.css</sdb:style>
<sdb:style static="false">/org.santedb.admin/css/sb-admin.css</sdb:style>
<sdb:state name="login" priority="1">
Quick and Dirty Login Screen:
<form class="form" ng-submit="doLogin(loginForm)" name="loginForm">
<!-- #include virtual="/org.santedb.uicore/partials/security/login.html" -->
<button type="submit" id="loginButton" class="btn btn-lg btn-primary">
<i class="fa fa-check"></i> {{ 'ui.action.login' | i18n }}
Now, whenever an asset wishes to prompt the user to login, your custom login page will be displayed in place of the original.
Last modified 1yr ago