public class FldCommonActualDate extends MboValueAdapter
// EnterDate is set with validation so Fin.Period is filled. try { setValue("EnterDate", transDate, NOACCESSCHECK); } catch (MXException mxe) { if (mxe.getErrorGroup().equalsIgnoreCase("common") && mxe.getErrorGroup().equalsIgnoreCase("NotValidActualDate")) { // could find a valid fin. period // clear the field and let the user figure it out setValueNull("EnterDate", NOACCESSCHECK) ; } else { // don't recognize this error, pass it up. throw mxe; } }
mboValue
TYPE_DOMAIN, TYPE_FIELDCLASS, TYPE_KEY, TYPE_UNKNOWN
ALLROWS, CHANGEDBY_USER, COUNT_ADDITIONS, COUNT_AFTERSAVE, COUNT_DATABASE, COUNT_DELETED, COUNT_EXISTING, DBCONFIG, DELAYVALIDATION, DELAYVALIDATIONONLY, DISCARDABLE, GOTCOMPLETEWHERE, HIDDEN, NO_RELATEDMBOS_OF_OWNERSCHILDREN_FETCH, NOACCESSCHECK, NOACTION, NOADD, NOCOMMIT, NODELETE, NONE, NOOVERWRITE, NOSAVE, NOSETVALUE, NOUPDATE, NOVALIDATION, NOVALIDATION_AND_NOACTION, NOVALIDATION_AND_NOACTION_ALLOWCROSSOVER, READONLY, REBUILD, REQUIRED, SAMEVALUEVALIDATION, SETBYPARENT, USER
Constructor and Description |
---|
FldCommonActualDate(MboValue mbv)
This constructor assumes the name of the financial period
attribute is FinancialPeriod.
|
FldCommonActualDate(MboValue mbv,
java.lang.String fpName)
Construct and attach to the mbo value
|
Modifier and Type | Method and Description |
---|---|
void |
action()
Set the fin.
|
void |
validate()
See if a financial period corresponds to the date given.
|
getAppLink, getIntegrationService, getList, getLookupName, getMatchingAttr, getMatchingAttr, getMboValue, getMboValue, getType, hasList, init, initValue, setType, setValueFromLookup, smartFill, smartFind, smartFind
public FldCommonActualDate(MboValue mbv, java.lang.String fpName)
mbv
- fpName
- The name of the finanical period attribute.public FldCommonActualDate(MboValue mbv)
public void validate() throws MXException, java.rmi.RemoteException
validate
in interface MboValueListener
validate
in class MboValueAdapter
MXException
- Group "common", Key "NotValidActualDate" if no valid fin. period found.java.rmi.RemoteException
public void action() throws MXException, java.rmi.RemoteException
action
in interface MboValueListener
action
in class MboValueAdapter
MXException
java.rmi.RemoteException