Merge branch 'develop' of http://25.13.9.101:9000/K17_AITS/tra-app into develop
This commit is contained in:
@@ -11,4 +11,5 @@ VITE_APP_BASE_H5_API_Url = 'http://25.18.122.91:9786'
|
||||
# VITE_APP_BASE_H5_API_Url_TRAPRACTICE = 'http://25.64.32.156:9603'
|
||||
# VITE_APP_BASE_H5_API_Url_TRAAPP = 'http://25.64.32.154:9601'
|
||||
# VITE_APP_BASE_H5_API_Url_TRAAPP = 'http://25.64.32.158:9601'
|
||||
# VITE_APP_BASE_H5_API_Url_TRASTUDY = 'http://25.64.32.154:9602'
|
||||
|
||||
|
||||
@@ -22,6 +22,7 @@
|
||||
import { useStorageStore } from "@/store/storage.js"
|
||||
import { get_base_url } from '@/api/request.js'
|
||||
import imagePreviewVue from './image-preview.vue'
|
||||
import { getToken } from '@/common/common.js'
|
||||
export default {
|
||||
name:"video-preview",
|
||||
components:{imagePreviewVue},
|
||||
@@ -74,11 +75,11 @@
|
||||
handler(newval, oldval) {
|
||||
if(this.fileType === 'image'){
|
||||
if (newval.indexOf('/') === 0) {
|
||||
this.fileUrlShow = this.base_url + newval;
|
||||
this.fileUrlShow = this.base_url + newval + '?tk=' + getToken();
|
||||
return;
|
||||
}
|
||||
if (newval.indexOf('http') === 0) {
|
||||
this.fileUrlShow = newval;
|
||||
this.fileUrlShow = newval + '?tk=' + getToken();
|
||||
return;
|
||||
}
|
||||
if (newval && this.watching) {
|
||||
@@ -87,7 +88,7 @@
|
||||
}
|
||||
if(this.fileType === 'video'){
|
||||
if(newval.indexOf('http') === 0){
|
||||
this.fileUrlShow = newval
|
||||
this.fileUrlShow = newval + '?tk=' + getToken()
|
||||
}else{
|
||||
if (newval && this.watching) {
|
||||
this.getPreviewUrlBlob(newval);
|
||||
@@ -102,9 +103,9 @@
|
||||
src: {
|
||||
handler(newval, oldval) {
|
||||
if(newval.indexOf('http') === 0){
|
||||
this.fileUrlShow = newval
|
||||
this.fileUrlShow = newval + '?tk=' + getToken()
|
||||
}else{
|
||||
this.fileUrlShow = this.base_url + newval
|
||||
this.fileUrlShow = this.base_url + newval + '?tk=' + getToken()
|
||||
}
|
||||
},
|
||||
immediate: true,
|
||||
@@ -132,7 +133,7 @@
|
||||
return;
|
||||
}
|
||||
previewCacheThumbImage(id, this.width, this.height).then((res) => {
|
||||
this.fileUrlShow = res;
|
||||
this.fileUrlShow = res + '?tk=' + getToken();
|
||||
this.storageStore.setStorage('image', `/${id}/${this.width}/${this.height}`, res);
|
||||
});
|
||||
} else {
|
||||
@@ -183,7 +184,7 @@
|
||||
if (this.fileId) {
|
||||
let _newDate = new Date().getTime()
|
||||
if(this.fileId.indexOf('http') === 0){
|
||||
this.fileUrlShow = this.fileId + '?t=' + _newDate
|
||||
this.fileUrlShow = this.fileId + '?tk=' + getToken() + '&t=' + _newDate
|
||||
}else{
|
||||
this.getPreviewUrlBlob(this.fileId);
|
||||
}
|
||||
@@ -213,7 +214,7 @@
|
||||
return
|
||||
}
|
||||
let _newDate = new Date().getTime()
|
||||
this.fileUrlShow = getPreviewFileUrl(this.fileId)+'?t=' + _newDate
|
||||
this.fileUrlShow = getPreviewFileUrl(this.fileId) + '?tk=' + getToken() + '&t=' + _newDate
|
||||
// downloadFile(id).then(res=>{
|
||||
// this.fileUrlShow = res.tempFilePath
|
||||
// this.storageStore.setStorage('video', id, this.fileUrlShow)
|
||||
@@ -222,7 +223,7 @@
|
||||
getPreviewFileUrlNow(id){
|
||||
let _newDate = new Date().getTime()
|
||||
if(id.indexOf('http') === 0){
|
||||
this.fileUrlShow = id + '?t=' + _newDate
|
||||
this.fileUrlShow = id + '?tk=' + getToken() + '&t=' + _newDate
|
||||
return
|
||||
}
|
||||
if (id && this.watching) {
|
||||
|
||||
@@ -31,6 +31,7 @@
|
||||
import { useStorageStore } from "@/store/storage.js"
|
||||
import { get_base_url } from '@/api/request.js'
|
||||
import imagePreviewVue from './image-preview.vue'
|
||||
import { getToken } from '@/common/common.js'
|
||||
export default {
|
||||
name:"video-preview",
|
||||
components:{ imagePreviewVue },
|
||||
@@ -75,7 +76,7 @@
|
||||
fileId: {
|
||||
handler(newval, oldval) {
|
||||
if(newval.indexOf('http') === 0){
|
||||
this.fileUrlShow = newval
|
||||
this.fileUrlShow = newval + '?tk=' + getToken()
|
||||
}else{
|
||||
if (newval && this.watching) {
|
||||
this.getPreviewUrlBlob(newval);
|
||||
@@ -129,7 +130,7 @@
|
||||
return
|
||||
}
|
||||
let _newDate = new Date().getTime()
|
||||
this.fileUrlShow = getPreviewFileUrl(this.fileId)+'?t=' + _newDate
|
||||
this.fileUrlShow = getPreviewFileUrl(this.fileId) + '?tk=' + getToken() + '&t=' + _newDate
|
||||
// downloadFile(id).then(res=>{
|
||||
// this.fileUrlShow = res.tempFilePath
|
||||
// this.storageStore.setStorage('video', id, this.fileUrlShow)
|
||||
@@ -150,7 +151,7 @@
|
||||
if (this.fileId) {
|
||||
let _newDate = new Date().getTime()
|
||||
if(this.fileId.indexOf('http') === 0){
|
||||
this.fileUrlShow = this.fileId + '?t=' + _newDate
|
||||
this.fileUrlShow = this.fileId + '?tk=' + getToken() + '&t=' + _newDate
|
||||
}else{
|
||||
this.getPreviewUrlBlob(this.fileId);
|
||||
}
|
||||
|
||||
@@ -6,7 +6,11 @@
|
||||
<view class="back-icon" @click="common.navigateBack()"></view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="analytics-box">
|
||||
<!-- <view class="analytics-box loading-box-cont" v-if="loading">
|
||||
<CommonLoading color="#06f" class="loading-box" />
|
||||
</view> -->
|
||||
<view :class="['analytics-box', loading?'loading-box-cont':'']" >
|
||||
<CommonLoading color="#06f" class="loading-box" v-if="loading"/>
|
||||
<view class="tabs-box">
|
||||
<uv-tabs :list="tabList" @click="changeTab" :scrollable="true" active-style="font-weight:bold; color:#000;"
|
||||
:current="currentTab" class="font_pf my_tabs"
|
||||
@@ -52,7 +56,7 @@
|
||||
完成任务数
|
||||
</view>
|
||||
<view class="analytics-item-value">
|
||||
<text class="analytics-item-value-v">{{statisticsObj.completeTaskCnt }}</text>
|
||||
<text class="analytics-item-value-v">{{statisticsObj.completeTaskCnt }}</text>
|
||||
<text class="analytics-item-value-unit"></text>
|
||||
</view>
|
||||
</view>
|
||||
@@ -61,7 +65,7 @@
|
||||
完成考试数
|
||||
</view>
|
||||
<view class="analytics-item-value">
|
||||
<text class="analytics-item-value-v">{{statisticsObj.completedExamCnt }}</text>
|
||||
<text class="analytics-item-value-v">{{statisticsObj.completedExamCnt }}</text>
|
||||
<text class="analytics-item-value-unit"></text>
|
||||
</view>
|
||||
</view>
|
||||
@@ -70,7 +74,7 @@
|
||||
考试及格率
|
||||
</view>
|
||||
<view class="analytics-item-value">
|
||||
<text class="analytics-item-value-v">{{statisticsObj.passExamRate }}</text>
|
||||
<text class="analytics-item-value-v">{{statisticsObj.passExamRate }}</text>
|
||||
<text class="analytics-item-value-unit">%</text>
|
||||
</view>
|
||||
</view>
|
||||
@@ -104,7 +108,7 @@
|
||||
</view>
|
||||
</view>
|
||||
<view class="evaluation-box dens" v-if="loading">
|
||||
<CommonLoading color="#06f" class="loading-box"/>
|
||||
<CommonLoading color="#06f" class="loading-box" />
|
||||
</view>
|
||||
<view class="evaluation-box dens" v-if="!loading">
|
||||
<view class="dens-item" v-for="(item, index) in dimesionList">
|
||||
@@ -113,7 +117,7 @@
|
||||
</view>
|
||||
</view>
|
||||
<view class="evaluation-box study" v-if="loading">
|
||||
<CommonLoading color="#06f" class="loading-box"/>
|
||||
<CommonLoading color="#06f" class="loading-box" />
|
||||
</view>
|
||||
<view class="evaluation-box study" v-if="!loading">
|
||||
<view class="study-item" v-for="(item, index) in studyList">
|
||||
@@ -122,7 +126,7 @@
|
||||
</view>
|
||||
</view>
|
||||
<view class="evaluation-box study1" v-if="loading">
|
||||
<CommonLoading color="#06f" class="loading-box"/>
|
||||
<CommonLoading color="#06f" class="loading-box" />
|
||||
</view>
|
||||
<view class="evaluation-box study1" v-if="!loading">
|
||||
<view class="study1-item">
|
||||
@@ -130,7 +134,7 @@
|
||||
</view>
|
||||
</view>
|
||||
<view class="evaluation-box course" v-if="loading">
|
||||
<CommonLoading color="#06f" class="loading-box"/>
|
||||
<CommonLoading color="#06f" class="loading-box" />
|
||||
</view>
|
||||
<view class="evaluation-box course" v-if="!loading">
|
||||
<CourseItem v-for="item in courseList" :itemInfo="item" @clickItem="toCourseDetail(item)" />
|
||||
@@ -186,15 +190,15 @@
|
||||
})
|
||||
const calendarRef = ref()
|
||||
const statisticsObj = ref({
|
||||
crsStdyTmLen: 0,
|
||||
completeTaskCnt: 0,
|
||||
completedExamCnt: 0,
|
||||
passExamRate: 0,
|
||||
partnerCnt: 0,
|
||||
askCnt: 0,
|
||||
completeCrsCnt: 0,
|
||||
crsCompleteRate: 0,
|
||||
partnerRate: 0
|
||||
crsStdyTmLen: 0,
|
||||
completeTaskCnt: 0,
|
||||
completedExamCnt: 0,
|
||||
passExamRate: 0,
|
||||
partnerCnt: 0,
|
||||
askCnt: 0,
|
||||
completeCrsCnt: 0,
|
||||
crsCompleteRate: 0,
|
||||
partnerRate: 0
|
||||
})
|
||||
const dimesionList = ref([])
|
||||
const studyList = ref([])
|
||||
@@ -225,17 +229,20 @@
|
||||
loading.value = true
|
||||
try {
|
||||
let _res1 = await queryStudyStatistics(params)
|
||||
statisticsObj.value = {..._res1.body}
|
||||
statisticsObj.value = {
|
||||
..._res1.body
|
||||
}
|
||||
let _res2 = await queryDimesionInfo(params)
|
||||
dimesionList.value = [..._res2.body]
|
||||
let _res3 = await queryHabitInfo(params)
|
||||
studyList.value = [..._res3.body]
|
||||
let _res4 = await querySuggestInfo(params)
|
||||
if(_res4.body && _res4.body.length > 0){
|
||||
suggestObj.value = {..._res4.body[0]}
|
||||
if (_res4.body && _res4.body.length > 0) {
|
||||
suggestObj.value = {
|
||||
..._res4.body[0]
|
||||
}
|
||||
}
|
||||
} catch {
|
||||
} finally{
|
||||
} catch {} finally {
|
||||
loading.value = false
|
||||
}
|
||||
}
|
||||
@@ -246,9 +253,9 @@
|
||||
const changeTab = (info) => {
|
||||
activeTabVal.value = info.value
|
||||
if (info.value === '04') {
|
||||
dateinputRef.value&&dateinputRef.value?.clear()
|
||||
dateinputRef.value && dateinputRef.value?.clear()
|
||||
daterange.value = ['', '']
|
||||
}else{
|
||||
} else {
|
||||
getInfoNow({
|
||||
dateType: activeTabVal.value
|
||||
})
|
||||
@@ -300,7 +307,7 @@
|
||||
background-size: 100% auto;
|
||||
background-position: top center;
|
||||
background-attachment: local;
|
||||
|
||||
|
||||
|
||||
.top-box {
|
||||
height: 280rpx;
|
||||
@@ -363,6 +370,25 @@
|
||||
position: relative;
|
||||
margin-bottom: 24rpx;
|
||||
backdrop-filter: blur(10rpx);
|
||||
overflow: hidden;
|
||||
z-index: 1;
|
||||
&.loading-box-cont::before{
|
||||
content: '';
|
||||
display: block;
|
||||
position: absolute;
|
||||
width: 100% ;
|
||||
height: 100%;
|
||||
z-index: 2;
|
||||
background: #ffffffee;
|
||||
backdrop-filter: blur(50rpx);
|
||||
}
|
||||
.loading-box {
|
||||
position: absolute;
|
||||
z-index: 3;
|
||||
top: 120rpx;
|
||||
left: 50%;
|
||||
transform: translateX(-50%);
|
||||
}
|
||||
|
||||
.calendar-box {
|
||||
position: absolute;
|
||||
@@ -385,6 +411,7 @@
|
||||
padding-bottom: 20rpx;
|
||||
width: 100%;
|
||||
overflow: hidden;
|
||||
position: relative;
|
||||
|
||||
.analytics-item {
|
||||
padding-bottom: 12rpx;
|
||||
@@ -405,6 +432,7 @@
|
||||
&-value {
|
||||
font-size: 54rpx;
|
||||
font-weight: 600;
|
||||
|
||||
&-v {
|
||||
font-family: DINAlternate, DINAlternate;
|
||||
}
|
||||
@@ -428,13 +456,15 @@
|
||||
margin-bottom: 24rpx;
|
||||
position: relative;
|
||||
min-height: 200rpx;
|
||||
.loading-box{
|
||||
|
||||
.loading-box {
|
||||
position: absolute;
|
||||
top: 120rpx;
|
||||
left: 50%;
|
||||
transform: translateX(-50%);
|
||||
}
|
||||
&::before{
|
||||
|
||||
&::before {
|
||||
content: '';
|
||||
display: block;
|
||||
position: absolute;
|
||||
@@ -445,26 +475,27 @@
|
||||
top: -12rpx;
|
||||
background-size: cover;
|
||||
}
|
||||
|
||||
&.dens {
|
||||
&::before{
|
||||
&::before {
|
||||
background-image: url(@/static/images/analytics/weidu-1.png);
|
||||
}
|
||||
}
|
||||
|
||||
&.study {
|
||||
&::before{
|
||||
&::before {
|
||||
background-image: url(@/static/images/analytics/study1-1.png)
|
||||
}
|
||||
}
|
||||
|
||||
&.study1 {
|
||||
&::before{
|
||||
&::before {
|
||||
background-image: url(@/static/images/analytics/study-1.png);
|
||||
}
|
||||
}
|
||||
|
||||
&.course {
|
||||
&::before{
|
||||
&::before {
|
||||
background-image: url(@/static/images/analytics/course-1.png);
|
||||
}
|
||||
}
|
||||
@@ -524,11 +555,13 @@
|
||||
background-repeat: no-repeat;
|
||||
background-size: 100% 100%;
|
||||
}
|
||||
&.study2-tip{
|
||||
|
||||
&.study2-tip {
|
||||
&::before {
|
||||
background-image: url(@/static/images/analytics/den-tips2.png);
|
||||
}
|
||||
}
|
||||
|
||||
&.bg-tm {
|
||||
padding-left: 54rpx;
|
||||
background-image: url(@/static/images/analytics/time-icon.png);
|
||||
|
||||
@@ -41,7 +41,7 @@ export default {
|
||||
this.fileApiSrc = params.fileApiSrc
|
||||
}
|
||||
const userInfo = getUserInfo();
|
||||
this.userParams = '/' + (userInfo?.loginName??'')
|
||||
this.userParams = '/' + (userInfo?.loginName??'') + '?tk=' + getToken()
|
||||
},
|
||||
onShow() {
|
||||
if (getPhoneEnvBool('AND')) {
|
||||
@@ -84,8 +84,8 @@ export default {
|
||||
const base_url = get_base_url(this.fileApiSrc)
|
||||
let _id = data?.fileId
|
||||
let fileUrl = base_url + this.fileApiSrc + _id + this.userParams
|
||||
this.showUrl = this.viewerUrl + '?url=' + fileUrl
|
||||
console.log(this.showUrl)
|
||||
this.showUrl = this.viewerUrl + '?url=' + encodeURIComponent(fileUrl)
|
||||
console.log(this.showUrl)
|
||||
this.showView = true
|
||||
}
|
||||
}
|
||||
|
||||
@@ -384,16 +384,16 @@
|
||||
currentTabSec.value = 0
|
||||
activeTabId.value = ''
|
||||
activeTabSecId.value = ''
|
||||
queryTraPartnerCatelogList().then(res => {
|
||||
catelogList.value = res.body || []
|
||||
})
|
||||
getTraTagListApi().then(res => {
|
||||
tagsTree.value = res.body || []
|
||||
})
|
||||
changeTab({
|
||||
name: '全部',
|
||||
value: ''
|
||||
})
|
||||
// queryTraPartnerCatelogList().then(res => {
|
||||
// catelogList.value = res.body || []
|
||||
// })
|
||||
// getTraTagListApi().then(res => {
|
||||
// tagsTree.value = res.body || []
|
||||
// })
|
||||
// changeTab({
|
||||
// name: '全部',
|
||||
// value: ''
|
||||
// })
|
||||
uni.$on('refresh_sparring_list', () => {
|
||||
changeTab({
|
||||
name: activeTab.value || '全部',
|
||||
@@ -415,13 +415,13 @@
|
||||
activeTabId.value = ''
|
||||
activeTabSecId.value = ''
|
||||
// 重新获取标签信息
|
||||
getTraTagListApi().then(res => {
|
||||
tagsTree.value = res.body || []
|
||||
})
|
||||
changeTab({
|
||||
name: '全部',
|
||||
value: ''
|
||||
})
|
||||
// getTraTagListApi().then(res => {
|
||||
// tagsTree.value = res.body || []
|
||||
// })
|
||||
// changeTab({
|
||||
// name: '全部',
|
||||
// value: ''
|
||||
// })
|
||||
})
|
||||
onShow(() => {
|
||||
console.log('onShow')
|
||||
|
||||
Reference in New Issue
Block a user