use of com.netsteadfast.greenstep.vo.SysVO in project bamboobsc by billchen198318.
the class SystemMessageNoticeConfigManagementAction method loadSysMsgNoticeConfigData.
private void loadSysMsgNoticeConfigData() throws ServiceException, Exception {
this.transformFields2ValueObject(this.sysMsgNoticeConfig, new String[] { "oid" });
DefaultResult<SysMsgNoticeConfigVO> result = this.sysMsgNoticeConfigService.findObjectByOid(sysMsgNoticeConfig);
if (result.getValue() == null) {
throw new ServiceException(result.getSystemMessage().getValue());
}
sysMsgNoticeConfig = result.getValue();
SysVO sys = new SysVO();
sys.setSysId(sysMsgNoticeConfig.getSystem());
DefaultResult<SysVO> sysResult = this.sysService.findByUK(sys);
if (sysResult.getValue() != null) {
this.selectValue = sysResult.getValue().getOid();
}
}
use of com.netsteadfast.greenstep.vo.SysVO in project bamboobsc by billchen198318.
the class SystemTwitterManagementAction method loadSysTwitterData.
private void loadSysTwitterData() throws ServiceException, Exception {
sysTwitter.setOid(this.getFields().get("oid"));
DefaultResult<SysTwitterVO> result = this.sysTwitterService.findObjectByOid(sysTwitter);
if (result.getValue() == null) {
throw new ServiceException(result.getSystemMessage().getValue());
}
this.sysTwitter = result.getValue();
this.getFields().put("content", new String(this.sysTwitter.getContent(), "utf8"));
SysVO sys = new SysVO();
sys.setSysId(this.sysTwitter.getSystem());
DefaultResult<SysVO> sysResult = this.sysService.findByUK(sys);
if (sysResult.getValue() == null) {
throw new ServiceException(sysResult.getSystemMessage().getValue());
}
sys = sysResult.getValue();
this.getFields().put("systemOid", sys.getOid());
}
use of com.netsteadfast.greenstep.vo.SysVO in project bamboobsc by billchen198318.
the class SystemTwitterSaveOrUpdateAction method save.
private void save() throws ControllerException, AuthorityException, ServiceException, Exception {
this.checkFields();
SysVO sys = this.findSys();
SysTwitterVO sysTwitter = new SysTwitterVO();
sysTwitter.setSystem(sys.getSysId());
sysTwitter.setTitle(this.getFields().get("title"));
sysTwitter.setEnableFlag(("true".equals(this.getFields().get("enableFlag")) ? YesNo.YES : YesNo.NO));
sysTwitter.setContent(this.getFields().get("content").getBytes());
DefaultResult<SysTwitterVO> result = this.sysTwitterService.saveObject(sysTwitter);
this.message = result.getSystemMessage().getValue();
if (result.getValue() != null) {
this.success = IS_YES;
}
}
use of com.netsteadfast.greenstep.vo.SysVO in project bamboobsc by billchen198318.
the class SystemTwitterSaveOrUpdateAction method findSys.
private SysVO findSys() throws ServiceException, Exception {
SysVO sys = new SysVO();
sys.setOid(this.getFields().get("systemOid"));
DefaultResult<SysVO> result = this.sysService.findObjectByOid(sys);
if (result.getValue() == null) {
throw new ServiceException(result.getSystemMessage().getValue());
}
sys = result.getValue();
return sys;
}
use of com.netsteadfast.greenstep.vo.SysVO in project bamboobsc by billchen198318.
the class SystemWsConfigManagementAction method loadSysWsConfigData.
private void loadSysWsConfigData() throws ServiceException, Exception {
this.transformFields2ValueObject(this.sysWsConfig, new String[] { "oid" });
DefaultResult<SysWsConfigVO> result = this.sysWsConfigService.findObjectByOid(sysWsConfig);
if (result.getValue() == null) {
throw new ServiceException(result.getSystemMessage().getValue());
}
this.sysWsConfig = result.getValue();
SysVO sys = new SysVO();
sys.setSysId(this.sysWsConfig.getSystem());
DefaultResult<SysVO> sResult = this.sysService.findByUK(sys);
if (sResult.getValue() != null) {
this.selectValue = sResult.getValue().getOid();
}
}
Aggregations