oauth.php 2.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135
  1. <?php
  2. /**
  3. * token
  4. */
  5. return array
  6. (
  7. # 表名
  8. 'name' => 'oauth',
  9. # 显示给用户看的名称
  10. 'lang' => 'oauth数据表',
  11. 'menu' => false,
  12. # 数据结构
  13. 'struct' => array
  14. (
  15. 'id' => array
  16. (
  17. 'type' => 'int-11',
  18. 'name' => 'ID',
  19. 'default' => '',
  20. 'desc' => '',
  21. 'match' => 'is_numeric',
  22. 'search' => 'order',
  23. 'list' => true,
  24. ),
  25. 'project_id' => array
  26. (
  27. 'type' => 'int-11',
  28. 'name' => '项目',
  29. 'default' => '',
  30. 'desc' => '请输入项目',
  31. 'match' => 'is_numeric',
  32. //'search' => 'order,fulltext',
  33. 'update' => 'text',
  34. 'list' => '{project_id} > 0 ? Dever::load("main/project-one#name", {project_id}) : "未知"',
  35. ),
  36. 'openid' => array
  37. (
  38. 'type' => 'varchar-60',
  39. 'name' => '用户id-如果是第三方平台,则为appid',
  40. 'default' => '',
  41. 'desc' => '用户id',
  42. 'match' => 'is_string',
  43. //'search' => 'order,fulltext',
  44. 'update' => 'text',
  45. 'list' => true,
  46. ),
  47. 'unionid' => array
  48. (
  49. 'type' => 'varchar-60',
  50. 'name' => '用户唯一id-如果是第三方平台,则为appid',
  51. 'default' => '',
  52. 'desc' => '用户唯一id',
  53. 'match' => 'is_string',
  54. //'search' => 'order,fulltext',
  55. 'update' => 'text',
  56. 'list' => true,
  57. ),
  58. 'value' => array
  59. (
  60. 'type' => 'varchar-255',
  61. 'name' => 'token标识',
  62. 'default' => '',
  63. 'desc' => 'token标识',
  64. 'match' => 'is_string',
  65. 'update' => 'text',
  66. 'list' => true,
  67. 'modal' => '查看',
  68. ),
  69. 'refresh' => array
  70. (
  71. 'type' => 'varchar-255',
  72. 'name' => 'refresh token标识',
  73. 'default' => '',
  74. 'desc' => 'refresh token标识',
  75. 'match' => 'is_string',
  76. 'update' => 'text',
  77. 'list' => true,
  78. 'modal' => '查看',
  79. ),
  80. 'expires' => array
  81. (
  82. 'type' => 'int-11',
  83. 'name' => '过期时间',
  84. 'default' => '',
  85. 'desc' => '过期时间',
  86. 'match' => 'is_numeric',
  87. 'update' => 'text',
  88. 'list' => true,
  89. ),
  90. 'mdate' => array
  91. (
  92. 'type' => 'int-11',
  93. 'name' => '更新时间',
  94. 'match' => array('is_numeric', time()),
  95. 'desc' => '',
  96. 'list' => 'date("Y-m-d H:i:s", {mdate})',
  97. ),
  98. 'state' => array
  99. (
  100. 'type' => 'tinyint-1',
  101. 'name' => '状态',
  102. 'default' => '1',
  103. 'desc' => '请选择状态',
  104. 'match' => 'is_numeric',
  105. ),
  106. 'cdate' => array
  107. (
  108. 'type' => 'int-11',
  109. 'name' => '录入时间',
  110. 'match' => array('is_numeric', time()),
  111. 'desc' => '',
  112. # 只有insert时才生效
  113. 'insert' => true,
  114. ),
  115. ),
  116. //'top' => 'main/project_id',
  117. 'manage' => array
  118. (
  119. 'delete' => false,
  120. 'insert' => false,
  121. 'edit' => false,
  122. ),
  123. );