import { requests } from './index';
const PREFIX = 'api-marketing/';

import config from '@/config';
export const url = config.api + PREFIX;

//智能营销--ECM营销引擎分页列表
export const loadEcmList = params => requests(PREFIX + 'page-ecm-list', params);

//扫码营销--分页列表排序
export const changeEcmPlanSort = params => requests(PREFIX + 'change-ecm-plan-sort', params);

//扫码营销-日志
export const listEcmScanLogPage = params => requests(PREFIX + 'list-ecm-scan-log-page', params);

//智能营销--ECM营销引擎-- 删除
export const deleteEcm = params => requests(PREFIX + 'delete-ecm', params);

//智能营销--ECM营销引擎-- 支付方式查询
export const gicPaymentList = params => requests(PREFIX + 'query-gic-payment-list', params);

//智能营销--ECM营销引擎-- 新建/修改 回显智能引擎计划信息
export const getEcmInfo = params => requests(PREFIX + 'get-ecm-info', params);

// 智能营销--ECM营销引擎-- 新建/修改 [保存]计划信息
export const saveEcmInfo = params => requests(PREFIX + 'save-update-ecm', params);

// 智能营销--下线
export const offlineEcmPlan = params => requests(PREFIX + 'ecm-plan-offline', params);

// 智能营销--记录--批次记录页面
export const ecmBatchSendInfos = params => requests(PREFIX + 'ecm-batch-send-infos', params);

// 智能营销--记录--批次人员列表
export const ecmBatchSendDetails = params => requests(PREFIX + 'ecm-batch-send-details', params);

// 智能营销--实时发送记录类型
export const ecmCurrentSendInfos = params => requests(PREFIX + 'ecm-current-send-infos', params);

// 智能营销--实时发送人员列表
export const ecmCurrentSendDetails = params => requests(PREFIX + 'ecm-current-send-details', params);

// 智能营销--记录--批次人员列表 导出csv
export const exportBatchSendDetails = config.api + PREFIX + 'export-batch-send-details';

// 智能营销--实时人员列表--导出csv
export const exportCurrentSendDetails = config.api + PREFIX + 'export-current-send-details';

// 智能营销--触达效果
export const ecmTouchEffectColumnDiagram = params => requests(PREFIX + 'ecmTouchEffectColumnDiagram', params);
export const ecmTouchEffectTable = params => requests(PREFIX + 'ecmTouchEffectTable', params);
export const ecmTouchTypeTableList = params => requests(PREFIX + 'ecmTouchTypeTableList', params); // 获取（1 群发任务、2 群发失败-话务、3 群发失败-短信、4 话务、5 短信、6 微信）列表
// export const ecmTouchEffectFunnelChart = params => requests(PREFIX + 'ecmTouchEffectFunnelChart', params);
export const ecmPlanTouchConfig = params => requests(PREFIX + 'ecmPlanTouchConfig', params);
export const getCardLeads = params => requests(PREFIX + 'getCardLeads', params); // 卡券收益
export const getCardLeadsList = params => requests(PREFIX + 'getCardLeadsList', params); // 卡券收益表格
// 智能营销--导购线索
export const ecmGuideCluesColumnDiagram = params => requests(PREFIX + 'ecmGuideCluesColumnDiagram', params);
export const ecmGuideCluesTable = params => requests(PREFIX + 'ecmGuideCluesTable', params);
export const ecmGuideCluesTaskTable = params => requests(PREFIX + 'ecmGuideCluesTaskTable', params); // 任务完成情况表格
export const ecmGuideCluesTouchEffectTotalTab = params => requests(PREFIX + 'ecmGuideCluesTouchEffectTotalTab', params); // 触达效果-整体转化-表格
export const ecmGuideCluesTouchEffectTab = params => requests(PREFIX + 'ecmGuideCluesTouchEffectTab', params); // 触达效果-其他tab-表格
// 智能营销--后台线索
export const ecmHeadCluesColumnDiagram = params => requests(PREFIX + 'ecmHeadCluesColumnDiagram', params);
export const ecmHeadGuideCluesTable = params => requests(PREFIX + 'ecmHeadGuideCluesTable', params);
export const ecmHeadCluesTaskTab = params => requests(PREFIX + 'ecmHeadCluesTaskTab', params); // 表格
// 智能营销--表格的合计和计划整体数据
export const ecmGuideCluesTouchEffectTotalTabHead = params => requests(PREFIX + 'ecmGuideCluesTouchEffectTotalTabHead', params); // 导购线索-触达效果整体计划表头
export const ecmGuideCluesTouchEffectTabHead = params => requests(PREFIX + 'ecmGuideCluesTouchEffectTabHead', params); //导购线索--触达效果其他表格表头
export const ecmGuideCluesTaskTableHead = params => requests(PREFIX + 'ecmGuideCluesTaskTableHead', params); // 触达效果-导购线索-任务完成情况表头
export const ecmHeadCluesTaskTabHead = params => requests(PREFIX + 'ecmHeadCluesTaskTabHead', params); // 总部线索表头

// 智能营销线索页tree
export const getGroupTree = params => requests(PREFIX + 'getGroupTree', params);
// export
export const getTabList = params => requests(PREFIX + 'ecmGuideCluesTableLabel', params);
// 智能营销导出表格
export const otherTableExoport = config.api + PREFIX + 'ecmGuideCluesTouchEffectTabExport'; // // 触达效果-其他tab-表格
export const allConvTableExport = config.api + PREFIX + 'ecmGuideCluesTouchEffectTotalTabExport'; // 触达效果-整体转化-表格
export const taskTableExport = config.api + PREFIX + 'ecmGuideCluesTaskTableExport'; // 触达效果-任务完成情况表格
export const headClueTableExport = config.api + PREFIX + 'ecmHeadCluesTaskTabExport'; // 触达效果-后台线索表格

export const getUseStoredFalg = params => requests(PREFIX + 'get-ecm-store-flag', params);

export const getXsxsFalg = params => requests(PREFIX + 'get-xsxs-open-flag', params);

export const getEcmLog = params => requests(PREFIX + 'get-ecm-operator_log', params);
