package com.kingdee.eas.custom.integration.feishu.task;

import javax.ejb.*;
import java.rmi.RemoteException;
import com.kingdee.bos.*;
import com.kingdee.bos.util.BOSObjectType;
import com.kingdee.bos.metadata.IMetaDataPK;
import com.kingdee.bos.metadata.rule.RuleExecutor;
import com.kingdee.bos.metadata.MetaDataPK;
//import com.kingdee.bos.metadata.entity.EntityViewInfo;
import com.kingdee.bos.framework.ejb.AbstractEntityControllerBean;
import com.kingdee.bos.framework.ejb.AbstractBizControllerBean;
//import com.kingdee.bos.dao.IObjectPK;
import com.kingdee.bos.dao.IObjectValue;
import com.kingdee.bos.dao.IObjectCollection;
import com.kingdee.bos.service.ServiceContext;
import com.kingdee.bos.service.IServiceContext;
import com.kingdee.eas.framework.Result;
import com.kingdee.eas.framework.LineResult;
import com.kingdee.eas.framework.exception.EASMultiException;
import com.kingdee.bos.dao.ormapping.ObjectUuidPK;

import com.kingdee.eas.common.EASBizException;
import java.util.Date;
import java.util.Map;
import java.lang.String;



public abstract class AbstractFeishuBizFacadeControllerBean extends AbstractBizControllerBean implements FeishuBizFacadeController
{
    protected AbstractFeishuBizFacadeControllerBean()
    {
    }

    protected BOSObjectType getBOSType()
    {
        return new BOSObjectType("04260294");
    }

    public void syncFeishuUserId(Context ctx, String userId, int switchType) throws BOSException, EASBizException
    {
        try {
            ServiceContext svcCtx = createServiceContext(new MetaDataPK("07684e36-3373-42c7-a2e8-21b0a0b3a689"), new Object[]{ctx, userId, new Integer(switchType)});
            invokeServiceBefore(svcCtx);
              if(!svcCtx.invokeBreak()) {
            _syncFeishuUserId(ctx, userId, switchType);
            }
            invokeServiceAfter(svcCtx);
        } catch (BOSException ex) {
            throw ex;
        } catch (EASBizException ex0) {
            throw ex0;
        } finally {
            super.cleanUpServiceState();
        }
    }
    protected void _syncFeishuUserId(Context ctx, String userId, int switchType) throws BOSException, EASBizException
    {    	
        return;
    }

    public Map syncAttendanceRecord(Context ctx, Date startDate, Date endDate, int advanceDays) throws BOSException, EASBizException
    {
        try {
            ServiceContext svcCtx = createServiceContext(new MetaDataPK("60b29792-3880-452f-88f6-f533c38a27ee"), new Object[]{ctx, startDate, endDate, new Integer(advanceDays)});
            invokeServiceBefore(svcCtx);
            if(!svcCtx.invokeBreak()) {
            Map retValue = (Map)_syncAttendanceRecord(ctx, startDate, endDate, advanceDays);
            svcCtx.setMethodReturnValue(retValue);
            }
            invokeServiceAfter(svcCtx);
            return (Map)svcCtx.getMethodReturnValue();
        } catch (BOSException ex) {
            throw ex;
        } catch (EASBizException ex0) {
            throw ex0;
        } finally {
            super.cleanUpServiceState();
        }
    }
    protected Map _syncAttendanceRecord(Context ctx, Date startDate, Date endDate, int advanceDays) throws BOSException, EASBizException
    {    	
        return null;
    }

}