I'm creating a form based on the SAP standard Adobe form F140_CUS_STAT_01.
In the "Document" column I have the requirement to display field REBZG if it contains a value, or BELNR if not.
I have done the following:
if ( data.CustomerStatement.ItemTable.TableOpenItem.REBZG.rawValue == null ||
data.CustomerStatement.ItemTable.TableOpenItem.REBZG.rawValue == '' )
{ data.CustomerStatement.ItemTable.TableOpenItem.REBZG.rawValue =
data.CustomerStatement.ItemTable.TableOpenItem.BELNR.rawValue; }
BELNR is a hidden field in TableOpenItem
Unfortunately nothing happens.
Is there something wrong with my syntax?; Should I be using a specific event? Do I have to treat the internal table fields differently?
Also, how do I debug javascript in the SAP context. I have tried both "Alert" and print to console, but neither has any effect.