unaudit.php 2.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168
  1. <?php
  2. /**
  3. * tester
  4. */
  5. $status = array
  6. (
  7. 1 => '撤回中',
  8. 2 => '撤回成功',
  9. 3 => '撤回失败',
  10. );
  11. $user = function()
  12. {
  13. $array = array();
  14. $info = Dever::load('component/user-state');
  15. if($info)
  16. {
  17. $array += $info;
  18. }
  19. return $array;
  20. };
  21. $template = function()
  22. {
  23. $array = array();
  24. $info = Dever::load('component_applet/template-state');
  25. if($info)
  26. {
  27. $array += $info;
  28. }
  29. return $array;
  30. };
  31. $version = function()
  32. {
  33. $array = array();
  34. $info = Dever::load('component_applet/version-state');
  35. if($info)
  36. {
  37. $array += $info;
  38. }
  39. return $array;
  40. };
  41. return array
  42. (
  43. # 表名
  44. 'name' => 'unaudit',
  45. # 显示给用户看的名称
  46. 'lang' => '审核撤回历史',
  47. 'order' => 1,
  48. # 数据结构
  49. 'struct' => array
  50. (
  51. 'id' => array
  52. (
  53. 'type' => 'int-11',
  54. 'name' => 'ID',
  55. 'default' => '',
  56. 'desc' => '',
  57. 'match' => 'is_numeric',
  58. 'search' => 'order',
  59. //'list' => true,
  60. ),
  61. 'project_id' => array
  62. (
  63. 'type' => 'int-11',
  64. 'name' => '项目',
  65. 'default' => '',
  66. 'desc' => '请输入项目',
  67. 'match' => 'is_numeric',
  68. ),
  69. 'version_id' => array
  70. (
  71. 'type' => 'int-11',
  72. 'name' => '版本',
  73. 'default' => '',
  74. 'desc' => '版本',
  75. 'match' => 'is_numeric',
  76. //'search' => 'order,fulltext',
  77. 'update' => 'checkbox',
  78. 'option' => $version,
  79. //'list' => true,
  80. ),
  81. 'name' => array
  82. (
  83. 'type' => 'varchar-60',
  84. 'name' => '版本号',
  85. 'default' => '',
  86. 'desc' => '版本号',
  87. 'match' => 'is_string',
  88. 'update' => 'text',
  89. 'search' => 'fulltext',
  90. 'list' => '"{name}" ? "{name}" : Dever::load("component_applet/version-one#name", {version_id})',
  91. ),
  92. 'user_id' => array
  93. (
  94. 'type' => 'int-11',
  95. 'name' => '用户',
  96. 'default' => '',
  97. 'desc' => '用户',
  98. 'match' => 'is_numeric',
  99. //'search' => 'order,fulltext',
  100. 'update' => 'select',
  101. 'option' => $user,
  102. 'list' => true,
  103. ),
  104. 'result' => array
  105. (
  106. 'type' => 'text-255',
  107. 'name' => '微信返回信息',
  108. 'default' => '',
  109. 'desc' => '微信返回信息',
  110. 'match' => 'option',
  111. 'update' => 'textarea',
  112. 'list' => true,
  113. 'modal' => '查看详情',
  114. ),
  115. 'status' => array
  116. (
  117. 'type' => 'tinyint-1',
  118. 'name' => '撤回状态',
  119. 'default' => '1',
  120. 'desc' => '撤回状态',
  121. 'match' => 'is_numeric',
  122. 'update' => 'select',
  123. 'option' => $status,
  124. 'list' => true,
  125. ),
  126. 'state' => array
  127. (
  128. 'type' => 'tinyint-1',
  129. 'name' => '状态',
  130. 'default' => '1',
  131. 'desc' => '请选择状态',
  132. 'match' => 'is_numeric',
  133. ),
  134. 'cdate' => array
  135. (
  136. 'type' => 'int-11',
  137. 'name' => '提交时间',
  138. 'match' => array('is_numeric', time()),
  139. 'desc' => '',
  140. # 只有insert时才生效
  141. 'insert' => true,
  142. 'list' => 'date("Y-m-d H:i:s", {cdate})',
  143. ),
  144. ),
  145. 'top' => Dever::config('base', 'component')->top,
  146. 'manage' => array
  147. (
  148. 'edit' => false,
  149. 'delete' => false,
  150. 'insert' => false,
  151. ),
  152. );