UNPKG

rsshub

Version:
27 lines (26 loc) 906 B
import { n as fetchMain, t as fetchDetail } from "./utils-BhkQG3L7.mjs"; //#region lib/routes/lixin/xsc.ts const route = { path: "/xsc/:id", categories: ["university"], example: "/lixin/xsc/13789", parameters: { id: "类别 ID,`info/iList.jsp?cat_id=` 后方数字" }, name: "学生处", maintainers: ["NeverBehave"], handler }; async function handler(ctx) { const { id } = ctx.req.param(); const baseUrl = "https://xsc.lixin.edu.cn"; const link = `${baseUrl}/info/iList.jsp?cat_id=${id}`; const { list, title } = await fetchMain(link, "body > div.details > div.contentright > div.rightlist > ul > li"); const items = await fetchDetail(list, baseUrl, "body > div.neirong > div.rong"); return { title: `${title} - 学生处 - 上海立信会计金融学院`, link, description: `${title} - 学生处 - 上海立信会计金融学院`, item: items }; } //#endregion export { route };