wjx 3 anni fa
parent
commit
13e834bbc9
32 ha cambiato i file con 516 aggiunte e 116 eliminazioni
  1. 4 0
      .hbuilderx/launch.json
  2. 6 3
      api/api.js
  3. 3 2
      manifest.json
  4. 276 34
      pages/index/index.vue
  5. 1 1
      pages/officialAccount/officialAccount.vue
  6. BIN
      static/12Back.png
  7. BIN
      static/doubleBt.png
  8. BIN
      static/goldBack.png
  9. BIN
      static/vipBack.png
  10. 3 5
      uni_modules/almost-lottery/components/almost-lottery/almost-lottery.vue
  11. 0 0
      unpackage/dist/dev/.sourcemap/mp-weixin/common/main.js.map
  12. 0 0
      unpackage/dist/dev/.sourcemap/mp-weixin/common/vendor.js.map
  13. 0 0
      unpackage/dist/dev/.sourcemap/mp-weixin/pages/checkInRecord/checkInRecord.js.map
  14. 0 0
      unpackage/dist/dev/.sourcemap/mp-weixin/pages/index/index.js.map
  15. 0 0
      unpackage/dist/dev/.sourcemap/mp-weixin/pages/officialAccount/officialAccount.js.map
  16. 0 0
      unpackage/dist/dev/.sourcemap/mp-weixin/uni_modules/almost-lottery/components/almost-lottery/almost-lottery.js.map
  17. 0 0
      unpackage/dist/dev/.sourcemap/mp-weixin/uview-ui/components/u-column-notice/u-column-notice.js.map
  18. 0 0
      unpackage/dist/dev/.sourcemap/mp-weixin/uview-ui/components/u-icon/u-icon.js.map
  19. 0 0
      unpackage/dist/dev/.sourcemap/mp-weixin/uview-ui/components/u-notice-bar/u-notice-bar.js.map
  20. 0 0
      unpackage/dist/dev/.sourcemap/mp-weixin/uview-ui/components/u-row-notice/u-row-notice.js.map
  21. 8 20
      unpackage/dist/dev/mp-weixin/common/vendor.js
  22. 131 16
      unpackage/dist/dev/mp-weixin/pages/index/index.js
  23. 0 0
      unpackage/dist/dev/mp-weixin/pages/index/index.wxml
  24. 75 6
      unpackage/dist/dev/mp-weixin/pages/index/index.wxss
  25. 1 1
      unpackage/dist/dev/mp-weixin/pages/officialAccount/officialAccount.js
  26. 3 6
      unpackage/dist/dev/mp-weixin/project.config.json
  27. BIN
      unpackage/dist/dev/mp-weixin/static/12Back.png
  28. BIN
      unpackage/dist/dev/mp-weixin/static/doubleBt.png
  29. BIN
      unpackage/dist/dev/mp-weixin/static/goldBack.png
  30. BIN
      unpackage/dist/dev/mp-weixin/static/vipBack.png
  31. 3 5
      unpackage/dist/dev/mp-weixin/uni_modules/almost-lottery/components/almost-lottery/almost-lottery.js
  32. 2 17
      utils/request.js

+ 4 - 0
.hbuilderx/launch.json

@@ -6,6 +6,10 @@
      	{
      		"launchtype" : "local"
      	},
