Files
coupon/pages/peizhen/peizhen.js
renjianbo0118 548fe4a47b AA
2023-05-14 00:33:17 +08:00

120 lines
2.7 KiB
JavaScript

//获取应用实例
var app = getApp();
Page({
data: {
option1: [{
text: '全部医院',
value: 0
},
{
text: '西京医院',
value: 1
},
{
text: '陕西省人民医院',
value: 2
},
{
text: '陕西省人民医院1',
value: 5
},
],
value1: 0,
version_number: '1.0',
height: '',
url: app.globalData.url,
itemView: [
{
icon: "诊前约号",
title: "全程陪诊",
price:"200",
describe:"服务内容:排队 预约 挂号 缴费 取药 记录医嘱"
},
{
icon: "诊前约号",
title: "诊前约号",
price:"20",
describe:"服务内容:协助办理完成挂号"
},
// {
// icon: "代办买药",
// title: "代办买药",
// price:"30",
// describe:"服务内容:协助代理买药"
// },
{
icon: "取送结果",
title: "代办问诊",
price:"50",
describe:"服务内容:使用病人或者家属取检查报告化验单向医生问明情况"
},
{
icon: "取送结果",
title: "取送结果",
price:"50",
describe:"服务内容:包括给病人或者家属取检查报告化验单等"
},
// {
// icon: "出入院办理",
// title: "出入院办理",
// price:"100",
// describe:"协助办理出入院手续"
// }
],
},
onChange(e) {
this.setData({
timeData: e.detail,
});
},
//生命周期回调——监听小程序启动或切前台。
onShow: function () {
this.getBannerAndCat();
},
//首页信息
getBannerAndCat: function () {
var that = this;
wx.request({
url: app.globalData.url + '/system/hospitalUserView/list',
header: app.getRequestHeader(),
method: 'GET',
data: {
},
success: (res) => {
var resp = res.data;
if (res.data.code == 200) {
that.setData({
special_offer: resp.data,
});
}
}
});
},
// 跳转详情
details(e) {
if (e.currentTarget.dataset.item != 0) {
let item = JSON.stringify(e.currentTarget.dataset.item);
console.log("传递的item" + item);
wx.navigateTo({
url: "/pages/peizhen/peizhendetail?item=" + item,
});
}
},
back(e){
wx.navigateBack()
},
onLoad() {
var statusBarHeight = wx.getSystemInfoSync().statusBarHeight;
this.setData({
statusBarHeight: statusBarHeight,
height: 46 + statusBarHeight,
});
},
changeDateTime1(e) {
this.setData({
dateTime1: e.detail.value
});
},
})