MS ClassUpdate entfernt
This commit is contained in:
@@ -754,9 +754,6 @@ LOGGER.Error(ex)
|
||||
|
||||
CURRENT_SQL_AUTO_VALUES_DT = DT_AUTOVALUES
|
||||
|
||||
If USER_WAN = True Then
|
||||
|
||||
End If
|
||||
Try
|
||||
Dim primaryKey(1) As DataColumn
|
||||
primaryKey(0) = CURRENT_DT_ENTITY_RECORDS.Columns("Record-ID")
|
||||
@@ -1636,7 +1633,10 @@ LOGGER.Error(ex)
|
||||
End Sub
|
||||
Private Sub OnCBSelectedValueChanged(sender As Object, e As EventArgs)
|
||||
Try
|
||||
Dim docId As Integer = ClassWindreamDocGrid.SELECTED_DOC_ID
|
||||
|
||||
Dim oDocuments = DocList.SelectedDocuments
|
||||
|
||||
Dim docId As Integer = oDocuments.First.DocId
|
||||
If docId = 0 Then
|
||||
MsgBox("Sorry no document was selected! Please try again!", MsgBoxStyle.Exclamation)
|
||||
Exit Sub
|
||||
@@ -1662,13 +1662,14 @@ LOGGER.Error(ex)
|
||||
End If
|
||||
|
||||
Catch ex As Exception
|
||||
LOGGER.Error(ex)
|
||||
LOGGER.Error(ex)
|
||||
ClassHelper.MSGBOX_Handler("ERROR", "Unexpected Error", "Error in OnCBSelectedValueChanged: ", ex.Message)
|
||||
End Try
|
||||
End Sub
|
||||
|
||||
Private Sub OnDateSelectedValueChanged(sender As Object, e As EventArgs)
|
||||
Try
|
||||
Dim oDocuments = DocList.SelectedDocuments
|
||||
Dim DatePicker As DateEdit = sender
|
||||
Dim value As DateTime = DatePicker.EditValue
|
||||
|
||||
@@ -1678,7 +1679,7 @@ LOGGER.Error(ex)
|
||||
Try
|
||||
validDate = Date.TryParse(DatePicker.OldEditValue, oldValue)
|
||||
Catch ex As Exception
|
||||
LOGGER.Error(ex)
|
||||
LOGGER.Error(ex)
|
||||
oldValue = Date.MinValue
|
||||
End Try
|
||||
|
||||
@@ -1697,7 +1698,7 @@ LOGGER.Error(ex)
|
||||
Dim detailRow As DataRowView = detailView.GetRow(detailView.FocusedRowHandle)
|
||||
Dim configid = detailRow.Item("CONFIG_ID")
|
||||
|
||||
Dim docId As Integer = ClassWindreamDocGrid.SELECTED_DOC_ID
|
||||
Dim docId As Integer = oDocuments.First.DocId
|
||||
If docId = 0 Then
|
||||
MsgBox("Sorry no document was selected! Please try again!", MsgBoxStyle.Exclamation)
|
||||
Exit Sub
|
||||
@@ -1712,13 +1713,14 @@ LOGGER.Error(ex)
|
||||
ClassProxy.PRPROXY_DOC_VALUES_UPD(docId, SELECTED_NODE_RECORD_ID)
|
||||
End If
|
||||
Catch ex As Exception
|
||||
LOGGER.Error(ex)
|
||||
LOGGER.Error(ex)
|
||||
ClassHelper.MSGBOX_Handler("ERROR", "Unexpected Error", "Error in OnDateSelectedValueChanged: ", ex.Message)
|
||||
End Try
|
||||
End Sub
|
||||
|
||||
Private Sub OnTextSelectedValueChanged(sender As Object, e As EventArgs)
|
||||
Try
|
||||
Dim oDocuments = DocList.SelectedDocuments
|
||||
Dim TextBox As TextEdit = sender
|
||||
Dim value = TextBox.EditValue
|
||||
If value.ToUpper = "Not displayable in Group-Search".ToUpper Then
|
||||
@@ -1733,7 +1735,7 @@ LOGGER.Error(ex)
|
||||
Dim detailRow As DataRowView = detailView.GetRow(detailView.FocusedRowHandle)
|
||||
Dim configid = detailRow.Item("CONFIG_ID")
|
||||
|
||||
Dim docId As Integer = ClassWindreamDocGrid.SELECTED_DOC_ID
|
||||
Dim docId As Integer = oDocuments.First.DocId
|
||||
If docId = 0 Then
|
||||
MsgBox("Sorry no document was selected! Please try again!", MsgBoxStyle.Exclamation)
|
||||
Exit Sub
|
||||
@@ -1747,7 +1749,7 @@ LOGGER.Error(ex)
|
||||
ClassProxy.PRPROXY_DOC_VALUES_UPD(docId, SELECTED_NODE_RECORD_ID)
|
||||
End If
|
||||
Catch ex As Exception
|
||||
LOGGER.Error(ex)
|
||||
LOGGER.Error(ex)
|
||||
ClassHelper.MSGBOX_Handler("ERROR", "Unexpected Error", "Error in OnTextSelectedValueChanged: ", ex.Message)
|
||||
End Try
|
||||
End Sub
|
||||
@@ -1755,6 +1757,7 @@ LOGGER.Error(ex)
|
||||
Private Sub OnCheckboxValueChanged(sender As Object, e As EventArgs)
|
||||
'TODO Save Checkboxvalue
|
||||
Try
|
||||
Dim oDocuments = DocList.SelectedDocuments
|
||||
Dim CheckBox As CheckEdit = sender
|
||||
Dim value As Boolean = CheckBox.EditValue
|
||||
|
||||
@@ -1764,7 +1767,7 @@ LOGGER.Error(ex)
|
||||
Dim detailRow As DataRowView = detailView.GetRow(detailView.FocusedRowHandle)
|
||||
Dim configid = detailRow.Item("CONFIG_ID")
|
||||
|
||||
Dim docId As Integer = ClassWindreamDocGrid.SELECTED_DOC_ID
|
||||
Dim docId As Integer = oDocuments.First.DocId
|
||||
If docId = 0 Then
|
||||
MsgBox("Sorry no document was selected! Please try again!", MsgBoxStyle.Exclamation)
|
||||
Exit Sub
|
||||
@@ -1778,7 +1781,7 @@ LOGGER.Error(ex)
|
||||
ClassProxy.PRPROXY_DOC_VALUES_UPD(docId, SELECTED_NODE_RECORD_ID)
|
||||
End If
|
||||
Catch ex As Exception
|
||||
LOGGER.Error(ex)
|
||||
LOGGER.Error(ex)
|
||||
ClassHelper.MSGBOX_Handler("ERROR", "Unexpected Error", "Error in OnCheckboxValueChanged: ", ex.Message)
|
||||
End Try
|
||||
End Sub
|
||||
@@ -1805,11 +1808,10 @@ LOGGER.Error(ex)
|
||||
Refresh_DocID()
|
||||
End Sub
|
||||
Sub Refresh_DocID()
|
||||
If ClassWindreamDocGrid.SELECTED_DOC_ID <> 0 Then
|
||||
Dim omsg = "Doc-ID: " & ClassWindreamDocGrid.SELECTED_DOC_ID.ToString
|
||||
Dim oDocuments = DocList.SelectedDocuments
|
||||
If oDocuments.Count <> 0 Then
|
||||
Dim omsg = "Doc-ID: " & oDocuments.First.DocId
|
||||
Update_DocID_Label(True, omsg, EditState.Update)
|
||||
|
||||
|
||||
Else
|
||||
Update_DocID_Label(True, "DocRow not selected", EditState.None)
|
||||
End If
|
||||
@@ -1890,7 +1892,11 @@ LOGGER.Error(ex)
|
||||
#Region "Dropping Files"
|
||||
Sub Drag_Enter(e As DragEventArgs)
|
||||
If _EntityId <> 0 Then
|
||||
ClassDragDrop.Drag_enter(e)
|
||||
If WM_READ_ONLY = False Then
|
||||
ClassDragDrop.Drag_enter(e)
|
||||
Else
|
||||
Update_Status_Label(True, "READ ONLY ACCESS", EditState.Insert)
|
||||
End If
|
||||
Else
|
||||
Update_Status_Label(True, "No entity selected", EditState.Insert)
|
||||
End If
|
||||
@@ -2229,41 +2235,46 @@ LOGGER.Error(ex)
|
||||
ContextMenu_Multiplefiles()
|
||||
ElseIf oSelectedDocs.Count = 1 Then
|
||||
File_in_Work()
|
||||
Dim oSelectedDocument = oSelectedDocs.First
|
||||
Dim Result = ClassDOC_SEARCH.Get_File_Rights(oSelectedDocument.DocId)
|
||||
If Not IsNothing(Result) Then
|
||||
_RowReadOnly = False
|
||||
Select Case Result.ToString
|
||||
Case "R"
|
||||
ContextMenu_Read()
|
||||
Case "RW"
|
||||
ContextMenu_Write()
|
||||
Case "RWA"
|
||||
ContextMenu_Write()
|
||||
Case ""
|
||||
If WM_READ_ONLY Then
|
||||
ContextMenu_Read()
|
||||
Else
|
||||
Dim oSelectedDocument = oSelectedDocs.First
|
||||
Dim Result = ClassDOC_SEARCH.Get_File_Rights(oSelectedDocument.DocId)
|
||||
If Not IsNothing(Result) Then
|
||||
_RowReadOnly = False
|
||||
Select Case Result.ToString
|
||||
Case "R"
|
||||
ContextMenu_Read()
|
||||
Case "RW"
|
||||
ContextMenu_Write()
|
||||
Case "RWA"
|
||||
ContextMenu_Write()
|
||||
Case ""
|
||||
If USER_IS_ADMIN = False Then
|
||||
ContextMenu_Read()
|
||||
Else
|
||||
LOGGER.Warn("FileRight is '' but User is Admin!! - Check the configuration!")
|
||||
End If
|
||||
_RowReadOnly = True
|
||||
End Select
|
||||
CURRENT_FILE_RIGHT = Result.ToString
|
||||
Else
|
||||
ContextMenu_Read()
|
||||
ClassHelper.MSGBOX_Handler("ERROR", "Unexpected Error", "Error in Getting rights - check the log")
|
||||
e.Cancel = True
|
||||
End If
|
||||
If _RowReadOnly = False Then
|
||||
If RIGHT_READ_ONLY_DOC = True Then
|
||||
If USER_IS_ADMIN = False Then
|
||||
ContextMenu_Read()
|
||||
Else
|
||||
LOGGER.Warn("FileRight is '' but User is Admin!! - Check the configuration!")
|
||||
LOGGER.Warn("RIGHT_READ_ONLY_DOC = True but User is Admin!! - Check the configuration!")
|
||||
End If
|
||||
_RowReadOnly = True
|
||||
End Select
|
||||
CURRENT_FILE_RIGHT = Result.ToString
|
||||
Else
|
||||
ContextMenu_Read()
|
||||
ClassHelper.MSGBOX_Handler("ERROR", "Unexpected Error", "Error in Getting rights - check the log")
|
||||
e.Cancel = True
|
||||
End If
|
||||
If _RowReadOnly = False Then
|
||||
If RIGHT_READ_ONLY_DOC = True Then
|
||||
If USER_IS_ADMIN = False Then
|
||||
ContextMenu_Read()
|
||||
Else
|
||||
LOGGER.Warn("RIGHT_READ_ONLY_DOC = True but User is Admin!! - Check the configuration!")
|
||||
End If
|
||||
End If
|
||||
End If
|
||||
|
||||
|
||||
If oSelectedDocs.First.DisplayName <> "" Then
|
||||
tsmiFileRenameDisplayname.Visible = True
|
||||
Else
|
||||
@@ -2284,12 +2295,9 @@ LOGGER.Error(ex)
|
||||
|
||||
Sub ContextMenu_Multiplefiles()
|
||||
tsmiFileProperties.Enabled = False
|
||||
|
||||
tsmiFileOpen.Enabled = False
|
||||
tsmiFileFolderOpen.Enabled = False
|
||||
|
||||
tsmiFileInWork.Enabled = False
|
||||
|
||||
tsmiFileLink_Add.Enabled = True
|
||||
tsmiFileLink_ShowAll.Enabled = True
|
||||
tsmiFileLinkRemove.Enabled = True
|
||||
@@ -2342,8 +2350,8 @@ LOGGER.Error(ex)
|
||||
Me.Cursor = Cursors.WaitCursor
|
||||
Dim allow_Open As Boolean = False
|
||||
'ClassWindreamDocGrid.GetDocItems(GridViewDoc_Search)
|
||||
|
||||
Dim Result = ClassDOC_SEARCH.Get_File_Rights(ClassWindreamDocGrid.SELECTED_DOC_ID)
|
||||
Dim oDocuments = DocList.SelectedDocuments
|
||||
Dim Result = ClassDOC_SEARCH.Get_File_Rights(oDocuments.First.DocId)
|
||||
|
||||
|
||||
If Not IsNothing(Result) Then
|
||||
@@ -2376,8 +2384,8 @@ LOGGER.Error(ex)
|
||||
End If
|
||||
Next
|
||||
Else
|
||||
If clsWD_GET.WDFile_exists(ClassWindreamDocGrid.SELECTED_DOC_PATH, DD_LIB_Standards.clsDatabase.DB_PROXY_INITIALIZED, ClassProxy.MyLinkedServer, True) = True Then
|
||||
ClassHelper.MSGBOX_Handler("ERROR", "Right-Management", "File is existing, but you do not have the rights to open this file! " & vbNewLine & "Please contact your admin!" & vbNewLine & "DOC-ID: " & ClassWindreamDocGrid.SELECTED_DOC_ID.ToString)
|
||||
If clsWD_GET.WDFile_exists(oDocuments.First.DocPath, DD_LIB_Standards.clsDatabase.DB_PROXY_INITIALIZED, ClassProxy.MyLinkedServer, True) = True Then
|
||||
ClassHelper.MSGBOX_Handler("ERROR", "Right-Management", "File is existing, but you do not have the rights to open this file! " & vbNewLine & "Please contact your admin!" & vbNewLine & "DOC-ID: " & oDocuments.First.DocId.ToString)
|
||||
Else
|
||||
ClassHelper.MSGBOX_Handler("ERROR", "", "File does not exist! Please contact your admin!")
|
||||
End If
|
||||
@@ -2390,50 +2398,55 @@ LOGGER.Error(ex)
|
||||
INWORK_FILE = False
|
||||
tsmiFileInWork.Enabled = True
|
||||
Try
|
||||
Dim expression As String
|
||||
expression = "DocID = " & ClassWindreamDocGrid.SELECTED_DOC_ID
|
||||
Dim foundRowsLevel0() As DataRow
|
||||
'Dim expression As String
|
||||
'expression = "DocID = " & ClassWindreamDocGrid.SELECTED_DOC_ID
|
||||
'Dim foundRowsLevel0() As DataRow
|
||||
' Use the Select method to find all rows matching the filter.
|
||||
foundRowsLevel0 = CURRENT_DOC_RESULTS.Select(expression)
|
||||
'foundRowsLevel0 = CURRENT_DOC_RESULTS.Select(expression)
|
||||
|
||||
Try
|
||||
Dim oSQLDRList = $"Select COALESCE(IN_WORK_USER,'') IN_WORK_USER, COALESCE(IN_WORK_COMMENT,'') IN_WORK_COMMENT,IN_WORK FROM TBPMO_DOCRESULT_LIST where DocID = {ClassWindreamDocGrid.SELECTED_DOC_ID}"
|
||||
Dim oDT As DataTable = MYDB_ECM.GetDatatable(oSQLDRList)
|
||||
If Not IsNothing(oDT) Then
|
||||
If oDT.Rows.Count = 1 Then
|
||||
IW_USER = oDT.Rows(0).Item("IN_WORK_USER")
|
||||
IW_COMMENT = oDT.Rows(0).Item("IN_WORK_COMMENT")
|
||||
INWORK_FILE = CBool(oDT.Rows(0).Item("IN_WORK"))
|
||||
Dim oDocuments = DocList.SelectedDocuments
|
||||
If oDocuments.Count = 1 Then
|
||||
Try
|
||||
Dim oSQLDRList = $"Select COALESCE(IN_WORK_USER,'') IN_WORK_USER, COALESCE(IN_WORK_COMMENT,'') IN_WORK_COMMENT,IN_WORK FROM TBPMO_DOCRESULT_LIST where DocID = {oDocuments.First.DocId}"
|
||||
Dim oDT As DataTable = MYDB_ECM.GetDatatable(oSQLDRList)
|
||||
If Not IsNothing(oDT) Then
|
||||
If oDT.Rows.Count = 1 Then
|
||||
IW_USER = oDT.Rows(0).Item("IN_WORK_USER")
|
||||
IW_COMMENT = oDT.Rows(0).Item("IN_WORK_COMMENT")
|
||||
INWORK_FILE = CBool(oDT.Rows(0).Item("IN_WORK"))
|
||||
End If
|
||||
End If
|
||||
End If
|
||||
Catch ex As Exception
|
||||
LOGGER.Error(ex)
|
||||
LOGGER.Error(ex)
|
||||
IW_USER = ""
|
||||
IW_COMMENT = ""
|
||||
End Try
|
||||
Catch ex As Exception
|
||||
LOGGER.Error(ex)
|
||||
IW_USER = ""
|
||||
IW_COMMENT = ""
|
||||
End Try
|
||||
|
||||
|
||||
Dim displ As String
|
||||
If INWORK_FILE = True Then
|
||||
If IW_USER.ToUpper = USER_USERNAME.ToUpper Or USER_IS_ADMIN Or USER_IS_SUPERVISOR Then
|
||||
displ = "Datei wieder freigeben"
|
||||
If USER_LANGUAGE <> "de-DE" Then
|
||||
displ = "Set file free"
|
||||
Dim displ As String
|
||||
If INWORK_FILE = True Then
|
||||
If IW_USER.ToUpper = USER_USERNAME.ToUpper Or USER_IS_ADMIN Or USER_IS_SUPERVISOR Then
|
||||
displ = "Datei wieder freigeben"
|
||||
If USER_LANGUAGE <> "de-DE" Then
|
||||
displ = "Set file free"
|
||||
End If
|
||||
Else
|
||||
displ = "Datei in Bearbeitung (zeige Info)"
|
||||
If USER_LANGUAGE <> "de-DE" Then
|
||||
displ = "File is in work (show details)"
|
||||
End If
|
||||
End If
|
||||
Else
|
||||
displ = "Datei in Bearbeitung (zeige Info)"
|
||||
displ = "Datei in Bearbeitung nehmen"
|
||||
If USER_LANGUAGE <> "de-DE" Then
|
||||
displ = "File is in work (show details)"
|
||||
displ = "Lock file for working"
|
||||
End If
|
||||
End If
|
||||
tsmiFileInWork.Text = displ
|
||||
Else
|
||||
displ = "Datei in Bearbeitung nehmen"
|
||||
If USER_LANGUAGE <> "de-DE" Then
|
||||
displ = "Lock file for working"
|
||||
End If
|
||||
MsgBox("Bitte nur eine Datei wählen!", MsgBoxStyle.Exclamation)
|
||||
End If
|
||||
tsmiFileInWork.Text = displ
|
||||
|
||||
Catch ex As Exception
|
||||
LOGGER.Error(ex)
|
||||
LOGGER.Warn("Unexpected Error in File-Work Info: " & ex.Message)
|
||||
@@ -2446,27 +2459,31 @@ LOGGER.Error(ex)
|
||||
MsgBox("Could not read File Parameters (3)!", MsgBoxStyle.Exclamation)
|
||||
Exit Sub
|
||||
End If
|
||||
ClassFileResult.DocID = ClassWindreamDocGrid.SELECTED_DOC_ID
|
||||
If INWORK_FILE = True Then ' Datei ist in Bearbeitung
|
||||
Dim msglbl As String
|
||||
Dim msg1 As String
|
||||
If IW_USER.ToUpper = USER_USERNAME.ToUpper Or USER_IS_ADMIN Or USER_IS_SUPERVISOR Then
|
||||
If ClassFileResult.Set_InWork(0, "") = True Then
|
||||
Await RUN_WDSEARCH_GRID(True)
|
||||
Dim oDocuments = DocList.SelectedDocuments
|
||||
If oDocuments.Count = 1 Then
|
||||
ClassFileResult.DocID = oDocuments.First.DocId
|
||||
If INWORK_FILE = True Then ' Datei ist in Bearbeitung
|
||||
Dim msglbl As String
|
||||
Dim msg1 As String
|
||||
If IW_USER.ToUpper = USER_USERNAME.ToUpper Or USER_IS_ADMIN Or USER_IS_SUPERVISOR Then
|
||||
If ClassFileResult.Set_InWork(0, "") = True Then
|
||||
Await RUN_WDSEARCH_GRID(True)
|
||||
End If
|
||||
Else
|
||||
msglbl = "In Bearbeitung durch User '" & IW_USER & "' - Kommentar:"
|
||||
msg1 = IW_COMMENT
|
||||
If USER_LANGUAGE <> "de-DE" Then
|
||||
msglbl = "File being edited by user '" & IW_USER & "' - Comment:"
|
||||
End If
|
||||
ClassHelper.MSGBOX_Handler("INFO", "Information file", msglbl, msg1)
|
||||
End If
|
||||
Else
|
||||
msglbl = "In Bearbeitung durch User '" & IW_USER & "' - Kommentar:"
|
||||
msg1 = IW_COMMENT
|
||||
If USER_LANGUAGE <> "de-DE" Then
|
||||
msglbl = "File in Work through User '" & IW_USER & "' - Comment:"
|
||||
End If
|
||||
ClassHelper.MSGBOX_Handler("INFO", "Information file", msglbl, msg1)
|
||||
frmFileInWork.ShowDialog()
|
||||
ClassWindreamDocGrid.SELECTED_INWORK = ClassFileResult.InWork
|
||||
Await RUN_WDSEARCH_GRID(True)
|
||||
End If
|
||||
Else
|
||||
frmFileInWork.ShowDialog()
|
||||
ClassWindreamDocGrid.SELECTED_INWORK = ClassFileResult.InWork
|
||||
Await RUN_WDSEARCH_GRID(True)
|
||||
End If
|
||||
|
||||
End Sub
|
||||
|
||||
Private Sub frmNodeNavigation_Shown(sender As Object, e As EventArgs) Handles Me.Shown
|
||||
@@ -2686,7 +2703,9 @@ LOGGER.Error(ex)
|
||||
End Sub
|
||||
|
||||
Private Sub tsmiFileRightsShow_Click(sender As Object, e As EventArgs) Handles tsmiFileRightsShow.Click
|
||||
Dim result = ClassDOC_SEARCH.Get_File_Rights(ClassWindreamDocGrid.SELECTED_DOC_ID)
|
||||
Dim oDocuments = DocList.SelectedDocuments
|
||||
|
||||
Dim result = ClassDOC_SEARCH.Get_File_Rights(oDocuments.First.DocId)
|
||||
If Not IsNothing(result) Then
|
||||
Dim msg = "Das aktuelle Recht für Sie (" & USER_USERNAME & ") ist: "
|
||||
If USER_LANGUAGE <> "de-DE" Then
|
||||
|
||||
Reference in New Issue
Block a user