user_bind.php 7.6 KB

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