/*
 * @Author: zc
 * @description 首页
 */
import request from '@/utils/request';

/**
 * @description 获取我的快捷入口
 * @return {*}
 */
export const geFastMenu = () => {
	return request({
		url: '/api/v1/Home/get-myfastmenu',
		method: 'get',
	});
};
/**
 * @description 获取可选快捷入口
 * @param {object} data
 * @return {*}
 */
export const fastMenu = (data?: object) => {
	return request({
		url: '/api/v1/Home/get-fastmenu',
		method: 'post',
		data,
	});
};
/**
 * @description 设置快捷入口
 * @param {object} data
 * @return {*}
 */
export const setFastMenu = (data: object) => {
	return request({
		url: '/api/v1/Home/set-fastmenu',
		method: 'post',
		data,
	});
};
/**
 * @description 获取首页数据
 * @return {*}
 */
export const getHomeData = () => {
	return request({
		url: '/api/v1/CommonP/home_data',
		method: 'get',
	});
};
/**
 * @description 获取首页列表待办
 * @return {*}
 */
export const getHomeList = () => {
	return request({
		url: '/api/v1/Order/waited/home',
		method: 'get',
	});
};
/**
 * @description 获取首页数据
 * @return {*}
 */
export const getHomeData2 = () => {
	return request({
		url: '/api/v1/CommonP/home_data_new',
		method: 'get',
	});
};
/**
 * @description 获取加密后的用户名
 * @return {*}
 */
export const getUserNameApi = (params?: object) => {
	return request({
		url: '/api/v1/OldHotline/get_rsa_loginname',
		method: 'get',
		params
	});
};
/**
 * @description 根据参数跳转 获取token
 * @return {*}
 */
export const getTokenByUrl = (data: object) => {
	return request({
		url: '/api/v1/OldHotline/loing-oldtonew',
		method: 'post',
		data,
	},{
		error_message_show:false
	});
};
/**
 * @description 查询老系统待办
 * @return {*}
 */
export const getOldHotlineList = (params?: object) => {
	return request({
		url: '/api/v1/oldhotline/ishas_canhandler_old',
		method: 'get',
		params,
	});
};