member.php 26 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904
  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. $title = function()
  13. {
  14. $array = array();
  15. $data = Dever::load('setting/title-state');
  16. if($data)
  17. {
  18. $array += $data;
  19. }
  20. return $array;
  21. };
  22. $status = array
  23. (
  24. 1 => array('name' => '未认证', 'style' => 'font-weight:bold;color:#436EEE'),
  25. 2 => array('name' => '正常', 'style' => 'font-weight:bold;color:green'),
  26. //3 => '驳回',
  27. //4 => '已删除',
  28. 5 => array('name' => '已禁用', 'style' => 'font-weight:bold;color:#CD3700'),
  29. );
  30. $type = array
  31. (
  32. 1 => '个人',
  33. 2 => '公司',
  34. );
  35. $prize_type = array
  36. (
  37. 1 => '名额外',
  38. 2 => '名额内',
  39. );
  40. $is_shop = array
  41. (
  42. 1 => '无法修改',
  43. 2 => '可以修改',
  44. );
  45. $import = array
  46. (
  47. 1 => '最新系统',
  48. 2 => 'v2旧系统导入',
  49. 3 => 'v1旧系统导入',
  50. );
  51. $is_area = array
  52. (
  53. 1 => '是',
  54. 2 => '否',
  55. );
  56. $source_id = function()
  57. {
  58. $array = array
  59. (
  60. -1 => array
  61. (
  62. 'id' => '-1',
  63. 'name' => '无来源',
  64. ),
  65. );
  66. $data = Dever::load('setting/source-state');
  67. if($data)
  68. {
  69. $array += $data;
  70. }
  71. return $array;
  72. };
  73. $level = function()
  74. {
  75. $array = array
  76. (
  77. -1 => array
  78. (
  79. 'id' => -1,
  80. 'name' => '普通',
  81. ),
  82. );
  83. $data = Dever::load('setting/level-state');
  84. if($data)
  85. {
  86. $array += $data;
  87. }
  88. return $array;
  89. };
  90. # 权限设置 1是查看详情、2是头衔统计
  91. $search_auth = Dever::input('search_option_dever_auth', 1);
  92. $info = '';
  93. $button = array();
  94. $list_button = array();
  95. if($search_auth == 1){
  96. $list_button['list'] = array('查看详情', '"member_area&mid={id}&page_type=1&[refer]"');
  97. }
  98. /*
  99. if (Dever::load('manage/auth')->checkFunc('agent.member', 'edit6', '查看关系图谱')) {
  100. $list_button['list1'] = array('查看关系图谱',Dever::url('lib/manage.relation?mid={id}&[refer].manage', 'agent'));
  101. }
  102. */
  103. # id小于50000为导入的数据
  104. return array
  105. (
  106. # 表名
  107. 'name' => 'member',
  108. # 显示给用户看的名称
  109. 'lang' => '代理商管理',
  110. 'order' => 100,
  111. 'auto' => 50000,
  112. 'config_type' => $type,
  113. 'config_status' => $status,
  114. 'info' => $info,
  115. 'start' => array
  116. (
  117. 'update' => 'agent/lib/manage.updateArea',
  118. ),
  119. # 数据结构
  120. 'struct' => array
  121. (
  122. 'id' => array
  123. (
  124. 'type' => 'int-11',
  125. 'name' => '代理商姓名/手机号',
  126. 'default' => '',
  127. 'desc' => '',
  128. 'match' => 'is_numeric',
  129. 'search' => 'order',
  130. //'list' => true,
  131. 'search' => array
  132. (
  133. 'api' => 'agent/member-getSearch',
  134. 'col' => 'col',
  135. 'result' => 'id',
  136. 'search' => 'id',
  137. ),
  138. 'list_name' => '代理商信息',
  139. 'list' => $search_auth == 1 ? 'Dever::load("agent/lib/member.getOne", {id}, "agent/member", true)' : false,
  140. ),
  141. 'name' => array
  142. (
  143. 'type' => 'varchar-100',
  144. 'name' => '代理商姓名',
  145. 'default' => '',
  146. 'desc' => '姓名',
  147. 'match' => 'is_string',
  148. 'update' => 'text',
  149. 'list_name' => $search_auth == 2 ? '姓名': false,
  150. 'list' => $search_auth == 2 ? true : false,
  151. ),
  152. 'rdate' => array
  153. (
  154. 'type' => 'int-11',
  155. 'name' => '认证时间',
  156. 'match' => 'option',
  157. 'default' => '0',
  158. 'desc' => '',
  159. 'update' => 'date',
  160. 'callback' => 'maketime',
  161. 'search' => $search_auth == 2 ? 'date' : false,
  162. // 'list' => '{rdate} > 0 ? date("Y-m-d H:i", {rdate}) : "无"',
  163. 'list' => $search_auth == 1 ? 'Dever::load("agent/lib/member.set_rdate", {id})' : false,
  164. 'list_order' => 100,
  165. ),
  166. 'avatar' => array
  167. (
  168. 'type' => 'varchar-150',
  169. 'name' => '头像',
  170. 'default' => '',
  171. 'desc' => '请选择头像',
  172. 'match' => 'option',
  173. 'update' => 'image',
  174. 'key' => '1',
  175. //'place' => '150',
  176. ),
  177. 'mobile' => array
  178. (
  179. 'type' => 'bigint-11',
  180. 'name' => '手机号',
  181. 'default' => '',
  182. 'desc' => '请输入手机号',
  183. 'match' => Dever::rule('mobile'),
  184. 'update' => 'hidden',
  185. //'search' => 'fulltext',
  186. 'list' => $search_auth == 2 ? true : false,
  187. ),
  188. 'email' => array
  189. (
  190. 'type' => 'varchar-150',
  191. 'name' => '邮箱',
  192. 'default' => '',
  193. 'desc' => '请输入邮箱',
  194. 'match' => 'option||' . Dever::rule('email'),
  195. 'update' => 'text',
  196. ),
  197. 'username' => array
  198. (
  199. 'type' => 'varchar-100',
  200. 'name' => '昵称',
  201. 'default' => '',
  202. 'desc' => '昵称',
  203. 'match' => 'is_string',
  204. 'update' => 'text',
  205. ),
  206. 'birthday' => array
  207. (
  208. 'type' => 'int-11',
  209. 'name' => '生日',
  210. 'default' => '',
  211. 'match' => 'option',
  212. 'desc' => '生日',
  213. 'update' => 'time',
  214. 'callback' => 'maketime',
  215. ),
  216. 'password' => array
  217. (
  218. 'type' => 'varchar-50',
  219. 'name' => '密码',
  220. 'default' => '',
  221. 'desc' => '请输入密码',
  222. 'match' => 'option',
  223. 'update' => 'password',
  224. 'callback' => 'sha1',
  225. ),
  226. 'parent_mid' => array
  227. (
  228. 'type' => 'int-11',
  229. 'name' => '上级姓名/手机号',
  230. 'default' => '-1',
  231. 'desc' => '邀请人',
  232. 'match' => 'is_string',
  233. //'update' => 'text',
  234. 'search' => $search_auth == 1 ? array
  235. (
  236. 'api' => 'agent/member-getSearch',
  237. 'col' => 'col',
  238. 'result' => 'id',
  239. 'search' => 'parent_mid',
  240. ) : false,
  241. 'list_name' => '上级信息',
  242. 'list' => $search_auth == 1 ? 'Dever::load("agent/lib/member.getOne", {parent_mid})' : false,
  243. ),
  244. 'source_id' => array
  245. (
  246. 'type' => 'int-11',
  247. 'name' => '注册来源',
  248. 'default' => '-1',
  249. 'desc' => '注册来源',
  250. 'match' => 'is_numeric',
  251. 'search' => 'select',
  252. //'update' => 'checkbox',
  253. 'option' => $source_id,
  254. ),
  255. 'code' => array
  256. (
  257. 'type' => 'varchar-50',
  258. 'name' => '邀请码',
  259. 'default' => '',
  260. 'desc' => '代理商邀请码',
  261. 'match' => 'option',
  262. //'update' => 'text',
  263. 'list_order'=>1,
  264. ),
  265. 'role' => array
  266. (
  267. 'type' => 'int-11',
  268. 'name' => '代理角色',
  269. 'default' => '',
  270. 'desc' => '代理角色',
  271. 'match' => 'is_numeric',
  272. 'search' => 'select',
  273. 'update' => 'select',
  274. 'option' => $role,
  275. 'list' => $search_auth == 2 ? true : false,
  276. ),
  277. 'level_id' => array
  278. (
  279. 'type' => 'int-11',
  280. 'name' => '代理商等级',
  281. 'default' => '-1',
  282. 'desc' => '代理商等级',
  283. 'match' => 'is_numeric',
  284. 'search' => 'select',
  285. 'update' => 'select',
  286. 'option' => $level,
  287. //'list' => true,
  288. ),
  289. 'title_id' => array
  290. (
  291. 'type' => 'int-11',
  292. 'name' => '代理商头衔',
  293. 'default' => '1',
  294. 'desc' => '代理商头衔',
  295. 'match' => 'is_numeric',
  296. 'search' => 'select',
  297. 'update' => 'radio',
  298. 'option' => $title,
  299. 'list' => $search_auth == 2 ? true : false,
  300. ),
  301. 'is_area' => array
  302. (
  303. 'type' => 'tinyint-1',
  304. 'name' => '是否有代理区域',
  305. 'default' => '1',
  306. 'desc' => '是否有代理区域',
  307. 'match' => 'is_numeric',
  308. 'option' => $is_area,
  309. 'update' => 'radio',
  310. ),
  311. 'area' => array
  312. (
  313. 'type' => 'varchar-500',
  314. 'name' => '代理区域',
  315. 'default' => '',
  316. 'desc' => '代理区域',
  317. 'match' => 'option',
  318. 'search' => 'linkage',
  319. 'update' => 'linkage',
  320. 'option' => Dever::url('api.get?level_total=4', 'area'),
  321. ),
  322. 'is_shop' => array
  323. (
  324. 'type' => 'tinyint-1',
  325. 'name' => '门店是否可以修改',
  326. 'default' => '2',
  327. 'desc' => '门店是否可以修改',
  328. 'match' => 'is_numeric',
  329. 'option' => $is_shop,
  330. 'update' => 'radio',
  331. ),
  332. 'shop_id' => array
  333. (
  334. 'type' => 'int-11',
  335. 'name' => '所属门店',
  336. 'default' => '',
  337. 'desc' => '所属门店',
  338. 'match' => 'is_numeric',
  339. 'update' => 'select',
  340. 'update_search' => 'shop/lib/manage.search',
  341. ),
  342. 'type' => array
  343. (
  344. 'type' => 'tinyint-1',
  345. 'name' => '类型',
  346. 'default' => '1',
  347. 'desc' => '类型',
  348. 'match' => 'is_numeric',
  349. 'option' => $type,
  350. 'update' => 'radio',
  351. 'control' => 'type',
  352. ),
  353. 'sign' => array
  354. (
  355. 'type' => 'varchar-150',
  356. 'name' => '手写签名',
  357. 'default' => '',
  358. 'desc' => '手写签名',
  359. 'match' => 'option',
  360. 'update' => 'image',
  361. 'key' => '7',
  362. ),
  363. 'idcard' => array
  364. (
  365. 'type' => 'varchar-32',
  366. 'name' => '身份证号码',
  367. 'default' => '',
  368. 'desc' => '身份证号码',
  369. 'match' => Dever::rule('idcard'),
  370. 'update' => 'text',
  371. ),
  372. 'idcard_front' => array
  373. (
  374. 'type' => 'varchar-150',
  375. 'name' => '身份证正面',
  376. 'default' => '',
  377. 'desc' => '身份证正面',
  378. 'match' => 'option',
  379. 'update' => 'image',
  380. 'key' => '8',
  381. //'place' => '660*660',
  382. ),
  383. 'idcard_back' => array
  384. (
  385. 'type' => 'varchar-150',
  386. 'name' => '身份证背面',
  387. 'default' => '',
  388. 'desc' => '身份证背面',
  389. 'match' => 'option',
  390. 'update' => 'image',
  391. 'key' => '8',
  392. //'place' => '660*660',
  393. ),
  394. 'company_name' => array
  395. (
  396. 'type' => 'varchar-100',
  397. 'name' => '公司名称',
  398. 'default' => '',
  399. 'desc' => '公司名称',
  400. 'match' => 'is_string',
  401. 'update' => 'text',
  402. //'search' => 'fulltext',
  403. //'list' => true,
  404. 'show' => 'type=2',
  405. ),
  406. 'company_pic' => array
  407. (
  408. 'type' => 'varchar-150',
  409. 'name' => '营业执照',
  410. 'default' => '',
  411. 'desc' => '营业执照',
  412. 'match' => 'option',
  413. 'update' => 'image',
  414. 'key' => '8',
  415. //'place' => '660*660',
  416. 'show' => 'type=2',
  417. ),
  418. 'company_number' => array
  419. (
  420. 'type' => 'varchar-80',
  421. 'name' => '营业执照号码',
  422. 'default' => '',
  423. 'desc' => '营业执照号码',
  424. 'match' => 'is_string',
  425. 'update' => 'text',
  426. 'show' => 'type=2',
  427. ),
  428. 'address' => array
  429. (
  430. 'type' => 'varchar-800',
  431. 'name' => '地址',
  432. 'default' => '',
  433. 'desc' => '地址',
  434. 'match' => 'is_string',
  435. 'update' => 'text',
  436. ),
  437. 'cash' => array
  438. (
  439. 'type' => 'decimal-11,2',
  440. 'name' => '余额',
  441. 'default' => '0',
  442. 'desc' => '余额',
  443. 'match' => 'is_numeric',
  444. 'update' => 'text',
  445. 'list_name' => '余额<br />直推业绩<br />团队业绩',
  446. 'list' => $search_auth == 1 ?'"{cash}<br />{sell}<br />{group_sell}"' : false,
  447. ),
  448. 'sell' => array
  449. (
  450. 'type' => 'decimal-11,2',
  451. 'name' => '直推业绩',
  452. 'default' => '0',
  453. 'desc' => '销售业绩',
  454. 'match' => 'is_numeric',
  455. 'update' => 'text',
  456. 'list' => $search_auth == 2 ? true : false,
  457. ),
  458. 'group_sell' => array
  459. (
  460. 'type' => 'decimal-11,2',
  461. 'name' => '团队业绩',
  462. 'default' => '0',
  463. 'desc' => '团队销售业绩',
  464. 'match' => 'is_numeric',
  465. 'update' => 'text',
  466. 'list' => $search_auth == 2 ? true : false,
  467. ),
  468. 'old_group_sell' => array
  469. (
  470. 'type' => 'decimal-11,2',
  471. 'name' => '历史团队业绩',
  472. 'default' => '0',
  473. 'desc' => '历史团队业绩',
  474. 'match' => 'is_numeric',
  475. 'update' => 'text',
  476. 'list_name' => $search_auth == 2 ? '新增业绩' : false,
  477. 'list' => $search_auth == 2 ? 'Dever::load("agent/lib/member.new_money",{id})': false,
  478. ),
  479. 'old_agentdownnum' => array
  480. (
  481. 'type' => 'int-11',
  482. 'name' => '历史直推人数',
  483. 'default' => '0',
  484. 'desc' => '历史团队业绩',
  485. 'match' => 'is_numeric',
  486. 'update' => 'text',
  487. ),
  488. 'old_pwd' => array
  489. (
  490. 'type' => 'varchar-32',
  491. 'name' => 'pwd',
  492. 'default' => '',
  493. 'desc' => 'pwd',
  494. 'match' => 'is_string',
  495. 'update' => 'text',
  496. ),
  497. 'old_salt' => array
  498. (
  499. 'type' => 'varchar-32',
  500. 'name' => 'salt',
  501. 'default' => '',
  502. 'desc' => 'salt',
  503. 'match' => 'is_string',
  504. 'update' => 'text',
  505. ),
  506. 'status' => array
  507. (
  508. 'type' => 'tinyint-1',
  509. 'name' => '状态',
  510. 'default' => '1',
  511. 'desc' => '状态',
  512. 'match' => 'is_numeric',
  513. 'option' => $status,
  514. 'search' => 'select',
  515. 'list' => $search_auth == 1 ? true : false,
  516. ),
  517. 'import' => array
  518. (
  519. 'type' => 'tinyint-1',
  520. 'name' => '是否导入',
  521. 'default' => '1',
  522. 'desc' => '是否导入',
  523. 'match' => 'is_numeric',
  524. 'option' => $import,
  525. 'update' => 'radio',
  526. ),
  527. 'prize_type' => array
  528. (
  529. 'type' => 'tinyint-1',
  530. 'name' => '是否名额内',
  531. 'default' => '1',
  532. 'desc' => '是否名额内',
  533. 'match' => 'is_numeric',
  534. 'option' => $prize_type,
  535. ),
  536. 'dever_auth' => array
  537. (
  538. 'name' => '权限',
  539. 'default' => '',
  540. 'desc' => '类型',
  541. 'match' => 'is_string',
  542. 'search' => 'hidden',
  543. ),
  544. 'reorder' => array
  545. (
  546. 'type' => 'int-11',
  547. 'name' => '排序(数值越大越靠前)',
  548. 'default' => '1',
  549. 'desc' => '请输入排序',
  550. 'match' => 'option',
  551. //'update' => 'text',
  552. //'search' => 'order',
  553. //'list' => true,
  554. //'order' => 'desc',
  555. //'edit' => true,
  556. ),
  557. 'state' => array
  558. (
  559. 'type' => 'tinyint-1',
  560. 'name' => '状态',
  561. 'default' => '1',
  562. 'desc' => '请选择状态',
  563. 'match' => 'is_numeric',
  564. ),
  565. 'cdate' => array
  566. (
  567. 'type' => 'int-11',
  568. 'name' => '加入日期',
  569. 'match' => array('is_numeric', time()),
  570. 'desc' => '',
  571. 'search' => $search_auth == 2 ? 'date' : false,
  572. # 只有insert时才生效
  573. 'insert' => true,
  574. //'search' => 'date',
  575. ),
  576. ),
  577. 'alter' => array
  578. (
  579. 5 => array
  580. (
  581. array('update', 'cash', 'cash', 'decimal-11,2 0 余额'),
  582. array('update', 'sell', 'sell', 'decimal-11,2 0 直推业绩'),
  583. array('update', 'group_sell', 'group_sell', 'decimal-11,2 0 团队业绩'),
  584. array('update', 'old_group_sell', 'old_group_sell', 'decimal-11,2 0 历史团队业绩'),
  585. ),
  586. 'version' => 5,
  587. ),
  588. 'index' => array
  589. (
  590. 1 => array
  591. (
  592. 'parent_mid' => 'parent_mid',
  593. ),
  594. # 版本号 更改版本号会更新当前表的索引
  595. 'version' => 1,
  596. ),
  597. 'manage' => array
  598. (
  599. 'insert' => false,
  600. 'delete' => false,
  601. 'edit' => false,
  602. 'button' => $button,
  603. 'list_button' => $list_button,
  604. ),
  605. 'request' => array
  606. (
  607. 'getInfo' => array
  608. (
  609. # 匹配的正则或函数 选填项
  610. 'option' => array
  611. (
  612. 'status' => 2,
  613. 'state' => 1,
  614. ),
  615. 'order' => array('id' => 'desc'),
  616. 'type' => 'one',
  617. 'col' => '*',
  618. ),
  619. 'getData' => array
  620. (
  621. # 匹配的正则或函数 选填项
  622. 'option' => array
  623. (
  624. 'idcard' => 'yes',
  625. 'id' => array('yes', '!='),
  626. 'status' => array('yes', 'in'),
  627. 'state' => 1,
  628. ),
  629. 'order' => array('id' => 'desc'),
  630. 'type' => 'all',
  631. 'page' => array(20, 'list'),
  632. 'col' => '*',
  633. ),
  634. 'upCash' => array
  635. (
  636. 'type' => 'update',
  637. 'where' => array
  638. (
  639. 'id' => 'yes',
  640. ),
  641. 'set' => array
  642. (
  643. 'cash' => array('yes', '+='),
  644. ),
  645. ),
  646. 'upSell' => array
  647. (
  648. 'type' => 'update',
  649. 'where' => array
  650. (
  651. 'id' => 'yes',
  652. ),
  653. 'set' => array
  654. (
  655. 'cash' => array('yes', '+='),
  656. 'upcol' => array('yes-sell', '+='),
  657. 'level_id' => 'yes',
  658. ),
  659. ),
  660. 'upGroupSell' => array
  661. (
  662. 'type' => 'update',
  663. 'where' => array
  664. (
  665. 'id' => 'yes',
  666. ),
  667. 'set' => array
  668. (
  669. 'cash' => array('yes', '+='),
  670. 'upcol' => array('yes-group_sell', '+='),
  671. 'level_id' => 'yes',
  672. ),
  673. ),
  674. 'upGroupSellOne' => array
  675. (
  676. 'type' => 'update',
  677. 'where' => array
  678. (
  679. 'id' => 'yes',
  680. ),
  681. 'set' => array
  682. (
  683. 'sell' => array('yes', '+='),
  684. 'group_sell' => array('yes', '+='),
  685. ),
  686. ),
  687. # 获取订单数量
  688. 'getNum' => array
  689. (
  690. # 匹配的正则或函数 选填项
  691. 'option' => array
  692. (
  693. 'start' => array('yes-cdate', '>='),
  694. 'end' => array('yes-cdate', '<='),
  695. 'fstart' => array('yes-rdate', '>='),
  696. 'fend' => array('yes-rdate', '<='),
  697. 'status' => 'yes',
  698. 'role' => 'yes',
  699. 'parent_mid' =>'yes',
  700. 'state' => 1,
  701. ),
  702. 'type' => 'count',
  703. 'col' => '*',
  704. ),
  705. 'getSearch' => array
  706. (
  707. # 匹配的正则或函数 选填项
  708. 'option' => array
  709. (
  710. 'col' => array('yes-mobile,name', 'like'),
  711. ),
  712. 'type' => 'all',
  713. 'col' => '*|id',
  714. ),
  715. 'getShopAll' => array
  716. (
  717. # 匹配的正则或函数 选填项
  718. 'option' => array
  719. (
  720. 'shop_id' => array('yes','>='),
  721. 'state' => 1,
  722. ),
  723. 'type' => 'all',
  724. 'col' => '*',
  725. ),
  726. 'getCount' => array
  727. (
  728. # 匹配的正则或函数 选填项
  729. 'option' => array
  730. (
  731. 'id' => 'yes',
  732. 'role' => array('yes','in'),
  733. 'prize_type' => 'yes',
  734. 'state' => 1,
  735. ),
  736. 'type' => 'count',
  737. 'col' => '*',
  738. ),
  739. 'getOutAll' => array
  740. (
  741. # 匹配的正则或函数 选填项
  742. 'option' => array
  743. (
  744. 'id' => 'yes',
  745. 'role' => 'yes',
  746. 'prize_type' => 'yes',
  747. 'state' => 1,
  748. ),
  749. 'type' => 'all',
  750. 'col' => '*',
  751. ),
  752. 'getCountByRole' => array
  753. (
  754. # 匹配的正则或函数 选填项
  755. 'option' => array
  756. (
  757. 'role' => 'yes',
  758. 'parent_mid' => 'yes',
  759. 'status' => 2,
  760. 'state' => 1,
  761. ),
  762. 'type' => 'count',
  763. 'col' => '*',
  764. ),
  765. 'search' => array
  766. (
  767. 'option' => array
  768. (
  769. 'ids' => array('yes-id', 'in'),
  770. 'name' => array('yes-name,mobile', 'like'),
  771. 'id' => 'yes',
  772. 'state' => 1,
  773. ),
  774. 'type' => 'all',
  775. 'order' => array('reorder' => 'desc', 'id' => 'desc'),
  776. 'limit' => '0,20',
  777. 'col' => 'concat(name, "(", mobile , ")") as name, id, id as value, "" as selected, "" as disabled|id',
  778. ),
  779. 'getAll' => array
  780. (
  781. # 匹配的正则或函数 选填项
  782. 'option' => array
  783. (
  784. 'start' => array('yes-rdate', '>='),
  785. 'end' => array('yes-rdate', '<='),
  786. 'status' => 'yes',
  787. 'state' => 1,
  788. ),
  789. 'type' => 'all',
  790. // 'limit' => 10,
  791. 'page' => array(20, 'list'),
  792. 'col' => 'id,name,mobile,idcard,role,group_sell',
  793. ),
  794. 'getNewParent' => array
  795. (
  796. # 匹配的正则或函数 选填项
  797. 'option' => array
  798. (
  799. 'parent_mid' => 'yes',
  800. 'state' => 1,
  801. ),
  802. 'type' => 'all',
  803. 'col' => 'id,group_sell',
  804. ),
  805. 'getDataByArea' => array
  806. (
  807. # 匹配的正则或函数 选填项
  808. 'option' => array
  809. (
  810. 'area' => array('yes', 'like'),
  811. 'state' => 1,
  812. ),
  813. 'order' => array('id' => 'desc'),
  814. 'type' => 'all',
  815. 'col' => '*',
  816. ),
  817. 'getDataByRole' => array
  818. (
  819. # 匹配的正则或函数 选填项
  820. 'option' => array
  821. (
  822. 'role' => array('yes', 'in'),
  823. 'state' => 1,
  824. ),
  825. 'order' => array('id' => 'desc'),
  826. 'type' => 'all',
  827. 'col' => '*',
  828. ),
  829. ),
  830. );