/*
 * @Author: zc
 * @description 质检管理-质检中心
 */
import request from '@/utils/request';
/**
 * @description 质检中心基础信息
 */
export const qualityBaseData = () => {
	return request({
		url: `/api/v1/Quality/base`,
		method: 'get',
	});
};
/**
 * @description 质检中心基础信息
 * @param {object}  params
 */
export const qualityList = (params: object) => {
	return request({
		url: `/api/v1/Quality/list`,
		method: 'get',
		params,
	});
};
/**
 * @description 更新质检
 * @param {object}  data
 */
export const qualityUpdate = (data: object) => {
	return request({
		url: `/api/v1/Quality`,
		method: 'put',
		data,
	});
};
/**
 * @description 删除质检
 * @param {object}  data
 */
export const qualityDelete = (data: object) => {
	return request({
		url: `/api/v1/Quality`,
		method: 'delete',
		data,
	});
};
/**
 * @description 查询质检实体
 * @param id
 */
export const qualityDetail = (id: string) => {
	return request({
		url: `/api/v1/Quality/${id}`,
		method: 'get',
	});
};
/**
 * @description 通话录音转写 兴唐
 * @param data
 */
export const qualityRecordTransfer = (data: object) => {
	return request({
		url: `/api/v1/Quality/aitransfer_xt`,
		method: 'post',
		data,
	});
};
/**
 * @description 更新质检内容
 * @param data
 */
export const qualityContentUpdate = (data: object) => {
	return request({
		url: `/api/v1/Quality/transfer`,
		method: 'put',
		data,
	});
};
/**
 * @description 导出质检单
 * @param data
 */
export const qualityExport = (data: object) => {
	return request(
		{
			url: `/api/v1/ExportWord/quality_certificate`,
			method: 'post',
			data,
			responseType: 'blob',
		},
		{
			reduce_data_format: false,
		}
	);
};
/**
 * @description 坐席质检分析
 * @param {object}  params
 */
export const qualityAnalysis = (params: object) => {
	return request({
		url: `/api/v1/BiQuality/seats_quality_analyse`,
		method: 'get',
		params,
	});
};
/**
 * @description 坐席质检分析导出
 * @param {object}  data
 */
export const qualityAnalysisExport = (data: object) => {
	return request(
		{
			url: `/api/v1/BiQuality/seats_quality_analyse/export`,
			method: 'post',
			data,
			responseType: 'blob',
		},
		{
			reduce_data_format: false,
		}
	);
};
/**
 * @description 质检工单概览
 * @param {object}  params
 */
export const qualityOverview = (params: object) => {
	return request({
		url: `/api/v1/BiQuality/quality_order_overview`,
		method: 'get',
		params,
	});
};
/**
 * @description 质检工单概览导出
 * @param {object}  data
 */
export const qualityOverviewExport = (data: object) => {
	return request(
		{
			url: `/api/v1/BiQuality/quality_order_overview/export`,
			method: 'post',
			data,
			responseType: 'blob',
		},
		{
			reduce_data_format: false,
		}
	);
};
/**
 * @description 坐席质检分值分析
 * @param {object}  params
 */
export const qualityScore = (params: object) => {
	return request({
		url: `/api/v1/BiQuality/seats_quality_grade_analyse`,
		method: 'get',
		params,
	});
};
/**
 * @description 质检分值分析/坐席质检工单分析
 * @param {object}  params
 */
export const qualityScoreGrade = (params: object) => {
	return request({
		url: `/api/v1/BiQuality/month_quality_grade`,
		method: 'get',
		params,
	});
};
/**
 * @description 坐席质检分值分析基础数据
 * @param {object}  params
 */
export const qualityScoreBase = (params?: object) => {
	return request({
		url: `/api/v1/BiQuality/quality_work/base`,
		method: 'get',
		params,
	});
};