|
@@ -5,7 +5,7 @@
|
|
|
<h3><strong>校卡审核</strong></h3>
|
|
|
</van-col>
|
|
|
<van-col span="8">
|
|
|
- <p :style="{ color: statusColor }">{{statusString}}</p>
|
|
|
+ <p :style="{ color: statusColor }">{{statusString}}</p>
|
|
|
</van-col>
|
|
|
</van-row>
|
|
|
<div v-if="status===30 || status === 500">
|
|
@@ -13,7 +13,6 @@
|
|
|
<p>活动仅允许深大学生参与,请上传正面校卡照片审核~</p>
|
|
|
<van-button
|
|
|
type="primary"
|
|
|
- class="submit_button"
|
|
|
@click="schoolPresent"
|
|
|
:loading="loading"
|
|
|
>保存
|
|
@@ -39,38 +38,39 @@
|
|
|
},
|
|
|
data() {
|
|
|
return {
|
|
|
- statusColor: '',
|
|
|
- statusString: '-----',
|
|
|
+ statusColor:'',
|
|
|
+ statusString:'-----',
|
|
|
photo: null,
|
|
|
- loading: false,
|
|
|
- status: 0,
|
|
|
+ loading:false,
|
|
|
+ status:0,
|
|
|
imgage: null,
|
|
|
- imgDo: {},
|
|
|
- schoolpic: "",
|
|
|
- IMGPREFIX: "http://gift.fogice.com"
|
|
|
+ imgDo:{},
|
|
|
+ schoolpic:"",
|
|
|
+ IMGPREFIX:"http://gift.fogice.com"
|
|
|
|
|
|
}
|
|
|
},
|
|
|
methods: {
|
|
|
schoolPresent() {
|
|
|
// 检验输入
|
|
|
- this.loading = true;
|
|
|
+ this.loading=true;
|
|
|
if (this.photo === null) {
|
|
|
Toast.fail('请上传礼物照片');
|
|
|
- this.loading = false;
|
|
|
+ this.loading=false;
|
|
|
return;
|
|
|
}
|
|
|
- this.imgDo.userSchoolCardPic = this.imgUrl;
|
|
|
- let that = this;
|
|
|
+ this.imgDo.userSchoolCardPic=this.photo;
|
|
|
BasicFunction.get_data("smartIdentity/updateBatch", function (response) {
|
|
|
console.log("------ Data Rcvd in uploadphotoChange --------");
|
|
|
console.log(response);
|
|
|
if (response.ret === "10000") {
|
|
|
Toast.success("上传成功")
|
|
|
+ this.$router.push('index');
|
|
|
} else {
|
|
|
Toast.fail("上传失败,请检查网络");
|
|
|
}
|
|
|
}, [this.imgDo]);
|
|
|
+
|
|
|
},
|
|
|
onRead: function (e) {
|
|
|
this.photo = e;
|
|
@@ -86,29 +86,30 @@
|
|
|
BasicFunction.get_data('smartIdentity/list?userId=' + userid, function (res) {
|
|
|
console.log(res);
|
|
|
if (res.ret === '10000') {
|
|
|
- var t = res.model.list;
|
|
|
- that.status = t[0].userReviewStatus;
|
|
|
- that.imgDo = t[0];
|
|
|
+ var t=res.model.list;
|
|
|
+ that.status=t[0].userReviewStatus;
|
|
|
+ that.imgDo=t[0];
|
|
|
console.log(that);
|
|
|
- if (that.status === 30) {
|
|
|
- that.statusColor = '#c5c5c5';
|
|
|
- that.statusString = '未上传校卡';
|
|
|
+ if(that.status === 30){
|
|
|
+ that.statusColor='#c5c5c5';
|
|
|
+ that.statusString='未上传校卡';
|
|
|
that.$router.push('verify');
|
|
|
return;
|
|
|
- } else if (that.status === 0 || that.status === 1000) {
|
|
|
- that.schoolpic = that.IMGPREFIX + t[0].userSchoolCardPic;
|
|
|
- if (that.status === 0) {
|
|
|
- that.statusColor = '#c5c530';
|
|
|
- that.statusString = '审核中'
|
|
|
+ } else if (that.status === 0|| that.status === 1000) {
|
|
|
+ that.schoolpic=that.IMGPREFIX+t[0].userSchoolCardPic;
|
|
|
+ if(that.status === 0)
|
|
|
+ {
|
|
|
+ that.statusColor='#c5c530';
|
|
|
+ that.statusString='审核中'
|
|
|
}
|
|
|
|
|
|
- if (that.status === 1000) {
|
|
|
+ if(that.status === 1000) {
|
|
|
that.statusColor = '#00ff00';
|
|
|
- that.statusString = '审核通过'
|
|
|
+ that.statusString='审核通过'
|
|
|
}
|
|
|
} else {
|
|
|
- that.statusColor = '#ff0000';
|
|
|
- that.statusString = '审核未通过'
|
|
|
+ that.statusColor='#ff0000';
|
|
|
+ that.statusString='审核未通过'
|
|
|
}
|
|
|
}
|
|
|
}, {});
|
|
@@ -134,17 +135,10 @@
|
|
|
padding: 15px;
|
|
|
text-align: left;
|
|
|
}
|
|
|
-
|
|
|
- .submit_button {
|
|
|
- margin-bottom: 10px;
|
|
|
- margin-left: auto;
|
|
|
- margin-right: auto;
|
|
|
- position: fixed;
|
|
|
- bottom: 0;
|
|
|
- left: 0;
|
|
|
- right: 0;
|
|
|
- background-color: #fd6740;
|
|
|
- border-color: #fd6740;
|
|
|
- width: 85%;
|
|
|
- }
|
|
|
+ .van-button {
|
|
|
+ background-color: #fd6740;
|
|
|
+ border-color: #fd6740;
|
|
|
+ margin: 10px 0 10px;
|
|
|
+ width: 55%;
|
|
|
+ }
|
|
|
</style>
|