feat: 电子药箱小程序 - 4Tab药品管理
- 电子药箱: 药品库存管理 + 手动录入 + 今日用药打卡 - 药品百科: 搜索 + 分类筛选 + 20种药品静态数据 - 惠教中心: 4条药品使用指南课程 - 我的: 家庭成员信息管理 - 自定义TabBar + navigation-bar组件 - SVG药品分类插图
This commit is contained in:
+1
@@ -0,0 +1 @@
|
||||
"use strict";var _luckymoneyService=require("../../../../services/luckymoney-service");Component({properties:{redPacketID:{type:Number,value:0,observer:"onRedPacketIDChange"},sdkInstance:{type:Object,value:null}},data:{count:3},lifetimes:{detached:function(){this.clearTimer()}},methods:{onRedPacketIDChange:function(e){if(!e)return this.clearTimer(),void this.setData({count:3});this.startCountdown()},clearTimer:function(){clearInterval(this.timer),this.timer=null},startCountdown:function(){var e=this;this.clearTimer(),this.setData({count:3}),this.timer=setInterval(function(){var t=e.data.count-1;if(t<=0)return e.clearTimer(),e.setData({count:0}),void e.finishCountdown();e.setData({count:t})},1e3)},finishCountdown:function(){var e,t,i,n,o,r,s=(null===(e=this.properties)||void 0===e||null===(t=e.sdkInstance)||void 0===t?void 0:t.uuid)||(null===(i=this.properties)||void 0===i?void 0:i.sdkInstance),a=null===(n=this.properties)||void 0===n?void 0:n.redPacketID;s&&a&&(null===(o=(0,_luckymoneyService.getLuckymoneyService)(s))||void 0===o||null===(r=o.finishRevealCountdown)||void 0===r||r.call(o,a))}}});
|
||||
+1
@@ -0,0 +1 @@
|
||||
{"component":true}
|
||||
+5
@@ -0,0 +1,5 @@
|
||||
<view class="trailerMask">
|
||||
<view class="trailer">
|
||||
<view class="count">{{count}}</view>
|
||||
</view>
|
||||
</view>
|
||||
+1
@@ -0,0 +1 @@
|
||||
.trailerMask{position:fixed;z-index:11010;top:0;left:0;width:100%;height:100%;background-color:rgba(0,0,0,.5)}.trailer{width:600rpx;height:925rpx;position:absolute;z-index:1;left:50%;top:50%;transform:translate(-50%,-50%);text-align:center;background-image:url(https://p3-live.byteimg.com/tos-cn-i-gjr78lqtd0/rain-trailer-2x~tplv-gjr78lqtd0-png.png);background-repeat:no-repeat;background-size:contain}.count{display:inline-block;font-size:calc(100rpx + .5 * (1rem - 16px));font-weight:700;margin-top:500rpx;color:#ff7300}
|
||||
Reference in New Issue
Block a user