Skip to content
Code-Schnipsel Gruppen Projekte
Commit 06a34ad6 erstellt von Henning Leutz's avatar Henning Leutz :martial_arts_uniform:
Dateien durchsuchen

fix: load user data for editing Invoice and TemporaryInvoice panels

- Loaded user lock information to enhance usability in Invoice and TemporaryInvoice panels.
- Ensured more meaningful user data for lock notification messages.
- Renamed functions and aligned code for better readability.
- Refined dependency loading in unlock panel function to increase stability.
- Added 'Users' dependency for user information retrieval.

Related: pcsg/buero#488
Übergeordneter 996a1676
No related branches found
No related tags found
2 Merge Requests!90fix: load user data for editing Invoice and TemporaryInvoice panels,!80Update 'next-3.x' with latest changes from 'main'
Pipeline #14414 bestanden mit Phase
in 2 Minuten und 31 Sekunden
Dieser Diff ist reduziert.
......@@ -1706,34 +1706,39 @@ define('package/quiqqer/invoice/bin/backend/controls/panels/TemporaryInvoice', [
btnText = QUILocale.get(lg, 'button.unlock.invoice.is.locked');
}
new QUIConfirm({
title: QUILocale.get(lg, 'window.unlock.invoice.title'),
icon: 'fa fa-warning',
texticon: 'fa fa-warning',
text: QUILocale.get(lg, 'window.unlock.invoice.text', this.$locked),
information: QUILocale.get(lg, 'message.invoice.is.locked', this.$locked),
autoclose: false,
maxHeight: 400,
maxWidth: 600,
ok_button: {
text: btnText
},
this.Loader.show();
events: {
onSubmit: function(Win) {
if (!window.USER.isSU) {
Win.close();
return;
}
Users.get(this.$locked).loadIfNotLoaded().then((user) => {
new QUIConfirm({
title: QUILocale.get(lg, 'window.unlock.invoice.title'),
icon: 'fa fa-warning',
texticon: 'fa fa-warning',
text: QUILocale.get(lg, 'window.unlock.invoice.text', user.getAttributes()),
information: QUILocale.get(lg, 'message.invoice.is.locked', user.getAttributes()),
autoclose: false,
maxHeight: 400,
maxWidth: 600,
ok_button: {
text: btnText
},
events: {
onSubmit: function(Win) {
if (!window.USER.isSU) {
Win.close();
return;
}
Win.Loader.show();
Win.Loader.show();
self.unlockPanel().then(function() {
Win.close();
});
self.unlockPanel().then(function() {
Win.close();
});
}
}
}
}).open();
}).open();
this.Loader.hide();
});
},
/**
......
0% oder .
You are about to add 0 people to the discussion. Proceed with caution.
Bearbeitung dieser Nachricht zuerst beenden!
Bitte registrieren oder zum Kommentieren