|
@@ -35,6 +35,7 @@ import dayjs from 'dayjs'
|
|
|
import { listenerMessage, postMessage } from '@/helpers/native-message'
|
|
|
import { browser, getHttpOrigin } from '@/helpers/utils'
|
|
|
import { useRouter } from 'vue-router'
|
|
|
+import { state } from '@/state'
|
|
|
|
|
|
// 注册必须的组件
|
|
|
echarts.use([
|
|
@@ -255,7 +256,25 @@ export default defineComponent({
|
|
|
myChart = echarts.init(
|
|
|
document.getElementById('eChart') as HTMLDivElement
|
|
|
)
|
|
|
- getHeight()
|
|
|
+ // 为了处理苹果审核版本
|
|
|
+ if (browser().ios) {
|
|
|
+ request
|
|
|
+ .post('/api-teacher/open/appVersion', {
|
|
|
+ data: {
|
|
|
+ platform: 'ios-teacher',
|
|
|
+ version: state.version
|
|
|
+ }
|
|
|
+ })
|
|
|
+ .then(res => {
|
|
|
+ const checked = res.data.checked ? true : false
|
|
|
+ if (!checked) {
|
|
|
+ getHeight()
|
|
|
+ }
|
|
|
+ })
|
|
|
+ } else {
|
|
|
+ getHeight()
|
|
|
+ }
|
|
|
+
|
|
|
getDetail()
|
|
|
})
|
|
|
|
|
@@ -368,7 +387,9 @@ export default defineComponent({
|
|
|
postMessage({
|
|
|
api: 'openWebView',
|
|
|
content: {
|
|
|
- url: `${getHttpOrigin()}/teacher/#/home-statistics-detail?currentType=${currentType.value}`,
|
|
|
+ url: `${getHttpOrigin()}/teacher/#/home-statistics-detail?currentType=${
|
|
|
+ currentType.value
|
|
|
+ }`,
|
|
|
orientation: 1,
|
|
|
isHideTitle: false
|
|
|
}
|
|
@@ -385,9 +406,6 @@ export default defineComponent({
|
|
|
|
|
|
// 监听页面返回
|
|
|
listenerMessage('webViewOnResume', () => {
|
|
|
- // if (!isNotifyHeight.value) {
|
|
|
- // getHeight()
|
|
|
- // }
|
|
|
getDetail()
|
|
|
})
|
|
|
return () => (
|
|
@@ -408,7 +426,7 @@ export default defineComponent({
|
|
|
<div class={styles.eChartTitle}>
|
|
|
<div class={styles.left}>
|
|
|
{/* {statisticCounts.value.time && ( */}
|
|
|
- <div class={styles.time}>{statisticCounts.value.time}</div>
|
|
|
+ <div class={styles.time}>{statisticCounts.value.time}</div>
|
|
|
{/* )} */}
|
|
|
|
|
|
<div class={styles.twoItem}>
|