|
|
@ -93,18 +93,19 @@ |
|
|
<div v-if="!formData.isNewJoint" class="union-list-container"> |
|
|
<div v-if="!formData.isNewJoint" class="union-list-container"> |
|
|
<van-loading v-if="unionLoading" size="20" /> |
|
|
<van-loading v-if="unionLoading" size="20" /> |
|
|
<div v-else-if="unionList.length === 0" class="empty-tip">暂无联合执法数据</div> |
|
|
<div v-else-if="unionList.length === 0" class="empty-tip">暂无联合执法数据</div> |
|
|
<div v-else class="union-list"> |
|
|
<van-radio-group v-else v-model="formData.uniteCheck" direction="vertical" class="union-list" @change="onUnionChange"> |
|
|
<div |
|
|
<van-radio |
|
|
v-for="item in unionList" |
|
|
v-for="item in unionList" |
|
|
:key="item.id" |
|
|
:key="item.id" |
|
|
|
|
|
:name="String(item.id)" |
|
|
class="union-item" |
|
|
class="union-item" |
|
|
:class="{ active: formData.uniteCheck === item.id }" |
|
|
|
|
|
@click="selectUnion(item)" |
|
|
|
|
|
> |
|
|
> |
|
|
<div class="union-item-title">{{ item.bureauDeptName || '联合执法' }}</div> |
|
|
<div class="union-item-content"> |
|
|
<div class="union-item-desc">{{ item.deptTexts || item.lawText || '' }}</div> |
|
|
<div class="union-item-title">{{ item.bureauDeptName || '联合执法' }}</div> |
|
|
</div> |
|
|
<div class="union-item-desc">{{ item.deptTexts || item.lawText || '' }}</div> |
|
|
</div> |
|
|
</div> |
|
|
|
|
|
</van-radio> |
|
|
|
|
|
</van-radio-group> |
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
|
<!-- 隐藏字段用于验证联合执法 --> |
|
|
<!-- 隐藏字段用于验证联合执法 --> |
|
|
@ -198,7 +199,7 @@ const unionList = ref([]); |
|
|
const unionLoading = ref(false); |
|
|
const unionLoading = ref(false); |
|
|
|
|
|
|
|
|
onMounted(() => { |
|
|
onMounted(() => { |
|
|
const range = getEnforcementTimeDateRange(10); |
|
|
const range = getEnforcementTimeDateRange(7); |
|
|
minDate.value = range.minDate; |
|
|
minDate.value = range.minDate; |
|
|
maxDate.value = range.maxDate; |
|
|
maxDate.value = range.maxDate; |
|
|
defaultPickerValue = range.currentDate; |
|
|
defaultPickerValue = range.currentDate; |
|
|
@ -224,6 +225,7 @@ const fetchUnionList = () => { |
|
|
unionLoading.value = false; |
|
|
unionLoading.value = false; |
|
|
if (res && res.data) { |
|
|
if (res && res.data) { |
|
|
unionList.value = res.data; |
|
|
unionList.value = res.data; |
|
|
|
|
|
console.log('联合执法列表:', unionList.value); |
|
|
} |
|
|
} |
|
|
}, (err) => { |
|
|
}, (err) => { |
|
|
unionLoading.value = false; |
|
|
unionLoading.value = false; |
|
|
@ -232,8 +234,20 @@ const fetchUnionList = () => { |
|
|
}; |
|
|
}; |
|
|
|
|
|
|
|
|
const selectUnion = (item) => { |
|
|
const selectUnion = (item) => { |
|
|
props.formData.unionNo = item.unionNo || ''; |
|
|
if (props.formData.uniteCheck === item.id) { |
|
|
props.formData.uniteCheck = item.id || ''; |
|
|
props.formData.unionNo = ''; |
|
|
|
|
|
props.formData.uniteCheck = ''; |
|
|
|
|
|
} else { |
|
|
|
|
|
props.formData.unionNo = item.unionNo || ''; |
|
|
|
|
|
props.formData.uniteCheck = item.id || ''; |
|
|
|
|
|
} |
|
|
|
|
|
}; |
|
|
|
|
|
|
|
|
|
|
|
const onUnionChange = (id) => { |
|
|
|
|
|
const item = unionList.value.find(item => String(item.id) === id); |
|
|
|
|
|
if (item) { |
|
|
|
|
|
props.formData.unionNo = item.unionNo || ''; |
|
|
|
|
|
} |
|
|
}; |
|
|
}; |
|
|
|
|
|
|
|
|
const openTimePicker = () => { |
|
|
const openTimePicker = () => { |
|
|
@ -462,6 +476,7 @@ const onAfterReadImage = (file) => { |
|
|
display: flex; |
|
|
display: flex; |
|
|
flex-direction: column; |
|
|
flex-direction: column; |
|
|
gap: 0.16rem; |
|
|
gap: 0.16rem; |
|
|
|
|
|
padding: 0; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
.union-item { |
|
|
.union-item { |
|
|
@ -472,24 +487,23 @@ const onAfterReadImage = (file) => { |
|
|
transition: all 0.2s; |
|
|
transition: all 0.2s; |
|
|
|
|
|
|
|
|
&:active { |
|
|
&:active { |
|
|
transform: scale(0.98); |
|
|
background: #f5f5f5; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
&.active { |
|
|
.union-item-content { |
|
|
border-color: #1367fe; |
|
|
flex: 1; |
|
|
background: rgba(19, 103, 254, 0.05); |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
.union-item-title { |
|
|
.union-item-title { |
|
|
font-size: 14px; |
|
|
font-size: 14px; |
|
|
color: #333; |
|
|
color: #333; |
|
|
font-weight: 500; |
|
|
font-weight: 500; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
.union-item-desc { |
|
|
.union-item-desc { |
|
|
font-size: 12px; |
|
|
font-size: 12px; |
|
|
color: #999; |
|
|
color: #999; |
|
|
margin-top: 0.08rem; |
|
|
margin-top: 0.08rem; |
|
|
|
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
|