// Load the jQuery Header application.ADF.scripts.loadJQuery(noConflict=true); // Variable for the version of the field - Display in Props UI. fieldVersion = "2.0.4"; // initialize some of the attributes variables typeid = attributes.typeid; prefix = attributes.prefix; formname = attributes.formname; currentValues = attributes.currentValues; // START - Build Date picker type list pickerArray = ArrayNew(1); pickerType = StructNew(); pickerType.displayName = "jQueryUI datepicker"; pickerType.name = "UIdatepicker"; arrayAppend(pickerArray,pickerType); pickerType = StructNew(); pickerType.displayName = "datepick"; pickerType.name = "datepick"; arrayAppend(pickerArray,pickerType); // END - Build Date picker type list // START - Build Date Field Time Type Options standardizedTimeOption = StructNew(); standardizedTimeOption['start'] = "00:00:00"; standardizedTimeOption['end'] = "23:59:59"; standardizedTimeOption['now'] = "{current-time}"; standardizedTimeOption['other'] = ""; // END - Build Date Field Time Type Options // Setup the default values defaultValues = StructNew(); defaultValues.fldID = ""; defaultValues.uiTheme = "ui-lightness"; defaultValues.displayType = pickerArray[1].name; defaultValues.fldIcon = "none"; //option: calendar defaultValues.fldClearDate = 'no'; defaultValues.fldIconImg = "/ADF/extensions/customfields/date_picker/ui_calendar.gif"; defaultValues.standardizedTimeType = "start"; defaultValues.standardizedTimeStr = standardizedTimeOption[defaultValues.standardizedTimeType]; // Default is for start dates: 00:00:00 - For end dates use: 23:59:59 defaultValues.jsDateMask = "m/d/yy"; defaultValues.cfDateMask = "M/D/YYYY"; //-- App Override Variables --// defaultValues.appBeanName = ""; defaultValues.appPropsVarName = ""; // This will override the current values with the default values. // In normal use this should not need to be modified. defaultValueArray = StructKeyArray(defaultValues); for(i=1;i<=ArrayLen(defaultValueArray);i++){ // If there is a default value to exists in the current values // AND the current value is an empty string // OR the default value does not exist in the current values if( ( StructKeyExists(currentValues, defaultValueArray[i]) AND (NOT LEN(currentValues[defaultValueArray[i]])) ) OR (NOT StructKeyExists(currentValues, defaultValueArray[i])) ){ currentValues[defaultValueArray[i]] = defaultValues[defaultValueArray[i]]; } }
Field ID:
Please enter the field ID to be used via JavaScript. If blank, will use default CS field name.

Display Type:
UI Theme:
JS Display Format:
CF Display Format:
Standardized Time Type: checked>    checked>    checked>
Standardized Time:
Since CS Date fields store a date/time string (YYYY-MM-DD HH:MM:SS) we generally want to capture the start of the day time '00:00:00' for Start Dates and capture end of the day time '23:59:59' for End Dates. But this value can be any valid time string.
Show icon next to Field: checked>    checked>
Show Clear Date Link: checked>   checked>

Optional ADF App PROPS Override Settings:
(IMPORTANT: If configured correctly these settings will override the entries above!)
App Bean Name:
Please enter the ADF Applications's AppName to override these configuration settings.
App Props Variable Name:
Please enter the App Props Variable name that contains PROPS keys and values to override.

ADF Custom Field v#fieldVersion#