add new Setup, add new SQL Designer

This commit is contained in:
Jonathan Jenne
2020-02-06 16:33:50 +01:00
parent c8e23e3ca0
commit f0ccea072f
12 changed files with 1909 additions and 4 deletions

View File

@@ -540,8 +540,35 @@ Public Class frmAdministration
Private Sub btnSQLView_Click(sender As Object, e As EventArgs) Handles btnSQLView.Click
Save_IndexMan()
CURRENT_INDEXMAN = GUIDTextBox1.Text
frmSQLSuggestion.ShowDialog()
'CURRENT_INDEXMAN = GUIDTextBox1.Text
'frmSQLSuggestion.ShowDialog()
Dim oIndexGuid As Integer = GUIDTextBox1.Text
Dim oDocTypeGuid As Integer = DOKART_GUIDTextBox.Text
Dim oSQLCommand = ""
Try
Dim oSQL = $"SELECT SQL_RESULT, CONNECTION_ID FROM TBDD_INDEX_MAN WHERE GUID = {oIndexGuid}"
Dim oDatatable As DataTable = ClassDatabase.Return_Datatable(oSQL)
Dim oRow = oDatatable.Rows.Item(0)
Dim oForm As New frmSQL_DESIGNER(oIndexGuid, oDocTypeGuid) With {
.SQLCommand = oRow.Item("SQL_RESULT"),
.ConnectionID = oRow.Item("CONNECTION_ID")
}
If oForm.ShowDialog() = DialogResult.OK Then
oSQLCommand = oForm.SQLCommand.Replace("'", "''")
Dim oConnectionId = oForm.SQLConnectionId
oSQL = $"UPDATE TBDD_INDEX_MAN SET CONNECTION_ID = {oConnectionId},SQL_RESULT = '{oSQLCommand}',CHANGED_WHO = '{Environment.UserName}' WHERE GUID = {oIndexGuid}"
ClassDatabase.Execute_non_Query(oSQL, True)
End If
Catch ex As Exception
LOGGER.Error(ex)
End Try
End Sub
Private Sub WINDREAM_DIRECTCheckBox_CheckedChanged(sender As Object, e As EventArgs) Handles WINDREAM_DIRECTCheckBox.CheckedChanged