店播抖音版小程序

index copy.vue 1.6KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071
  1. <template>
  2. <view class="content">
  3. <page-head title="home"></page-head>
  4. <view class="tabbar-container" :style="'padding-top:'+ safeAreaTop+'px'">
  5. 111
  6. <selfEcharts></selfEcharts>
  7. <selfEcharts></selfEcharts>
  8. <button type="primary" @click="goLogin">去登录</button>
  9. <button type="default" @click="classifyFlag=true">分类选择</button>
  10. <button type="default" @click="timeEvent">时间选择</button>
  11. <view class="li" v-for="(item,index) in 80" @click="toCeshi(index)">
  12. 测试{{index+1}}
  13. </view>
  14. </view>
  15. <classify @close='classifyFlag=false' v-if="classifyFlag" @getData='getChoiceData'></classify>
  16. <tabbar selected='homePage'></tabbar>
  17. </view>
  18. </template>
  19. <script>
  20. import tabbar from '@/components/tabbar.vue'
  21. import selfEcharts from "@/components/echarts/self-echarts.vue"
  22. import classify from "@/components/classify.vue"
  23. export default {
  24. components:{
  25. tabbar,
  26. selfEcharts,
  27. classify
  28. },
  29. data() {
  30. return {
  31. classifyFlag:false,
  32. safeAreaTop:this.$store.state.systemInfo.safeAreaTop,
  33. }
  34. },
  35. methods:{
  36. timeEvent(){
  37. wx.showActionSheet({
  38. itemList: ['近7天', '近15天', '近30天', '近90天'],
  39. success (res) {
  40. },
  41. fail (res) {
  42. }
  43. })
  44. },
  45. getChoiceData(data){
  46. console.log(data,'分类数据')
  47. },
  48. toCeshi(index) {
  49. uni.navigateTo({
  50. url: "/pages/subPackages/liveDetail/liveDetail?room_id=" + index
  51. })
  52. },
  53. goLogin() {
  54. uni.navigateTo({
  55. url: '/pages/subPackages/login/login'
  56. })
  57. }
  58. }
  59. }
  60. </script>
  61. <style lang="scss" scoped>
  62. .li {
  63. height: 100rpx;
  64. }
  65. </style>