This commit is contained in:
那些花儿
2025-10-19 19:17:30 +08:00
parent 6e5c612600
commit 4269459d70
31 changed files with 1208 additions and 184 deletions
@@ -47,6 +47,48 @@ const PROPOSAL_INFO = {
<!-- </van-cell>-->
</van-cell-group>
<!--并案信息-->
<van-cell-group title="并案信息" v-if="viewData.merges && viewData.merges.length">
<van-cell v-for="(merge, index) in viewData.merges" :key="merge.id"
:title="(index + 1) + '. ' + merge.name"
:label="'提案编号:' + merge.code + ' | 提案人:' + merge.createUserName + ' | 类别:' + merge.typeName + ' | 代表团:' + merge.delegationName"
is-link
@click="openView(merge)">
</van-cell>
</van-cell-group>
<!--委员会成员意见-->
<template v-if="viewData.commissionerOpinions && viewData.commissionerOpinions.length">
<div class="process-title" style="margin-bottom: 0!important;">
委员会成员意见
</div>
<div v-for="(opinion, index) in viewData.commissionerOpinions" :key="index"
style="margin-bottom: 16px;">
<van-cell :title="opinion.commissionerName + '(' + opinion.commissionerLoginName + ')'"
class="direction-column-cell">
</van-cell>
<van-cell title="立案结果">
<div style="display: flex;justify-content: end;">
<dict-tag :options="dict.type.PROPOSAL_CASE_FILING_RESULT"
:value="opinion.caseFilingResult"></dict-tag>
<template v-if="opinion.caseFilingType">
(
<dict-tag :options="dict.type.PROPOSAL_CASE_FILING_TYPE"
:value="opinion.caseFilingType"></dict-tag>
)
</template>
</div>
</van-cell>
<van-cell title="意见" v-if="opinion.opinionText">
<div>{{ opinion.opinionText }}</div>
</van-cell>
<van-cell title="时间" v-if="opinion.opinionTime">
{{ opinion.opinionTime }}
</van-cell>
</div>
</template>
<template v-for="task in doneTasks">
<van-cell-group :title="task.displayName" v-if="task.ext.isFirstTaskNode">
<van-cell title="申请用户">{{ task.ext.initiatorName }}({{task.ext.initiatorAccount}})
@@ -76,28 +118,6 @@ const PROPOSAL_INFO = {
<el-table-column label="代表团" prop="delegationName"
show-overflow-tooltip></el-table-column>
</el-table>
<!-- <table>-->
<!-- <thead>-->
<!-- <tr>-->
<!-- <th>姓名</th>-->
<!-- <th>工号</th>-->
<!-- <th>性别</th>-->
<!-- <th>单位</th>-->
<!-- <th>分工会</th>-->
<!-- <th>代表团</th>-->
<!-- </tr>-->
<!-- </thead>-->
<!-- <tbody>-->
<!-- <tr v-for="item in task?.taskFormData?.seconder">-->
<!-- <td>{{item.userName}}</td>-->
<!-- <td>{{item.loginName}}</td>-->
<!-- <td>{{item.sex}}</td>-->
<!-- <td>{{item.unitName}}</td>-->
<!-- <td>{{item.unionName}}</td>-->
<!-- <td>{{item.delegationName}}</td>-->
<!-- </tr>-->
<!-- </tbody>-->
<!-- </table>-->
</van-cell>
</van-cell-group>
@@ -108,11 +128,20 @@ const PROPOSAL_INFO = {
</van-cell>
<van-cell title="办理时间">{{ task.finishTime }}</van-cell>
<van-cell title="立案结果">
<dict-tag :options="dict.type.PROPOSAL_CASE_FILING_RESULT"
:value="task.ext.caseFilingResult"></dict-tag>
<div style="display: flex;justify-content: center">
<dict-tag :options="dict.type.PROPOSAL_CASE_FILING_RESULT"
:value="task.ext.tf_caseFilingResult"></dict-tag>
<template v-if="task.ext.tf_caseFilingType">
(
<dict-tag :options="dict.type.PROPOSAL_CASE_FILING_TYPE"
:value="task.ext.tf_caseFilingType"></dict-tag>
)
</template>
</div>
</van-cell>
<van-cell title="主办单位">{{ task.ext.tf_hostUnitName }}</van-cell>
<van-cell title="协办单位">{{ task?.ext?.tf_helpUnitNames?.join('、') }}</van-cell>
<van-cell title="主办单位">{{ task.ext.tf_masterUnitName }}</van-cell>
<van-cell title="协办单位">{{ task?.ext?.tf_slaveUnitNameStr }}</van-cell>
</van-cell-group>
<van-cell-group :title="task.displayName" v-else>
@@ -129,8 +158,8 @@ const PROPOSAL_INFO = {
:value="task.ext.tf_feedback"></dict-tag>
</van-cell>
<van-cell title="办理结果" v-else>
<dict-tag :options="dict.type.PROPOSAL_CASE_FILING_RESULT"
:value="task.ext.caseFilingResult"></dict-tag>
<dict-tag :options="dict.type.PROCESS_TASK_SUBMIT_TYPE"
:value="task.ext.submitType"></dict-tag>
</van-cell>
<van-cell title="办理意见" v-if="!task.ext.isFirstTaskNode" class="direction-column-cell">
<div v-html="task.taskFormData.tf_opinion"></div>
@@ -149,6 +178,7 @@ const PROPOSAL_INFO = {
viewData: {},
doneTasks: [],
row: null,
originalRow: null, // 用于保存原始数据,支持返回功能
}
},
methods: {
@@ -175,10 +205,27 @@ const PROPOSAL_INFO = {
},
// 查看提案
openView(id) {
this.$nextTick(() => {
this.$refs.infoDialogRef.onOpen(id)
})
openView(row) {
// 如果传入的是并案对象,则打开新的详情页面
if (row && typeof row === 'object' && row.id) {
// 创建一个新的提案详情组件实例来显示并案详情
this.$nextTick(() => {
// 可以通过事件总线或者其他方式来打开新的详情页面
// 这里暂时使用简单的方式,直接在当前组件中显示
const currentRow = this.row;
this.row = row;
this.getInfo();
// 保存原来的数据,以便返回时恢复
this.originalRow = currentRow;
})
} else {
// 原有的逻辑,通过ID查看
this.$nextTick(() => {
if (this.$refs.infoDialogRef) {
this.$refs.infoDialogRef.onOpen(row)
}
})
}
},
// 获取已办任务审批记录
@@ -82,6 +82,38 @@ layout("/layouts/platform_h5.html"){
maxlength="100"
show-word-limit
></van-field>
<template v-if="['SATISFIED','FAIRLY_SATISFIED'].includes(formData.tf_feedback)">
<van-field
v-model="formData.tf_address"
name="tf_address"
label="通讯地址"
placeholder="请输入通讯地址"
:rules="[{ required: true, message: '请输入通讯地址' }]"
required
show-word-limit
></van-field>
<!--联系电话-->
<van-field
v-model="formData.tf_phone"
name="tf_phone"
label="联系电话"
placeholder="请输入联系电话"
:rules="[{ required: true, message: '请输入联系电话' }]"
required
show-word-limit
></van-field>
<!--邮政编码-->
<van-field
v-model="formData.tf_postcode"
name="tf_postcode"
label="邮政编码"
placeholder="请输入邮政编码"
:rules="[{ required: true, message: '请输入邮政编码' }]"
required
show-word-limit
></van-field>
</template>
</van-form>
<div style="display: flex; justify-content: space-between; column-gap: 10px; padding: 10px">
<van-button type="danger" block @click="$refs.proposalInfoRef.onClose()">取消</van-button>
@@ -25,7 +25,7 @@ layout("/layouts/platform_h5.html"){
<table-column label="提案类别">{{row.typeName}}</table-column>
<table-column label="提案人">{{row.createUserName}}</table-column>
<table-column label="代表团">{{row.delegationName}}</table-column>
<table-column label="当前节点">{{row.curTaskName}}</table-column>
<table-column label="当前节点">{{row.taskName}}</table-column>
</template>
<template #actions="{index,row}">
<div class="action-btn" @click="onView(row)">
@@ -43,7 +43,7 @@ layout("/layouts/platform_h5.html"){
<i class="fa fa-user-plus"></i>
<span>邀请附议人</span>
</div>
<div class="action-btn delete" v-if="row.canRevoke" @click="onRevoke(item)">
<div class="action-btn delete" v-if="row.canRevoke" @click="onRevoke(row)">
<i class="fa fa-undo"></i>
<span>撤回</span>
</div>
@@ -128,8 +128,10 @@ layout("/layouts/platform_h5.html"){
})
.then(() => {
this.$axios.post("/flow/common/revokeTask", {taskId: row.startTaskId}).then((res) => {
this.$toast.success(resp.msg)
this.doSearch()
if(res.code===0){
this.$toast.success(res.msg)
this.doSearch()
}
})
})
},
@@ -65,8 +65,8 @@ layout("/layouts/platform_h5.html"){
></van-field>
</van-form>
<div style="display: flex; justify-content: space-between; column-gap: 10px; padding: 10px">
<van-button type="danger" block @click="handleTaskAction(4)">退回答复</van-button>
<van-button type="primary" block @click="handleTaskAction(1)">同意答复</van-button>
<van-button type="danger" block @click="handleTaskAction('back')">退回答复</van-button>
<van-button type="primary" block @click="handleTaskAction('agree')">同意答复</van-button>
</div>
</div>
</proposal-info>
@@ -129,7 +129,9 @@ layout("/layouts/platform_h5.html"){
this.$refs.proposalInfoRef.onOpen(row)
this.formData = {
processTaskId: row.taskId,
taskName: row.curTaskName
taskKey: row.taskKey,
taskName: row.taskName,
proposalId: row.id
}
},
@@ -140,11 +142,17 @@ layout("/layouts/platform_h5.html"){
title: "提示",
message: "您确定要提交吗?"
}).then(() => {
const formData = {
...this.formData,
tf_approval: val
}
delete formData.taskKey
delete formData.taskName
this.$axios.post("/flow/common/executeTask", {
data: JSON.stringify({
...this.formData,
submitType: val
})
data: JSON.stringify(formData)
}).then((res) => {
if (res.code === 0) {
this.$refs.proposalInfoRef.onClose()
@@ -3,7 +3,75 @@ layout("/layouts/platform_h5.html"){
#-->
<style>
.suggestion-unit-picker {
height: 100%;
display: flex;
flex-direction: column;
}
.picker-toolbar {
display: flex;
align-items: center;
justify-content: space-between;
padding: 16px;
background-color: #f8f8f8;
border-bottom: 1px solid #eee;
}
.picker-cancel, .picker-confirm {
background: none;
border: none;
font-size: 16px;
color: #1989fa;
cursor: pointer;
}
.picker-cancel {
color: #969799;
}
.picker-title {
font-size: 16px;
font-weight: 500;
color: #323233;
}
.search-container {
padding: 12px 16px;
background-color: #fff;
border-bottom: 1px solid #eee;
}
.options-container {
flex: 1;
overflow-y: auto;
background-color: #fff;
}
.option-item {
display: flex;
align-items: center;
width: 100%;
}
.option-text {
margin-left: 12px;
flex: 1;
font-size: 14px;
color: #323233;
}
.van-checkbox {
margin-right: 0;
}
.van-cell {
padding: 12px 16px;
}
.van-cell:active {
background-color: #f2f3f5;
}
</style>
<div id="app" v-cloak>
@@ -113,6 +181,7 @@ layout("/layouts/platform_h5.html"){
placeholder="请选择提案方式"
@click="showSourcePicker = true"
:rules="[{ required: true, message: '请选择提案方式' }]"
required
></van-field>
<van-popup v-model="showSourcePicker" position="bottom">
<van-picker
@@ -132,6 +201,7 @@ layout("/layouts/platform_h5.html"){
placeholder="请选择提案类别"
@click="showTypePicker = true"
:rules="[{ required: true, message: '请选择提案类别' }]"
required
></van-field>
<van-popup v-model="showTypePicker" position="bottom">
<van-picker
@@ -142,6 +212,61 @@ layout("/layouts/platform_h5.html"){
></van-picker>
</van-popup>
<van-field
:value="formData.suggestUnits.length > 0 ? formData.suggestUnits.join(', ') : ''"
is-link
readonly
name="suggestUnits"
label="建议承办单位"
placeholder="请选择建议承办单位"
@click="showSuggestionUnitPicker = true"
:rules="[{ required: true, message: '请选择建议承办单位' }]"
required
></van-field>
<van-popup v-model="showSuggestionUnitPicker" position="bottom" :style="{ height: '70%' }">
<div class="suggestion-unit-picker">
<!-- 头部工具栏 -->
<div class="picker-toolbar">
<button class="picker-cancel" @click="onSuggestionUnitCancel">取消</button>
<div class="picker-title">选择建议承办单位</div>
<button class="picker-confirm" @click="onSuggestionUnitConfirm">确认</button>
</div>
<!-- 搜索框 -->
<div class="search-container">
<van-search
v-model="suggestionUnitSearchText"
placeholder="搜索承办单位"
@input="onSuggestionUnitSearch"
></van-search>
</div>
<!-- 选项列表 -->
<div class="options-container">
<van-checkbox-group v-model="selectedSuggestionUnits">
<van-cell-group>
<van-cell
v-for="item in filteredSuggestionUnits"
:key="item.id"
clickable
@click="toggleSuggestionUnit(item)"
>
<template #title>
<div class="option-item">
<van-checkbox
:name="item.name"
:checked="selectedSuggestionUnits.includes(item.name)"
@click.stop
/>
<span class="option-text">{{ item.name }}</span>
</div>
</template>
</van-cell>
</van-cell-group>
</van-checkbox-group>
</div>
</div>
</van-popup>
</van-cell-group>
<van-cell-group title="提案内容" class="form-group">
@@ -226,7 +351,9 @@ layout("/layouts/platform_h5.html"){
bizId: GetQueryString("bizId"),
taskId: GetQueryString("taskId"),
formData: {},
formData: {
suggestUnits: []
},
sessionOptions: [],
sourceOptions: [],
delegationOptions: [],
@@ -245,7 +372,14 @@ layout("/layouts/platform_h5.html"){
proposalConfig: {},
noticeDialogVisible: false,
isWriteTime: true
isWriteTime: true,
// 建议承办单位
suggestUnitOptions: [],
showSuggestionUnitPicker: false,
selectedSuggestionUnits: [], // 当前选中的承办单位
suggestionUnitSearchText: '', // 搜索文本
filteredSuggestionUnits: [] // 过滤后的承办单位列表
}
},
methods: {
@@ -272,6 +406,46 @@ layout("/layouts/platform_h5.html"){
this.showTypePicker = false;
},
onSuggestionUnitConfirm() {
// 将选中的承办单位保存到表单数据中
this.formData.suggestUnits = [...this.selectedSuggestionUnits];
this.showSuggestionUnitPicker = false;
},
onSuggestionUnitCancel() {
// 取消时恢复到之前的选择状态
this.selectedSuggestionUnits = [...this.formData.suggestUnits];
this.suggestionUnitSearchText = '';
this.showSuggestionUnitPicker = false;
},
// 切换承办单位选择状态
toggleSuggestionUnit(item) {
const index = this.selectedSuggestionUnits.indexOf(item.name);
if (index > -1) {
this.selectedSuggestionUnits.splice(index, 1);
} else {
this.selectedSuggestionUnits.push(item.name);
}
},
// 搜索承办单位
onSuggestionUnitSearch(value) {
this.suggestionUnitSearchText = value;
this.filterSuggestionUnits();
},
// 过滤承办单位列表
filterSuggestionUnits() {
if (!this.suggestionUnitSearchText) {
this.filteredSuggestionUnits = this.suggestUnitOptions;
} else {
this.filteredSuggestionUnits = this.suggestUnitOptions.filter(item =>
item.name.toLowerCase().includes(this.suggestionUnitSearchText.toLowerCase())
);
}
},
onCommitteeConfirm(value) {
this.formData.committeeId = value.value;
this.$set(this.formData, 'committeeName', value.text);
@@ -445,6 +619,15 @@ layout("/layouts/platform_h5.html"){
});
},
// 建议承办单位
listSuggestUnit() {
this.$axios.post("/platform/proposal/common/listUnderTake").then((res) => {
if (res.code === 0) {
this.suggestUnitOptions = res.data
}
})
},
// 查询开启的教代会
listOpenSession(isModify = false) {
this.$axios.post("/platform/proposal/common/listOpenSession").then(async (res) => {
@@ -546,8 +729,27 @@ layout("/layouts/platform_h5.html"){
},
created() {
this.init();
this.listSuggestUnit();
this.listProposalType();
this.getProposalConfig();
},
watch: {
// 监听suggestUnitOptions变化,初始化过滤列表
suggestUnitOptions: {
handler(newVal) {
this.filteredSuggestionUnits = newVal;
},
immediate: true
},
// 监听选择器显示状态,重置搜索和选择状态
showSuggestionUnitPicker(newVal) {
if (newVal) {
// 打开选择器时,初始化选择状态
this.selectedSuggestionUnits = [...this.formData.suggestUnits];
this.suggestionUnitSearchText = '';
this.filterSuggestionUnits();
}
}
}
})
</script>