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

// 获取轮播图
export function loadIndexs(data) {
	return request({
		url: '/api/index',
		method: 'get',
		data
	});
}

// 获取科普文章列表
export function getArticList(data) {
	return request({
		url: '/api/article/lst',
		method: 'get',
		data
	});
}

// 获取博爱项目文章列表
export function itemList(data) {
	return request({
		url: '/api/article/list/4',
		method: 'get',
		data
	});
}
//上传图片
export function upload(data) {
	return upFilse({
		url: '/api/upload/image',
		method: 'post',
		data
	});
}
// 促销商品
export function groom4(data) {
	return request({
		url: '/api/groom/list/4',
		method: 'get',
		data
	});
}


// 造血干细胞捐献
export function getList(data) {
	return request({
		url: '/api/sign_cell',
		method: 'post',
		data
	});
}

// 救护者页面获取参与人数  
export function getNumber(data) {
	return request({
		url: '/api/get_rescuer',
		method: 'get',
		data
	});
}

// 志愿者报名
export function add_volunteers(data) {
	return request({
		url: '/api/volunteer/apply',
		method: 'post',
		data
	});
}

// joinSec
export function vip(data) {
	return request({
		url: '/api/User/setuser',
		method: 'post',
		data
	});
}
//  器官捐赠
export function joinSecc(data) {
	return request({
		url: '/api/donate/apply',
		method: 'post',
		data
	});
}

//捐献类目
export function donate_ify(data) {
	return request({
		url:'/api/donate/ify',
		method:'get',
		data
	})
}

// 获取定位
export function getdis(data) {
	return request({
		url: '/api/getdis',
		method: 'get',
		data
	});
}
// 立即救援
export function tocall(data) {
	return request({
		url: '/api/do_getdis',
		method: 'get',
		data
	});
}

// 救护培训报名 
export function training(data) {
	return request({
		url: '/api/training/lst',
		method: 'get',
		data
	});
}

// 求助记录 getsee
export function getseek(data) {
	return request({
		url: '/api/seek',
		method: 'get',
		data
	});
}

// getcomAddress 获取常用地址
export function getcomAddress(data) {
	return request({
		url: '/api/get_commonly',
		method: 'get',
		data
	});
}

// 救援记录 rescue
export function getrescue(data) {
	return request({
		url: '/api/rescueee',
		method: 'get',
		data
	});
}

export function change_rescue(data) {
	return request({
		url: '/api/change_rescue',
		method: 'get',
		data
	});
}

// 获取ADE经纬度 getListAED getDistance
export function getListAED(data) {
	return request({
		url: '/api/getAed',
		method: 'get',
		data
	});
}

export function getDistance(data) {
	return request({
		url: '/api/aeddiss',
		method: 'get',
		data
	});
}

// deleteList 删除救援地址
export function deleteList(data) {
	return request({
		url: '/api/rescue/sos_del',
		method: 'get',
		data
	});
}
//获取机构
export function getListMechanism(data) {
	return request({
		url: '/api/mechanism',
		method: 'get',
		data
	});
}

// 爱心帮扶
export function one_help(data) {
	return request({
		url: '/api/one_help',
		method: 'get',
		data
	});
}

export function getCompany(data) {
	return request({
		url: '/api/index/company',
		method: 'get',
		data
	});
}

export function getVipmoney(data) {
	return request({
		url: '/api/Level/ify',
		method: 'get',
		data
	});
}

//创建入会订单
export function createOrder(data) {
	return request({
		url: '/api/Level/create',
		method: 'post',
		data
	});
}