=load( local!pagingInfo:a!pagingInfo( startIndex: 1, batchSize: local!selectGrid, sort: a!sortInfo( field: "dataCorrectionRequestIdentifier", ascending: true() ) ), local!gridSelection: a!gridSelection( pagingInfo:local!pagingInfo ), with( local!datasubset: if(rule!PFDC_isBlank(local!poDataToLoad),{},local!poDataToLoad), { a!sectionLayout( label: "", firstColumnContents: { a!dateField( label: "From:", labelPosition: cons!PFDC_LABELPOSITION, value: ri!searchPFDC.DCCreatedFromDT, saveInto: ri!searchPFDC.DCCreatedFromDT ), a!dateField( label: "To:", labelPosition: cons!PFDC_LABELPOSITION, value: ri!searchPFDC.DCCreatedToDT, saveInto: ri!searchPFDC.DCCreatedToDT ), a!textField( label: "Freddie Mac Loan Number:", labelPosition: cons!PFDC_LABELPOSITION, align: "LEFT", value: ri!searchPFDC.fmLoanNumber, saveInto: ri!searchPFDC.fmLoanNumber ) }, secondcolumncontents: {} ), a!sectionLayout( label: "", firstColumnContents: { a!buttonLayout( primarybuttons: { a!buttonWidget( label: "Search ", validate: true(), validationGroup: "searchPFDC", value: "searchPFDC", saveInto: {local!searchAction, a!save(local!loanCount,0), a!save(local!selectedLoans,null), a!save(local!gridSelection.selected,null), a!save(local!poDataToLoad,rule!TestEntity(ri!searchPFDC,local!pagingInfo) ) } ) } ) }, secondColumnContents: {} ), if( local!searchAction = "searchPFDC", { a!gridField( label: "", instructions: "Total Selected :" & local!loanCount, totalCount: local!datasubset.totalCount, columns: { a!gridTextColumn( label: "Primary Borrower Last Name", field: "primaryBorrowerLastName", data: index( local!datasubset.data, "primaryBorrowerLastName", {} ) ), a!gridTextColumn( label: "Data Correction Identifier", field: "dataCorrectionRequestIdentifier", data: index( local!datasubset.data, "dataCorrectionRequestIdentifier", {} ) ), a!gridTextColumn( label: "Data Correction Creation Date", field: "requestCreateDateTime", data: index( local!datasubset.data, "requestCreateDateTime", {} ) ) }, identifiers: index( local!datasubset.data, "dataCorrectionRequestIdentifier", {} ), value: local!gridSelection, saveInto: { local!gridSelection }, selection: true ) }, {} ) } ) )