首检完成
This commit is contained in:
@@ -21,12 +21,10 @@
|
||||
<div class="title_sub">{{ paint[0].inspectionModule }}</div>
|
||||
<div class="grid_sub">
|
||||
<div class="a_11" v-for="(item, index) of paint" :key="index">
|
||||
<div @click="Accumulator(item, index)" class="button_">
|
||||
|
||||
<div @click="Accumulator(item, index)" class="button_" @mousedown="startimer(item.counter, 'paint', index)" @mouseup="clearTimer">
|
||||
<div class="context">{{ item.inspectionName }}</div>
|
||||
<el-input-number style="margin-bottom: 0px;" size="mini" v-model="item.counter" @change="handleChange"></el-input-number>
|
||||
<div class="number">{{ item.counter }}</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -34,9 +32,14 @@
|
||||
<div class="title_sub">{{ device[0].inspectionModule }}</div>
|
||||
<div class="grid_sub">
|
||||
<div class="a_11" v-for="(item, index) of device" :key="index">
|
||||
<div @click="Accumulator(item, index)" class="button_">
|
||||
<div
|
||||
@click="Accumulator(item, index)"
|
||||
class="button_"
|
||||
@mousedown="startimer(item.counter, 'device', index)"
|
||||
@mouseup="clearTimer"
|
||||
>
|
||||
<div class="context">{{ item.inspectionName }}</div>
|
||||
<span role="button" class="el-input-number__decrease"><i class="el-icon-minus"></i></span>
|
||||
<div class="number">{{ item.counter }}</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -45,10 +48,9 @@
|
||||
<div class="title_sub">{{ blank[0].inspectionModule }}</div>
|
||||
<div class="grid_sub">
|
||||
<div class="a_11" v-for="(item, index) of blank" :key="index">
|
||||
<div @click="Accumulator(item, index)" class="button_">
|
||||
<el-badge :value="item.counter" type="primary"
|
||||
><div class="context">{{ item.inspectionName }}</div></el-badge
|
||||
>
|
||||
<div @click="Accumulator(item, index)" class="button_" @mousedown="startimer(item.counter, 'blank', index)" @mouseup="clearTimer">
|
||||
<div class="context">{{ item.inspectionName }}</div>
|
||||
<div class="number">{{ item.counter }}</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -57,10 +59,14 @@
|
||||
<div class="title_sub">{{ program[0].inspectionModule }}</div>
|
||||
<div class="grid_sub">
|
||||
<div class="a_11" v-for="(item, index) of program" :key="index">
|
||||
<div @click="Accumulator(item, index)" class="button_">
|
||||
<el-badge :value="item.counter" type="primary"
|
||||
><div class="context">{{ item.inspectionName }}</div></el-badge
|
||||
>
|
||||
<div
|
||||
@click="Accumulator(item, index)"
|
||||
class="button_"
|
||||
@mousedown="startimer(item.counter, 'program', index)"
|
||||
@mouseup="clearTimer"
|
||||
>
|
||||
<div class="context">{{ item.inspectionName }}</div>
|
||||
<div class="number">{{ item.counter }}</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -69,17 +75,16 @@
|
||||
<div class="title_sub">{{ team[0].inspectionModule }}</div>
|
||||
<div class="grid_sub">
|
||||
<div class="a_11" v-for="(item, index) of team" :key="index">
|
||||
<div @click="Accumulator(item, index)" class="button_">
|
||||
<el-badge :value="item.counter" type="primary"
|
||||
><div class="context">{{ item.inspectionName }}</div></el-badge
|
||||
>
|
||||
<div @click="Accumulator(item, index)" class="button_" @mousedown="startimer(item.counter, 'team', index)" @mouseup="clearTimer">
|
||||
<div class="context">{{ item.inspectionName }}</div>
|
||||
<div class="number">{{ item.counter }}</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="f">
|
||||
<div class="f_item">
|
||||
<div class="f_name">工单id:{{ ProductSituationForm.workorderid }}</div>
|
||||
<div class="f_name">工单id:{{ ProductSituationForm.workorderid }}</div>
|
||||
</div>
|
||||
<div class="f_item">
|
||||
<div class="f_name">产品名称:{{ ProductSituationForm.productName }}</div>
|
||||
@@ -98,11 +103,31 @@
|
||||
<div class="f_item">
|
||||
<div class="f_name">投入数:{{ ProductSituationForm.inputNum }}</div>
|
||||
</div>
|
||||
<div class="f_item">
|
||||
<div class="f_name">一次合格数:{{ ProductSituationForm.inputNum }}</div>
|
||||
</div>
|
||||
<div class="f_item">
|
||||
<div class="f_name">一次合格率:{{ ProductSituationForm.inputNum }}</div>
|
||||
</div>
|
||||
<div class="f_item">
|
||||
<div class="f_name">打磨数:{{ ProductSituationForm.inputNum }}</div>
|
||||
</div>
|
||||
<div class="f_item">
|
||||
<div class="f_name">报废数:{{ ProductSituationForm.inputNum }}</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</el-col>
|
||||
</el-row>
|
||||
|
||||
<el-dialog title="修改" :visible.sync="DMLdialog.visiable" width="600px" append-to-body>
|
||||
<el-input-number v-model="toUpdateNum" label="修改"></el-input-number>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button @click="DMLdialog.visiable = false">取 消</el-button>
|
||||
<el-button @click="confirm">确认</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
@@ -129,6 +154,13 @@ export default {
|
||||
},
|
||||
signal: null,
|
||||
data: null,
|
||||
timer: null,
|
||||
DMLdialog: {
|
||||
visiable: false,
|
||||
},
|
||||
toUpdateNum: 0, //弹窗更新值
|
||||
toname: '',
|
||||
toindex: 0, //索引
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
@@ -230,6 +262,41 @@ export default {
|
||||
break
|
||||
}
|
||||
},
|
||||
//todo 长按事件
|
||||
startimer(value, name, index) {
|
||||
this.timer = setTimeout(() => {
|
||||
this.toUpdateNum = value
|
||||
this.DMLdialog.visiable = true
|
||||
this.toname = name
|
||||
this.toindex = index
|
||||
}, 1000)
|
||||
},
|
||||
clearTimer() {
|
||||
clearTimeout(this.timer)
|
||||
},
|
||||
//todo 弹窗确认事件
|
||||
confirm() {
|
||||
switch (this.toname) {
|
||||
case 'paint':
|
||||
this.paint[this.toindex].counter = this.toUpdateNum
|
||||
break
|
||||
case 'blank':
|
||||
this.device[this.toindex].counter = this.toUpdateNum
|
||||
break
|
||||
case 'team':
|
||||
this.team[this.toindex].counter = this.toUpdateNum
|
||||
break
|
||||
case 'device':
|
||||
this.device[this.toindex].counter = this.toUpdateNum
|
||||
break
|
||||
case 'program':
|
||||
this.program[this.toindex].counter = this.toUpdateNum
|
||||
break
|
||||
}
|
||||
|
||||
this.DMLdialog.visiable = false
|
||||
},
|
||||
|
||||
//todo 数据同步
|
||||
/*
|
||||
1.从后台获取数据
|
||||
@@ -267,21 +334,6 @@ export default {
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
::v-deep .el-input-number {
|
||||
width: 68px;
|
||||
}
|
||||
::v-deep .el-input-number__decrease {
|
||||
width: 15px;
|
||||
}
|
||||
|
||||
::v-deep .el-input-number__increase {
|
||||
width: 15px;
|
||||
}
|
||||
|
||||
::v-deep .el-input > .el-input__inner {
|
||||
width: 40px;
|
||||
}
|
||||
|
||||
.title {
|
||||
font-family: Arial, sans-serif;
|
||||
font-size: 30px;
|
||||
@@ -374,7 +426,7 @@ export default {
|
||||
}
|
||||
}
|
||||
.grid > * {
|
||||
height: 300px;
|
||||
height: 320px;
|
||||
background-color: #ebeef5;
|
||||
color: white;
|
||||
border-radius: 0.5em;
|
||||
@@ -383,6 +435,7 @@ export default {
|
||||
.grid_sub > * {
|
||||
height: 80px;
|
||||
background-color: #11a983;
|
||||
width: 60px;
|
||||
color: white;
|
||||
border-radius: 0.2em;
|
||||
transition: all 0.2s ease-in-out;
|
||||
@@ -395,7 +448,7 @@ export default {
|
||||
.title_Line {
|
||||
color: #409eff;
|
||||
font-family: Arial, sans-serif;
|
||||
font-size: 1.5rem;
|
||||
font-size: 1rem;
|
||||
text-align: center;
|
||||
margin-top: 40px;
|
||||
}
|
||||
@@ -404,15 +457,23 @@ export default {
|
||||
margin-left: 20px;
|
||||
}
|
||||
.f_name {
|
||||
color: #dd7118;
|
||||
color: #409eff;
|
||||
font-family: Arial, sans-serif;
|
||||
font-size: 1.2rem;
|
||||
}
|
||||
.context {
|
||||
margin: 0.5em 1em;
|
||||
font-size: 0.8rem;
|
||||
}
|
||||
.button_ {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
text-align: center;
|
||||
}
|
||||
.number {
|
||||
font-size: 1.2rem;
|
||||
text-align: center;
|
||||
color: red;
|
||||
font-weight: bold;
|
||||
}
|
||||
</style>
|
||||
|
||||
Reference in New Issue
Block a user