Commit b512b8d8 authored by 田翔's avatar 田翔

fix: 反馈状态标签优化

parent 218079eb
{
"name": "panda-xform",
"version": "6.9.8",
"description": "6.9.8 区域任务控件增加操作列",
"version": "6.9.10",
"description": "6.9.10 反馈状态标签优化",
"keywords": [
"panda-xform"
],
......
......@@ -17,7 +17,7 @@ const TagPack = (props) => {
return (
<span
className={styles.tagPack}
style={{ background: hexToRgba(color, 0.4), color: color, border: color ? '1px solid' : 'none' }}
style={{ background: hexToRgba(color, 0.3), color: color, border: color ? '1px solid' : 'none' }}
>
{text}
{onClose ? <CloseOutlined style={{ fontSize: '12px', marginLeft: '2px' }} onClick={() => onClose()} /> : null}
......
......@@ -23,6 +23,7 @@ import {
GetCaseGISAreaData,
} from '../../../../apis/process'
import FileView from '../../../Account/components/TablePack/components/FileView'
import TagPack from '../../../components/TagPack'
const getRings = (rings) => {
rings = rings.map(ring => {
......@@ -126,6 +127,23 @@ const AreaTask = (props) => {
return <FileView value={row[`${v.fieldType}-${v.fieldName}`]} {...schema} />
}
})
} else if (v.fieldType === '台账' && v.fieldName === '反馈状态') {
array.push({
title: v.fieldAliasName,
dataIndex: isGIS ? v.fieldName : `${v.fieldType}-${v.fieldName}`,
key: isGIS ? v.fieldName : `${v.fieldType}-${v.fieldName}`,
render: (_, row) => {
if (!row['台账-反馈状态']) return null
let color = 'rgb(75, 172, 25)'
if (row['台账-反馈状态'] === '进行中') {
color = 'rgb(255, 169, 64)'
}
if (row['台账-反馈状态'] === '被驳回') {
color = 'rgb(255, 77, 79)'
}
return <TagPack color={color} text={row['台账-反馈状态']} />
}
})
} else {
array.push({
title: v.fieldAliasName,
......@@ -412,7 +430,7 @@ const AreaTask = (props) => {
let params = {
user: userID,
mapServerName: service,
caseNo: codes['工单编号'],
caseNo: codes['工单编号'] || 'QB-2024-0000088',
feedbackTableName: tableName,
caseTableName: tableNameParent,
// sortFields: '录入时间',
......@@ -422,7 +440,7 @@ const AreaTask = (props) => {
// pageSize: 0,
// queryWheres: [{ field: '工单编号', type: '等于', value: codes['工单编号'] }],
}
if (!codes['工单编号']) return
// if (!codes['工单编号']) return
const { code, data, msg } = await GetCaseGISAreaData(params)
if (code === 0) {
setDataSource(data)
......
......@@ -40,6 +40,7 @@ const Device = (props) => {
const getView = (mapObj, Map, extentInfos, layersInfo) => {
if (mapObj && layersInfo && !isSendQueryRef.current) {
setTimeout(() => {
let gisCode = ''
let gisLayerName = ''
let values = addons?.getValues()
......@@ -118,6 +119,7 @@ const Device = (props) => {
}
})
}
}, 500)
isSendQueryRef.current = true
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment