index.tsx 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  1. import { defineComponent, PropType } from 'vue'
  2. import styles from './index.module.less'
  3. import { CellGroup, Sticky } from 'vant'
  4. import iconMoney from '../../images/icon-money.png'
  5. import ColResult from '@/components/col-result'
  6. import Echats from '../echats'
  7. import TeacherItem from '../teacher-item'
  8. import BuyItem from '../buy-item'
  9. export default defineComponent({
  10. name: 'list',
  11. props: {
  12. type: {
  13. type: String as PropType<
  14. 'vip' | 'practice' | 'group' | 'live' | 'video' | 'music'
  15. >,
  16. default: 'vip'
  17. }
  18. },
  19. setup(props) {
  20. return () => (
  21. <div class={styles.list}>
  22. <Echats />
  23. <div class={styles.expectedIncome}>
  24. {/* <Sticky> */}
  25. <div class={styles.incomeTitle}>
  26. <div class={styles.title}>
  27. <img src={iconMoney} />
  28. <span>预计总收入</span>
  29. </div>
  30. <div class={styles.price}>
  31. <span>¥ </span>
  32. 4260.00
  33. </div>
  34. </div>
  35. {/* </Sticky> */}
  36. <div class={styles.incomeTip}>实际收入将在课程结束2天后结算</div>
  37. <div class={styles.element}></div>
  38. <CellGroup border={false}>
  39. {['vip', 'practice'].includes(props.type) && <TeacherItem list={[1,2,3,4,5,6,7,7,8,]} />}
  40. {['group', 'live', 'video', 'music'].includes(props.type) && (
  41. <BuyItem list={[1,2,3,4,5,6,7,7,8,]} isSquare={props.type === "music"} />
  42. )}
  43. </CellGroup>
  44. {/* <ColResult type="empty" btnStatus={false} classImgSize="SMALL" tips='暂无数据~' /> */}
  45. </div>
  46. </div>
  47. )
  48. }
  49. })