eas之常用源码整理

//查看是否有相关权限
boolean hasAllotPermission=
        PermissionFactory.getRemoteInstance().hasFunctionPermission(new ObjectUuidPK(userId),new ObjectUuidPK(orgId),paramString);
 
//Context上下文的获取
Context ctx=Tools.getInstance().getCtx();
SysContext ctx=SysContext.getContext();
 
//清除分录删除事件  
int n=kdtEntrys_detailPanel.getRemoveLineButton().getActionListenes().length();
if(n>0){
   for (int i = 0; i < n; i++) {
     kdtEntrys_detailPanel.getRemoveLinesButton().removeActionListener(kdtEntrys_detailPanel.getRemoveLinesButton().getActionListeners()[i]);
   }
}
kdtEntrys_detailPanel.getRemoveLinesButton().addActionListeners(actionRemoveLine);
 
//清除分录插入事件
int n=kdtEntrys_detailPanel.getInsertLineButton().getActionListenes().length();
if(n>0){
   for (int i = 0; i < n; i++) {
     kdtEntrys_detailPanel.getInsertLineButton().removeActionListener(kdtEntrys_detailPanel.getInsertLineButton().getActionListeners()[i]);
   }
}
kdtEntrys_detailPanel.getInsertLineButton().addActionListeners(actionInsertLine);
 
//清除分录新增事件  
n = kdtEntrys_detailPanel.getAddNewLineButton().getActionListeners().length;  
if (n > 0) {  
  for (int i=0; i<n; i++) {  
       kdtEntrys_detailPanel.getAddNewLineButton().removeActionListener(kdtEntrys_detailPanel.getAddNewLineButton().getActionListeners() [i]);  
  }  
}  
kdtEntrys_detailPanel.getAddNewLineButton().addActionListener(actionAddLine); 
posted @ 2019-06-02 17:24  一条有梦想的海洋咸鱼  阅读(522)  评论(0编辑  收藏  举报