Date recorded = new Date();
final List<ObservationModel> addList = new ArrayList<ObservationModel>(2);
if (model.getHeight() != null) {
ObservationModel observation = new ObservationModel();
observation.setKarte(context.getKarte());
observation.setCreator(Project.getUserModel());
observation.setObservation(IInfoModel.OBSERVATION_PHYSICAL_EXAM);
observation.setPhenomenon(IInfoModel.PHENOMENON_BODY_HEIGHT);
observation.setValue(model.getHeight());
observation.setUnit(IInfoModel.UNIT_BODY_HEIGHT);
observation.setConfirmed(confirmed); // 確定(同定日)
observation.setStarted(confirmed); // 適合開始日
observation.setRecorded(recorded); // 記録日
observation.setStatus(IInfoModel.STATUS_FINAL);
//observation.setMemo(model.getMemo());
addList.add(observation);
}
if (model.getWeight() != null) {
ObservationModel observation = new ObservationModel();
observation.setKarte(context.getKarte());
observation.setCreator(Project.getUserModel());
observation.setObservation(IInfoModel.OBSERVATION_PHYSICAL_EXAM);
observation.setPhenomenon(IInfoModel.PHENOMENON_BODY_WEIGHT);
observation.setValue(model.getWeight());
observation.setUnit(IInfoModel.UNIT_BODY_WEIGHT);
observation.setConfirmed(confirmed); // 確定(同定日)
observation.setStarted(confirmed); // 適合開始日
observation.setRecorded(recorded); // 記録日
observation.setStatus(IInfoModel.STATUS_FINAL);
//observation.setMemo(model.getMemo());
addList.add(observation);
}
if (addList.size() == 0) {