package com.engine.organization.wrapper;


import com.engine.common.util.ServiceUtil;
import com.engine.organization.enums.ModuleTypeEnum;
import com.engine.organization.service.VersionManageService;
import com.engine.organization.service.impl.VersionManageServiceImpl;
import com.engine.organization.util.OrganizationWrapper;
import weaver.hrm.User;

import java.util.Map;

/**
 * @Author weaver_cl
 * @Description:
 * @Date 2022/12/8
 * @Version V1.0
 **/
public class VersionManageWrapper extends OrganizationWrapper {

    private VersionManageService getVersionManageService(User user) {
        return ServiceUtil.getService(VersionManageServiceImpl.class, user);
    }

    public void save(ModuleTypeEnum moduleTypeEnum, Map<String, Object> params) {
        getVersionManageService(user).save(moduleTypeEnum, params, user);
    }

    public Map<String, Object> getVersion(ModuleTypeEnum moduleTypeEnum, Map<String, Object> params) {
        return getVersionManageService(user).getVersion(moduleTypeEnum, params, user);
    }
}
