import request from '@/utils/request'
import {upFilse} from '@/utils/request'

// 求救记录
export function mySosList(data) {
	return request({
		url: '/api/Sos/mySosList',
		method: 'post',
		data
	});
}

// 援助记录
export function toMySosList(data) {
	return request({
		url: '/api/Sos/toMySosList',
		method: 'post',
		data
	});
}
// 救援者列表
export function getAroundHelper(data) {
	return request({
		url: '/api/Sos/getAroundHelper',
		method: 'post',
		data
	});
}
// 申请成为救援者
export function toBeHelper(data) {
	return request({
		url: '/api/Sos/toBeHelper',
		method: 'post',
		data
	});
}
//上传图片
export function upload(data) {
	return upFilse({
		url: '/api/Common/upload',
		method: 'post',
		data
	});
}
//机构列表
export function hospitalList(data) {
	return request({
		url: '/api/Hospital/hospitalList',
		method: 'post',
		data
	});
}
//发送求救信息
export function sendSos(data) {
	return request({
		url: '/api/Sos/sendSos',
		method: 'post',
		data
	});
}
//接受求救信号
export function accessSos(data) {
	return request({
		url: '/api/Sos/accessSos',
		method: 'post',
		data
	});
}
//拒接求救信号
export function refuseSos(data) {
	return request({
		url: '/api/Sos/refuseSos',
		method: 'post',
		data
	});
}
//救援记录详情
export function sosInfo(data) {
	return request({
		url: '/api/Sos/sosInfo',
		method: 'post',
		data
	});
}
//救援记录详情
export function successSos(data) {
	return request({
		url: '/api/Sos/successSos',
		method: 'post',
		data
	});
}
//所有的救援者
export function getAllHelper(data) {
	return request({
		url: '/api/Sos/getAllHelper',
		method: 'post',
		data
	});
}
//最新待救援
export function newSos(data) {
	return request({
		url: '/api/Sos/newSos',
		method: 'post',
		data
	});
}
//修改常用地址
export function changePoint(data) {
	return request({
		url: '/api/User/changePoint',
		method: 'post',
		data
	});
}
//获取用户sig
export function getSig(data) {
	return request({
		url: '/api/trtc/getSig',
		method: 'post',
		data
	});
}