2312970463@qq.com 4 years ago
parent
commit
08c2d4e7b1
4 changed files with 505 additions and 3 deletions
  1. 24 0
      pages.json
  2. 200 3
      pages/donate/donateDetail.vue
  3. 178 0
      pages/donate/idonate.vue
  4. 103 0
      pages/donate/progress.vue

+ 24 - 0
pages.json

@@ -737,6 +737,30 @@
 				// #endif
 				"navigationBarTitleText": "捐赠详情"
 			
+			}
+		},
+		{
+			"path": "pages/donate/progress",
+			"style": {
+				// #ifndef MP
+				"app-plus": {
+					"titleNView": false
+				},
+				// #endif
+				"navigationBarTitleText": "详情进展"
+			
+			}
+		},
+		{
+			"path": "pages/donate/idonate",
+			"style": {
+				// #ifndef MP
+				"app-plus": {
+					"titleNView": false
+				},
+				// #endif
+				"navigationBarTitleText": "我要捐赠"
+			
 			}
 		}
 	],

+ 200 - 3
pages/donate/donateDetail.vue

@@ -99,22 +99,64 @@
 			<view class="feedback-content">
 				<view class="overall" v-if="navCurrentIndex === 0">
 					<view class="title">
-						
+						项目整体反馈
 					</view>
 					<view class="content">
 						截止2021年6月10日,荆州市红十字会已将捐赠的消毒液1120瓶和帐篷200顶,500箱矿泉水全数发往阳光福利院。
 					</view>
 				</view>
+				<view class="feedback-item">
+					<view class="item-top">
+						<image src="" mode=""></image>
+						<view class="item-name-time">
+							<view class="item-name">荆州捐赠</view>
+							<view class="item-time">2021年06月10日 22:25:14</view>
+						</view>
+					</view>
+					<view class="item-content">
+						<text>荆州XXXX有限分公司</text>2021年6月10日,荆州市红十字会已将贵公司捐赠的消毒液1120瓶和帐篷200顶,发往阳光福利院。
+					</view>
+				</view>
 			</view>
 		</view>
 		<view class="btn-wrapper flex">
-			<view class="btn1 btn">
+			<view class="btn1 btn" @click="navTo('/pages/donate/progress')">
 				实时进展
 			</view>
-			<view class="btn2 btn">
+			<view class="btn2 btn" @click="want()">
 				我要捐款
 			</view>
 		</view>
+		<uni-popup ref="popup" type="center">
+			<view  class="type-box">
+				<view class="box-title">捐款类型</view>
+				<view class="box-tip">请选择您的捐赠身份类型</view>
+				<view class="box-btn" @click="chooseType(0)">
+					<image src="" mode=""></image>
+					<view class="btn-title" >
+						个人捐赠
+					</view>
+					<view class="qq" :class="{'action': jxType === 0}">
+						<view class="yx">
+							
+						</view>
+					</view>
+				</view>
+				<view class="box-btn" @click="chooseType(1)">
+					<image src="" mode=""></image>
+					<view class="">
+						企业(团队)捐赠
+					</view>
+					<view class="qq"  :class="{'action': jxType === 1}">
+						<view class="yx">
+						</view>
+					</view>
+				</view>
+				<view class="qr" @click="qr()">
+					确认
+				</view>
+			</view>
+		</uni-popup>
 	</view>
 </template>
 
@@ -126,14 +168,30 @@ export default {
 			currentIndex: 0,
 			swiperHeight: 0,
 			navCurrentIndex: 0,
+			jxType: 0,
 		};
 	},
 	methods: {
+		navTo(url) {
+			uni.navigateTo({
+				url: url
+			})
+		},
 		navClick(index) {
 			this.currentIndex = index;
 		},
 		lookmore(index) {
 			this.navCurrentIndex = index
+		},
+		want() {
+			this.$refs.popup.open()
+		},
+		chooseType(index) {
+			this.jxType = index
+		},
+		qr() {
+			this.$refs.popup.close()
+			this.navTo('/pages/donate/idonate?type=' + this.jxType )
 		}
 		
 	}
