order.php 33 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088
  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 => array('name' => '待签名', 'style' => 'font-weight:bold;color:#00FFFF'),
  32. 1 => array('name' => '待业务初审', 'style' => 'font-weight:bold;color:#436EEE'),
  33. 2 => array('name' => '待财务终审', 'style' => 'font-weight:bold;color:#003366'),
  34. 3 => array('name' => '待权益发放', 'style' => 'font-weight:bold;color:#993333'),
  35. 4 => array('name' => '已完成', 'style' => 'font-weight:bold;color:green'),
  36. 5 => array('name' => '驳回', 'style' => 'font-weight:bold;color:#CD3700'),
  37. 6 => array('name' => '挂起', 'style' => 'font-weight:bold;color:#436EEE'),
  38. 7 => array('name' => '关闭', 'style' => 'font-weight:bold;color:#000000'),
  39. );
  40. $pay_status = array
  41. (
  42. 1 => '待支付',
  43. 2 => '已支付',
  44. 3 => '已退款',
  45. );
  46. $goods_status = array
  47. (
  48. 1 => array('name' => '未发放', 'style' => 'font-weight:bold;color:#436EEE'),
  49. 2 => array('name' => '无权益', 'style' => 'font-weight:bold;'),
  50. 3 => array('name' => '已发放', 'style' => 'font-weight:bold;color:green'),
  51. );
  52. $type = array
  53. (
  54. 1 => '个人',
  55. 2 => '公司',
  56. );
  57. $pay_type = array
  58. (
  59. 1 => '在线支付',
  60. 2 => '汇款',
  61. 3 => '个人转账',
  62. );
  63. $get_type = array
  64. (
  65. 1 => '购买',
  66. 2 => '赠送',
  67. );
  68. $level = function()
  69. {
  70. $array = array
  71. (
  72. -1 => array
  73. (
  74. 'id' => -1,
  75. 'name' => '普通',
  76. ),
  77. );
  78. $data = Dever::load('setting/level-state');
  79. if($data)
  80. {
  81. $array += $data;
  82. }
  83. return $array;
  84. };
  85. $import = array
  86. (
  87. 1 => '最新系统',
  88. 2 => 'v2旧系统导入',
  89. 3 => 'v1旧系统导入',
  90. );
  91. $order_type = array
  92. (
  93. 1 => '新购',
  94. 2 => '升级',
  95. );
  96. $button = array();
  97. $parent_mid = Dever::input('search_option_parent_mid');
  98. $mid = Dever::input('search_option_mid');
  99. $pmid = '';
  100. if ($parent_mid) {
  101. $pmid = $parent_mid;
  102. }
  103. if ($mid) {
  104. $pmid = $mid;
  105. }
  106. $excel = false;
  107. if ($pmid) {
  108. $button = array
  109. (
  110. '返回上一页' => array('location', 'l=project/database/list&project=agent&table=member_area&page_type=1&mid=' . $pmid),
  111. );
  112. }else{
  113. if(Dever::load('manage/auth')->checkFunc('agent.order', 'editorderout', '数据导出')){
  114. $excel[] = array('数据导出', '代理商订单','agent/lib/order.out_order');
  115. }
  116. if(Dever::load('manage/auth')->checkFunc('agent.order', 'editbeidiao', '背调订单记录数据导出')){
  117. $excel[] = array('代理商订单导出', '代理商订单记录','agent/lib/order.out_beidiaoorder');
  118. }
  119. }
  120. # 权限设置 1是查看详情、2是城市数据统计
  121. $search_auth = Dever::input('search_option_dever_auth', 1);
  122. $list_button = array();
  123. if($search_auth == 1){
  124. $list_button['list'] = array('查看详情', '"order_process&project=agent&order_id={id}&page_type=1&[refer]"');
  125. if(Dever::load('manage/auth')->checkFunc('agent.order', 'editSoftorderout', '软件服务费数据导出')){
  126. $excel[] = array('软件服务费数据导出','软件服务费数据导出', 'agent/lib/order.out_softorder');
  127. }
  128. }
  129. $search_pmid = Dever::input('search_in_parent_mid');
  130. $invite_type = array
  131. (
  132. 1 => '邀请人',
  133. 2 => '来源',
  134. );
  135. # id小于50000为导入的数据
  136. return array
  137. (
  138. # 表名
  139. 'name' => 'order',
  140. # 显示给用户看的名称
  141. 'lang' => '代理商订单',
  142. 'auto' => 50000,
  143. 'set' => array
  144. (
  145. 'status' => $status,
  146. 'pay_status' => $pay_status,
  147. 'goods_status' => $goods_status,
  148. 'type' => $type,
  149. 'pay_type' => $pay_type,
  150. 'order_type' => $order_type,
  151. ),
  152. 'start' => array
  153. (
  154. 'update' => 'agent/lib/manage.orderUpdateParent',
  155. ),
  156. 'order' => 99,
  157. # 数据结构
  158. 'struct' => array
  159. (
  160. 'id' => array
  161. (
  162. 'type' => 'int-11',
  163. 'name' => 'ID',
  164. 'default' => '',
  165. 'desc' => '',
  166. 'match' => 'is_numeric',
  167. 'search' => 'order',
  168. //'list' => true,
  169. ),
  170. 'mid' => array
  171. (
  172. 'type' => 'int-11',
  173. 'name' => '代理商姓名/手机号',
  174. 'default' => '-1',
  175. 'desc' => '代理商',
  176. 'match' => 'is_string',
  177. 'update' => 'text',
  178. 'search' => $search_pmid ? false : array
  179. (
  180. 'api' => 'agent/member-getSearch',
  181. 'col' => 'col',
  182. 'result' => 'id',
  183. 'search' => 'mid',
  184. ),
  185. 'list_name' => '代理商信息',
  186. 'list' => $search_auth == 1 ? 'Dever::load("agent/lib/member.getOne", {mid}, "agent/member", true)' : false,
  187. 'list_order' => 3,
  188. ),
  189. 'order_num' => array
  190. (
  191. 'type' => 'varchar-100',
  192. 'name' => '订单号',
  193. 'default' => '',
  194. 'desc' => '订单号',
  195. 'match' => 'is_string',
  196. 'update' => 'text',
  197. //'search' => 'fulltext',
  198. //'list' => true,
  199. //'list_order' => 1,
  200. ),
  201. 'order_type' => array
  202. (
  203. 'type' => 'tinyint-1',
  204. 'name' => '订单类型',
  205. 'default' => '1',
  206. 'desc' => '订单类型',
  207. 'match' => 'is_numeric',
  208. 'option' => $order_type,
  209. ),
  210. 'mobile' => array
  211. (
  212. 'type' => 'bigint-11',
  213. 'name' => '手机号',
  214. 'default' => '',
  215. 'desc' => '请输入手机号',
  216. 'match' => Dever::rule('mobile'),
  217. 'update' => 'text',
  218. //'search' => 'fulltext',
  219. 'list' => $search_auth == 2 ? true : false,
  220. 'list_order' => 2,
  221. ),
  222. 'invite_type' => array
  223. (
  224. 'type' => 'tinyint-1',
  225. 'name' => '邀请类型',
  226. 'default' => '1',
  227. 'desc' => '邀请类型',
  228. 'match' => 'is_numeric',
  229. //'search' => 'select',
  230. 'update' => 'radio',
  231. 'option' => $invite_type,
  232. //'list' => true,
  233. //'list_order' => 7,
  234. 'control' => 'invite_type',
  235. ),
  236. 'parent_code' => array
  237. (
  238. 'type' => 'varchar-100',
  239. 'name' => '上级邀请码',
  240. 'default' => '',
  241. 'desc' => '上级邀请码',
  242. 'match' => 'is_string',
  243. 'update' => 'text',
  244. # 绑定js脚本,更新时使用,第一个参数是执行的方式,第二个参数执行的方法,第三个参数是传值。
  245. 'bind' => array('onblur', 'loading', array('url' => Dever::url("lib/member.search", 'agent'))),
  246. 'show' => 'invite_type=1',
  247. ),
  248. 'parent_mid' => array
  249. (
  250. 'type' => 'int-11',
  251. 'name' => '上级姓名/手机号',
  252. 'default' => '-1',
  253. 'desc' => '邀请人',
  254. 'match' => 'is_string',
  255. //'update' => 'text',
  256. 'search' => $search_pmid ? false : array
  257. (
  258. 'api' => 'agent/member-getSearch',
  259. 'col' => 'col',
  260. 'result' => 'id',
  261. 'search' => 'parent_mid',
  262. ),
  263. 'list_name' => '上级信息',
  264. 'list' => $search_auth == 1 ? 'Dever::load("agent/lib/member.getOne", {parent_mid})' : false,
  265. ),
  266. 'source_id' => array
  267. (
  268. 'type' => 'int-11',
  269. 'name' => '注册来源',
  270. 'default' => '-1',
  271. 'desc' => '注册来源',
  272. 'match' => 'is_numeric',
  273. 'search' => 'select',
  274. 'update' => 'radio',
  275. 'option' => $source_id,
  276. // 'list' => true,
  277. // 'list_order' => 5,
  278. // 'show' => 'invite_type=2',
  279. ),
  280. 'name' => array
  281. (
  282. 'type' => 'varchar-100',
  283. 'name' => '姓名',
  284. 'default' => '',
  285. 'desc' => '姓名',
  286. 'match' => 'is_string',
  287. 'update' => 'text',
  288. //'search' => 'fulltext',
  289. 'list' => $search_auth == 2 ? true : false,
  290. 'list_order' => 1,
  291. ),
  292. 'role' => array
  293. (
  294. 'type' => 'int-11',
  295. 'name' => '代理角色',
  296. 'default' => '',
  297. 'desc' => '代理角色',
  298. 'match' => 'is_numeric',
  299. 'search' => 'select',
  300. 'update' => 'select',
  301. 'option' => $role,
  302. 'list' => $search_auth == 2 ? true : false,
  303. 'list_order' => 3,
  304. ),
  305. 'area' => array
  306. (
  307. 'type' => 'varchar-500',
  308. 'name' => '代理区域',
  309. 'default' => '',
  310. 'desc' => '代理区域',
  311. 'match' => 'option',
  312. 'search' => 'linkage',
  313. 'update' => 'linkage',
  314. 'option' => Dever::url('api.get?level_total=4', 'area'),
  315. 'list' => $search_auth == 2 ? 'Dever::load("agent/lib/order.getArea", {id})' : false,
  316. 'list_order' => 3,
  317. ),
  318. 'desc' => array
  319. (
  320. 'type' => 'varchar-600',
  321. 'name' => '付款备注',
  322. 'default' => '',
  323. 'desc' => '付款备注',
  324. 'match' => 'is_string',
  325. 'update' => 'text',
  326. ),
  327. 'f_price' => array
  328. (
  329. 'type' => 'decimal-11,2',
  330. 'name' => '原价',
  331. 'default' => '0',
  332. 'desc' => '原价',
  333. 'match' => 'option',
  334. 'update' => 'text',
  335. ),
  336. 'price' => array
  337. (
  338. 'type' => 'decimal-11,2',
  339. 'name' => '金额',
  340. 'default' => '0',
  341. 'desc' => '金额',
  342. 'match' => 'option',
  343. 'update' => 'text',
  344. // 'list' => true,
  345. //'list_name' => '应付金额<br />实付金额<br />代理费<br />软件服务费<br />',
  346. 'list_name' => $search_auth == 1 ? '实付金额' : '总销售额',
  347. 'list' => true,
  348. // 'list' =>'Dever::load("agent/lib/order.set_price", {id})',
  349. 'list_order' => 100,
  350. ),
  351. 'pay_type' => array
  352. (
  353. 'type' => 'tinyint-1',
  354. 'name' => '支付方式',
  355. 'default' => '1',
  356. 'desc' => '支付方式',
  357. 'match' => 'is_numeric',
  358. //'search' => 'select',
  359. //'update' => 'select',
  360. 'option' => $pay_type,
  361. //'list' => true,
  362. //'list_order' => 7,
  363. ),
  364. 'pay_pic' => array
  365. (
  366. 'type' => 'text-255',
  367. 'name' => '打款凭证',
  368. 'default' => '',
  369. 'desc' => '打款凭证',
  370. 'match' => 'option',
  371. 'update' => 'images',
  372. 'key' => '1',
  373. //'place' => '150',
  374. ),
  375. 'pay_price' => array
  376. (
  377. 'type' => 'decimal-11,2',
  378. 'name' => '交款金额',
  379. 'default' => '0',
  380. 'desc' => '交款金额',
  381. 'match' => 'option',
  382. 'update' => 'text',
  383. ),
  384. 'option_price' => array
  385. (
  386. 'type' => 'decimal-11,2',
  387. 'name' => '赠送期权价值',
  388. 'default' => '0',
  389. 'desc' => '金额',
  390. 'match' => 'option',
  391. 'update' => 'text',
  392. // 'value' => Dever::input('soft_price', '0'),
  393. // 'show' => 'cstatus=2',
  394. ),
  395. 'bank_id' => array
  396. (
  397. 'type' => 'int-11',
  398. 'name' => '所属银行',
  399. 'default' => '',
  400. 'desc' => '所属银行',
  401. 'match' => 'is_numeric',
  402. ),
  403. 'bank_card' => array
  404. (
  405. 'type' => 'int-11',
  406. 'name' => '银行卡号',
  407. 'default' => '',
  408. 'desc' => '银行卡号',
  409. 'match' => 'is_numeric',
  410. ),
  411. 'type' => array
  412. (
  413. 'type' => 'tinyint-1',
  414. 'name' => '类型',
  415. 'default' => '1',
  416. 'desc' => '类型',
  417. 'match' => 'is_numeric',
  418. 'option' => $type,
  419. 'update' => 'radio',
  420. 'control' => 'type',
  421. ),
  422. 'sign' => array
  423. (
  424. 'type' => 'varchar-150',
  425. 'name' => '手写签名',
  426. 'default' => '',
  427. 'desc' => '手写签名',
  428. 'match' => 'option',
  429. 'update' => 'image',
  430. 'key' => '7',
  431. ),
  432. 'idcard' => array
  433. (
  434. 'type' => 'varchar-100',
  435. 'name' => '身份证号码',
  436. 'default' => '',
  437. 'desc' => '身份证号码',
  438. 'match' => 'is_string',
  439. 'match' => Dever::rule('idcard'),
  440. 'update' => 'text',
  441. //'search' => 'fulltext',
  442. ),
  443. 'idcard_front' => array
  444. (
  445. 'type' => 'varchar-150',
  446. 'name' => '身份证正面',
  447. 'default' => '',
  448. 'desc' => '身份证正面',
  449. 'match' => 'option',
  450. 'update' => 'image',
  451. 'key' => '8',
  452. //'place' => '660*660',
  453. ),
  454. 'idcard_back' => array
  455. (
  456. 'type' => 'varchar-150',
  457. 'name' => '身份证背面',
  458. 'default' => '',
  459. 'desc' => '身份证背面',
  460. 'match' => 'option',
  461. 'update' => 'image',
  462. 'key' => '8',
  463. //'place' => '660*660',
  464. ),
  465. 'company_name' => array
  466. (
  467. 'type' => 'varchar-100',
  468. 'name' => '公司名称',
  469. 'default' => '',
  470. 'desc' => '公司名称',
  471. 'match' => 'is_string',
  472. 'update' => 'text',
  473. //'search' => 'fulltext',
  474. //'list' => true,
  475. 'show' => 'type=2',
  476. ),
  477. 'company_pic' => array
  478. (
  479. 'type' => 'varchar-150',
  480. 'name' => '营业执照',
  481. 'default' => '',
  482. 'desc' => '营业执照',
  483. 'match' => 'option',
  484. 'update' => 'image',
  485. 'key' => '8',
  486. //'place' => '660*660',
  487. 'show' => 'type=2',
  488. ),
  489. 'company_number' => array
  490. (
  491. 'type' => 'varchar-80',
  492. 'name' => '营业执照号码',
  493. 'default' => '',
  494. 'desc' => '营业执照号码',
  495. 'match' => 'is_string',
  496. 'update' => 'text',
  497. 'show' => 'type=2',
  498. ),
  499. 'address' => array
  500. (
  501. 'type' => 'varchar-800',
  502. 'name' => '地址',
  503. 'default' => '',
  504. 'desc' => '地址',
  505. 'match' => 'is_string',
  506. 'update' => 'text',
  507. ),
  508. 'audit_desc' => array
  509. (
  510. 'type' => 'varchar-400',
  511. 'name' => '审核备注-从order_process中同步过来',
  512. 'default' => '',
  513. 'desc' => '审核备注',
  514. 'match' => 'is_string',
  515. //'update' => 'textarea',
  516. ),
  517. 'admin_desc' => array
  518. (
  519. 'type' => 'varchar-800',
  520. 'name' => '管理员备注',
  521. 'default' => '',
  522. 'desc' => '管理员备注',
  523. 'match' => 'is_string',
  524. 'update' => 'textarea',
  525. ),
  526. 'status' => array
  527. (
  528. 'type' => 'tinyint-1',
  529. 'name' => '订单状态',
  530. 'default' => '1',
  531. 'desc' => '状态',
  532. 'match' => 'is_numeric',
  533. 'option' => $status,
  534. 'search' => 'select',
  535. 'list' => $search_auth == 1 ? true : false,
  536. 'list_order' => 8,
  537. ),
  538. 'history_status' => array
  539. (
  540. 'type' => 'tinyint-1',
  541. 'name' => '记录挂起之前的状态',
  542. 'default' => '1',
  543. 'desc' => '状态',
  544. 'match' => 'is_numeric',
  545. 'option' => $status,
  546. ),
  547. 'goods_status' => array
  548. (
  549. 'type' => 'tinyint-1',
  550. 'name' => '权益状态',
  551. 'default' => '1',
  552. 'desc' => '权益状态',
  553. 'match' => 'is_numeric',
  554. 'option' => $goods_status,
  555. 'search' => 'select',
  556. 'list' => $search_auth == 1 ? true : false,
  557. 'list_order' => 9,
  558. ),
  559. 'pay_status' => array
  560. (
  561. 'type' => 'tinyint-1',
  562. 'name' => '支付状态',
  563. 'default' => '1',
  564. 'desc' => '状态',
  565. 'match' => 'is_numeric',
  566. 'option' => $pay_status,
  567. ),
  568. 'get_type' => array
  569. (
  570. 'type' => 'tinyint-1',
  571. 'name' => '获取方式',
  572. 'default' => '1',
  573. 'desc' => '获取方式',
  574. 'match' => 'is_numeric',
  575. 'update' => 'radio',
  576. 'option' => $get_type,
  577. ),
  578. 'agent_cash' => array
  579. (
  580. 'type' => 'decimal-11,2',
  581. 'name' => '代理费',
  582. 'default' => '0',
  583. 'desc' => '代理费',
  584. 'match' => 'option',
  585. 'update' => 'text',
  586. 'list' => $search_auth == 2 ? true : false,
  587. ),
  588. 'soft_cash' => array
  589. (
  590. 'type' => 'decimal-11,2',
  591. 'name' => '软件服务费',
  592. 'default' => '0',
  593. 'desc' => '软件服务费',
  594. 'match' => 'option',
  595. 'update' => 'text',
  596. 'list' => $search_auth == 2 ? '{soft_cash}' : false,
  597. ),
  598. 'goods_cash' => array
  599. (
  600. 'type' => 'decimal-11,2',
  601. 'name' => '商品价值-名额不算,商品价值第一次分配后保持不变',
  602. 'default' => '0',
  603. 'desc' => '商品价值',
  604. 'match' => 'option',
  605. 'update' => 'text',
  606. ),
  607. 'import' => array
  608. (
  609. 'type' => 'tinyint-1',
  610. 'name' => '是否导入',
  611. 'default' => '1',
  612. 'desc' => '是否导入',
  613. 'match' => 'is_numeric',
  614. 'option' => $import,
  615. 'update' => 'radio',
  616. ),
  617. 'dever_auth' => array
  618. (
  619. 'name' => '权限',
  620. 'default' => '',
  621. 'desc' => '类型',
  622. 'match' => 'is_string',
  623. 'search' => 'hidden',
  624. ),
  625. 'state' => array
  626. (
  627. 'type' => 'tinyint-1',
  628. 'name' => '状态',
  629. 'default' => '1',
  630. 'desc' => '请选择状态',
  631. 'match' => 'is_numeric',
  632. ),
  633. 'fdate' => array
  634. (
  635. 'type' => 'int-11',
  636. 'name' => '完成时间',
  637. 'default' => '',
  638. 'match' => 'is_numeric',
  639. 'search' => 'date',
  640. 'desc' => '',
  641. ),
  642. 'udate' => array
  643. (
  644. 'type' => 'int-11',
  645. 'name' => '更新时间',
  646. 'default' => '',
  647. 'match' => 'is_numeric',
  648. 'desc' => '',
  649. 'order' => 'desc',
  650. ),
  651. 'cdate' => array
  652. (
  653. 'type' => 'int-11',
  654. 'name' => '注册时间',
  655. 'match' => array('is_numeric', time()),
  656. 'default' => '',
  657. 'desc' => '',
  658. # 只有insert时才生效
  659. 'insert' => true,
  660. 'search' => 'date',
  661. // 'list' => 'date("Y-m-d H:i:s", {cdate})',
  662. 'list_name' => '注册时间<br />初审时间<br />终审时间<br />完成时间<br />',
  663. 'list' => $search_auth == 1 ? 'Dever::load("agent/lib/order.set_cdate", {id})' : false,
  664. 'list_order' => 200,
  665. ),
  666. ),
  667. 'alter' => array
  668. (
  669. 10 => array
  670. (
  671. array('update', 'price', 'price', 'decimal-11,2 0 实付金额'),
  672. array('update', 'f_price', 'f_price', 'decimal-11,2 0 原价'),
  673. array('update', 'agent_cash', 'agent_cash', 'decimal-11,2 0 代理费'),
  674. array('update', 'soft_cash', 'soft_cash', 'decimal-11,2 0 软件服务费'),
  675. array('update', 'goods_cash', 'goods_cash', 'decimal-11,2 0 商品价值'),
  676. array('update', 'pay_price', 'pay_price', 'decimal-11,2 0 交款金额'),
  677. array('update', 'option_price', 'option_price', 'decimal-11,2 0 赠送期权价值'),
  678. ),
  679. 11 => array
  680. (
  681. array('update', 'pay_pic', 'pay_pic', 'text-255 打款凭证'),
  682. ),
  683. 'version' => 11,
  684. ),
  685. 'manage' => array
  686. (
  687. //'list_table' => 'js',
  688. 'insert' => false,
  689. 'delete' => false,
  690. 'edit' => false,
  691. 'excel' => $excel,
  692. 'button' => $button,
  693. 'list_button' => $list_button,
  694. // (
  695. // //fast_list
  696. // 'list' => array('查看详情', '"order_process&project=agent&order_id={id}&page_type=1&[refer]"'),
  697. // //'edit' => array('退款', 'status,tk_time,tk_pic,tk_desc,tk_admin,tk_status', '{status} == 6'),
  698. // //'delete' => array('删除', '', '{status} == 1'),
  699. // ),
  700. ),
  701. 'request' => array
  702. (
  703. 'getNew' => array
  704. (
  705. # 匹配的正则或函数 选填项
  706. 'option' => array
  707. (
  708. 'mid' => 'yes',
  709. 'status' => array('yes', 'in'),
  710. 'state' => 1,
  711. ),
  712. 'order' => array('id' => 'desc'),
  713. 'type' => 'one',
  714. 'col' => '*',
  715. ),
  716. 'getTotal' => array
  717. (
  718. # 匹配的正则或函数 选填项
  719. 'option' => array
  720. (
  721. 'mid' => 'yes',
  722. 'status' => array('yes', 'in'),
  723. 'state' => 1,
  724. ),
  725. 'order' => array('id' => 'desc'),
  726. 'type' => 'count',
  727. 'col' => '*',
  728. ),
  729. 'getData' => array
  730. (
  731. # 匹配的正则或函数 选填项
  732. 'option' => array
  733. (
  734. 'mid' => 'yes',
  735. 'status' => array('yes', 'in'),
  736. 'state' => 1,
  737. ),
  738. 'order' => array('id' => 'desc'),
  739. 'page' => array(10, 'list'),
  740. 'type' => 'all',
  741. 'col' => '*',
  742. ),
  743. # 获取订单数量
  744. 'getNum' => array
  745. (
  746. # 匹配的正则或函数 选填项
  747. 'option' => array
  748. (
  749. 'start' => array('yes-cdate', '>='),
  750. 'end' => array('yes-cdate', '<='),
  751. 'fstart' => array('yes-fdate', '>='),
  752. 'fend' => array('yes-fdate', '<='),
  753. 'role' => 'yes',
  754. 'status' => array('yes', 'in'),
  755. 'state' => 1,
  756. ),
  757. 'type' => 'count',
  758. 'col' => '*',
  759. ),
  760. # 获取订单数量
  761. 'getCash' => array
  762. (
  763. # 匹配的正则或函数 选填项
  764. 'option' => array
  765. (
  766. 'start' => array('yes-cdate', '>='),
  767. 'end' => array('yes-cdate', '<='),
  768. 'fstart' => array('yes-fdate', '>='),
  769. 'fend' => array('yes-fdate', '<='),
  770. 'role' => 'yes',
  771. 'status' => array('yes', 'in'),
  772. 'state' => 1,
  773. ),
  774. 'type' => 'one',
  775. 'col' => 'sum(price) as total',
  776. ),
  777. 'getDailiCash' => array
  778. (
  779. # 匹配的正则或函数 选填项
  780. 'option' => array
  781. (
  782. 'start' => array('yes-cdate', '>='),
  783. 'end' => array('yes-cdate', '<='),
  784. 'fstart' => array('yes-fdate', '>='),
  785. 'fend' => array('yes-fdate', '<='),
  786. 'status' => array('yes', 'in'),
  787. 'state' => 1,
  788. ),
  789. 'type' => 'one',
  790. 'col' => 'sum(agent_cash) as total',
  791. ),
  792. #期权价值
  793. 'getOptionPrice' => array
  794. (
  795. # 匹配的正则或函数 选填项
  796. 'option' => array
  797. (
  798. 'start' => array('yes-cdate', '>='),
  799. 'end' => array('yes-cdate', '<='),
  800. 'fstart' => array('yes-fdate', '>='),
  801. 'fend' => array('yes-fdate', '<='),
  802. 'status' => array('yes', 'in'),
  803. 'role' => 'yes',
  804. 'state' => 1,
  805. ),
  806. 'type' => 'one',
  807. 'col' => 'sum(option_price) as total',
  808. ),
  809. 'getSoftCash' => array
  810. (
  811. # 匹配的正则或函数 选填项
  812. 'option' => array
  813. (
  814. 'start' => array('yes-cdate', '>='),
  815. 'end' => array('yes-cdate', '<='),
  816. 'fstart' => array('yes-fdate', '>='),
  817. 'fend' => array('yes-fdate', '<='),
  818. 'status' => array('yes', 'in'),
  819. 'role' => 'yes',
  820. 'state' => 1,
  821. ),
  822. 'type' => 'one',
  823. 'col' => 'sum(soft_cash) as total',
  824. ),
  825. 'getSoftNoCash' => array
  826. (
  827. # 匹配的正则或函数 选填项
  828. 'option' => array
  829. (
  830. 'fstart' => array('yes-cdate', '>='),
  831. 'fend' => array('yes-cdate', '<='),
  832. 'status' => array('yes', 'in'),
  833. 'state' => 1,
  834. ),
  835. 'type' => 'one',
  836. 'col' => 'sum(soft_cash) as total',
  837. ),
  838. 'getSoftNum' => array
  839. (
  840. # 匹配的正则或函数 选填项
  841. 'option' => array
  842. (
  843. 'fstart' => array('yes-fdate', '>='),
  844. 'fend' => array('yes-fdate', '<='),
  845. 'soft_cash' => array('yes', '>='),
  846. 'status' => array('yes','in'),
  847. 'state' => 1,
  848. ),
  849. 'type' => 'count',
  850. 'col' => '*',
  851. ),
  852. 'getSoftNoNum' => array
  853. (
  854. # 匹配的正则或函数 选填项
  855. 'option' => array
  856. (
  857. 'fstart' => array('yes-cdate', '>='),
  858. 'fend' => array('yes-cdate', '<='),
  859. 'soft_cash' => array('yes', '>='),
  860. 'status' => array('yes','in'),
  861. 'state' => 1,
  862. ),
  863. 'type' => 'count',
  864. 'col' => '*',
  865. ),
  866. 'getGoodsCash' => array
  867. (
  868. # 匹配的正则或函数 选填项
  869. 'option' => array
  870. (
  871. 'start' => array('yes-cdate', '>='),
  872. 'end' => array('yes-cdate', '<='),
  873. 'fstart' => array('yes-fdate', '>='),
  874. 'fend' => array('yes-fdate', '<='),
  875. 'status' => array('yes', 'in'),
  876. 'state' => 1,
  877. ),
  878. 'type' => 'one',
  879. 'col' => 'sum(goods_cash) as total',
  880. ),
  881. 'getFindOne' => array
  882. (
  883. # 匹配的正则或函数 选填项
  884. 'option' => array
  885. (
  886. 'id' => array('yes','!='),
  887. 'mid' => 'yes',
  888. 'order_type' => 'yes',
  889. 'state' => 1,
  890. ),
  891. 'type' => 'one',
  892. 'order' => array('cdate' => 'desc'),
  893. 'col' => '*',
  894. ),
  895. 'getPrice' => array
  896. (
  897. # 匹配的正则或函数 选填项
  898. 'option' => array
  899. (
  900. 'mid' => 'yes',
  901. 'status' => 4,
  902. 'state' => 1,
  903. ),
  904. 'type' => 'one',
  905. 'col' => 'sum(price) as total',
  906. ),
  907. 'getCount' => array
  908. (
  909. # 匹配的正则或函数 选填项
  910. 'option' => array
  911. (
  912. 'start' => array('yes-fdate','>='),
  913. 'end' => array('yes-fdate','<='),
  914. 'mid' => 'yes',
  915. 'parent_mid' => 'yes',
  916. 'state' => 1,
  917. ),
  918. 'type' => 'one',
  919. 'col' => 'sum(price) as total',
  920. ),
  921. 'getVCount' => array
  922. (
  923. # 匹配的正则或函数 选填项
  924. 'option' => array
  925. (
  926. 'start' => array('yes-fdate','>='),
  927. 'end' => array('yes-fdate','<='),
  928. 'mid' => 'yes',
  929. 'parent_mid' => 'yes',
  930. 'role' => array('yes','in'),
  931. 'status' => 4,
  932. 'state' => 1,
  933. ),
  934. 'type' => 'one',
  935. 'col' => 'sum(price) as total',
  936. ),
  937. 'getExcelAll' => array
  938. (
  939. # 匹配的正则或函数 选填项
  940. 'option' => array
  941. (
  942. 'start' => array('yes-cdate', '>='),
  943. 'end' => array('yes-cdate', '<='),
  944. 'fstart' => array('yes-fdate', '>='),
  945. 'fend' => array('yes-fdate', '<='),
  946. 'status' => array('yes', 'in'),
  947. 'state' => 1,
  948. ),
  949. 'type' => 'all',
  950. 'col' => '*',
  951. ),
  952. 'getSum' => array
  953. (
  954. # 匹配的正则或函数 选填项
  955. 'option' => array
  956. (
  957. 'start' => array('yes-fdate', '>='),
  958. 'end' => array('yes-fdate', '<='),
  959. 'fstart' => array('yes-fdate', '>='),
  960. 'fend' => array('yes-fdate', '<='),
  961. 'status' => array('yes', 'in'),
  962. 'role' => 'yes',
  963. 'state' => 1,
  964. ),
  965. 'type' => 'one',
  966. 'col' => 'sum(price) as total',
  967. ),
  968. 'getAll' => array
  969. (
  970. # 匹配的正则或函数 选填项
  971. 'option' => array
  972. (
  973. 'start' => array('yes-fdate','>='),
  974. 'end' => array('yes-fdate','<='),
  975. 'mid' => 'yes',
  976. 'area' => array('yes','in'),
  977. 'role' => array('yes','in'),
  978. 'state' => 1,
  979. ),
  980. 'type' => 'all',
  981. 'page' => array(20,'list'),
  982. 'col' => 'id,mid,name,mobile,idcard,soft_cash,option_price,price,area,role,agent_cash',
  983. ),
  984. 'getDataByNew' => array
  985. (
  986. # 匹配的正则或函数 选填项
  987. 'option' => array
  988. (
  989. 'id' => 'yes',
  990. 'ids' => array('yes-id', '>='),
  991. 'status' => 4,
  992. 'state' => 1,
  993. ),
  994. 'order' => array('id' => 'asc'),
  995. 'type' => 'all',
  996. //'limit' => '0,2',
  997. 'col' => '*',
  998. ),
  999. 'getDataBySoft' => array
  1000. (
  1001. # 匹配的正则或函数 选填项
  1002. 'option' => array
  1003. (
  1004. 'soft_cash' => array('yes', '>='),
  1005. 'status' => 4,
  1006. 'state' => 1,
  1007. ),
  1008. 'order' => array('id' => 'asc'),
  1009. 'type' => 'all',
  1010. 'col' => '*',
  1011. ),
  1012. ),
  1013. );