Commit ac3e3bd9 by 李嘉林

修改

parent 120832d3
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
<!-- 核验历史 --> <!-- 核验历史 -->
<div class="checkHistory"> <div class="checkHistory">
<div class="list"> <div class="list">
<div class="item flex" v-for="(item, index) in 20" :key="index"> <div class="item flex" v-for="(item, index) in list" :key="index">
<div class="left"> <div class="left">
<p> <p>
<span>核验地点:</span><span>{{ "云顶大酒店" }}</span> <span>核验地点:</span><span>{{ "云顶大酒店" }}</span>
...@@ -22,16 +22,19 @@ ...@@ -22,16 +22,19 @@
></image> ></image>
</div> </div>
</div> </div>
<div class="noCheck" v-if="loaded && list.length == 0">暂无核验</div>
</div> </div>
</div> </div>
</template> </template>
<script type="text/ecmascript-6"> <script type="text/ecmascript-6">
import index from "@/api/index";
export default { export default {
name: "checkHistory", name: "checkHistory",
data() { data() {
return { return {
list: [], list: [],
loaded: false,
}; };
}, },
components: {}, components: {},
...@@ -44,9 +47,28 @@ export default { ...@@ -44,9 +47,28 @@ export default {
console.log("---onLoad"); console.log("---onLoad");
}, },
onShow() { onShow() {
this.init();
console.log("---onShow"); console.log("---onShow");
}, },
methods: {}, methods: {
init() {
wx.showLoading({
title: "加载中...",
});
let query = {
pageNum: 1,
pageSize: 10000,
checkOrVerified: 2,
};
index.getHistoryByVerifier(query).then((res) => {
this.loaded = true;
wx.hideLoading();
if (res.data.ok == "ok") {
this.list = res.data.data;
}
});
},
},
}; };
</script> </script>
...@@ -71,17 +93,25 @@ export default { ...@@ -71,17 +93,25 @@ export default {
font-weight: 400; font-weight: 400;
color: #333333; color: #333333;
} }
.time{ .time {
margin-top: 8px; margin-top: 8px;
} }
} }
.checkIcon { .checkIcon {
image{ image {
width: 64px; width: 64px;
height: 50px; height: 50px;
} }
} }
} }
} }
.noCheck {
margin-top: 20px;
font-size: 13px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #666;
text-align: center;
}
} }
</style> </style>
...@@ -121,11 +121,11 @@ export default { ...@@ -121,11 +121,11 @@ export default {
}, },
methods: { methods: {
init(){ init(){
// wx.showLoading({ wx.showLoading({
// title: "加载中...", title: "加载中...",
// }); });
live.getUserInfo().then(res=>{ live.getUserInfo().then(res=>{
// wx.hideLoading(); wx.hideLoading();
if(res.data.ok=='true'){ if(res.data.ok=='true'){
this.userInfo = res.data.data; this.userInfo = res.data.data;
} }
...@@ -150,7 +150,13 @@ export default { ...@@ -150,7 +150,13 @@ export default {
// wx.reLaunch({ // wx.reLaunch({
// url: '/pages/home/main' // 指定页面的url // url: '/pages/home/main' // 指定页面的url
// }); // });
wx.navigateBack(); if(getCurrentPages().length>1){
wx.navigateBack();
} else {
wx.reLaunch({
url: '/pages/home/main' // 指定页面的url
});
}
}, },
}, },
onHide() { onHide() {
......
...@@ -21,7 +21,7 @@ ...@@ -21,7 +21,7 @@
</div> </div>
</div> </div>
</div> </div>
<div class="btm" v-if="!reported"> <div class="btm" v-if="!reported && loaded">
<div class="btn" @click="confirm" :class="{ btn1: confirmLoading }"> <div class="btn" @click="confirm" :class="{ btn1: confirmLoading }">
确认挂失 确认挂失
</div> </div>
......
...@@ -32,7 +32,7 @@ ...@@ -32,7 +32,7 @@
placeholder="请输入姓名" placeholder="请输入姓名"
v-model="name" v-model="name"
/> />
<i class="iconfont icon-you"></i> <!-- <i class="iconfont icon-you"></i> -->
</div> </div>
</div> </div>
<div class="cell flex"> <div class="cell flex">
...@@ -48,7 +48,7 @@ ...@@ -48,7 +48,7 @@
@input="input_id_number" @input="input_id_number"
v-model="idNum" v-model="idNum"
/> />
<i class="iconfont icon-you"></i> <!-- <i class="iconfont icon-you"></i> -->
</div> </div>
</div> </div>
</div> </div>
...@@ -143,7 +143,7 @@ export default { ...@@ -143,7 +143,7 @@ export default {
// 下一步 // 下一步
next() { next() {
console.log("--下一步--"); console.log("--下一步--");
this.check_id_number(); // this.check_id_number();
if (this.idPhoto == "") { if (this.idPhoto == "") {
wx.showToast({ wx.showToast({
title: "请上传证件照", title: "请上传证件照",
...@@ -179,11 +179,6 @@ export default { ...@@ -179,11 +179,6 @@ export default {
let query = { customerName: this.name, identityCard: this.idNum }; let query = { customerName: this.name, identityCard: this.idNum };
login.get_certified_info(query).then((res) => { login.get_certified_info(query).then((res) => {
if (res.data.ok == "true") { if (res.data.ok == "true") {
wx.showToast({
title: "认证通过",
icon: "success",
duration: 1000,
});
let infoData = res.data.data; let infoData = res.data.data;
this.mini_certified(infoData); this.mini_certified(infoData);
} else { } else {
...@@ -225,6 +220,11 @@ export default { ...@@ -225,6 +220,11 @@ export default {
}) })
.then((res) => { .then((res) => {
if (res.data.code == 200 && res.data.data.sessionId) { if (res.data.code == 200 && res.data.data.sessionId) {
wx.showToast({
title: "认证通过",
icon: "success",
duration: 1000,
});
wx.setStorage({ wx.setStorage({
key: "sessionid", key: "sessionid",
data: res.data.data.sessionId data: res.data.data.sessionId
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment