Browse Source

push id 适配

dev
kola-web 2 weeks ago
parent
commit
de550aa169
  1. 14
      project.private.config.json
  2. 3
      src/pages/home/index.wxml
  3. 13
      src/patient/pages/liveDetail/index.ts
  4. 16
      src/patient/pages/qol/index.ts

14
project.private.config.json

@ -23,6 +23,13 @@ @@ -23,6 +23,13 @@
"miniprogram": {
"list": [
{
"name": "患者-qol",
"pathName": "patient/pages/qol/index",
"query": "pushId=81",
"scene": null,
"launchMode": "default"
},
{
"name": "医生-患者量表",
"pathName": "pages/d_qolDetail/index",
"query": "id=178",
@ -121,13 +128,6 @@ @@ -121,13 +128,6 @@
"scene": null
},
{
"name": "患者-qol",
"pathName": "patient/pages/qol/index",
"query": "",
"launchMode": "default",
"scene": null
},
{
"name": "患者-录入个人信息",
"pathName": "patient/pages/enterInfo/index",
"query": "",

3
src/pages/home/index.wxml

@ -146,8 +146,7 @@ @@ -146,8 +146,7 @@
<view class="stat" bind:tap="handlePatient">
<view class="s-header">
<view class="title">
统计数据截止到昨天
<text class="sub">每天00:05更新</text>
患者数据看板
</view>
</view>
<view class="s-container">

13
src/patient/pages/liveDetail/index.ts

@ -38,12 +38,15 @@ Page({ @@ -38,12 +38,15 @@ Page({
answer: false,
isAnswer: false,
pushId: '',
},
videoContext: {} as WechatMiniprogram.VideoContext,
onLoad(options) {
this.setData({
id: options.id,
answer: options.answer === '1',
pushId: options.pushId,
})
if (options.jump == '1') {
this.setData({
@ -101,6 +104,16 @@ Page({ @@ -101,6 +104,16 @@ Page({
app.getZdUserInfo(this, true, () => {
this.getPosterParams()
})
if (this.data.pushId) {
wx.ajax({
method: 'POST',
url: '?r=xd/push-click/update-click-status',
data: {
pushId: this.data.pushId,
},
showMsg: false,
})
}
})
},
async getPopup() {

16
src/patient/pages/qol/index.ts

@ -2,8 +2,20 @@ const app = getApp<IAppOption>() @@ -2,8 +2,20 @@ const app = getApp<IAppOption>()
Page({
data: {},
onLoad() {
app.waitLogin({ type: [1] }).then(() => {})
onLoad(options) {
app.waitLogin({ type: [1] }).then(() => {
const pushId = options.pushId
if (pushId) {
wx.ajax({
method: 'POST',
url: '?r=xd/push-click/update-click-status',
data: {
pushId,
},
showMsg: false,
})
}
})
},
handleAdd() {
wx.navigateTo({

Loading…
Cancel
Save