user_bind.php 9.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324
  1. <?php
  2. $status = array
  3. (
  4. 1 => '未核实',
  5. 2 => '已核实',
  6. 3 => '驳回',
  7. );
  8. $manage_audit = array
  9. (
  10. //1 => '未核实',
  11. 2 => '已核实',
  12. 3 => '驳回',
  13. );
  14. $type = array
  15. (
  16. 1 => '个人',
  17. 2 => '公司',
  18. );
  19. $col = Dever::input('col');
  20. return array
  21. (
  22. # 表名
  23. 'name' => 'user_bind',
  24. # 显示给用户看的名称
  25. 'lang' => '零售绑定认证',
  26. 'end' => array
  27. (
  28. 'update' => 'agent/lib/manage.updateUserBind',
  29. ),
  30. 'status' => $status,
  31. 'order' => 1,
  32. # 数据结构
  33. 'struct' => array
  34. (
  35. 'id' => array
  36. (
  37. 'type' => 'int-11',
  38. 'name' => 'ID',
  39. 'default' => '',
  40. 'desc' => '',
  41. 'match' => 'is_numeric',
  42. 'search' => 'order',
  43. //'list' => true,
  44. ),
  45. 'uid' => array
  46. (
  47. 'type' => 'int-11',
  48. 'name' => '绑定用户',
  49. 'default' => '',
  50. 'desc' => '绑定用户',
  51. 'match' => 'is_numeric',
  52. 'update' => 'text',
  53. 'list_name' => '昵称',
  54. 'list' => '{uid} > 0 ? Dever::load("passport/user-find#username", {uid}) : "匿名用户"',
  55. 'list_order' => 1,
  56. ),
  57. 'mid' => array
  58. (
  59. 'type' => 'int-11',
  60. 'name' => '代理商姓名/手机号',
  61. 'default' => '-1',
  62. 'desc' => '代理商',
  63. 'match' => 'is_string',
  64. 'update' => 'text',
  65. 'search' => array
  66. (
  67. 'api' => 'agent/member-getSearch',
  68. 'col' => 'col',
  69. 'result' => 'id',
  70. 'search' => 'mid',
  71. ),
  72. 'list_name' => '代理商信息',
  73. 'list' => 'Dever::load("agent/lib/member.getOne", {mid}, "agent/member", true)',
  74. 'list_order' => 3,
  75. ),
  76. 'name' => array
  77. (
  78. 'type' => 'varchar-100',
  79. 'name' => '绑定姓名',
  80. 'default' => '',
  81. 'desc' => '姓名',
  82. 'match' => 'is_string',
  83. 'update' => 'text',
  84. //'search' => 'fulltext',
  85. //'list' => true,
  86. 'list_order' => 4,
  87. ),
  88. 'mobile' => array
  89. (
  90. 'type' => 'bigint-11',
  91. 'name' => '手机号',
  92. 'default' => '',
  93. 'desc' => '请输入手机号',
  94. 'match' => Dever::rule('mobile'),
  95. 'update' => 'text',
  96. //'search' => 'fulltext',
  97. 'list' => true,
  98. 'list_order' => 2,
  99. ),
  100. 'type' => array
  101. (
  102. 'type' => 'tinyint-1',
  103. 'name' => '类型',
  104. 'default' => '1',
  105. 'desc' => '类型',
  106. 'match' => 'is_numeric',
  107. 'option' => $type,
  108. 'update' => 'radio',
  109. 'control' => 'type',
  110. ),
  111. 'idcard' => array
  112. (
  113. 'type' => 'varchar-32',
  114. 'name' => '身份证号码',
  115. 'default' => '',
  116. 'desc' => '身份证号码',
  117. 'match' => 'is_string',
  118. 'update' => 'text',
  119. 'search' => 'fulltext',
  120. 'list' => true,
  121. 'list_order' => 5,
  122. ),
  123. 'idcard_front' => array
  124. (
  125. 'type' => 'varchar-150',
  126. 'name' => '身份证正面',
  127. 'default' => '',
  128. 'desc' => '身份证正面',
  129. 'match' => 'option',
  130. 'update' => 'image',
  131. 'key' => '8',
  132. 'place' => '660*660',
  133. ),
  134. 'idcard_back' => array
  135. (
  136. 'type' => 'varchar-150',
  137. 'name' => '身份证背面',
  138. 'default' => '',
  139. 'desc' => '身份证背面',
  140. 'match' => 'option',
  141. 'update' => 'image',
  142. 'key' => '8',
  143. 'place' => '660*660',
  144. ),
  145. 'company_name' => array
  146. (
  147. 'type' => 'varchar-100',
  148. 'name' => '公司名称',
  149. 'default' => '',
  150. 'desc' => '公司名称',
  151. 'match' => 'is_string',
  152. 'update' => 'text',
  153. //'search' => 'fulltext',
  154. //'list' => true,
  155. 'show' => 'type=2',
  156. ),
  157. 'company_pic' => array
  158. (
  159. 'type' => 'varchar-150',
  160. 'name' => '营业执照',
  161. 'default' => '',
  162. 'desc' => '营业执照',
  163. 'match' => 'option',
  164. 'update' => 'image',
  165. 'key' => '8',
  166. 'place' => '660*660',
  167. 'show' => 'type=2',
  168. ),
  169. 'company_number' => array
  170. (
  171. 'type' => 'varchar-80',
  172. 'name' => '营业执照号码',
  173. 'default' => '',
  174. 'desc' => '营业执照号码',
  175. 'match' => 'is_string',
  176. 'update' => 'text',
  177. 'show' => 'type=2',
  178. ),
  179. 'status' => array
  180. (
  181. 'type' => 'tinyint-1',
  182. 'name' => '状态',
  183. 'default' => '1',
  184. 'desc' => '状态',
  185. 'match' => 'is_numeric',
  186. 'option' => $status,
  187. 'search' => 'select',
  188. 'list' => true,
  189. ),
  190. 'audit' => array
  191. (
  192. 'type' => 'int-11',
  193. 'name' => '审核状态',
  194. 'default' => '2',
  195. 'desc' => '审核状态',
  196. 'match' => 'is_numeric',
  197. 'update' => $col ? 'radio' : false,
  198. 'option' => $manage_audit,
  199. 'mul' => true,
  200. 'control' => 'audit',
  201. ),
  202. 'audit_desc' => array
  203. (
  204. 'type' => 'varchar-600',
  205. 'name' => '备注',
  206. 'default' => '',
  207. 'desc' => '审核说明',
  208. 'match' => 'is_string',
  209. 'update' => $col ? 'textarea' : false,
  210. // 'list' => '"{audit_desc}" ? "{audit_desc}" : "-"',
  211. // 'list_order' => 9,
  212. 'show' => 'audit=3',
  213. ),
  214. 'audit_date' => array
  215. (
  216. 'type' => 'int-11',
  217. 'name' => '审核时间',
  218. 'default' => '',
  219. 'match' => 'is_numeric',
  220. 'desc' => '审核时间',
  221. ),
  222. 'admin' => array
  223. (
  224. 'type' => 'int-11',
  225. 'name' => '操作人',
  226. 'default' => '',
  227. 'match' => 'is_numeric',
  228. 'desc' => '操作人',
  229. //'list' => '"{admin}" > 0 ? Dever::load("manage/admin-find#username", {admin}) : "-"',
  230. ),
  231. 'state' => array
  232. (
  233. 'type' => 'tinyint-1',
  234. 'name' => '状态',
  235. 'default' => '1',
  236. 'desc' => '请选择状态',
  237. 'match' => 'is_numeric',
  238. ),
  239. 'cdate' => array
  240. (
  241. 'type' => 'int-11',
  242. 'name' => '申请日期',
  243. 'match' => array('is_numeric', time()),
  244. 'desc' => '',
  245. # 只有insert时才生效
  246. 'insert' => true,
  247. 'search' => 'date',
  248. 'list' => 'date("Y-m-d H:i", {cdate})',
  249. 'list_order' => 3,
  250. ),
  251. ),
  252. 'manage' => array
  253. (
  254. 'insert' => false,
  255. 'delete' => false,
  256. 'edit' => false,
  257. 'page_list' => 'user_bind',
  258. 'list_button' => array
  259. (
  260. 'list' => array('查看详情', '"user_bind&id={id}&page_type=1"'),
  261. //'edit' => array('退款', 'status,tk_time,tk_pic,tk_desc,tk_admin,tk_status', '{status} == 6'),
  262. 'edit' => array('审核', 'audit,audit_desc', '{status} == 1'),
  263. //'delete' => array('删除关联', '', '{status} == 2'),
  264. ),
  265. ),
  266. 'request' => array
  267. (
  268. 'getInfo' => array
  269. (
  270. # 匹配的正则或函数 选填项
  271. 'option' => array
  272. (
  273. 'status' => 2,
  274. 'state' => 1,
  275. ),
  276. 'order' => array('id' => 'desc'),
  277. 'type' => 'one',
  278. 'col' => '*',
  279. ),
  280. 'getData' => array
  281. (
  282. # 匹配的正则或函数 选填项
  283. 'option' => array
  284. (
  285. 'idcard' => 'yes',
  286. 'id' => array('yes', '!='),
  287. 'status' => 2,
  288. 'state' => 1,
  289. ),
  290. 'order' => array('id' => 'desc'),
  291. 'type' => 'all',
  292. 'page' => array(20, 'list'),
  293. 'col' => '*',
  294. ),
  295. ),
  296. );