rate.php 2.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118
  1. <?php
  2. return array
  3. (
  4. # 表名
  5. 'name' => 'rate',
  6. # 显示给用户看的名称
  7. 'lang' => '税率设置',
  8. # 是否显示在后台菜单
  9. 'order' => 10,
  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. 'list' => true,
  21. 'order' => 'asc',
  22. ),
  23. 'name' => array
  24. (
  25. 'type' => 'varchar-150',
  26. 'name' => '税率名称',
  27. 'default' => '',
  28. 'desc' => '税率名称',
  29. 'match' => 'is_string',
  30. 'update' => 'text',
  31. 'search' => 'fulltext',
  32. 'list' => true,
  33. 'edit' => true,
  34. ),
  35. 'value' => array
  36. (
  37. 'type' => 'varchar-150',
  38. 'name' => '税率值',
  39. 'default' => '',
  40. 'desc' => '税率值',
  41. 'match' => 'is_string',
  42. 'update' => 'text',
  43. 'search' => 'fulltext',
  44. 'list' => '{value} ? {value} : 0',
  45. 'edit' => true,
  46. ),
  47. 'reorder' => array
  48. (
  49. 'type' => 'int-11',
  50. 'name' => '排序(数值越大越靠前)',
  51. 'default' => '1',
  52. 'desc' => '请输入排序',
  53. 'match' => 'option',
  54. //'update' => 'text',
  55. 'search' => 'order',
  56. 'list_name' => '排序',
  57. 'list' => true,
  58. 'order' => 'desc',
  59. 'edit' => true,
  60. ),
  61. 'state' => array
  62. (
  63. 'type' => 'tinyint-1',
  64. 'name' => '状态',
  65. 'default' => '1',
  66. 'desc' => '请选择状态',
  67. 'match' => 'is_numeric',
  68. ),
  69. 'cdate' => array
  70. (
  71. 'type' => 'int-11',
  72. 'name' => '录入时间',
  73. 'match' => array('is_numeric', time()),
  74. 'desc' => '',
  75. # 只有insert时才生效
  76. 'insert' => true,
  77. //'search' => 'date',
  78. //'list' => 'date("Y-m-d H:i:s", {cdate})',
  79. ),
  80. ),
  81. 'manage' => array
  82. (
  83. 'insert' => false,
  84. 'edit' => false,
  85. # 自定义快捷新增和编辑
  86. 'button' => array
  87. (
  88. '新增' => array('fast'),
  89. ),
  90. 'list_button' => array
  91. (
  92. 'edit' => array('编辑'),
  93. )
  94. ),
  95. 'default' => array
  96. (
  97. 'col' => 'name,value,state,cdate',
  98. 'value' => array
  99. (
  100. '"0税率", "0", 1,' . DEVER_TIME,
  101. ),
  102. ),
  103. 'request' => array
  104. (
  105. )
  106. );