scheduleId = RequestUtils.getMetricId(request);
}
MeasurementScheduleManagerLocal scheduleManager = LookupUtil.getMeasurementScheduleManager();
MeasurementBaseline metricValue = new MeasurementBaseline();
MeasurementSchedule schedule = scheduleManager.getScheduleById(subject, scheduleId);
if ((schedule != null) && (schedule.getBaseline() != null)) {
metricValue = schedule.getBaseline();
} else {
log.info(" the measurement object does not have a baseline set");
}
// XXX: temporary settings
editForm.setFromDate(metricValue.getComputeTime().getTime());
editForm.setToDate(metricValue.getComputeTime().getTime());
editForm.setNumOfPts((long) 1);
editForm.setMean(metricValue.getMean());
editForm.setMetricName(RequestUtils.getStringParameter(request, ParamConstants.METRIC_NAME_PARAM));
editForm.setOldMode(RequestUtils.getStringParameter(request, "oldMode"));
log.debug("in editMetricBaseline form prepare action");
request.setAttribute("BaselineValue", editForm);
return null;