UNPKG

rsshub

Version:
55 lines (53 loc) 1.4 kB
import "./dist-Bog6z_OM.mjs"; import "./config-MQ-7ebJ_.mjs"; import "./logger-C4avouvV.mjs"; import "./ofetch-DKl_Ma9g.mjs"; import { t as parseDate } from "./parse-date-r5WDWHno.mjs"; import "./helpers-Bo4JQYdN.mjs"; import { t as got_default } from "./got-CO-ndVl2.mjs"; import { load } from "cheerio"; //#region lib/routes/sustech/bidding.ts const route = { path: "/bidding", categories: ["university"], example: "/sustech/bidding", parameters: {}, features: { requireConfig: false, requirePuppeteer: false, antiCrawler: false, supportBT: false, supportPodcast: false, supportScihub: false }, radar: [{ source: ["biddingoffice.sustech.edu.cn/"] }], name: "采购与招标管理部", maintainers: ["sparkcyf"], handler, url: "biddingoffice.sustech.edu.cn/" }; async function handler() { const link = "http://biddingoffice.sustech.edu.cn"; const data = (await got_default({ method: "get", url: link })).data; const $ = load(data); const list = $(".index-wrap.index-2 ul li"); return { title: "南方科技大学采购与招标管理部", link, item: list && list.toArray().map((item) => { item = $(item); const itemPubdate = item.find("li > span").text(); const a = item.find("li > a"); return { pubDate: parseDate(itemPubdate, "YYYY-MM-DD"), title: a.text(), link: a.attr("href") }; }) }; } //#endregion export { route };