package com.qmth.sop.business.service;

import com.alibaba.fastjson.JSONObject;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import com.google.gson.JsonObject;
import com.qmth.sop.business.bean.result.TBQualityProblemApplyResult;
import com.qmth.sop.business.entity.TBQualityProblemApply;
import com.qmth.sop.business.entity.TBService;
import com.qmth.sop.common.enums.InfluenceDegreeEnum;
import com.qmth.sop.common.enums.QualityAnalyseGroupEnum;
import com.qmth.sop.common.enums.QualityProblemReasonEnum;

import java.util.List;
import java.util.Map;

public interface QualityAnalyseService extends IService<TBQualityProblemApply> {

    List<TBService> list(Long startTime,Long endTime);

    Double progress(Long serviceUnitId);

    JSONObject influence(Long serviceUnitId, QualityAnalyseGroupEnum group);

    Map<String, Object> pie(Long serviceUnitId);

    Map<String, Map<String, Object>> radar(Long serviceUnitId, QualityAnalyseGroupEnum group);

    IPage<TBQualityProblemApplyResult> detail(Page<Object> objectPage, Long serviceUnitId, InfluenceDegreeEnum degree);

    IPage<TBQualityProblemApplyResult> influence(Page<Object> tPage, Long serviceUnitId, Long supplierId, Long region_id, InfluenceDegreeEnum influenceDegree, QualityProblemReasonEnum reason);
}
