use of com.netsteadfast.greenstep.vo.PerspectiveVO in project bamboobsc by billchen198318.
the class RegionMapRelationKpisAction method fillCharts.
private void fillCharts(BscStructTreeObj treeObj) throws Exception {
List<VisionVO> visions = treeObj.getVisions();
for (VisionVO vision : visions) {
List<String> names = new LinkedList<String>();
List<Float> values = new LinkedList<Float>();
List<String> colors = new LinkedList<String>();
for (PerspectiveVO perspective : vision.getPerspectives()) {
names.add(perspective.getName() + "(" + BscReportSupportUtils.parse2(perspective.getScore()) + ")");
values.add(perspective.getScore());
colors.add(perspective.getBgColor());
}
this.barUploadOids.add(JFreeChartDataMapperUtils.createBarData(vision.getTitle(), "Score", "", names, values, colors, 480, 280, false));
this.pieUploadOids.add(JFreeChartDataMapperUtils.createPieData(vision.getTitle(), names, values, colors, 480, 280));
}
}
use of com.netsteadfast.greenstep.vo.PerspectiveVO in project bamboobsc by billchen198318.
the class PerspectiveManagementAction method loadPerspectiveData.
private void loadPerspectiveData() throws ServiceException, Exception {
this.transformFields2ValueObject(this.perspective, new String[] { "oid" });
DefaultResult<PerspectiveVO> result = this.perspectiveService.findObjectByOid(this.perspective);
if (result.getValue() == null) {
throw new ServiceException(result.getSystemMessage().getValue());
}
this.perspective = result.getValue();
this.getFields().put("visionSelectValue", Constants.HTML_SELECT_NO_SELECT_ID);
VisionVO vision = new VisionVO();
vision.setVisId(this.perspective.getVisId());
DefaultResult<VisionVO> vResult = this.visionService.findForSimpleByVisId(vision.getVisId());
if (vResult.getValue() != null) {
this.getFields().put("visionSelectValue", vResult.getValue().getOid());
}
}
use of com.netsteadfast.greenstep.vo.PerspectiveVO in project bamboobsc by billchen198318.
the class StrategyMapManagementAction method loadObjectiveItem.
private void loadObjectiveItem() throws ControllerException, ServiceException, Exception {
// 這裡的 fields.oid 放的是 BB_OBJECTIVE.OBJ_ID
String objId = super.defaultString(super.getFields().get("oid")).trim();
if (StringUtils.isBlank(objId)) {
throw new ControllerException(SysMessageUtil.get(GreenStepSysMsgConstants.PARAMS_BLANK));
}
this.objective = new ObjectiveVO();
this.objective.setObjId(objId);
DefaultResult<ObjectiveVO> result = this.objectiveService.findByUK(this.objective);
if (result.getValue() == null) {
throw new ServiceException(result.getSystemMessage().getValue());
}
this.objective = result.getValue();
PerspectiveVO perspective = new PerspectiveVO();
perspective.setPerId(this.objective.getPerId());
DefaultResult<PerspectiveVO> pResult = this.perspectiveService.findByUK(perspective);
if (pResult.getValue() == null) {
throw new ServiceException(pResult.getSystemMessage().getValue());
}
perspective = pResult.getValue();
DefaultResult<VisionVO> vResult = this.visionService.findForSimpleByVisId(perspective.getVisId());
if (vResult.getValue() == null) {
throw new ServiceException(vResult.getSystemMessage().getValue());
}
VisionVO vision = vResult.getValue();
this.visionOid = vision.getOid();
}
use of com.netsteadfast.greenstep.vo.PerspectiveVO in project bamboobsc by billchen198318.
the class ScorecardQueryContentAction method loadPerspectiveCardContent.
private void loadPerspectiveCardContent() throws ServiceException, Exception {
StringBuilder outContent = new StringBuilder();
this.message = SysMessageUtil.get(GreenStepSysMsgConstants.SEARCH_NO_DATA);
String uploadOid = this.getFields().get("uploadOid");
VisionVO vision = BscMobileCardUtils.getVisionCardFromUpload(uploadOid);
this.rootVision = vision;
List<PerspectiveVO> perspectives = vision.getPerspectives();
for (PerspectiveVO perspective : perspectives) {
outContent.append(BscMobileCardUtils.getPerspectivesCardContent(uploadOid, perspective));
outContent.append(super.getHtmlBr());
}
this.content = outContent.toString();
if (!StringUtils.isBlank(content)) {
this.loadColor();
this.message = this.getText("MESSAGE.ScorecardQueryContentAction_06");
this.success = IS_YES;
}
}
use of com.netsteadfast.greenstep.vo.PerspectiveVO in project bamboobsc by billchen198318.
the class ScorecardQueryContentAction method loadObjectiveCardContent.
private void loadObjectiveCardContent() throws ServiceException, Exception {
StringBuilder outContent = new StringBuilder();
this.message = SysMessageUtil.get(GreenStepSysMsgConstants.SEARCH_NO_DATA);
String uploadOid = this.getFields().get("uploadOid");
String perspectiveOid = super.defaultString(this.getFields().get("perspectiveOid"));
VisionVO vision = BscMobileCardUtils.getVisionCardFromUpload(uploadOid);
List<PerspectiveVO> perspectives = vision.getPerspectives();
for (PerspectiveVO perspective : perspectives) {
if (perspectiveOid.equals(perspective.getOid())) {
this.rootPerspective = perspective;
List<ObjectiveVO> objectives = perspective.getObjectives();
for (ObjectiveVO objective : objectives) {
outContent.append(BscMobileCardUtils.getObjectivesCardContent(uploadOid, objective));
outContent.append(super.getHtmlBr());
}
}
}
this.content = outContent.toString();
if (!StringUtils.isBlank(content)) {
this.loadColor();
this.message = this.getText("MESSAGE.ScorecardQueryContentAction_06");
this.success = IS_YES;
}
}
Aggregations