Browse Source

no message

MS-CIAZDCOIXVRW\Administrator 3 years ago
parent
commit
d1070ebcaa
6 changed files with 249 additions and 130 deletions
  1. 0 1
      pages.json
  2. 8 0
      pages/bill/bill.vue
  3. 160 107
      pages/home/home.vue
  4. 31 11
      pages/index/index.vue
  5. 48 9
      pages/select/select.vue
  6. 2 2
      util/api.js

+ 0 - 1
pages.json

@@ -20,7 +20,6 @@
 				"navigationStyle": "custom"
 				"navigationStyle": "custom"
 			}
 			}
 		}
 		}
-
 		, {
 		, {
 			"path": "pages/pay/pay",
 			"path": "pages/pay/pay",
 			"style": {
 			"style": {

+ 8 - 0
pages/bill/bill.vue

@@ -838,4 +838,12 @@
 	::v-deep .uni-forms-item__label {
 	::v-deep .uni-forms-item__label {
 		width: 160rpx !important;
 		width: 160rpx !important;
 	}
 	}
+
+	::v-deep .placeholder {
+		color: #fff;
+	}
+
+	::v-deep .input-arrow {
+		border-color: #fff;
+	}
 </style>
 </style>

+ 160 - 107
pages/home/home.vue

@@ -6,72 +6,71 @@
 				<image class="picker-item-logo-left" src="../../static/room.png"></image>
 				<image class="picker-item-logo-left" src="../../static/room.png"></image>
 			</view>
 			</view>
 			<view class="picker-item-label">已选房间</view>
 			<view class="picker-item-label">已选房间</view>
-			<view class="picker-item-content">{{roomSelect}}</view>
+			<view class="picker-item-content" v-if="roomSelect=='请选择宿舍'">{{roomSelect}}</view>
+			<view class="picker-item-content2" v-else>{{roomSelect}}</view>
 			<view class="picker-item-logor">
 			<view class="picker-item-logor">
 				<image class="picker-item-logo-right" src="../../static/right.png"></image>
 				<image class="picker-item-logo-right" src="../../static/right.png"></image>
 			</view>
 			</view>
 		</view>
 		</view>
 		<!-- 账单显示区域 -->
 		<!-- 账单显示区域 -->
 		<view class="bill">
 		<view class="bill">
+			<!-- 筛选框区域 -->
+			<view class="choose">
+				<view class="time">
+					<uni-data-select :clear="false" placeholder="请选择时间" :localdata="time_range" @change="changeTime">
+					</uni-data-select>
+				</view>
+				<view class="type">
+					<uni-data-select :clear="false" placeholder="请选择支付状态" :localdata="type_range" @change="changeType">
+					</uni-data-select>
+				</view>
+			</view>
+
 			<!-- 没有账单时展示的内容 -->
 			<!-- 没有账单时展示的内容 -->
 			<view class="null" v-if="!list.length">
 			<view class="null" v-if="!list.length">
 				<img src="../../static/null.png">
 				<img src="../../static/null.png">
-				<span>暂无账单,请选择宿舍查询</span>
+				<span>暂无账单,请选择条件查询</span>
 			</view>
 			</view>
 
 
 			<!-- 有账单时展示的内容 -->
 			<!-- 有账单时展示的内容 -->
 			<view class="has" v-else>
 			<view class="has" v-else>
-				<!-- 筛选框区域 -->
-				<view class="choose">
-					<view class="time">
-						<uni-data-select placeholder="请选择时间" v-model="time_value" :localdata="time_range"
-							@change="changeTime">
-						</uni-data-select>
-					</view>
-					<view class="type">
-						<uni-data-select placeholder="请选择支付状态" v-model="type_value" :localdata="type_range"
-							@change="changeType">
-						</uni-data-select>
-					</view>
-				</view>
-
 				<!-- 账单列表区域 -->
 				<!-- 账单列表区域 -->
 				<view class="has_bill">
 				<view class="has_bill">
 					<view class="item" v-for="item in list" :key="item.id">
 					<view class="item" v-for="item in list" :key="item.id">
 						<view class="item_header">
 						<view class="item_header">
-							{{item.title}}
+							{{item.payMonth+item.paymentItem}}
 						</view>
 						</view>
 						<view class="item_box">
 						<view class="item_box">
 							<view class="item_box_1">
 							<view class="item_box_1">
-								上月表数:{{item.last}}
+								上月表数:{{item.lastElectry}}
 							</view>
 							</view>
 							<view class="item_box_2">
 							<view class="item_box_2">
-								本月表数:{{item.current}}
+								本月表数:{{item.nowElectry}}
 							</view>
 							</view>
 						</view>
 						</view>
 						<view class="item_box">
 						<view class="item_box">
 							<view class="item_box_1">
 							<view class="item_box_1">
-								用量:{{item.use}}吨
+								用量:{{item.nowTonnage}}吨
 							</view>
 							</view>
 							<view class="item_box_2">
 							<view class="item_box_2">
-								补助吨数:{{item.sub}}吨
+								补助吨数:{{item.subsidiesTonnage}}吨
 							</view>
 							</view>
 						</view>
 						</view>
-						<view class="item_box" v-if="item.payPeople">
+						<view class="item_box" v-if="item.payItemType=='2'">
 							<view class="item_box_1">
 							<view class="item_box_1">
-								支付人:{{item.payPeople}}
+								支付人:{{item.cardNumber}}
 							</view>
 							</view>
 						</view>
 						</view>
 						<view class="item_notes">
 						<view class="item_notes">
-							备注:{{item.notes}}
+							备注:{{item.orderNotice}}
 						</view>
 						</view>
 
 
 						<view class="item_box">
 						<view class="item_box">
 							<view class="item_box_1 font">
 							<view class="item_box_1 font">
-								{{item.time}}
+								{{item.payCreateTime}}
 							</view>
 							</view>
 							<view class="item_box_2">
 							<view class="item_box_2">
-								实付款:{{item.money}}
+								实付款:{{item.realPayAmount}}
 							</view>
 							</view>
 						</view>
 						</view>
 
 
@@ -82,7 +81,7 @@
 								订单反馈
 								订单反馈
 							</button>
 							</button>
 
 
-							<button class="feedback" type="warn" size="mini" disabled v-if="item.payPeople">
+							<button class="feedback" type="warn" size="mini" disabled v-if="item.payItemType=='2'">
 								已支付
 								已支付
 							</button>
 							</button>
 
 
@@ -93,7 +92,14 @@
 					</view>
 					</view>
 				</view>
 				</view>
 
 
+			</view>
+		</view>
 
 
+		<!-- 电话区域按钮 -->
+		<view class="phone">
+			<view class="phone_box">
+				咨询电话:
+				<span @click="handlePhone">82293462</span>
 			</view>
 			</view>
 		</view>
 		</view>
 
 
@@ -181,69 +187,25 @@
 				nx: 0,
 				nx: 0,
 				ny: 0,
 				ny: 0,
 				// 账单数据
 				// 账单数据
-				list: [{
-						id: 1,
-						title: "2022年9月水费账单",
-						last: 0,
-						current: 22,
-						use: 22,
-						sub: 15,
-						notes: "水费为3.2元/吨",
-						time: "2022-09-20 15:25:28",
-						money: 14.66,
-						payPeople: ""
-					},
-					{
-						id: 2,
-						title: "2022年6月水费账单",
-						last: 66,
-						current: 100,
-						use: 34,
-						sub: 14,
-						notes: "水费为3.2元/吨",
-						time: "2022-06-20 15:25:28",
-						money: 64,
-						payPeople: ""
-					},
-					{
-						id: 3,
-						title: "2022年5月水费账单",
-						last: 100,
-						current: 120,
-						use: 20,
-						sub: 10,
-						notes: "水费为3.2元/吨",
-						time: "2022-05-20 15:25:28",
-						money: 32,
-						payPeople: "测试"
-					},
-				],
+				list: [],
 				// 时间筛选框选中值绑定数据
 				// 时间筛选框选中值绑定数据
 				time_value: "",
 				time_value: "",
 				// 时间筛选框列表绑定数据
 				// 时间筛选框列表绑定数据
-				time_range: [{
-						value: 0,
-						text: "2022"
-					},
-					{
+				time_range: [],
+				// 支付状态 0是全部 1是未支付 2是已支付
+				pay_type: 0,
+				// 支付状态筛选框列表绑定数据
+				type_range: [{
 						value: 1,
 						value: 1,
-						text: "2023"
+						text: "全部"
 					},
 					},
 					{
 					{
 						value: 2,
 						value: 2,
-						text: "2024"
-					},
-				],
-				// 支付状态筛选框选中值绑定数据
-				type_value: "",
-				// 支付状态筛选框列表绑定数据
-				type_range: [{
-						value: 0,
-						text: "已支付"
+						text: "未支付"
 					},
 					},
 					{
 					{
-						value: 1,
-						text: "支付"
+						value: 3,
+						text: "已支付"
 					},
 					},
 				],
 				],
 				// 订单反馈弹窗 表格的验证规则
 				// 订单反馈弹窗 表格的验证规则
@@ -304,22 +266,46 @@
 		onLoad() {
 		onLoad() {
 			// 如果之前已经选择过宿舍,则从缓存中读取
 			// 如果之前已经选择过宿舍,则从缓存中读取
 			if (localStorage.room) {
 			if (localStorage.room) {
-				this.roomSelect = localStorage.room
+				this.roomSelect = "黄家湖" + localStorage.room
 				this.getData()
 				this.getData()
+				this.getTimeList()
 			}
 			}
 		},
 		},
 		methods: {
 		methods: {
 			// 获取账单列表数据
 			// 获取账单列表数据
-			// async
-			getData() {
-				console.log("获取数据");
-				// let res = await this.$myRequest({
-				// 	url: "/payableinfo/payableInfo",
-				// 	data: {
-				// 		pageSize: "999",
-				// 	},
-				// });
+			async getData() {
+				if (!this.time_value) {
+					let date = new Date();
+					this.time_value = date.getFullYear()
+				}
+
+				let res = await this.$myRequest({
+					url: "/payableinfowater/queryWaterInfo",
+					data: {
+						dorm: localStorage.room,
+						// dorm: "12栋202",
+						year: this.time_value,
+						payStatu: this.pay_type,
+					},
+				});
+				// console.log(res);
+				if (res.success) {
+					this.list = res.data
+				}
+			},
+			// 获取时间筛选框时间数组
+			async getTimeList() {
+				let res = await this.$myRequest({
+					url: "/payableinfowater/queryAllYear",
+					data: {
+						dorm: localStorage.room,
+						// dorm: "12栋202",
+					},
+				});
 				// console.log(res);
 				// console.log(res);
+				if (res.success) {
+					this.time_range = res.data
+				}
 			},
 			},
 			// 选择图片回调
 			// 选择图片回调
 			select(e) {
 			select(e) {
@@ -369,7 +355,8 @@
 				console.log(this.valiFormData.feedbackImg);
 				console.log(this.valiFormData.feedbackImg);
 			},
 			},
 			// 订单反馈按钮弹窗
 			// 订单反馈按钮弹窗
-			handleFeedback(item) {
+			async handleFeedback(item) {
+				console.log(item);
 				this.popTitle = item.title
 				this.popTitle = item.title
 				this.valiFormData.feedbackPersonName = "";
 				this.valiFormData.feedbackPersonName = "";
 				this.valiFormData.feedbackPersonPhone = "";
 				this.valiFormData.feedbackPersonPhone = "";
@@ -377,6 +364,18 @@
 				this.valiFormData.feedbackInfo = "";
 				this.valiFormData.feedbackInfo = "";
 				this.valiFormData.feedbackImg = [];
 				this.valiFormData.feedbackImg = [];
 
 
+				let res = await this.$myRequest({
+					url: "/wechat/getUserNameTele",
+					data: {
+						cardNumber: item.cardNumber,
+					},
+				});
+				// console.log(res);
+				if (res.success) {
+					this.valiFormData.feedbackPersonName = res.data.name
+					this.valiFormData.feedbackPersonPhone = res.data.telephone
+				}
+
 				this.$refs.popup_feedback.open();
 				this.$refs.popup_feedback.open();
 			},
 			},
 			// 订单反馈弹窗提交按钮回调
 			// 订单反馈弹窗提交按钮回调
@@ -400,11 +399,27 @@
 			},
 			},
 			// 时间筛选框数据改变回调
 			// 时间筛选框数据改变回调
 			changeTime(e) {
 			changeTime(e) {
-				console.log(e);
+				if (e != "") {
+					this.time_range.forEach((element) => {
+						if (element.value == e) {
+							this.time_value = element.text
+						}
+					})
+					this.getData()
+				}
 			},
 			},
 			// 支付状态筛选框数据改变回调
 			// 支付状态筛选框数据改变回调
 			changeType(e) {
 			changeType(e) {
-				console.log(e);
+				if (e == 1 || e == 2 || e == 3) {
+					if (e == 1) {
+						this.pay_type = 0
+					} else if (e == 2) {
+						this.pay_type = 1
+					} else if (e == 3) {
+						this.pay_type = 2
+					}
+					this.getData()
+				}
 			},
 			},
 			// 跳转到选择宿舍页面
 			// 跳转到选择宿舍页面
 			navigateToSelect() {
 			navigateToSelect() {
@@ -476,6 +491,13 @@
 				this.flags = false;
 				this.flags = false;
 			},
 			},
 
 
+			// 拨打电话回调
+			handlePhone() {
+				uni.makePhoneCall({
+					phoneNumber: '82293462'
+				});
+			},
+
 			// 下拉刷新回调
 			// 下拉刷新回调
 			onPullDownRefresh() {
 			onPullDownRefresh() {
 				console.log('刷新');
 				console.log('刷新');
@@ -530,6 +552,15 @@
 				color: #999999;
 				color: #999999;
 			}
 			}
 
 
+			.picker-item-content2 {
+				width: 360rpx;
+				height: 139rpx;
+				line-height: 139rpx;
+				font-size: 36rpx;
+				text-align: center;
+				color: black;
+			}
+
 			.picker-item-logor {
 			.picker-item-logor {
 				width: 91rpx;
 				width: 91rpx;
 				display: flex;
 				display: flex;
@@ -545,7 +576,21 @@
 
 
 		.bill {
 		.bill {
 			margin: 20rpx 0;
 			margin: 20rpx 0;
-			min-height: 982rpx;
+			min-height: 920rpx;
+
+			.choose {
+				display: flex;
+				margin: 0 20rpx;
+
+				.time {
+					flex: 1;
+					padding-right: 40rpx;
+				}
+
+				.type {
+					flex: 1;
+				}
+			}
 
 
 			.null {
 			.null {
 				display: flex;
 				display: flex;
@@ -568,19 +613,7 @@
 			.has {
 			.has {
 				margin: 0 20rpx;
 				margin: 0 20rpx;
 
 
-				.choose {
-					display: flex;
 
 
-					.time {
-						flex: 1;
-						padding-right: 40rpx;
-					}
-
-					.type {
-						flex: 1;
-						padding-right: 40rpx;
-					}
-				}
 
 
 				.has_bill {
 				.has_bill {
 					margin-top: 20rpx;
 					margin-top: 20rpx;
@@ -653,6 +686,22 @@
 			}
 			}
 		}
 		}
 
 
+		.phone {
+			display: flex;
+			justify-content: center;
+			align-items: center;
+			margin: 20rpx 0;
+			height: 70rpx;
+
+			.phone_box {
+				margin-bottom: 20rpx;
+
+				span {
+					color: #4993EA;
+				}
+			}
+		}
+
 		.suspend_button {
 		.suspend_button {
 			position: fixed;
 			position: fixed;
 			left: 80rpx;
 			left: 80rpx;
@@ -698,6 +747,10 @@
 		color: #fff;
 		color: #fff;
 	}
 	}
 
 
+	::v-deep .uniui-bottom::before {
+		color: #fff;
+	}
+
 	::v-deep .uni-forms-item__label {
 	::v-deep .uni-forms-item__label {
 		width: 160rpx !important;
 		width: 160rpx !important;
 	}
 	}

+ 31 - 11
pages/index/index.vue

@@ -9,25 +9,27 @@
 		data() {
 		data() {
 			return {
 			return {
 				//线上服务器域名
 				//线上服务器域名
-				homeUrl: "https://chtech.ncjti.edu.cn/jiaofei/jiaofei-api",
-				// homeUrl: "http://192.168.161.34:9999",
+				// homeUrl: "https://chtech.ncjti.edu.cn/jiaofei/jiaofei-api",
+				homeUrl: "http://192.168.161.34:9999",
 			}
 			}
 		},
 		},
 		onLoad() {
 		onLoad() {
 			//获取cardNumber
 			//获取cardNumber
-			// this.loginFilter();
+			this.loginFilter();
 		},
 		},
 		methods: {
 		methods: {
 			//获取cardNumber
 			//获取cardNumber
 			loginFilter() {
 			loginFilter() {
-				let card_number = localStorage.getItem("card_number")
+				// let card_number = localStorage.getItem("card_number")
+				let card_number = localStorage.card_number
 				if (!card_number) {
 				if (!card_number) {
 					let cardNumber = this.getQueryString("cardNumber");
 					let cardNumber = this.getQueryString("cardNumber");
 					if (!cardNumber) {
 					if (!cardNumber) {
 						window.location.href =
 						window.location.href =
-							`https://open.wecard.qq.com/connect/oauth/authorize?app_key=580DBB565097446B&response_type=code&scope=snsapi_userinfo&ocode=1015730314&redirect_uri=${this.homeUrl}/tuitionpayment/wechat/weixiao/auth/&connect=curLogin&state=${this.homeUrl}/tuitionpayment/wechat/weixiao/auth/`;
+							`https://open.wecard.qq.com/connect/oauth/authorize?app_key=580DBB565097446B&response_type=code&scope=snsapi_userinfo&ocode=1015730314&redirect_uri=${this.homeUrl}/tuitionpayment/wechat/weixiao/auth/hjh/&connect=curLogin&state=${this.homeUrl}/tuitionpayment/wechat/weixiao/auth/hjh`;
 					} else {
 					} else {
-						localStorage.setItem("card_number", cardNumber)
+						// localStorage.setItem("card_number", cardNumber)
+						localStorage.card_number = cardNumber
 						this.getStudentName()
 						this.getStudentName()
 					}
 					}
 				} else {
 				} else {
@@ -37,14 +39,15 @@
 
 
 			// 获取学生姓名
 			// 获取学生姓名
 			getStudentName() {
 			getStudentName() {
-				let studentName = localStorage.getItem("studentName")
+				// let studentName = localStorage.getItem("studentName")
+				let studentName = localStorage.studentName
 				if (!studentName) {
 				if (!studentName) {
 					let studentName = this.getQueryString("name");
 					let studentName = this.getQueryString("name");
 					if (!studentName) {
 					if (!studentName) {
 						window.location.href =
 						window.location.href =
-							`https://open.wecard.qq.com/connect/oauth/authorize?app_key=580DBB565097446B&response_type=code&scope=snsapi_userinfo&ocode=1015730314&redirect_uri=${this.homeUrl}/tuitionpayment/wechat/weixiao/auth/&connect=curLogin&state=${this.homeUrl}/tuitionpayment/wechat/weixiao/auth/`;
+							`https://open.wecard.qq.com/connect/oauth/authorize?app_key=580DBB565097446B&response_type=code&scope=snsapi_userinfo&ocode=1015730314&redirect_uri=${this.homeUrl}/tuitionpayment/wechat/weixiao/auth/hjh/&connect=curLogin&state=${this.homeUrl}/tuitionpayment/wechat/weixiao/auth/hjh`;
 					} else {
 					} else {
-						localStorage.setItem("studentName", studentName)
+						localStorage.studentName = studentName
 						this.getOpenId()
 						this.getOpenId()
 					}
 					}
 				} else {
 				} else {
@@ -52,18 +55,35 @@
 				}
 				}
 			},
 			},
 
 
+			// 获取学生手机号
+			// getStudentPhone() {
+			// 	let studentPhone = localStorage.studentPhone
+			// 	if (!studentPhone) {
+			// 		let studentPhone = this.getQueryString("name");
+			// 		if (!studentPhone) {
+			// 			window.location.href =
+			// 				`https://open.wecard.qq.com/connect/oauth/authorize?app_key=580DBB565097446B&response_type=code&scope=snsapi_userinfo&ocode=1015730314&redirect_uri=${this.homeUrl}/tuitionpayment/wechat/weixiao/auth/&connect=curLogin&state=${this.homeUrl}/tuitionpayment/wechat/weixiao/auth/`;
+			// 		} else {
+			// 			localStorage.studentPhone = studentPhone
+			// 			this.getOpenId()
+			// 		}
+			// 	} else {
+			// 		this.getOpenId()
+			// 	}
+			// },
+
 			//获取openId
 			//获取openId
 			getOpenId() {
 			getOpenId() {
 				// 从缓存获取openId,如果有的话
 				// 从缓存获取openId,如果有的话
 				let openId = localStorage.getItem("openId")
 				let openId = localStorage.getItem("openId")
 				if (!openId) {
 				if (!openId) {
-					// 从url连接中获取openId,如果有的话
+					// 从url接中获取openId,如果有的话
 					let openId = this.getQueryString("openId");
 					let openId = this.getQueryString("openId");
 
 
 					// 缓存中和url参数中度没有获取到openId,则请求授权地址发起授权
 					// 缓存中和url参数中度没有获取到openId,则请求授权地址发起授权
 					if (!openId) {
 					if (!openId) {
 						window.location.href =
 						window.location.href =
-							`https://open.weixin.qq.com/connect/oauth2/authorize?appid=wxd87cbe1db0437303&redirect_uri=${this.homeUrl}/tuitionpayment/wechat/pub/auth&response_type=code&scope=snsapi_base&state=pages/index/index#wechat_redire`;
+							`https://open.weixin.qq.com/connect/oauth2/authorize?appid=wxd87cbe1db0437303&redirect_uri=${this.homeUrl}/tuitionpayment/wechat/pub/auth/hjh&response_type=code&scope=snsapi_base&state=pages/index/index#wechat_redire`;
 						return
 						return
 					} else {
 					} else {
 						// 获取到openId,存入缓存
 						// 获取到openId,存入缓存

+ 48 - 9
pages/select/select.vue

@@ -16,7 +16,7 @@
 
 
 		<!-- 选择楼栋区域 -->
 		<!-- 选择楼栋区域 -->
 		<picker class="picker-item" @click="handleBuild" @change="changeSelect_build" :range="array_build"
 		<picker class="picker-item" @click="handleBuild" @change="changeSelect_build" :range="array_build"
-			:value="index_build" :disabled="disabled_build">
+			range-key="buildName" :value="index_build" :disabled="disabled_build">
 			<view class="select-item">
 			<view class="select-item">
 				<view class="picker-item-logol">
 				<view class="picker-item-logol">
 					<image class="picker-item-logo-left" src="../../static/building.png"></image>
 					<image class="picker-item-logo-left" src="../../static/building.png"></image>
@@ -31,7 +31,7 @@
 
 
 		<!-- 选择楼层区域 -->
 		<!-- 选择楼层区域 -->
 		<picker class="picker-item" @click="handleFloor" @change="changeSelect_floor" :range="array_floor"
 		<picker class="picker-item" @click="handleFloor" @change="changeSelect_floor" :range="array_floor"
-			:value="index_floor" :disabled="disabled_floor">
+			range-key="floorName" :value="index_floor" :disabled="disabled_floor">
 			<view class="select-item">
 			<view class="select-item">
 				<view class="picker-item-logol">
 				<view class="picker-item-logol">
 					<image class="picker-item-logo-left" src="../../static/floor.png"></image>
 					<image class="picker-item-logo-left" src="../../static/floor.png"></image>
@@ -46,7 +46,7 @@
 
 
 		<!-- 选择房间区域 -->
 		<!-- 选择房间区域 -->
 		<picker class="picker-item" @click="handleRoom" @change="changeSelect_room" :range="array_room"
 		<picker class="picker-item" @click="handleRoom" @change="changeSelect_room" :range="array_room"
-			:value="index_room" :disabled="disabled_room">
+			range-key="roomName" :value="index_room" :disabled="disabled_room">
 			<view class="select-item">
 			<view class="select-item">
 				<view class="picker-item-logol">
 				<view class="picker-item-logol">
 					<image class="picker-item-logo-left" src="../../static/room.png"></image>
 					<image class="picker-item-logo-left" src="../../static/room.png"></image>
@@ -101,7 +101,20 @@
 				disabled_room: true,
 				disabled_room: true,
 			};
 			};
 		},
 		},
+		mounted() {
+			this.getBuild()
+		},
 		methods: {
 		methods: {
+			// 获取楼栋数据
+			async getBuild() {
+				let res = await this.$myRequest({
+					url: "/room/queryAllBuild",
+				})
+				// console.log(res);
+				if (res.success) {
+					this.array_build = res.data
+				}
+			},
 			// 点击楼栋区域回调
 			// 点击楼栋区域回调
 			handleBuild() {
 			handleBuild() {
 				if (this.disabled_build) {
 				if (this.disabled_build) {
@@ -151,26 +164,52 @@
 				this.disabled_build = false
 				this.disabled_build = false
 			},
 			},
 			// 楼栋筛选框change回调
 			// 楼栋筛选框change回调
-			changeSelect_build(e) {
+			async changeSelect_build(e) {
 				let index = e.detail.value
 				let index = e.detail.value
-				this.value_build = this.array_build[index]
+				this.value_build = this.array_build[index].buildName
 				this.disabled_floor = false
 				this.disabled_floor = false
+
+				let data = {
+					buildId: this.array_build[index].buildId
+				}
+
+				let res = await this.$myRequest({
+					url: "/room/queryAllFloor",
+					data
+				})
+				// console.log(res);
+				if (res.success) {
+					this.array_floor = res.data
+				}
 			},
 			},
 			// 楼层筛选框change回调
 			// 楼层筛选框change回调
-			changeSelect_floor(e) {
+			async changeSelect_floor(e) {
 				let index = e.detail.value
 				let index = e.detail.value
-				this.value_floor = this.array_floor[index]
+				this.value_floor = this.array_floor[index].floorName
 				this.disabled_room = false
 				this.disabled_room = false
+
+				let data = {
+					floorId: this.array_floor[index].floorId
+				}
+
+				let res = await this.$myRequest({
+					url: "/room/queryAllRoom",
+					data
+				})
+				// console.log(res);
+				if (res.success) {
+					this.array_room = res.data
+				}
 			},
 			},
 			// 房间筛选框change回调
 			// 房间筛选框change回调
 			changeSelect_room(e) {
 			changeSelect_room(e) {
 				let index = e.detail.value
 				let index = e.detail.value
-				this.value_room = this.array_room[index]
+				this.value_room = this.array_room[index].roomName
 			},
 			},
 			// 完成按钮点击回调
 			// 完成按钮点击回调
 			handleSubmit() {
 			handleSubmit() {
 				if (!this.disabled_build && !this.disabled_floor && !this.disabled_room) {
 				if (!this.disabled_build && !this.disabled_floor && !this.disabled_room) {
-					let temRoom = this.value + this.value_build + this.value_floor + this.value_room
+					let temRoom = this.value_build + this.value_floor + this.value_room
 					localStorage.room = temRoom
 					localStorage.room = temRoom
 					uni.reLaunch({
 					uni.reLaunch({
 						url: "/pages/home/home"
 						url: "/pages/home/home"

+ 2 - 2
util/api.js

@@ -1,7 +1,7 @@
 // 线上地址
 // 线上地址
-const BASE_URL = "https://chtech.ncjti.edu.cn/jiaofei/jiaofei-api/tuitionpayment"
+// const BASE_URL = "https://chtech.ncjti.edu.cn/jiaofei/jiaofei-api/tuitionpayment"
 // 本地地址
 // 本地地址
-// const BASE_URL = "http://192.168.161.34:9999/tuitionpayment"
+const BASE_URL = "http://192.168.161.34:9999/tuitionpayment"
 export const myRequest = (options) => {
 export const myRequest = (options) => {
 	uni.showLoading({
 	uni.showLoading({
 		title: "加载中",
 		title: "加载中",