fix changed when for profiles
This commit is contained in:
@@ -22,10 +22,42 @@ Public Class frmAdministration
|
||||
InitializeComponent()
|
||||
End Sub
|
||||
|
||||
Public Class SQLPlaceholder
|
||||
Public Property Name
|
||||
Public Property Value
|
||||
|
||||
Public Sub New(Name As String, Value As String)
|
||||
Me.Name = Name
|
||||
Me.Value = Value
|
||||
End Sub
|
||||
|
||||
Public Overrides Function ToString() As String
|
||||
Return Name
|
||||
End Function
|
||||
End Class
|
||||
|
||||
Private Function GetPlaceholders() As List(Of SQLPlaceholder)
|
||||
Return New List(Of SQLPlaceholder) From {
|
||||
New SQLPlaceholder("Zwischenablage", "@Clipboard"),
|
||||
New SQLPlaceholder("Benutzer-Vorname", "{#USER#PRENAME}"),
|
||||
New SQLPlaceholder("Benutzer-Nachname", "{#USER#SURNAME}"),
|
||||
New SQLPlaceholder("Benutzer-Email", "{#USER#EMAIL}"),
|
||||
New SQLPlaceholder("Benutzer-Kurzname", "{#USER#SHORTNAME}"),
|
||||
New SQLPlaceholder("Benutzer-Id", "{#USER#USER_ID}"),
|
||||
New SQLPlaceholder("Benutzer-Name", "{#INT#USERNAME}"),
|
||||
New SQLPlaceholder("Computer-Name", "{#INT#MACHINE}"),
|
||||
New SQLPlaceholder("Computer-Domäne", "{#INT#DOMAIN}"),
|
||||
New SQLPlaceholder("Aktuelles Datum", "{#INT#DATE}")
|
||||
}
|
||||
End Function
|
||||
|
||||
Private Sub frmAdministration_Load(sender As Object, e As EventArgs) Handles MyBase.Load
|
||||
' Select first tab to prevent profile textbox from being empty
|
||||
XtraTabControl3.SelectedTabPageIndex = 0
|
||||
|
||||
ComboBoxEdit3.Properties.Items.AddRange(GetPlaceholders())
|
||||
ComboBoxEdit4.Properties.Items.AddRange(GetPlaceholders())
|
||||
|
||||
_DragDrop = New ClassDragDrop()
|
||||
_DragDrop.AddGridView(GridViewGroupInProfile)
|
||||
_DragDrop.AddGridView(GridViewGroupNotInProfile)
|
||||
@@ -324,8 +356,9 @@ Public Class frmAdministration
|
||||
|
||||
Private Sub BarButtonItem3_ItemClick(sender As Object, e As DevExpress.XtraBars.ItemClickEventArgs) Handles BarButtonItem3.ItemClick
|
||||
Save_Profile()
|
||||
|
||||
ClassInit.Refresh_Profile_Links()
|
||||
'TableAdapterManager.UpdateAll(MyDataset)
|
||||
Refresh_ProfileScreen()
|
||||
End Sub
|
||||
|
||||
Private Sub BarButtonItem2_ItemClick(sender As Object, e As DevExpress.XtraBars.ItemClickEventArgs) Handles BarButtonItem2.ItemClick
|
||||
@@ -765,4 +798,18 @@ Public Class frmAdministration
|
||||
MsgBox("Unexpected Error while adding Group-Rights: " & vbNewLine & ex.Message, MsgBoxStyle.Critical)
|
||||
End Try
|
||||
End Sub
|
||||
|
||||
Private Sub SimpleButton2_Click(sender As Object, e As EventArgs) Handles SimpleButton2.Click
|
||||
If ComboBoxEdit3.SelectedIndex > -1 Then
|
||||
Dim oItem As SQLPlaceholder = ComboBoxEdit3.SelectedItem
|
||||
MemoEdit5.Text &= oItem.Value
|
||||
End If
|
||||
End Sub
|
||||
|
||||
Private Sub SimpleButton3_Click(sender As Object, e As EventArgs) Handles SimpleButton3.Click
|
||||
If ComboBoxEdit4.SelectedIndex > -1 Then
|
||||
Dim oItem As SQLPlaceholder = ComboBoxEdit4.SelectedItem
|
||||
MemoEdit6.Text &= oItem.Value
|
||||
End If
|
||||
End Sub
|
||||
End Class
|
||||
Reference in New Issue
Block a user