|
@@ -43,10 +43,10 @@
|
|
|
/>
|
|
|
</el-select>
|
|
|
</el-form-item>
|
|
|
- <el-form-item label="刷新时间间隔">
|
|
|
- <el-select v-model="value" @change="change()" placeholder="请选择刷新时间" clearable size="small" style="width: 100%" >
|
|
|
+ <el-form-item label="刷新时间" labelWidth="80px">
|
|
|
+ <el-select v-model="timerValue" @change="timerChange()" placeholder="" clearable size="small" style="width: 50%" >
|
|
|
<el-option
|
|
|
- v-for="item in options"
|
|
|
+ v-for="item in timerOptions"
|
|
|
:key="item.value"
|
|
|
:label="item.label"
|
|
|
:value="item.value">
|
|
@@ -126,27 +126,27 @@ import { clearLocRequest,locationInvView,queryLocationZoneDict,lockLocRequest,lo
|
|
|
export default {
|
|
|
data () {
|
|
|
return {
|
|
|
- options: [{
|
|
|
+ timerOptions: [{
|
|
|
value: 60000,
|
|
|
- label: '1min'
|
|
|
+ label: '1分钟'
|
|
|
}, {
|
|
|
value: 300000,
|
|
|
- label: '5min'
|
|
|
+ label: '5分钟'
|
|
|
}, {
|
|
|
value: 600000,
|
|
|
- label: '10min'
|
|
|
+ label: '10分钟'
|
|
|
}, {
|
|
|
value: 900000,
|
|
|
- label: '15min'
|
|
|
+ label: '15分钟'
|
|
|
}, {
|
|
|
value: 1200000,
|
|
|
- label: '20min'
|
|
|
+ label: '20分钟'
|
|
|
},
|
|
|
{
|
|
|
value: 5000,
|
|
|
- label: '5s'
|
|
|
+ label: '5秒'
|
|
|
}],
|
|
|
- value: 5000,
|
|
|
+ timerValue: 5000,
|
|
|
open: false,
|
|
|
showSearch: true,
|
|
|
dataForm: {
|
|
@@ -193,15 +193,21 @@ import { clearLocRequest,locationInvView,queryLocationZoneDict,lockLocRequest,lo
|
|
|
this.getBasZoneList()
|
|
|
this.getDataList()
|
|
|
this.getItemopention()
|
|
|
- this.timer = setInterval(this.getDataList, this.value);
|
|
|
+ this.timer = setInterval(this.getDataList, this.timerValue);
|
|
|
+ },
|
|
|
+ beforeDestroy () {
|
|
|
+ clearInterval(this.timer)
|
|
|
},
|
|
|
methods: {
|
|
|
- beforeDestroy () {
|
|
|
+ handleQuery() {
|
|
|
+ this.getDataList();
|
|
|
+ },
|
|
|
+ clearInterval () {
|
|
|
clearInterval(this.timer)
|
|
|
},
|
|
|
- change(){
|
|
|
- this.beforeDestroy ();
|
|
|
- this.timer = setInterval(this.getDataList, this.value);
|
|
|
+ timerChange(){
|
|
|
+ this.clearInterval ();
|
|
|
+ this.timer = setInterval(this.getDataList, this.timerValue);
|
|
|
},
|
|
|
getItemopention(){
|
|
|
lotattConfigList().then(response => {
|
|
@@ -228,7 +234,6 @@ import { clearLocRequest,locationInvView,queryLocationZoneDict,lockLocRequest,lo
|
|
|
resetQuery() {//重置搜索
|
|
|
this.resetForm("queryForm");
|
|
|
this.getDataList();
|
|
|
- this.handleQuery();
|
|
|
},
|
|
|
selected(item) {
|
|
|
if (item.locationNo) {
|