1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859 |
- <template>
- <view style="height: 100%;">
- <rich-text style="flex: 1" :nodes="richText" />
- </view>
- </template>
- <script setup lang='ts'>
- import {
- ref
- } from 'vue';
- import {
- request
- } from "@/utils/network/request.js";
- import {
- onLoad
- } from '@dcloudio/uni-app'
-
- let richText = ref('')
- let singleEquityId = ref('')
- let couponAgencyType = ref('')
- let couponId = ref('')
-
- onLoad((options) => {
- singleEquityId.value = options.singleEquityId
- couponAgencyType.value = options.couponAgencyType
- //卡券渠道类型获取单项权益列表
- request("35c5db593cea426d87fb48525873ecc9", {
- type: 2,
- data: {
- singleEquityId: singleEquityId.value
- },
- method: "POST",
- showLoading: true,
- }).then((item) => {
- let res = JSON.parse(item.bizContent)
- console.log(res, '=========');
- richText.value = res.productIntro
- couponId.value = res.couponId
- })
- })
-
- function onClick() {
- uni.navigateTo({
- url: '/subpackage/service/equity/equity?singleEquityId=' + singleEquityId.value +
- "&couponAgencyType=" + couponAgencyType.value + "&couponId=" + couponId.value,
- })
- }
- </script>
- <style lang='scss' scoped>
- .copy-btn {
- background-color: #4caf50;
- color: #fff;
- border: none;
- width: 100%;
- padding: 10rpx 0;
- border-radius: 10rpx;
- font-size: 24rpx;
- box-shadow: 0 2rpx 4rpx rgba(0, 0, 0, 0.2);
- }
- </style>
|