Skip to Main Content

APEX

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Interested in getting your voice heard by members of the Developer Marketing team at Oracle? Check out this post for AppDev or this post for AI focus group information.

GetRecordMetadat.fields gets only hidden columns in Interactive Grid

HansMueller69Oct 22 2023

Hello

I need your help, I develop an application on the Apex Version 23.1. Latest Patchset at 22.10.2023.

I want to use the “highlight” Option on fields of getRecordMetadata.

My aim is to use for example: the v_cols.ID.highlight = “css_changed”

You can reproduce the problem too:

  • Create in your application a new page
  • Put an Interactive Grid into the Body and set the static id to IG_TEST
  • Choose a table as Source-Object directly (No SQL or PLSQL)
  • Put a Button and create a DA with this :
var ig$ = apex.region("IG_TEST").widget();
var grid = ig$.interactiveGrid("getViews", "grid");
var model = grid.model;
grid.model.forEach(function(record, index, id) 
{
   var v_cols = model.getRecordMetadata(id).fields;
   for (var fieldName in v_cols) {
        console.log("Field Name: " + fieldName);
   }
});

Problem: ONLY the HIDDEN Columns are listed out! If there is no hidden column, in this case it does nothing.

I spent many hours to solve the Problem, I set static id to the Columns, I put the primary key column to the first position, but nothing helps.

Could you please help me to say what i am doing wrong?

Thank you best Regards

This post has been answered by Karel Ekema on Oct 23 2023
Jump to Answer
Comments
Post Details
Added on Oct 22 2023
6 comments
660 views