order.php 24 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854
  1. <?php
  2. $role = function()
  3. {
  4. $array = array();
  5. $data = Dever::load('setting/role-state');
  6. if($data)
  7. {
  8. $array += $data;
  9. }
  10. return $array;
  11. };
  12. $source_id = function()
  13. {
  14. $array = array
  15. (
  16. -1 => array
  17. (
  18. 'id' => '-1',
  19. 'name' => '无来源',
  20. ),
  21. );
  22. $data = Dever::load('setting/source-state');
  23. if($data)
  24. {
  25. $array += $data;
  26. }
  27. return $array;
  28. };
  29. $status = array
  30. (
  31. -2 => '待签名',
  32. 1 => '待业务初审',
  33. 2 => '待财务终审',
  34. 3 => '待权益发放',
  35. 4 => '已完成',
  36. 5 => '驳回',
  37. 6 => '挂起',
  38. );
  39. $pay_status = array
  40. (
  41. 1 => '待支付',
  42. 2 => '已支付',
  43. 3 => '已退款',
  44. );
  45. $goods_status = array
  46. (
  47. 1 => '未发放',
  48. 2 => '无权益',
  49. 3 => '已发放',
  50. );
  51. $type = array
  52. (
  53. 1 => '个人',
  54. 2 => '公司',
  55. );
  56. $pay_type = array
  57. (
  58. 1 => '在线支付',
  59. 2 => '汇款',
  60. 3 => '个人转账',
  61. );
  62. $get_type = array
  63. (
  64. 1 => '购买',
  65. 2 => '赠送',
  66. );
  67. $level = function()
  68. {
  69. $array = array
  70. (
  71. -1 => array
  72. (
  73. 'id' => -1,
  74. 'name' => '普通',
  75. ),
  76. );
  77. $data = Dever::load('setting/level-state');
  78. if($data)
  79. {
  80. $array += $data;
  81. }
  82. return $array;
  83. };
  84. $import = array
  85. (
  86. 1 => '最新系统',
  87. 2 => 'v2旧系统导入',
  88. 3 => 'v1旧系统导入',
  89. );
  90. $order_type = array
  91. (
  92. 1 => '新购',
  93. 2 => '升级',
  94. );
  95. $button = array();
  96. $parent_mid = Dever::input('search_option_parent_mid');
  97. $mid = Dever::input('search_option_mid');
  98. $pmid = '';
  99. if ($parent_mid) {
  100. $pmid = $parent_mid;
  101. }
  102. if ($mid) {
  103. $pmid = $mid;
  104. }
  105. if ($pmid) {
  106. $button = array
  107. (
  108. '返回上一页' => array('location', 'l=project/database/list&project=agent&table=member_area&page_type=1&mid=' . $pmid),
  109. );
  110. }
  111. $invite_type = array
  112. (
  113. 1 => '邀请人',
  114. 2 => '来源',
  115. );
  116. # id小于50000为导入的数据
  117. return array
  118. (
  119. # 表名
  120. 'name' => 'order',
  121. # 显示给用户看的名称
  122. 'lang' => '代理商订单',
  123. 'auto' => 50000,
  124. 'set' => array
  125. (
  126. 'status' => $status,
  127. 'pay_status' => $pay_status,
  128. 'goods_status' => $goods_status,
  129. 'type' => $type,
  130. 'pay_type' => $pay_type,
  131. 'order_type' => $order_type,
  132. ),
  133. 'start' => array
  134. (
  135. 'update' => 'agent/lib/manage.orderUpdateParent',
  136. ),
  137. 'order' => 99,
  138. # 数据结构
  139. 'struct' => array
  140. (
  141. 'id' => array
  142. (
  143. 'type' => 'int-11',
  144. 'name' => 'ID',
  145. 'default' => '',
  146. 'desc' => '',
  147. 'match' => 'is_numeric',
  148. 'search' => 'order',
  149. //'list' => true,
  150. ),
  151. 'mid' => array
  152. (
  153. 'type' => 'int-11',
  154. 'name' => '代理商',
  155. 'default' => '-1',
  156. 'desc' => '代理商',
  157. 'match' => 'is_string',
  158. 'update' => 'text',
  159. 'searchs' => array
  160. (
  161. 'api' => 'agent/member-find',
  162. 'col' => 'mobile',
  163. 'result' => 'id',
  164. ),
  165. //'list' => 'Dever::load("agent/member-find#name", {mid})',
  166. ),
  167. 'order_num' => array
  168. (
  169. 'type' => 'varchar-100',
  170. 'name' => '订单号',
  171. 'default' => '',
  172. 'desc' => '订单号',
  173. 'match' => 'is_string',
  174. 'update' => 'text',
  175. //'search' => 'fulltext',
  176. //'list' => true,
  177. //'list_order' => 1,
  178. ),
  179. 'order_type' => array
  180. (
  181. 'type' => 'tinyint-1',
  182. 'name' => '订单类型',
  183. 'default' => '1',
  184. 'desc' => '订单类型',
  185. 'match' => 'is_numeric',
  186. 'option' => $order_type,
  187. ),
  188. 'mobile' => array
  189. (
  190. 'type' => 'bigint-11',
  191. 'name' => '手机号',
  192. 'default' => '',
  193. 'desc' => '请输入手机号',
  194. 'match' => Dever::rule('mobile'),
  195. 'update' => 'text',
  196. 'search' => 'fulltext',
  197. //'list' => true,
  198. ),
  199. 'invite_type' => array
  200. (
  201. 'type' => 'tinyint-1',
  202. 'name' => '邀请类型',
  203. 'default' => '1',
  204. 'desc' => '邀请类型',
  205. 'match' => 'is_numeric',
  206. //'search' => 'select',
  207. 'update' => 'radio',
  208. 'option' => $invite_type,
  209. //'list' => true,
  210. //'list_order' => 7,
  211. 'control' => 'invite_type',
  212. ),
  213. 'parent_code' => array
  214. (
  215. 'type' => 'varchar-100',
  216. 'name' => '上级邀请码',
  217. 'default' => '',
  218. 'desc' => '上级邀请码',
  219. 'match' => 'is_string',
  220. 'update' => 'text',
  221. # 绑定js脚本,更新时使用,第一个参数是执行的方式,第二个参数执行的方法,第三个参数是传值。
  222. 'bind' => array('onblur', 'loading', array('url' => Dever::url("lib/member.search", 'agent'))),
  223. 'show' => 'invite_type=1',
  224. ),
  225. 'parent_mid' => array
  226. (
  227. 'type' => 'int-11',
  228. 'name' => '邀请人手机号',
  229. 'default' => '-1',
  230. 'desc' => '邀请人',
  231. 'match' => 'is_string',
  232. //'update' => 'text',
  233. 'search' => $parent_mid ? 'hidden' : array
  234. (
  235. 'api' => 'agent/member-find',
  236. 'col' => 'mobile',
  237. 'result' => 'id',
  238. ),
  239. 'list_name' => '邀请人',
  240. 'list' => 'Dever::load("agent/lib/member.getOne", {parent_mid})',
  241. 'list_order' => 4,
  242. ),
  243. 'source_id' => array
  244. (
  245. 'type' => 'int-11',
  246. 'name' => '注册来源',
  247. 'default' => '-1',
  248. 'desc' => '注册来源',
  249. 'match' => 'is_numeric',
  250. 'search' => 'select',
  251. 'update' => 'radio',
  252. 'option' => $source_id,
  253. // 'list' => true,
  254. // 'list_order' => 5,
  255. // 'show' => 'invite_type=2',
  256. ),
  257. 'name' => array
  258. (
  259. 'type' => 'varchar-100',
  260. 'name' => '姓名',
  261. 'default' => '',
  262. 'desc' => '姓名',
  263. 'match' => 'is_string',
  264. 'update' => 'text',
  265. 'search' => 'fulltext',
  266. 'list' => 'Dever::load("agent/lib/order.new_set",{id})',
  267. // 'Dever::load("agent/lib/member.getOne", {id}, "agent/order")',
  268. 'list_order' => 3,
  269. ),
  270. 'role' => array
  271. (
  272. 'type' => 'int-11',
  273. 'name' => '代理角色',
  274. 'default' => '',
  275. 'desc' => '代理角色',
  276. 'match' => 'is_numeric',
  277. 'search' => 'select',
  278. 'update' => 'checkbox',
  279. 'option' => $role,
  280. //'list' => true,
  281. ),
  282. 'area' => array
  283. (
  284. 'type' => 'varchar-500',
  285. 'name' => '区域',
  286. 'default' => '',
  287. 'desc' => '区域',
  288. 'match' => 'option',
  289. 'search' => 'linkage',
  290. 'update' => 'linkage',
  291. 'option' => Dever::url('api.get?level_total=4', 'area'),
  292. // 'list' => 'Dever::load("area/api.string", "{area}")',
  293. ),
  294. 'desc' => array
  295. (
  296. 'type' => 'varchar-600',
  297. 'name' => '付款备注',
  298. 'default' => '',
  299. 'desc' => '付款备注',
  300. 'match' => 'is_string',
  301. 'update' => 'text',
  302. ),
  303. 'f_price' => array
  304. (
  305. 'type' => 'float-11,2',
  306. 'name' => '原价',
  307. 'default' => '0',
  308. 'desc' => '原价',
  309. 'match' => 'option',
  310. 'update' => 'text',
  311. ),
  312. 'price' => array
  313. (
  314. 'type' => 'float-11,2',
  315. 'name' => '金额',
  316. 'default' => '0',
  317. 'desc' => '金额',
  318. 'match' => 'option',
  319. 'update' => 'text',
  320. // 'list' => true,
  321. 'list_name' => '应付金额<br />实付金额<br />代理费<br />软件服务费<br />',
  322. 'list' =>'Dever::load("agent/lib/order.set_price", {id})',
  323. 'list_order' => 10,
  324. ),
  325. 'pay_type' => array
  326. (
  327. 'type' => 'tinyint-1',
  328. 'name' => '支付方式',
  329. 'default' => '1',
  330. 'desc' => '支付方式',
  331. 'match' => 'is_numeric',
  332. //'search' => 'select',
  333. //'update' => 'select',
  334. 'option' => $pay_type,
  335. //'list' => true,
  336. //'list_order' => 7,
  337. ),
  338. 'pay_pic' => array
  339. (
  340. 'type' => 'varchar-2000',
  341. 'name' => '打款凭证',
  342. 'default' => '',
  343. 'desc' => '打款凭证',
  344. 'match' => 'option',
  345. 'update' => 'images',
  346. 'key' => '1',
  347. 'place' => '150',
  348. ),
  349. 'pay_price' => array
  350. (
  351. 'type' => 'float-11,2',
  352. 'name' => '交款金额',
  353. 'default' => '0',
  354. 'desc' => '交款金额',
  355. 'match' => 'option',
  356. 'update' => 'text',
  357. ),
  358. 'option_price' => array
  359. (
  360. 'type' => 'float-11,2',
  361. 'name' => '赠送期权价值',
  362. 'default' => '0',
  363. 'desc' => '金额',
  364. 'match' => 'option',
  365. 'update' => 'text',
  366. // 'value' => Dever::input('soft_price', '0'),
  367. // 'show' => 'cstatus=2',
  368. ),
  369. 'bank_id' => array
  370. (
  371. 'type' => 'int-11',
  372. 'name' => '所属银行',
  373. 'default' => '',
  374. 'desc' => '所属银行',
  375. 'match' => 'is_numeric',
  376. ),
  377. 'bank_card' => array
  378. (
  379. 'type' => 'int-11',
  380. 'name' => '银行卡号',
  381. 'default' => '',
  382. 'desc' => '银行卡号',
  383. 'match' => 'is_numeric',
  384. ),
  385. 'type' => array
  386. (
  387. 'type' => 'tinyint-1',
  388. 'name' => '类型',
  389. 'default' => '1',
  390. 'desc' => '类型',
  391. 'match' => 'is_numeric',
  392. 'option' => $type,
  393. 'update' => 'radio',
  394. 'control' => 'type',
  395. ),
  396. 'sign' => array
  397. (
  398. 'type' => 'varchar-150',
  399. 'name' => '手写签名',
  400. 'default' => '',
  401. 'desc' => '手写签名',
  402. 'match' => 'option',
  403. 'update' => 'image',
  404. 'key' => '7',
  405. ),
  406. 'idcard' => array
  407. (
  408. 'type' => 'varchar-100',
  409. 'name' => '身份证号码',
  410. 'default' => '',
  411. 'desc' => '身份证号码',
  412. 'match' => 'is_string',
  413. 'match' => Dever::rule('idcard'),
  414. 'update' => 'text',
  415. 'search' => 'fulltext',
  416. ),
  417. 'idcard_front' => array
  418. (
  419. 'type' => 'varchar-150',
  420. 'name' => '身份证正面',
  421. 'default' => '',
  422. 'desc' => '身份证正面',
  423. 'match' => 'option',
  424. 'update' => 'image',
  425. 'key' => '8',
  426. //'place' => '660*660',
  427. ),
  428. 'idcard_back' => array
  429. (
  430. 'type' => 'varchar-150',
  431. 'name' => '身份证背面',
  432. 'default' => '',
  433. 'desc' => '身份证背面',
  434. 'match' => 'option',
  435. 'update' => 'image',
  436. 'key' => '8',
  437. //'place' => '660*660',
  438. ),
  439. 'company_name' => array
  440. (
  441. 'type' => 'varchar-100',
  442. 'name' => '公司名称',
  443. 'default' => '',
  444. 'desc' => '公司名称',
  445. 'match' => 'is_string',
  446. 'update' => 'text',
  447. //'search' => 'fulltext',
  448. //'list' => true,
  449. 'show' => 'type=2',
  450. ),
  451. 'company_pic' => array
  452. (
  453. 'type' => 'varchar-150',
  454. 'name' => '营业执照',
  455. 'default' => '',
  456. 'desc' => '营业执照',
  457. 'match' => 'option',
  458. 'update' => 'image',
  459. 'key' => '8',
  460. //'place' => '660*660',
  461. 'show' => 'type=2',
  462. ),
  463. 'company_number' => array
  464. (
  465. 'type' => 'varchar-80',
  466. 'name' => '营业执照号码',
  467. 'default' => '',
  468. 'desc' => '营业执照号码',
  469. 'match' => 'is_string',
  470. 'update' => 'text',
  471. 'show' => 'type=2',
  472. ),
  473. 'address' => array
  474. (
  475. 'type' => 'varchar-800',
  476. 'name' => '地址',
  477. 'default' => '',
  478. 'desc' => '地址',
  479. 'match' => 'is_string',
  480. 'update' => 'text',
  481. ),
  482. 'audit_desc' => array
  483. (
  484. 'type' => 'varchar-400',
  485. 'name' => '审核备注-从order_process中同步过来',
  486. 'default' => '',
  487. 'desc' => '审核备注',
  488. 'match' => 'is_string',
  489. //'update' => 'textarea',
  490. ),
  491. 'admin_desc' => array
  492. (
  493. 'type' => 'varchar-800',
  494. 'name' => '管理员备注',
  495. 'default' => '',
  496. 'desc' => '管理员备注',
  497. 'match' => 'is_string',
  498. 'update' => 'textarea',
  499. ),
  500. 'status' => array
  501. (
  502. 'type' => 'tinyint-1',
  503. 'name' => '订单状态',
  504. 'default' => '1',
  505. 'desc' => '状态',
  506. 'match' => 'is_numeric',
  507. 'option' => $status,
  508. 'search' => 'select',
  509. 'list' => true,
  510. 'list_order' => 8,
  511. ),
  512. 'history_status' => array
  513. (
  514. 'type' => 'tinyint-1',
  515. 'name' => '记录挂起之前的状态',
  516. 'default' => '1',
  517. 'desc' => '状态',
  518. 'match' => 'is_numeric',
  519. 'option' => $status,
  520. ),
  521. 'goods_status' => array
  522. (
  523. 'type' => 'tinyint-1',
  524. 'name' => '权益状态',
  525. 'default' => '1',
  526. 'desc' => '权益状态',
  527. 'match' => 'is_numeric',
  528. 'option' => $goods_status,
  529. 'search' => 'select',
  530. 'list' => true,
  531. 'list_order' => 9,
  532. ),
  533. 'pay_status' => array
  534. (
  535. 'type' => 'tinyint-1',
  536. 'name' => '支付状态',
  537. 'default' => '1',
  538. 'desc' => '状态',
  539. 'match' => 'is_numeric',
  540. 'option' => $pay_status,
  541. ),
  542. 'get_type' => array
  543. (
  544. 'type' => 'tinyint-1',
  545. 'name' => '获取方式',
  546. 'default' => '1',
  547. 'desc' => '获取方式',
  548. 'match' => 'is_numeric',
  549. 'update' => 'radio',
  550. 'option' => $get_type,
  551. ),
  552. 'agent_cash' => array
  553. (
  554. 'type' => 'float-11,2',
  555. 'name' => '代理费',
  556. 'default' => '0',
  557. 'desc' => '代理费',
  558. 'match' => 'option',
  559. 'update' => 'text',
  560. ),
  561. 'soft_cash' => array
  562. (
  563. 'type' => 'float-11,2',
  564. 'name' => '软件服务费',
  565. 'default' => '0',
  566. 'desc' => '软件服务费',
  567. 'match' => 'option',
  568. 'update' => 'text',
  569. ),
  570. 'goods_cash' => array
  571. (
  572. 'type' => 'float-11,2',
  573. 'name' => '商品价值-名额不算,商品价值第一次分配后保持不变',
  574. 'default' => '0',
  575. 'desc' => '商品价值',
  576. 'match' => 'option',
  577. 'update' => 'text',
  578. ),
  579. 'import' => array
  580. (
  581. 'type' => 'tinyint-1',
  582. 'name' => '是否导入',
  583. 'default' => '1',
  584. 'desc' => '是否导入',
  585. 'match' => 'is_numeric',
  586. 'option' => $import,
  587. 'update' => 'radio',
  588. ),
  589. 'state' => array
  590. (
  591. 'type' => 'tinyint-1',
  592. 'name' => '状态',
  593. 'default' => '1',
  594. 'desc' => '请选择状态',
  595. 'match' => 'is_numeric',
  596. ),
  597. 'fdate' => array
  598. (
  599. 'type' => 'int-11',
  600. 'name' => '完成时间',
  601. 'default' => '',
  602. 'match' => 'is_numeric',
  603. 'desc' => '',
  604. ),
  605. 'cdate' => array
  606. (
  607. 'type' => 'int-11',
  608. 'name' => '处理时间',
  609. 'match' => array('is_numeric', time()),
  610. 'desc' => '',
  611. # 只有insert时才生效
  612. 'insert' => true,
  613. 'search' => 'date',
  614. // 'list' => 'date("Y-m-d H:i:s", {cdate})',
  615. 'list_name' => '注册时间<br />初审时间<br />终审时间<br />完成时间<br />',
  616. 'list' => 'Dever::load("agent/lib/order.set_cdate", {id})',
  617. 'list_order' => 200,
  618. ),
  619. ),
  620. 'alter' => array
  621. (
  622. 5 => array
  623. (
  624. array('update', 'price', 'price', 'float-11,2 0 实付金额'),
  625. array('update', 'f_price', 'f_price', 'float-11,2 0 原价'),
  626. array('update', 'agent_cash', 'agent_cash', 'float-11,2 0 代理费'),
  627. array('update', 'soft_cash', 'soft_cash', 'float-11,2 0 软件服务费'),
  628. array('update', 'goods_cash', 'goods_cash', 'float-11,2 0 商品价值'),
  629. ),
  630. 'version' => 5,
  631. ),
  632. 'manage' => array
  633. (
  634. 'insert' => false,
  635. 'delete' => false,
  636. 'edit' => false,
  637. 'button' => $button,
  638. 'list_button' => array
  639. (
  640. //fast_list
  641. 'list' => array('查看详情', '"order_process&project=agent&order_id={id}&page_type=1"'),
  642. //'edit' => array('退款', 'status,tk_time,tk_pic,tk_desc,tk_admin,tk_status', '{status} == 6'),
  643. //'delete' => array('删除', '', '{status} == 1'),
  644. ),
  645. ),
  646. 'request' => array
  647. (
  648. 'getNew' => array
  649. (
  650. # 匹配的正则或函数 选填项
  651. 'option' => array
  652. (
  653. 'mid' => 'yes',
  654. 'status' => array('yes', 'in'),
  655. 'state' => 1,
  656. ),
  657. 'order' => array('id' => 'desc'),
  658. 'type' => 'one',
  659. 'col' => '*',
  660. ),
  661. 'getTotal' => array
  662. (
  663. # 匹配的正则或函数 选填项
  664. 'option' => array
  665. (
  666. 'mid' => 'yes',
  667. 'status' => array('yes', 'in'),
  668. 'state' => 1,
  669. ),
  670. 'order' => array('id' => 'desc'),
  671. 'type' => 'count',
  672. 'col' => '*',
  673. ),
  674. 'getData' => array
  675. (
  676. # 匹配的正则或函数 选填项
  677. 'option' => array
  678. (
  679. 'mid' => 'yes',
  680. 'status' => array('yes', 'in'),
  681. 'state' => 1,
  682. ),
  683. 'order' => array('id' => 'desc'),
  684. 'page' => array(10, 'list'),
  685. 'type' => 'all',
  686. 'col' => '*',
  687. ),
  688. # 获取订单数量
  689. 'getNum' => array
  690. (
  691. # 匹配的正则或函数 选填项
  692. 'option' => array
  693. (
  694. 'start' => array('yes-cdate', '>='),
  695. 'end' => array('yes-cdate', '<='),
  696. 'status' => array('yes', 'in'),
  697. 'state' => 1,
  698. ),
  699. 'type' => 'count',
  700. 'col' => '*',
  701. ),
  702. # 获取订单数量
  703. 'getCash' => array
  704. (
  705. # 匹配的正则或函数 选填项
  706. 'option' => array
  707. (
  708. 'start' => array('yes-cdate', '>='),
  709. 'end' => array('yes-cdate', '<='),
  710. 'status' => array('yes', 'in'),
  711. 'state' => 1,
  712. ),
  713. 'type' => 'one',
  714. 'col' => 'sum(price) as total',
  715. ),
  716. 'getDailiCash' => array
  717. (
  718. # 匹配的正则或函数 选填项
  719. 'option' => array
  720. (
  721. 'start' => array('yes-cdate', '>='),
  722. 'end' => array('yes-cdate', '<='),
  723. 'status' => array('yes', 'in'),
  724. 'state' => 1,
  725. ),
  726. 'type' => 'one',
  727. 'col' => 'sum(agent_cash) as total',
  728. ),
  729. 'getSoftCash' => array
  730. (
  731. # 匹配的正则或函数 选填项
  732. 'option' => array
  733. (
  734. 'start' => array('yes-cdate', '>='),
  735. 'end' => array('yes-cdate', '<='),
  736. 'status' => array('yes', 'in'),
  737. 'state' => 1,
  738. ),
  739. 'type' => 'one',
  740. 'col' => 'sum(soft_cash) as total',
  741. ),
  742. 'getGoodsCash' => array
  743. (
  744. # 匹配的正则或函数 选填项
  745. 'option' => array
  746. (
  747. 'start' => array('yes-cdate', '>='),
  748. 'end' => array('yes-cdate', '<='),
  749. 'status' => array('yes', 'in'),
  750. 'state' => 1,
  751. ),
  752. 'type' => 'one',
  753. 'col' => 'sum(goods_cash) as total',
  754. ),
  755. 'getFindOne' => array
  756. (
  757. # 匹配的正则或函数 选填项
  758. 'option' => array
  759. (
  760. 'id' => array('yes','!='),
  761. 'mid' => 'yes',
  762. 'order_type' => 'yes',
  763. 'state' => 1,
  764. ),
  765. 'type' => 'one',
  766. 'order' => array('cdate' => 'desc'),
  767. 'col' => '*',
  768. ),
  769. 'getPrice' => array
  770. (
  771. # 匹配的正则或函数 选填项
  772. 'option' => array
  773. (
  774. 'mid' => 'yes',
  775. 'status' => 4,
  776. 'state' => 1,
  777. ),
  778. 'type' => 'one',
  779. 'col' => 'sum(price) as total',
  780. ),
  781. ),
  782. );