// 检查管理
import request from '@/utils/request'

// 检查->患者列表
export function getPatientList(data) {
    return request({
        url: '/Patient/getPatientList',
        method: 'post',
        data
    })
}

// 检查->患者可加入项目列表
export function getPatientJoinTrialInitList(data) {
    return request({
        url: '/Patient/getPatientJoinTrialInitList',
        method: 'post',
        data
    })
}

// 检查->患者可加入项目列表（下拉选框）
export function getPatientJoinTrialInitSelectList(data) {
    return request({
        url: '/Patient/getPatientJoinTrialInitSelectList',
        method: 'post',
        data
    })
}

// 检查->患者已加入项目列表
export function getPatientJoinedTrialList(data) {
    return request({
        url: '/Patient/getPatientJoinedTrialList',
        method: 'post',
        data
    })
}

// 获取患者列表（下拉框）
export function getTrialSubejctSelectList(data) {
    return request({
        url: '/Patient/getTrialSubejctSelectList',
        method: 'post',
        data
    })
}

// 患者与受试者建立绑定关系
export function addSubjectPatientBinding(data) {
    return request({
        url: '/Patient/addSubjectPatientBinding',
        method: 'post',
        data
    })
}

// 患者与受试者移除绑定关系
export function deleteSubjectPatientBinding(params) {
    return request({
        url: '/Patient/deleteSubjectPatientBinding',
        method: 'delete',
        params
    })
}

// 获取患者检查列表
export function getPatientStudyList(data) {
    return request({
        url: '/Patient/getPatientStudyList',
        method: 'post',
        data
    })
}

// 绑定访视->获取患者检查列表
export function getVisitPatientStudyList(data) {
    return request({
        url: '/Patient/getVisitPatientStudyList',
        method: 'post',
        data
    })
}

// 绑定访视->获取已存在的访视
export function getSubjectVisitSelectList(data) {
    return request({
        url: '/Patient/getSubjectVisitSelectList',
        method: 'post',
        data
    })
}

// 绑定访视->添加或更新访视
export function addOrUpdateSubjectVisit(data) {
    return request({
        url: '/Patient/addOrUpdateSubjectVisit',
        method: 'post',
        data
    })
}

// 绑定访视->确认患者与访视关系
export function addSubjectPatientStudyBinding(data) {
    return request({
        url: '/Patient/addSubjectPatientStudyBinding',
        method: 'post',
        data
    })
}

// 绑定访视->提交患者与访视关系
export function submitVisitStudyBinding(data) {
    return request({
        url: '/Patient/submitVisitStudyBinding',
        method: 'post',
        data
    })
}

// 清除数据
export function DeletePatientStudyAllData(params) {
    return request({
        url: '/Patient/DeletePatientStudyAllData',
        method: 'delete',
        params
    })
}