fix: BUG修改
This commit is contained in:
parent
eb5e2ec392
commit
995556a25f
@ -78,8 +78,8 @@
|
||||
<div
|
||||
class="downDiv"
|
||||
style="text-align: center;"
|
||||
:style="{ height: backimgheightDown + 'px' }"
|
||||
>
|
||||
<!-- :style="{ height: backimgheightDown + 'px' }" -->
|
||||
<div
|
||||
class="downHear"
|
||||
:style="{
|
||||
@ -118,36 +118,38 @@
|
||||
>通过后台查询到,您有以下扣分记录:</div>
|
||||
<ul
|
||||
class="text2-content"
|
||||
v-infinite-scroll="load"
|
||||
style="overflow:auto"
|
||||
:style="{ fontSize: backimgFontSize * 0.5 + 'px', height: backimgFontSize * 6 + 'px', }"
|
||||
style="overflow-y:scroll"
|
||||
:style="{ fontSize: backimgFontSize * 0.5 + 'px' }"
|
||||
>
|
||||
<vue-scroll :style="{height: backimgFontSize * 6 + 'px'}">
|
||||
<li
|
||||
class="text2-item"
|
||||
v-for="( item, i ) in scoreRecord "
|
||||
:key="item.id"
|
||||
:style="{ height: backimgFontSize * 2 + 'px', paddingTop: backimgFontSize * 0.33 + 'px', width: ((backimgFontSize * 13.35) - 25) + 'px' }"
|
||||
:style="{ paddingTop: backimgFontSize * 0.33 + 'px', width: ((backimgFontSize * 13.35) - 25) + 'px' }"
|
||||
>{{ i + 1 }}. {{ item.deductReason }}</li>
|
||||
<!-- height: backimgFontSize * 2 + 'px', -->
|
||||
</vue-scroll>
|
||||
</ul>
|
||||
</div>
|
||||
<div
|
||||
class="foot"
|
||||
v-if="WorkerInfo.safeScore >= 90"
|
||||
:style="{ 'color': fontColor, paddingTop: backimgFontSize * 0.4 + 'px', fontSize: backimgFontSize * 0.9 + 'px' }"
|
||||
:style="{ 'color': fontColor, 'left': '40%', paddingTop: backimgFontSize * 0.4 + 'px', fontSize: backimgFontSize * 0.9 + 'px' }"
|
||||
>
|
||||
可通行
|
||||
</div>
|
||||
<div
|
||||
class="foot"
|
||||
v-if="WorkerInfo.safeScore >= 80 && WorkerInfo.safeScore < 90"
|
||||
:style="{ 'color': fontColor, paddingTop: backimgFontSize * 0.2 + 'px', fontSize: backimgFontSize * 0.9 + 'px' }"
|
||||
:style="{ 'color': fontColor, 'left': '21%', paddingTop: backimgFontSize * 0.2 + 'px', fontSize: backimgFontSize * 0.9 + 'px' }"
|
||||
>
|
||||
安全分已经低于90分
|
||||
</div>
|
||||
<div
|
||||
class="foot"
|
||||
v-if="WorkerInfo.safeScore < 80"
|
||||
:style="{ 'color': fontColor, paddingTop: backimgFontSize * 0.2 + 'px', fontSize: backimgFontSize * 0.9 + 'px' }"
|
||||
:style="{ 'color': fontColor, 'left': '21%', paddingTop: backimgFontSize * 0.2 + 'px', fontSize: backimgFontSize * 0.9 + 'px' }"
|
||||
>
|
||||
安全分已经低于80分
|
||||
</div>
|
||||
@ -452,7 +454,8 @@ export default {
|
||||
}
|
||||
|
||||
.content-down {
|
||||
height: 45.5%;
|
||||
// height: 45.5%;
|
||||
height: 40.5%;
|
||||
}
|
||||
|
||||
.upDiv {
|
||||
@ -535,6 +538,9 @@ li {
|
||||
font-size: 1.3rem;
|
||||
font-weight: bold;
|
||||
text-align: center;
|
||||
position: absolute;
|
||||
bottom: 4%;
|
||||
z-index: 10;
|
||||
}
|
||||
|
||||
.down-up {
|
||||
@ -545,8 +551,10 @@ li {
|
||||
|
||||
|
||||
.downDiv {
|
||||
/* height: 100%; */
|
||||
|
||||
height: 100%;
|
||||
position: relative;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
}
|
||||
|
||||
.downHear {
|
||||
|
||||
@ -10,14 +10,9 @@
|
||||
placeholder="请输入身份证号码"
|
||||
v-model="value"
|
||||
maxlength="18"
|
||||
>
|
||||
</div>
|
||||
<div
|
||||
class="anniu"
|
||||
@click="toQR"
|
||||
>
|
||||
查看二维码
|
||||
/>
|
||||
</div>
|
||||
<div class="anniu" @click="toQR">查看二维码</div>
|
||||
<div class="p">
|
||||
<p v-if="!isValidIdCard">请输入有效的身份证号码!</p>
|
||||
</div>
|
||||
@ -29,9 +24,9 @@
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { entryCodeApi } from '@/assets/js/api/safeManage.js'
|
||||
import { entryCodeApi } from "@/assets/js/api/safeManage.js";
|
||||
export default {
|
||||
name: 'myLogin',
|
||||
name: "myLogin",
|
||||
data() {
|
||||
return {
|
||||
value: "",
|
||||
@ -40,12 +35,11 @@ export default {
|
||||
projectSn: "",
|
||||
userId: "",
|
||||
id: "",
|
||||
}
|
||||
};
|
||||
},
|
||||
|
||||
mounted() {
|
||||
this.getQuery();
|
||||
|
||||
},
|
||||
|
||||
methods: {
|
||||
@ -57,7 +51,7 @@ export default {
|
||||
async selectWorkerInfo() {
|
||||
const params = {
|
||||
// projectSn: this.projectSn,
|
||||
idCard: this.value
|
||||
idCard: this.value,
|
||||
};
|
||||
// const idCard = this.value;
|
||||
const res = await entryCodeApi(params);
|
||||
@ -65,36 +59,38 @@ export default {
|
||||
if (res.success == true) {
|
||||
this.id = res.result.id;
|
||||
console.log("this.id:" + this.id);
|
||||
this.$router.push({ name: '准入二维码_详情', params: { WorkerInfo: res.result, projectSn: this.projectSn } })
|
||||
this.$router.push({
|
||||
name: "准入二维码_详情",
|
||||
params: { WorkerInfo: res.result, projectSn: this.projectSn },
|
||||
});
|
||||
// this.$router.push({path: '/entryCodeDetail'});
|
||||
} else {
|
||||
console.log("没有查到信息");
|
||||
}
|
||||
|
||||
},
|
||||
|
||||
validateIdCard() {
|
||||
// 身份证号码正则表达式,简单示例
|
||||
const idCardRegex = /^[1-9]\d{5}(19|20)\d{2}(0[1-9]|1[0-2])([0-2][1-9]|10|20|30)\d{3}[\dX]$/;
|
||||
const idCardRegex =
|
||||
/^[1-9]\d{5}(19|20)\d{2}(0[1-9]|1[0-2])([0-2][1-9]|10|20|30)\d{3}[\dX]$/;
|
||||
// 验证身份证号码格式
|
||||
this.isValidIdCard = idCardRegex.test(this.value);
|
||||
},
|
||||
toQR() {
|
||||
if (this.value != null && this.value != "") {
|
||||
this.iscunzai = true
|
||||
this.iscunzai = true;
|
||||
this.validateIdCard();
|
||||
if (this.isValidIdCard) {
|
||||
console.log("身份证号:" + this.value);
|
||||
this.selectWorkerInfo();
|
||||
}
|
||||
} else {
|
||||
this.isValidIdCard = true
|
||||
this.iscunzai = false
|
||||
this.isValidIdCard = true;
|
||||
this.iscunzai = false;
|
||||
}
|
||||
},
|
||||
}
|
||||
|
||||
}
|
||||
},
|
||||
};
|
||||
</script>
|
||||
|
||||
<style scoped lang="less">
|
||||
@ -119,16 +115,15 @@ export default {
|
||||
}
|
||||
|
||||
.input {
|
||||
width: 90%;
|
||||
margin: 0 auto;
|
||||
width: 100%;
|
||||
margin-top: 40%;
|
||||
}
|
||||
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
input {
|
||||
font-size: 1.3rem;
|
||||
text-align: center;
|
||||
height: 2.5rem;
|
||||
width: 100%;
|
||||
width: 88%;
|
||||
border: rgb(165, 165, 165) solid 0.08rem;
|
||||
border-radius: 0.41rem;
|
||||
}
|
||||
@ -146,6 +141,7 @@ input::-ms-input-placeholder {
|
||||
input::-webkit-input-placeholder {
|
||||
text-align: center;
|
||||
}
|
||||
}
|
||||
|
||||
.title {
|
||||
font-size: 1.6rem;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user