WorkflowDocument classına aşağıdaki metodlar eklenmeli
public class yourClassName extends WorkflowDocument { } > Class metodları protected void checkContext(tableId _tableId, RecId _recId) {; if (_tableId != tablenum(DRTExpenseTable)) // Your table name { // Workflow context table id reference: %1 is not valid throw error(strfmt("@SYS107963", _tableId)); } if (_recId == 0) { // Workflow context record id is zero. throw error(strfmt("@SYS107964")); } } public PurchReqSpendingLimitValueMST parmSpendingLimit(CompanyId _companyId, tableId _tableId, RecId _recId) { YourTableName yourTableName = YourTableName::findRecId(_recID); HRPLimitTypeTable limitTypeTable; HRPLimitTableMap limitTableMap; AmountMST limitValue; ; this.checkContext(_tableId, _recId); while select limitTypeTable where limitTypeTable.LimitType == HRPLimitType::Spending && limitTypeTable.DocumentType == HRPLimitDocumentType::CustCredit { limitTableMap = HRPLimitTableRelationship::getActiveLimitEmpl(limitTypeTable.LimitId, EmplTable::userId2EmplId(yourTableName.createdBy)); limitValue = max(limitValue,Currency::mstAmount(limitTableMap.LimitValue, limitTableMap.CurrencyCode)); } return limitValue; }