phpyun 7.0补丁升级后由于缓存极致bug造成“网络招聘会”栏目不能显示,给小程序上架审核造成影响解决方法如下

最近Phpyun系统直接从6.44升级到了v7.0跨度非常大,以前都是0.1的标准升级现在直接跨度这么大升级内容很多,我看了下后台UI都改了 体验确实好了很多,老用户建议升级下,这次升级小程序不用重新上架,完美对接,但是有一个问题却出现了那就是升级后"网络招聘会"栏目不显示了,小程序也是,目前客服给的说法是是bug需要下一个版本里修复,。。。下一个版本又要一个月自己正在用这个功能还是自己动手吧!懂得看我教程不懂得也可以Q我2568478886分享给你请注明来自CSDN网友,我贴出代码文件对应得改过来

1 .打开app\ide\libs\sysplugins\smarty_internal_compile_fairs.php 文件114行把原始代码改成如下代码

$jobidlist = d b − > s e l e c t a l l ( " c o m p a n y j o b " , " ' i d ' i n ( " . i m p l o d e ( , ˊ , ˊ db->select_all("company_job","`id` in (".implode(\',\', db−>selectall("companyjob","'id'in(".implode(,ˊ,ˊjob_ids).") and state and status=0 and r_status=1","id");

php 复制代码
		if(is_array('.$name.')){
			foreach('.$name.' as $key=>$v){
				$array_zid[]=$v[id];
			}
            if(!empty($array_zid)){
                $rows=$db->select_all("zhaopinhui_com","`zid` in (".implode(\',\',$array_zid).") and `status`=1","`uid`,`zid`,`jobid`");
    			$zph_com=array();
                $job_ids=array();
                foreach($rows as $va){
                    
					$arr_uid[]=$a_uid[$va[zid]][]=$va[uid];

                    if($va[jobid]){

                        $job_ids = array_unique(array_merge($job_ids,@explode(",",$va[jobid])));

                    }
                    
				}
                
                if(!empty($arr_uid)){
                    $arr_uid  =  array_unique($arr_uid);
                    $joblist = $db->select_all("company_job","`uid` in (".implode(\',\',$arr_uid).") and `state`=1 and `status`=0 and `r_status`=1 GROUP BY `uid`","`uid`,count(*) as `num`");

                    $comalljobnum = array();

                    foreach($joblist as $val){
                        
                        $comalljobnum[$val[uid]] = $val[num];

                    }
                    
                    $jobidlist = $db->select_all("company_job","`id` in (".implode(\',\',$job_ids).") and `state`=1 and `status`=0 and `r_status`=1","`id`");

                    $jidarr =   array();

                    foreach($jobidlist as $jidv){
                        $jidarr[] = $jidv[id];
                    }

                    foreach($rows as $k=>$v){

                        $rows[$k][jobnum] = 0;

                        if($v["jobid"]){

                            $jobidarr = @explode(",",$v["jobid"]);

                            foreach($jobidarr as $jv){

                                if(in_array($jv,$jidarr)){

                                    $rows[$k][jobnum]++;

                                }

                            }
  1. 打开app\include\libs\sysplugins\smarty_internal_compile_zphnet.php页面
  2. 75行内容:$usercount = d b − > s e l e c t a l l ( " z p h n e t u s e r " , " ' z i d ' i n ( " . i m p l o d e ( , ˊ , ˊ db->select_all("zphnet_user","`zid` in (".implode(\',\', db−>selectall("zphnetuser","'zid'in(".implode(,ˊ,ˊzids).") and usertype=1 GROUP BY zid","zid,count(*) as num");
  3. `

$comlist = d b − > s e l e c t a l l ( " z p h n e t c o m " , " ' z i d ' i n ( " . i m p l o d e ( , ˊ , ˊ db->select_all("zphnet_com","`zid` in (".implode(\',\', db−>selectall("zphnetcom","'zid'in(".implode(,ˊ,ˊzids).") and status=1","zid,uid,jobid");

$cuids = array();
j o b i d s = a r r a y ( ) ; f o r e a c h ( job_ids=array(); foreach( jobids=array();foreach(comlist as c o m k = > comk=> comk=>comv){

$cuids[] = $comv["uid"];

            if($comv[jobid]){

                $job_ids = array_unique(array_merge($job_ids,@explode(",",$comv[jobid])));

            }
        }
        $jobarr = array();
        if(!empty($cuids)){
            $cuids  =  array_unique($cuids);
            $jobs = $db->select_all("company_job","`uid` in (".@implode(",",$cuids).") AND `state`=1 AND `r_status`=1 AND `status`=\'0\' GROUP BY `uid`","count(*) as num,uid");

            foreach($jobs as $jk=>$jv){

                $jobarr[$jv["uid"]] = $jv["num"];
            }

            $jobidlist = $db->select_all("company_job","`id` in (".implode(\',\',$job_ids).") and `state`=1 and `status`=0 and `r_status`=1","`id`");

            $jidarr =   array();

            foreach($jobidlist as $jidv){
                $jidarr[] = $jidv[id];
            }
        }`
相关推荐
丁总学Java2 小时前
页面、组件、应用、生命周期(微信小程序)
微信小程序·小程序·生命周期
编程千纸鹤7 小时前
高校宿舍信息管理系统小程序
小程序·宿舍管理小程序
说私域7 小时前
基于开源 AI 智能名片 S2B2C 商城小程序的视频号交易小程序优化研究
人工智能·小程序·零售
材料苦逼不会梦到计算机白富美14 小时前
golang分布式缓存项目 Day 1
分布式·缓存·golang
dj154022520314 小时前
group_concat配置影响程序出bug
android·bug
布值倒区什么name14 小时前
bug日常记录responded with a status of 413 (Request Entity Too Large)
运维·服务器·bug
码农派大星。14 小时前
软件测试--BUG篇
功能测试·bug
国王不在家14 小时前
【bug日志-水】解决本地开发下代理和url同名导致刷新404的问题
bug
Java 第一深情14 小时前
高性能分布式缓存Redis-数据管理与性能提升之道
redis·分布式·缓存
HBryce2415 小时前
缓存-基础概念
java·缓存