zzp 2 years ago
parent
commit
df42e52e00
3 changed files with 14 additions and 15 deletions
  1. 2 2
      config/api.js
  2. 2 2
      pagesClass/classDetail.vue
  3. 10 11
      pagesClass/signForm.vue

+ 2 - 2
config/api.js

@@ -5,9 +5,9 @@
 
 //const API_BASE = 'http://192.168.1.117:8089'
 // const API_BASE = 'http://192.168.1.109/newApi'
-const API_BASE = 'http://192.168.1.145/newApi'
+// const API_BASE = 'http://192.168.1.145/newApi'
 // const API_BASE = 'http://192.168.1.126:30000'
-// const API_BASE = 'http://192.168.1.117:8089'
+const API_BASE = 'http://192.168.1.117:8089'
 
 module.exports = {
 	//  微信授权登录

+ 2 - 2
pagesClass/classDetail.vue

@@ -24,9 +24,9 @@
 		<u-card :title="'学员信息(' + getStudentsNumber(1) + ')'" title-size="32" margin="0px 0px 10px 0px" :head-style="cardStyle">
 			<u-grid :col="3" slot="body" :border="false">
 				<u-grid-item v-for="(item, index) in classInfo.studentSignList" :key="index" :custom-style="gridCustomStyle" @click="goToStudentInfo(item)">
-					<view class="class-student-col" :class="item.state ? 'student-active' : ''">
+					<view class="class-student-col">
 						{{item.name}}
-						<u-icon name="bookmark" :color="mainColor" size="48"></u-icon>
+						<u-icon :name="item.state == 1 ? 'bookmark-fill' : 'bookmark'" :color="mainColor" size="48"></u-icon>
 					</view>
 				</u-grid-item>
 			</u-grid>

+ 10 - 11
pagesClass/signForm.vue

@@ -144,21 +144,20 @@
 			},
 			//  提交表单
 			submitForm() {
-				console.log(this.studentList)
 				NET.request(API.submitSignForm, {
 					classId: this.classId,
 					signStudentIdList: this.studentList.filter(site => site.state == 0 && site.checked).map(site => {
-						if (site.fileId) {
-							return {
-								id: site.id,
-								fileId: site.fileId,
-							}
-						} else {
-							return {
-								id: site.id,
-							}
+					if (site.fileId) {
+						return {
+							id: site.id,
+							fileId: site.fileId,
 						}
-					})
+					} else {
+						return {
+							id: site.id,
+						}
+					}
+				})
 				}, 'POST').then(res => {
 					this.$refs.uTips.show({
 						title: '签到成功',