import request from '@/utils/request'

export function getTotalDialysis (params) {
  // const params = {
  //   startime: startime,
  //   endtime: endtime
  // }
  return request({
    url: '/m/api/gettotaldialysis',
    method: 'get',
    params: params
  })
}

export function getMobileTotalLapseCount (params) {
  // const params = {
  //   startime: startime,
  //   endtime: endtime
  // }
  return request({
    url: '/m/api/getmobiletotallapsecount',
    method: 'get',
    params: params
  })
}

export function getMobileTotalSexCount (params) {
  // const params = {
  //   startime: startime,
  //   endtime: endtime
  // }
  return request({
    url: '/m/api/getmobiletotalsexcount',
    method: 'get',
    params: params
  })
}

export function getMobileTotalInfectiousCount (params) {
  // const params = {
  //   startime: startime,
  //   endtime: endtime
  // }
  return request({
    url: '/m/api/getmobiletotalinfectiouscount',
    method: 'get',
    params: params
  })
}

export function getMobileTotalAgeCount (params) {
  // const params = {
  //   startime: startime,
  //   endtime: endtime
  // }
  return request({
    url: '/m/api/getmobiletotalagecount',
    method: 'Get',
    params: params
  })
}

export function getMobileTotalDialysisCount (params) {
  // const params = {
  //   startime: startime,
  //   endtime: endtime
  // }
  return request({
    url: '/m/api/getmobiletotaldialysiscount',
    method: 'Get',
    params: params
  })
}

export function getMobilePatientList (params) {
  return request({
    url: '/m/api/gemobilepatientlist',
    method: 'get',
    params: params
  })
}

export function getPrescriptionList (startime, endtime, limit, page) {
  const params = {
    startime: startime,
    endtime: endtime,
    limit: limit,
    page: page

  }
  console.log('parasm', params)
  return request({
    url: '/m/api/getprescriptionlist/one',
    method: 'get',
    params: params
  })
}

export function getMobilePatientDetial (id, startime, endtime, limit, page) {
  const params = {
    id: id,
    startime: startime,
    endtime: endtime,
    limit: limit,
    page: page
  }
  return request({
    url: '/m/api/getmobilepatientdetail',
    method: 'get',
    params: params
  })
}

export function toSearchPatient (patientid, startime, endtime, limit, page) {
  const params = {
    patientid: patientid,
    startime: startime,
    endtime: endtime,
    limit: limit,
    page: page
  }
  return request({
    url: '/m/api/tosearchpatient',
    method: 'get',
    params: params
  })
}

export function getAllPatientsMode (startime, endtime, state, limit, page, modeid) {
  const params = {
    startime: startime,
    endtime: endtime,
    value: state,
    limit: limit,
    page: page,
    mode_id: modeid
  }
  return request({
    url: '/m/api/getallpatientsmode',
    method: 'get',
    params: params
  })
}

export function getMobileTreatlist (startime, endtime, state) {
  const params = {
    startime: startime,
    endtime: endtime,
    value: state
  }
  return request({
    url: '/m/api/getmobiletreatlist',
    method: 'get',
    params: params
  })
}

export function getMobileInspectionList (startime, endtime, patientid) {
  const params = {
    startime: startime,
    endtime: endtime,
    patientid: patientid
  }
  return request({
    url: '/m/api/getmobileInspectionList',
    method: 'get',
    params: params
  })
}

export function getPatientInspectionDetail (id, startime, endtime) {
  const params = {
    id: id,
    startime: startime,
    endtime: endtime
  }
  return request({
    url: '/m/api/getpatientinspectiondetail',
    method: 'get',
    params: params
  })
}

export function GetSearchPatientDetail (patientid, startime, endtime) {
  const params = {
    patientid: patientid,
    startime: startime,
    endtime: endtime
  }
  return request({
    url: 'm/api/getseachpatientdetail',
    method: 'get',
    params: params
  })
}

export function getMobileNormData (params) {
  return request({
    url: 'm/api/getmobilenormdata',
    method: 'get',
    params: params
  })
}

