34 lines
715 B
C#
34 lines
715 B
C#
|
|
|
|||
|
|
|
|||
|
|
using Plugin.LocalNotification;
|
|||
|
|
|
|||
|
|
namespace Bitget_App
|
|||
|
|
{
|
|||
|
|
public partial class MainPage : ContentPage
|
|||
|
|
{
|
|||
|
|
|
|||
|
|
public MainPage()
|
|||
|
|
{
|
|||
|
|
InitializeComponent();
|
|||
|
|
Permissions.RequestAsync<Permissions.PostNotifications>();
|
|||
|
|
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
private void OnCounterClicked(object sender, EventArgs e)
|
|||
|
|
{
|
|||
|
|
var request = new NotificationRequest
|
|||
|
|
{
|
|||
|
|
NotificationId = 1000,
|
|||
|
|
Title = "MEDIUM",
|
|||
|
|
Subtitle = "Hello! I'm Erdal",
|
|||
|
|
Description = "Local Push Notification",
|
|||
|
|
BadgeNumber = 42
|
|||
|
|
};
|
|||
|
|
|
|||
|
|
LocalNotificationCenter.Current.Show(request);
|
|||
|
|
|
|||
|
|
}
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
}
|