+     	"h5" : 
+     	{
+     		"launchtype" : "local"
+     	},
      	"mp-weixin" : 
      	{
      		"launchtype" : "local"

+ 6 - 3
api/api.js

@@ -1,10 +1,13 @@
 import { request } from "@/utils/request"
 
 /**
+ * 大转盘小程序
  * wx021e792baf529aff  好运赢书券
+ * wxe1b04d1d8f6df382  书币礼包送不停(转盘抽奖)
+ * wx4e8c3f946c06c519  书币礼包领不停(转盘抽奖)
  */
 export let config = {
-	appid: 'wx021e792baf529aff'
+	appid: 'wx4e8c3f946c06c519'
 }
 
 export async function getHome(data) {
@@ -41,8 +44,8 @@ export async function setDrawGain(data) {
 }
 
 // 获取公众号文章
-export async function getUrl() {
-	return request({url: `/applet/mp/url`})
+export async function getUrl(data) {
+	return request({url: `/applet/mp/url`, data})
 }
 
 // 头两次领取

+ 3 - 2
manifest.json

@@ -50,10 +50,11 @@
     "quickapp" : {},
     /* 小程序特有相关 */
     "mp-weixin" : {
-        "appid" : "wx021e792baf529aff",
+        "appid" : "wx4e8c3f946c06c519",
         "setting" : {
             "urlCheck" : false,
-            "es6" : true
+            "es6" : true,
+            "minified" : false
         },
         "usingComponents" : true
     },

+ 276 - 34
pages/index/index.vue

@@ -42,7 +42,7 @@
 						:outerHeight="canvasConfig.outerHeight"
 						:colors="canvasConfig.colors"
 						:ringCount="8"
-						:duration="1" 
+						:duration="5" 
 						:prizeList="prizeList"
 						:prizeIndex="prizeIndex"
 						@reset-index="prizeIndex = -1"
@@ -101,15 +101,66 @@
 					<view class="content">
 						<image src="../../static/popupBack.png"></image>
 						<view class="textCon">
-							<text class="ts">中奖了!</text> </br>
-							<text class="reward">恭喜您获得{{luckyDay.name}}</text> </br>
-							<image src="../../static/doubleBt.png" class="doubleBt" mode="widthFix" @click="lookVideo"></image> </br>
+							<text class="ts">恭喜您获得</text> </br>
+							<text class="reward ts">{{luckyDay.name}}</text> </br>
+							<image src="../../static/doubleBt.png" class="doubleBt" mode="widthFix" :style="{transform: `scale(${scale})`}" @click="lookVideo"></image> </br>
 							<text class="bt" @click="receiveGold(false)">不了,单倍领取</text>
 						</view>
 					</view>
 					<image src="../../static/close.png" class="close" mode="widthFix" @click="closeHandle"></image>
 				</view>
 			</view>
+			<!-- 弹窗VIP -->
+			<view class="popupVIP popup" v-if="popupVIPShow">
+				<view class="popupContent" style="width: 524rpx;">
+					<view class="content">
+						<image src="../../static/vipBack.png"></image>
+						<view class="textCon" style="display: flex; align-items: flex-end;">
+							<view class="againLuckDrawBt btVip" @click="againLuckDraw('vip');startAni(2)" :style="{transform: `scale(${scale})`}">再次抽奖</view>
+						</view>
+					</view>
+					<image src="../../static/close.png" class="close" mode="widthFix" @click="popupVIPShow = false;startAni(2)"></image>
+				</view>
+			</view>
+			<!-- 弹窗12 -->
+			<view class="popup12 popup" v-if="popup12Show">
+				<view class="popupContent" style="width: 702rpx;">
+					<view class="content">
+						<image src="../../static/12Back.png" style="height: 722rpx;"></image>
+						<view class="textCon" style="display: flex; align-items: flex-end;">
+							<view class="againLuckDrawBt" @click="againLuckDraw('12'); startAni(3)" :style="{transform: `scale(${scale})`, marginBottom: 0}">再次抽奖</view>
+						</view>
+					</view>
+					<image src="../../static/close.png" class="close" mode="widthFix" @click="popup12Show = false; startAni(3)"></image>
+				</view>
+			</view>
+			<!-- 弹窗金币 -->
+			<view class="popup12 popup" v-if="popupGoldShow">
+				<view class="popupContent" style="width: 636rpx;">
+					<view class="content">
+						<image src="../../static/goldBack.png" style="height: 790rpx;"></image>
+						<view class="textCon" style="display: flex; align-items: center; flex-direction: column; justify-content: flex-end;">
+							<text class="goldText">恭喜您获得</text> </br>
+							<text class="goldText" style="margin-bottom: 48rpx;">{{luckyDay.name}}</text>
+							<view class="againLuckDrawBt btGold" @click="againLuckDraw('gold'); startGold(false)" :style="{transform: `translateX(12rpx) scale(${scale})`}">再次抽奖</view>
+						</view>
+					</view>
+					<image src="../../static/close.png" class="close" mode="widthFix" @click="popupGoldShow = false; startGold(false)"></image>
+				</view>
+			</view>
+		
+			<!-- 碎片飞行 -->
+			<view class="fragmentAni" :animation="animationData">
+				<image :src="prizeType === 3 ? '../../static/turntable_iPhone12.png' : '../../static/turntable_VIP.png'" mode="widthFix"></image>
+			</view>
+			<!-- 金币飞行组 -->
+			<view class="fragmentGold" :animation="animationDatas[index]" v-for="(item, index) in goldData" :key="index" :style="{top: item.top, left: item.left}">
+				<image src="../../static/turntable_gold.png" mode="widthFix"></image>
+			</view>
+			<!-- 弹窗提示 -->
+			<view class="receiveTs" :animation="animationDataTs">
+				{{tsTitle}}
+			</view>
 		</view>
 	</view>
 </template>
@@ -119,6 +170,7 @@
 	import AlmostLottery from '@/uni_modules/almost-lottery/components/almost-lottery/almost-lottery.vue'
 	import { config, getHome, getOpenId, getBanner, setDrawGain, getPond, setReceive } from '@/api/api.js'
 	import { clearCacheFile } from '@/uni_modules/almost-lottery/utils/almost-utils.js'
+	
 	export default {
 		components: {
 			AlmostLottery
@@ -154,29 +206,21 @@
 				// 是否正在抽奖中,避免重复触发
 				prizeing: false,
 				
-				// 以下为中奖概率有关数据
-				// 是否由前端控制概率,默认不开启,强烈建议由后端控制
-				onFrontend: false,
-				// 权重随机数的最大值
-				weightTotal: 0,
-				// 权重数组
-				weightArr: [],
-				
 				// 以下为业务需求有关示例数据
-				// 金币余额
-				goldCoin: 50,
 				// 当日免费抽奖次数余额
 				freeNum: 10,
-				// 每次消耗的金币数
-				goldNum: 20,
-				// 每天免费抽奖次数
-				freeNumDay: 2,
 				
 				// 以下是
 				// 活动规则开关控制
 				activityRules: false,
 				// 弹窗控制
 				popupShow: false,
+				// 抽到VIP碎片弹窗控制
+				popupVIPShow: false,
+				// 抽到12碎片弹窗控制
+				popup12Show: false,
+				// 抽到金币弹窗控制
+				popupGoldShow: false,
 				
 				openId: '',
 				mpData: {},
@@ -186,6 +230,26 @@
 				luckyDay: {}, // 中奖信息
 				doubleKey: "", // 领取key
 				clearTime: "", // 碎片有效期
+				scale: 1,
+				animation: null,  // 动画实例
+				animationData: null, // 动画
+				animationDatas: [null, null, null, null, null, null, null, null], // 动画组
+				animationDataTs: null,
+				prizeType: 3, // 奖品类型
+				durationMath: 20,  // 防止动画每次都一样
+				durationMath1: 20,
+				durationMath2: 20,
+				goldData: [
+					{top: '404rpx', left: '300rpx'},
+					{top: '434rpx', left: '240rpx'},
+					{top: '430rpx', left: '398rpx'},
+					{top: '448rpx', left: '424rpx'},
+					{top: '380rpx', left: '412rpx'},
+					{top: '332rpx', left: '332rpx'},
+					{top: '356rpx', left: '240rpx'},
+					{top: '474rpx', left: '294rpx'}
+				],
+				tsTitle: '',   //提示信息
 			}
 		},
 		computed: {
@@ -197,9 +261,11 @@
 			// 请求奖品数据
 			this.mpData = options
 			this.getData()
+			this.animation = uni.createAnimation({ timingFunction: 'ease' })
 		},
 		onUnload() {
 			uni.hideLoading()
+			timer && clearInterval(timer)
 		},
 		onShareAppMessage() {},
 		filters: {
@@ -223,7 +289,102 @@
 			await this.getList()
 			uni.stopPullDownRefresh();
 		},
+		watch: {
+			// 监听获奖序号的变动
+			popupShow(newVal, oldVal) {
+				this.openAniBt(newVal)
+			},
+			popupVIPShow(newVal) {
+				this.openAniBt(newVal)
+			},
+			popup12Show(newVal) {
+				this.openAniBt(newVal)
+			},
+			popupGoldShow(newVal) {
+				this.openAniBt(newVal)
+			}
+		},
 		methods: {
+			// 是否开始呼吸开关动画
+			openAniBt(val) {
+				if(val) {
+					timer = setInterval(() => {
+						if(this.scale === 1) {
+							this.scale = 0.92
+						}else {
+							this.scale = 1
+						}
+					}, 500)
+				} else {
+					timer && clearInterval(timer)
+				}
+			},
+			// 开始动画 12 vip 碎片
+			startAni(prizeType = 3) {
+				if(prizeType === 3 || prizeType === 2) {
+					this.prizeType = prizeType
+					this.startTsAni(false)
+					let index = this.prizeCountDtoList.findIndex(item => item.prizeType === prizeType)
+					let left = index !== -1 ? index === 0 ? '150rpx' : '500rpx' : '500rpx'
+					this.animation.opacity(1).step({ duration: this.durationMath })
+					if( this.durationMath >= 50 ) {
+						this.durationMath = 20
+					} else {
+						this.durationMath = this.durationMath + 1
+					}
+					this.animation.top('1300rpx').left(left).step({ duration: 1200, delay: 100 })
+					this.animation.opacity(0).top('453rpx').left('331rpx').step({ duration: 0 })
+					this.animationData = this.animation.export()
+				}
+			},
+			startGold(watchVideos) {
+				this.prizeType = 1
+				this.startTsAni(watchVideos)
+				if( this.durationMath1 >= 50 ) {
+					this.durationMath1 = 20
+				} else {
+					this.durationMath1 = this.durationMath1 + 1
+				}
+				this.animationDatas = this.goldData.map(item => {
+					let animation = uni.createAnimation({ timingFunction: 'ease' })
+					animation.opacity(1).step({ duration: this.durationMath1 })
+					animation.top('76rpx').left('60rpx').step({ duration: Math.floor(Math.random() * 101) + 1000, delay: 100 })  //  
+					animation.opacity(0).top(item.top).left(item.left).step({ duration: 0 })
+					return animation.export()
+				})
+			},
+			startTsAni(watchVideos) {
+				if(this.prizeType === 1) {
+					if (watchVideos) {
+						this.tsTitle = '+' + (this.luckyDay.prizeCount * 2) + this.luckyDay.prizeName
+					} else {
+						this.tsTitle = '+' + this.luckyDay.name
+					}
+				} else {
+					this.tsTitle = this.luckyDay.prizeName + '+1'
+				}
+				if( this.durationMath2 >= 50 ) {
+					this.durationMath2 = 20
+				} else {
+					this.durationMath2 = this.durationMath2 + 1
+				}
+				let animation = uni.createAnimation({ timingFunction: 'ease' })
+				animation.opacity(1).step({ duration: this.durationMath2 })
+				animation.top('250rpx').step({ duration: 1000, delay: 100 })
+				animation.opacity(0).top('450rpx').step({ duration: 0 })
+				this.animationDataTs = animation.export()
+			},
+			// 再次抽奖
+			againLuckDraw(type) {
+				if (type === 'vip') {
+					this.popupVIPShow = false
+				} else if (type === '12') {
+					this.popup12Show = false
+				} else {
+					this.popupGoldShow = false
+				}
+				this.handleDrawStart()
+			},
 			// 看视频双倍
 			lookVideo() {
 				this.receiveGold(true)
@@ -232,6 +393,7 @@
 			receiveGold(watchVideos = false) {
 				if(this.doubleKey) {
 					setReceive({appId: config.appid, doubleKey: this.doubleKey, openId: this.openId, watchVideos, ...this.mpData }).then(res => {
+						this.startGold(watchVideos)
 						this.popupShow = false
 						this.doubleKey = ""
 						this.getList()
@@ -346,7 +508,10 @@
 								name: item.prizeCount + item.prizeName,
 								stock: 100,
 								weight: 10,
-								prizeImage
+								prizeImage,
+								prizeType: item.prizeType,
+								prizeCount: item.prizeCount,
+								prizeName: item.prizeName,
 							}
 						} else {
 							prizeImage = '/static/turntable_iPhone12.png'
@@ -358,7 +523,10 @@
 								name: item.prizeName,
 								stock: 100,
 								weight: 10,
-								prizeImage
+								prizeImage,
+								prizeType: item.prizeType,
+								prizeCount: item.prizeCount,
+								prizeName: item.prizeName,
 							}
 						}
 					})
@@ -420,13 +588,13 @@
 				// 旋转结束后,开始处理拿到结果后的逻辑
 				this.prizeing = false
 				let prizeName = this.prizeList[this.prizeIndex].name
-				
+				let { prizeType, prizeCount } = this.prizeList[this.prizeIndex]
+				this.luckyDay = this.prizeList[this.prizeIndex]
 				let tipContent = ''
 				if (prizeName === '谢谢参与') {
 					tipContent = '很遗憾,没有中奖,请再接再厉!'
 				} else if (prizeName.indexOf('碎片') === -1 && this.freeNum >= 8) {
 					this.popupShow = true
-					this.luckyDay = this.prizeList[this.prizeIndex]
 					return
 				} else {
 					// 如果奖品设有库存
@@ -434,13 +602,15 @@
 						let prizeStock = this.prizeList[this.prizeIndex].stock
 						tipContent = prizeStock ? `恭喜您,获得 ${prizeName}` : `很抱歉,您来晚了,当前奖品 ${prizeName} 已无库存`
 					} else {
-						tipContent = `恭喜您,获得 ${prizeName} !`
+						if (prizeType === 1) {
+							this.popupGoldShow = true
+						} else if (prizeType === 2) {
+							this.popupVIPShow = true
+						} else if (prizeType === 3) {
+							this.popup12Show = true
+						}
 					}
 				}
-				uni.showModal({
-					content: tipContent,
-					showCancel: false
-				})
 				this.getList()
 			},
 			// 抽奖转盘绘制完成
@@ -448,7 +618,7 @@
 				console.log('抽奖转盘绘制完成', res)
 				uni.showToast({
 					title: res.msg,
-					duration: 3000,
+					duration: 800,
 					mask: true,
 					icon: 'none'
 				})
@@ -469,6 +639,7 @@
 	}
 	
 	.luckyDrawContent {
+		overflow-x: hidden;
 		position: absolute;
 		top: 0;
 		width: 100%;
@@ -781,9 +952,9 @@
 						
 						.reward {
 							height: 60rpx;
-							background: #FFD9A2;
-							border-radius: 31rpx;
-							font-size: 32rpx;
+							// background: #FFD9A2;
+							// border-radius: 31rpx;
+							font-size: 50rpx;
 							font-weight: 400;
 							display: inline-block;
 							padding: 0 32rpx;
@@ -792,10 +963,20 @@
 							margin-top: 20rpx;
 						}
 						
+						.goldText {
+							font-size: 64rpx;
+							font-family: FZZZHONGJW--GB1-0, FZZZHONGJW--GB1;
+							font-weight: normal;
+							color: #FFFFFF;
+							margin-bottom: 25rpx;
+							transform: translateX(12rpx);
+						}
+						
 						.doubleBt {
-							width: 424rpx;
-							height: 84rpx;
-							margin-top: 114rpx;
+							width: 456rpx;
+							height: 104rpx;
+							margin-top: 90rpx;
+							transition: all linear .5s; 
 						}
 						
 						.bt {
@@ -804,6 +985,37 @@
 							font-weight: 400;
 							color: #FCE8CD;
 						}
+						
+						.againLuckDrawBt {
+							width: 424rpx;
+							height: 86rpx;
+							background: linear-gradient(180deg, #FDDEA5 0%, #FFC981 75%, #FFC983 100%);
+							border-radius: 43rpx;
+							font-size: 36rpx;
+							font-family: SourceHanSansCN-Medium, SourceHanSansCN;
+							font-weight: 500;
+							color: #854007;
+							text-align: center;
+							line-height: 86rpx;
+							margin: 0 auto 40rpx;
+							transition: all linear .5s;
+						}
+						.btGold {
+							width: 448rpx;
+							height: 104rpx;
+							border-radius: 52rpx;
+							line-height: 104rpx;
+							font-size: 40rpx;
+							box-shadow: 0px 2rpx 8rpx 4rpx rgba(183, 2, 2, 0.37);
+							background: linear-gradient(180deg, #FFFCBE 0%, #F87527 100%);
+						}
+						.btVip {
+							width: 426rpx;
+							height: 88rpx;
+							background: linear-gradient(180deg, #F6E5CA 0%, #EDC388 100%);
+							box-shadow: 0rpx 6rpx 16rpx 0rpx rgba(162, 58, 20, 0.77);
+							border-radius: 44rpx;
+						}
 					}
 				}
 				&>.close {
@@ -813,5 +1025,35 @@
 				}
 			}
 		}
+	
+		// 碎片飞行初始样式 // 金币飞行
+		.fragmentAni, .fragmentGold {
+			position: absolute;
+			z-index: 100;
+			top: 453rpx;
+			left: 330rpx;
+			opacity: 0;
+			&>image {
+				width: 100rpx;
+				height: 100rpx;
+			}
+		}
+		.fragmentGold {
+			// opacity: 1;
+		}
+		
+		.receiveTs {
+			position: absolute;
+			border: 2rpx solid rgb(242, 69, 69);
+			top: 450rpx;
+			z-index: 100;
+			color: #FFFFFF;
+			left: 50%;
+			transform: translateX(-50%);
+			padding: 10rpx 20rpx;
+			background-color: rgba(131, 37, 37, 0.6);
+			border-radius: 5rpx;
+			opacity: 0;
+		}
 	}
 </style>

