mirror of
https://github.com/inventree/InvenTree.git
synced 2025-07-11 07:24:15 +00:00
More refactoring for notifications
- Adds default behaviour for successful stock item creation
This commit is contained in:
@ -904,19 +904,19 @@ function handleFormSuccess(response, options) {
|
||||
|
||||
// Display any messages
|
||||
if (response && response.success) {
|
||||
showAlertOrCache(response.success, 'success', cache);
|
||||
showAlertOrCache(response.success, cache, {style: 'success'});
|
||||
}
|
||||
|
||||
if (response && response.info) {
|
||||
showAlertOrCache(response.info, 'info', cache);
|
||||
showAlertOrCache(response.info, cache, {style: 'info'});
|
||||
}
|
||||
|
||||
if (response && response.warning) {
|
||||
showAlertOrCache(response.warning, 'warning', cache);
|
||||
showAlertOrCache(response.warning, cache, {style: 'warning'});
|
||||
}
|
||||
|
||||
if (response && response.danger) {
|
||||
showAlertOrCache(response.danger, 'dagner', cache);
|
||||
showAlertOrCache(response.danger, cache, {style: 'danger'});
|
||||
}
|
||||
|
||||
if (options.onSuccess) {
|
||||
|
Reference in New Issue
Block a user