Ejemplo n.º 1
0
 protected async Task Delete(object context)
 {
     await ConfirmService.ConfirmAsync(
         async() => await NetService.DeleteRoleAsync(((RoleDisplayDto)context).Id),
         async() => await SearchData(true),
         "确定要删除该记录吗?");
 }
Ejemplo n.º 2
0
 protected async Task Delete(object obj)
 {
     if (obj is ReplyDisplayDto dto)
     {
         await ConfirmService.ConfirmAsync(
             async() => await NetService.DeleteReply(dto.Id),
             async() => await SearchData(true));
     }
 }
Ejemplo n.º 3
0
 protected async Task Resume(object obj)
 {
     if (obj is TopicDisplayDto dto)
     {
         await ConfirmService.ConfirmAsync(
             async() => await NetService.ResumeTopic(dto.Id),
             async() => await SearchData(true)
             );
     }
 }
Ejemplo n.º 4
0
 protected async Task Resume(object obj)
 {
     if (obj is UserDisplayDto dto)
     {
         await ConfirmService.ConfirmAsync(
             async() => await NetService.ResumeUser(dto.Id),
             async() => await SearchData(true),
             "确定要激活该账号吗?");
     }
 }
Ejemplo n.º 5
0
 protected async Task Resume(object obj)
 {
     if (obj is VersionDisplayDto dto)
     {
         await ConfirmService.ConfirmAsync(
             async() => await NetService.ResumeVersion(dto.Id),
             async() => await SearchData(true),
             "确定要删除?");
     }
 }
Ejemplo n.º 6
0
 protected async Task Delete(object obj)
 {
     if (obj is BannerDisplayDto dto)
     {
         await ConfirmService.ConfirmAsync(
             async() => await NetService.DeleteBanner(dto.Id),
             async() => await SearchData(true),
             "确定要删除?");
     }
 }
Ejemplo n.º 7
0
        protected async Task ResetPassword(object obj)
        {
            if (obj is UserDisplayDto dto)
            {
                await ConfirmService.ConfirmAsync(
                    async() => await NetService.ResetPassword(dto.Id),
                    async result =>
                {
                    await MessageBox.AlertAsync($"重置密码成功,新密码为{result.Data?.ToString()},请牢记");
                    //todo--发送短信至用户
                    await SearchData(true);
                },

                    "确定要重置密码吗?");
            }
        }