order.php 33 KB

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