tixian.php 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402
  1. <?php
  2. $status = array
  3. (
  4. -1 => '未审核待发放',
  5. 1 => '已审核待发放',
  6. 2 => '已发放',
  7. );
  8. $cash_status = array
  9. (
  10. 1 => '待审核',
  11. 2 => '已审核',
  12. 3 => '已作废',
  13. );
  14. $manage_status = array
  15. (
  16. //1 => '待发放',
  17. 2 => '已发放',
  18. );
  19. $mid = Dever::input('search_option_mid');
  20. return array
  21. (
  22. # 表名
  23. 'name' => 'tixian',
  24. # 显示给用户看的名称
  25. 'lang' => '提现管理',
  26. 'set' => array
  27. (
  28. 'status' => $status,
  29. ),
  30. 'end' => array
  31. (
  32. 'update' => 'bill/lib/manage.tixianAuditUpdate',
  33. ),
  34. 'order' => 80,
  35. # 数据结构
  36. 'struct' => array
  37. (
  38. 'id' => array
  39. (
  40. 'type' => 'int-11',
  41. 'name' => 'ID',
  42. 'default' => '',
  43. 'desc' => '',
  44. 'match' => 'is_numeric',
  45. 'search' => 'order',
  46. //'list' => true,
  47. ),
  48. 'mid' => array
  49. (
  50. 'type' => 'int-11',
  51. 'name' => '手机号',
  52. 'default' => '-1',
  53. 'desc' => '代理商',
  54. 'match' => 'is_string',
  55. 'update' => 'text',
  56. 'search' => $mid ? 'hidden' : array
  57. (
  58. 'api' => 'agent/member-find',
  59. 'col' => 'mobile',
  60. 'result' => 'id',
  61. ),
  62. 'list_name' => '手机号',
  63. 'list' => 'Dever::load("agent/member-find#mobile", {mid})',
  64. 'list_order' => 4,
  65. ),
  66. 'agent-member-name'=> array
  67. (
  68. 'name' => '姓名',
  69. 'default' => '',
  70. 'desc' => '姓名',
  71. 'match' => 'option',
  72. # 读取另外表的关联方式
  73. 'sync' => array('mid', 'id'),
  74. 'list' => true,
  75. 'search' => 'fulltext',
  76. 'list_order' => 3,
  77. ),
  78. 'agent-member-role'=> array
  79. (
  80. 'name' => '代理角色',
  81. 'default' => '',
  82. 'desc' => '代理角色',
  83. 'match' => 'option',
  84. # 读取另外表的关联方式
  85. 'sync' => array('mid', 'id'),
  86. 'list' => 'Dever::load("setting/role-find#name", "{agent-member-role}")',
  87. 'list_order' => 5,
  88. ),
  89. 'order_num' => array
  90. (
  91. 'type' => 'varchar-100',
  92. 'name' => '流水号',
  93. 'default' => '',
  94. 'desc' => '流水号',
  95. 'match' => 'is_string',
  96. 'update' => 'text',
  97. 'search' => 'fulltext',
  98. 'list' => true,
  99. 'list_order' => 1,
  100. ),
  101. 'ycash' => array
  102. (
  103. 'type' => 'float-11,2',
  104. 'name' => '提现金额',
  105. 'default' => '0',
  106. 'desc' => '金额',
  107. 'match' => 'is_numeric',
  108. 'update' => 'text',
  109. 'list' => true,
  110. 'list_order' => 6,
  111. ),
  112. 'cash' => array
  113. (
  114. 'type' => 'float-11,2',
  115. 'name' => '实际提现金额',
  116. 'default' => '0',
  117. 'desc' => '提现金额',
  118. 'match' => 'is_numeric',
  119. 'update' => 'text',
  120. 'list' => true,
  121. 'list_order' => 7,
  122. ),
  123. 'yue' => array
  124. (
  125. 'type' => 'float-11,2',
  126. 'name' => '提现后余额',
  127. 'default' => '0',
  128. 'desc' => '提现后余额',
  129. 'match' => 'is_numeric',
  130. 'update' => 'text',
  131. 'list' => true,
  132. 'list_order' => 8,
  133. ),
  134. 'name' => array
  135. (
  136. 'type' => 'varchar-100',
  137. 'name' => '姓名',
  138. 'default' => '',
  139. 'desc' => '姓名',
  140. 'match' => 'is_string',
  141. 'update' => 'text',
  142. ),
  143. 'bank' => array
  144. (
  145. 'type' => 'int-11',
  146. 'name' => '银行',
  147. 'default' => '',
  148. 'desc' => '银行',
  149. 'match' => 'is_numeric',
  150. 'update' => 'text',
  151. ),
  152. 'bankname' => array
  153. (
  154. 'type' => 'varchar-100',
  155. 'name' => '开户行',
  156. 'default' => '',
  157. 'desc' => '开户行',
  158. 'match' => 'is_string',
  159. 'update' => 'text',
  160. ),
  161. 'card' => array
  162. (
  163. 'type' => 'varchar-200',
  164. 'name' => '卡号',
  165. 'default' => '',
  166. 'desc' => '卡号',
  167. 'match' => 'is_string',
  168. 'update' => 'text',
  169. ),
  170. 'cash_id' => array
  171. (
  172. 'type' => 'int-11',
  173. 'name' => '资金表id',
  174. 'default' => '',
  175. 'desc' => '资金表id',
  176. 'match' => 'is_string',
  177. 'update' => 'text',
  178. ),
  179. 'bill-cash-status'=> array
  180. (
  181. 'name' => '交易状态',
  182. 'default' => '',
  183. 'desc' => '交易状态',
  184. 'match' => 'option',
  185. # 读取另外表的关联方式
  186. 'sync' => array('cash_id', 'id'),
  187. 'search' => 'select',
  188. 'list' => true,
  189. 'option' => $cash_status,
  190. 'list_order' => 9,
  191. ),
  192. 'status' => array
  193. (
  194. 'type' => 'int-11',
  195. 'name' => '发放状态',
  196. 'default' => '1',
  197. 'desc' => '发放状态',
  198. 'match' => 'is_numeric',
  199. 'update' => 'hidden',
  200. 'option' => $status,
  201. 'search' => 'select',
  202. 'list' => true,
  203. 'list_order' => 10,
  204. ),
  205. 'audit' => array
  206. (
  207. 'type' => 'int-11',
  208. 'name' => '审核状态',
  209. 'default' => '2',
  210. 'desc' => '审核状态',
  211. 'match' => 'is_numeric',
  212. 'update' => 'radio',
  213. 'option' => $manage_status,
  214. 'mul' => true,
  215. 'control' => 'audit',
  216. ),
  217. 'audit_desc' => array
  218. (
  219. 'type' => 'varchar-600',
  220. 'name' => '备注',
  221. 'default' => '',
  222. 'desc' => '审核说明',
  223. 'match' => 'is_string',
  224. 'update' => 'textarea',
  225. 'list' => '"{audit_desc}" ? "{audit_desc}" : "-"',
  226. 'list_order' => 12,
  227. 'show' => 'audit=3',
  228. ),
  229. 'pic' => array
  230. (
  231. 'type' => 'text-255',
  232. 'name' => '凭证',
  233. 'default' => '',
  234. 'desc' => '请选择凭证',
  235. 'match' => 'option',
  236. 'update' => 'images',
  237. 'key' => '1',
  238. 'place' => '150',
  239. ),
  240. 'sign' => array
  241. (
  242. 'type' => 'varchar-150',
  243. 'name' => '手写签名',
  244. 'default' => '',
  245. 'desc' => '手写签名',
  246. 'match' => 'option',
  247. 'update' => 'image',
  248. 'key' => '7',
  249. 'list' => '"<img src=\'{sign}\' width=\'150\'>"',
  250. ),
  251. 'operdate' => array
  252. (
  253. 'type' => 'int-11',
  254. 'name' => '发放时间',
  255. 'default' => '',
  256. 'match' => 'is_numeric',
  257. 'desc' => '',
  258. 'list' => '"{operdate}" > 0 ? date("Y-m-d H:i", {operdate}) : "-"',
  259. 'list_order' => 11,
  260. ),
  261. 'state' => array
  262. (
  263. 'type' => 'tinyint-1',
  264. 'name' => '状态',
  265. 'default' => '1',
  266. 'desc' => '请选择状态',
  267. 'match' => 'is_numeric',
  268. ),
  269. 'cdate' => array
  270. (
  271. 'type' => 'int-11',
  272. 'name' => '交易时间',
  273. 'match' => array('is_numeric', time()),
  274. 'desc' => '',
  275. # 只有insert时才生效
  276. //'insert' => true,
  277. 'search' => 'date',
  278. 'list' => 'date("Y-m-d H:i", {cdate})',
  279. 'list_order' => 2,
  280. ),
  281. ),
  282. 'manage' => array
  283. (
  284. 'insert' => false,
  285. 'delete' => false,
  286. 'edit' => false,
  287. 'mul' => true,
  288. 'list_button' => array
  289. (
  290. 'list' => array('查看详情', '"push_cash&project=bill&id={cash_id}&page_type=1"'),
  291. 'fast' => array('发放', '"tixian&where_id={id}&col=audit,audit_desc,pic&oper_save_jump=tixian&oper_table=tixian&oper_parent=tixian"', '{status} == 1 && "{bill-cash-status}" == 2'),
  292. ),
  293. ),
  294. 'request' => array
  295. (
  296. 'getData' => array
  297. (
  298. # 匹配的正则或函数 选填项
  299. 'option' => array
  300. (
  301. 'mid' => 'yes',
  302. 'state' => 1,
  303. ),
  304. 'order' => array('id' => 'desc'),
  305. 'page' => array(10, 'list'),
  306. 'type' => 'all',
  307. 'col' => '*',
  308. ),
  309. 'getNew' => array
  310. (
  311. # 匹配的正则或函数 选填项
  312. 'option' => array
  313. (
  314. 'mid' => 'yes',
  315. 'state' => 1,
  316. ),
  317. 'order' => array('id' => 'desc'),
  318. 'type' => 'one',
  319. 'col' => '*',
  320. ),
  321. 'gettxCash' => array
  322. (
  323. # 匹配的正则或函数 选填项
  324. 'option' => array
  325. (
  326. 'start' => array('yes-cdate', '>='),
  327. 'end' => array('yes-cdate', '<='),
  328. 'status' => array('yes', 'in'),
  329. 'state' => 1,
  330. ),
  331. 'type' => 'one',
  332. 'col' => 'sum(cash) as total',
  333. ),
  334. 'getdfCash' => array
  335. (
  336. # 匹配的正则或函数 选填项
  337. 'option' => array
  338. (
  339. 'start' => array('yes-cdate', '>='),
  340. 'end' => array('yes-cdate', '<='),
  341. 'status' => array('yes', 'in'),
  342. 'state' => 1,
  343. ),
  344. 'type' => 'one',
  345. 'col' => 'sum(cash) as total',
  346. ),
  347. 'getwsCash' => array
  348. (
  349. # 匹配的正则或函数 选填项
  350. 'option' => array
  351. (
  352. 'start' => array('yes-cdate', '>='),
  353. 'end' => array('yes-cdate', '<='),
  354. 'bill-cash-status' => array('yes', 'in'),
  355. 'state' => 1,
  356. ),
  357. 'type' => 'one',
  358. 'col' => 'mid as mid',
  359. ),
  360. 'upStatus' => array
  361. (
  362. 'type' => 'update',
  363. 'where' => array
  364. (
  365. 'id' => 'yes',
  366. ),
  367. 'set' => array
  368. (
  369. 'status' =>'yes',
  370. 'bill-cash-status'=>'yes',
  371. ),
  372. ),
  373. ),
  374. );