276efd9ac42f1b186b95cf0b84ce630dcfc89a11.svn-base 9.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237
  1. package com.kingdee.eas.custom.bill.salary.app;
  2. import javax.ejb.*;
  3. import java.rmi.RemoteException;
  4. import com.kingdee.bos.*;
  5. import com.kingdee.bos.util.BOSObjectType;
  6. import com.kingdee.bos.metadata.IMetaDataPK;
  7. import com.kingdee.bos.metadata.rule.RuleExecutor;
  8. import com.kingdee.bos.metadata.MetaDataPK;
  9. //import com.kingdee.bos.metadata.entity.EntityViewInfo;
  10. import com.kingdee.bos.framework.ejb.AbstractEntityControllerBean;
  11. import com.kingdee.bos.framework.ejb.AbstractBizControllerBean;
  12. //import com.kingdee.bos.dao.IObjectPK;
  13. import com.kingdee.bos.dao.IObjectValue;
  14. import com.kingdee.bos.dao.IObjectCollection;
  15. import com.kingdee.bos.service.ServiceContext;
  16. import com.kingdee.bos.service.IServiceContext;
  17. import com.kingdee.eas.framework.Result;
  18. import com.kingdee.eas.framework.LineResult;
  19. import com.kingdee.eas.framework.exception.EASMultiException;
  20. import com.kingdee.bos.dao.ormapping.ObjectUuidPK;
  21. import com.kingdee.eas.custom.bill.salary.PayPacketCollection;
  22. import com.kingdee.eas.framework.app.CoreBillBaseControllerBean;
  23. import com.kingdee.eas.framework.ObjectBaseCollection;
  24. import com.kingdee.eas.custom.bill.salary.PayPacketInfo;
  25. import com.kingdee.bos.dao.IObjectPK;
  26. import com.kingdee.bos.metadata.entity.EntityViewInfo;
  27. import java.lang.String;
  28. import com.kingdee.eas.framework.CoreBaseInfo;
  29. import com.kingdee.eas.framework.CoreBaseCollection;
  30. import com.kingdee.eas.framework.CoreBillBaseCollection;
  31. import com.kingdee.eas.common.EASBizException;
  32. import com.kingdee.bos.metadata.entity.SelectorItemCollection;
  33. public abstract class AbstractPayPacketControllerBean extends CoreBillBaseControllerBean implements PayPacketController
  34. {
  35. protected AbstractPayPacketControllerBean()
  36. {
  37. }
  38. protected BOSObjectType getBOSType()
  39. {
  40. return new BOSObjectType("2676510E");
  41. }
  42. public PayPacketCollection getPayPacketCollection(Context ctx) throws BOSException
  43. {
  44. try {
  45. ServiceContext svcCtx = createServiceContext(new MetaDataPK("3db09957-de7f-4586-9d87-1e4c4c64e433"), new Object[]{ctx});
  46. invokeServiceBefore(svcCtx);
  47. if(!svcCtx.invokeBreak()) {
  48. PayPacketCollection retValue = (PayPacketCollection)_getCollection(ctx, svcCtx);
  49. svcCtx.setMethodReturnValue(retValue);
  50. }
  51. invokeServiceAfter(svcCtx);
  52. return (PayPacketCollection)svcCtx.getMethodReturnValue();
  53. } catch (BOSException ex) {
  54. throw ex;
  55. } finally {
  56. super.cleanUpServiceState();
  57. }
  58. }
  59. protected IObjectCollection _getCollection(Context ctx, IServiceContext svcCtx) throws BOSException
  60. {
  61. return super._getCollection(ctx, svcCtx);
  62. }
  63. public PayPacketCollection getPayPacketCollection(Context ctx, EntityViewInfo view) throws BOSException
  64. {
  65. try {
  66. ServiceContext svcCtx = createServiceContext(new MetaDataPK("370e87c1-bd2f-4030-9ea3-2cd1a87537b0"), new Object[]{ctx, view});
  67. invokeServiceBefore(svcCtx);
  68. if(!svcCtx.invokeBreak()) {
  69. PayPacketCollection retValue = (PayPacketCollection)_getCollection(ctx, svcCtx, view);
  70. svcCtx.setMethodReturnValue(retValue);
  71. }
  72. invokeServiceAfter(svcCtx);
  73. return (PayPacketCollection)svcCtx.getMethodReturnValue();
  74. } catch (BOSException ex) {
  75. throw ex;
  76. } finally {
  77. super.cleanUpServiceState();
  78. }
  79. }
  80. protected IObjectCollection _getCollection(Context ctx, IServiceContext svcCtx, EntityViewInfo view) throws BOSException
  81. {
  82. return super._getCollection(ctx, svcCtx, view);
  83. }
  84. public PayPacketCollection getPayPacketCollection(Context ctx, String oql) throws BOSException
  85. {
  86. try {
  87. ServiceContext svcCtx = createServiceContext(new MetaDataPK("b4273ff4-7886-4513-afa7-6ce7fe9f85bc"), new Object[]{ctx, oql});
  88. invokeServiceBefore(svcCtx);
  89. if(!svcCtx.invokeBreak()) {
  90. PayPacketCollection retValue = (PayPacketCollection)_getCollection(ctx, svcCtx, oql);
  91. svcCtx.setMethodReturnValue(retValue);
  92. }
  93. invokeServiceAfter(svcCtx);
  94. return (PayPacketCollection)svcCtx.getMethodReturnValue();
  95. } catch (BOSException ex) {
  96. throw ex;
  97. } finally {
  98. super.cleanUpServiceState();
  99. }
  100. }
  101. protected IObjectCollection _getCollection(Context ctx, IServiceContext svcCtx, String oql) throws BOSException
  102. {
  103. return super._getCollection(ctx, svcCtx, oql);
  104. }
  105. public PayPacketInfo getPayPacketInfo(Context ctx, IObjectPK pk) throws BOSException, EASBizException
  106. {
  107. try {
  108. ServiceContext svcCtx = createServiceContext(new MetaDataPK("8997a712-46cc-4704-9f09-ceff360a9baa"), new Object[]{ctx, pk});
  109. invokeServiceBefore(svcCtx);
  110. if(!svcCtx.invokeBreak()) {
  111. PayPacketInfo retValue = (PayPacketInfo)_getValue(ctx, pk);
  112. svcCtx.setMethodReturnValue(retValue);
  113. }
  114. invokeServiceAfter(svcCtx);
  115. return (PayPacketInfo)svcCtx.getMethodReturnValue();
  116. } catch (BOSException ex) {
  117. throw ex;
  118. } catch (EASBizException ex0) {
  119. throw ex0;
  120. } finally {
  121. super.cleanUpServiceState();
  122. }
  123. }
  124. protected IObjectValue _getValue(Context ctx, IObjectPK pk) throws BOSException, EASBizException
  125. {
  126. return super._getValue(ctx, pk);
  127. }
  128. public PayPacketInfo getPayPacketInfo(Context ctx, IObjectPK pk, SelectorItemCollection selector) throws BOSException, EASBizException
  129. {
  130. try {
  131. ServiceContext svcCtx = createServiceContext(new MetaDataPK("b02c099d-c070-4617-a6a9-6901860364c5"), new Object[]{ctx, pk, selector});
  132. invokeServiceBefore(svcCtx);
  133. if(!svcCtx.invokeBreak()) {
  134. PayPacketInfo retValue = (PayPacketInfo)_getValue(ctx, pk, selector);
  135. svcCtx.setMethodReturnValue(retValue);
  136. }
  137. invokeServiceAfter(svcCtx);
  138. return (PayPacketInfo)svcCtx.getMethodReturnValue();
  139. } catch (BOSException ex) {
  140. throw ex;
  141. } catch (EASBizException ex0) {
  142. throw ex0;
  143. } finally {
  144. super.cleanUpServiceState();
  145. }
  146. }
  147. protected IObjectValue _getValue(Context ctx, IObjectPK pk, SelectorItemCollection selector) throws BOSException, EASBizException
  148. {
  149. return super._getValue(ctx, pk, selector);
  150. }
  151. public PayPacketInfo getPayPacketInfo(Context ctx, String oql) throws BOSException, EASBizException
  152. {
  153. try {
  154. ServiceContext svcCtx = createServiceContext(new MetaDataPK("4f4914db-f075-4acd-a356-b953c73ac0d9"), new Object[]{ctx, oql});
  155. invokeServiceBefore(svcCtx);
  156. if(!svcCtx.invokeBreak()) {
  157. PayPacketInfo retValue = (PayPacketInfo)_getValue(ctx, oql);
  158. svcCtx.setMethodReturnValue(retValue);
  159. }
  160. invokeServiceAfter(svcCtx);
  161. return (PayPacketInfo)svcCtx.getMethodReturnValue();
  162. } catch (BOSException ex) {
  163. throw ex;
  164. } catch (EASBizException ex0) {
  165. throw ex0;
  166. } finally {
  167. super.cleanUpServiceState();
  168. }
  169. }
  170. protected IObjectValue _getValue(Context ctx, String oql) throws BOSException, EASBizException
  171. {
  172. return super._getValue(ctx, oql);
  173. }
  174. protected com.kingdee.eas.basedata.org.OrgUnitInfo getMainBizOrgUnit(Context ctx,com.kingdee.eas.framework.CoreBillBaseInfo model) {
  175. Object obj = model.get("adminOrgUnit");
  176. if (obj != null && obj instanceof com.kingdee.eas.basedata.org.OrgUnitInfo)
  177. return (com.kingdee.eas.basedata.org.OrgUnitInfo)obj;
  178. else
  179. return null;
  180. }
  181. public CoreBillBaseCollection getCoreBillBaseCollection (Context ctx) throws BOSException
  182. {
  183. return (CoreBillBaseCollection)(getPayPacketCollection(ctx).cast(CoreBillBaseCollection.class));
  184. }
  185. public CoreBillBaseCollection getCoreBillBaseCollection (Context ctx, EntityViewInfo view) throws BOSException
  186. {
  187. return (CoreBillBaseCollection)(getPayPacketCollection(ctx, view).cast(CoreBillBaseCollection.class));
  188. }
  189. public CoreBillBaseCollection getCoreBillBaseCollection (Context ctx, String oql) throws BOSException
  190. {
  191. return (CoreBillBaseCollection)(getPayPacketCollection(ctx, oql).cast(CoreBillBaseCollection.class));
  192. }
  193. public ObjectBaseCollection getObjectBaseCollection (Context ctx) throws BOSException
  194. {
  195. return (ObjectBaseCollection)(getPayPacketCollection(ctx).cast(ObjectBaseCollection.class));
  196. }
  197. public ObjectBaseCollection getObjectBaseCollection (Context ctx, EntityViewInfo view) throws BOSException
  198. {
  199. return (ObjectBaseCollection)(getPayPacketCollection(ctx, view).cast(ObjectBaseCollection.class));
  200. }
  201. public ObjectBaseCollection getObjectBaseCollection (Context ctx, String oql) throws BOSException
  202. {
  203. return (ObjectBaseCollection)(getPayPacketCollection(ctx, oql).cast(ObjectBaseCollection.class));
  204. }
  205. public CoreBaseCollection getCoreBaseCollection (Context ctx) throws BOSException
  206. {
  207. return (CoreBaseCollection)(getPayPacketCollection(ctx).cast(CoreBaseCollection.class));
  208. }
  209. public CoreBaseCollection getCoreBaseCollection (Context ctx, EntityViewInfo view) throws BOSException
  210. {
  211. return (CoreBaseCollection)(getPayPacketCollection(ctx, view).cast(CoreBaseCollection.class));
  212. }
  213. public CoreBaseCollection getCoreBaseCollection (Context ctx, String oql) throws BOSException
  214. {
  215. return (CoreBaseCollection)(getPayPacketCollection(ctx, oql).cast(CoreBaseCollection.class));
  216. }
  217. }