tmp
This commit is contained in:
@@ -1,7 +1,8 @@
|
||||
import ResponseUtil from "../utils/responseUtil.js";
|
||||
import services from "../resource/services.js";
|
||||
import agreement from "../resource/agreement.js";
|
||||
import hospitalContact from "../resource/hospital_contact.js";
|
||||
import hospitalInfo from "../resource/hospital_info.js";
|
||||
import { hospitalRanking, departmentRankings } from "../resource/hospital_ranking.js";
|
||||
|
||||
class HandlerResource {
|
||||
constructor() {
|
||||
@@ -25,10 +26,28 @@ class HandlerResource {
|
||||
}
|
||||
}
|
||||
|
||||
// 获取医院联系电话
|
||||
async getHospitalContact(ctx) {
|
||||
// 获取医院信息
|
||||
async getHospitalInfo(ctx) {
|
||||
try {
|
||||
return ResponseUtil.success(ctx, { hospitalContact }, "查询成功");
|
||||
return ResponseUtil.success(ctx, { hospitalInfo }, "查询成功");
|
||||
} catch (err) {
|
||||
return ResponseUtil.internalError(ctx, err.message);
|
||||
}
|
||||
}
|
||||
|
||||
// 获取医院排名
|
||||
async getHospitalRanking(ctx) {
|
||||
try {
|
||||
return ResponseUtil.success(ctx, { hospitalRanking }, "查询成功");
|
||||
} catch (err) {
|
||||
return ResponseUtil.internalError(ctx, err.message);
|
||||
}
|
||||
}
|
||||
|
||||
// 获取科室排名
|
||||
async getDepartmentRankings(ctx) {
|
||||
try {
|
||||
return ResponseUtil.success(ctx, { departmentRankings }, "查询成功");
|
||||
} catch (err) {
|
||||
return ResponseUtil.internalError(ctx, err.message);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user