Definition at line 43 of file TemplateUtils.java.
Static Public Member Functions | |
static SimpleHash | getInputDate (int selectedDay, int selectedMonth, int selectedYear, int selectedHours, int selectedMinutes) |
Use to fill form template with day, month, year, hour, minute combo box. | |
static SimpleHash | getInputDuration (int selectedHours, int selectedMinutes, int maxHour) |
static String | format (int value) |
static SimpleList | fillFormPopUpWithLabel (Array labelArray, String selectedId) |
Use to facilitate label fields edit. |
static SimpleHash org.openmobileis.services.util.TemplateUtils.getInputDate | ( | int | selectedDay, | |
int | selectedMonth, | |||
int | selectedYear, | |||
int | selectedHours, | |||
int | selectedMinutes | |||
) | [static] |
Use to fill form template with day, month, year, hour, minute combo box.
Return a simple hash containing 5 lists: dayList, monthList, yearList, hourList and minuteList set with the date giving by parameters. Template code : <SELECT name="startDay"> <list startDate.dayList as day> <OPTION VALUE="${day.value}" <if day.select>selected</if>>${day.value}</OPTION>
</SELECT> <SELECT name="startMonth"> <list startDate.monthList as month> <OPTION VALUE="${month.value}" <if month.select>selected</if>>${month.value}</OPTION>
</SELECT> <SELECT name="startYear"> <list startDate.yearList as year> <OPTION VALUE="${year.value}" <if year.select>selected</if>>${year.value}</OPTION>
</SELECT>
Definition at line 68 of file TemplateUtils.java.
References org.openmobileis.services.util.TemplateUtils.format().
static SimpleList org.openmobileis.services.util.TemplateUtils.fillFormPopUpWithLabel | ( | Array | labelArray, | |
String | selectedId | |||
) | [static] |
Use to facilitate label fields edit.
Returnt the template simplelist to use to fill your template. Exemple of HTML template : <select name="type">
</select> generate the template list with fct.value and fct.selected. If no selectedid is available use null.
labelArray | : list of label to display in the list. | |
selectedId | : default label to show in the list. |
Definition at line 182 of file TemplateUtils.java.
References org.openmobileis.common.util.collection.Array.get(), and org.openmobileis.common.util.collection.Array.size.