export function getMobileProjectList (params) {
  return request({
    url: 'm/api/getmobileprojectlist',
    method: 'Get',
    params: params
  })
}

export function getMobileFirstQuarter (params) {
  return request({
    url: '/m/api/getmobilefirstquarter',
    method: 'get',
    params: params
  })
}

export function getMobileMonthProjectList (params) {
  return request({
    url: '/m/api/getmobilemonthprojectlist',
    method: 'get',
    params: params
  })
}

export function getAllMobileMajorInspection (params) {
  return request({
    url: '/m/api/getallmobilemajorinspection',
    method: 'get',
    params: params
  })
}

export function getMobilePatientTwo (startime, endtime, limit, page) {
  const params = {
    startime: startime,
    endtime: endtime,
    limit: limit,
    page: page
  }

  return request({
    url: '/m/api/getmobilepatientlist',
    method: 'get',
    params: params
  })
}

export function getMobilePatientDetailCheck (id, startime, endtime) {
  const params = {
    id: id,
    startime: startime,
    endtime: endtime
  }

  return request({
    url: '/m/api/getmobilepatientdetailcheck',
    method: 'get',
    params: params
  })
}

export function getMobilePatientsControl (params) {
  return request({
    url: '/m/api/getmobilepatientcontrol',
    method: 'Get',
    params: params
  })
}

export function getMobileCartogramlist (params) {
  return request({
    url: 'm/api/getmobilecartogramlist',
    method: 'Get',
    params: params
  })
}

export function GetMobileQualityControl (params) {
  console.log('params', params)
  return request({
    url: '/m/api/getmobilequalitycontrol',
    method: 'get',
    params: params
  })
}

export function toSearchPatientsControl (params) {
  return request({
    url: '/m/api/toseachpatientscontrol',
    method: 'Get',
    params: params
  })
}

export function getListPatientDetail (params) {
  return request({
    url: '/m/api/getlistpatientdetail',
    method: 'get',
    params: params
  })
}

export function getMobileBloodList (params) {
  console.log('params', params)
  return request({
    url: '/m/api/getmobilebloodlist',
    method: 'get',
    params: params
  })
}

export function getBloodMonthList (params) {
  return request({
    url: '/m/api/getbloodmonthlist',
    method: 'get',
    params: params
  })
}

export function getQuarterTarget (params) {
  return request({
    url: '/m/api/getquarterTargelist',
    method: 'Get',
    params: params
  })
}

export function getMonthTarget (params) {
  return request({
    url: '/m/api/getmonthtarge',
    method: 'Get',
    params: params
  })
}

export function getQuarterBloodList (params) {
  return request({
    url: '/m/api/getquarterbloodlist',
    method: 'get',
    params: params
  })
}

export function getMonthBloodList (params) {
  return request({
    url: '/m/api/getmonthbloolist',
    method: 'get',
    params: params
  })
}

export function getTargetNoStandDetail (params) {
  return request({
    url: '/m/api/gettargetnostanddetail',
    method: 'Get',
    params: params
  })
}

export function getTargeStandDetail (params) {
  return request({
    url: '/m/api/gettargestanddetail',
    method: 'Get',
    params: params
  })
}

export function getSystolicBloodStand (params) {
  return request({
    url: '/m/api/getsystolicbloodstand',
    method: 'get',
    params: params
  })
}

export function getSystolicBloodNoStand (params) {
  return request({
    url: '/m/api/getsystolicbloodnostand',
    method: 'Get',
    params: params
  })
}

export function getMobileIdsList (data, patientid) {
  return request({
    url: '/m/api/getmobileidslist?patientid=' + patientid,
    method: 'post',
    data: data
  })
}

export function getMobileTreatModelist(params){
  return request({
    url:"/m/api/getmobiletreatmodelist",
    method:"get",
    params:params
  })
}

export function getMobileCountModeId(params){
  return request({
    url:"/m/api/getmobileCountModeId",
    method:"get",
    params:params
  })
}

export function getMobileRolloutCount(params){
  return request({
    url:"/m/api/getmobilerolloutcount",
    method:"get",
    params:params
  })
}