@@ -355,6 +413,12 @@ page {
 				background: #FA7E67;
 				box-shadow: 0px 0px 10rpx 0rpx rgba(0, 0, 0, 0.1);
 				border-radius: 10rpx 10rpx 0px 0px;
+				font-size: 28rpx;
+				font-family: PingFang SC;
+				font-weight: bold;
+				color: #FFFFFF;
+				line-height: 75rpx;
+				padding-left: 17rpx;
 			}
 			.content {
 				padding: 33rpx 36rpx 43rpx 30rpx;
@@ -369,6 +433,139 @@ page {
 				line-height: 42rpx;
 			}
 		}
+		.feedback-item {
+			margin: 20rpx auto;
+			// display: flex;
+			background-color: #fff;
+			box-shadow: 0px 0px 10rpx 0px rgba(0, 0, 0, 0.1);
+			border-radius: 10rpx 10rpx 10rpx;
+			.item-top {
+				height: 118rpx;
+				border-radius: 10px 10px 0 0;
+				border-bottom: 1px solid #ECECEC;
+				padding: 25rpx 0 0 17rpx;
+				display: flex;
+				image {
+					width: 77rpx;
+					height: 77rpx;
+					border-radius: 50%;
+					background-color: red;
+					margin-right: 12rpx;
+				}
+				.item-name-time {
+					.item-name {
+						font-size: 28rpx;
+						font-family: PingFang SC;
+						font-weight: bold;
+						color: #333333;
+						line-height: 35rpx;
+					}
+					.item-time {
+						font-size: 24rpx;
+						font-family: PingFang SC;
+						font-weight: 500;
+						color: #999999;
+						line-height: 50rpx;
+					}
+				}
+			}
+			.item-content {
+				padding: 25rpx 47rpx 40rpx 30rpx;
+				border-radius: 0 0 10rpx 10rpx;
+				font-size: 26rpx;
+				font-family: PingFang SC;
+				font-weight: 500;
+				color: #999;
+				line-height: 42rpx;
+				text {
+					color: #E80000;
+					font-weight: bold;
+				}
+			}
+		}
+	}
+}
+.type-box {
+	width: 542rpx;
+	height: 575rpx;
+	// background: linear-gradient(0deg, rgba(249, 98, 105, 0.06), rgba(255, 255, 255, 0.06));
+	border-radius: 20rpx;
+	background-color: #fff;
+	position: relative;
+	.box-title {
+		text-align: center;
+		font-size: 36rpx;
+		font-family: PingFang SC;
+		font-weight: bold;
+		color: #333333;
+		line-height: 1;
+		padding-top: 77rpx;
+	}
+	.box-tip {
+		text-align: center;
+		font-size: 24rpx;
+		font-family: PingFang SC;
+		font-weight: 500;
+		color: #808080;
+		line-height: 1;
+		padding-top: 12rpx;
+		margin-bottom: 43rpx;
+	}
+	.box-btn {
+		margin: 0 auto;
+		width: 460rpx;
+		height: 95rpx;
+		display: flex;
+		align-items: center;
+		border-bottom: 1px solid #f3efef;
+		position: relative;
+		image {
+			height: 43rpx;
+			width: 43rpx;
+			background-color: red;
+			margin-right: 15rpx;
+		}
+		.qq {
+			width: 32rpx;
+			height: 32rpx;
+			border: 1px solid #808080;
+			opacity: 0.5;
+			border-radius: 50%;
+			position: absolute;
+			right: 0;
+		}
+		.action {
+			border-color: #FA7E67;
+			// position: relative;
+			.yx {
+				
+				width: 20rpx;
+				height: 20rpx;
+				background: #FA7E67;
+				// border: 1px solid #FA7E67;
+				border-radius: 50%;
+				position: absolute;
+				top: 0;
+				bottom: 0;
+				left: 0;
+				right: 0;
+				margin: auto;
+			}
+		}
+	}
+	.qr {
+		width: 460rpx;
+		height: 71rpx;
+		background: #FA7E67;
+		box-shadow: 0px 16rpx 16rpx 0px rgba(250, 126, 103, 0.5);
+		border-radius: 10rpx;
+		font-size: 28rpx;
+		font-family: PingFang SC;
+		font-weight: 500;
+		color: #FFFFFF;
+		text-align: center;
+		line-height: 71rpx;
+		margin: 62rpx auto 0;
 	}
 }
 </style>

