Commit 537f57bd authored by wangxuelai's avatar wangxuelai

'海报scene模式修改完结,需要去做埋点的兼容'

parent 268c6669
...@@ -34,4 +34,4 @@ ...@@ -34,4 +34,4 @@
7.分享打卡详情海报长图 7.分享打卡详情海报长图
page: src/pages/clockdetail/newindex page: src/pages/clockdetail/newindex
修改前 `t=${tid}&c=${clockId}&w=${app.globalData.currentSchoolStudentId}`, 修改前 `t=${tid}&c=${clockId}&w=${app.globalData.currentSchoolStudentId}`,
修改后 `${clockId}_${tid}_${app.globalData.currentSchoolStudentId}`, 修改后 `${clockId}_${tid}_${app.globalData.**currentSchoolStudentId**}`,
\ No newline at end of file \ No newline at end of file
...@@ -45,7 +45,8 @@ import { ...@@ -45,7 +45,8 @@ import {
videoPoster, videoPoster,
scenQueryGet, scenQueryGet,
getDailyMateria, getDailyMateria,
dateDetail dateDetail,
newScenQueryGet
} from '../../../utilities/index.js'; } from '../../../utilities/index.js';
import initCalendar, { import initCalendar, {
setTodoLabels, setTodoLabels,
...@@ -192,19 +193,29 @@ Page({ ...@@ -192,19 +193,29 @@ Page({
onLoad: function (options) { // Do some initialize when page load. onLoad: function (options) { // Do some initialize when page load.
// this.getWeeksDay(new Date()); // this.getWeeksDay(new Date());
if (options.scene) { if (options.scene) {
let sceneQuery = scenQueryGet(options.scene); let sceneQuery = newScenQueryGet(options.scene);
const { if (sceneQuery.type == 1) {
i, const {
t, i,
d t,
} = sceneQuery; d
this.setData({ } = sceneQuery.queryObj;
id: i, this.setData({
tid: t, id: i,
d: d || '', tid: t,
pagefrom: '', d: d || '',
pageScene: options.scene || '' pagefrom: '',
}) pageScene: options.scene || ''
})
} else if (sceneQuery.type == 2) {
this.setData({
id: sceneQuery.queryObj[0],
tid: sceneQuery.queryObj[1],
d: sceneQuery.queryObj[2],
pagefrom: '',
pageScene: options.scene || ''
})
}
} else { } else {
const { const {
id, id,
......
...@@ -53,6 +53,7 @@ import { ...@@ -53,6 +53,7 @@ import {
LocalStorage, LocalStorage,
audioorigin, audioorigin,
scenQueryGet, scenQueryGet,
newScenQueryGet,
} from '../../../utilities/index.js'; } from '../../../utilities/index.js';
import regexp from '../../../constants/regexp.js'; import regexp from '../../../constants/regexp.js';
import { import {
...@@ -266,23 +267,41 @@ Page({ ...@@ -266,23 +267,41 @@ Page({
onLoad: function(options) { // Do some initialize when page load. onLoad: function(options) { // Do some initialize when page load.
let that = this; let that = this;
if (options.scene) { if (options.scene) {
let sceneQuery = scenQueryGet(options.scene); console.log(options.scene, 'options.scene')
const {s,i, ctd, p} = sceneQuery; let sceneQuery = newScenQueryGet(options.scene);
if (p == 4) { if (sceneQuery.type == 1) {
const {s,i, ctd, p} = sceneQuery.queryObj;
if (p == 4) {
}
posterLog({
poster_type: 7,
type: 2,
consumer_id: ctd,
clock_circle_id: i,
})
this.setData({
sid: s || 0,
id: i,
id2: i,
consumerId: ctd,
advertisementshow: true
})
} else if (sceneQuery.type == 2) {
posterLog({
poster_type: 7,
type: 2,
consumer_id: sceneQuery.queryObj[2],
clock_circle_id: sceneQuery.queryObj[1],
})
console.log(sceneQuery.queryObj, 'sceneQuery.queryObj');
this.setData({
sid: sceneQuery.queryObj[3],
id: sceneQuery.queryObj[1],
id2: sceneQuery.queryObj[1],
consumerId: sceneQuery.queryObj[2],
advertisementshow: true
})
} }
posterLog({
poster_type: 7,
type: 2,
consumer_id: ctd,
clock_circle_id: i,
})
this.setData({
sid: s || 0,
id: i,
id2: i,
consumerId: ctd,
advertisementshow: true
})
} else { } else {
const {sid, id, consumerId} = options; const {sid, id, consumerId} = options;
this.setData({ this.setData({
...@@ -1645,7 +1664,8 @@ Page({ ...@@ -1645,7 +1664,8 @@ Page({
let qrcode = ''; let qrcode = '';
generateCustomerQrcode({ generateCustomerQrcode({
scene: `4_${this.data.id}_${this.data.consumerId}_${app.globalData.currentSchoolStudentId}`, // `i=${this.data.id}&ctd=${this.data.consumerId}&p=4&s=${this.data.sid}&w=${app.globalData.currentSchoolStudentId}`,
scene: `4_${this.data.id}_${this.data.consumerId}_${this.data.sid}_${app.globalData.currentSchoolStudentId}`,
page: `src/pages/growthrecord/index` page: `src/pages/growthrecord/index`
}).then((res) => { }).then((res) => {
const {code, data} = res; const {code, data} = res;
......
...@@ -255,7 +255,7 @@ Page({ ...@@ -255,7 +255,7 @@ Page({
title: '结课证书生成中...' title: '结课证书生成中...'
}) })
generateCustomerQrcode({ generateCustomerQrcode({
scene: `${certificateInfo.subject.class_id}_${certificateInfo.subject.id}_${app.globalData.currentSchoolStudentId}`, scene: `${certificateInfo.subject.class_id}_${certificateInfo.subject.id}__${app.globalData.currentSchoolStudentId}`,
// scene: `i=${certificateInfo.subject.class_id}&t=${certificateInfo.subject.id}&w=${app.globalData.currentSchoolStudentId}`, // scene: `i=${certificateInfo.subject.class_id}&t=${certificateInfo.subject.id}&w=${app.globalData.currentSchoolStudentId}`,
page: `src/pages/calendarthemeindex/index` page: `src/pages/calendarthemeindex/index`
}).then((res) => { }).then((res) => {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment