class Mechanism { constructor() { header("机构") footer(); this.getmechanism() } async getmechanism() { var res = await indexServe.mechanism({ }); console.log(res); res.forEach((v) => { $(".list").html(`
${v.title}
${v.id}套
`) }) } } new Mechanism()