action.php 1.9 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495
  1. <?php
  2. return array
  3. (
  4. # 表名
  5. 'name' => 'action',
  6. # 显示给用户看的名称
  7. 'lang' => '用户行为配置',
  8. 'order' => 10,
  9. 'check' => 'key',
  10. # 数据结构
  11. 'struct' => array
  12. (
  13. 'id' => array
  14. (
  15. 'type' => 'int-11',
  16. 'name' => 'ID',
  17. 'default' => '',
  18. 'desc' => '',
  19. 'match' => 'is_numeric',
  20. ),
  21. 'name' => array
  22. (
  23. 'type' => 'varchar-80',
  24. 'name' => '行为名称',
  25. 'default' => '',
  26. 'desc' => '请输入行为名称',
  27. 'match' => 'is_string',
  28. 'update' => 'text',
  29. 'search' => 'fulltext',
  30. 'list' => true,
  31. ),
  32. 'key' => array
  33. (
  34. 'type' => 'varchar-80',
  35. 'name' => '行为标识-用于程序中统计积分总数',
  36. 'default' => '',
  37. 'desc' => '行为标识',
  38. 'match' => 'is_string',
  39. 'update' => 'text',
  40. 'search' => 'fulltext',
  41. 'list' => true,
  42. ),
  43. 'state' => array
  44. (
  45. 'type' => 'tinyint-1',
  46. 'name' => '状态',
  47. 'default' => '1',
  48. 'desc' => '请选择状态',
  49. 'match' => 'is_numeric',
  50. ),
  51. 'cdate' => array
  52. (
  53. 'type' => 'int-11',
  54. 'name' => '录入时间',
  55. 'match' => array('is_numeric', time()),
  56. 'desc' => '',
  57. # 只有insert时才生效
  58. 'insert' => true,
  59. ),
  60. ),
  61. 'manage' => array
  62. (
  63. 'insert' => false,
  64. 'delete' => false,
  65. 'edit' => false,
  66. # 列表
  67. 'list_button' => array
  68. (
  69. 'list' => array('未计算日志', '"action_log&search_option_action_id={id}&oper_parent=action"'),
  70. 'list1' => array('已计算日志', '"action_log_finish&search_option_action_id={id}&oper_parent=action"'),
  71. ),
  72. ),
  73. # request 请求接口定义
  74. 'request' => array
  75. (
  76. 'getData' => array
  77. (
  78. # 匹配的正则或函数 选填项
  79. 'option' => array
  80. (
  81. 'state' => 1,
  82. ),
  83. 'type' => 'all',
  84. 'order' => array('id' => 'desc'),
  85. 'col' => '*|id',
  86. ),
  87. )
  88. );