index.vue 6.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394
  1. <template>
  2. <view>
  3. <button @click="yanxeu">研学</button>
  4. <button @click="home">首页</button>
  5. <button @click="huodong">活动</button>
  6. <!-- <u--input type="text" v-model="page" />
  7. <button @click="jump">走!</button> -->
  8. <button @click="openCalendar">日历</button>
  9. <button @click="toStudyOrder">研学订单</button>
  10. <button @click="toShare">记录研学历程</button>
  11. <button @click="jscode">获取jscode</button>
  12. <button @click="fenxiang">研学分享</button>
  13. <uni-calendar ref="calendar" :showMonth="false" style="z-index: 999;" :insert="false" @confirm="confirm"
  14. title="出发时间" :showCancelAndOk="false">
  15. <template v-slot:btn>
  16. <view style="margin: 0 24rpx;">
  17. <u-button shape="circle" type="primary" text="确定"></u-button>
  18. </view>
  19. </template>
  20. </uni-calendar>
  21. </view>
  22. </template>
  23. <script>
  24. export default {
  25. data() {
  26. return {
  27. page: "/pages/index/index",
  28. info: { "shopId": "65fe8e5874d67a7dbd842c5a", "goodsId": "1820779910092951552", "goodsName": "探索光圈科技", "goodsDescribe": "研学类型商品", "goodsType": "801", "isStudy": true, "goodsLabel": "专享折扣价", "goodsLabelId": 8, "goodsCateId": "24", "crossedPrice": 0, "marketPrice": 998, "realPrice": 0.01, "goodsPath": "http://zswl-dev.oss-cn-chengdu.aliyuncs.com/63b7c68b71a69169d1b33f92/store/65fe8e5874d67a7dbd842c5a/ext/GOODS_INFO/School.png/5.png", "goodsDetail": "<p style=\"text-align: start;\"><img class=\"img_class\" src=\"http://zswl-dev.oss-cn-chengdu.aliyuncs.com/63b7c68b71a69169d1b33f92/store/65fe8e5874d67a7dbd842c5a/ext/OTHER/wallhaven-4lp55p.png/1.png\" alt=\"\" data-href=\"\" style=\"\"></p><p style=\"text-align: start;\">什巍表芽棘率幸枪元退贺川冈襄琅俭流共右沫您怎县贺蓝月悟挺锁醚靳申己兽茎据意措撤嫂精荣闪?</p><p style=\"text-align: start;\">泥稀愤缠拢注牌拚?</p><p style=\"text-align: start;\">哀白裕冰狮考超煞嘻烈展。凌儒助铸节输鱼址凸骑佩罩己沈鲍搭满野资岗恨台场型热佐可碑镦减奠雾污;蝼悠固壕跌雹;碎凉廉戒烫园冠局畜锡糊昏陋螟撇锻往借剿橘礁仇苦撤鸡荆致稍损锐及递雀灿巧陕滋受衍爹洼克跃稼乏姿图势舌横治祭矮屯湾刀永破奈包伍涨摇尊骂桥踢踩学兄池撇或葱砌隔国也鞭佳酷错醋已轻馆肠答侯档扔晰酯贸钒肤酬想捞衷灰傀衬迹孟坠歼铆。壮?</p><p style=\"text-align: start;\">予绩。锻潜。汉骂逸炕豌弊们腐钢殷彭琢撑伤母稠!当码!荫玻赌南婆弧话</p><p style=\"text-align: start;\"><br></p>", "goodsSort": 1, "status": 3, "stockNum": 2000, "stockThresholdNum": 0, "saleNum": 1254, "applyState": 0, "applyTime": "2024-08-09 17:35:10", "checkUserId": "657c35e3cae1326607ea9ed2", "checkDetail": "test", "checkTime": "2024-08-09 17:26:04", "syncEnable": 1, "syncRang": "", "validEnable": 1, "validRang": "", "specs": [{ "specId": 609, "goodsId": "1820779910092951552", "specName": "xxx", "specValues": [{ "specId": 609, "specValue": "123", "specImg": null, "status": 1, "specPrice": 0, "price": null, "marketPrice": null, "stockNum": null, "sku": null }] }], "attrs": [{ "goodsId": "1820779910092951552", "attrName": "validDay", "attrValue": "90", "status": 1 }, { "goodsId": "1820779910092951552", "attrName": "使用说明", "attrValue": "袭膨寇伴汗妇,碗层捧颈纷谎喂绳借炸勒齿招纱杰镦役哪寻橄幼痰潭畦首!", "status": 1 }], "taxRate": 0, "withdrawalRate": 0, "shareId": 1, "goodsSets": [], "sharePlatformVo": { "shareRule": "平台抽成20%,购买商户70%,核销店铺10%", "shareType": 1, "cycle": 0, "platformRate": 20, "buyShopRate": 70, "checkShopRate": 10, "createTime": "2023-11-29 17:45:24" }, "validDay": 90, "realStockNum": 2000, "isGzuGood": false, "shopInfo": { "shopId": "65fe8e5874d67a7dbd842c5a", "shopName": "周黑鸭重庆江北店", "serviceName": "", "serviceTel": "18716330270", "address": "重庆市江北区中野路191号嘛嘛公寓(观音桥店)西南88米", "mapLon": "106.54497098121142", "mapLat": "29.57767497468472", "logoPath": "http://zswl-dev.oss-cn-chengdu.aliyuncs.com/63b7c68b71a69169d1b33f92/store/657c35e3cae1326607ea9ed2/ext/SHOP_INFO/1977.jpg_wh300.jpg/6.jpg", "doorImg": "", "shopLabel": "", "district": "江北区" }, "refundType": 1, "services": [], "goodsService": null, "showType": 1, "courses": [{ "id": 45, "courseName": "1", "courseImg": "http://zswl-dev.oss-cn-chengdu.aliyuncs.com/63b7c68b71a69169d1b33f92/store/65fe8e5874d67a7dbd842c5a/ext/GOODS_INFO/School.png/6.png", "columnId": null, "courseMsg": "1", "status": 1, "goodsId": "1820779910092951552", "type": "2", "chapterUrl": "http://zswl-dev.oss-cn-chengdu.aliyuncs.com/63b7c68b71a69169d1b33f92/store/65fe8e5874d67a7dbd842c5a/ext/GOODS_INFO/16.mp4/5.mp4", "chapterName": "16.mp4", "videoSize": null, "viewedCount": null, "per": 0 }, { "id": 46, "courseName": "易…鞋谬的胶请,位贩?", "courseImg": "http://zswl-dev.oss-cn-chengdu.aliyuncs.com/63b7c68b71a69169d1b33f92/store/65fe8e5874d67a7dbd842c5a/ext/GOODS_INFO/wallhaven-d5we7o.png/1.png", "columnId": null, "courseMsg": "塑科搏迫兜场矿哺勤塑渐芒浙璃购芒楔镗设。捧脓玛腹浸休杆阮嫌溴架钴眇祭已策毛骚乌娟黎厂!", "status": 1, "goodsId": "1820779910092951552", "type": "2", "chapterUrl": "http://zswl-dev.oss-cn-chengdu.aliyuncs.com/63b7c68b71a69169d1b33f92/store/65fe8e5874d67a7dbd842c5a/ext/GOODS_INFO/192d9a98d782d9c74c96f09db9378d93.mp4/19.mp4", "chapterName": "192d9a98d782d9c74c96f09db9378d93.mp4", "videoSize": null, "viewedCount": null, "per": 0 }], "saleTimeType": "1", "saleWeekDays": "", "saleStartTime": "2024-08-04 00:00:00", "saleEndTime": "2024-09-15 00:00:00" }
  29. };
  30. },
  31. methods: {
  32. openCalendar() {
  33. this.$refs.calendar.open();
  34. },
  35. confirm(e) {
  36. console.log(e);
  37. },
  38. yanxeu() {
  39. uni.navigateTo({
  40. url: '/study/index'
  41. });
  42. },
  43. jump() {
  44. uni.navigateTo({
  45. url: this.page
  46. });
  47. },
  48. home() {
  49. uni.switchTab({
  50. url: '/pages/index/index'
  51. });
  52. },
  53. huodong() {
  54. uni.switchTab({
  55. url: '/pages/activity/index'
  56. });
  57. },
  58. toStudyOrder() {
  59. let that = this
  60. uni.navigateTo({
  61. url: `/study/pay/order`,
  62. success: function (res) {
  63. // 通过eventChannel向被打开页面传送数据
  64. res.eventChannel.emit('pay', that.info)
  65. }
  66. })
  67. },
  68. toShare() {
  69. uni.navigateTo({
  70. url: '/share/sharePosts'
  71. });
  72. },
  73. jscode() {
  74. uni.login({
  75. provider: 'weixin',
  76. success: function (loginRes) {
  77. console.log('登录成功!' + JSON.stringify(loginRes));
  78. }
  79. });
  80. },
  81. fenxiang() {
  82. uni.navigateTo(
  83. {
  84. url: '/share/index'
  85. }
  86. )
  87. }
  88. },
  89. };
  90. </script>
  91. <style lang="scss" scoped></style>