import {requestInstance} from "@/service";
import * as url from "url";

export function getSafeRuleHomeTableData(params) {
 return requestInstance({
  url:'/ptjkInterface/selectCatalogSafeMainPageList',
  data:{
   ...params
  }
 })
}
export function getSafeRuleDetailTableData(params) {
 return requestInstance({
  url:'/ptjkInterface/selectSafaRulesPageList',
  data:{
   ...params
  }
 })
}
export function changeSafeStatus(params) {
 return requestInstance({
  url:'/ptjkInterface/editSafaRules',
  data:{
   ...params
  }
 })
}
export function delSafeRuleD(SAFE_RULES_ID){
 return requestInstance({
  url:'/ptjkInterface/removeSafaRules',
  data:{
   SAFE_RULES_ID
  }
 })
}
export function getEncodeTypeSelect(level,SAFE_TYPE) {
 return requestInstance({
  url:'/DataSafe/querySafeTypeRulesList',
  data:{
   "pageIndex": '1',
   "pageSize": '10000',
   "SAFE_LEVEL": level,
   "SAFE_TYPE_NAME": '',
   "SAFE_TYPE": SAFE_TYPE,
  }
 })
}
export function getSafeRuleMetaInfo(CATALOG_ID) {
 return requestInstance(
  {
   url:'/DataSafe/querySafeParamsResult',
   data:{
    pageIndex:1,
    pageSize:1000,
    CATALOG_ID
   }
  }
 )
}
export function getDetailDangerTableData(parmas){
 return requestInstance({
  url:'/ptjkInterface/selectSafeRiskPageList',
  data:{
   ...parmas
  }
 })
}
