package com.base.helper; import java.util.Map; import jbo.sys.DOC_ATTACHMENT; import com.amarsoft.are.jbo.BizObject; import com.amarsoft.are.jbo.BizObjectManager; import com.amarsoft.are.jbo.JBOException; import com.amarsoft.are.jbo.JBOFactory; import com.base.util.BizObjectUtil; public class LBDocHelper { public static Map getDocById(String sId) throws JBOException { BizObjectManager bm = JBOFactory .getBizObjectManager("jbo.app.tenwa.doc.LB_DOCATTRIBUTE"); BizObject bo = bm.createQuery("id=:id").setParameter("id", sId) .getSingleResult(false); if (null == bo) return null; BizObjectUtil util = new BizObjectUtil(); return util.bizObject2MapValue(bo); } // public static Map getDocById2(String sId) // throws JBOException { // BizObjectManager bm = JBOFactory // .getBizObjectManager(DOC_ATTACHMENT.CLASS_NAME); // BizObject bo = bm.createQuery("ATTACHMENTNO=:id").setParameter("id", sId) // .getSingleResult(false); // if (null == bo) // return null; // BizObjectUtil util = new BizObjectUtil(); // return util.bizObject2MapValue(bo); // } }