shop_stat.php 4.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166
  1. <?php
  2. // if (Dever::load('manage/auth')->checkFunc('bill.member_stat', 'edit1', '导出数据')) {
  3. // $excel = true;
  4. // }else{
  5. // $excel = false;
  6. // }
  7. $shop = function()
  8. {
  9. $array = array();
  10. $data = Dever::db('shop/info-state');
  11. if($data)
  12. {
  13. $array += $data;
  14. }
  15. return $array;
  16. };
  17. $config = array
  18. (
  19. # 表名
  20. 'name' => 'shop_stat',
  21. # 显示给用户看的名称
  22. 'lang' => '归店统计',
  23. 'order' => -10,
  24. # 数据结构 不同的字段放这里
  25. 'struct' => array
  26. (
  27. 'id' => array
  28. (
  29. 'type' => 'int-11',
  30. 'name' => 'ID',
  31. 'default' => '',
  32. 'desc' => '',
  33. 'match' => 'is_numeric',
  34. //'list' => true,
  35. ),
  36. 'month' => array
  37. (
  38. 'type' => 'int-11',
  39. 'name' => '月份',
  40. 'default' => '',
  41. 'match' => 'is_numeric',
  42. 'desc' => '',
  43. 'search' => 'month',
  44. 'list' => 'date("Y-m", {month})',
  45. ),
  46. 'shop_id' => array
  47. (
  48. 'type' => 'int-11',
  49. 'name' => '店铺名称',
  50. 'default' => '',
  51. 'desc' => '店铺名称',
  52. 'match' => 'is_numeric',
  53. 'option' => $shop,
  54. 'list' => true,
  55. //'list_order' => 6,
  56. ),
  57. 'num' => array
  58. (
  59. 'type' => 'int-11',
  60. 'name' => '代理商总数量',
  61. 'default' => '0',
  62. 'desc' => '代理商总数量',
  63. 'match' => 'is_numeric',
  64. 'search' => 'order',
  65. // 'list' => true,
  66. ),
  67. 'dl_num' => array
  68. (
  69. 'type' => 'int-11',
  70. 'name' => '代理商数量-除掉创v的数量',
  71. 'default' => '0',
  72. 'desc' => '代理商数量',
  73. 'match' => 'is_numeric',
  74. 'search' => 'order',
  75. 'list' => true,
  76. ),
  77. 'v_num' => array
  78. (
  79. 'type' => 'int-11',
  80. 'name' => '创V数量',
  81. 'default' => '0',
  82. 'desc' => '创V数量',
  83. 'match' => 'is_numeric',
  84. 'search' => 'order',
  85. 'list' => true,
  86. ),
  87. 'money' => array
  88. (
  89. 'type' => 'decimal-11,2',
  90. 'name' => '代理商的总业绩',
  91. 'default' => '0',
  92. 'desc' => '代理商的总业绩',
  93. 'match' => 'is_numeric',
  94. 'update' => 'text',
  95. // 'list' => true,
  96. ),
  97. 'dl_money' => array
  98. (
  99. 'type' => 'decimal-11,2',
  100. 'name' => '代理商业绩',
  101. 'default' => '0',
  102. 'desc' => '代理商业绩',
  103. 'match' => 'is_numeric',
  104. 'update' => 'text',
  105. 'list' => true,
  106. ),
  107. 'v_money' => array
  108. (
  109. 'type' => 'decimal-11,2',
  110. 'name' => '创V总业绩',
  111. 'default' => '0',
  112. 'desc' => '创V总业绩',
  113. 'match' => 'is_numeric',
  114. 'update' => 'text',
  115. 'list' => true,
  116. ),
  117. 'state' => array
  118. (
  119. 'type' => 'tinyint-1',
  120. 'name' => '数据状态',
  121. 'default' => '1',
  122. 'desc' => '请选择状态',
  123. 'match' => 'is_numeric',
  124. ),
  125. 'cdate' => array
  126. (
  127. 'type' => 'int-11',
  128. 'name' => '发布时间',
  129. 'match' => array('is_numeric', time()),
  130. 'desc' => '',
  131. # 只有insert时才生效
  132. 'insert' => true,
  133. //'search' => 'date',
  134. //'list' => 'date("Y-m-d H:i:s", {cdate})',
  135. ),
  136. ),
  137. 'manage' => array
  138. (
  139. 'insert' => false,
  140. 'edit' => false,
  141. 'delete' => false,
  142. 'num' => false,
  143. // 'excel' => $excel,
  144. ),
  145. # request 请求接口定义
  146. 'request' => array
  147. (
  148. ),
  149. );
  150. return $config;