0417 0022
更新
This commit is contained in:
@@ -283,4 +283,28 @@ class UserService {
|
||||
throw _getErrorMessage(e);
|
||||
}
|
||||
}
|
||||
// 上传 Sega 成绩数据
|
||||
static Future<Map<String, dynamic>> uploadSegaRating(
|
||||
String token,
|
||||
String segaId,
|
||||
Map<String, dynamic> segaResult,
|
||||
) async {
|
||||
try {
|
||||
final res = await _dio.post(
|
||||
'$baseUrl/api/union/segaReisaRating',
|
||||
queryParameters: {
|
||||
"segaId": segaId,
|
||||
},
|
||||
data: segaResult,
|
||||
options: Options(
|
||||
headers: {
|
||||
"Authorization": token,
|
||||
},
|
||||
),
|
||||
);
|
||||
return Map<String, dynamic>.from(res.data);
|
||||
} on DioException catch (e) {
|
||||
throw _getErrorMessage(e);
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user