Page 6248 Sustainability Value Entries
src/Apps/W1/Sustainability/app/src/Ledger/SustainabilityValueEntries.Page.al299 lines, Copyright (c) Microsoft Corporation. MIT
namespace Microsoft.Sustainability.Ledger;using Microsoft.Finance.Dimension;using Microsoft.Foundation.Navigate;page 6248 "Sustainability Value Entries"{ ApplicationArea = Basic, Suite; Caption = 'Sustainability Value Entries'; PageType = List; SourceTable = "Sustainability Value Entry"; SourceTableView = sorting("Entry No.") order(descending); UsageCategory = History; DeleteAllowed = false; InsertAllowed = false; Editable = false; AnalysisModeEnabled = true; layout { area(Content) { repeater(General) { field("Entry No."; Rec."Entry No.") { ToolTip = 'Specifies the value of the Entry No. field.'; } field("Type"; Rec."Type") { ToolTip = 'Specifies the value of the Type field.'; } field("No."; Rec."No.") { ToolTip = 'Specifies the value of the No. field.'; } field("Posting Date"; Rec."Posting Date") { ToolTip = 'Specifies the value of the Posting Date field.'; } field("Item Ledger Entry Type"; Rec."Item Ledger Entry Type") { ToolTip = 'Specifies the value of the Item Ledger Entry Type field.'; } field("Document No."; Rec."Document No.") { ToolTip = 'Specifies the value of the Document No. field.'; } field("Item No."; Rec."Item No.") { ToolTip = 'Specifies the value of the Item No. field.'; } field("Item Ledger Entry No."; Rec."Item Ledger Entry No.") { ToolTip = 'Specifies the value of the Item Ledger Entry No. field.'; } field("Valued Quantity"; Rec."Valued Quantity") { ToolTip = 'Specifies the value of the Valued Quantity field.'; } field("Item Ledger Entry Quantity"; Rec."Item Ledger Entry Quantity") { ToolTip = 'Specifies the value of the Item Ledger Entry Quantity field.'; } field("Invoiced Quantity"; Rec."Invoiced Quantity") { ToolTip = 'Specifies the value of the Invoiced Quantity field.'; } field("CO2e per Unit"; Rec."CO2e per Unit") { ToolTip = 'Specifies the value of the CO2e per Unit field.'; } field("User ID"; Rec."User ID") { ToolTip = 'Specifies the value of the User ID field.'; } field("Source Code"; Rec."Source Code") { ToolTip = 'Specifies the value of the Source Code field.'; } field("Applies-to Entry"; Rec."Applies-to Entry") { ToolTip = 'Specifies the value of the Applies-to Entry field.'; } field("Expected Emission"; Rec."Expected Emission") { ToolTip = 'Specifies the value of the Expected Emission field.'; } field("CO2e Amount (Actual)"; Rec."CO2e Amount (Actual)") { ToolTip = 'Specifies the value of the CO2e Amount (Actual) field.'; } field("CO2e Amount (Expected)"; Rec."CO2e Amount (Expected)") { ToolTip = 'Specifies the value of the CO2e Amount (Expected) field.'; } field("Journal Batch Name"; Rec."Journal Batch Name") { ToolTip = 'Specifies the value of the Journal Batch Name field.'; } field("Document Date"; Rec."Document Date") { ToolTip = 'Specifies the value of the Document Date field.'; } field("External Document No."; Rec."External Document No.") { ToolTip = 'Specifies the value of the External Document No. field.'; } field("Document Type"; Rec."Document Type") { ToolTip = 'Specifies the value of the Document Type field.'; } field("Document Line No."; Rec."Document Line No.") { ToolTip = 'Specifies the value of the Document Line No. field.'; } field("Entry Type"; Rec."Entry Type") { ToolTip = 'Specifies the value of the Entry Type field.'; } field("Capacity Ledger Entry No."; Rec."Capacity Ledger Entry No.") { ToolTip = 'Specifies the value of the Capacity Ledger Entry No. field.'; } field("Job No."; Rec."Job No.") { ApplicationArea = Jobs; ToolTip = 'Specifies the number of the project that the value entry relates to.'; } field("Job Task No."; Rec."Job Task No.") { ApplicationArea = Jobs; ToolTip = 'Specifies the number of the related project task.'; } field(Adjustment; Rec.Adjustment) { ToolTip = 'Specifies the value of the Adjustment field.'; } field("Global Dimension 1 Code"; Rec."Global Dimension 1 Code") { ApplicationArea = Dimensions; ToolTip = 'Specifies the code for the global dimension that is linked to the record or entry for analysis purposes. Two global dimensions, typically for the company''s most important activities, are available on all cards, documents, reports, and lists.'; Visible = Dim1Visible; } field("Global Dimension 2 Code"; Rec."Global Dimension 2 Code") { ApplicationArea = Dimensions; ToolTip = 'Specifies the code for the global dimension that is linked to the record or entry for analysis purposes. Two global dimensions, typically for the company''s most important activities, are available on all cards, documents, reports, and lists.'; Visible = Dim2Visible; } field("Shortcut Dimension 3 Code"; Rec."Shortcut Dimension 3 Code") { ApplicationArea = Dimensions; ToolTip = 'Specifies the code for Shortcut Dimension 3, which is one of dimension codes that you set up in the General Ledger Setup window.'; Visible = Dim3Visible; } field("Shortcut Dimension 4 Code"; Rec."Shortcut Dimension 4 Code") { ApplicationArea = Dimensions; ToolTip = 'Specifies the code for Shortcut Dimension 4, which is one of dimension codes that you set up in the General Ledger Setup window.'; Visible = Dim4Visible; } field("Shortcut Dimension 5 Code"; Rec."Shortcut Dimension 5 Code") { ApplicationArea = Dimensions; ToolTip = 'Specifies the code for Shortcut Dimension 5, which is one of dimension codes that you set up in the General Ledger Setup window.'; Visible = Dim5Visible; } field("Shortcut Dimension 6 Code"; Rec."Shortcut Dimension 6 Code") { ApplicationArea = Dimensions; ToolTip = 'Specifies the code for Shortcut Dimension 6, which is one of dimension codes that you set up in the General Ledger Setup window.'; Visible = Dim6Visible; } field("Shortcut Dimension 7 Code"; Rec."Shortcut Dimension 7 Code") { ApplicationArea = Dimensions; ToolTip = 'Specifies the code for Shortcut Dimension 7, which is one of dimension codes that you set up in the General Ledger Setup window.'; Visible = Dim7Visible; } field("Shortcut Dimension 8 Code"; Rec."Shortcut Dimension 8 Code") { ApplicationArea = Dimensions; ToolTip = 'Specifies the code for Shortcut Dimension 8, which is one of dimension codes that you set up in the General Ledger Setup window.'; Visible = Dim8Visible; } } } } actions { area(navigation) { group("Ent&ry") { Caption = 'Ent&ry'; Image = Entry; action(Dimensions) { AccessByPermission = TableData Dimension = R; ApplicationArea = Dimensions; Caption = 'Dimensions'; Image = Dimensions; ShortCutKey = 'Alt+D'; ToolTip = 'View dimensions, such as area, project, or department, that are assigned to sustainability value entry.'; trigger OnAction() begin Rec.ShowDimensions(); end; } action(SetDimensionFilter) { ApplicationArea = Dimensions; Caption = 'Set Dimension Filter'; Ellipsis = true; Image = "Filter"; ToolTip = 'Limit the entries according to the dimension filters that you specify. NOTE: If you use a high number of dimension combinations, this function may not work and can result in a message that the SQL server only supports a maximum of 2100 parameters.'; trigger OnAction() begin Rec.SetFilter("Dimension Set ID", DimensionSetIDFilter.LookupFilter()); end; } } } area(processing) { action("&Navigate") { ApplicationArea = Basic, Suite; Caption = 'Find entries...'; Image = Navigate; ShortCutKey = 'Ctrl+Alt+Q'; ToolTip = 'Find entries and documents that exist for the document number and posting date on the selected document. (Formerly this action was named Navigate.)'; Visible = ShowPostedEntryActions; trigger OnAction() begin Navigate.SetDoc(Rec."Posting Date", Rec."Document No."); Navigate.Run(); end; } } area(Promoted) { group(Category_Process) { Caption = 'Process', Comment = 'Generated from the PromotedActionCategories property index 1.'; actionref("&Navigate_Promoted"; "&Navigate") { } group(Category_Category4) { Caption = 'Entry', Comment = 'Generated from the PromotedActionCategories property index 3.'; actionref(Dimensions_Promoted; Dimensions) { } actionref(SetDimensionFilter_Promoted; SetDimensionFilter) { } } } group(Category_Report) { Caption = 'Report', Comment = 'Generated from the PromotedActionCategories property index 2.'; } } } trigger OnOpenPage() begin ShowPostedEntryActions := true; SetDimVisibility(); end; trigger OnAfterGetCurrRecord() begin ShowPostedEntryActions := not (Rec.IsTemporary() and SustPreviewPostInstance.IsPreviewValueEntry(Rec."Entry No.")); end; var SustPreviewPostInstance: Codeunit "Sust. Preview Post Instance"; Navigate: Page Navigate; DimensionSetIDFilter: Page "Dimension Set ID Filter"; Dim1Visible, Dim2Visible, Dim3Visible, Dim4Visible, Dim5Visible, Dim6Visible, Dim7Visible, Dim8Visible : Boolean; ShowPostedEntryActions: Boolean; local procedure SetDimVisibility() var DimensionManagement: Codeunit DimensionManagement; begin DimensionManagement.UseShortcutDims(Dim1Visible, Dim2Visible, Dim3Visible, Dim4Visible, Dim5Visible, Dim6Visible, Dim7Visible, Dim8Visible); end;}