+ 178 - 0
pages/donate/idonate.vue

@@ -0,0 +1,178 @@
+<template>
+	<view class="idonate">
+		<view class="one" v-show="limit === 1">
+			<view class="item">
+				捐赠个体<text>*</text>
+				<radio-group @change="typeChange" class="check-box">
+					<label  v-for="(item, index) in items" :key="item.value">
+						<radio :value="item.iid" :checked="index === type" color="#f3392c" style="transform:scale(0.7)" />
+						<text>{{ item.value }}</text>
+					</label>
+				</radio-group>
+			</view>
+			<view class="item">
+				捐赠单位<text>*</text>
+				<input type="text" :value="unit" placeholder="请填写捐赠单位"/>
+			</view>
+			<view class="item">
+				单位联系人 <text>*</text>
+				<input type="text" :value="people" placeholder="请填写捐赠方联系人"/>
+			</view>
+			<view class="item">
+				单位电话 <text>*</text>
+				<input type="text" :value="people" placeholder="请填写单位联系方式"/>
+			</view>
+		</view>
+		<view class="tow" v-show="limit === 2">
+			
+		</view>
+		<view class="jg">
+			
+		</view>
+		<view class="btn">
+			<view class="next" v-show="limit === 1" @click="nextLimit()">
+				下一页
+			</view>
+			<view class="prev" v-show="limit === 2" @click="prevLimit()">
+				上一步
+			</view>
+			<view class="sub" v-show="limit === 2">
+				提交
+			</view>
+		</view>
+	</view>
+</template>
+
+<script>
+	export default {
+		data() {
+			return {
+				items: [
+					{
+						value: '企业(团体)',
+						iid: '0'
+					},
+					{
+						value: '个人',
+						iid: '1'
+					}
+				],
+				limit: 1,
+				type: 0,//捐赠个体 1位个人 0为团体(企业)
+				unit: '',//捐赠单位
+				people: '',//捐赠方联系人或姓名
+				phone: '',//单位电话或联系电话
+			}
+		},
+		onLoad(ops) {
+			if(ops) {
+				this.type = ops.type*1
+				console.log(this.type)
+			}
+			
+		},
+		methods: {
+			nextLimit() {
+				this.limit = 2
+			},
+			prevLimit() {
+				this.limit = 1
+			},
+			typeChange(evt) {
+				console.log(evt)
+				this.type = evt.detail.value.
+			}
+		}
+	}
+</script>
+
+<style lang="scss" scoped>
+	.idonate {
+		padding: 0 30rpx;
+		margin-top: 20rpx;
+		background-color: #fff;
+	}
+	.btn {
+		
+		height: 196rpx;
+		width: 100%;
+		text-align: center;
+		display: flex;
+		justify-content: center;
+		line-height: 75rpx;
+		.next {
+			width: 478rpx;
+			height: 75rpx;
+			// margin: 0 auto;
+			background: #FA7E67;
+			border-radius: 35rpx;
+			color: #fff;
+			font-size: 32rpx;
+			font-family: PingFang SC;
+			font-weight: 500;
+			color: #FFFFFF;
+		}
+		.prev {
+			width: 264rpx;
+			height: 75rpx;
+			border: 1px solid #FA7E67;
+			border-radius: 35rpx;
+			font-size: 32rpx;
+			font-family: PingFang SC;
+			font-weight: 500;
+			color: #FA7E67;
+			margin-right: 60rpx;
+			line-height: 70rpx;
+		}
+		.sub {
+			width: 264rpx;
+			height: 75rpx;
+			background: #FA7E67;
+			border-radius: 35rpx;
+			font-size: 32rpx;
+			font-family: PingFang SC;
+			font-weight: 500;
+			color: #FFFFFF;
+			line-height: 70rpx;
+		}
+	}
+	// .check-protocol uni-checkbox .uni-checkbox-input{
+	// 		width: 25rpx;
+	// 		height: 25rpx;
+	// 		border-radius: 0;
+	// 		border: 1rpx solid #C1C1C1;
+	// 	}
+	// 	/* 选中后的 背景样式  */
+	// 	.check-protocol uni-checkbox .uni-checkbox-input.uni-checkbox-input-checked{
+	// 		position: relative;
+	// 		border: 1rpx solid #C1C1C1;
+	// 		width: 25rpx;
+	// 		height: 25rpx;
+	// 	}
+	// 	/* 选中后的*/
+	// 	.check-protocol uni-checkbox .uni-checkbox-input.uni-checkbox-input-checked::before{
+	// 		position: absolute;
+	// 		left: 50%;
+	// 		top: 50%;
+	// 		content: '';
+	// 		width: 19rpx!important;
+	// 		height: 19rpx!important;;
+	// 		background-color: #3AAF4A;
+	// 		transform: translate(-50%,-50%);
+	// 	}
+	.item {
+		display: flex;
+		align-items: center;
+		height: 102rpx;
+		border-bottom: 1px #ECECEC solid;
+		font-size: 30rpx;
+		font-family: PingFang SC;
+		font-weight: 500;
+		color: #222222;
+	}
+	.check-box {
+		
+		display: flex;
+		display: inline-block;
+	}
+</style>

