WXL
13 小时以前 05c363fdd7ab04e3bd9a753e2c5d5bfff04d681c
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
"use strict";
const common_vendor = require("../../common/vendor.js");
const _sfc_main = {
  __name: "detail",
  setup(__props) {
    const hospital = common_vendor.ref({
      id: 1,
      name: "青岛镜湖医院",
      type: "三级甲等综合医院",
      logo: "/static/hospital/kiang-wu.jpg",
      coverImage: "/static/hospital/kiang-wu.png",
      address: "青岛连胜马路33号",
      phone: "+853 2837 1333",
      hours: "门诊:周一至周日 8:00-22:00\n急诊:24小时",
      tags: ["综合医院", "24小时急诊", "特需门诊"],
      introduction: "青岛镜湖医院创立于1871年,是青岛历史最悠久的非牟利医疗机构...",
      images: [
        "/static/hospital/image1.jpg",
        "/static/hospital/image2.jpg",
        "/static/hospital/image3.jpg"
      ],
      featuredDepartments: [
        {
          id: 1,
          name: "心内科",
          icon: "/static/department/cardiology.png",
          description: "心血管疾病诊治"
        }
      ],
      latitude: 22.1934,
      longitude: 113.5529,
      transport: [
        {
          type: "公交路线",
          route: "3、3X、10、10A、23、32等路公交车到镜湖医院站"
        },
        {
          type: "轻轨路线",
          route: "青岛轻轨氹仔线到科技大学站,步行约10分钟"
        }
      ]
    });
    const previewImage = (index) => {
      common_vendor.index.previewImage({
        urls: hospital.value.images,
        current: index
      });
    };
    const navigateToDepartment = (dept) => {
      common_vendor.index.navigateTo({
        url: `/pages/department/detail?id=${dept.id}&hospitalId=${hospital.value.id}`
      });
    };
    common_vendor.onMounted(() => {
      var _a, _b;
      const pages = getCurrentPages();
      const page = pages[pages.length - 1];
      (_b = (_a = page.$page) == null ? void 0 : _a.options) == null ? void 0 : _b.id;
      loadHospitalDetail();
    });
    const loadHospitalDetail = (id) => {
    };
    return (_ctx, _cache) => {
      return {
        a: hospital.value.coverImage,
        b: hospital.value.logo,
        c: common_vendor.t(hospital.value.name),
        d: common_vendor.t(hospital.value.type),
        e: common_vendor.f(hospital.value.tags, (tag, idx, i0) => {
          return {
            a: common_vendor.t(tag),
            b: idx
          };
        }),
        f: common_vendor.t(hospital.value.address),
        g: common_vendor.t(hospital.value.phone),
        h: common_vendor.t(hospital.value.hours),
        i: common_vendor.t(hospital.value.introduction),
        j: common_vendor.f(hospital.value.images, (img, idx, i0) => {
          return {
            a: idx,
            b: img,
            c: common_vendor.o(($event) => previewImage(idx), idx)
          };
        }),
        k: common_vendor.f(hospital.value.featuredDepartments, (dept, index, i0) => {
          return {
            a: dept.icon,
            b: common_vendor.t(dept.name),
            c: common_vendor.t(dept.description),
            d: index,
            e: common_vendor.o(($event) => navigateToDepartment(dept), index)
          };
        }),
        l: hospital.value.latitude,
        m: hospital.value.longitude,
        n: [{
          latitude: hospital.value.latitude,
          longitude: hospital.value.longitude,
          iconPath: "/static/icons/marker.png",
          width: 32,
          height: 32
        }],
        o: common_vendor.f(hospital.value.transport, (item, idx, i0) => {
          return {
            a: common_vendor.t(item.type),
            b: common_vendor.t(item.route),
            c: idx
          };
        }),
        p: common_vendor.gei(_ctx, "")
      };
    };
  }
};
wx.createPage(_sfc_main);
//# sourceMappingURL=../../../.sourcemap/mp-weixin/pages/hospital/detail.js.map