This commit is contained in:
SchreiberM
2017-02-07 13:46:55 +01:00
parent e772d0cd57
commit acc6e2ebb3
9 changed files with 122 additions and 66 deletions

View File

@@ -8,6 +8,7 @@ Imports System.Threading
Imports System.Globalization
Imports System.Net
Imports System.Net.Sockets
Imports DD_LIB_Standards
Public Class frmMain
@@ -128,9 +129,10 @@ Public Class frmMain
End If
End Sub
Sub Proxy_Server_Controls()
If LICENSE_SITE_PROXY = True And ClassProxy.MyPROXYConnectionString <> "" Then
If LICENSE_SITE_PROXY = True And clsDatabase.DB_PROXY_INITIALIZED = True Then
itemRefreshProxy.Visibility = BarItemVisibility.Always
LabelProxyServer.Visibility = BarItemVisibility.Always
ClassLogger.Add(">> PROXY-SERVER is being used", False)
Else
itemRefreshProxy.Visibility = BarItemVisibility.Never
LabelProxyServer.Visibility = BarItemVisibility.Never
@@ -366,7 +368,6 @@ Public Class frmMain
End If
Dim sql = "SELECT COUNT(GUID) FROM TBPMO_USER_GLOBAL_SEARCH WHERE USER_ID = " & USER_GUID
Dim Count = ClassDatabase.Execute_Scalar(sql)
If Count = 0 Then
@@ -383,10 +384,13 @@ Public Class frmMain
End Sub
Private Sub ToolbarButtonItemClick(sender As Object, e As DevExpress.XtraBars.ItemClickEventArgs)
Dim formId As Integer = Integer.Parse(e.Item.Tag)
Cursor = Cursors.WaitCursor
OpenFormConstructor(formId)
If ClassProxy.IS_PROXY_BUSY = False Then
Dim formId As Integer = Integer.Parse(e.Item.Tag)
OpenFormConstructor(formId)
Else
MsgBox("Proxy-Server is actually synchronizing! Please wait until synchronisation is finished!" & vbNewLine & "This might take up to 3 minutes!", MsgBoxStyle.Information)
End If
Cursor = Cursors.Default
End Sub
@@ -618,6 +622,8 @@ Public Class frmMain
End Sub
Private Sub itemRefreshProxy_ItemClick(sender As Object, e As ItemClickEventArgs) Handles itemRefreshProxy.ItemClick
Me.Cursor = Cursors.WaitCursor
Dim upd = "UPDATE TBPROXY_CONFIG SET SYNC_RUNNING = 1 WHERE GUID = 1"
clsDatabase.Execute_non_Query(upd, True)
If ClassProxy.Refresh_Object_Data() = True Then
If ClassProxy.PRPROXY_SYNC_DOC_OBJECTS() = True Then
Dim msg = "Die Proxydaten wurden erfolgreich synchronisiert!"
@@ -631,6 +637,8 @@ Public Class frmMain
Else
MessageBox.Show("Error while refreshing proxy-data (objects)!", "", MessageBoxButtons.OK, MessageBoxIcon.Error)
End If
upd = "UPDATE TBPROXY_CONFIG SET SYNC_RUNNING = 0, LAST_SYNC = GETDATE() WHERE GUID = 1"
clsDatabase.Execute_non_Query(upd, True)
Me.Cursor = Cursors.Default
End Sub
Sub Load_ConfigBasic()