Compare commits
5 Commits
181199039e
...
c6748055fd
Author | SHA1 | Date | |
---|---|---|---|
c6748055fd | |||
e6746f76b1 | |||
e9f389b885 | |||
919ab3356d | |||
39060f6a1e |
@@ -287,17 +287,17 @@ namespace Elwig.Windows {
|
||||
if (MemberInput.SelectedItem is not Member m) return;
|
||||
Mouse.OverrideCursor = Cursors.Wait;
|
||||
try {
|
||||
var modAbs = decimal.TryParse(CustomModAbsInput.Text, out var n1) ? (decimal?)n1 : null;
|
||||
var modRel = decimal.TryParse(CustomModRelInput.Text, out var n2) ? (decimal?)n2 / 100 : null;
|
||||
var amount = decimal.TryParse(CustomAmountInput.Text, out var n3) ? (decimal?)n3 : null;
|
||||
var modText = CustomModCommentInput.Text.Trim();
|
||||
var text = CustomCommentInput.Text.Trim();
|
||||
await Task.Run(async () => {
|
||||
using var ctx = new AppDbContext();
|
||||
if (CustomPayments?.TryGetValue(m.MgNr, out var p) == true) {
|
||||
ctx.Remove(p);
|
||||
}
|
||||
if (sender == SaveCustomButton) {
|
||||
var modAbs = decimal.TryParse(CustomModAbsInput.Text, out var n1) ? (decimal?)n1 : null;
|
||||
var modRel = decimal.TryParse(CustomModRelInput.Text, out var n2) ? (decimal?)n2 / 100 : null;
|
||||
var amount = decimal.TryParse(CustomAmountInput.Text, out var n3) ? (decimal?)n3 : null;
|
||||
var modText = CustomModCommentInput.Text.Trim();
|
||||
var text = CustomCommentInput.Text.Trim();
|
||||
ctx.Add(new PaymentCustom {
|
||||
MgNr = m.MgNr,
|
||||
Year = Year,
|
||||
|
Reference in New Issue
Block a user