finance-asset-report/PowerAutomateFlow-Dell.txt
2024-03-22 09:37:32 -06:00

14 lines
1.4 KiB
Plaintext

Text.ParseText.RegexParseForFirstOccurrence Text: ExtractedPDFText TextToFind: $'''PO Number\\/Réf client: (\\S+)''' StartingPosition: 0 IgnoreCase: False OccurrencePosition=> Position Match=> Match
Text.CropText.CropTextAfterFlag Text: Match FromFlag: $''':''' IgnoreCase: True CroppedText=> CroppedText IsFlagFound=> IsFlagFound
SET PONumber TO CroppedText
Text.ParseText.RegexParseForFirstOccurrence Text: ExtractedPDFText TextToFind: $'''No de facture: (\\S+)''' StartingPosition: 0 IgnoreCase: False OccurrencePosition=> Position Match=> Match
Text.CropText.CropTextAfterFlag Text: Match FromFlag: $''':''' IgnoreCase: True CroppedText=> CroppedText IsFlagFound=> IsFlagFound
SET InvoiceNumber TO CroppedText
Text.ParseText.RegexParse Text: ExtractedPDFText TextToFind: $'''\\b(?=.*\\d)[A-Z0-9]{7}\\b''' StartingPosition: 0 IgnoreCase: False OccurrencePositions=> Positions Matches=> Matches
LOOP FOREACH MatchedTags IN Matches
Variables.FindOrReplaceInDataTable.FindItemInDataTableByColumnIndex DataTable: AssetList AllMatches: True ValueToFind: MatchedTags MatchCase: False MatchEntireCellContents: False ColumnNameOrIndex: $'''serial''' DataTableMatches=> DataTableMatches
LOOP FOREACH Asset_Match IN DataTableMatches
Variables.ModifyDataTableItem DataTable: AssetList ColumnNameOrIndex: $'''InvoiceNumber''' RowIndex: Asset_Match['Row'] Value: InvoiceNumber.Trimmed
END
END