/** * Constructor. * @param record The parent record. * @param strName The field name. * @param iDataLength The maximum string length (pass -1 for default). * @param strDesc The string description (usually pass null, to use the resource file desc). * @param strDefault The default value (if object, this value is the default value, if string, the string is the default). */ public ApTrxField(Record record, String strName, int iDataLength, String strDesc, Object strDefault) { this(); this.init(record, strName, iDataLength, strDesc, strDefault); } /**
/** * Set up the default screen control for this field. * @param itsLocation Location of this component on screen (ie., GridBagConstraint). * @param targetScreen Where to place this component (ie., Parent screen or GridBagLayout). * @param converter The converter to set the screenfield to. * @param iDisplayFieldDesc Display the label? (optional). * @param properties Extra properties * @return Return the component or ScreenField that is created for this field. */ public ScreenComponent setupDefaultView(ScreenLoc itsLocation, ComponentParent targetScreen, Convert converter, int iDisplayFieldDesc, Map<String, Object> properties) { return this.setupTableLookup(itsLocation, targetScreen, iDisplayFieldDesc, this.makeReferenceRecord(), ApTrx.CODE_KEY, ApTrx.DESCRIPTION, true); }
field = new ApTrxField(this, AP_TRX_ID, Constants.DEFAULT_FIELD_LENGTH, null, null); field.setNullable(false);
field = new VendorField(this, DRAFT_VENDOR_ID, Constants.DEFAULT_FIELD_LENGTH, null, null); if (iFieldSeq == 33) field = new ApTrxField(this, PREPAYMENT_AP_TRX_ID, Constants.DEFAULT_FIELD_LENGTH, null, null); if (iFieldSeq == 34) field = new DateField(this, VOUCHER_BASED_DATE, Constants.DEFAULT_FIELD_LENGTH, null, null);
field = new TourField(this, TOUR_ID, Constants.DEFAULT_FIELD_LENGTH, null, null); if (iFieldSeq == 22) field = new ApTrxField(this, AP_TRX_ID, Constants.DEFAULT_FIELD_LENGTH, null, null); if (iFieldSeq == 23) field = new StringField(this, PRICING_DETAIL_KEY, 128, null, null);