You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

DepartmentCreate.cs 1.1 KiB

4 years ago
12345678910111213141516171819202122232425262728293031323334353637383940
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using System.Text;
  5. using System.Threading.Tasks;
  6. namespace Learun.Application.WeChat
  7. {
  8. /// <summary>
  9. /// 创建部门
  10. /// </summary>
  11. public class DepartmentCreate : OperationRequestBase<DepartmentResult, HttpPostRequest>
  12. {
  13. protected override string Url()
  14. {
  15. return "https://qyapi.weixin.qq.com/cgi-bin/department/create?access_token=ACCESS_TOKEN";
  16. }
  17. /// <summary>
  18. /// 部门名称。长度限制为1~64个字符
  19. /// </summary>
  20. /// <returns></returns>
  21. [Length(1, 64)]
  22. [IsNotNull]
  23. public string name { get; set; }
  24. /// <summary>
  25. /// 父亲部门id。根部门id为1
  26. /// </summary>
  27. /// <returns></returns>
  28. [IsNotNull]
  29. public string parentid { get; set; }
  30. /// <summary>
  31. /// 在父部门中的次序。从1开始,数字越大排序越靠后
  32. /// </summary>
  33. /// <returns></returns>
  34. public string order { get; set; }
  35. }
  36. }