Implemented structure for push Notifications
This commit is contained in:
26
lib/api/mhsl/notify/register/notifyRegister.dart
Normal file
26
lib/api/mhsl/notify/register/notifyRegister.dart
Normal file
@ -0,0 +1,26 @@
|
||||
|
||||
import 'dart:convert';
|
||||
import 'dart:developer';
|
||||
|
||||
import 'package:http/http.dart' as http;
|
||||
|
||||
import '../../mhslApi.dart';
|
||||
import 'notifyRegisterParams.dart';
|
||||
|
||||
class NotifyRegister extends MhslApi<void> {
|
||||
NotifyRegisterParams params;
|
||||
NotifyRegister(this.params) : super("notify/register/");
|
||||
|
||||
|
||||
@override
|
||||
void assemble(String raw) {
|
||||
|
||||
}
|
||||
|
||||
@override
|
||||
Future<http.Response> request(Uri uri) {
|
||||
String requestString = jsonEncode(params.toJson());
|
||||
log(requestString);
|
||||
return http.post(uri, body: requestString);
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user