page 62802 OpenPoTableJobItem
{
Caption = 'Open PO Report (Job)(Item)';
PageType = List;
UsageCategory = Lists;
ApplicationArea = All;
SourceTable = OpenPoTableJobItem;
Editable = false;
SaveValues = false;
SourceTableView = sorting(/Expected Receipt Date/, /No./, INXPOLine);
layout
{
area(Content)
{
repeater(Group)
{
field(RowNo; Rec.RowNo)
{
ApplicationArea = All;
}
field(/Purchase Order/; Rec./No./)
{
ApplicationArea = All;
}
field(INXPOLine; Rec.INXPOLine)
{
ApplicationArea = All;
}
field(/Job No./; Rec./Job No./)
{
ApplicationArea = All;
}
field(Quantity; Rec.Quantity)
{
ApplicationArea = All;
Caption = 'QTY Ordered';
DecimalPlaces = 0;
}
field(/Quantity Received/; Rec./Quantity Received/)
{
ApplicationArea = All;
Caption = 'QTY Received';
DecimalPlaces = 0;
}
field(/No./; Rec./TypeNo./)
{
ApplicationArea = All;
}
field(Description; Rec.Description)
{
ApplicationArea = All;
}
field(/Promised Receipt Date/; Rec./Promised Receipt Date/)
{
ApplicationArea = All;
}
field(/Expected Receipt Date/; Rec./Expected Receipt Date/)
{
ApplicationArea = All;
StyleExpr = StyleExprTxt;
}
field(/Buy-from Vendor Name/; Rec./Buy-from Vendor Name/)
{
ApplicationArea = All;
}
field(Name; Rec.Name)
{
ApplicationArea = All;
}
field(inxPOrec; Rec./inxPOrec/)
{
ApplicationArea = All;
}
field(INXComment; Rec.INXComment)
{
ApplicationArea = All;
}
}
}
}
trigger OnOpenPage()
var
PurchaseOrderQuery: Query /openPoQueryA/;
begin
if PurchaseOrderQuery.Open() then begin
while PurchaseOrderQuery.Read() do begin
Rec.Init();
Rec.RowNo := Rec.RowNo + 1;
Rec./No./ := PurchaseOrderQuery.PHponumber;
Rec.INXPOLine := PurchaseOrderQuery.PLlinenumber;
Rec./Buy-from Vendor Name/ := PurchaseOrderQuery.PHvendor;
Rec.Description := PurchaseOrderQuery.PLlinedesc;
Rec.INXComment := PurchaseOrderQuery.PLcomment;
Rec.inxPOrec := PurchaseOrderQuery.PLdelivered;
Rec./Promised Receipt Date/ := PurchaseOrderQuery.PLpromiseddate;
Rec./Expected Receipt Date/ := PurchaseOrderQuery.PLexpecteddate;
Rec./Job No./ := PurchaseOrderQuery.PLjobno;
Rec./TypeNo./ := PurchaseOrderQuery.PLTypeno;
Rec.Quantity := PurchaseOrderQuery.PLqtyordered;
Rec./Quantity Received/ := PurchaseOrderQuery.PLqtyreceived;
Rec.Name := PurchaseOrderQuery.REbuyer;
Rec.Insert();
end;
PurchaseOrderQuery.Close();
rec.FindFirst()
end;
end;
trigger OnAfterGetRecord()
begin
If Rec./Expected Receipt Date/ < WorkDate() then
StyleExprTxt := 'Unfavorable'
else
If Rec./Expected Receipt Date/ > WorkDate() then
StyleExprTxt := 'Favorable'
else
StyleExprTxt := 'None'
end;
var
StyleExprTxt: Text;
}