Commit 1a6f2b07 by 李君

优化

1 parent 7aef0de6
......@@ -6,20 +6,24 @@
<div class="inlineBlock" v-for="item in counterTypeData" :key="item.id">
<template v-if="item.key != '4'">
<p class="itemTitle" style="font-weight: 900">{{item.text}}</p>
<el-form-item :label="$t('table.alarmPensonNum')" prop="queueLengthThreshold">
{{$t('message.queuelengthmorethan')}}
<el-input-number v-model="item.queueLengthThreshold" :min="0" :controls = 'false' :precision = '0'></el-input-number> {{$t('format.perNum')}},
{{$t('message.waitingtimemorethan')}}<el-input-number v-model="item.waitTimeThreshold" :min="0" :controls = 'false' :precision = '0'></el-input-number> {{$t('format.minute')}},
{{$t('message.trolleycounts')}}<el-input-number v-model="item.trolleyThreshold" :min="0" :controls = 'false' :precision = '0'></el-input-number>{{$t('iPage.number')}}.
<!-- <el-form-item :label="$t('table.alarmPensonNum')" prop="queueLengthThreshold">
<el-input-number v-model="item.queueLengthThreshold" :min="0" :controls = 'false' :precision = '0'></el-input-number> {{$t('format.perNum')}}
</el-form-item>
<el-form-item :label="$t('table.waitingTime')" prop="waitTimeThreshold">
<el-input-number v-model="item.waitTimeThreshold" :min="0" :controls = 'false' :precision = '0'></el-input-number> {{$t('format.minute')}}
</el-form-item>
<el-form-item label="Trolle No." prop="trolleyThreshold">
<el-form-item :label="$t('table.trolleyNum')" prop="trolleyThreshold">
<el-input-number v-model="item.trolleyThreshold" :min="0" :controls = 'false' :precision = '0'></el-input-number>
</el-form-item>
<el-form-item :label="$t('table.alarmCycle')" prop="alarmInterval">
<el-input-number v-model="item.alarmInterval" :min="0" :controls = 'false' :precision = '0'></el-input-number> {{$t('format.minute')}}
</el-form-item>
</el-form-item> -->
</template>
</div>
<el-form-item :label="$t('table.alarmCycle')" prop="alarmInterval">
<el-input-number v-model="addForm.alarmInterval" :min="0" :controls = 'false' :precision = '0'></el-input-number> {{$t('format.minute')}}
</el-form-item>
<p class="info">{{$t('message.alarmInfo')}}</p>
<p class="itemTitle">{{$t('table.alarmReceiver')}}</p>
<div v-for="(item,index) in alarmReceiverList" :key='index' style="margin-top: 10px;">
......@@ -61,11 +65,11 @@ export default {
// message: this.$t('pholder.input'),
// trigger: 'blur'
// }],
// alarmInterval:[{
// required: true,
// message: this.$t('pholder.input'),
// trigger: 'blur'
// }],
alarmInterval:[{
required: true,
message: this.$t('pholder.input'),
trigger: 'blur'
}],
}
}
},
......@@ -90,10 +94,10 @@ export default {
email:arr[i]
})
}
this.addForm.alarmInterval = data[0].channelRules[0].alarmInterval
data[0].channelRules.forEach(itemR=>{
this.counterTypeData.forEach(item=>{
if(itemR.counterType == item.key){
item.alarmInterval = itemR.alarmInterval;
item.queueLengthThreshold = itemR.queueLengthThreshold;
item.trolleyThreshold = itemR.trolleyThreshold;
item.waitTimeThreshold = itemR.waitTimeThreshold;
......@@ -146,7 +150,7 @@ export default {
channelRules.push({
queueLengthThreshold:item.queueLengthThreshold,
waitTimeThreshold:item.waitTimeThreshold,
alarmInterval:item.alarmInterval,
alarmInterval:this.addForm.alarmInterval,
trolleyThreshold:item.trolleyThreshold,
counterType:item.key,
id: item.counterTypeId||null
......@@ -160,8 +164,6 @@ export default {
}
}
}
// this.addForm.queueLengthSwitch = 1
// this.addForm.waitTimeSwitch = 1
this.addForm.channelRules = channelRules
if(this.isAdd){
this.$api.queueManagementApi.addAlarmRules(this.addForm)
......
......@@ -306,7 +306,8 @@
areaId: this.searchForm.cashierAreaId,
countDate: moment(this.searchForm.countDate).format('YYYY-MM-DD'),
chartType: this.isTabChart ? "table" : "bar",
counterId: this.searchForm.cashierChannelId
counterId: this.searchForm.cashierChannelId,
counterType:this.searchForm.counterType
}
this.$api.queueManagementApi.getDistributeList(parmas).then(res => {
this.loading = false;
......@@ -362,7 +363,7 @@
queuingUrl
} = window._vionConfig;
let params =
`areaId=${this.searchForm.cashierAreaId}&counterId=${this.searchForm.cashierChannelId}&countDate=${moment(this.searchForm.countDate).format('YYYY-MM-DD')}&chartType=${this.searchForm.chartType}&mallId=${this.searchForm.mallId}`
`counterType=${this.searchForm.counterType}&areaId=${this.searchForm.cashierAreaId}&counterId=${this.searchForm.cashierChannelId}&countDate=${moment(this.searchForm.countDate).format('YYYY-MM-DD')}&chartType=${this.searchForm.chartType}&mallId=${this.searchForm.mallId}`
const downloadUrl = `${queuingUrl}/queuing/waitTime/distribute/export?${params}&localLanguage=${localStorage.getItem("lang")}&authorization=${this.$cookie.get("atoken")}&title=${encodeURI(title)}`;
window.open(downloadUrl)
}
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!