BaseClass.cs 1.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using System.Data;
  5. using System.Text.RegularExpressions;
  6. using Library;
  7. using MySystem.Service.Main;
  8. using MySystem.Service.Bs;
  9. using System.IO;
  10. using System.Web;
  11. using Microsoft.IdentityModel.Tokens;
  12. using System.Security.Claims;
  13. using System.IdentityModel.Tokens.Jwt;
  14. using System.Text;
  15. using AppConfig;
  16. namespace MySystem
  17. {
  18. /// <summary>
  19. /// 基础功能方法
  20. /// </summary>
  21. public class BaseClass
  22. {
  23. #region 推送个人消息
  24. /// <summary>
  25. /// 推送个人消息
  26. /// </summary>
  27. /// <param name="UserId">接收创客</param>
  28. /// <param name="MsgType">展示类型(0 html页面 1 指定url 2 简单中文描述)</param>
  29. /// <param name="Title">标题</param>
  30. /// <param name="Content">内容</param>
  31. /// <param name="Summary">简介</param>
  32. public static void SendPersonalMsg(int UserId, int MsgType, string Title, string Content, string Summary)
  33. {
  34. RedisDbconn.Instance.AddList("MsgPersonalQueue", Newtonsoft.Json.JsonConvert.SerializeObject(new MySystem.Models.Main.MsgPersonal()
  35. {
  36. UserId = UserId, //接收创客
  37. MsgType = MsgType, //展示类型
  38. Title = Title, //标题
  39. Content = Content, //内容
  40. Summary = Summary, //简介
  41. }));
  42. }
  43. #endregion
  44. }
  45. }