yspay_cash.php 6.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230
  1. <?php
  2. $status = array
  3. (
  4. 1 => '未确认',
  5. 2 => '待入账',
  6. 3 => '已入账',
  7. 4 => '申请提现',
  8. 5 => '已提现',
  9. 6 => '提现失败',
  10. );
  11. $button = array
  12. (
  13. '资金划付' => array('oper', 'pay/yspay/cash.huafu_commit?account_id=' . Dever::input('search_option_account_id') . '&merchant_id=' . Dever::input('search_option_merchant_id')),
  14. );
  15. return array
  16. (
  17. # 表名
  18. 'name' => 'yspay_cash',
  19. # 显示给用户看的名称
  20. 'lang' => '银联资金记录表',
  21. 'menu' => false,
  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. 'update' => 'hidden',
  34. //'list' => true,
  35. ),
  36. 'account_id' => array
  37. (
  38. 'type' => 'int-11',
  39. 'name' => '账户id',
  40. 'default' => '',
  41. 'desc' => '账户id',
  42. 'match' => 'option',
  43. 'search' => 'hidden',
  44. 'update' => 'hidden',
  45. 'value' => Dever::input('search_option_account_id'),
  46. ),
  47. 'merchant_id' => array
  48. (
  49. 'type' => 'int-11',
  50. 'name' => '商户id',
  51. 'default' => '',
  52. 'desc' => '商户id',
  53. 'match' => 'option',
  54. 'search' => 'hidden',
  55. 'update' => 'hidden',
  56. 'value' => Dever::input('search_option_merchant_id'),
  57. 'list_name' => '商户名称',
  58. 'list' => 'Dever::load("pay/yspay_merchant-one#name", "{merchant_id}")',
  59. ),
  60. 'order_num' => array
  61. (
  62. 'type' => 'varchar-800',
  63. 'name' => '流水号',
  64. 'default' => '',
  65. 'desc' => '流水号',
  66. 'match' => 'is_string',
  67. 'update' => 'text',
  68. 'list' => true,
  69. ),
  70. 'source_order_num' => array
  71. (
  72. 'type' => 'varchar-800',
  73. 'name' => '关联订单号',
  74. 'default' => '',
  75. 'desc' => '关联订单号',
  76. 'match' => 'is_string',
  77. 'update' => 'text',
  78. 'list' => true,
  79. ),
  80. 'ycash' => array
  81. (
  82. 'type' => 'int-11',
  83. 'name' => '交易金额',
  84. 'default' => '0',
  85. 'desc' => '交易金额',
  86. 'match' => 'option',
  87. 'list' => 'Dever::number({ycash}/100, 2)',
  88. ),
  89. 'yl_cash' => array
  90. (
  91. 'type' => 'int-11',
  92. 'name' => '银联手续费',
  93. 'default' => '0',
  94. 'desc' => '银联手续费',
  95. 'match' => 'option',
  96. 'list' => 'Dever::number({yl_cash}/100, 2)',
  97. ),
  98. 'pt_cash' => array
  99. (
  100. 'type' => 'int-11',
  101. 'name' => '平台手续费',
  102. 'default' => '0',
  103. 'desc' => '平台手续费',
  104. 'match' => 'option',
  105. 'list' => 'Dever::number({pt_cash}/100, 2)',
  106. ),
  107. 'cash' => array
  108. (
  109. 'type' => 'int-11',
  110. 'name' => '实际金额',
  111. 'default' => '0',
  112. 'desc' => '实际金额',
  113. 'match' => 'option',
  114. 'list' => 'Dever::number({cash}/100, 2)',
  115. ),
  116. 'hf_cash' => array
  117. (
  118. 'type' => 'int-11',
  119. 'name' => '商户划付金额',
  120. 'default' => '0',
  121. 'desc' => '划付金额',
  122. 'match' => 'option',
  123. //'update' => 'text',
  124. 'list' => 'Dever::number({hf_cash}/100, 2)',
  125. ),
  126. 'fz_cash' => array
  127. (
  128. 'type' => 'int-11',
  129. 'name' => '平台分账金额',
  130. 'default' => '0',
  131. 'desc' => '分账金额',
  132. 'match' => 'option',
  133. //'update' => 'text',
  134. 'list' => 'Dever::number({fz_cash}/100, 2)',
  135. ),
  136. 'rdate' => array
  137. (
  138. 'type' => 'int-11',
  139. 'name' => '入账时间',
  140. 'default' => '',
  141. 'match' => 'is_numeric',
  142. 'desc' => '',
  143. 'search' => 'date',
  144. 'list' => '"{rdate}" ? date("Y-m-d H:i", \'{rdate}\') : "-"',
  145. 'list_order' => 100,
  146. ),
  147. 'tdate' => array
  148. (
  149. 'type' => 'int-11',
  150. 'name' => '提现时间',
  151. 'default' => '',
  152. 'match' => 'is_numeric',
  153. 'desc' => '',
  154. 'search' => 'date',
  155. 'list' => '"{tdate}" ? date("Y-m-d H:i", \'{tdate}\') : "-"',
  156. 'list_order' => 101,
  157. ),
  158. 'status' => array
  159. (
  160. 'type' => 'tinyint-1',
  161. 'name' => '状态',
  162. 'default' => '1',
  163. 'desc' => '状态',
  164. 'match' => 'is_numeric',
  165. 'option' => $status,
  166. 'search' => 'select',
  167. 'list' => true,
  168. ),
  169. 'state' => array
  170. (
  171. 'type' => 'tinyint-1',
  172. 'name' => '状态',
  173. 'default' => '1',
  174. 'desc' => '请选择状态',
  175. 'match' => 'is_numeric',
  176. ),
  177. 'cdate' => array
  178. (
  179. 'type' => 'int-11',
  180. 'name' => '创建时间',
  181. 'match' => array('is_numeric', time()),
  182. 'desc' => '',
  183. # 只有insert时才生效
  184. //'insert' => true,
  185. //'search' => 'date',
  186. 'list' => 'date("Y-m-d H:i:s", {cdate})',
  187. ),
  188. ),
  189. 'manage' => array
  190. (
  191. 'edit' => false,
  192. 'insert' => false,
  193. 'delete' => false,
  194. //'button' => $button,
  195. ),
  196. 'request' => array
  197. (
  198. 'getTotal' => array
  199. (
  200. 'option' => array
  201. (
  202. 'merchant_id' => 'yes',
  203. 'status' => array('yes', '>='),
  204. 'state' => 1,
  205. ),
  206. 'type' => 'one',
  207. 'col' => 'sum(cash) as cash,sum(hf_cash) as hf_cash,sum(fz_cash) as fz_cash,sum(yl_cash) as yl_cash,sum(pt_cash) as pt_cash',
  208. ),
  209. ),
  210. );