public static String getRemindNoticeText() throws PureException { INoticeMgr mgr = (INoticeMgr) PureFactory.getBean("INoticeMgr"); Notice notice = mgr.getNotice("project$all"); if (notice == null) return ""; NoticeItem item = notice.getItem("hurry"); return item == null ? "" : item.getText(); }
public static void setRemindNoticeText(String _sText) throws PureException { INoticeMgr mgr = (INoticeMgr) PureFactory.getBean("INoticeMgr"); Notice notice = mgr.getNotice("project$all"); if (notice == null) notice = new Notice("project$all"); NoticeItem item = notice.getItem("hurry"); if (item == null) { item = new NoticeItem("hurry"); notice.getItems().put("hurry", item); } item.setText(_sText); mgr.updateNotce(notice); mgr.store(); }