Commit 1292e05c authored by sujie@126.com's avatar sujie@126.com

dd

parent de5ef7e0
...@@ -62,10 +62,11 @@ WussComponent({ ...@@ -62,10 +62,11 @@ WussComponent({
"s":"00" "s":"00"
}, },
downTime:99, downTime:99,
localImageRoot: '../../images/',
}, },
attached () { attached () {
if (this.data.isRead > 0) { if (this.data.isRead > 0) {
this._downTime() // this._downTime()
} }
}, },
detached() { detached() {
...@@ -99,7 +100,7 @@ WussComponent({ ...@@ -99,7 +100,7 @@ WussComponent({
_startTime() { _startTime() {
clearInterval(this.timer); clearInterval(this.timer);
this.timer = setInterval(() => { this.timer = setInterval(() => {
console.log('启动了分钟的计时器'); // console.log('启动了分钟的计时器');
this._timer(); this._timer();
}, 1e3); }, 1e3);
this._timer(); this._timer();
...@@ -107,7 +108,7 @@ WussComponent({ ...@@ -107,7 +108,7 @@ WussComponent({
_downTime(){ _downTime(){
clearInterval(this.downtimer); clearInterval(this.downtimer);
this.downtimer = setInterval(() => { this.downtimer = setInterval(() => {
console.log('启动了毫秒的计时器'); // console.log('启动了毫秒的计时器');
this.setData({ this.setData({
downTime:Number(this.data.downTime)-1>=0?(Number(this.data.downTime)-1>=10?Number(this.data.downTime)-1:'0'+(Number(this.data.downTime)-1)):99 downTime:Number(this.data.downTime)-1>=0?(Number(this.data.downTime)-1>=10?Number(this.data.downTime)-1:'0'+(Number(this.data.downTime)-1)):99
}) })
...@@ -157,7 +158,7 @@ WussComponent({ ...@@ -157,7 +158,7 @@ WussComponent({
case 'H': case 'H':
return `${h}:${mm}:${s}`; return `${h}:${mm}:${s}`;
case 'MM': case 'MM':
return `${mm}:${s}`; return `${h}:${mm}:${s}`;
case 's': case 's':
return s; return s;
case 'd': case 'd':
......
...@@ -13,7 +13,7 @@ ...@@ -13,7 +13,7 @@
</view> </view>
<view class="down" > <view class="down" >
{{downTime}}
</view> </view>
</view> </view>
<view class="clock-cut" wx:if="{{isRead==2}}"> <view class="clock-cut" wx:if="{{isRead==2}}">
...@@ -23,7 +23,7 @@ ...@@ -23,7 +23,7 @@
<view class="maohao" >:</view> <view class="maohao" >:</view>
<view class="time" >{{timedate.s}}</view> <view class="time" >{{timedate.s}}</view>
<view class="maohao" >:</view> <view class="maohao" >:</view>
<view class="time" >{{downTime}}</view> <view class="time" ><image class="" src="{{localImageRoot}}common/cutdown/detailCutd.gif" mode="aspectFit|aspectFill|widthFix" lazy-load="false" binderror="" bindload="" /></view>
</view> </view>
<text class="wuss-class wuss-countdown" wx:if="{{!isRead}}">{{timeText}}</text> <text class="wuss-class wuss-countdown" wx:if="{{!isRead}}">{{timeText}}</text>
\ No newline at end of file
...@@ -23,10 +23,14 @@ ...@@ -23,10 +23,14 @@
align-items: center; align-items: center;
} }
.wuss-countdown-box .down{ .wuss-countdown-box .down{
font-size:30rpx; /* font-size:30rpx;
font-family:PingFang-SC-Bold; font-family:PingFang-SC-Bold;
font-weight:bold; font-weight:bold;
color:rgba(0,0,0,1); color:rgba(0,0,0,1); */
}
.wuss-countdown-box .down image{
width: 32rpx;
height: 28rpx;
} }
.clock-cut{ .clock-cut{
display: flex; display: flex;
...@@ -48,4 +52,8 @@ ...@@ -48,4 +52,8 @@
font-size:22rpx; font-size:22rpx;
padding: 0 4rpx; padding: 0 4rpx;
font-weight:bold; font-weight:bold;
}
.clock-cut .time image{
width: 28rpx;
height: 24rpx;
} }
\ No newline at end of file
...@@ -340,27 +340,10 @@ Page({ ...@@ -340,27 +340,10 @@ Page({
code code
} = res; } = res;
if (code == 200) { if (code == 200) {
// if(!res.data){
// wx.showModal({
// title: '提示',
// content: '暂无数据,班级可能已被删除',
// showCancel:false,
// confirmText:"返回首页",
// success(res) {
// if (res.confirm) {
// wx.navigateTo({
// url:"/customer/pages/userindex/index"
// })
// }
// }
// })
// return
// }
this.schoolInfoGet(data.school_id) this.schoolInfoGet(data.school_id)
data.content = JSON.parse(data.content); data.content = JSON.parse(data.content);
// console.log(new Date(new Date().setHours(new Date().getHours() + 2)).getTime())
// console.log( new Date(res.datetime.replace(/-/g,'/')).getTime(),'44')
const StorageTime = LocalStorage.getItem(data.id + 'themeRead'); // 存储的时间 const StorageTime = LocalStorage.getItem(data.id + 'themeRead'); // 存储的时间
console.log( new Date(new Date().setMinutes(new Date().getMinutes() + data.force_num)), 'new Date().setMinutes')
this.setData({ this.setData({
themeSelect: data, themeSelect: data,
cutDownDate: StorageTime ? new Date().getTime() + StorageTime * 1000 : new Date(new Date().setMinutes(new Date().getMinutes() + data.force_num)).getTime() cutDownDate: StorageTime ? new Date().getTime() + StorageTime * 1000 : new Date(new Date().setMinutes(new Date().getMinutes() + data.force_num)).getTime()
......
...@@ -76,7 +76,7 @@ ...@@ -76,7 +76,7 @@
<form report-submit="true" bindsubmit="formIdCreate" class="createidform"> <form report-submit="true" bindsubmit="formIdCreate" class="createidform">
<button form-type="submit" class="createidbutton">生成form</button> <button form-type="submit" class="createidbutton">生成form</button>
</form> </form>
<view class="home-text" >班级</view> <view class="home-text" >首页</view>
</view> </view>
</btn-drag> </btn-drag>
</view> </view>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment