class IEDeliveryDateReportController extends SrsReportRunController
{
}
protected void PrePromptModifyContract()
{
this.parmShowDialog(false);
this.setRange(this.parmReportContract().parmQueryContracts().lookup(this.getFirstQueryContractKey()));
}
public void setRange(Query _query)
{
RecId inventJournalTableRecId,inventJournalTransRecId;
InventJournalTable inventJournalTable;
InventJournalTrans inventJournalTrans;
if(this.parmArgs())
{
if( (this.parmArgs().record().TableId) == tableNum(InventJournalTable))
{
inventJournalTable = this.parmArgs().record() as InventJournalTable;
inventJournalTableRecId = inventJournalTable.RecId;
}
if( (this.parmArgs().record().TableId) == tableNum(InventJournalTrans))
{
inventJournalTrans = this.parmArgs().record() as InventJournalTrans;
inventJournalTableRecId = inventJournalTrans.RecId;
}
}
if (inventJournalTableRecId)
{
SysQuery::findOrCreateRange(_query.dataSourceTable(tableNum(InventJournalTable)),fieldNum(InventJournalTable, RecId)).value(SysQuery::value(inventJournalTableRecId));
}
if (inventJournalTransRecId)
{
SysQuery::findOrCreateRange(_query.dataSourceTable(tableNum(InventJournalTrans)),fieldNum(InventJournalTrans, RecId)).value(SysQuery::value(inventJournalTransRecId));
}
}
No comments:
Post a Comment