故障查询调整

This commit is contained in:
joylink_zhaoerwei 2024-11-12 17:28:58 +08:00
parent 9ac2c2dc59
commit 52fbdba1af

View File

@ -53,19 +53,18 @@
}} }}
</div> </div>
<div class="text"> <div class="text">
<span class="textHead"> 消息名称(故障现象)</span>{{ <span class="textHead"> {{ showTitle.faultNameShower }}</span
clickRowInfo.faultNameShower >{{ clickRowInfo.faultNameShower }}
}}
</div> </div>
<q-card class="box-card"> <q-card class="box-card">
<div class="head">司机处理结果(服务故障现象)</div> <div class="head">{{ showTitle.faultDriverShower }}</div>
<q-separator /> <q-separator />
<div> <div>
<div class="detail">{{ clickRowInfo.faultDriverShower }}</div> <div class="detail">{{ clickRowInfo.faultDriverShower }}</div>
</div> </div>
</q-card> </q-card>
<q-card class="box-card"> <q-card class="box-card">
<div class="head">司机关键点(退出服务地点)</div> <div class="head">{{ showTitle.resultMsg }}</div>
<q-separator /> <q-separator />
<div> <div>
<div class="detail">{{ clickRowInfo.resultMsg }}</div> <div class="detail">{{ clickRowInfo.resultMsg }}</div>
@ -199,6 +198,7 @@ const onRequest: QTable['onRequest'] = async (props) => {
pagination.value.rowsNumber = resp.total; pagination.value.rowsNumber = resp.total;
pagination.value.rowsPerPage = resp.size; pagination.value.rowsPerPage = resp.size;
rows.splice(0, rows.length, ...(resp.records as [])); rows.splice(0, rows.length, ...(resp.records as []));
handleRowClick(rows[0]);
} catch (err) { } catch (err) {
$q.notify({ $q.notify({
type: 'negative', type: 'negative',
@ -216,7 +216,21 @@ const clickRowInfo = reactive({
faultDriverShower: '', faultDriverShower: '',
resultMsg: '', resultMsg: '',
}); });
const showTitle = reactive({
faultNameShower: '',
faultDriverShower: '',
resultMsg: '',
});
function handleRowClick(row: FaultQueryListItem) { function handleRowClick(row: FaultQueryListItem) {
if (row.faultType.includes('FAULT_EMERGENCY_GUIDE')) {
showTitle.faultNameShower = '故障现象';
showTitle.faultDriverShower = '司机处理结果';
showTitle.resultMsg = '行调提醒司机关键点';
} else {
showTitle.faultNameShower = '故障名称';
showTitle.faultDriverShower = '故障现象';
showTitle.resultMsg = '退出服务地点';
}
clickRowInfo.id = row?.id as number; clickRowInfo.id = row?.id as number;
clickRowInfo.faultType = getFaultTypeName(row) as string; clickRowInfo.faultType = getFaultTypeName(row) as string;
clickRowInfo.faultNameShower = row.faultNameShower; clickRowInfo.faultNameShower = row.faultNameShower;
@ -281,7 +295,7 @@ const onDialogShow = () => {
<style lang='scss' scoped> <style lang='scss' scoped>
.changeBackground { .changeBackground {
background-color: orange; /* 浅蓝色 */ background-color: #31ccec;
} }
.custom-column { .custom-column {
overflow: hidden; overflow: hidden;