Refactor Receiver to ReceiverVM in EnvelopeEditor and Main
Updated the `oReceiver` variable type from `Receiver` to `ReceiverVM` in the `frmEnvelopeEditor` and `frmMain` classes to align with a view model pattern. Modified the `Controller.DeleteReceiver` method to use `oReceiver.Receiver`, reflecting the new structure. Additionally, created `BindingList` of `ReceiverVM` to support a more MVVM architecture.
This commit is contained in:
@@ -366,7 +366,7 @@ Partial Public Class frmEnvelopeEditor
|
||||
Exit Sub
|
||||
End If
|
||||
|
||||
Dim oReceiver As Receiver = ViewReceivers.GetFocusedRow()
|
||||
Dim oReceiver As ReceiverVM = ViewReceivers.GetFocusedRow()
|
||||
|
||||
If oReceiver Is Nothing Then
|
||||
Exit Sub
|
||||
@@ -381,7 +381,7 @@ Partial Public Class frmEnvelopeEditor
|
||||
Exit Sub
|
||||
End If
|
||||
|
||||
If Controller.DeleteReceiver(oReceiver) Then
|
||||
If Controller.DeleteReceiver(oReceiver.Receiver) Then
|
||||
Receivers.Remove(oReceiver)
|
||||
Else
|
||||
MsgBox(Resources.Envelope.Recipient_could_not_be_deleted, MsgBoxStyle.Critical, Text)
|
||||
|
||||
Reference in New Issue
Block a user