help.php 2.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114
  1. <?php
  2. $type = array
  3. (
  4. 1 => '门店销售',
  5. 2 => '门店管理',
  6. 3 => '仓库管理',
  7. 4 => '工厂管理',
  8. 5 => '网站',
  9. );
  10. $config = array
  11. (
  12. # 表名
  13. 'name' => 'help',
  14. # 显示给用户看的名称
  15. 'lang' => '帮助中心',
  16. # 后台菜单排序
  17. 'order' => 1,
  18. # 数据结构
  19. 'struct' => array
  20. (
  21. 'id' => array
  22. (
  23. 'type' => 'int-11',
  24. 'name' => 'ID',
  25. 'default' => '',
  26. 'desc' => '',
  27. 'match' => 'is_numeric',
  28. //'search' => 'order',
  29. //'list' => true,
  30. 'order' => 'desc',
  31. ),
  32. 'name' => 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. 'desc' => array
  44. (
  45. 'type' => 'varchar-500',
  46. 'name' => '描述',
  47. 'default' => '',
  48. 'desc' => '描述',
  49. 'match' => 'option',
  50. 'update' => 'textarea',
  51. ),
  52. 'type' => array
  53. (
  54. 'type' => 'int-11',
  55. 'name' => '帮助类型',
  56. 'default' => '1',
  57. 'desc' => '帮助类型',
  58. 'match' => 'is_numeric',
  59. 'update' => 'radio',
  60. 'option' => $type,
  61. 'search' => 'select',
  62. 'list' => true,
  63. ),
  64. 'content' => array
  65. (
  66. 'type' => 'text-255',
  67. 'name' => '内容',
  68. 'default' => '',
  69. 'desc' => '内容',
  70. 'match' => 'is_string',
  71. 'update' => 'editor',
  72. //'list_name' => '链接',
  73. //'list' => 'Dever::load("content/lib/page.link", {id})',
  74. ),
  75. 'state' => array
  76. (
  77. 'type' => 'tinyint-1',
  78. 'name' => '状态',
  79. 'default' => '1',
  80. 'desc' => '请选择状态',
  81. 'match' => 'is_numeric',
  82. ),
  83. 'cdate' => array
  84. (
  85. 'type' => 'int-11',
  86. 'name' => '录入时间',
  87. 'match' => array('is_numeric', time()),
  88. 'desc' => '',
  89. # 只有insert时才生效
  90. 'insert' => true,
  91. 'list' => 'date("Y-m-d H:i:s", {cdate})',
  92. ),
  93. ),
  94. 'manage' => array
  95. (
  96. ),
  97. 'request' => array
  98. (
  99. )
  100. );
  101. return $config;