hi all,
I added a new field to ProjTable, similar to the WorkerResponsibleSales field, and want it to have the same behavior.
How do I add the following codes for 'resolveReference', 'lookupReference' and 'modified' to my new field for Project form, ProjTable datasource.
Here's the codes that I found on ProjectTable.xpp:
[DataField]
class WorkerResponsibleSales
{
public Common resolveReference(FormReferenceControl _formReferenceControl)
{
HcmWorker ret;ret = super(_formReferenceControl);
if (ret.RecId && !ProjWorkerLookup::validateWorker(ret.RecId, projTable, false))
{
ret = null;
}return ret;
}public Common lookupReference(FormReferenceControl _formReferenceControl)
{
return ProjWorkerLookup::lookupWorker(_formReferenceControl, projTable, element.shouldWorkerLookupFilterToCurrentCompany());
}public void modified()
{
super();if (!projTable.editSubProj(fieldNum(ProjTable, WorkerResponsibleSales), projTable.WorkerResponsibleSales, projTable.orig().WorkerResponsibleSales))
{
projTable.WorkerResponsibleSales = projTable.orig().WorkerResponsibleSales;
}
}}
thank you,
Fen
Stay up to date on forum activity by subscribing. You can also customize your in-app and email Notification settings across all subscriptions.
André Arnaud de Cal... 291,240 Super User 2024 Season 2
Martin Dráb 230,149 Most Valuable Professional
nmaenpaa 101,156