diff --git a/components/s-video/res-s-video.vue b/components/s-video/res-s-video.vue index c468b78..d22ccd0 100644 --- a/components/s-video/res-s-video.vue +++ b/components/s-video/res-s-video.vue @@ -7,7 +7,10 @@ - {{ask}} + + + {{ask}} + @@ -22,15 +25,23 @@

开始

--> - + - + + + + + + + 重新选择逃生路线 + + @@ -334,18 +345,14 @@ top: 50%; left: 50%; transform: translate(-50%, -50%); - /* background-color: #fff; */ color: #fff; - padding: 20px; z-index: 9999; } .popup-layer .anitem1 { position: relative; - /* margin: 80rpx; */ width: 650rpx; height: 200rpx; - /* text-align: center; */ } .popup-layer .anitem1 .animg1 { @@ -408,6 +415,42 @@ height: 50%; } + .failed-tip { + position: absolute; + top: 50%; + left: 50%; + transform: translate(-50%, -50%); + width: 560rpx; + height: 400rpx; + } + + .failed-tip image { + width: 100%; + height: 100%; + } + + .fullbox { + width: 100%; + height: 100%; + } + + .btnsty { + position: absolute; + left: 20%; + bottom: 10%; + width: 60%; + height: 90rpx; + line-height: 90rpx; + text-align: center; + color: #fff; + font-size: 30rpx; + border-radius: 50rpx; + background: rgba(255, 255, 255, 0.2); + border: 1px solid #1367fe; + color: #fff; + white-space: nowrap; + } + /* 设置关闭按钮 */ .popup-layer-close { position: absolute; diff --git a/components/s-video/s-video.vue b/components/s-video/s-video.vue index 2c9c7fc..f1efc13 100644 --- a/components/s-video/s-video.vue +++ b/components/s-video/s-video.vue @@ -4,7 +4,9 @@ - + @@ -14,7 +16,8 @@ {{ask}} - + {{item.channel}} @@ -32,14 +35,13 @@ --> - - - - - 重新选择逃生路线 - + + - + + 重新选择逃生路线 + + @@ -76,7 +78,7 @@ resCheck: false, showLayer: false, isResVideo: false, - failUrl: uni.$http.baseUrl +"/profile//images/fail.gif", + failUrl: uni.$http.baseUrl + "/profile//images/fail.gif", innerAudioContext: null, }; }, @@ -106,7 +108,7 @@ this.videoHeight = res.screenHeight; } }); - + this.innerAudioContext = uni.createInnerAudioContext(); this.innerAudioContext.autoplay = true; this.innerAudioContext.src = "/static/videos/supermario.mp3"; @@ -183,7 +185,7 @@ this.innerAudioContext.stop(); }, onMetadataLoaded(event) { - if(this.isResVideo) { + if (this.isResVideo) { this.isResVideo = false; const duration = event.detail.duration; this.videoContext.seek(duration); @@ -196,7 +198,7 @@ this.$api.addQuestionFre({ roleId: this.jsonId, sceneId: this.sceneId, - userId : this.userId + userId: this.userId }) .then(res => { this.questionFreId = res.data; @@ -207,7 +209,7 @@ // 先提交所选答案 if (null != obj) { // 判断答题是否正确 - if(this.correct.toUpperCase() == obj.channel.slice(0, 1).toUpperCase()) { + if (this.correct.toUpperCase() == obj.channel.slice(0, 1).toUpperCase()) { // 控制选中答案单条显示对错 this.$set(obj, 'choose', 'true'); isCorrect = 1 @@ -247,10 +249,10 @@ that.isError = false; that.isOk = false; that.hasNodeId(outId); - if(!that.videoObj.videoUrl.includes("http")) { + if (!that.videoObj.videoUrl.includes("http")) { that.videoObj.videoUrl = uni.$http.baseUrl + that.videoObj.videoUrl } - + // 用于记录上一个视频 if (null == obj) { that.resVideoUrl = that.videoObj.videoUrl; @@ -328,14 +330,18 @@ height: 100%; background-color: rgba(0, 0, 0, .35); } + .animg { - position:absolute; - top:0;left:0;right:0;bottom:0; - margin:auto; + position: absolute; + top: 0; + left: 0; + right: 0; + bottom: 0; + margin: auto; width: 100px; height: 100px; } - + /* 首先设置背景层 */ .popup-layer-back { position: absolute; @@ -343,7 +349,7 @@ left: 0; width: 100%; height: 100%; - background-color: rgba(0, 0, 0, 0.5); + background-color: rgba(0, 0, 0, 0.8); z-index: 9998; } @@ -353,18 +359,14 @@ top: 50%; left: 50%; transform: translate(-50%, -50%); - /* background-color: #fff; */ color: #fff; - padding: 20px; z-index: 9999; } .popup-layer .anitem1 { position: relative; - /* margin: 80rpx; */ width: 650rpx; height: 200rpx; - /* text-align: center; */ } .popup-layer .anitem1 .animg1 { @@ -421,12 +423,48 @@ position: absolute; top: 50%; left: 50%; - -webkit-transform: translate(-50%, -50%); transform: translate(-50%, -50%); width: 50%; height: 50%; } + .failed-tip { + position: absolute; + top: 50%; + left: 50%; + transform: translate(-50%, -50%); + width: 560rpx; + height: 400rpx; + } + + .failed-tip image { + width: 100%; + height: 100%; + } + + .fullbox { + width: 100%; + height: 100%; + } + + .btnsty { + position: absolute; + left: 20%; + bottom: 10%; + width: 60%; + height: 90rpx; + line-height: 90rpx; + text-align: center; + color: #fff; + font-size: 30rpx; + border-radius: 50rpx; + background: rgba(255, 255, 255, 0.2); + border: 1px solid #1367fe; + color: #fff; + white-space: nowrap; + } + + /* 设置关闭按钮 */ .popup-layer-close { position: absolute; diff --git a/static/images/icon_play2.png b/static/images/icon_play2.png new file mode 100644 index 0000000..55cfa96 Binary files /dev/null and b/static/images/icon_play2.png differ diff --git a/static/images/medal_1.png b/static/images/medal_1.png new file mode 100644 index 0000000..dbf4a0c Binary files /dev/null and b/static/images/medal_1.png differ diff --git a/subpkg/review/review.vue b/subpkg/review/review.vue index e676bc9..8c198c5 100644 --- a/subpkg/review/review.vue +++ b/subpkg/review/review.vue @@ -2,25 +2,33 @@ - 演练回顾 + 演练回顾 - - 您已完成“{{sceneName}}”场景中 “{{roleName}}”〞角色挑战的共计{{total}}道题目,,每道题目和您选择的答案详情如下: - - - - + + 您已完成“{{sceneName}}”场景中 “{{roleName}} + ”〞角色挑战的共计{{total}}道题目,,每道题目和您选择的答案详情如下: + + + + - - - - - - - + + + @@ -28,14 +36,14 @@ export default { data() { return { - "sceneName":"", - "roleName":"", - "total":0, - questionFreId: "", - sceneId: "", - roleId: "", - imgUrl: "", - questionList:[] + "sceneName": "", + "roleName": "", + "total": 0, + questionFreId: "", + sceneId: "", + roleId: "", + imgUrl: "", + questionList: [] } }, onLoad(options) { @@ -50,39 +58,43 @@ async getQuestionList() { const { data: res - } = await uni.$http.post('/small/questionAnswer/listAll',{questionFreId:this.questionFreId}) + } = await uni.$http.post('/small/questionAnswer/listAll', { + questionFreId: this.questionFreId + }) if (!res.success) return uni.$showMsg() - this.questionList = res.data - this.total = res.data.length + this.questionList = res.data + this.total = res.data.length //uni.$showMsg('数据请求成功!') }, - async getRelationInfo() { - const { - data: res - } = await uni.$http.post('/small/questionFre/getRelationInfo',this.questionFreId) - if (!res.success) return uni.$showMsg() - if (res.data != null) { - this.roleName = res.data.sceneRole != null ? res.data.sceneRole.name : "" + async getRelationInfo() { + const { + data: res + } = await uni.$http.post('/small/questionFre/getRelationInfo', this.questionFreId) + if (!res.success) return uni.$showMsg() + if (res.data != null) { + this.roleName = res.data.sceneRole != null ? res.data.sceneRole.name : "" this.sceneName = res.data.sceneManage != null ? res.data.sceneManage.name : "" - this.backgroundImg = res.data.file.length!=0 ? uni.$http.baseUrl +res.data.file[0].uploadPath : "" + this.backgroundImg = res.data.file.length != 0 ? uni.$http.baseUrl + res.data.file[0].uploadPath : + "" } - //uni.$showMsg('数据请求成功!') - }, + //uni.$showMsg('数据请求成功!') + }, async getFiles() { const { data: res - } = await uni.$http.get('/small/scene/manage/queryFiles/'+this.sceneId); + } = await uni.$http.get('/small/scene/manage/queryFiles/' + this.sceneId); this.imgUrl = uni.$http.baseUrl + res.data.filePreview.fileList[0]; //uni.$showMsg('数据请求成功!') }, respractice() { uni.navigateTo({ - url: '/subpkg/respractice/respractice?questionFreId=' + this.questionFreId +'&sceneId=' + this.sceneId +"&roleId=" + this.roleId + url: '/subpkg/respractice/respractice?questionFreId=' + this.questionFreId + '&sceneId=' + this + .sceneId + "&roleId=" + this.roleId }) }, - back(){ + back() { uni.navigateBack({ - delta:1,//返回层数,2则上上页 + delta: 1, //返回层数,2则上上页 }) }, } @@ -91,8 +103,9 @@ + \ No newline at end of file