苹果cms采集二次更新豆瓣ID豆瓣评分,手动查询豆瓣评分视频数据

application/admin/view/system/configcollect.html 第155行左右增加如下代码

<input type="checkbox" lay-skin="primary" name="collect[vod][uprule][]" value="tv" title="豆瓣ID" {if condition="strpos($config['collect']['vod']['uprule'],'tv') !==false"}checked {/if}>
<input type="checkbox" lay-skin="primary" name="collect[vod][uprule][]" value="av" title="豆瓣评分" {if condition="strpos($config['collect']['vod']['uprule'],'av') !==false"}checked {/if}>

 

application/common/model/Collect.php中在545行 注释掉 $v[‘vod_score’] = round($v[‘vod_score_all’] / $v[‘vod_score_num’], 1); 后下增加如下代码

//$v['vod_score'] = round($v['vod_score_all'] / $v['vod_score_num'], 1);
                    // 模板score评分排序无效,所以将douban_score值赋给score
                    $v['vod_score'] = $v['vod_douban_score'];

图片[1]-苹果cms采集二次更新豆瓣ID豆瓣评分,手动查询豆瓣评分视频数据-301cool

application/common/model/Collect.php中在第914行左右下面增加如下代码

if (strpos(',' . $config['uprule'], 'tv')!==false && !empty($v['vod_douban_id']) && $v['vod_douban_id']!=$info['vod_douban_id']) {
                            $update['vod_douban_id'] = $v['vod_douban_id'];
                        }
                       if (strpos(',' . $config['uprule'], 'av')!==false && !empty($v['vod_douban_score']) && $v['vod_douban_score']!=$info['vod_douban_id'] && $v['vod_douban_score'] != 0) {
                            $update['vod_douban_score'] = $v['vod_douban_score'];
                        }

 

图片[2]-苹果cms采集二次更新豆瓣ID豆瓣评分,手动查询豆瓣评分视频数据-301cool
后台效果:

图片[3]-苹果cms采集二次更新豆瓣ID豆瓣评分,手动查询豆瓣评分视频数据-301cool

苹果cms v10 豆瓣评分信息采集api接口源码

下载 douban.php

打开/application/admin/view/vod/info.html 搜索url: ‘

timeout: 5000,
url: '//' + 'api' + '.' + 'mac'+ 'cms' + '.'+ 'la' + '/douban/index/id/' + id,

 

替换为:
timeout: 10000,
url: 'https://你的域名/api/douban.php?id=' + id,

 

图片[3]-苹果cms采集二次更新豆瓣ID豆瓣评分,手动查询豆瓣评分视频数据-301cool

© 版权声明
THE END
喜欢就支持一下吧
点赞5 分享
评论 抢沙发

    暂无评论内容