|
@@ -434,6 +434,10 @@ Page({
|
|
"speed": _data.fluency,
|
|
"speed": _data.fluency,
|
|
"intonation": _data.tone,
|
|
"intonation": _data.tone,
|
|
"score": _data.myOverall
|
|
"score": _data.myOverall
|
|
|
|
+ }).finally(() => {
|
|
|
|
+ this.setData({
|
|
|
|
+ uploadState: false
|
|
|
|
+ })
|
|
})
|
|
})
|
|
console.log({
|
|
console.log({
|
|
"userReadId": uploadRes.id,
|
|
"userReadId": uploadRes.id,
|
|
@@ -456,11 +460,7 @@ Page({
|
|
url: `/pages/pkResult/index?id=${result.id}`
|
|
url: `/pages/pkResult/index?id=${result.id}`
|
|
})
|
|
})
|
|
},
|
|
},
|
|
- complete: () => {
|
|
+
|
|
- this.setData({
|
|
|
|
- uploadState: false
|
|
|
|
- })
|
|
|
|
- }
|
|
|
|
});
|
|
});
|
|
uploadTask.onProgressUpdate((res) => {
|
|
uploadTask.onProgressUpdate((res) => {
|
|
this.setData({
|
|
this.setData({
|
|
@@ -592,6 +592,26 @@ Page({
|
|
["silderData.currentTime"]: '00:00'
|
|
["silderData.currentTime"]: '00:00'
|
|
})
|
|
})
|
|
},
|
|
},
|
|
|
|
+
|
|
|
|
+ beforeleave() {
|
|
|
|
+ if (this.data.uploadState) {
|
|
|
|
+ this.setData({
|
|
|
|
+ uploadState: false
|
|
|
|
+ })
|
|
|
|
+ wx.showModal({
|
|
|
|
+ title: '上传作品中',
|
|
|
|
+ content: '小朋友请耐心等待哦~',
|
|
|
|
+ showCancel: false,
|
|
|
|
+ success: (res) => {
|
|
|
|
+ if (res.confirm) {
|
|
|
|
+ this.setData({
|
|
|
|
+ uploadState: true
|
|
|
|
+ })
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ })
|
|
|
|
+ }
|
|
|
|
+ },
|
|
|
|
|
|
getHeight() {
|
|
getHeight() {
|
|
var query = wx.createSelectorQuery();
|
|
var query = wx.createSelectorQuery();
|
|
@@ -622,7 +642,6 @@ Page({
|
|
wsEngine.reset()
|
|
wsEngine.reset()
|
|
this.resetReading()
|
|
this.resetReading()
|
|
this.storeBindings.destroyStoreBindings()
|
|
this.storeBindings.destroyStoreBindings()
|
|
-
|
|
|
|
},
|
|
},
|
|
backReading() {
|
|
backReading() {
|
|
wx.navigateBack({
|
|
wx.navigateBack({
|