新修改_bug
This commit is contained in:
parent
17a76041eb
commit
ddb1651e28
|
@ -1 +0,0 @@
|
|||
.main-title-color[data-v-07850ae0]{color:#d14328}
|
|
@ -0,0 +1 @@
|
|||
.main-title-color[data-v-cc0dc560]{color:#d14328}
|
File diff suppressed because one or more lines are too long
|
@ -1 +0,0 @@
|
|||
var t=Object.defineProperty,e=Object.defineProperties,a=Object.getOwnPropertyDescriptors,n=Object.getOwnPropertySymbols,s=Object.prototype.hasOwnProperty,o=Object.prototype.propertyIsEnumerable,l=(e,a,n)=>a in e?t(e,a,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[a]=n,i=(t,e)=>{for(var a in e||(e={}))s.call(e,a)&&l(t,a,e[a]);if(n)for(var a of n(e))o.call(e,a)&&l(t,a,e[a]);return t},r=(t,n)=>e(t,a(n)),c=(t,e,a)=>new Promise(((n,s)=>{var o=t=>{try{i(a.next(t))}catch(e){s(e)}},l=t=>{try{i(a.throw(t))}catch(e){s(e)}},i=t=>t.done?n(t.value):Promise.resolve(t.value).then(o,l);i((a=a.apply(t,e)).next())}));import{r as u,s as d,d as p,g as v,a as f,b as y,u as m,n as _,c as g,o as O,e as b,f as h,h as w,i as j,w as I,j as x,k,l as P,m as $,p as T,q,_ as D}from"./index-Dm41iOPZ.js";const L=t=>new Promise(((e,a)=>{u(r(i({},t),{dataType:"json",header:{"content-type":"application/json"},responseType:"json",success(t){var n,s,o;(null==(n=t.data)?void 0:n.code)>=200&&(null==(s=t.data)?void 0:s.code)<300?e(t.data):401===(null==(o=t.data)?void 0:o.code)?(window.parent.postMessage({data:{type:"logout"}},"*"),a(t)):e(t.data)},fail(t){d({icon:"none",title:"网络错误,换个网络试试"}),a(t)}}))}));L.get=(t,e)=>L({url:t,query:e,method:"GET"}),L.post=(t,e,a,n=!1)=>L({url:t,query:a,data:e,method:"POST",hideErrorToast:n});const E=t=>L.get("/v1/content",t),S=D(p(r(i({},{name:"Home"}),{__name:"index",setup(t){const{safeAreaInsets:e}=v(),a=f({}),n=y(""),s=y(""),o=m();let l="activity",i=null;const r={Interface:"api_code",lottery:"lottery_code",activity:"activity_code"},u=f({url:"",title:""});function p(){return c(this,null,(function*(){const t={};t[r[l]]=n.value||"",o.reset();D(yield E(t))}))}function D(t){if(200===t.code){const{login_content_template:e,login_content_templates:s,content_templates:l,token:i}=t.data;n.value=t.data.activity_code,Object.assign(a,t.data),1===e.validate_login?Object.assign(u,{url:L(s.source+`?activity_code=${n.value}`),title:s.moduledesc}):2===e.validate_login&&Object.assign(u,{url:L(l.source+`?activity_code=${n.value}&token=${i}`),title:l.moduledesc}),g({title:u.title}),o.setUserInfo({srcList:u,contentData:a,query:n.value,token:i})}else d({title:t.message,icon:"none"})}function L(t){const e=(new Date).getTime();return t+(t.includes("?")?"×tamp=":"?timestamp=")+e}window.parent.addEventListener("message",(function(t){let e={url:"",title:""};switch(t.data.data.type){case"login":case"couponBack":e={url:a.content_templates.source+`?activity_code=${n.value}`,title:a.content_templates.moduledesc};break;case"coupon":e={url:a.user_content_templates.source+`?activity_code=${n.value}`,title:a.user_content_templates.moduledesc};break;case"product":const s=`product_id=${t.data.data.product_id}&id=${t.data.data.id}&activity_code=${n.value}`,o=encodeURIComponent(s);e={url:a.user_content_templates.source+`#/pages/coupon/product?url=${o}`,title:a.user_content_templates.moduledesc};break;case"logout":return p()}_((()=>{Object.assign(u,{url:L(e.url),title:e.title}),g({title:u.title}),o.setUserInfo({srcList:u,contentData:a,query:n.value,token:a.token})}))}));const S=()=>{i=setInterval((()=>c(this,null,(function*(){const t={};t[r[l]]=s.value||"";const e=yield E(t);JSON.stringify(e.data)!==JSON.stringify(o.userInfo.contentData)&&(d({title:"活动发生变更",icon:"none"}),D(e))}))),6e4)};return O((()=>{n.value=(()=>{const t=window.location.href;if(-1!==t.indexOf("#/")){let e="";const a=-1!==t.indexOf("#/")?t.split("#/")[1]:t.split("/")[t.split("/").length-1];return e=-1===a.indexOf("/")?a||"":a.split("/")[0],-1===e.indexOf("-")?l="activity":(l=e.split("-")[0],e=e.split("-")[1]),e}if(-1!==t.indexOf("?")){let e="";return e=t.split("=")[1],l=e.split("-")[0],e.split("-")[1]}{const e=t.split("/"),a=e[e.length-1];let n="";return-1===a.indexOf("-")?(n=a,l="activity"):(l=a.split("-")[0],n=a.split("-")[1]),n}})(),s.value=n.value,o.userInfo.srcList.url&&o.userInfo.query===n.value?(Object.assign(u,o.userInfo.srcList,{url:L(o.userInfo.srcList.url)}),Object.assign(a,o.userInfo.contentData),g({title:u.title})):p(),S()})),b((()=>{clearInterval(i),i=null})),(t,a)=>{const n=T,s=q,o=h("layout-default-uni");return w(),j(o,null,{default:I((()=>{var t;return[x(s,{class:"bg-white overflow-hidden pt-2 px-4",style:$({marginTop:(null==(t=k(e))?void 0:t.top)+"px"})},{default:I((()=>[k(u).url?(w(),j(n,{key:0,src:k(u).url},null,8,["src"])):P("",!0)])),_:1},8,["style"])]})),_:1})}}})),[["__scopeId","data-v-07850ae0"]]);export{S as default};
|
|
@ -0,0 +1 @@
|
|||
var t=Object.defineProperty,e=Object.defineProperties,a=Object.getOwnPropertyDescriptors,n=Object.getOwnPropertySymbols,o=Object.prototype.hasOwnProperty,s=Object.prototype.propertyIsEnumerable,l=(e,a,n)=>a in e?t(e,a,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[a]=n,i=(t,e)=>{for(var a in e||(e={}))o.call(e,a)&&l(t,a,e[a]);if(n)for(var a of n(e))s.call(e,a)&&l(t,a,e[a]);return t},r=(t,n)=>e(t,a(n)),c=(t,e,a)=>new Promise(((n,o)=>{var s=t=>{try{i(a.next(t))}catch(e){o(e)}},l=t=>{try{i(a.throw(t))}catch(e){o(e)}},i=t=>t.done?n(t.value):Promise.resolve(t.value).then(s,l);i((a=a.apply(t,e)).next())}));import{r as u,s as d,d as p,g as v,a as y,b as f,u as m,n as _,c as g,o as O,e as b,f as h,h as w,i as j,w as I,j as x,k,l as P,m as $,p as T,q as D,_ as L}from"./index-b9C2rvKz.js";const C=t=>new Promise(((e,a)=>{u(r(i({},t),{dataType:"json",header:{"content-type":"application/json"},responseType:"json",success(t){var n,o,s;(null==(n=t.data)?void 0:n.code)>=200&&(null==(o=t.data)?void 0:o.code)<300?e(t.data):401===(null==(s=t.data)?void 0:s.code)?(window.parent.postMessage({data:{type:"logout"}},"*"),a(t)):e(t.data)},fail(t){d({icon:"none",title:"网络错误,换个网络试试"}),a(t)}}))}));C.get=(t,e)=>C({url:t,query:e,method:"GET"}),C.post=(t,e,a,n=!1)=>C({url:t,query:a,data:e,method:"POST",hideErrorToast:n});const E=t=>C.get("/v1/content",t),S=L(p(r(i({},{name:"Home"}),{__name:"index",setup(t){const{safeAreaInsets:e}=v(),a=y({}),n=f(""),o=f(""),s=m();let l="activity",i=null;const r={Interface:"api_code",lottery:"lottery_code",activity:"activity_code"},u=y({url:"",title:""});function p(){return c(this,null,(function*(){const t={};t[r[l]]=n.value||"",s.reset();L(yield E(t))}))}function L(t){if(200===t.code){const{login_content_template:e,login_content_templates:l,content_templates:i,token:r}=t.data;n.value=t.data.activity_code,Object.assign(a,t.data),1===e.validate_login?Object.assign(u,{url:C(l.source+`?activity_code=${n.value}`),title:l.moduledesc}):2===e.validate_login&&Object.assign(u,{url:C(i.source+`?activity_code=${n.value}&token=${r}`),title:i.moduledesc}),g({title:u.title}),s.setUserInfo({srcList:u,contentData:a,activityCode:n.value,token:r,lottery:o.value})}else d({title:t.message,icon:"none"})}function C(t){const e=(new Date).getTime();return t+(t.includes("?")?"×tamp=":"?timestamp=")+e}window.parent.addEventListener("message",(function(t){let e={url:"",title:""};switch(t.data.data.type){case"login":case"couponBack":e={url:a.content_templates.source+`?activity_code=${n.value}`,title:a.content_templates.moduledesc};break;case"coupon":e={url:a.user_content_templates.source+`?activity_code=${n.value}`,title:a.user_content_templates.moduledesc};break;case"product":const o=`product_id=${t.data.data.product_id}&id=${t.data.data.id}&activity_code=${n.value}`,s=encodeURIComponent(o);e={url:a.user_content_templates.source+`#/pages/coupon/product?url=${s}`,title:a.user_content_templates.moduledesc};break;case"logout":return p()}_((()=>{Object.assign(u,{url:C(e.url),title:e.title}),g({title:u.title}),s.setUserInfo({srcList:u,contentData:a,activityCode:n.value,token:a.token,lottery:o.value})}))}));const S=()=>{i=setInterval((()=>c(this,null,(function*(){const t={};t[r[l]]=o.value||"";const e=yield E(t);JSON.stringify(e.data)!==JSON.stringify(s.userInfo.contentData)&&(d({title:"活动发生变更",icon:"none"}),L(e))}))),6e4)};return O((()=>{n.value=(()=>{const t=window.location.href;if(-1!==t.indexOf("#/")){let e="";const a=-1!==t.indexOf("#/")?t.split("#/")[1]:t.split("/")[t.split("/").length-1];return e=-1===a.indexOf("/")?a||"":a.split("/")[0],-1===e.indexOf("-")?l="activity":(l=e.split("-")[0],e=e.split("-")[1]),e}if(-1!==t.indexOf("?")){let e="";return e=t.split("=")[1],l=e.split("-")[0],e.split("-")[1]}{const e=t.split("/"),a=e[e.length-1];let n="";return-1===a.indexOf("-")?(n=a,l="activity"):(l=a.split("-")[0],n=a.split("-")[1]),n}})(),o.value=n.value,!s.userInfo.srcList.url||s.userInfo.lottery!==o.value&&s.userInfo.activityCode!==n.value?p():(n.value=s.userInfo.activityCode,Object.assign(u,s.userInfo.srcList,{url:C(s.userInfo.srcList.url)}),Object.assign(a,s.userInfo.contentData),g({title:u.title})),S()})),b((()=>{clearInterval(i),i=null})),(t,a)=>{const n=T,o=D,s=h("layout-default-uni");return w(),j(s,null,{default:I((()=>{var t;return[x(o,{class:"bg-white overflow-hidden pt-2 px-4",style:$({marginTop:(null==(t=k(e))?void 0:t.top)+"px"})},{default:I((()=>[k(u).url?(w(),j(n,{key:0,src:k(u).url},null,8,["src"])):P("",!0)])),_:1},8,["style"])]})),_:1})}}})),[["__scopeId","data-v-cc0dc560"]]);export{S as default};
|
|
@ -1,5 +1,5 @@
|
|||
<!doctype html>
|
||||
<html build-date="2024-07-02 16:54:19">
|
||||
<html build-date="2024-07-09 15:57:55">
|
||||
<head>
|
||||
<link rel="stylesheet" href="./assets/uni.ad4bcb33.css">
|
||||
|
||||
|
@ -19,7 +19,7 @@
|
|||
<title>场景营销</title>
|
||||
<!--preload-links-->
|
||||
<!--app-context-->
|
||||
<script type="module" crossorigin src="./assets/index-Dm41iOPZ.js"></script>
|
||||
<script type="module" crossorigin src="./assets/index-b9C2rvKz.js"></script>
|
||||
<link rel="stylesheet" crossorigin href="./assets/index-DfE4H0b6.css">
|
||||
</head>
|
||||
|
||||
|
|
|
@ -24,7 +24,6 @@ export default defineManifestConfig({
|
|||
locale: VITE_FALLBACK_LOCALE, // 'zh-Hans'
|
||||
h5: {
|
||||
router: {
|
||||
mode: 'history',
|
||||
base: VITE_APP_PUBLIC_BASE,
|
||||
},
|
||||
},
|
||||
|
|
|
@ -105,7 +105,6 @@
|
|||
"vueVersion": "3",
|
||||
"h5": {
|
||||
"router": {
|
||||
"mode": "history",
|
||||
"base": "./"
|
||||
}
|
||||
}
|
||||
|
|
|
@ -382,6 +382,8 @@ function getAccountInfo() {
|
|||
// eslint-disable-next-line camelcase
|
||||
receive_num.value = res.data.lottery_count - res.data.use_lottery_count
|
||||
// eslint-disable-next-line camelcase
|
||||
receive_num.value = receive_num.value > 0 ? receive_num.value : 0
|
||||
// eslint-disable-next-line camelcase
|
||||
lottery_code.value = res.data.lottery_code
|
||||
// eslint-disable-next-line camelcase
|
||||
validate_whitelist.value = res.data.validate_whitelist
|
||||
|
|
|
@ -250,6 +250,7 @@ onLoad(() => {
|
|||
) {
|
||||
initContent()
|
||||
} else {
|
||||
activityCode.value = useStore.userInfo.activityCode
|
||||
Object.assign(srcList, useStore.userInfo.srcList, {
|
||||
url: getTimesTamp(useStore.userInfo.srcList.url),
|
||||
})
|
||||
|
|
|
@ -25,7 +25,7 @@
|
|||
mode=""
|
||||
></image>
|
||||
</view>
|
||||
<text class="f40 mt80" style="color: #003a6e">{{ jiang }}</text>
|
||||
<text class="f40 mt40" style="color: #003a6e">{{ jiang }}</text>
|
||||
<text v-if="isz === 1" class="f24 mt10" style="color: #003a6e">请到【我的奖品】中查看</text>
|
||||
<view
|
||||
v-if="isz == 1"
|
||||
|
@ -244,8 +244,7 @@ export default {
|
|||
if (res.code === 200) {
|
||||
// eslint-disable-next-line camelcase
|
||||
const { activity_info, status, lottery_code, lottery_count, use_lottery_count } = res.data
|
||||
// eslint-disable-next-line camelcase
|
||||
this.freeNum = lottery_count - use_lottery_count
|
||||
this.freeNum = this.freeNum > 0 ? this.freeNum : 0
|
||||
// eslint-disable-next-line camelcase
|
||||
this.status = activity_info?.status || 0
|
||||
// eslint-disable-next-line camelcase
|
||||
|
|
|
@ -87,7 +87,7 @@
|
|||
</view>
|
||||
<view
|
||||
@click="gomypre(item)"
|
||||
:class="['f24', 'f-center', item.status !== 1 && 'not-view']"
|
||||
:class="['f24', 'f-center', item.product_form === 2 && 'not-view']"
|
||||
style="
|
||||
width: 124rpx;
|
||||
line-height: 48rpx;
|
||||
|
@ -238,7 +238,7 @@ page {
|
|||
background: #f5f5f5 !important;
|
||||
}
|
||||
.not-view {
|
||||
background-color: #848486;
|
||||
background: #848486 !important;
|
||||
}
|
||||
.three {
|
||||
overflow: hidden;
|
||||
|
|
|
@ -347,10 +347,15 @@ function okdiu() {
|
|||
}
|
||||
api.exchange(params).then((res: any) => {
|
||||
if (res.code === 200) {
|
||||
uni.hideLoading()
|
||||
uni.showToast({
|
||||
title: '兑换成功',
|
||||
icon: 'success',
|
||||
})
|
||||
setTimeout(() => {
|
||||
uni.navigateTo({
|
||||
url: '/pages/tt-coupon/index?activity_code=' + route.activity_code,
|
||||
})
|
||||
}, 500)
|
||||
} else {
|
||||
uni.hideLoading()
|
||||
uni.showToast({
|
||||
|
|
|
@ -82,11 +82,15 @@
|
|||
class="bgwhite pb30 plr20 pt20 mt35 flex_column"
|
||||
style="width: calc(100% - 100rpx); border-radius: 20rpx"
|
||||
>
|
||||
<text class="f30 mt30 bold" style="color: #333">待充账号</text>
|
||||
<text class="f30 mt30 bold" style="color: #333">充值账号</text>
|
||||
<wd-input
|
||||
class="mt30"
|
||||
fontSize="14"
|
||||
placeholder="请输入手机号"
|
||||
:placeholder="
|
||||
info.account_type === 1 || info.account_type === 2
|
||||
? '请输入充值手机号'
|
||||
: '请输入手机/QQ'
|
||||
"
|
||||
v-model="info.mobile"
|
||||
></wd-input>
|
||||
<text class="f26 mt40" style="color: #4d4d4d">温馨提示</text>
|
||||
|
@ -138,9 +142,9 @@ function dui() {
|
|||
uni.showLoading({
|
||||
title: '兑换中...',
|
||||
})
|
||||
if (!info.mobile) {
|
||||
if (info.product_form !== 3 && !info.mobile) {
|
||||
return uni.showToast({
|
||||
title: '充值账号未输入',
|
||||
title: '请输入充值账号',
|
||||
icon: 'none',
|
||||
})
|
||||
}
|
||||
|
|
|
@ -29,8 +29,8 @@ type IUserInfo = {
|
|||
token?: string
|
||||
srcList?: SrcListType
|
||||
contentData?: object
|
||||
query?: string
|
||||
href?: string
|
||||
activityCode?: string
|
||||
lottery?: string
|
||||
}
|
||||
|
||||
enum TestEnum {
|
||||
|
|
Loading…
Reference in New Issue