infor.com
concierge
infor u
developer portal
Home
Developer Community
General Developer Forum
Extensibility Framework - how do I get the current user to move the UserID to custom field
unknown
Extensibility Framework - how do I get the current user to move the UserID to custom field
Find more posts tagged with
UI Design
Accepted answers
unknown
Hi Jacquie,
To get the user you need to use EAM.AppData.getInstallParams().get("user");
Here is an example where it's stored in a variable:
var vUser = EAM.AppData.getInstallParams().get("user");
Is this what you were looking for?
All comments
unknown
Hi Jacquie,
To get the user you need to use EAM.AppData.getInstallParams().get("user");
Here is an example where it's stored in a variable:
var vUser = EAM.AppData.getInstallParams().get("user");
Is this what you were looking for?
unknown
perfect - thank you
unknown
Veronique,
I am now trying to to move the Current Date to custom date field. How do I get the current date? Is ther a list of values / installparameters that I can pull from?
Thanks in advance
unknown
Hi Jacquie,
We are an international company with organizations is various time zones, so this had to be a consideration when retrieving a user's organization date/time.
Maybe there is a better option but, so far, we used a function that calls a grid of type Alert Management that does the following query:
select org_code org_code, O7GTTIME(ORG_CODE) org_date FROM r5organization WHERE org_code = 'OurOrgCode'
In the function that gets the formatted date from the DB we have a request that looks like this:
response = EAM.Ajax.request({
url: 'GRIDDATA',
params: {
GRID_NAME: 'THENAMEOFOURGRID',
REQUEST_TYPE: 'LIST.HEAD_DATA.STORED',
LOV_ALIAS_NAME_1: 'pOrg',
LOV_ALIAS_VALUE_1: pOrgValue,
LOV_ALIAS_TYPE_1: '',
},
async: false,
method: 'POST'
});
if (response && response.success !== false) {
var gridresult = response.responseData.pageData.grid.GRIDRESULT.GRID;
var vDateOrg = EAM.Date.parseDate(gridresult.DATA[0].org_date);
}
It's possible that the dates you work with are not in the same format.
We have also, when needed, formatted dates with the following:
var vDateFormatted = Ext.util.Format.date(vDate, Ext.Date.defaultFormat + " H:i");
There is also an install parameter for language but I did not see anything for a user's org date/time.
EAM.AppData.getInstallParams().get("language")
Maybe someone else has a different idea?
Hope this helps!
Quick Links
Developer Community
Infor OS Platform Forums
Hackathon
Developer Portal
Developer Newsletter