- This topic has 2 replies, 2 voices, and was last updated 7 years, 1 month ago by .
Viewing 3 posts - 1 through 3 (of 3 total)
Viewing 3 posts - 1 through 3 (of 3 total)
- You must be logged in to reply to this topic.
Integrated Application Platform
Integrated Application Platform › Forums › General › Browse display columns
Controller
{
New()
{
super(.layout())
.Data.Set(Record()) // otherwise rules don’t work
.browse = .Data.Vert.Browse
.browse.SetReadOnly(true)
.data = .Data.Get()
.data.Observer(.Record_changed)
//default filter on date…
.Data.SetField(‘shiprel_date’ Object(operation: ‘equals’, value: Date(), value2: “”))
.Load_list(false)
}
query: ‘shiprel rename shiprel_num to shiprel_num_new, shiprel_status to shiprel_status_default’
layout()
{
return Object(‘Record’ Object(‘Vert’
Object(‘CenterTitle’, ‘Load Releases’)
#(Skip 5)
#(Form
(ParamsSelect shiprel_date, group: 0) (ParamsSelect shiprel_status, group: 1) nl
(ParamsSelect shipcust_num, group: 0) nl
(ParamsSelect shipprod_num, group: 0) nl
)
‘Skip’
Object(‘Browse’
“”,
columns: .Columns(),
//validField: ‘ardbpay_valid’,
statusBar:,
columnsSaveName: “Releases – Browse”
)
#(Skip 5)
#(Horz (Button ‘Access’))
#(Skip 5)
))
}
Columns()
{
//cols = Object(‘shipprod_name’, ‘shipprod_abbrev’,
// ‘shipprod_status_default’)
cols = #(shiprel_date, shipprod_num, shipcust_num, shipcontact_num)
//Alert(cols)
return cols
}
The browse returns all the columns, and not only those of Columns(). I must be missing something here. Any ideas please? Thanks
If you are calling SetQuery in your Load_list method, you need to pass the columns (since they could be different for the new query) otherwise they will default to all.
Thank you Andrew. Passing the columns with SetQuery did it.