AdminWebModule web resources
AdminWebModule javascript
AdminWebModule registers some Javascript and exposes an AdminWebModule
and AcrossWebModule
global variable.
These can be used to configure some of the default client-side behaviour settings.
The necessary web resources are registered automatically by the AdminWebLayoutTemplate
.
If you have a custom template implementation, you probably want to register the AdminWebWebResources
manually.
Client-side paths
A couple of web application paths are exposed as global javascript variables:
Variable | Content |
---|---|
|
Holds the base path for exposed web resources.
Equivalent of |
|
Holds the base path for the default static resources.
Equivalent of |
|
Holds the base path onto which AdminWeb UI has been mapped.
Equivalent of |
The last slash (/) token will always be stripped from the exposed paths.
Example creating a custom path: AdminWebModule.rootPath + '/my-controller' .
|
Toastr notifications
By default AdminWebModule will convert all Bootstrap dismissible alerts into Toastr notifications.
If you do not want to use Toastr at all, simply removing the javascript should be sufficient.
If you only want to disable dismissible alert conversion, you can do so by updating the AdminWebModule
javascript property:
<script type="text/javascript">
// Disable Toastr notifications - ensure this block is executed after initial admin-web-module.js
AdminWebModule.useToastrNotifications = false;
</script>