user_cash.php 2.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135
  1. <?php
  2. $type = array
  3. (
  4. 1 => '微信',
  5. 2 => '支付宝',
  6. );
  7. $status = array
  8. (
  9. 1 => '申请中',
  10. 2 => '兑现中',
  11. 3 => '已完成',
  12. //4 => '失败',
  13. );
  14. return array
  15. (
  16. # 表名
  17. 'name' => 'user_cash',
  18. # 显示给用户看的名称
  19. 'lang' => '用户兑现',
  20. 'menu' => 'passport',
  21. 'order' => 98,
  22. # 数据结构
  23. 'struct' => array
  24. (
  25. 'id' => array
  26. (
  27. 'type' => 'int-11',
  28. 'name' => 'ID',
  29. 'default' => '',
  30. 'desc' => '',
  31. 'match' => 'is_numeric',
  32. //'search' => 'order',
  33. 'order' => 'desc',
  34. 'list' => true,
  35. ),
  36. 'uid' => array
  37. (
  38. 'type' => 'int-11',
  39. 'name' => '用户名',
  40. 'default' => '',
  41. 'desc' => '用户名',
  42. 'match' => 'is_numeric',
  43. //'update' => 'text',
  44. 'search' => array
  45. (
  46. 'api' => 'passport/user-all',
  47. 'col' => 'username',
  48. 'result' => 'id',
  49. ),
  50. 'list' => 'Dever::load("passport/user-one#username", {uid})',
  51. ),
  52. 'num' => array
  53. (
  54. 'type' => 'int-11',
  55. 'name' => '兑现积分',
  56. 'default' => '',
  57. 'desc' => '兑现积分',
  58. 'match' => 'is_numeric',
  59. 'update' => 'text',
  60. 'list' => 'table',
  61. 'list_name' => '兑现信息',
  62. 'modal' => '查看详情',
  63. ),
  64. 'cash_num' => array
  65. (
  66. 'type' => 'int-11',
  67. 'name' => '兑换金额',
  68. 'default' => '',
  69. 'desc' => '兑换金额',
  70. 'match' => 'is_numeric',
  71. 'update' => 'text',
  72. ),
  73. 'type' => array
  74. (
  75. 'type' => 'tinyint-1',
  76. 'name' => '兑现类型',
  77. 'default' => '1',
  78. 'desc' => '兑现类型',
  79. 'match' => 'is_numeric',
  80. 'update' => 'select',
  81. 'option' => $type,
  82. 'search' => 'select',
  83. 'list' => true,
  84. //'edit' => true,
  85. ),
  86. 'status' => array
  87. (
  88. 'type' => 'tinyint-1',
  89. 'name' => '审核状态',
  90. 'default' => '1',
  91. 'desc' => '审核状态',
  92. 'match' => 'is_numeric',
  93. 'update' => 'select',
  94. 'option' => $status,
  95. 'search' => 'select',
  96. 'list' => true,
  97. ),
  98. 'state' => array
  99. (
  100. 'type' => 'tinyint-1',
  101. 'name' => '状态',
  102. 'default' => '1',
  103. 'desc' => '请选择状态',
  104. 'match' => 'is_numeric',
  105. ),
  106. 'cdate' => array
  107. (
  108. 'type' => 'int-11',
  109. 'name' => '录入时间',
  110. 'match' => array('is_numeric', time()),
  111. 'desc' => '',
  112. # 只有insert时才生效
  113. 'insert' => true,
  114. 'search' => 'date',
  115. 'list' => 'date("Y-m-d H:i:s", {cdate})',
  116. ),
  117. ),
  118. 'manage' => array
  119. (
  120. 'insert' => false,
  121. 'edit' => false,
  122. 'delete' => false,
  123. ),
  124. );