import request from '/@/utils/request';

// ==================== 代收订单相关 API ====================

export function fetchPayOrderList(query?: Object) {
	return request({
		url: 'open/admin/payOrder/page',
		method: 'post',
		data: query,
	});
}

export function fetchPayOrderStatistics(query?: Object) {
	return request({
		url: 'open/admin/payOrder/statistics',
		method: 'post',
		data: query,
	});
}

// ==================== 代付订单相关 API ====================

export function fetchWithdrawOrderList(query?: Object) {
	return request({
		url: 'open/admin/withdrawOrder/page',
		method: 'post',
		data: query,
	});
}

// ==================== 回调日志相关 API ====================

export function fetchPayNotifyLog(appId: string, orderId: string) {
	return request({
		url: 'open/admin/payNotify/page',
		method: 'get',
		params: {
			appId,
			orderId,
		},
	});
}
