role_reward_goods.php 3.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130
  1. <?php
  2. $type = array
  3. (
  4. 1 => '商品',
  5. 2 => '礼品卡',
  6. 3 => '名额',
  7. );
  8. return array
  9. (
  10. # 表名
  11. 'name' => 'role_reward_goods',
  12. # 显示给用户看的名称
  13. 'lang' => '名额权益设置',
  14. 'menu' => false,
  15. 'set' => array
  16. (
  17. 'type' => $type,
  18. ),
  19. # 数据结构
  20. 'struct' => array
  21. (
  22. 'id' => array
  23. (
  24. 'type' => 'int-11',
  25. 'name' => 'ID',
  26. 'default' => '',
  27. 'desc' => '',
  28. 'match' => 'is_numeric',
  29. 'search' => 'order',
  30. 'update' => 'hidden',
  31. //'list' => true,
  32. ),
  33. 'reward_give_id' => array
  34. (
  35. 'type' => 'int-11',
  36. 'name' => '奖励id',
  37. 'default' => '',
  38. 'desc' => '奖励id',
  39. 'match' => 'is_numeric',
  40. 'update' => 'hidden',
  41. 'value' => Dever::input('search_option_reward_give_id'),
  42. ),
  43. 'type' => array
  44. (
  45. 'type' => 'tinyint-1',
  46. 'name' => '类型',
  47. 'default' => '1',
  48. 'desc' => '类型',
  49. 'match' => 'is_numeric',
  50. 'update' => 'radio',
  51. 'option' => $type,
  52. ),
  53. 'type_id' => array
  54. (
  55. 'type' => 'int-11',
  56. 'name' => '类型id',
  57. 'default' => '-1',
  58. 'desc' => '类型id',
  59. 'match' => 'is_numeric',
  60. ),
  61. 'sku_id' => array
  62. (
  63. 'type' => 'int-11',
  64. 'name' => 'sku_id',
  65. 'default' => '-1',
  66. 'desc' => 'sku_id',
  67. 'match' => 'is_numeric',
  68. ),
  69. 'num' => array
  70. (
  71. 'type' => 'int-11',
  72. 'name' => '数量',
  73. 'default' => '',
  74. 'desc' => '数量',
  75. 'match' => 'is_numeric',
  76. 'search' => 'select',
  77. 'list' => true,
  78. ),
  79. 'state' => array
  80. (
  81. 'type' => 'tinyint-1',
  82. 'name' => '状态',
  83. 'default' => '1',
  84. 'desc' => '请选择状态',
  85. 'match' => 'is_numeric',
  86. ),
  87. 'cdate' => array
  88. (
  89. 'type' => 'int-11',
  90. 'name' => '创建时间',
  91. 'match' => array('is_numeric', time()),
  92. 'desc' => '',
  93. # 只有insert时才生效
  94. //'insert' => true,
  95. 'search' => 'date',
  96. 'list' => 'date("Y-m-d H:i:s", {cdate})',
  97. ),
  98. ),
  99. 'manage' => array
  100. (
  101. ),
  102. 'request' => array
  103. (
  104. 'getData' => array
  105. (
  106. # 匹配的正则或函数 选填项
  107. 'option' => array
  108. (
  109. 'reward_give_id' => 'yes',
  110. 'state' => 1,
  111. ),
  112. 'order' => array('type' => 'desc', 'id' => 'desc'),
  113. 'type' => 'all',
  114. 'col' => '*',
  115. ),
  116. ),
  117. );