|
@@ -17,7 +17,7 @@ import {
|
|
|
showSuccessToast,
|
|
|
showToast
|
|
|
} from 'vant'
|
|
|
-import { computed, defineComponent, nextTick, onMounted, reactive } from 'vue'
|
|
|
+import { computed, defineComponent, nextTick, onMounted, reactive, Teleport } from 'vue'
|
|
|
import styles from './information.module.less'
|
|
|
import iconSaveImage from '../images/icon-save-image.png'
|
|
|
import iconWechat from '../images/icon-wechat.png'
|
|
@@ -32,6 +32,7 @@ import isSameOrAfter from 'dayjs/plugin/isSameOrAfter'
|
|
|
dayjs.extend(isSameOrBefore, isSameOrAfter)
|
|
|
import { promisefiyPostMessage, postMessage } from '@/helpers/native-message'
|
|
|
import html2canvas from 'html2canvas'
|
|
|
+import OActionSheet from '@/components/o-action-sheet'
|
|
|
|
|
|
export default defineComponent({
|
|
|
name: 'detail-information',
|
|
@@ -53,7 +54,7 @@ export default defineComponent({
|
|
|
actionText: '上学期',
|
|
|
actionType: 'up',
|
|
|
actionTerm: [
|
|
|
- { name: '上学期', color: 'var(--van-primary-color)', value: 'up' },
|
|
|
+ { name: '上学期', selected: true, value: 'up' },
|
|
|
{ name: '下学期', value: 'down' }
|
|
|
],
|
|
|
oPopover: false,
|
|
@@ -66,7 +67,7 @@ export default defineComponent({
|
|
|
loading: false,
|
|
|
finished: false
|
|
|
},
|
|
|
-
|
|
|
+ bottomHeight: 0,
|
|
|
params: {
|
|
|
startTime: dayjs(dayjs().year() + startTime.value).format('YYYY-MM-DD HH:mm:ss'),
|
|
|
endTime: dayjs(dayjs().year() + endTime.value)
|
|
@@ -82,11 +83,10 @@ export default defineComponent({
|
|
|
|
|
|
// 选择学期
|
|
|
const onSelect = (val: any) => {
|
|
|
- console.log(val, '1')
|
|
|
state.actionTerm.forEach((item: any) => {
|
|
|
- item.color = null
|
|
|
+ item.selected = false
|
|
|
})
|
|
|
- val.color = 'var(--van-primary-color)'
|
|
|
+ val.selected = true
|
|
|
state.actionText = val.name
|
|
|
state.actionType = val.value
|
|
|
|
|
@@ -254,6 +254,13 @@ export default defineComponent({
|
|
|
state.currentData = [year - 1 + '']
|
|
|
state.actionText = '下学期'
|
|
|
state.actionType = 'up'
|
|
|
+ state.actionTerm.forEach((item: any) => {
|
|
|
+ if (item.value === 'up') {
|
|
|
+ item.selected = true
|
|
|
+ } else {
|
|
|
+ item.selected = false
|
|
|
+ }
|
|
|
+ })
|
|
|
}
|
|
|
|
|
|
await getDetails()
|
|
@@ -278,7 +285,13 @@ export default defineComponent({
|
|
|
</div>
|
|
|
</div>
|
|
|
|
|
|
- <div style="height: calc(100vh - var(--header-height) - 1.17333rem); overflow: hidden; overflow-y: auto;">
|
|
|
+ <div
|
|
|
+ style={{
|
|
|
+ height: `calc(100vh - var(--header-height) - var(--van-tabs-line-height) - 1.17333rem)`,
|
|
|
+ overflow: 'hidden',
|
|
|
+ overflowY: 'auto'
|
|
|
+ }}
|
|
|
+ >
|
|
|
<Grid border={false} class={styles.gridContainer}>
|
|
|
<GridItem>
|
|
|
<p class={[styles.title, styles.red]}>
|
|
@@ -348,7 +361,14 @@ export default defineComponent({
|
|
|
)}
|
|
|
{/* */}
|
|
|
{state.orchestraInfo.canSignUp && (
|
|
|
- <OSticky position="bottom">
|
|
|
+ // <Teleport to={'body'}>
|
|
|
+ <OSticky
|
|
|
+ position="bottom"
|
|
|
+ class={styles.informationBottom}
|
|
|
+ onGetHeight={(height: any) => {
|
|
|
+ state.bottomHeight = height
|
|
|
+ }}
|
|
|
+ >
|
|
|
<div class={'btnGroup'}>
|
|
|
<Button
|
|
|
round
|
|
@@ -368,13 +388,13 @@ export default defineComponent({
|
|
|
</Button>
|
|
|
</div>
|
|
|
</OSticky>
|
|
|
+ // </Teleport>
|
|
|
)}
|
|
|
</div>
|
|
|
|
|
|
- <ActionSheet
|
|
|
+ <OActionSheet
|
|
|
v-model:show={state.oPopover}
|
|
|
actions={state.actionTerm}
|
|
|
- cancelText="取消"
|
|
|
onSelect={onSelect}
|
|
|
/>
|
|
|
|