From f74fb13f6e6f0a8fc4f46d6a262358e86c01f222 Mon Sep 17 00:00:00 2001 From: QIanGua Date: Sat, 23 Mar 2019 16:58:29 +0800 Subject: [PATCH] bug fix (#1810) update the website address --- docs/README.md | 12 +++++------ lib/routes/universities/zju/career/index.js | 22 +++++++------------- lib/routes/universities/zju/physics/index.js | 7 +++++-- 3 files changed, 19 insertions(+), 22 deletions(-) diff --git a/docs/README.md b/docs/README.md index cb837add8..afe580911 100755 --- a/docs/README.md +++ b/docs/README.md @@ -2074,7 +2074,7 @@ https://rsshub.app/**nuist**/`bulletin` 或 https://rsshub.app/**nuist**/`bullet ### 浙江大学 - + | 全部公告 | 教学管理 | 各类资助 | 学科建设 | 海外交流 | | -------- | -------- | -------- | -------- | -------- | @@ -2082,7 +2082,7 @@ https://rsshub.app/**nuist**/`bulletin` 或 https://rsshub.app/**nuist**/`bullet - + | 新闻动态 | 活动通知 | 学院通知 | 告示通知 | | -------- | -------- | -------- | -------- | @@ -2090,11 +2090,11 @@ https://rsshub.app/**nuist**/`bulletin` 或 https://rsshub.app/**nuist**/`bullet - + -| 本系动态 | 科研通知 | 研究生教育最新消息 | 学生思政最新消息 | 研究生思政消息公告 | 研究生奖助学金 | 研究生思政就业信息 | 本科生思政消息公告 | 本科生奖助学金 | 本科生就业信息 | -| -------- | -------- | ------------------ | ---------------- | ------------------ | -------------- | ------------------ | ------------------ | -------------- | -------------- | -| 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | +| 本系动态 | 科研通知 | 研究生教育最新消息 | 学生思政最新消息 | 研究生思政消息公告 | 研究生奖助学金 | 研究生思政就业信息 | 本科生思政消息公告 | 本科生奖助学金 | 本科生就业信息 | 学术报告 | +| -------- | -------- | ------------------ | ---------------- | ------------------ | -------------- | ------------------ | ------------------ | -------------- | -------------- | -------- | +| 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | diff --git a/lib/routes/universities/zju/career/index.js b/lib/routes/universities/zju/career/index.js index 1853e61b6..68b25c7b0 100644 --- a/lib/routes/universities/zju/career/index.js +++ b/lib/routes/universities/zju/career/index.js @@ -1,22 +1,14 @@ const axios = require('../../../../utils/axios'); const cheerio = require('cheerio'); -const host = 'http://www.career.zju.edu.cn/jyxt/jygz/new/getContent.zf?minCount=0&maxCount=10&lmjdid=739BEBB72A072B25E0538713470A6C41&sjlmid=undefined&lmtype=2&lx=2&_='; +const host = 'http://www.career.zju.edu.cn/jyxt/jygz/new/getContent.zf?minCount=0&maxCount=10&'; const map = new Map([ - [1, { title: '浙大就业服务平台 -- 新闻动态', id: '1553156316534' }], - [2, { title: '浙大就业服务平台 -- 活动通知', id: '1553156316535' }], - [3, { title: '浙大就业服务平台 -- 学院动态', id: '1553156316536' }], - [4, { title: '浙大就业服务平台 -- 告示通告', id: '1553156316537' }], + [1, { title: '浙大就业服务平台 -- 新闻动态', id: 'lmjdid=739BEBB72A072B25E0538713470A6C41&sjlmid=undefined&lmtype=2&lx=2&_=670' }], + [2, { title: '浙大就业服务平台 -- 活动通知', id: 'lmjdid=739BEBB72A0B2B25E0538713470A6C41&sjlmid=undefined&lmtype=2&lx=2&_=1196' }], + [3, { title: '浙大就业服务平台 -- 学院动态', id: 'lmjdid=739BEBB72A0C2B25E0538713470A6C41&sjlmid=undefined&lmtype=2&lx=2&_=8' }], + [4, { title: '浙大就业服务平台 -- 告示通告', id: 'lmjdid=739BEBB72A252B25E0538713470A6C41&sjlmid=undefined&lmtype=2&lx=2&_=15' }], ]); -// http://www.career.zju.edu.cn/jyxt/jygz/new/getContent.zf?minCount=0&maxCount=10&lmjdid=739BEBB72A072B25E0538713470A6C41&sjlmid=undefined&lmtype=2&lx=2&_=1553156316534 - -// http://www.career.zju.edu.cn/jyxt/jygz/new/getContent.zf?minCount=0&maxCount=10&lmjdid=739BEBB72A0B2B25E0538713470A6C41&sjlmid=undefined&lmtype=2&lx=2&_=1553156316535 - -// http://www.career.zju.edu.cn/jyxt/jygz/new/getContent.zf?minCount=0&maxCount=10&lmjdid=739BEBB72A0C2B25E0538713470A6C41&sjlmid=undefined&lmtype=2&lx=2&_=1553156316536 - -// http://www.career.zju.edu.cn/jyxt/jygz/new/getContent.zf?minCount=0&maxCount=10&lmjdid=739BEBB72A252B25E0538713470A6C41&sjlmid=undefined&lmtype=2&lx=2&_=1553156316537 - module.exports = async (ctx) => { const type = Number.parseInt(ctx.params.type); const id = map.get(type).id; @@ -38,7 +30,9 @@ module.exports = async (ctx) => { // title: item.find('a').attr('title'), title: item.find('.news-ctn').text(), pubDate: new Date(item.find('.new-time').text()).toUTCString(), - link: `www.career.zju.edu.cn/${item + + link: `www.career.zju.edu.cn${item + .find('a') .eq(0) .attr('href')}`, diff --git a/lib/routes/universities/zju/physics/index.js b/lib/routes/universities/zju/physics/index.js index 922fa59c0..bc7eb72f4 100644 --- a/lib/routes/universities/zju/physics/index.js +++ b/lib/routes/universities/zju/physics/index.js @@ -2,7 +2,8 @@ const axios = require('../../../../utils/axios'); const cheerio = require('cheerio'); const iconv = require('iconv-lite'); -const host = 'http://physics.zju.edu.cn/redir.php?catalog_id='; +// const host = 'http://physics.zju.edu.cn/redir.php?catalog_id='; +const host = 'http://10.14.122.238/redir.php?catalog_id='; const map = new Map([ [1, { title: '浙大物理系 -- 本系动态', id: '66' }], @@ -15,6 +16,7 @@ const map = new Map([ [8, { title: '浙大物理系 -- 本科生思政消息公告', id: '667' }], [9, { title: '浙大物理系 -- 本科生奖助学金', id: '670' }], [10, { title: '浙大物理系 -- 本科生就业信息', id: '671' }], + [11, { title: '浙大物理系 -- 学术报告', id: '3735' }], ]); module.exports = async (ctx) => { @@ -40,7 +42,8 @@ module.exports = async (ctx) => { title: item.find('a').text(), // title: item.find('a').attr('title'), pubDate: new Date(item.find('.date').text()).toUTCString(), - link: `http://physics.zju.edu.cn/${item.find('a').attr('href')}`, + // link: `http://physics.zju.edu.cn/${item.find('a').attr('href')}`, + link: `http://10.14.122.238/${item.find('a').attr('href')}`, }; }) .get();