import {
    WeaTools
} from 'ecCom'

export const getHasRight = (params) => {
    return WeaTools.callApi('/api/hrm/job/getHasRight', 'GET', params);
}

export const getSearchCondition = (params) => {
    return WeaTools.callApi('/api/hrm/job/getSearchCondition', 'GET', params);
}

export const getJobGroupList = (params) => {
    return WeaTools.callApi('/api/hrm/job/getJobGroupList', 'GET', params);
}

export const getJobActivityList = (params) => {
    return WeaTools.callApi('/api/hrm/job/getJobActivityList', 'GET', params);
}

export const getJobTitleList = (params) => {
    return WeaTools.callApi('/api/hrm/job/getJobTitleList', 'GET', params);
}

export const getJobGroupForm = (params) => {
    return WeaTools.callApi('/api/hrm/job/getJobGroupForm?is_multilang_set=true', 'GET', params);
}

export const getJobForm = (params) => {
    return WeaTools.callApi('/api/hrm/job/getJobActivityForm?is_multilang_set=true', 'GET', params);
}

export const getPostForm = (params) => {
    return WeaTools.callApi('/api/hrm/job/getJobTitleForm?is_multilang_set=true', 'GET', params);
}

export const addJobGroup = (params) => {
    return WeaTools.callApi('/api/hrm/job/addJobGroup', 'POST', params);
}

export const addJob = (params) => {
    return WeaTools.callApi('/api/hrm/job/addJobActivity', 'POST', params);
}

export const addPost = (params) => {
    return WeaTools.callApi('/api/hrm/job/addJobTitle', 'POST', params);
}

export const editJobGroup = (params) => {
    return WeaTools.callApi('/api/hrm/job/editeJobGroup', 'POST', params);
}

export const editJob = (params) => {
    return WeaTools.callApi('/api/hrm/job/editeJobActivity', 'POST', params);
}

export const editPost = (params) => {
    return WeaTools.callApi('/api/hrm/job/editeJobTitle', 'POST', params);
}

export const deleteJobGroup = (params) => {
    return WeaTools.callApi('/api/hrm/job/deleteJobGroup', 'POST', params);
}

export const deleteJob = (params) => {
    return WeaTools.callApi('/api/hrm/job/deleteJobActivity', 'POST', params);
}

export const deletePost = (params) => {
    return WeaTools.callApi('/api/hrm/job/deleteJobTitle', 'POST', params);
}

export const getImportForm = (params) => {
    return WeaTools.callApi('/api/hrm/job/getImportForm?is_multilang_set=true', 'GET', params);
}

export const saveImport = (params) => {
    return WeaTools.callApi('/api/hrm/job/saveImport', 'POST', params);
}

export const getJobDetail = (params) => {
    return WeaTools.callApi('/api/hrm/job/getJobDetail', 'GET', params);
}

export const getImportResultDetail = (params) => {
    return WeaTools.callApi('/api/hrm/job/getImportRowResultLog', 'GET', params);
}

export const getImportHistory = (params) => {
    return WeaTools.callApi('/api/hrm/job/getImportHistory', 'GET', params);
}

export const getImportLogDetail = (params) => {
    return WeaTools.callApi('/api/hrm/job/getImportColResultLog', 'GET', params);
}

export const getImportLogSearchCondition = (params) => {
    return WeaTools.callApi('/api/hrm/job/getHistorySearchCondition', 'GET', params);
}

export const doCanceled = (params) => {
    return WeaTools.callApi('/api/hrm/job/doCanceled', 'POST', params);
}
export const getJobTree = (params) => {
    return WeaTools.callApi('/api/hrm/job/getJobTree', 'GET', params);
}

export const doISCanceled = (params) => {
    return WeaTools.callApi('/api/hrm/job/doISCanceled', 'POST', params);
}