Compare commits
2 Commits
eef779ab09
...
65b73b45bf
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
65b73b45bf | ||
|
|
4554c5841d |
@ -482,7 +482,7 @@ Public Class ClassControlCreator
|
|||||||
Return control
|
Return control
|
||||||
End Function
|
End Function
|
||||||
|
|
||||||
Public Function CreateExistingGridControl(row As DataRow, DT_MY_COLUMNS As DataTable, designMode As Boolean) As GridControl
|
Public Function CreateExistingGridControl(row As DataRow, DT_MY_COLUMNS As DataTable, designMode As Boolean, pcurrencySymbol As String) As GridControl
|
||||||
Dim oGridControlCreator = New ControlCreator.GridControl(LogConfig, GridTables)
|
Dim oGridControlCreator = New ControlCreator.GridControl(LogConfig, GridTables)
|
||||||
Dim oControl As GridControl = CreateBaseControl(New GridControl(), row, designMode)
|
Dim oControl As GridControl = CreateBaseControl(New GridControl(), row, designMode)
|
||||||
Dim oControlId = DirectCast(oControl.Tag, ControlMetadata).Guid
|
Dim oControlId = DirectCast(oControl.Tag, ControlMetadata).Guid
|
||||||
@ -586,7 +586,7 @@ Public Class ClassControlCreator
|
|||||||
End Try
|
End Try
|
||||||
End If
|
End If
|
||||||
|
|
||||||
oGridControlCreator.ConfigureViewColumns(DT_MY_COLUMNS, oView, oControl)
|
oGridControlCreator.ConfigureViewColumns(DT_MY_COLUMNS, oView, oControl, pcurrencySymbol)
|
||||||
oGridControlCreator.ConfigureViewEvents(DT_MY_COLUMNS, oView, oControl, oControlId)
|
oGridControlCreator.ConfigureViewEvents(DT_MY_COLUMNS, oView, oControl, oControlId)
|
||||||
|
|
||||||
' 08.11.2021: Fix editor being empty on first open
|
' 08.11.2021: Fix editor being empty on first open
|
||||||
|
|||||||
@ -144,8 +144,16 @@ Namespace ControlCreator
|
|||||||
Return oEditor
|
Return oEditor
|
||||||
End If
|
End If
|
||||||
End Function
|
End Function
|
||||||
|
' Hilfsroutine: passt NUR das Summary-Item an (ohne FormatInfo)
|
||||||
|
Private Sub ApplyCurrencySummaryFormat(oCol As GridColumn, currencySymbol As String)
|
||||||
|
oCol.SummaryItem.SummaryType = DevExpress.Data.SummaryItemType.Sum
|
||||||
|
' Variante A: Standard-Währungsformat aus aktueller Kultur
|
||||||
|
' oCol.SummaryItem.DisplayFormat = "SUM: {0:C2}"
|
||||||
|
|
||||||
Public Sub ConfigureViewColumns(pColumnTable As DataTable, pGridView As GridView, pGrid As DevExpress.XtraGrid.GridControl)
|
' Variante B: Kulturunabhängig, Symbol explizit anhängen
|
||||||
|
oCol.SummaryItem.DisplayFormat = $"SUM: {{0:N2}} {currencySymbol}"
|
||||||
|
End Sub
|
||||||
|
Public Sub ConfigureViewColumns(pColumnTable As DataTable, pGridView As GridView, pGrid As DevExpress.XtraGrid.GridControl, pcurrencySymbol As String)
|
||||||
Dim oShouldDisplayFooter As Boolean = False
|
Dim oShouldDisplayFooter As Boolean = False
|
||||||
|
|
||||||
|
|
||||||
@ -192,8 +200,7 @@ Namespace ControlCreator
|
|||||||
oShouldDisplayFooter = True
|
oShouldDisplayFooter = True
|
||||||
|
|
||||||
Case Constants.AGGREGATE_TOTAL_CURRENCY
|
Case Constants.AGGREGATE_TOTAL_CURRENCY
|
||||||
oCol.SummaryItem.SummaryType = DevExpress.Data.SummaryItemType.Sum
|
ApplyCurrencySummaryFormat(oCol, pcurrencySymbol)
|
||||||
oCol.SummaryItem.DisplayFormat = "SUM: {0:C2}"
|
|
||||||
oShouldDisplayFooter = True
|
oShouldDisplayFooter = True
|
||||||
|
|
||||||
Case Constants.AGGREGATE_TOTAL_AVG
|
Case Constants.AGGREGATE_TOTAL_AVG
|
||||||
|
|||||||
@ -295,7 +295,7 @@ Public Class frmFormDesigner
|
|||||||
Dim oDTColumnsPerDevExGrid As DataTable = DatabaseFallback.GetDatatableECM(oSQL) ', "FDesignLaodControls")
|
Dim oDTColumnsPerDevExGrid As DataTable = DatabaseFallback.GetDatatableECM(oSQL) ', "FDesignLaodControls")
|
||||||
|
|
||||||
|
|
||||||
Dim table = ControlCreator.CreateExistingGridControl(row, oDTColumnsPerDevExGrid, True)
|
Dim table = ControlCreator.CreateExistingGridControl(row, oDTColumnsPerDevExGrid, True, "EUR")
|
||||||
|
|
||||||
AddHandler table.MouseClick, AddressOf gridControl_MouseClick
|
AddHandler table.MouseClick, AddressOf gridControl_MouseClick
|
||||||
' AddHandler table.ColumnHeaderMouseClick, AddressOf table_ColumnHeaderMouseClick
|
' AddHandler table.ColumnHeaderMouseClick, AddressOf table_ColumnHeaderMouseClick
|
||||||
|
|||||||
@ -3299,7 +3299,7 @@ FROM VWPM_PROFILE_ACTIVE T WHERE T.GUID IN (SELECT PROFILE_ID FROM [dbo].[FNPM_G
|
|||||||
|
|
||||||
LOGGER.Debug($"oTargetPath with NowParams: {oTargetPath}")
|
LOGGER.Debug($"oTargetPath with NowParams: {oTargetPath}")
|
||||||
|
|
||||||
Dim oResult = WINDREAM_MOD.NewFileStream(oSourcePath, oTargetPath, oWMObjecttype, True)
|
Dim oResult = WINDREAM_MOD.NewFileStream(oSourcePath, oTargetPath, oWMObjecttype)
|
||||||
If oResult = True Then
|
If oResult = True Then
|
||||||
WM_AHWF_docPath = oTargetPath
|
WM_AHWF_docPath = oTargetPath
|
||||||
Dim oDocID = WINDREAM_MOD.NewDocumentID
|
Dim oDocID = WINDREAM_MOD.NewDocumentID
|
||||||
|
|||||||
@ -355,7 +355,7 @@ Public Class frmMassValidator
|
|||||||
LOGGER.Debug("Versuch Tabelle zu laden")
|
LOGGER.Debug("Versuch Tabelle zu laden")
|
||||||
Dim oDTMyColumns As DataTable = DatabaseFallback.GetDatatableECM($"SELECT * FROM TBPM_CONTROL_TABLE WHERE CONTROL_ID = {oControlRow.Item("GUID")} ORDER BY SEQUENCE") ', "MV_LoadControls1")
|
Dim oDTMyColumns As DataTable = DatabaseFallback.GetDatatableECM($"SELECT * FROM TBPM_CONTROL_TABLE WHERE CONTROL_ID = {oControlRow.Item("GUID")} ORDER BY SEQUENCE") ', "MV_LoadControls1")
|
||||||
|
|
||||||
oControl = ControlCreator.CreateExistingGridControl(oControlRow, oDTMyColumns, False)
|
oControl = ControlCreator.CreateExistingGridControl(oControlRow, oDTMyColumns, False, CURRENT_DOC_CURRENCY)
|
||||||
End Select
|
End Select
|
||||||
|
|
||||||
If oControl IsNot Nothing AndAlso TypeOf oControl IsNot Label Then
|
If oControl IsNot Nothing AndAlso TypeOf oControl IsNot Label Then
|
||||||
|
|||||||
@ -75,6 +75,7 @@ Public Class frmValidator
|
|||||||
Private CountAction As Int16 = 0
|
Private CountAction As Int16 = 0
|
||||||
Public Shared Property WMDocPathWindows As String
|
Public Shared Property WMDocPathWindows As String
|
||||||
Private Property DocPathWindows As String
|
Private Property DocPathWindows As String
|
||||||
|
Private Property DocCurrency As String = "EUR"
|
||||||
'Anzahl der Validierungsdokumente
|
'Anzahl der Validierungsdokumente
|
||||||
Private Property Amount_Docs2Validate As Integer
|
Private Property Amount_Docs2Validate As Integer
|
||||||
Private Property first_control As Control
|
Private Property first_control As Control
|
||||||
@ -1137,7 +1138,7 @@ Public Class frmValidator
|
|||||||
Continue For
|
Continue For
|
||||||
End If
|
End If
|
||||||
|
|
||||||
Dim oGrid = ControlCreator.CreateExistingGridControl(oControlRow, oFilteredDatatable, False)
|
Dim oGrid = ControlCreator.CreateExistingGridControl(oControlRow, oFilteredDatatable, False, DocCurrency)
|
||||||
oMyControl = oGrid
|
oMyControl = oGrid
|
||||||
'AddHandler oGrid.Views(0).c AddressOf GridView_CustomColumnDisplayText
|
'AddHandler oGrid.Views(0).c AddressOf GridView_CustomColumnDisplayText
|
||||||
|
|
||||||
@ -1345,6 +1346,7 @@ Public Class frmValidator
|
|||||||
Dim oTitle
|
Dim oTitle
|
||||||
Dim oCaption
|
Dim oCaption
|
||||||
Dim oColor
|
Dim oColor
|
||||||
|
Dim oIncludeFI As Boolean = False
|
||||||
Try
|
Try
|
||||||
oAction = oDT_ACTIONS?.Rows(0).Item("ActionType")
|
oAction = oDT_ACTIONS?.Rows(0).Item("ActionType")
|
||||||
Catch ex As Exception
|
Catch ex As Exception
|
||||||
@ -1375,12 +1377,17 @@ Public Class frmValidator
|
|||||||
Catch ex As Exception
|
Catch ex As Exception
|
||||||
oColor = ""
|
oColor = ""
|
||||||
End Try
|
End Try
|
||||||
|
Try
|
||||||
|
oIncludeFI = oDT_ACTIONS?.Rows(0).Item("IncludeFI")
|
||||||
|
Catch ex As Exception
|
||||||
|
End Try
|
||||||
Try
|
Try
|
||||||
OverrideAll = oDT_ACTIONS?.Rows(0).Item("OverrideAll")
|
OverrideAll = oDT_ACTIONS?.Rows(0).Item("OverrideAll")
|
||||||
Catch ex As Exception
|
Catch ex As Exception
|
||||||
MyValidationLogger.Warn($"Could not set OverrideAll {ex.Message}")
|
MyValidationLogger.Warn($"Could not set OverrideAll {ex.Message}")
|
||||||
OverrideAll = False
|
OverrideAll = False
|
||||||
End Try
|
End Try
|
||||||
|
|
||||||
If OverrideAll = True Then
|
If OverrideAll = True Then
|
||||||
MyValidationLogger.Info($"CURRENT_DOC_ID: {CURRENT_DOC_ID} - OverrideAll will be in Action!")
|
MyValidationLogger.Info($"CURRENT_DOC_ID: {CURRENT_DOC_ID} - OverrideAll will be in Action!")
|
||||||
End If
|
End If
|
||||||
@ -1395,7 +1402,7 @@ Public Class frmValidator
|
|||||||
result = MessageBox.Show(oQuestion, oTitle, MessageBoxButtons.YesNo, MessageBoxIcon.Exclamation)
|
result = MessageBox.Show(oQuestion, oTitle, MessageBoxButtons.YesNo, MessageBoxIcon.Exclamation)
|
||||||
If result = MsgBoxResult.Yes Then
|
If result = MsgBoxResult.Yes Then
|
||||||
Override = True
|
Override = True
|
||||||
Finish_WFStep()
|
Finish_WFStep(oIncludeFI)
|
||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
Case "Update_Single_Control".ToUpper
|
Case "Update_Single_Control".ToUpper
|
||||||
@ -1441,7 +1448,7 @@ Public Class frmValidator
|
|||||||
Case "Override_Direct".ToUpper
|
Case "Override_Direct".ToUpper
|
||||||
Override = True
|
Override = True
|
||||||
If Check_UpdateIndexe() = True Then
|
If Check_UpdateIndexe() = True Then
|
||||||
Finish_WFStep(False)
|
Finish_WFStep(oIncludeFI)
|
||||||
End If
|
End If
|
||||||
|
|
||||||
Case "Override incFinal".ToUpper
|
Case "Override incFinal".ToUpper
|
||||||
@ -2789,24 +2796,24 @@ Public Class frmValidator
|
|||||||
End If
|
End If
|
||||||
|
|
||||||
If Not IsNothing(oCurrency) Then
|
If Not IsNothing(oCurrency) Then
|
||||||
|
DocCurrency = oCurrency
|
||||||
Dim oValueType = oCurrency.GetType.ToString
|
Dim oValueType = DocCurrency.GetType.ToString
|
||||||
If IsDBNull(oCurrency) Then
|
If IsDBNull(DocCurrency) Then
|
||||||
oCurrency = "EUR"
|
DocCurrency = "EUR"
|
||||||
Else
|
Else
|
||||||
Try
|
Try
|
||||||
oCurrency = oCurrency.ToString
|
DocCurrency = DocCurrency.ToString
|
||||||
Catch ex As Exception
|
Catch ex As Exception
|
||||||
MyValidationLogger.Warn($"Unexpected error in Converting oCurreny to string: " & ex.Message)
|
MyValidationLogger.Warn($"Unexpected error in Converting oCurreny to string: " & ex.Message)
|
||||||
oCurrency = "EUR"
|
DocCurrency = "EUR"
|
||||||
End Try
|
End Try
|
||||||
End If
|
End If
|
||||||
If oCurrency <> String.Empty Then
|
If DocCurrency <> String.Empty Then
|
||||||
If oCurrency.ToString.Length <> 3 Then
|
If DocCurrency.ToString.Length <> 3 Then
|
||||||
MyValidationLogger.Info("oCurrency-Length = 3 - Setting to EUR")
|
MyValidationLogger.Info("DocCurrency-Length = 3 - Setting to EUR")
|
||||||
oCurrency = "EUR"
|
DocCurrency = "EUR"
|
||||||
End If
|
End If
|
||||||
MyValidationLogger.Debug($"oCurrency = {oCurrency}")
|
MyValidationLogger.Debug($"DocCurrency = {DocCurrency}")
|
||||||
For Each oControl As Control In PanelValidatorControl.Controls
|
For Each oControl As Control In PanelValidatorControl.Controls
|
||||||
Try
|
Try
|
||||||
Dim oMeta = DirectCast(oControl.Tag, ClassControlCreator.ControlMetadata)
|
Dim oMeta = DirectCast(oControl.Tag, ClassControlCreator.ControlMetadata)
|
||||||
@ -2818,7 +2825,7 @@ Public Class frmValidator
|
|||||||
DT_COLUMNS_GRID.Select(oExpression, "SEQUENCE").CopyToDataTable(oFilteredDatatable, LoadOption.PreserveChanges)
|
DT_COLUMNS_GRID.Select(oExpression, "SEQUENCE").CopyToDataTable(oFilteredDatatable, LoadOption.PreserveChanges)
|
||||||
|
|
||||||
Dim oCultureInfo As CultureInfo = New CultureInfo("de-DE")
|
Dim oCultureInfo As CultureInfo = New CultureInfo("de-DE")
|
||||||
oCultureInfo.NumberFormat.CurrencySymbol = oCurrency
|
oCultureInfo.NumberFormat.CurrencySymbol = DocCurrency
|
||||||
Dim riTextEdit As RepositoryItemTextEdit = New RepositoryItemTextEdit()
|
Dim riTextEdit As RepositoryItemTextEdit = New RepositoryItemTextEdit()
|
||||||
riTextEdit.MaskSettings.Configure(Of MaskSettings.Numeric)(Sub(settings)
|
riTextEdit.MaskSettings.Configure(Of MaskSettings.Numeric)(Sub(settings)
|
||||||
settings.MaskExpression = "c"
|
settings.MaskExpression = "c"
|
||||||
@ -2852,7 +2859,7 @@ Public Class frmValidator
|
|||||||
End Try
|
End Try
|
||||||
Next
|
Next
|
||||||
Else
|
Else
|
||||||
MyValidationLogger.Warn($"oCurrency is String.empty! ")
|
MyValidationLogger.Warn($"DocCurrency is String.empty! ")
|
||||||
End If
|
End If
|
||||||
Else
|
Else
|
||||||
MyValidationLogger.Warn($"oCurrency is Nothing - Check PROFIL_CURRENCY_ATTRIBUTE! ")
|
MyValidationLogger.Warn($"oCurrency is Nothing - Check PROFIL_CURRENCY_ATTRIBUTE! ")
|
||||||
@ -6359,11 +6366,8 @@ Public Class frmValidator
|
|||||||
Indexiere_File(CURRENT_WMFILE, PROFIL_NOT_RESP_COMMENT_ATTR, frmDialog.oComment)
|
Indexiere_File(CURRENT_WMFILE, PROFIL_NOT_RESP_COMMENT_ATTR, frmDialog.oComment)
|
||||||
Else
|
Else
|
||||||
Dim oREsult = IDBData.SetVariableValue(PROFIL_NOT_RESP_COMMENT_ATTR, frmDialog.oComment)
|
Dim oREsult = IDBData.SetVariableValue(PROFIL_NOT_RESP_COMMENT_ATTR, frmDialog.oComment)
|
||||||
|
|
||||||
End If
|
End If
|
||||||
|
Finish_WFStep(oIncludeFI)
|
||||||
|
|
||||||
Finish_WFStep()
|
|
||||||
End If
|
End If
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
|||||||
@ -456,32 +456,19 @@ Public Class frmValidatorSearch
|
|||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
If My.Settings.frmValidatorSearchSize.IsEmpty = False Then
|
If My.Settings.frmValidatorSearchSize.IsEmpty = False Then
|
||||||
If My.Settings.frmValidatorSearchSize.Height > 100 And My.Settings.frmValidatorSearchSize.Width > 100 Then
|
If My.Settings.frmValidatorSearchSize.Height > 120 And My.Settings.frmValidatorSearchSize.Width > 120 Then
|
||||||
Me.Size = My.Settings.frmValidatorSearchSize
|
Me.Size = My.Settings.frmValidatorSearchSize
|
||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
SplitContainerSearches.SplitterDistance = My.Settings.frmValSearchSplitterDistance
|
If My.Settings.frmValSearchSplitterDistance > 20 Then
|
||||||
|
SplitContainerSearches.SplitterDistance = My.Settings.frmValSearchSplitterDistance
|
||||||
|
End If
|
||||||
|
|
||||||
|
|
||||||
ToolStripDropDownButtonFile.Visible = False
|
ToolStripDropDownButtonFile.Visible = False
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Private Sub frmValidatorSearch_Shown(sender As Object, e As EventArgs) Handles Me.Shown
|
Private Sub frmValidatorSearch_Shown(sender As Object, e As EventArgs) Handles Me.Shown
|
||||||
Try
|
|
||||||
If My.Settings.frmValidatorSearchPosition.X > 0 And My.Settings.frmValidatorSearchPosition.Y > 0 Then
|
|
||||||
Me.Location = My.Settings.frmValidatorSearchPosition
|
|
||||||
End If
|
|
||||||
|
|
||||||
If Me.Size.Height > 100 And Me.Size.Width > 100 Then
|
|
||||||
Me.Size = My.Settings.frmValidatorSearchSize
|
|
||||||
Else
|
|
||||||
Me.Size = New Size(500, 800)
|
|
||||||
End If
|
|
||||||
SplitContainerSearches.SplitterDistance = My.Settings.frmValSearchSplitterDistance
|
|
||||||
Catch ex As Exception
|
|
||||||
LOGGER.Error(ex)
|
|
||||||
End Try
|
|
||||||
|
|
||||||
|
|
||||||
formLoaded = True
|
formLoaded = True
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user