marketoneuser.html 23 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519
  1. <include file="public@header"/>
  2. </head>
  3. <body>
  4. <div class="wrap js-check-wrap">
  5. <ul class="nav nav-tabs">
  6. <li class="active">
  7. <if condition="$Request.param.agent_type eq 0">
  8. <a> {$Request.param.user_nickname}下所属普通会员</a>
  9. <elseif condition="$Request.param.agent_type eq 1">
  10. <a>{$Request.param.user_nickname}下所属分销队员</a>
  11. </if>
  12. </li>
  13. </ul>
  14. <form class="well form-inline margin-top-20" method="post" action="{:url('user/adminIndex/index',array('u'=>1))}">
  15. <!-- 用户ID:
  16. <input class="form-control" type="text" name="uid" style="width: 200px;" value="{:input('request.uid')}"
  17. placeholder="请输入用户ID"> -->
  18. 关键字:
  19. <input class="form-control" type="text" name="keyword" style="width: 200px;" value="{:input('request.keyword')}" placeholder="昵称/真实姓名/手机">
  20. <input type="submit" class="btn btn-primary" value="搜索"/>
  21. <if condition="$Request.action eq 'custom' || $Request.param.u eq 2">
  22. <a class="btn btn-default" href="{:url('user/adminIndex/index',array('u'=>2))}">清空</a>
  23. <elseif condition="$Request.action eq 'userban' || $Request.param.u eq 3">
  24. <a class="btn btn-default" href="{:url('user/adminIndex/index',array('u'=>3))}">清空</a>
  25. <elseif condition="$Request.action eq 'screen' || $Request.param.u eq 4">
  26. <a class="btn btn-default" href="{:url('user/adminIndex/index',array('u'=>4))}">清空</a>
  27. <elseif condition="$Request.action eq 'userlogout' || $Request.param.u eq 5">
  28. <a class="btn btn-default" href="{:url('user/adminIndex/index',array('u'=>5))}">清空</a>
  29. <else/>
  30. <a class="btn btn-default" href="{:url('user/adminIndex/index',array('u'=>1))}">清空</a>
  31. </if>
  32. <if condition="$Request.action eq 'custom' || $Request.param.u eq 2">
  33. <a class="btn btn-warning" href="{:url('user/adminIndex/export',array('uid'=>$Request.param.uid,'keyword'=>$Request.param.keyword,'u'=>2))}">导出</a>
  34. <elseif condition="$Request.action eq 'userban' || $Request.param.u eq 3">
  35. <a class="btn btn-warning" href="{:url('user/adminIndex/export',array('uid'=>$Request.param.uid,'keyword'=>$Request.param.keyword,'u'=>3))}">导出</a>
  36. <elseif condition="$Request.action eq 'screen' || $Request.param.u eq 4">
  37. <a class="btn btn-warning" href="{:url('user/adminIndex/export',array('uid'=>$Request.param.uid,'keyword'=>$Request.param.keyword,'u'=>4))}">导出</a>
  38. <elseif condition="$Request.action eq 'userlogout' || $Request.param.u eq 5">
  39. <a class="btn btn-warning" href="{:url('user/adminIndex/export',array('uid'=>$Request.param.uid,'keyword'=>$Request.param.keyword,'u'=>5))}">导出</a>
  40. <else/>
  41. <a class="btn btn-warning" href="{:url('user/adminIndex/export',array('uid'=>$Request.param.uid,'keyword'=>$Request.param.keyword,'u'=>1))}">导出</a>
  42. </if>
  43. <a class="btn btn-danger" onclick="doDelete()">批量删除</a>
  44. <!-- <a class="btn btn-danger" href="{:url('user/adminIndex/index')}" style="border-color:#7349B8;background-color:#7349B8">已冻结的用户</a> -->
  45. <!-- <a class="btn btn-danger" id="showcho" style="border-color:#7349B8;background-color:#7349B8">条件筛选</a> -->
  46. <div id="showchoice" style="display: none; margin-top: 10px;">
  47. <php>$educationarray=array(1=>'大专',2=>'本科',3=>'硕士',4=>'博士');</php>
  48. <php>$marriedarray=array(1=>'未婚',2=>'离异',3=>'离异有孩子');</php>
  49. <php>$propertyarray=array(0=>'无',1=>'有房',2=>'有车',3=>'有房有车');</php>
  50. <php>$agearray=array('1980','1981','1982','1983','1984','1985','1986','1987','1988','1989','1990','1991','1992','1993','1994','1995','1996','1997','1998','1999','2000');</php>
  51. <php>$sexarray=array(1=>'男',2=>'女');</php>
  52. <div>
  53. <div style="margin-top: 10px;">
  54. <!-- 年龄: <input class="form-control js-bootstrap-datetime" type="text" name="age1" style="width: 150px;margin-right:10px;" value="" placeholder="请选择年龄">
  55. <font style="color: red">至</font> &nbsp;
  56. <input class="form-control js-bootstrap-datetime" type="text" name="age2" style="width: 150px;margin-right:25px;" value="" placeholder="请选择年龄"> -->
  57. 年龄: <select class="form-control" name="age1" id="age1" style="width: 150px;margin-right:10px;">
  58. <option value="none">--请选择年龄--</option>
  59. <volist name="$agearray" id="vo">
  60. <option value="{$vo}">{$vo}</option>
  61. </volist>
  62. </select>
  63. <font style="color: red">至</font> &nbsp;
  64. <select class="form-control" name="age2" id="age2" style="width: 150px;margin-right:10px;">
  65. <option value="none">--请选择年龄--</option>
  66. <volist name="$agearray" id="vo">
  67. <option value="{$vo}">{$vo}</option>
  68. </volist>
  69. </select>
  70. 身高: <select class="form-control" name="height" id="height" style="width: 150px;margin-right:10px;">
  71. <option value="none">--请选择身高--</option>
  72. </select>
  73. <font style="color: red">至</font> &nbsp;
  74. <select class="form-control" name="heightt" id="heightt" style="width: 150px;margin-right:10px;">
  75. <option value="none">--请选择身高--</option>
  76. </select>
  77. </div>
  78. <div style="margin-top: 10px;">
  79. 学历: <select class="form-control" name="education" id="education" style="width: 150px;margin-right:10px;">
  80. <option value="none">--请选择学历--</option>
  81. <volist name="$educationarray" id="vo">
  82. <option value="{$key}">{$vo}</option>
  83. </volist>
  84. </select>
  85. 职业:
  86. <select class="form-control" name="occupation" style="margin-right: 15px;width: 150px;" id="position1">
  87. <option value="none">--请选择职位--</option>
  88. </select>
  89. 收入: <select class="form-control" name="salary" id="salary" style="width: 150px;margin-right:10px;">
  90. <option value="none">--请选择收入--</option>
  91. <option value="1">5-10w</option>
  92. <option value="2">10-20w</option>
  93. <option value="3">20-35w</option>
  94. <option value="4">35-55w</option>
  95. <option value="5">100w以上</option>
  96. </select>
  97. 资产: <select class="form-control" name="property" id="property" style="width: 150px;margin-right:10px;">
  98. <option value="none">--请选择资产--</option>
  99. <volist name="$propertyarray" id="vo">
  100. <option value="{$key}">{$vo}</option>
  101. </volist>
  102. </select>
  103. </div>
  104. <div style="margin-top: 10px;">
  105. 家乡: <input class="form-control" type="text" name="home_city" style="width: 150px;margin-right:10px;" value="" placeholder="请输入省/市">
  106. 居住地: <input class="form-control" type="text" name="city" style="width: 150px;margin-right:10px;" value="" placeholder="请输入市">
  107. 婚姻状况: <select class="form-control" name="married" id="married" style="width: 150px;margin-right:10px;">
  108. <option value="none">--请选择婚姻--</option>
  109. <volist name="$marriedarray" id="vo">
  110. <option value="{$key}">{$vo}</option>
  111. </volist>
  112. </select>
  113. 性别: <select class="form-control" name="sex" id="sex" style="width: 150px;margin-right:10px;">
  114. <option value="none">--请选择性别--</option>
  115. <volist name="$sexarray" id="vo">
  116. <option value="{$key}">{$vo}</option>
  117. </volist>
  118. </select>
  119. <a class="btn btn-warning" style=" padding: 3px 10px; border-color:#ca1883;background-color:#ca1883;color: #fff" id="nonecho">隐藏</a>
  120. </div>
  121. </div>
  122. </div>
  123. </form>
  124. <form method="post" class="js-ajax-form">
  125. <div class="table-actions">
  126. <if condition="$Request.action eq 'custom' || $Request.param.u eq 2">
  127. <button class="btn btn-primary btn-sm js-ajax-submit" type="submit"
  128. data-action="{:url('AdminIndex/tozhuxiao',array('yes'=>1))}" onclick="return confirm('确定要成为注销吗?')" data-subcheck="true">
  129. </button>
  130. </if>
  131. </div>
  132. <table class="table table-hover table-bordered">
  133. <thead>
  134. <tr>
  135. <th><input type="checkbox" class="js-check-all" data-direction="x" data-checklist="js-check-x">全选</th>
  136. <th>ID</th>
  137. <th>账号</th>
  138. <th>{:lang('NICENAME')}</th>
  139. <th>真实姓名</th>
  140. <th>爱心</th>
  141. <th style="text-align: center;">是否推荐</th>
  142. <th style="text-align: center;">推荐人</th>
  143. <th style="text-align: center;">下级用户数</th>
  144. <th style="text-align: center;">可提佣金</th>
  145. <!-- <th>等级</th> -->
  146. <if condition="$Request.action eq 'userban' || $Request.param.u eq 3">
  147. <th>冻结原因</th>
  148. <else/>
  149. <th>手机</th>
  150. </if>
  151. <if condition="$Request.action eq 'custom' || $Request.param.u eq 2 || $Request.param.u eq 4">
  152. <th>网址</th>
  153. </if>
  154. <if condition="$Request.action eq 'userban' || $Request.param.u eq 3">
  155. <th>冻结时间</th>
  156. <else/>
  157. <th>{:lang('REGISTRATION_TIME')}</th>
  158. </if>
  159. <!-- <th>登录时间</th> -->
  160. <th>{:lang('STATUS')}</th>
  161. <th>{:lang('ACTIONS')}</th>
  162. </tr>
  163. </thead>
  164. <tbody>
  165. <php>
  166. $user_statuses=array("0"=>lang('USER_STATUS_BLOCKED'),"1"=>lang('USER_STATUS_ACTIVATED'),"2"=>lang('USER_STATUS_UNVERIFIED'));
  167. </php>
  168. <foreach name="list" item="vo">
  169. <tr>
  170. <td><input type="checkbox" class="js-check" data-yid="js-check-y" data-xid="js-check-x" name="ids[]"
  171. value="{$vo.id}" title="ID:{$vo.id}"></td>
  172. <td>{$vo.id}</td>
  173. <td>{$vo['user_login']?$vo['user_login']:($vo['mobile']?$vo['mobile']:lang('THIRD_PARTY_USER'))}
  174. </td>
  175. <td>{$vo['user_nickname']?$vo['user_nickname']:lang('NOT_FILLED')}</td>
  176. <td>{$vo['real_name']?$vo['real_name']:lang('NOT_FILLED')}</td>
  177. <td>{$vo['redheart']}</td>
  178. <td style="text-align: center;">
  179. <switch name="vo.is_tuijian">
  180. <case value="1">
  181. <span style="color: blue">是</span>
  182. </case>
  183. <case value="0">
  184. <span style="color: red">否</span>
  185. </case>
  186. </switch>
  187. </td>
  188. <td style="text-align: center;">
  189. <if condition="$vo.marketusername.user_nickname eq ''">
  190. <span style="color: red">无</span>
  191. <else/>
  192. <span style="color: blue">{$vo.marketusername.user_nickname}</span>
  193. </if>
  194. </td>
  195. <td style="text-align: center;">
  196. <if condition="$vo.marketcount eq 0">
  197. <a href="#">{$vo.marketcount}</a>
  198. <else/>
  199. <a href="{:url('Market/marketoneuser',array('id'=>$vo.id,'user_nickname'=>$vo.user_nickname,'agent_type'=>0))}">{$vo.marketcount}</a>
  200. </if>
  201. </td>
  202. <td style="text-align: center;">
  203. {$vo.balance}
  204. </td>
  205. <!-- <td>{$vo.level}</td> -->
  206. <if condition="$Request.action eq 'userban' || $Request.param.u eq 3">
  207. <td><span style="color:red">{$vo.freezing}</span></td>
  208. <else/>
  209. <td>{$vo.mobile}</td>
  210. </if>
  211. <if condition="$Request.action eq 'custom' || $Request.param.u eq 2 || $Request.param.u eq 4">
  212. <td>
  213. <span class="label label-primary copy-btn copy" data-url="{:url('/weixin/member/home?id=','','',true)}{$vo.id}">复制</span>
  214. </td>
  215. </if>
  216. <if condition="$Request.action eq 'userban' || $Request.param.u eq 3">
  217. <td>{$vo.updated_at}</td>
  218. <else/>
  219. <td>{:date('Y-m-d H:i',$vo['create_time'])}</td>
  220. </if>
  221. <!-- <td>{:date('Y-m-d H:i',$vo['last_login_time'])}</td> -->
  222. <!-- <td>
  223. <switch name="vo.idcard_check">
  224. <case value="1">
  225. <span style="color:red">未审</span>
  226. </case>
  227. <case value="2">
  228. <span style="color:green">已审</span>
  229. </case>
  230. <case value="3">
  231. <span style="color:#ef9413">驳回</span>
  232. </case>
  233. <case value="">
  234. <span style="color:blue">未填</span>
  235. </case>
  236. </switch>
  237. </td>
  238. <td>
  239. <switch name="vo.position_check">
  240. <case value="0">
  241. <span style="color:blue">未填</span>
  242. </case>
  243. <case value="1">
  244. <span style="color:red">未审</span>
  245. </case>
  246. <case value="2">
  247. <span style="color:green">已审</span>
  248. </case>
  249. <case value="3">
  250. <span style="color:#ef9413">驳回</span>
  251. </case>
  252. <case value="">
  253. <span style="color:blue">未填</span>
  254. </case>
  255. </switch>
  256. </td>
  257. <td>
  258. <switch name="vo.education_check">
  259. <case value="0">
  260. <span style="color:blue">未填</span>
  261. </case>
  262. <case value="1">
  263. <span style="color:red">未审</span>
  264. </case>
  265. <case value="2">
  266. <span style="color:green">已审</span>
  267. </case>
  268. <case value="3">
  269. <span style="color:#ef9413">驳回</span>
  270. </case>
  271. <case value="">
  272. <span style="color:blue">未填</span>
  273. </case>
  274. </switch>
  275. </td> -->
  276. <td>
  277. <if condition="$Request.action eq 'userlogout' || $Request.param.u eq 5">
  278. <if condition="$vo.idcard eq '' || $vo.idcard eq null">
  279. <span style="color:green">身份已清除</span>
  280. <else/>
  281. <span style="color:red">身份未清除</span>
  282. </if>
  283. <else/>
  284. <switch name="vo.user_status">
  285. <case value="0">
  286. <span class="label label-danger">已冻结</span>
  287. </case>
  288. <case value="1">
  289. <span class="label label-success">{$user_statuses[$vo['user_status']]}</span>
  290. </case>
  291. <case value="2">
  292. <span class="label label-warning">{$user_statuses[$vo['user_status']]}</span>
  293. </case>
  294. </switch>
  295. </if>
  296. </td>
  297. <td>
  298. <if condition="$Request.action eq 'userlogout' || $Request.param.u eq 5">
  299. <a class="btn btn-xs btn-primary" href="{:url('adminIndex/edit',array('id'=>$vo['id']))}">编辑</a>
  300. <a class="btn btn-xs btn-warning js-ajax-dialog-btn" style="background-color: #d00a81;border-color:#d00a81" href="{:url('adminIndex/touserlogout',array('yes'=>1,'ids'=>$vo['id']))}" data-msg="确认清理该用户身份证信息?">清除身份证信息</a>
  301. <else/>
  302. <if condition="$Request.action eq 'custom' || $Request.param.u eq 2">
  303. <a class="btn btn-xs btn-primary" href="{:url('adminIndex/edit',array('id'=>$vo['id'],'u'=>2))}">编辑</a>
  304. <else/>
  305. <a class="btn btn-xs btn-primary" href="{:url('adminIndex/edit',array('id'=>$vo['id']))}">编辑</a>
  306. </if>
  307. <neq name="vo.id" value="1">
  308. <empty name="vo.user_status">
  309. <a class="btn btn-xs btn-success js-ajax-dialog-btn"
  310. href="{:url('adminIndex/cancelban',array('id'=>$vo['id']))}"
  311. data-msg="{:lang('ACTIVATE_USER_CONFIRM_MESSAGE')}">{:lang('ACTIVATE_USER')}</a>
  312. <else/>
  313. <!-- <a class="btn btn-xs btn-warning js-ajax-dialog-btn"
  314. href="{:url('adminIndex/ban',array('id'=>$vo['id']))}"
  315. data-msg="确认冻结该用户?">冻结</a> -->
  316. <a class="btn btn-xs btn-warning" onclick="getPaike({$vo['id']})"
  317. >冻结</a>
  318. </empty>
  319. <else/>
  320. <a class="btn btn-xs btn-warning disabled">冻结</a>
  321. </neq>
  322. <if condition="$Request.action eq 'userban' || $Request.param.u eq 3">
  323. <else/>
  324. <php> $adminId = cmf_get_current_admin_id(); </php>
  325. <!-- <if condition="$adminId eq 1">
  326. <a class="btn btn-xs btn-danger" href="{:url('adminIndex/accountadd',array('id'=>$vo['id']))}">爱心充值</a>
  327. </if> -->
  328. </if>
  329. <a class="btn btn-xs btn-danger" style="background-color: #5c0d8e;border-color:#5c0d8e" onclick="getPaike2({$vo['id']})">奖励充值</a>
  330. <if condition="$Request.action eq 'screen' || $Request.param.u eq 2">
  331. <a class="btn btn-xs btn-danger" style="background-color: #e807b8;border-color:#e807b8" onclick="getPaike2({$vo['id']})">备注</a>
  332. </if>
  333. </if>
  334. </td>
  335. </tr>
  336. </foreach>
  337. </tbody>
  338. </table>
  339. <div class="pagination">{$page}</div>
  340. </form>
  341. </div>
  342. <script src="__STATIC__/js/admin.js"></script>
  343. <script src="__STATIC__/js/clipboard.min.js"></script>
  344. <script src="__STATIC__/js/layer/layer.js"></script>
  345. <script>
  346. function doDelete() {
  347. // Wind.use('artDialog', function () {
  348. var ids = [];
  349. $(".js-check:checked").each(function () {
  350. var id = $(this).val();
  351. if (id > 0) {
  352. ids.push(id);
  353. }
  354. });
  355. if (ids.length <= 0) {
  356. showMsg('请先选择操作项');
  357. return false;
  358. }
  359. if(confirm('确定批量删除选择项?不可恢复')){
  360. $.post('/user/admin_index/del',{id:ids},function(res){
  361. if(res.code == 1){
  362. showMsg(res.msg);
  363. setTimeout(function () {
  364. location.reload();
  365. }, 800)
  366. }else{
  367. showMsg(res.msg);
  368. }
  369. },"json")
  370. }
  371. // });
  372. }
  373. function getPaike(id){
  374. var addUrl = "{:url('AdminIndex/ban')}?id="+id;
  375. layer.open({
  376. type: 2, //1:页面层,2:iframe层,3:加载层,4:tips层。
  377. title: '条件筛选',
  378. shadeClose: false, //不开启遮罩关闭,也就是说,点击弹出层其它地方不会关闭弹出框
  379. shade: 0.8, //遮罩
  380. area: ['480px', '360px'],
  381. content: addUrl,
  382. end: function () { //最后执行reload
  383. location.reload();
  384. }
  385. });
  386. }
  387. $("#showcho").click(function(){
  388. $("#showchoice").show();
  389. });
  390. $("#nonecho").click(function(){
  391. $("#showchoice").hide();
  392. });
  393. /* function showMsg(msg, time){
  394. time = time? time : 1000;
  395. art.dialog({
  396. content: msg,
  397. icon: 'warning'
  398. });
  399. setTimeout(function () {
  400. }, time)
  401. }*/
  402. </script>
  403. <script >
  404. function getPaike2(id){
  405. openIframeLayer("{:url('market/marketshowreward')}?id=" + id , "", {
  406. area: ['600px', '300px'],
  407. // btn: ['确定', '取消'],
  408. })
  409. }
  410. </script>
  411. </body>
  412. </html>