Hello, I'm trying to make some grid calls while using the Extensibility Framework and grab some data. I found this following post and have tried to follow it as a template. However I don't get any Data when I return the 'response' object. My understanding is that this will return a response with an array of results based on the specified dataspy. Is this correct? Any help is appreciated.
Notes:
- I have tried to add the uncommented LOV_ fields to narrow the search, but I'm not 100% clear on how they work. Are they filters?
Here is my sample code:
var getGridData = function () {
try{
var response = EAM.Ajax.request({
url: 'GRIDDATA',
params: {
GRID_NAME: 'WSJOBS',
REQUEST_TYPE: 'LIST.HEAD_DATA.STORED',
DATASPY_ID: '107931',
//LOV_ALIAS_NAME_1: 'workordernum',
//LOV_ALIAS_VALUE_1: '1004085713',
//LOV_ALIAS_TYPE_1: ''
},
async: false,
method: 'POST'
});
return response;
}
catch (err) {
console.log ("ERROR: " + err);
}
}
Here is the response object I receive, there is no DATA being returned.
{success: true, response: {…}, responseData: {…}}
response: {request: constructor, requestId: 13, status: 200, statusText: "OK", getResponseHeader: ƒ, …}
responseData:
pageData:
fromCome: false
grid:
GRIDRESULT:
DATASPY: {id: "107931", label: ""}
GRID:
DATA: Array(0)
length: 0
__proto__: Array(0)
FIELDS: {viewtype: "LIST", visibleColumn: true, visiblerowcount: "", FIELD: Array(311)}
METADATA: {REQUEST_TYPE_META: "LIST.HEAD_DATA.STORED", RECORDS: "0", BLACKLISTVIOLATIONS: "0", CLIENTROWS: "50", ISSYSTEMUSER: false, …}
__proto__: Object
TOOLBAR: {FIELD: Array(4), FIELDVALUES: {…}}
type: "LIST.HEAD_DATA.STORED"
__proto__: Object
__proto__: Object
messages: null
__proto__: Object
__proto__: Object
success: true
__proto__: Object