From 8764e828471d949fbc5bd27a98f0729e402cfb91 Mon Sep 17 00:00:00 2001
From: zhaoyongnian <541231643@qq.com>
Date: Wed, 3 Jun 2020 14:39:59 +0800
Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
components/activity/activity.js | 6 +-
components/activity/activity.wxml | 1 +
.../components/volunteer/volunteer.js | 11 +-
.../components/volunteer/volunteer.wxml | 2 +-
pages/heartNew/heartNew.js | 22 ++-
pages/heartNew/heartNew.wxss | 4 +-
.../heart/pages/heartDetail/heartDetail.js | 8 +-
.../heart/pages/heartDetail/heartDetail.wxml | 154 +++++++++++-------
.../heart/pages/heartDetail/heartDetail.wxss | 14 +-
9 files changed, 145 insertions(+), 77 deletions(-)
diff --git a/components/activity/activity.js b/components/activity/activity.js
index 0aff0dd..898a3d6 100644
--- a/components/activity/activity.js
+++ b/components/activity/activity.js
@@ -17,6 +17,9 @@ Component({
methods: {
getActivityList(params) {
let that = this
+ that.setData({
+ selectedTab: params.selectedTab
+ })
if (params.qkdat == true) {
console.log('清空')
that.setData({
@@ -45,6 +48,7 @@ Component({
},
toActDetail(e) {
+ console.log('selectedTab::::'+this.data.selectedTab)
const id = e.currentTarget.dataset.id
const actcurrentstate = e.currentTarget.dataset.actcurrentstate
const signupflag = e.currentTarget.dataset.signupflag
@@ -52,7 +56,7 @@ Component({
actId: id
})
wx.navigateTo({
- url: `/subpages/heart/pages/heartDetail/heartDetail?id=${id}&actcurrentstate=${actcurrentstate}&signupflag=${signupflag}`
+ url: `/subpages/heart/pages/heartDetail/heartDetail?id=${id}&actcurrentstate=${actcurrentstate}&signupflag=${signupflag}&selectedTab=${this.data.selectedTab}`
})
},
updateActivityList(params) {
diff --git a/components/activity/activity.wxml b/components/activity/activity.wxml
index 5902a09..901d62a 100644
--- a/components/activity/activity.wxml
+++ b/components/activity/activity.wxml
@@ -10,6 +10,7 @@
未开始
进行中
已结束
+ 已取消
{{item.title}}
diff --git a/pages/heartNew/components/volunteer/volunteer.js b/pages/heartNew/components/volunteer/volunteer.js
index bf3fb55..e5abc46 100644
--- a/pages/heartNew/components/volunteer/volunteer.js
+++ b/pages/heartNew/components/volunteer/volunteer.js
@@ -1,4 +1,5 @@
// pages/indexNew/components/volunteer/volunteer.js
+const app = getApp()
Component({
/**
* 组件的属性列表
@@ -21,6 +22,12 @@ Component({
* 组件的方法列表
*/
methods: {
-
- }
+ preViewImage(e) {
+ console.log(JSON.stringify(e))
+ wx.previewImage({
+ urls: [e.currentTarget.dataset.src],
+ current: e.currentTarget.dataset.src
+ })
+ }
+ },
})
diff --git a/pages/heartNew/components/volunteer/volunteer.wxml b/pages/heartNew/components/volunteer/volunteer.wxml
index e495af4..93d9683 100644
--- a/pages/heartNew/components/volunteer/volunteer.wxml
+++ b/pages/heartNew/components/volunteer/volunteer.wxml
@@ -1,5 +1,5 @@
-
+
{{volunteerItemObj.nickname}}
{{volunteerItemObj.volunteerSignature}}
diff --git a/pages/heartNew/heartNew.js b/pages/heartNew/heartNew.js
index 46d9457..edd6153 100644
--- a/pages/heartNew/heartNew.js
+++ b/pages/heartNew/heartNew.js
@@ -52,7 +52,8 @@ Page({
pageSize: this.data.pageSize,
timestamp: getTimestamp(),
actType: 0,
- qkdat: true
+ qkdat: true,
+ selectedTab:this.data.selectedTab
}
this.selectComponent("#state-0").getActivityList(parms)
},
@@ -106,7 +107,8 @@ Page({
pageSize: this.data.pageSize,
timestamp: getTimestamp(),
actType: 0,//活动列表类型(0-招募令,1-精彩活动)
- qkdat: true
+ qkdat: true,
+ selectedTab:e.currentTarget.dataset.tab
}
this.selectComponent("#state-0").getActivityList(parms)
} else if (e.currentTarget.dataset.tab == 'tab1') {
@@ -120,7 +122,6 @@ Page({
pageIndex: this.data.indexPage,
pageSize: this.data.pageSize,
}
- console.log('志愿者列表传值:'+JSON.stringify(parms))
this.volunteerlist(parms)
} else if (e.currentTarget.dataset.tab == 'tab2') {
this.setData({
@@ -132,7 +133,8 @@ Page({
pageSize: this.data.pageSize,
timestamp: getTimestamp(),
actType: 1,//活动列表类型(0-招募令,1-精彩活动)
- qkdat: true
+ qkdat: true,
+ selectedTab:e.currentTarget.dataset.tab
}
this.selectComponent("#state-2").getActivityList(parms)
} else if (e.currentTarget.dataset.tab == 'tab3') {
@@ -157,7 +159,8 @@ Page({
pageSize: 10,
timestamp: getTimestamp(),
actType: 0,
- actId: this.data.actId
+ actId: this.data.actId,
+ selectedTab:this.data.selectedTab
}
this.selectComponent("#state-0").updateActivityList(params)
} else if (this.data.selectedTab === 'tab2') {
@@ -166,7 +169,8 @@ Page({
pageSize: 10,
timestamp: getTimestamp(),
actType: 1,
- actId: this.data.actId
+ actId: this.data.actId,
+ selectedTab:this.data.selectedTab
}
this.selectComponent("#state-2").updateActivityList(params)
}
@@ -279,7 +283,8 @@ Page({
pageIndex: this.data.indexPage,
pageSize: this.data.pageSize,
timestamp: getTimestamp(),
- actType: 0
+ actType: 0,
+ selectedTab:this.data.selectedTab
}
this.selectComponent("#state-0").getActivityList(parms)
}else if(this.data.selectedTab == 'tab1'){
@@ -299,7 +304,8 @@ Page({
pageIndex: this.data.indexPage,
pageSize: this.data.pageSize,
timestamp: getTimestamp(),
- actType: 1
+ actType: 1,
+ selectedTab:this.data.selectedTab
}
this.selectComponent("#state-2").getActivityList(parms)
}
diff --git a/pages/heartNew/heartNew.wxss b/pages/heartNew/heartNew.wxss
index 81aa21f..54b4b31 100644
--- a/pages/heartNew/heartNew.wxss
+++ b/pages/heartNew/heartNew.wxss
@@ -309,7 +309,7 @@ button:last-child {
}
.tab-bar .tab {
- font-size: 30rpx;
+ font-size: 34rpx;
font-weight: 500;
color: rgba(171, 171, 171, 1);
width: 25%;
@@ -322,7 +322,7 @@ button:last-child {
}
.tab-bar .tab.select {
- font-size: 32rpx;
+ font-size: 36rpx;
font-weight: bold;
color: rgba(229, 15, 0, 1);
}
diff --git a/subpages/heart/pages/heartDetail/heartDetail.js b/subpages/heart/pages/heartDetail/heartDetail.js
index 92e774d..c04fcbc 100644
--- a/subpages/heart/pages/heartDetail/heartDetail.js
+++ b/subpages/heart/pages/heartDetail/heartDetail.js
@@ -13,6 +13,7 @@ Page({
clocks: [], //打卡列表
clockNum: 0, //打卡人次
actContent: '', //富文本
+ actNewsContent:'',//新闻稿
dialogTitle: '',
dialogContent: '',
dialogConfirmText: '',
@@ -20,13 +21,15 @@ Page({
uservolunteerflag: '',
cancelSignupVisible: false,
cancelSignupTipValue: '',
- cancelSignupTipVisible: false
+ cancelSignupTipVisible: false,
+ selectedTab:'',//用来判断详情是否显示志愿者打卡
},
onLoad: function(options) {
this.setData({
id: options.id,
actCurrentState: options.actcurrentstate,
- signupFlag: options.signupflag
+ signupFlag: options.signupflag,
+ selectedTab:options.selectedTab,
})
// this.getDetail();//活动详情
// this.clockList();//打卡列表
@@ -42,6 +45,7 @@ Page({
this.setData({
detail: res.data,
actContent: res.data.actContent.replace(/\
{{detail.title}}
-
+
+
+
@@ -91,7 +93,7 @@
-
+
@@ -111,8 +113,9 @@
3. 专业不限,具有美术教育者优先。
-->
-
-
+
+
@@ -124,74 +127,102 @@
-
-
-
-
-
-
- 志愿者打卡
-
-
- {{clockNum}}次
-
-
+
+
+
+
+
-
-
-
-
-
-
- {{item.nickname}}
- {{item.createdTime}}
+
+ -->
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 志愿者打卡
-
- {{item.clockDesc}}
+
+ {{clockNum}}次
-
+
+
+
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+ {{item.nickname}}
+ {{item.createdTime}}
+
+
+ {{item.clockDesc}}
+
+
-
-
-
+ -->
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
+
+
-
-
-
+
-
-
-
-
+
+
+
+
+
-
+
-
+
已报名 {{detail.signupNum}}人
@@ -257,7 +288,8 @@
-
+
我要打卡
更新打卡
@@ -266,8 +298,10 @@
-
+
-
+
\ No newline at end of file
diff --git a/subpages/heart/pages/heartDetail/heartDetail.wxss b/subpages/heart/pages/heartDetail/heartDetail.wxss
index 2a207db..dc79851 100644
--- a/subpages/heart/pages/heartDetail/heartDetail.wxss
+++ b/subpages/heart/pages/heartDetail/heartDetail.wxss
@@ -1,3 +1,6 @@
+page{
+ background: #f7f7f7;
+}
.container {
width: 100%;
}
@@ -143,6 +146,7 @@
font-weight: 500;
color: rgba(51, 51, 51, 1);
line-height: 54rpx;
+ word-break: break-all;
}
.bottom {
@@ -231,7 +235,6 @@
color: rgba(153, 153, 153, 1);
margin-top: 10rpx;
}
-
.info-box-volunteer {
width: 100wh;
height: auto;
@@ -239,6 +242,9 @@
padding: 26rpx 0rpx;
margin: 0rpx 22rpx;
}
+.info-box-volunteer:last-child {
+ border: none;
+}
.info-box-volunteer-last {
width: 100wh;
@@ -343,3 +349,9 @@
margin-left: 1%;
border-radius: 15rpx;
}
+/* rich-text{
+ white-space:normal;
+ overflow: hidden;
+ white-space: nowrap;
+ text-overflow: ellipsis;
+} */