Page 33 Customer Lookup, source in 29
Source29
src/Layers/W1/BaseApp/Sales/Customer/CustomerLookup.Page.al240 lines, Copyright (c) Microsoft Corporation. MIT
// ------------------------------------------------------------------------------------------------
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
// ------------------------------------------------------------------------------------------------
namespace Microsoft.Sales.Customer;
/// <summary>
/// Provides a simplified lookup page for selecting customers with essential fields.
/// </summary>
page 33 "Customer Lookup"
{
Caption = 'Customers';
CardPageID = "Customer Card";
Editable = false;
PageType = List;
SourceTable = Customer;
layout
{
area(content)
{
repeater(Group)
{
field("No."; Rec."No.")
{
ApplicationArea = All;
}
field(Name; Rec.Name)
{
ApplicationArea = All;
}
field("Responsibility Center"; Rec."Responsibility Center")
{
ApplicationArea = Basic, Suite;
}
field(BillToCustomerNo; Rec."Bill-to Customer No.")
{
ApplicationArea = Basic, Suite;
Visible = false;
}
field("Location Code"; Rec."Location Code")
{
ApplicationArea = Location;
}
field("Post Code"; Rec."Post Code")
{
ApplicationArea = All;
}
field(Address; Rec.Address)
{
ApplicationArea = All;
}
field(City; Rec.City)
{
ApplicationArea = All;
Visible = false;
}
field("Country/Region Code"; Rec."Country/Region Code")
{
ApplicationArea = Basic, Suite;
Visible = false;
}
field("Phone No."; Rec."Phone No.")
{
ApplicationArea = All;
}
field(Contact; Rec.Contact)
{
ApplicationArea = All;
}
field(Email; Rec."E-Mail")
{
ApplicationArea = All;
}
field("IC Partner Code"; Rec."IC Partner Code")
{
ApplicationArea = Intercompany;
Visible = false;
}
field("Salesperson Code"; Rec."Salesperson Code")
{
ApplicationArea = Suite;
}
field(RegistrationNumber; Rec."Registration Number")
{
ApplicationArea = All;
}
field("VAT Registration No."; Rec."VAT Registration No.")
{
ApplicationArea = All;
}
field("Customer Posting Group"; Rec."Customer Posting Group")
{
ApplicationArea = Basic, Suite;
Visible = false;
}
field("Gen. Bus. Posting Group"; Rec."Gen. Bus. Posting Group")
{
ApplicationArea = Basic, Suite;
Visible = false;
}
field("VAT Bus. Posting Group"; Rec."VAT Bus. Posting Group")
{
ApplicationArea = Basic, Suite;
Visible = false;
}
field("Customer Price Group"; Rec."Customer Price Group")
{
ApplicationArea = Basic, Suite;
Visible = false;
}
field("Customer Disc. Group"; Rec."Customer Disc. Group")
{
ApplicationArea = Basic, Suite;
Visible = false;
}
field("Payment Terms Code"; Rec."Payment Terms Code")
{
ApplicationArea = Basic, Suite;
Visible = false;
}
field("Reminder Terms Code"; Rec."Reminder Terms Code")
{
ApplicationArea = Suite;
Visible = false;
}
field("Fin. Charge Terms Code"; Rec."Fin. Charge Terms Code")
{
ApplicationArea = Suite;
Visible = false;
}
field("Currency Code"; Rec."Currency Code")
{
ApplicationArea = Suite;
Visible = false;
}
field("Language Code"; Rec."Language Code")
{
ApplicationArea = Basic, Suite;
Visible = false;
}
field("Search Name"; Rec."Search Name")
{
ApplicationArea = Basic, Suite;
Visible = false;
}
field("Credit Limit (LCY)"; Rec."Credit Limit (LCY)")
{
ApplicationArea = Basic, Suite;
Visible = false;
}
field(Blocked; Rec.Blocked)
{
ApplicationArea = Basic, Suite;
Visible = false;
}
field("Privacy Blocked"; Rec."Privacy Blocked")
{
ApplicationArea = Basic, Suite;
Visible = false;
}
field("Last Date Modified"; Rec."Last Date Modified")
{
ApplicationArea = Basic, Suite;
Visible = false;
}
field("Application Method"; Rec."Application Method")
{
ApplicationArea = Basic, Suite;
Visible = false;
}
field("Combine Shipments"; Rec."Combine Shipments")
{
ApplicationArea = Basic, Suite;
Visible = false;
}
field(Reserve; Rec.Reserve)
{
ApplicationArea = Reservation;
Visible = false;
}
field("Ship-to Code"; Rec."Ship-to Code")
{
ApplicationArea = Basic, Suite;
Visible = false;
}
field("Shipping Advice"; Rec."Shipping Advice")
{
ApplicationArea = Basic, Suite;
Visible = false;
}
field("Shipping Agent Code"; Rec."Shipping Agent Code")
{
ApplicationArea = Suite;
Visible = false;
}
}
}
}
actions
{
area(navigation)
{
action(CustomerList)
{
ApplicationArea = All;
Caption = 'Advanced View';
Image = CustomerList;
ToolTip = 'Open the Customers page showing all possible columns. ';
trigger OnAction()
var
CustomerList: Page "Customer List";
begin
CustomerList.SetTableView(Rec);
CustomerList.SetRecord(Rec);
CustomerList.LookupMode := true;
if CustomerList.RunModal() = ACTION::LookupOK then begin
CustomerList.GetRecord(Rec);
CurrPage.Close();
end;
end;
}
}
area(Promoted)
{
group(Category_Process)
{
Caption = 'Process';
actionref(CustomerList_Promoted; CustomerList)
{
}
}
}
}
}