Application/Admin/Controller/YaoshiController.class.php

(开头部分) 8KB

这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。

<?php

    /*******************************************************************\
    |                                                                   |
    |   开单大师(专业的房产中介管理系统)                              |
    |                                                                   |
    |   © 2017-2023 http://www.kaidandashi.com/ All rights reserved     |
    |                                                                   |
    |   本系统由淮南市银泰软件科技有限公司提供技术支持                  |
    |                                                                   |
    |   QQ号:984784483                                                 |
    |                                                                   |
    \*******************************************************************/

    namespace Admin\Controller;
    use Think\Controller;
    class YaoshiController extends CommonController {
        public function index(){
            if (I('is_ajax')) {
                /*权限控制开始*/
                $condition = "e.gongsiid=".session('gongsiid');
                $x = _rbac_lists_where(747,0);
                if ($x && $x != "all" && $x != "me") {
                    $condition .= " and e.bumen in ({$x})";
                }elseif ($x == "me") {
                    $condition .= " and e.id=".session('uid');
                }elseif ($x == false) {
                    $condition .= " and e.id=0";
                }
                /*权限控制结束*/
                $sousuo = I('sousuo');
                $bumen = I("get.bumen",0,'intval');
                if ($bumen) {
                    $string = get_bm_sz($bumen,2);
                    $condition .= " and a.ys_bumen in ($string)";
                }
                $shijian = I('shijian');
                if ($shijian) {
                    $time_s = explode(' - ',$shijian);
                    $time_s1 = strtotime($time_s[0]);
                    $time_s2 = strtotime($time_s[1])+86400;
                    $condition .= " and a.addtime>=".$time_s1." and a.addtime<".$time_s2;
                }
                if ($sousuo) {
                    $condition .= " and ((e.pinyinjs like '%$sousuo%') or (e.ygmingcheng like '%$sousuo%') or (e.dianhua like '%$sousuo%') or (a.fybianhao like '%$sousuo%') or (a.ys_bianhao like '%$sousuo%'))";
                }
                $field = I('field'); //排序字段名
                $order = I('order'); //排序方式
                $limit = I('limit',30,'int'); //每页条数
                $limit = $limit > 150 ? 150 : $limit;
                if ($field && $order) {
                    $yspx = "order by a.".$field." ".$order;
                } else {
                    $yspx = "order by a.id desc";
                }
                $Model = new \Think\Model();
                $sqlcount = "select count(*) from __YAOSHI__ a join __YONGHU__ e on a.ys_uid=e.id where {$condition}";
                $Page = new \Think\Page($count['0']['count(*)'],$limit);
                $list = "select a.*,e.ygmingcheng from __YAOSHI__ a join __YONGHU__ e on a.ys_uid=e.id where {$condition} ".$yspx." limit ".$Page->firstRow.','.$Page->listRows;
                $data = $Model->query($list);
后面还有 88 行代码,解锁后查看完整代码

24 小时内免费解锁 3 个项目,之后 1 积分/个。 规则说明

AI 解读

登录后可用,每次 10 积分,解读结果公开显示在下面。

还没有人解读过这个文件。