Specific Scheduled Outages inserts month shortcut as Roman number and after clicking on Finish web application returns error
Description
Environment
Acceptance / Success Criteria
is duplicated by
Lucidchart Diagrams
Activity
Jan Papež March 10, 2010 at 11:28 AM
thank you very much
(In reply to comment #5)
> this got merged to the 1.6.10 branch, marking as verified
>
Benjamin Reed March 8, 2010 at 11:26 AM
this got merged to the 1.6.10 branch, marking as verified
Seth Leger (community account) March 4, 2010 at 2:53 PM
has been marked as a duplicate of this bug. ***
Jan Papež March 4, 2010 at 1:24 AM
Thank you.
Will the fix be included in version 1.6.x too?
Seth Leger (community account) March 3, 2010 at 4:19 PM
We need to force the form value to always output in Locale.US, I'll apply the following change to "master" for inclusion in 1.7:
diff --git a/opennms-webapp/src/main/webapp/admin/sched-outages/editoutage.jsp b/opennms-webapp/src/main/webapp/admin/sched-outages/editoutage.jsp
index dac6ffb..9eef02c 100644
— a/opennms-webapp/src/main/webapp/admin/sched-outages/editoutage.jsp
+++ b/opennms-webapp/src/main/webapp/admin/sched-outages/editoutage.jsp
@@ -46,7 +46,7 @@
private static String getMonthSelectField(String name, int month) {
StringBuffer sb = new StringBuffer();
sb.append("<select name=\"").append(name).append("\">");
SimpleDateFormat shortDF = new SimpleDateFormat("MMM");
+ SimpleDateFormat shortDF = new SimpleDateFormat("MMM", Locale.US);
SimpleDateFormat longDF = new SimpleDateFormat("MMMM");
for (int mon = 0; mon < 12; mon++) {
Date tempDate = new GregorianCalendar(0, mon, 1).getTime();
Details
Assignee
OpenNMS Bug Mailing ListOpenNMS Bug Mailing ListReporter
Jan PapežJan PapežComponents
Fix versions
Affects versions
Priority
Major
Details
Details
Assignee
Reporter
Components
Fix versions
Affects versions
Priority
PagerDuty
PagerDuty Incident
PagerDuty
PagerDuty Incident
PagerDuty

If I insert new Specific Scheduled Outage (Admin > Scheduled Outages > Add New Outage), fillup all form and click on Finish, Web Administration returns error: http://paste.lisp.org/display/82548
from the IRC:
<honyczek> you wanna say, that it causes my localisation?
<honyczek> but i'm not using roman numbers in dates
<Drak0nfly> why does it show as 27-VI-2009 then?
<Drak0nfly> i thought you typed it that way
<honyczek> no, i selected "cerven" (in czech Jun) from dropdown menu (<select>)
<honyczek> <select name="chooseStartMonth"><option value="I" >leden</option>.....<option value="VI" selected>?erven</option>
<McFly> hehe, ouch
<honyczek> it's source code of administration console - edit scheduled outage
<sartin> honyczek: Gimme a moment, I'll take a look
<Drak0nfly> hah
...
<sartin> honyczek: Well that drop down is populated using SimpleDateFormat, which respects your locale (so you get the czech date format)
<sartin> honyczek: can you lisppaste the whole error?
...
<sartin> honyczek Yeah, paste it into pastebin.
<honyczek> huh, where?
<sartin> ~tell honyczek about pastebin
<_sndbot> honyczek, pastebin is http://paste.lisp.org/new/opennms
...
<lisppaste7> honyczek pasted "Edit Scheduled Outages Error" at http://paste.lisp.org/display/82548
...
<sartin> honyczek: I think that's a bug.
<honyczek> I think so