import {
	WeaTools
} from 'ecCom'

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

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

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

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

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

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

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

//是否在免密时间内
export const getSecondAuthFreeTime = (params = {}) => WeaTools.callApi('/api/hrm/login/getSecondAuthFreeTime', 'POST', params);
//获取二次验证表单
export const getSecondAuthForm = (params = {}) => WeaTools.callApi('/api/hrm/login/getSecondAuthForm', 'POST', params);
//二次验证
export const doSecondAuth = (params = {}) => WeaTools.callApi('/api/hrm/login/doSecondAuth', 'POST', params);
//获取动态密码
export const getSecDynamicPassword = (params = {}) => WeaTools.callApi('/api/hrm/login/getSecDynamicPassword', 'POST', params);