+ 103 - 0
pages/donate/progress.vue

@@ -0,0 +1,103 @@
+<template>
+	<view class="progress">
+		<view class="top">
+			<view class="top-t">
+				<view class="top-item">
+					<image src="" mode=""></image>
+					<view class="item-tit">
+						1.项目创建
+					</view>
+				</view>
+				<view class="top-item">
+					<image src="" mode=""></image>
+					<view class="item-tit">
+						2.项目审核
+					</view>
+				</view>
+				<view class="top-item">
+					<image src="" mode=""></image>
+					<view class="item-tit">
+						3.捐赠响应
+					</view>
+				</view>
+				<view class="top-item">
+					<image src="" mode=""></image>
+					<view class="item-tit">
+						4.捐赠审核
+					</view>
+				</view>
+			</view>
+			<view class="top-t">
+				<view class="top-item">
+					<image src="" mode=""></image>
+					<view class="item-tit">
+						5.捐赠品入库
+					</view>
+				</view>
+				<view class="top-item">
+					<image src="" mode=""></image>
+					<view class="item-tit">
+						6.捐赠品出库
+					</view>
+				</view>
+				<view class="top-item">
+					<image src="" mode=""></image>
+					<view class="item-tit">
+						7.发往受捐者
+					</view>
+				</view>
+				<view class="top-item">
+					<image src="" mode=""></image>
+					<view class="item-tit">
+						8.受捐者反馈
+					</view>
+				</view>
+			</view>
+		</view>
+		<view class="">
+			
+		</view>
+	</view>
+</template>
+
+<script>
+</script>
+
+<style lang="scss" scoped>
+	.top {
+		padding: 40rpx 0;
+		background-color: #fff;
+		margin: 20rpx 0;
+		.top-t{
+			display: flex;
+			justify-content: space-between;
+			padding: 0 55rpx;
+			.top-item {
+				width: 160rpx;
+				display: flex;
+				flex-direction: column;
+				justify-content: center;
+				align-items: center;
+				margin-bottom: 30rpx;
+				image {
+					width: 115rpx;
+					height: 115rpx;
+					background: #FFFFFF;
+					border: 1px solid #DADADA;
+					box-shadow: 0px 0px 10px 0px rgba(0, 0, 0, 0.1);
+					border-radius: 14px;
+					margin-bottom: 15rpx;
+				}
+				.item-tit {
+					font-size: 24rpx;
+					font-family: PingFang SC;
+					font-weight: 500;
+					color: #333333;
+					line-height: 1;
+				}
+				
+			}
+		}
+		
+	}
+</style>