@@ -29,6 +29,36 @@ | |||
<n-image class="image_size" :src="form.fileMarkerUrl" alt="" width="120" /> | |||
</n-form-item> | |||
</n-form> | |||
<n-form | |||
v-if="showResultForm" | |||
:model="resultForm" | |||
:label-width="80" | |||
label-placement="left" | |||
require-mark-placement="left" | |||
> | |||
<n-form-item label="处理状态:"> | |||
<span>{{ resultList[resultForm.status] }}</span> | |||
</n-form-item> | |||
<n-form-item label="处理图片:"> | |||
<div class="handle_image"> | |||
<n-image | |||
v-for="(item,index) in resultForm.images" | |||
:key="index" | |||
class="image_size" | |||
:src="item" | |||
alt="" | |||
width="120" | |||
/> | |||
</div> | |||
</n-form-item> | |||
<n-form-item label="处理描述:"> | |||
<span>{{ resultForm.handlerResult }}</span> | |||
</n-form-item> | |||
<n-form-item label="处理时间:"> | |||
<span>{{ resultForm.handlerTime }}</span> | |||
</n-form-item> | |||
</n-form> | |||
</div> | |||
<div v-if="positionType === 'handle'" class="btn_list"> | |||
<n-button v-if="form.status !== 1" class="btn_item" type="primary" @click="makeSure">确定</n-button> | |||
@@ -39,6 +69,7 @@ | |||
<script> | |||
import { toRefs, reactive, watch, inject } from 'vue' | |||
import { QUESTION_TYPE } from '@/utils/dictionary.js' | |||
import { orderDetail } from '@/api/order/index.js' | |||
export default { | |||
name: 'OverLay', | |||
props: { | |||
@@ -49,6 +80,10 @@ export default { | |||
type: { | |||
type: String, | |||
default: '' | |||
}, | |||
showResult: { | |||
type: Boolean, | |||
default: false | |||
} | |||
}, | |||
emits: { | |||
@@ -57,6 +92,9 @@ export default { | |||
setup(props, { emit }) { | |||
const data = reactive({ | |||
form: {}, | |||
resultForm: {}, | |||
resultList: { 0: '待处理', 1: '已处理' }, | |||
showResultForm: false, | |||
positionType: '', | |||
typeList: [] | |||
}) | |||
@@ -67,7 +105,16 @@ export default { | |||
data.positionType = props.type | |||
data.typeList = QUESTION_TYPE | |||
data.form = Object.assign({}, props.data) | |||
if (props.showResult && props.data.status === 1) { | |||
orderDetail({ questionId: props.data.questionId }) | |||
.then(res => { | |||
data.showResultForm = true | |||
data.resultForm = res.data.questionHandle | |||
data.resultForm.images = res.data.questionHandle.handlerImage.split(',') | |||
}) | |||
} | |||
}) | |||
const updateVisible = function() { | |||
emit('close') | |||
} | |||
@@ -135,4 +182,13 @@ export default { | |||
margin-left: 20px; | |||
} | |||
.handle_image{ | |||
display: flex; | |||
flex-wrap: wrap; | |||
justify-content: space-between; | |||
.n-image{ | |||
margin: 0 0 5px 0; | |||
} | |||
} | |||
</style> |
@@ -2,7 +2,7 @@ | |||
<div class="main_container"> | |||
<div id="track" ref="map" /> | |||
<div id="pointOverlay" class="point_overlay"> | |||
<over-lay :data="problemData" :type="positionType" @close="closeOverlay" /> | |||
<over-lay :data="problemData" :show-result="showResult" :type="positionType" @close="closeOverlay" /> | |||
</div> | |||
<ul v-if="showLegend" class="legend_list"> | |||
@@ -43,6 +43,10 @@ export default { | |||
showLegend: { | |||
type: Boolean, | |||
default: true | |||
}, | |||
showResult: { | |||
type: Boolean, | |||
default: false | |||
} | |||
}, | |||
emits: {}, |
@@ -1,7 +1,7 @@ | |||
<template> | |||
<n-drawer v-bind="getDrawerOptions" @update:show="handleDrawerColse"> | |||
<n-drawer-content closable title="图片位置"> | |||
<PositionMsg :data="getPostionOptions" :show-legend="false" /> | |||
<PositionMsg :data="getPostionOptions" show-result :show-legend="false" /> | |||
</n-drawer-content> | |||
</n-drawer> | |||
</template> |
@@ -1,4 +1,4 @@ | |||
import { QUESTION_TYPE, QUES_STATUS } from '@/utils/dictionary.js' | |||
import { QUES_STATUS } from '@/utils/dictionary.js' | |||
import TableImage from '@/components/DataTable/tools/Image.vue' | |||
import TableTags from '@/components/DataTable/tools/Tags.vue' | |||
import TableAction from '@/components/DataTable/tools/Action.vue' |
@@ -8,7 +8,6 @@ const tableRef = ref() | |||
const searchParams = ref() | |||
function handleSearch(params) { | |||
console.log(params) | |||
searchParams.value = { ...params } | |||
if (params?.time?.length) { | |||
searchParams.value = { |
@@ -93,6 +93,11 @@ export default defineComponent({ | |||
return { | |||
...list | |||
} | |||
} else if (props.data.status === 0) { | |||
const list = form.formItem.filter((item) => !item.handle) | |||
return { | |||
...list | |||
} | |||
} else { | |||
return { | |||
...form.formItem |
@@ -14,7 +14,9 @@ export const form = reactive({ | |||
{ type: 'input', key: 'createTime', label: '问题发现时间', props: { disabled: true }}, | |||
{ type: 'image', key: 'fileMarkerUrl', label: '问题图片', props: { width: 100 }}, | |||
{ type: 'select', key: 'status', label: '问题状态', props: { options: QUES_STATUS, disabled: true }}, | |||
{ type: 'oss', refIndex: 0, key: 'imageStatus', file: 'handlerImage', label: '封面', mode: true }, | |||
{ type: 'input', key: 'handlerTime', label: '处理时间', props: { disabled: true }, mode: true, handle: true }, | |||
{ type: 'input', key: 'handlerUserName', label: '处理人员', props: { disabled: true }, mode: true, handle: true }, | |||
{ type: 'oss', refIndex: 0, key: 'imageStatus', file: 'handlerImage', label: '处理图片', mode: true }, | |||
{ type: 'input', key: 'handlerResult', label: '描述', props: { type: 'textarea', maxlength: 255 }, mode: true } | |||
] | |||
}) |
@@ -14,8 +14,9 @@ export const form = reactive({ | |||
{ type: 'input', key: 'createTime', label: '问题发现时间', props: { disabled: true }}, | |||
{ type: 'image', key: 'fileMarkerUrl', label: '问题图片', props: { width: 100 }}, | |||
{ type: 'select', key: 'status', label: '问题状态', props: { options: QUES_STATUS, disabled: true }}, | |||
{ type: 'oss', refIndex: 0, key: 'imageStatus', file: 'handlerImage', label: '封面', mode: true }, | |||
{ type: 'input', key: 'handlerResult', label: '描述', props: { type: 'textarea', maxlength: 255 }, mode: true } | |||
{ type: 'oss', refIndex: 0, key: 'imageStatus', file: 'handlerImage', label: '处理结果', mode: true }, | |||
{ type: 'input', key: 'handlerResult', label: '描述', props: { type: 'textarea', maxlength: 255 }, mode: true }, | |||
{ type: 'input', key: 'handlerUserName', label: '处理人', mode: true } | |||
] | |||
}) | |||
@@ -59,8 +59,8 @@ | |||
<n-gi><span>{{ item.questionDesc ? item.questionDesc : '-' }}</span></n-gi> | |||
<n-gi><span>问题图片</span></n-gi> | |||
<n-gi><n-image :src="item.fileMarkerUrl" /></n-gi> | |||
<n-gi v-if="type === 'result' && item.questionHandleList.length"><span>处理结果</span></n-gi> | |||
<n-gi v-if="type === 'result' && item.questionHandleList.length"><n-image v-for="(cItem,cIndex) in item.questionHandleList" :key="cIndex" :src="cItem.handlerImage" /></n-gi> | |||
<n-gi v-if="type === 'result' && item.list.length"><span>处理结果</span></n-gi> | |||
<n-gi v-if="type === 'result' && item.list.length"><n-image v-for="(cItem,cIndex) in item.list" :key="cIndex" :src="cItem" /></n-gi> | |||
</n-grid> | |||
</div> | |||
<!-- </n-image-group> --> | |||
@@ -141,6 +141,10 @@ export default defineComponent({ | |||
}) | |||
data.problemsList.push(obj) | |||
}) | |||
data.reportDetail.questionReportList.forEach((item) => { | |||
const list = item.questionHandleList[0]?.handlerImage.split(',') || [] | |||
item.list = list | |||
}) | |||
// data.reportDetail.questionReportList.forEach((item, index) => { | |||
// if (index === 0)item.fileMarkerUrl = 'https://image.t-aaron.com/XJRW20220720165837/2022-07-20-17-07-34_frame-6563-6720_type-%E6%B0%B4%E7%94%9F%E6%A4%8D%E8%A2%AB_o3MORSWHXz5pQ8F9_s-live-XJRW20220720165837-a0ec218ddd884ffcadd4f3c8fc27d825_AI.jpg' | |||
// if (index === 1)item.fileMarkerUrl = 'https://image.t-aaron.com/XJRW20220720165837/2022-07-20-17-04-30_frame-1802-1920_type-%E6%B0%B4%E7%94%9F%E6%A4%8D%E8%A2%AB_b0N6GXoM178nUxhC_s-live-XJRW20220720165837-a0ec218ddd884ffcadd4f3c8fc27d825_AI.jpg' |
@@ -8,7 +8,7 @@ import { taskDelete, implement } from '@/api/task/index.js' | |||
const tableRef = ref() | |||
const searchParams = ref() | |||
function handleSearch (params) { | |||
function handleSearch(params) { | |||
searchParams.value = { ...params } | |||
tableRef.value.reFetch({ searchParams }) | |||
} | |||
@@ -19,13 +19,13 @@ function handleSearch (params) { | |||
* @param {*} type 操作类型 create:创建,preview:预览,edit:编辑 | |||
* @return {*} | |||
*/ | |||
function getRowData (row, type) { | |||
function getRowData(row, type) { | |||
data.rowData = row | |||
data.modalType = type | |||
data.modalShow = true | |||
} | |||
function handleRowDelete (row) { | |||
function handleRowDelete(row) { | |||
taskDelete(row.id) | |||
.then(res => { | |||
if (res.code === 0) { | |||
@@ -34,7 +34,7 @@ function handleRowDelete (row) { | |||
}) | |||
} | |||
function handleImplement (row) { | |||
function handleImplement(row) { | |||
$message.info('机场设备开始自检,请稍等') | |||
implement(row.id) | |||
@@ -46,19 +46,19 @@ function handleImplement (row) { | |||
} | |||
/* 直播 */ | |||
function handleTaskLive (row) { | |||
function handleTaskLive(row) { | |||
data.rowData = row | |||
data.liveDrawer = true | |||
} | |||
/* 回放 */ | |||
function handleTaskDemand (row) { | |||
function handleTaskDemand(row) { | |||
data.rowData = row | |||
data.demandDrawer = true | |||
} | |||
/* 问题核实 */ | |||
function handleTaskVerify (row) { | |||
function handleTaskVerify(row) { | |||
data.rowData = row | |||
data.verifyDrawer = true | |||
} | |||
@@ -97,7 +97,7 @@ const data = reactive({ | |||
title: '巡检方式', | |||
key: 'inspectionType', | |||
align: 'center', | |||
render (row) { | |||
render(row) { | |||
return h(TableTags, { | |||
data: row.inspectionType, | |||
filters: TASK_MODE | |||
@@ -118,7 +118,7 @@ const data = reactive({ | |||
title: '任务类型', | |||
key: 'type', | |||
align: 'center', | |||
render (row) { | |||
render(row) { | |||
return h(TableTags, { | |||
data: row.type, | |||
filters: TASK_TYPE | |||
@@ -134,7 +134,7 @@ const data = reactive({ | |||
title: '状态', | |||
key: 'status', | |||
align: 'center', | |||
render (row) { | |||
render(row) { | |||
return h(TableTags, { | |||
data: row.status, | |||
filters: TASK_STATUS | |||
@@ -147,7 +147,7 @@ const data = reactive({ | |||
align: 'center', | |||
width: 150, | |||
fixed: 'right', | |||
render (row) { | |||
render(row) { | |||
return h(TableAction, { | |||
actions: [ | |||
{ | |||
@@ -219,7 +219,7 @@ const data = reactive({ | |||
onClick: handleTaskVerify.bind(null, row) | |||
}, | |||
auth: 'basic_list', | |||
show: row.status !== 1 | |||
show: row.status !== 1 && row.status !== 3 | |||
} | |||
], | |||
align: 'center' |
@@ -1,4 +1,4 @@ | |||
import { QUESTION_STATUS, QUESTION_TYPE } from '@/utils/dictionary.js' | |||
import { QUESTION_STATUS, QUESTION_TYPE, ORDER_STATUS } from '@/utils/dictionary.js' | |||
import TableTags from '@/components/DataTable/tools/Tags.vue' | |||
import TableImage from '@/components/DataTable/tools/Image.vue' | |||
import TableAction from '@/components/DataTable/tools/Action.vue' | |||
@@ -161,7 +161,7 @@ const data = reactive({ | |||
render(row) { | |||
return h(TableTags, { | |||
data: row.status, | |||
filters: QUESTION_STATUS | |||
filters: ORDER_STATUS | |||
}) | |||
} | |||
}, | |||
@@ -185,7 +185,7 @@ const data = reactive({ | |||
type: 'primary' | |||
}, | |||
auth: 'basic_list', | |||
hidden: row.status === 2 | |||
hidden: row.wordOrderStatus === 1 || row.status === 2 | |||
}, | |||
{ | |||
label: '确认', | |||
@@ -199,7 +199,7 @@ const data = reactive({ | |||
type: 'primary' | |||
}, | |||
auth: 'basic_list', | |||
hidden: row.status === 1 | |||
hidden: row.wordOrderStatus === 1 || row.status === 1 | |||
} | |||
], | |||
align: 'center' |