discount_goods.php 2.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899
  1. <?php
  2. return array
  3. (
  4. # 表名
  5. 'name' => 'discount_goods',
  6. # 显示给用户看的名称
  7. 'lang' => '折扣商品设置',
  8. 'menu' => false,
  9. # 数据结构
  10. 'struct' => array
  11. (
  12. 'id' => array
  13. (
  14. 'type' => 'int-11',
  15. 'name' => 'ID',
  16. 'default' => '',
  17. 'desc' => '',
  18. 'match' => 'is_numeric',
  19. 'search' => 'order',
  20. 'update' => 'hidden',
  21. //'list' => true,
  22. ),
  23. 'discount_id' => array
  24. (
  25. 'type' => 'int-11',
  26. 'name' => '折扣',
  27. 'default' => '',
  28. 'desc' => '折扣',
  29. 'match' => 'is_numeric',
  30. 'update' => 'hidden',
  31. 'search' => 'hidden',
  32. 'value' => Dever::input('search_option_discount_id'),
  33. 'list' => 'Dever::load("act/discount-find#name", "{discount_id}")',
  34. ),
  35. 'cate_id' => array
  36. (
  37. 'type' => 'int-11',
  38. 'name' => '商品分类id',
  39. 'default' => '-1',
  40. 'desc' => '商品id',
  41. 'match' => 'is_numeric',
  42. ),
  43. 'goods_id' => array
  44. (
  45. 'type' => 'int-11',
  46. 'name' => '商品id',
  47. 'default' => '-1',
  48. 'desc' => '商品id',
  49. 'match' => 'is_numeric',
  50. ),
  51. 'state' => array
  52. (
  53. 'type' => 'tinyint-1',
  54. 'name' => '状态',
  55. 'default' => '1',
  56. 'desc' => '请选择状态',
  57. 'match' => 'is_numeric',
  58. ),
  59. 'cdate' => array
  60. (
  61. 'type' => 'int-11',
  62. 'name' => '创建时间',
  63. 'match' => array('is_numeric', time()),
  64. 'desc' => '',
  65. # 只有insert时才生效
  66. //'insert' => true,
  67. 'search' => 'date',
  68. 'list' => 'date("Y-m-d H:i:s", {cdate})',
  69. ),
  70. ),
  71. 'manage' => array
  72. (
  73. ),
  74. 'request' => array
  75. (
  76. 'getData' => array
  77. (
  78. # 匹配的正则或函数 选填项
  79. 'option' => array
  80. (
  81. 'discount_id' => 'yes',
  82. 'state' => 1,
  83. ),
  84. 'order' => array('id' => 'desc'),
  85. 'type' => 'all',
  86. 'col' => '*|goods_id|',
  87. ),
  88. ),
  89. );