From eda4134496029060ff8cd692bd90802653ad1913 Mon Sep 17 00:00:00 2001 From: gongfuxiang Date: Sun, 26 Jan 2025 01:48:35 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A4=84=E6=96=B9=E5=BC=80=E6=96=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- components/goods-buy/goods-buy.vue | 14 +- pages.json | 12 ++ pages/goods-detail/goods-detail.vue | 13 -- .../hospital/prescription/prescription.vue | 125 ++++++++++++++++++ 4 files changed, 149 insertions(+), 15 deletions(-) create mode 100644 pages/plugins/hospital/prescription/prescription.vue diff --git a/components/goods-buy/goods-buy.vue b/components/goods-buy/goods-buy.vue index 4d436837..4b1100ca 100644 --- a/components/goods-buy/goods-buy.vue +++ b/components/goods-buy/goods-buy.vue @@ -58,7 +58,7 @@ - + @@ -771,7 +771,17 @@ ) ) }; - app.globalData.url_open('/pages/buy/buy?data=' + encodeURIComponent(base64.encode(JSON.stringify(data)))); + // 转换数据 + var data_params = encodeURIComponent(base64.encode(JSON.stringify(data))); + + // 是否互联网医院插件-开处方 + if(parseInt(this.goods.plugins_hospital_is_prescription || 0) == 1) { + app.globalData.url_open('/pages/plugins/hospital/prescription/prescription?data=' + data_params); + } else { + // 默认进去订单确认页面 + app.globalData.url_open('/pages/buy/buy?data=' + data_params); + } + // 关闭弹窗 this.popup_close_event(); break; diff --git a/pages.json b/pages.json index 78627458..9f7735a5 100644 --- a/pages.json +++ b/pages.json @@ -1710,6 +1710,18 @@ } } ] + }, + { + "root": "pages/plugins/hospital", + "pages": [ + { + "path": "prescription/prescription", + "style": { + "enablePullDownRefresh": true, + "navigationBarTitleText": "" + } + } + ] } ], "preloadRule": { diff --git a/pages/goods-detail/goods-detail.vue b/pages/goods-detail/goods-detail.vue index 3fee3872..8337f8a6 100644 --- a/pages/goods-detail/goods-detail.vue +++ b/pages/goods-detail/goods-detail.vue @@ -1365,19 +1365,6 @@ this.setData({ 'plugins_coupon_data.data': temp_list, }); - // if ((res.data.data.is_repeat_receive = 1)) { - // temp_list[index]['is_repeat_receive'] = 1; - // temp_list[index]['already_receive_text'] = '已领取'; - // temp_list[index]['already_receive_text'] = '已领取'; - // if (temp_list[index].process_data.type !== 0) { - // temp_list[index]['already_send_count'] = Number(temp_list[index]['already_send_count']) + 1; - // temp_list[index]['process_data'].value = Math.floor((Number(temp_list[index]['already_send_count']) / Number(temp_list[index]['limit_send_count'])) * 100); - // temp_list[index]['process_data'].msg = '已领' + Math.floor((Number(temp_list[index]['already_send_count']) / Number(temp_list[index]['limit_send_count'])) * 100) + '%'; - // } - // this.setData({ - // 'plugins_coupon_data.data': temp_list, - // }); - // } } else { if (app.globalData.is_login_check(res.data, this, 'coupon_receive_event')) { app.globalData.showToast(res.data.msg); diff --git a/pages/plugins/hospital/prescription/prescription.vue b/pages/plugins/hospital/prescription/prescription.vue new file mode 100644 index 00000000..f87431d2 --- /dev/null +++ b/pages/plugins/hospital/prescription/prescription.vue @@ -0,0 +1,125 @@ + + + \ No newline at end of file