+ 1 - 1
pages/officialAccount/officialAccount.vue

@@ -13,7 +13,7 @@
 			}
 		},
 		onLoad() {
-			getUrl().then(res => {
+			getUrl({appId: config.appid}).then(res => {
 				this.url = res.data
 			})
 		},

BIN
static/12Back.png


BIN
static/doubleBt.png


BIN
static/goldBack.png


BIN
static/vipBack.png


+ 3 - 5
uni_modules/almost-lottery/components/almost-lottery/almost-lottery.vue

@@ -264,10 +264,8 @@
 			let circleCount = 0;
 			// 初始化一个动画
 			let animation = uni.createAnimation({
-				duration: 500,
-				timingFunction: 'linear',
-				delay: 100,
-				transformOrigin: "50% 50%",
+				duration: 600,
+				timingFunction: 'linear'
 			})
 			
 			timer = setInterval(() => {
@@ -281,7 +279,7 @@
 				if(circleCount === 1000){
 					circleCount = 0
 				}
-			}, 500)
+			}, 600)
 			
 			timer1 = setInterval(() => {
 				if (this.imgType === 0) {

File diff suppressed because it is too large
+ 0 - 0
unpackage/dist/dev/.sourcemap/mp-weixin/common/main.js.map


File diff suppressed because it is too large
+ 0 - 0
unpackage/dist/dev/.sourcemap/mp-weixin/common/vendor.js.map


File diff suppressed because it is too large
+ 0 - 0
unpackage/dist/dev/.sourcemap/mp-weixin/pages/checkInRecord/checkInRecord.js.map


File diff suppressed because it is too large
+ 0 - 0
unpackage/dist/dev/.sourcemap/mp-weixin/pages/index/index.js.map


File diff suppressed because it is too large
+ 0 - 0
unpackage/dist/dev/.sourcemap/mp-weixin/pages/officialAccount/officialAccount.js.map


File diff suppressed because it is too large
+ 0 - 0
unpackage/dist/dev/.sourcemap/mp-weixin/uni_modules/almost-lottery/components/almost-lottery/almost-lottery.js.map


File diff suppressed because it is too large
+ 0 - 0
unpackage/dist/dev/.sourcemap/mp-weixin/uview-ui/components/u-column-notice/u-column-notice.js.map


File diff suppressed because it is too large
+ 0 - 0
unpackage/dist/dev/.sourcemap/mp-weixin/uview-ui/components/u-icon/u-icon.js.map


File diff suppressed because it is too large
+ 0 - 0
unpackage/dist/dev/.sourcemap/mp-weixin/uview-ui/components/u-notice-bar/u-notice-bar.js.map


File diff suppressed because it is too large
+ 0 - 0
unpackage/dist/dev/.sourcemap/mp-weixin/uview-ui/components/u-row-notice/u-row-notice.js.map


+ 8 - 20
unpackage/dist/dev/mp-weixin/common/vendor.js

@@ -10618,10 +10618,13 @@ Object.defineProperty(exports, "__esModule", { value: true });exports.default =
 Object.defineProperty(exports, "__esModule", { value: true });exports.getHome = getHome;exports.getPond = getPond;exports.getOpenId = getOpenId;exports.getBanner = getBanner;exports.getSignList = getSignList;exports.setReClaim = setReClaim;exports.setDrawGain = setDrawGain;exports.getUrl = getUrl;exports.setReceive = setReceive;exports.config = void 0;var _regenerator = _interopRequireDefault(__webpack_require__(/*! ./node_modules/@babel/runtime/regenerator */ 19));var _request = __webpack_require__(/*! @/utils/request */ 47);function _interopRequireDefault(obj) {return obj && obj.__esModule ? obj : { default: obj };}function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) {try {var info = gen[key](arg);var value = info.value;} catch (error) {reject(error);return;}if (info.done) {resolve(value);} else {Promise.resolve(value).then(_next, _throw);}}function _asyncToGenerator(fn) {return function () {var self = this,args = arguments;return new Promise(function (resolve, reject) {var gen = fn.apply(self, args);function _next(value) {asyncGeneratorStep(gen, resolve, reject, _next, _throw, "next", value);}function _throw(err) {asyncGeneratorStep(gen, resolve, reject, _next, _throw, "throw", err);}_next(undefined);});};}
 
 /**
+                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        * 大转盘小程序
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                         * wx021e792baf529aff  好运赢书券
+                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        * wxe1b04d1d8f6df382  书币礼包送不停(转盘抽奖)
+                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        * wx4e8c3f946c06c519  书币礼包领不停(转盘抽奖)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                         */
 var config = {
-  appid: 'wx021e792baf529aff' };exports.config = config;function
+  appid: 'wx4e8c3f946c06c519' };exports.config = config;function
 
 
 getHome(_x) {return _getHome.apply(this, arguments);}
@@ -10658,12 +10661,12 @@ function _setReClaim() {_setReClaim = _asyncToGenerator( /*#__PURE__*/_regenerat
 
 
 // 获取公众号文章
-function _setDrawGain() {_setDrawGain = _asyncToGenerator( /*#__PURE__*/_regenerator.default.mark(function _callee7(data) {return _regenerator.default.wrap(function _callee7$(_context7) {while (1) {switch (_context7.prev = _context7.next) {case 0:return _context7.abrupt("return", (0, _request.request)({ url: "/luck/draw/gain", data: data }));case 1:case "end":return _context7.stop();}}}, _callee7);}));return _setDrawGain.apply(this, arguments);}function getUrl() {return _getUrl.apply(this, arguments);}
+function _setDrawGain() {_setDrawGain = _asyncToGenerator( /*#__PURE__*/_regenerator.default.mark(function _callee7(data) {return _regenerator.default.wrap(function _callee7$(_context7) {while (1) {switch (_context7.prev = _context7.next) {case 0:return _context7.abrupt("return", (0, _request.request)({ url: "/luck/draw/gain", data: data }));case 1:case "end":return _context7.stop();}}}, _callee7);}));return _setDrawGain.apply(this, arguments);}function getUrl(_x8) {return _getUrl.apply(this, arguments);}
 
 
 
 // 头两次领取
-function _getUrl() {_getUrl = _asyncToGenerator( /*#__PURE__*/_regenerator.default.mark(function _callee8() {return _regenerator.default.wrap(function _callee8$(_context8) {while (1) {switch (_context8.prev = _context8.next) {case 0:return _context8.abrupt("return", (0, _request.request)({ url: "/applet/mp/url" }));case 1:case "end":return _context8.stop();}}}, _callee8);}));return _getUrl.apply(this, arguments);}function setReceive(_x8) {return _setReceive.apply(this, arguments);}function _setReceive() {_setReceive = _asyncToGenerator( /*#__PURE__*/_regenerator.default.mark(function _callee9(data) {return _regenerator.default.wrap(function _callee9$(_context9) {while (1) {switch (_context9.prev = _context9.next) {case 0:return _context9.abrupt("return",
+function _getUrl() {_getUrl = _asyncToGenerator( /*#__PURE__*/_regenerator.default.mark(function _callee8(data) {return _regenerator.default.wrap(function _callee8$(_context8) {while (1) {switch (_context8.prev = _context8.next) {case 0:return _context8.abrupt("return", (0, _request.request)({ url: "/applet/mp/url", data: data }));case 1:case "end":return _context8.stop();}}}, _callee8);}));return _getUrl.apply(this, arguments);}function setReceive(_x9) {return _setReceive.apply(this, arguments);}function _setReceive() {_setReceive = _asyncToGenerator( /*#__PURE__*/_regenerator.default.mark(function _callee9(data) {return _regenerator.default.wrap(function _callee9$(_context9) {while (1) {switch (_context9.prev = _context9.next) {case 0:return _context9.abrupt("return",
             (0, _request.request)({ url: "/luck/draw/gain/receive", data: data }));case 1:case "end":return _context9.stop();}}}, _callee9);}));return _setReceive.apply(this, arguments);}
 
 /***/ }),
@@ -10675,8 +10678,8 @@ function _getUrl() {_getUrl = _asyncToGenerator( /*#__PURE__*/_regenerator.defau
 /***/ (function(module, exports, __webpack_require__) {
 
 "use strict";
-/* WEBPACK VAR INJECTION */(function(uni) {Object.defineProperty(exports, "__esModule", { value: true });exports.request = request;var apiUrl = 'https://test.api.zanxiangnet.com/miniapp';
-
+/* WEBPACK VAR INJECTION */(function(uni) {Object.defineProperty(exports, "__esModule", { value: true });exports.request = request; // let apiUrl = 'https://test.api.zanxiangnet.com/miniapp'
+var apiUrl = 'https://api.zanxiangnet.com/miniapp';
 
 
 var isopen = false; // 控制loading
@@ -10692,21 +10695,6 @@ var hiddenLoading = function hiddenLoading() {
   isopen = false;
   uni.hideLoading();
 };
-/**
-    * 
-    */
-// interface Props {
-//     url: string,
-//     data?: any,
-//     config?: {
-//         header?: any,
-//         method?: "OPTIONS" | "GET" | "HEAD" | "POST" | "PUT" | "DELETE" | "TRACE" | "CONNECT",
-//         responseType?: "text" | "arraybuffer"
-//     },
-//     backspace?: boolean, // 是否返回上一页 默认否
-//     isLoading?: boolean,  // 是否展示loading
-//     isToast?: boolean  // 是否提示
-// }
 function request(props) {var
 
   url =

File diff suppressed because it is too large
+ 131 - 16
unpackage/dist/dev/mp-weixin/pages/index/index.js


File diff suppressed because it is too large
+ 0 - 0
unpackage/dist/dev/mp-weixin/pages/index/index.wxml


+ 75 - 6
unpackage/dist/dev/mp-weixin/pages/index/index.wxss

@@ -35,6 +35,7 @@ page {
   width: 100%;
 }
 .luckyDrawContent {
+  overflow-x: hidden;
   position: absolute;
   top: 0;
   width: 100%;
@@ -380,9 +381,7 @@ page {
 }
 .luckyDrawContent .popup .popupContent > .content > .textCon .reward {
   height: 60rpx;
-  background: #FFD9A2;
-  border-radius: 31rpx;
-  font-size: 32rpx;
+  font-size: 50rpx;
   font-weight: 400;
   display: inline-block;
   padding: 0 32rpx;
@@ -390,10 +389,21 @@ page {
   line-height: 60rpx;
   margin-top: 20rpx;
 }
+.luckyDrawContent .popup .popupContent > .content > .textCon .goldText {
+  font-size: 64rpx;
+  font-family: FZZZHONGJW--GB1-0, FZZZHONGJW--GB1;
+  font-weight: normal;
+  color: #FFFFFF;
+  margin-bottom: 25rpx;
+  -webkit-transform: translateX(12rpx);
+          transform: translateX(12rpx);
+}
 .luckyDrawContent .popup .popupContent > .content > .textCon .doubleBt {
-  width: 424rpx;
-  height: 84rpx;
-  margin-top: 114rpx;
+  width: 456rpx;
+  height: 104rpx;
+  margin-top: 90rpx;
+  -webkit-transition: all linear .5s;
+  transition: all linear .5s;
 }
 .luckyDrawContent .popup .popupContent > .content > .textCon .bt {
   margin-top: 14rpx;
@@ -401,9 +411,68 @@ page {
   font-weight: 400;
   color: #FCE8CD;
 }
+.luckyDrawContent .popup .popupContent > .content > .textCon .againLuckDrawBt {
+  width: 424rpx;
+  height: 86rpx;
+  background: -webkit-linear-gradient(top, #FDDEA5 0%, #FFC981 75%, #FFC983 100%);
+  background: linear-gradient(180deg, #FDDEA5 0%, #FFC981 75%, #FFC983 100%);
+  border-radius: 43rpx;
+  font-size: 36rpx;
+  font-family: SourceHanSansCN-Medium, SourceHanSansCN;
+  font-weight: 500;
+  color: #854007;
+  text-align: center;
+  line-height: 86rpx;
+  margin: 0 auto 40rpx;
+  -webkit-transition: all linear .5s;
+  transition: all linear .5s;
+}
+.luckyDrawContent .popup .popupContent > .content > .textCon .btGold {
+  width: 448rpx;
+  height: 104rpx;
+  border-radius: 52rpx;
+  line-height: 104rpx;
+  font-size: 40rpx;
+  box-shadow: 0px 2rpx 8rpx 4rpx rgba(183, 2, 2, 0.37);
+  background: -webkit-linear-gradient(top, #FFFCBE 0%, #F87527 100%);
+  background: linear-gradient(180deg, #FFFCBE 0%, #F87527 100%);
+}
+.luckyDrawContent .popup .popupContent > .content > .textCon .btVip {
+  width: 426rpx;
+  height: 88rpx;
+  background: -webkit-linear-gradient(top, #F6E5CA 0%, #EDC388 100%);
+  background: linear-gradient(180deg, #F6E5CA 0%, #EDC388 100%);
+  box-shadow: 0rpx 6rpx 16rpx 0rpx rgba(162, 58, 20, 0.77);
+  border-radius: 44rpx;
+}
 .luckyDrawContent .popup .popupContent > .close {
   width: 54rpx;
   height: 54rpx;
   margin-top: 76rpx;
 }
+.luckyDrawContent .fragmentAni, .luckyDrawContent .fragmentGold {
+  position: absolute;
+  z-index: 100;
+  top: 453rpx;
+  left: 330rpx;
+  opacity: 0;
+}
+.luckyDrawContent .fragmentAni > image, .luckyDrawContent .fragmentGold > image {
+  width: 100rpx;
+  height: 100rpx;
+}
+.luckyDrawContent .receiveTs {
+  position: absolute;
+  border: 2rpx solid #f24545;
+  top: 450rpx;
+  z-index: 100;
+  color: #FFFFFF;
+  left: 50%;
+  -webkit-transform: translateX(-50%);
+          transform: translateX(-50%);
+  padding: 10rpx 20rpx;
+  background-color: rgba(131, 37, 37, 0.6);
+  border-radius: 5rpx;
+  opacity: 0;
+}
 

+ 1 - 1
unpackage/dist/dev/mp-weixin/pages/officialAccount/officialAccount.js

@@ -143,7 +143,7 @@ var _api = __webpack_require__(/*! @/api/api.js */ 46); //
 //
 var _default = { data: function data() {return { url: '' };},
   onLoad: function onLoad() {var _this = this;
-    (0, _api.getUrl)().then(function (res) {
+    (0, _api.getUrl)({ appId: _api.config.appid }).then(function (res) {
       _this.url = res.data;
     });
   },

+ 3 - 6
unpackage/dist/dev/mp-weixin/project.config.json

@@ -5,27 +5,24 @@
   },
   "setting": {
     "urlCheck": false,
-    "es6": true
+    "es6": true,
+    "minified": false
   },
   "compileType": "miniprogram",
   "libVersion": "",
-  "appid": "wx021e792baf529aff",
+  "appid": "wx4e8c3f946c06c519",
   "projectname": "qc-luckyDraw",
   "condition": {
     "search": {
-      "current": -1,
       "list": []
     },
     "conversation": {
-      "current": -1,
       "list": []
     },
     "game": {
-      "current": -1,
       "list": []
     },
     "miniprogram": {
-      "current": -1,
       "list": []
     }
   }

BIN
unpackage/dist/dev/mp-weixin/static/12Back.png


BIN
unpackage/dist/dev/mp-weixin/static/doubleBt.png


BIN
unpackage/dist/dev/mp-weixin/static/goldBack.png


BIN
unpackage/dist/dev/mp-weixin/static/vipBack.png


+ 3 - 5
unpackage/dist/dev/mp-weixin/uni_modules/almost-lottery/components/almost-lottery/almost-lottery.js

@@ -380,10 +380,8 @@ var systemInfo = uni.getSystemInfoSync();var timer = null,timer1 = null;var _def
     var circleCount = 0;
     // 初始化一个动画
     var animation = uni.createAnimation({
-      duration: 500,
-      timingFunction: 'linear',
-      delay: 100,
-      transformOrigin: "50% 50%" });
+      duration: 600,
+      timingFunction: 'linear' });
 
 
     timer = setInterval(function () {
@@ -397,7 +395,7 @@ var systemInfo = uni.getSystemInfoSync();var timer = null,timer1 = null;var _def
       if (circleCount === 1000) {
         circleCount = 0;
       }
-    }, 500);
+    }, 600);
 
     timer1 = setInterval(function () {
       if (_this.imgType === 0) {

+ 2 - 17
utils/request.js

@@ -1,5 +1,5 @@
-let apiUrl = 'https://test.api.zanxiangnet.com/miniapp'
-
+// let apiUrl = 'https://test.api.zanxiangnet.com/miniapp'
+let apiUrl = 'https://api.zanxiangnet.com/miniapp'
 
 
 let isopen = false  // 控制loading
@@ -15,21 +15,6 @@ const hiddenLoading = () => {
     isopen = false
     uni.hideLoading()
 }
-/**
- * 
- */
-// interface Props {
-//     url: string,
-//     data?: any,
-//     config?: {
-//         header?: any,
-//         method?: "OPTIONS" | "GET" | "HEAD" | "POST" | "PUT" | "DELETE" | "TRACE" | "CONNECT",
-//         responseType?: "text" | "arraybuffer"
-//     },
-//     backspace?: boolean, // 是否返回上一页 默认否
-//     isLoading?: boolean,  // 是否展示loading
-//     isToast?: boolean  // 是否提示
-// }
 export function request(props) {
 	let {
 		url,

Some files were not shown because too many files changed in this diff