|
|
@@ -298,8 +298,7 @@ export default {
|
|
|
},
|
|
|
|
|
|
onLoad() {
|
|
|
- const app = getApp()
|
|
|
- this.currentChildId = app.globalData.currentChildId || null
|
|
|
+ this.currentChildId = uni.getStorageSync('currentChildId') || null
|
|
|
this.loadStats()
|
|
|
},
|
|
|
|
|
|
@@ -317,8 +316,7 @@ export default {
|
|
|
|
|
|
methods: {
|
|
|
loadStats() {
|
|
|
- const app = getApp()
|
|
|
- const childId = app.globalData.currentChildId
|
|
|
+ const childId = uni.getStorageSync('currentChildId')
|
|
|
if (!childId) return
|
|
|
uni.request({
|
|
|
url: config.API_BASE_URL + '/api/mind/checkin/stats',
|
|
|
@@ -671,8 +669,7 @@ export default {
|
|
|
if (!this.canSubmit || this.submitting) return
|
|
|
this.submitting = true
|
|
|
|
|
|
- const app = getApp()
|
|
|
- const childId = app.globalData.currentChildId
|
|
|
+ const childId = uni.getStorageSync('currentChildId')
|
|
|
|
|
|
const doSubmit = (mediaUrl) => {
|
|
|
uni.request({
|