!7 集成删除相关流程按钮
Merge pull request !7 from new_new_new/feature/0514-adapt
This commit is contained in:
@@ -166,3 +166,7 @@ export const setProcessVariable = (params) => {
|
|||||||
export const updateLaunchType = (params) => {
|
export const updateLaunchType = (params) => {
|
||||||
return defHttp.post({ url: '/bg/xispeak/bgXiSpeak/edit', params }, { isTransformResponse: false });
|
return defHttp.post({ url: '/bg/xispeak/bgXiSpeak/edit', params }, { isTransformResponse: false });
|
||||||
};
|
};
|
||||||
|
|
||||||
|
export const withDrawXiSpeak = (params) => {
|
||||||
|
return defHttp.post({ url: '/bg/xispeak/bgXiSpeak/withDrawXiSpeak', params }, { joinParamsToUrl: true, isTransformResponse: false });
|
||||||
|
};
|
||||||
|
|||||||
@@ -85,30 +85,30 @@ export const columns: BasicColumn[] = [
|
|||||||
dataIndex: 'delayRiskMitigation',
|
dataIndex: 'delayRiskMitigation',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '完成状态(0推进中,1已完成)',
|
title: '完成状态',
|
||||||
align: 'center',
|
align: 'center',
|
||||||
dataIndex: 'completionStatus',
|
dataIndex: 'completionStatus_dictText',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '落实部门id',
|
title: '落实部门',
|
||||||
align: 'center',
|
align: 'center',
|
||||||
dataIndex: 'implDept_dictText',
|
dataIndex: 'implDept_dictText',
|
||||||
},
|
},
|
||||||
{
|
// {
|
||||||
title: '层深(最顶层节点层深为0)',
|
// title: '层深(最顶层节点层深为0)',
|
||||||
align: 'center',
|
// align: 'center',
|
||||||
dataIndex: 'treeDepth',
|
// dataIndex: 'treeDepth',
|
||||||
},
|
// },
|
||||||
{
|
// {
|
||||||
title: '同级数据排序号',
|
// title: '同级数据排序号',
|
||||||
align: 'center',
|
// align: 'center',
|
||||||
dataIndex: 'sortOrder',
|
// dataIndex: 'sortOrder',
|
||||||
},
|
// // },
|
||||||
{
|
// {
|
||||||
title: '流程引擎状态字段',
|
// title: '流程引擎状态字段',
|
||||||
align: 'center',
|
// align: 'center',
|
||||||
dataIndex: 'bpmStatus',
|
// dataIndex: 'bpmStatus',
|
||||||
},
|
// },
|
||||||
{
|
{
|
||||||
title: '督办次数',
|
title: '督办次数',
|
||||||
align: 'center',
|
align: 'center',
|
||||||
@@ -250,7 +250,7 @@ export const superQuerySchema = {
|
|||||||
reportFeedbackStatus: { title: '报告反馈情况', order: 13, view: 'text', type: 'string' },
|
reportFeedbackStatus: { title: '报告反馈情况', order: 13, view: 'text', type: 'string' },
|
||||||
isCompletionRisk: { title: '是否存在完成风险(0不存在,1存在)', order: 14, view: 'number', type: 'number' },
|
isCompletionRisk: { title: '是否存在完成风险(0不存在,1存在)', order: 14, view: 'number', type: 'number' },
|
||||||
delayRiskMitigation: { title: '拖期风险应对措施', order: 15, view: 'text', type: 'string' },
|
delayRiskMitigation: { title: '拖期风险应对措施', order: 15, view: 'text', type: 'string' },
|
||||||
completionStatus: { title: '完成状态(0推进中,1已完成)', order: 16, view: 'number', type: 'number' },
|
completionStatus: { title: '完成状态(督办中,1已完成)', order: 16, view: 'number', type: 'number' },
|
||||||
implDept: { title: '落实部门id', order: 17, view: 'sel_depart', type: 'string' },
|
implDept: { title: '落实部门id', order: 17, view: 'sel_depart', type: 'string' },
|
||||||
treeDepth: { title: '层深(最顶层节点层深为0)', order: 18, view: 'number', type: 'number' },
|
treeDepth: { title: '层深(最顶层节点层深为0)', order: 18, view: 'number', type: 'number' },
|
||||||
sortOrder: { title: '同级数据排序号', order: 19, view: 'number', type: 'number' },
|
sortOrder: { title: '同级数据排序号', order: 19, view: 'number', type: 'number' },
|
||||||
|
|||||||
@@ -1,7 +1,5 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="erpNativeList">
|
<div>
|
||||||
<div class="content">
|
|
||||||
<!--引用表格-->
|
|
||||||
<BasicTable @register="registerTable" :expandedRowKeys="expandedRowKeys" @expand="handleExpand" @fetch-success="onFetchSuccess">
|
<BasicTable @register="registerTable" :expandedRowKeys="expandedRowKeys" @expand="handleExpand" @fetch-success="onFetchSuccess">
|
||||||
<!--插槽:table标题-->
|
<!--插槽:table标题-->
|
||||||
<template #tableTitle>
|
<template #tableTitle>
|
||||||
@@ -30,15 +28,6 @@
|
|||||||
<super-query :config="superQueryConfig" @search="handleSuperQuery" />
|
<super-query :config="superQueryConfig" @search="handleSuperQuery" />
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<!-- 自定义展开图标,完全复刻 Jeecg 原生树形效果 -->
|
|
||||||
<template #expandIcon="{ expanded, onExpand, record }">
|
|
||||||
<span v-if="record.hasChild === '1'" class="jeecg-tree-expand-icon" @click="(e) => onExpand(record, e)">
|
|
||||||
<!-- 用方块样式的加减号,和 Jeecg 原生一致 -->
|
|
||||||
<Icon :icon="expanded ? 'ant-design:minus-square-outlined' : 'ant-design:plus-square-outlined'" />
|
|
||||||
</span>
|
|
||||||
<span v-else class="jeecg-tree-expand-placeholder"></span>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<!--操作栏-->
|
<!--操作栏-->
|
||||||
<template #action="{ record }">
|
<template #action="{ record }">
|
||||||
<TableAction :actions="getTableAction(record)" :dropDownActions="getDropDownAction(record)" />
|
<TableAction :actions="getTableAction(record)" :dropDownActions="getDropDownAction(record)" />
|
||||||
@@ -92,12 +81,12 @@
|
|||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
</BasicTable>
|
</BasicTable>
|
||||||
</div>
|
|
||||||
<!-- 表单区域 -->
|
<!-- 表单区域 -->
|
||||||
<BgXiSpeakModal ref="registerModal" @success="handleSuccess"></BgXiSpeakModal>
|
<BgXiSpeakModal ref="registerModal" @success="handleSuccess"></BgXiSpeakModal>
|
||||||
<!-- 审批记录 -->
|
<!-- 审批记录 -->
|
||||||
<BpmPictureModal @register="registerBpmModal" />
|
<BpmPictureModal @register="registerBpmModal" />
|
||||||
<FlowScheduleStartModal ref="flowScheduleModalRef" @confirm="handleFlowScheduleConfirm" />
|
<FlowScheduleStartModal ref="flowScheduleModalRef" @confirm="handleFlowScheduleConfirm" />
|
||||||
|
<FeedbackRightNowModal ref="feedbackRightNowModalRef" @confirm="handleFeedbackRightNowConfirm" />
|
||||||
<BusinessProcessListModal ref="businessProcessListModalRef" />
|
<BusinessProcessListModal ref="businessProcessListModalRef" />
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
@@ -116,6 +105,7 @@
|
|||||||
import SUploadFile from '/@/components/semri/fileComponent/SUploadFile.vue';
|
import SUploadFile from '/@/components/semri/fileComponent/SUploadFile.vue';
|
||||||
import BusinessProcessListModal from '/src/components/semri/process/BusinessProcessListModal.vue';
|
import BusinessProcessListModal from '/src/components/semri/process/BusinessProcessListModal.vue';
|
||||||
import FlowScheduleStartModal from '/src/components/semri/process/FlowScheduleStartModal.vue';
|
import FlowScheduleStartModal from '/src/components/semri/process/FlowScheduleStartModal.vue';
|
||||||
|
import FeedbackRightNowModal from './components/FeedbackRightNowModal.vue';
|
||||||
import { columns as taskTaskColumns } from '/@/views/taskProcess/TaskTask.data';
|
import { columns as taskTaskColumns } from '/@/views/taskProcess/TaskTask.data';
|
||||||
import { columns, superQuerySchema, bgXiSpeakFeedbackColumns } from './BgXiSpeak.data';
|
import { columns, superQuerySchema, bgXiSpeakFeedbackColumns } from './BgXiSpeak.data';
|
||||||
import {
|
import {
|
||||||
@@ -127,7 +117,9 @@
|
|||||||
getChildList,
|
getChildList,
|
||||||
getChildListBatch,
|
getChildListBatch,
|
||||||
updateLaunchType,
|
updateLaunchType,
|
||||||
|
saveOrUpdateDict,
|
||||||
bgXiSpeakFeedbackList,
|
bgXiSpeakFeedbackList,
|
||||||
|
withDrawXiSpeak,
|
||||||
} from './BgXiSpeak.api';
|
} from './BgXiSpeak.api';
|
||||||
|
|
||||||
const FLOW_CODE = 'dev_bg_xi_speak_001';
|
const FLOW_CODE = 'dev_bg_xi_speak_001';
|
||||||
@@ -143,7 +135,9 @@
|
|||||||
const toggleSearchStatus = ref<boolean>(false);
|
const toggleSearchStatus = ref<boolean>(false);
|
||||||
const registerModal = ref();
|
const registerModal = ref();
|
||||||
const flowScheduleModalRef = ref();
|
const flowScheduleModalRef = ref();
|
||||||
|
const feedbackRightNowModalRef = ref();
|
||||||
const businessProcessListModalRef = ref();
|
const businessProcessListModalRef = ref();
|
||||||
|
const pendingFeedbackRightNow = ref(0);
|
||||||
const processColumns = taskTaskColumns;
|
const processColumns = taskTaskColumns;
|
||||||
const selectedFeedbackId = ref<string | number | null>(null);
|
const selectedFeedbackId = ref<string | number | null>(null);
|
||||||
const feedbackTableData = reactive<Record<string, Recordable[]>>({});
|
const feedbackTableData = reactive<Record<string, Recordable[]>>({});
|
||||||
@@ -166,6 +160,7 @@
|
|||||||
const showSdwLeaderSelect = computed(() => queryParam.value.needSdwApproval === '1');
|
const showSdwLeaderSelect = computed(() => queryParam.value.needSdwApproval === '1');
|
||||||
|
|
||||||
const { prefixCls, tableContext, onExportXls, onImportXls } = useListPage({
|
const { prefixCls, tableContext, onExportXls, onImportXls } = useListPage({
|
||||||
|
designScope: 'bg-xispeak-template',
|
||||||
tableProps: {
|
tableProps: {
|
||||||
title: '习总书记重要讲话指示批示情况',
|
title: '习总书记重要讲话指示批示情况',
|
||||||
api: list,
|
api: list,
|
||||||
@@ -173,13 +168,7 @@
|
|||||||
canResize: false,
|
canResize: false,
|
||||||
useSearchForm: false,
|
useSearchForm: false,
|
||||||
isTreeTable: true,
|
isTreeTable: true,
|
||||||
indentSize: 24, // 和 Jeecg 原生树形缩进保持一致
|
|
||||||
expandIconColumnIndex: 0,
|
|
||||||
clickToRowSelect: true,
|
clickToRowSelect: true,
|
||||||
treeProps: {
|
|
||||||
children: 'children',
|
|
||||||
indent: 24, // 和 indentSize 保持一致,保证缩进对齐
|
|
||||||
},
|
|
||||||
actionColumn: {
|
actionColumn: {
|
||||||
width: 120,
|
width: 120,
|
||||||
fixed: 'right',
|
fixed: 'right',
|
||||||
@@ -190,7 +179,6 @@
|
|||||||
},
|
},
|
||||||
afterFetch: (result) => {
|
afterFetch: (result) => {
|
||||||
if (result && result.length > 0) {
|
if (result && result.length > 0) {
|
||||||
// 为有子节点的记录设置 children(用于显示展开图标)
|
|
||||||
result.forEach((item) => {
|
result.forEach((item) => {
|
||||||
if (item.hasChild == '1' && (!item.children || item.children.length === 0)) {
|
if (item.hasChild == '1' && (!item.children || item.children.length === 0)) {
|
||||||
item.children = [{ id: item.id + '_loadChild', name: 'loading...', isLoading: true }];
|
item.children = [{ id: item.id + '_loadChild', name: 'loading...', isLoading: true }];
|
||||||
@@ -274,6 +262,16 @@
|
|||||||
await deleteBgXiSpeak({ id: record.id }, success);
|
await deleteBgXiSpeak({ id: record.id }, success);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
async function handleWithDraw(record) {
|
||||||
|
const res = await withDrawXiSpeak({ id: record.id });
|
||||||
|
if (res.success) {
|
||||||
|
createMessage.success(res.message || '删除流程成功');
|
||||||
|
reload();
|
||||||
|
} else {
|
||||||
|
createMessage.error(res.message || '删除流程失败');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 批量删除事件
|
* 批量删除事件
|
||||||
*/
|
*/
|
||||||
@@ -471,6 +469,15 @@
|
|||||||
label: '查询督办流程',
|
label: '查询督办流程',
|
||||||
onClick: handleQueryProcess.bind(null, record),
|
onClick: handleQueryProcess.bind(null, record),
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
label: '删除关联流程',
|
||||||
|
popConfirm: {
|
||||||
|
title: '确定删除该记录关联的所有运行中流程吗?',
|
||||||
|
confirm: handleWithDraw.bind(null, record),
|
||||||
|
placement: 'topLeft',
|
||||||
|
},
|
||||||
|
ifShow: !!record.bpmStatus && record.bpmStatus !== '1',
|
||||||
|
},
|
||||||
{
|
{
|
||||||
label: selectedFeedbackId.value === record.id ? '收起反馈信息' : '查看反馈',
|
label: selectedFeedbackId.value === record.id ? '收起反馈信息' : '查看反馈',
|
||||||
onClick: handleViewFeedback.bind(null, record),
|
onClick: handleViewFeedback.bind(null, record),
|
||||||
@@ -487,14 +494,62 @@
|
|||||||
onClick: handleProcessJbr.bind(null, record),
|
onClick: handleProcessJbr.bind(null, record),
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
if (record.bpmStatus == '2') {
|
||||||
|
dropDownAction.push({
|
||||||
|
label: '再次发起经办人执行反馈流程',
|
||||||
|
onClick: handleProcessJbr.bind(null, record),
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
return dropDownAction;
|
return dropDownAction;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function splitDeptValue(value) {
|
||||||
|
if (Array.isArray(value)) {
|
||||||
|
return value.map((item) => String(item || '').trim()).filter(Boolean);
|
||||||
|
}
|
||||||
|
return String(value || '')
|
||||||
|
.split(/[,\uFF0C]/)
|
||||||
|
.map((item) => item.trim())
|
||||||
|
.filter(Boolean);
|
||||||
|
}
|
||||||
|
|
||||||
|
function getImplDeptOptions(record) {
|
||||||
|
const deptIds = splitDeptValue(record?.implDept);
|
||||||
|
const deptNames = splitDeptValue(record?.implDept_dictText);
|
||||||
|
return deptIds.map((deptId, index) => ({
|
||||||
|
value: deptId,
|
||||||
|
label: deptNames[index] || deptId,
|
||||||
|
}));
|
||||||
|
}
|
||||||
|
|
||||||
|
function getLeadDeptOptions(record) {
|
||||||
|
const deptIds = splitDeptValue(record?.leadDepartment);
|
||||||
|
const deptNames = splitDeptValue(record?.leadDepartment_dictText);
|
||||||
|
return deptIds.map((deptId, index) => ({
|
||||||
|
value: deptId,
|
||||||
|
label: deptNames[index] || deptId,
|
||||||
|
}));
|
||||||
|
}
|
||||||
|
|
||||||
|
function getNextSuperviseCount(value) {
|
||||||
|
const count = Number(value || 0);
|
||||||
|
return Number.isFinite(count) ? count + 1 : 1;
|
||||||
|
}
|
||||||
|
|
||||||
function handleProcess(record) {
|
function handleProcess(record) {
|
||||||
|
feedbackRightNowModalRef.value?.open(record);
|
||||||
|
}
|
||||||
|
|
||||||
|
function handleFeedbackRightNowConfirm({ record, feedbackRightNow }) {
|
||||||
|
pendingFeedbackRightNow.value = feedbackRightNow;
|
||||||
flowScheduleModalRef.value?.open({
|
flowScheduleModalRef.value?.open({
|
||||||
title: '发起督办计划收集流程',
|
title: '发起督办计划收集流程',
|
||||||
payload: { record },
|
payload: { record },
|
||||||
|
deptOptions: getLeadDeptOptions(record),
|
||||||
|
showSuoleaderFields: true,
|
||||||
|
isNeedAppro: record?.needSdwApproval,
|
||||||
|
supDeptleaderid: record?.sdwLeaderList,
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -502,6 +557,10 @@
|
|||||||
flowScheduleModalRef.value?.open({
|
flowScheduleModalRef.value?.open({
|
||||||
title: '发起落实部门经办人执行反馈流程',
|
title: '发起落实部门经办人执行反馈流程',
|
||||||
payload: { record, flowCode: FLOW_CODE_JBR },
|
payload: { record, flowCode: FLOW_CODE_JBR },
|
||||||
|
deptOptions: getImplDeptOptions(record),
|
||||||
|
showSuoleaderFields: true,
|
||||||
|
isNeedAppro: record?.needSdwApproval,
|
||||||
|
supDeptleaderid: record?.sdwLeaderList,
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -520,46 +579,33 @@
|
|||||||
return value ? dateUtil(value).format(format) : undefined;
|
return value ? dateUtil(value).format(format) : undefined;
|
||||||
};
|
};
|
||||||
|
|
||||||
// triggerType: 1=立即发起, 2=重复发起; launchType: 0=收集后直接发起, 1=收集后周期性发起
|
|
||||||
const launchType = options.triggerType === 2 ? 1 : 0;
|
const launchType = options.triggerType === 2 ? 1 : 0;
|
||||||
|
|
||||||
// 先保存 launchType 到主表
|
|
||||||
if (flowCode === FLOW_CODE) {
|
if (flowCode === FLOW_CODE) {
|
||||||
await updateLaunchType({ id: record.id, launchType });
|
await updateLaunchType({ id: record.id, launchType });
|
||||||
}
|
}
|
||||||
|
|
||||||
// 合并选中的DW领导列表到record中
|
const nextSuperviseCount = getNextSuperviseCount(record.supervisionCount);
|
||||||
const recordWithSdwLeader = {
|
|
||||||
|
const flowJsonData = {
|
||||||
...record,
|
...record,
|
||||||
sdwLeaderList: queryParam.value.sdwLeaderList || '',
|
isNeedAppro: options.isNeedAppro ?? record.needSdwApproval ?? '',
|
||||||
needSdwApproval: queryParam.value.needSdwApproval || '',
|
supDeptleaderid: options.supDeptleaderid ?? record.sdwLeaderList ?? '',
|
||||||
|
supervisionCount: nextSuperviseCount,
|
||||||
|
feedback_right_now: flowCode === FLOW_CODE ? pendingFeedbackRightNow.value : undefined,
|
||||||
};
|
};
|
||||||
|
|
||||||
// 如果是经办人执行反馈流程,需要遍历每个部门单独发起
|
|
||||||
if (flowCode === FLOW_CODE_JBR) {
|
if (flowCode === FLOW_CODE_JBR) {
|
||||||
let approveInfo = {};
|
const selectedDeptIds = options.deptIds || [];
|
||||||
if (record.approveInfo) {
|
if (selectedDeptIds.length === 0) {
|
||||||
try {
|
createMessage.warning('请选择落实部门');
|
||||||
approveInfo = typeof record.approveInfo === 'string' ? JSON.parse(record.approveInfo) : record.approveInfo;
|
|
||||||
} catch (e) {
|
|
||||||
createMessage.error('审批信息解析失败');
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
const deptKeys = Object.keys(approveInfo);
|
|
||||||
if (deptKeys.length === 0) {
|
|
||||||
createMessage.warning('没有可用的部门审批信息');
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
let successCount = 0;
|
let successCount = 0;
|
||||||
const total = deptKeys.length;
|
const total = selectedDeptIds.length;
|
||||||
|
|
||||||
for (const deptId of deptKeys) {
|
|
||||||
const deptApproveDetail = approveInfo[deptId];
|
|
||||||
const implUserIdList = deptApproveDetail.implUserIdList || [];
|
|
||||||
const implUserNameList = deptApproveDetail.implUserNameList || [];
|
|
||||||
|
|
||||||
|
for (const deptId of selectedDeptIds) {
|
||||||
const params = {
|
const params = {
|
||||||
intervalType: options.intervalType,
|
intervalType: options.intervalType,
|
||||||
startCount: options.startCount,
|
startCount: options.startCount,
|
||||||
@@ -570,21 +616,16 @@
|
|||||||
formUrl: FORM_URL,
|
formUrl: FORM_URL,
|
||||||
flowName: '落实部门经办人执行反馈流程',
|
flowName: '落实部门经办人执行反馈流程',
|
||||||
jsonData: {
|
jsonData: {
|
||||||
...recordWithSdwLeader,
|
...flowJsonData,
|
||||||
currentDeptId: deptId,
|
currentDeptId: deptId,
|
||||||
currentApproverId: deptApproveDetail.approverId,
|
|
||||||
currentApproverName: deptApproveDetail.approverName,
|
|
||||||
implUserIdList: implUserIdList.join(','),
|
|
||||||
implUserNameList: implUserNameList.join(','),
|
|
||||||
},
|
},
|
||||||
businessTablename: BUSINESS_TABLE_NAME,
|
businessTablename: BUSINESS_TABLE_NAME,
|
||||||
businessId: record.id,
|
businessId: record.id,
|
||||||
deptHandlerName: deptApproveDetail.implUserNameList.join(','),
|
|
||||||
title: record.speakStatus,
|
title: record.speakStatus,
|
||||||
content: record.implStatus,
|
content: record.implStatus,
|
||||||
urgencyLevel: record.completionStatus,
|
urgencyLevel: record.completionStatus,
|
||||||
deptId: deptId,
|
deptId: deptId,
|
||||||
deptLeaderId: deptApproveDetail.approverId,
|
deptLeaderId: deptId,
|
||||||
requireFinishDate: formatDate(record.time, 'YYYY-MM-DD'),
|
requireFinishDate: formatDate(record.time, 'YYYY-MM-DD'),
|
||||||
deadline: formatDate(record.time, 'YYYY-MM-DD HH:mm:ss'),
|
deadline: formatDate(record.time, 'YYYY-MM-DD HH:mm:ss'),
|
||||||
},
|
},
|
||||||
@@ -594,6 +635,7 @@
|
|||||||
await startProcessSchedules(params);
|
await startProcessSchedules(params);
|
||||||
successCount++;
|
successCount++;
|
||||||
if (successCount === total) {
|
if (successCount === total) {
|
||||||
|
await saveOrUpdateDict({ id: record.id, bpmStatus: '2', supervisionCount: nextSuperviseCount, completionStatus: 0 }, true);
|
||||||
createMessage.success(`成功发起 ${total} 个经办人执行反馈流程`);
|
createMessage.success(`成功发起 ${total} 个经办人执行反馈流程`);
|
||||||
reload();
|
reload();
|
||||||
}
|
}
|
||||||
@@ -604,7 +646,6 @@
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
// 原有的督办计划收集流程逻辑
|
|
||||||
const params = {
|
const params = {
|
||||||
intervalType: options.intervalType,
|
intervalType: options.intervalType,
|
||||||
startCount: options.startCount,
|
startCount: options.startCount,
|
||||||
@@ -614,13 +655,13 @@
|
|||||||
flowCode: flowCode,
|
flowCode: flowCode,
|
||||||
formUrl: FORM_URL,
|
formUrl: FORM_URL,
|
||||||
flowName: FLOW_NAME,
|
flowName: FLOW_NAME,
|
||||||
jsonData: recordWithSdwLeader,
|
jsonData: flowJsonData,
|
||||||
businessTablename: BUSINESS_TABLE_NAME,
|
businessTablename: BUSINESS_TABLE_NAME,
|
||||||
businessId: record.id,
|
businessId: record.id,
|
||||||
title: record.speakStatus,
|
title: record.speakStatus,
|
||||||
content: record.implStatus,
|
content: record.implStatus,
|
||||||
urgencyLevel: record.completionStatus,
|
urgencyLevel: record.completionStatus,
|
||||||
deptId: record.leadDepartment,
|
deptId: options.deptId || record.leadDepartment,
|
||||||
deptLeaderId: record.responsiblePerson,
|
deptLeaderId: record.responsiblePerson,
|
||||||
requireFinishDate: formatDate(record.time, 'YYYY-MM-DD'),
|
requireFinishDate: formatDate(record.time, 'YYYY-MM-DD'),
|
||||||
deadline: formatDate(record.time, 'YYYY-MM-DD HH:mm:ss'),
|
deadline: formatDate(record.time, 'YYYY-MM-DD HH:mm:ss'),
|
||||||
@@ -628,6 +669,7 @@
|
|||||||
};
|
};
|
||||||
|
|
||||||
await startProcessSchedules(params);
|
await startProcessSchedules(params);
|
||||||
|
await saveOrUpdateDict({ id: record.id, bpmStatus: '2', supervisionCount: nextSuperviseCount, completionStatus: 0 }, true);
|
||||||
createMessage.success('发起成功');
|
createMessage.success('发起成功');
|
||||||
reload();
|
reload();
|
||||||
}
|
}
|
||||||
@@ -715,199 +757,6 @@
|
|||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style lang="less" scoped>
|
<style lang="less" scoped>
|
||||||
.erpNativeList {
|
|
||||||
height: 100%;
|
|
||||||
padding: 16px;
|
|
||||||
background: #f5f7fa;
|
|
||||||
|
|
||||||
// 查询区域卡片
|
|
||||||
.search-card {
|
|
||||||
background: #fff;
|
|
||||||
border-radius: 8px;
|
|
||||||
padding: 20px 24px;
|
|
||||||
margin-bottom: 16px;
|
|
||||||
box-shadow: 0 2px 12px rgba(0, 0, 0, 0.04);
|
|
||||||
transition: box-shadow 0.3s ease;
|
|
||||||
|
|
||||||
&:hover {
|
|
||||||
box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
|
|
||||||
}
|
|
||||||
|
|
||||||
:deep(.ant-form-item) {
|
|
||||||
margin-bottom: 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
:deep(.ant-select),
|
|
||||||
:deep(.ant-picker) {
|
|
||||||
border-radius: 6px;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// 内容区域
|
|
||||||
.content {
|
|
||||||
background: #fff;
|
|
||||||
border-radius: 8px;
|
|
||||||
padding: 0;
|
|
||||||
box-shadow: 0 2px 12px rgba(0, 0, 0, 0.04);
|
|
||||||
overflow: hidden;
|
|
||||||
}
|
|
||||||
|
|
||||||
// 表格标题区域
|
|
||||||
:deep(.ant-table-title) {
|
|
||||||
padding: 16px 20px !important;
|
|
||||||
border-bottom: 1px solid #f0f0f0;
|
|
||||||
background: #fafafa;
|
|
||||||
|
|
||||||
.ant-btn {
|
|
||||||
height: 32px;
|
|
||||||
padding: 0 16px;
|
|
||||||
border-radius: 6px;
|
|
||||||
font-size: 13px;
|
|
||||||
margin-right: 8px;
|
|
||||||
border: none;
|
|
||||||
transition: all 0.2s ease;
|
|
||||||
|
|
||||||
&:hover {
|
|
||||||
transform: translateY(-1px);
|
|
||||||
box-shadow: 0 4px 12px rgba(24, 144, 255, 0.3);
|
|
||||||
}
|
|
||||||
|
|
||||||
&:active {
|
|
||||||
transform: translateY(0);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.ant-btn-primary {
|
|
||||||
background: linear-gradient(135deg, #1890ff 0%, #096dd9 100%);
|
|
||||||
|
|
||||||
&:hover {
|
|
||||||
background: linear-gradient(135deg, #40a9ff 0%, #1890ff 100%);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// 表格样式优化
|
|
||||||
:deep(.ant-table-thead > tr > th) {
|
|
||||||
background: #fafafa;
|
|
||||||
font-weight: 600;
|
|
||||||
color: #333;
|
|
||||||
border-bottom: 1px solid #f0f0f0;
|
|
||||||
padding: 12px 16px;
|
|
||||||
}
|
|
||||||
|
|
||||||
:deep(.ant-table-tbody > tr > td) {
|
|
||||||
padding: 14px 16px;
|
|
||||||
border-bottom: 1px solid #f5f5f5;
|
|
||||||
transition: background 0.2s ease;
|
|
||||||
}
|
|
||||||
|
|
||||||
// 树形表格缩进样式,和 Jeecg 原生对齐
|
|
||||||
:deep(.ant-table-row) {
|
|
||||||
.ant-table-row-indent {
|
|
||||||
display: inline-block;
|
|
||||||
width: 24px; // 和 indentSize 保持一致
|
|
||||||
height: 1px;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
:deep(.ant-table-tbody > tr:hover > td) {
|
|
||||||
background: #f5f7fa;
|
|
||||||
}
|
|
||||||
|
|
||||||
// Jeecg 原生风格的树形展开图标
|
|
||||||
:deep(.jeecg-tree-expand-icon) {
|
|
||||||
display: inline-flex;
|
|
||||||
align-items: center;
|
|
||||||
justify-content: center;
|
|
||||||
width: 20px;
|
|
||||||
height: 20px;
|
|
||||||
margin-right: 6px;
|
|
||||||
cursor: pointer;
|
|
||||||
border-radius: 2px;
|
|
||||||
transition: all 0.2s;
|
|
||||||
|
|
||||||
&:hover {
|
|
||||||
background-color: #f0f0f0;
|
|
||||||
}
|
|
||||||
|
|
||||||
.anticon {
|
|
||||||
font-size: 14px;
|
|
||||||
color: #666;
|
|
||||||
transition: color 0.2s;
|
|
||||||
}
|
|
||||||
|
|
||||||
&:hover .anticon {
|
|
||||||
color: #1890ff;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
:deep(.jeecg-tree-expand-placeholder) {
|
|
||||||
display: inline-block;
|
|
||||||
width: 20px;
|
|
||||||
height: 20px;
|
|
||||||
margin-right: 6px;
|
|
||||||
}
|
|
||||||
|
|
||||||
// 操作按钮样式
|
|
||||||
:deep(.ant-btn-link) {
|
|
||||||
padding: 4px 8px;
|
|
||||||
height: auto;
|
|
||||||
border-radius: 4px;
|
|
||||||
|
|
||||||
&:hover {
|
|
||||||
background: rgba(24, 144, 255, 0.1);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// 标签页样式
|
|
||||||
:deep(.ant-tabs) {
|
|
||||||
margin: 16px;
|
|
||||||
|
|
||||||
.ant-tabs-nav {
|
|
||||||
margin-bottom: 12px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.ant-tabs-tab {
|
|
||||||
padding: 8px 0;
|
|
||||||
font-size: 14px;
|
|
||||||
|
|
||||||
&:hover {
|
|
||||||
color: #1890ff;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.ant-tabs-tab-active .ant-tabs-tab-btn {
|
|
||||||
color: #1890ff;
|
|
||||||
font-weight: 500;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// 下拉菜单样式
|
|
||||||
:deep(.ant-dropdown-menu-item) {
|
|
||||||
border-radius: 4px;
|
|
||||||
margin: 2px 4px;
|
|
||||||
|
|
||||||
&:hover {
|
|
||||||
background: #e6f7ff;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// 分页样式
|
|
||||||
:deep(.ant-pagination) {
|
|
||||||
padding: 16px 20px;
|
|
||||||
margin: 0 !important;
|
|
||||||
border-top: 1px solid #f0f0f0;
|
|
||||||
background: #fafafa;
|
|
||||||
}
|
|
||||||
|
|
||||||
// 搜索和重置按钮
|
|
||||||
:deep(.ant-form-item-with-search) {
|
|
||||||
display: flex;
|
|
||||||
justify-content: flex-end;
|
|
||||||
gap: 8px;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.feedback-expand-table {
|
.feedback-expand-table {
|
||||||
margin: 4px 10px 12px 42px;
|
margin: 4px 10px 12px 42px;
|
||||||
padding: 12px 14px 14px;
|
padding: 12px 14px 14px;
|
||||||
@@ -915,7 +764,6 @@
|
|||||||
border: 1px solid #d6e8ff;
|
border: 1px solid #d6e8ff;
|
||||||
border-left: 4px solid #1677ff;
|
border-left: 4px solid #1677ff;
|
||||||
border-radius: 6px;
|
border-radius: 6px;
|
||||||
box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.72);
|
|
||||||
|
|
||||||
.feedback-expand-header {
|
.feedback-expand-header {
|
||||||
display: flex;
|
display: flex;
|
||||||
@@ -951,13 +799,6 @@
|
|||||||
margin-left: 10px;
|
margin-left: 10px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.feedback-expand-desc {
|
|
||||||
color: #64748b;
|
|
||||||
font-size: 13px;
|
|
||||||
line-height: 22px;
|
|
||||||
white-space: nowrap;
|
|
||||||
}
|
|
||||||
|
|
||||||
.feedback-expand-actions {
|
.feedback-expand-actions {
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
@@ -1009,15 +850,4 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// 响应式适配
|
|
||||||
@media (max-width: 768px) {
|
|
||||||
.erpNativeList {
|
|
||||||
padding: 12px;
|
|
||||||
|
|
||||||
.search-card {
|
|
||||||
padding: 16px;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
</style>
|
</style>
|
||||||
|
|||||||
@@ -0,0 +1,305 @@
|
|||||||
|
<template>
|
||||||
|
<JModal
|
||||||
|
title="新增反馈"
|
||||||
|
:width="820"
|
||||||
|
:visible="visible"
|
||||||
|
:confirmLoading="saving"
|
||||||
|
okText="保存"
|
||||||
|
cancelText="取消"
|
||||||
|
@ok="handleOk"
|
||||||
|
@cancel="handleCancel"
|
||||||
|
>
|
||||||
|
<a-form
|
||||||
|
ref="formRef"
|
||||||
|
class="bpm-feedback-modal-form"
|
||||||
|
:model="formData"
|
||||||
|
:rules="formRules"
|
||||||
|
:labelCol="labelCol"
|
||||||
|
:wrapperCol="wrapperCol"
|
||||||
|
>
|
||||||
|
<a-row :gutter="16">
|
||||||
|
<a-col :span="12">
|
||||||
|
<a-form-item label="反馈部门" name="responDeptid">
|
||||||
|
<j-select-dept v-model:value="formData.responDeptid" :multiple="true" checkStrictly allow-clear @change="handleDeptChange" />
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
<a-col :span="12">
|
||||||
|
<a-form-item label="反馈人" name="responPersonid">
|
||||||
|
<j-select-user v-model:value="formData.responPersonid" allow-clear @change="handleUserChange" />
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
<a-col :span="12">
|
||||||
|
<a-form-item label="序号" name="num">
|
||||||
|
<a-input-number v-model:value="formData.num" style="width: 100%" allow-clear />
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
<a-col :span="12">
|
||||||
|
<a-form-item label="完成期限" name="deadline">
|
||||||
|
<a-date-picker v-model:value="formData.deadline" value-format="YYYY-MM-DD HH:mm:ss" style="width: 100%" allow-clear />
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
<a-col :span="24">
|
||||||
|
<a-form-item label="措施内容" name="method" :labelCol="wideLabelCol" :wrapperCol="wideWrapperCol">
|
||||||
|
<a-textarea v-model:value="formData.method" :rows="3" allow-clear />
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
<a-col :span="12">
|
||||||
|
<a-form-item label="成果形式" name="outcomeForm">
|
||||||
|
<a-input v-model:value="formData.outcomeForm" allow-clear />
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
<a-col :span="12">
|
||||||
|
<a-form-item label="完成状态" name="completionStatus">
|
||||||
|
<a-input v-model:value="formData.completionStatus" allow-clear />
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
<a-col :span="24">
|
||||||
|
<a-form-item label="进展情况" name="progress" :labelCol="wideLabelCol" :wrapperCol="wideWrapperCol">
|
||||||
|
<a-textarea v-model:value="formData.progress" :rows="3" allow-clear />
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
<a-col :span="24">
|
||||||
|
<a-form-item label="落实情况" name="implStatus" :labelCol="wideLabelCol" :wrapperCol="wideWrapperCol">
|
||||||
|
<a-textarea v-model:value="formData.implStatus" :rows="3" allow-clear />
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
<a-col :span="24">
|
||||||
|
<a-form-item label="落实计划" name="completionPlan" :labelCol="wideLabelCol" :wrapperCol="wideWrapperCol">
|
||||||
|
<a-textarea v-model:value="formData.completionPlan" :rows="3" allow-clear />
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
<a-col :span="12">
|
||||||
|
<a-form-item label="总措施号" name="sumMethodNum">
|
||||||
|
<a-input v-model:value="formData.sumMethodNum" allow-clear />
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
<a-col :span="12">
|
||||||
|
<a-form-item label="检查情况" name="checkStatus">
|
||||||
|
<a-input v-model:value="formData.checkStatus" allow-clear />
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
<a-col :span="24">
|
||||||
|
<a-form-item label="监督意见" name="inspectionAdvice" :labelCol="wideLabelCol" :wrapperCol="wideWrapperCol">
|
||||||
|
<a-textarea v-model:value="formData.inspectionAdvice" :rows="3" allow-clear />
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
<a-col :span="12">
|
||||||
|
<a-form-item label="措施数量" name="measureNum">
|
||||||
|
<a-input-number v-model:value="formData.measureNum" style="width: 100%" allow-clear />
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
<a-col :span="12">
|
||||||
|
<a-form-item label="发起类型" name="launchType">
|
||||||
|
<a-select v-model:value="formData.launchType" placeholder="请选择发起类型" allow-clear>
|
||||||
|
<a-select-option :value="0">立即发起</a-select-option>
|
||||||
|
<a-select-option :value="1">周期发起</a-select-option>
|
||||||
|
</a-select>
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
<a-col :span="12">
|
||||||
|
<a-form-item label="周期类型" name="intervalType">
|
||||||
|
<a-select v-model:value="formData.intervalType" placeholder="请选择周期类型" allow-clear>
|
||||||
|
<a-select-option :value="1">日</a-select-option>
|
||||||
|
<a-select-option :value="2">周</a-select-option>
|
||||||
|
<a-select-option :value="3">两周</a-select-option>
|
||||||
|
<a-select-option :value="4">月</a-select-option>
|
||||||
|
<a-select-option :value="5">季</a-select-option>
|
||||||
|
</a-select>
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
<a-col :span="12">
|
||||||
|
<a-form-item label="周期任务数量" name="startCount">
|
||||||
|
<a-input-number v-model:value="formData.startCount" style="width: 100%" allow-clear />
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
<a-col :span="12">
|
||||||
|
<a-form-item label="周期开始时间" name="startTime">
|
||||||
|
<a-date-picker v-model:value="formData.startTime" showTime value-format="YYYY-MM-DD HH:mm:ss" style="width: 100%" placeholder="请选择周期开始时间" allow-clear />
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
<a-col :span="24">
|
||||||
|
<a-form-item label="附件" :labelCol="wideLabelCol" :wrapperCol="wideWrapperCol">
|
||||||
|
<SUploadFile
|
||||||
|
:key="uploadKey"
|
||||||
|
ref="uploadFileRef"
|
||||||
|
:bussiness-id="formData.id"
|
||||||
|
:bussiness-secret-level="uploadSecretLevel"
|
||||||
|
:multiple="true"
|
||||||
|
/>
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
</a-row>
|
||||||
|
</a-form>
|
||||||
|
</JModal>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script lang="ts" setup>
|
||||||
|
import { nextTick, reactive, ref } from 'vue';
|
||||||
|
import { useMessage } from '/@/hooks/web/useMessage';
|
||||||
|
import JModal from '/@/components/Modal/src/JModal/JModal.vue';
|
||||||
|
import { bgXiSpeakFeedbackSaveOrUpdate } from '../BgXiSpeak.api';
|
||||||
|
import { useUserStore } from '/@/store/modules/user';
|
||||||
|
import { buildUUID } from '/@/utils/uuid';
|
||||||
|
import SUploadFile from '/@/components/semri/fileComponent/SUploadFile.vue';
|
||||||
|
import JSelectDept from '/@/components/Form/src/jeecg/components/JSelectDept.vue';
|
||||||
|
import JSelectUser from '/@/components/Form/src/jeecg/components/JSelectUser.vue';
|
||||||
|
|
||||||
|
const emit = defineEmits(['success']);
|
||||||
|
const { createMessage } = useMessage();
|
||||||
|
const userStore = useUserStore();
|
||||||
|
|
||||||
|
const visible = ref(false);
|
||||||
|
const saving = ref(false);
|
||||||
|
const formRef = ref();
|
||||||
|
const uploadFileRef = ref<InstanceType<typeof SUploadFile> | null>(null);
|
||||||
|
const uploadSecretLevel = ref(1);
|
||||||
|
const uploadKey = ref(0);
|
||||||
|
const labelCol = { xs: { span: 24 }, sm: { span: 7 } };
|
||||||
|
const wrapperCol = { xs: { span: 24 }, sm: { span: 17 } };
|
||||||
|
const wideLabelCol = { xs: { span: 24 }, sm: { span: 3 } };
|
||||||
|
const wideWrapperCol = { xs: { span: 24 }, sm: { span: 21 } };
|
||||||
|
|
||||||
|
const formData = reactive<Record<string, any>>({
|
||||||
|
id: '',
|
||||||
|
responDeptid: '',
|
||||||
|
responDeptname: '',
|
||||||
|
responPersonid: '',
|
||||||
|
responPersonname: '',
|
||||||
|
implStatus: '',
|
||||||
|
completionStatus: '',
|
||||||
|
completionPlan: '',
|
||||||
|
mainId: '',
|
||||||
|
bpmProcessId: '',
|
||||||
|
num: undefined,
|
||||||
|
method: '',
|
||||||
|
deadline: '',
|
||||||
|
outcomeForm: '',
|
||||||
|
progress: '',
|
||||||
|
sumMethodNum: '',
|
||||||
|
checkStatus: '',
|
||||||
|
inspectionAdvice: '',
|
||||||
|
measureNum: undefined,
|
||||||
|
launchType: undefined,
|
||||||
|
intervalType: undefined,
|
||||||
|
startCount: undefined,
|
||||||
|
startTime: '',
|
||||||
|
});
|
||||||
|
|
||||||
|
const formRules = {
|
||||||
|
implStatus: [{ required: true, message: '请输入落实情况' }],
|
||||||
|
};
|
||||||
|
|
||||||
|
function resetForm(mainId = '', bpmProcessId = '') {
|
||||||
|
Object.keys(formData).forEach((key) => {
|
||||||
|
if (key === 'num' || key === 'measureNum' || key === 'launchType' || key === 'intervalType' || key === 'startCount') {
|
||||||
|
formData[key] = undefined;
|
||||||
|
} else {
|
||||||
|
formData[key] = '';
|
||||||
|
}
|
||||||
|
});
|
||||||
|
formData.mainId = mainId;
|
||||||
|
formData.bpmProcessId = bpmProcessId;
|
||||||
|
uploadKey.value += 1;
|
||||||
|
nextTick(() => formRef.value?.clearValidate?.());
|
||||||
|
}
|
||||||
|
|
||||||
|
function open(mainId: string, secretLevel?: string | number, bpmProcessId = '') {
|
||||||
|
resetForm(mainId, bpmProcessId);
|
||||||
|
uploadSecretLevel.value = normalizeSecretLevel(secretLevel);
|
||||||
|
void applyCurrentUserFeedbackInfo();
|
||||||
|
visible.value = true;
|
||||||
|
}
|
||||||
|
|
||||||
|
function normalizeSecretLevel(value?: string | number) {
|
||||||
|
const level = Number(value);
|
||||||
|
return [1, 2, 3, 4].includes(level) ? level : 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
function getCurrentLoginDepart() {
|
||||||
|
const userInfo = (userStore.getUserInfo || {}) as Record<string, any>;
|
||||||
|
const loginInfo = (userStore.getLoginInfo || {}) as Record<string, any>;
|
||||||
|
const departs = Array.isArray(loginInfo.departs) ? loginInfo.departs : [];
|
||||||
|
if (userInfo.orgCode) {
|
||||||
|
return departs.find((item) => item.orgCode === userInfo.orgCode);
|
||||||
|
}
|
||||||
|
return departs.length === 1 ? departs[0] : undefined;
|
||||||
|
}
|
||||||
|
|
||||||
|
async function getCurrentDepartInfo() {
|
||||||
|
const userInfo = (userStore.getUserInfo || {}) as Record<string, any>;
|
||||||
|
const loginDepart = getCurrentLoginDepart();
|
||||||
|
if (loginDepart) {
|
||||||
|
return {
|
||||||
|
id: loginDepart.id || '',
|
||||||
|
departName: loginDepart.departName || '',
|
||||||
|
};
|
||||||
|
}
|
||||||
|
return {
|
||||||
|
id: userInfo.departIds || '',
|
||||||
|
departName: userInfo.departIds_dictText || userInfo.orgCodeTxt || '',
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
async function applyCurrentUserFeedbackInfo() {
|
||||||
|
const userInfo = (userStore.getUserInfo || {}) as Record<string, any>;
|
||||||
|
formData.responPersonid = userInfo.id || userInfo.userId || '';
|
||||||
|
formData.responPersonname = userInfo.realname || '';
|
||||||
|
const departInfo = await getCurrentDepartInfo();
|
||||||
|
formData.responDeptid = departInfo.id;
|
||||||
|
formData.responDeptname = departInfo.departName;
|
||||||
|
}
|
||||||
|
|
||||||
|
function handleDeptChange(value, row) {
|
||||||
|
if (row) {
|
||||||
|
formData.responDeptname = row.name || '';
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
function handleUserChange(value, row) {
|
||||||
|
if (row) {
|
||||||
|
formData.responPersonname = row.realname || row.name || '';
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
function handleCancel() {
|
||||||
|
visible.value = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
async function handleOk() {
|
||||||
|
try {
|
||||||
|
await formRef.value?.validate?.();
|
||||||
|
} catch {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
saving.value = true;
|
||||||
|
try {
|
||||||
|
await applyCurrentUserFeedbackInfo();
|
||||||
|
if (!formData.id && uploadFileRef.value?.hasPendingFiles?.()) {
|
||||||
|
formData.id = buildUUID();
|
||||||
|
}
|
||||||
|
const res = await bgXiSpeakFeedbackSaveOrUpdate({ ...formData }, false);
|
||||||
|
if (res.success) {
|
||||||
|
if (formData.id && uploadFileRef.value?.hasPendingFiles?.()) {
|
||||||
|
await uploadFileRef.value.bindBussinessId(formData.id);
|
||||||
|
}
|
||||||
|
createMessage.success(res.message || '保存成功');
|
||||||
|
visible.value = false;
|
||||||
|
emit('success');
|
||||||
|
} else {
|
||||||
|
createMessage.warning(res.message || '保存失败');
|
||||||
|
}
|
||||||
|
} finally {
|
||||||
|
saving.value = false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
defineExpose({
|
||||||
|
open,
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style lang="less" scoped>
|
||||||
|
.bpm-feedback-modal-form {
|
||||||
|
padding: 12px 8px 0;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
@@ -1,17 +1,35 @@
|
|||||||
<template>
|
<template>
|
||||||
<a-spin :spinning="loading">
|
<a-spin :spinning="loading">
|
||||||
<div class="bg-xispeak-bpm-form">
|
<div class="bg-xispeak-bpm-form">
|
||||||
<a-form class="main-form" :labelCol="labelCol" :wrapperCol="wrapperCol" :model="mainForm">
|
<a-form class="main-form" :class="{ 'main-form-readonly': mainDisabled }" labelAlign="left" :labelCol="labelCol" :wrapperCol="wrapperCol" :model="mainForm">
|
||||||
|
<div class="base-info-header section-toolbar">
|
||||||
<div class="section-title">基础信息</div>
|
<div class="section-title">基础信息</div>
|
||||||
<a-row :gutter="16">
|
<a-space class="section-actions">
|
||||||
<a-col :span="24" v-if="hasPermission('xizhishi')">
|
<a-button v-if="!mainDisabled" class="base-save-button" type="link" size="small" :loading="savingMain" @click="submitForm">
|
||||||
<a-form-item label="习近平总书记重要讲话指示批示情况" name="speakStatus" :labelCol="wideLabelCol" :wrapperCol="wideWrapperCol">
|
<Icon icon="ant-design:save-outlined" />
|
||||||
<a-input v-model:value="mainForm.speakStatus" :disabled="isDisabledAuth('xizhishi')" allow-clear />
|
保存
|
||||||
|
</a-button>
|
||||||
|
<a-button class="section-action-button" :type="showBaseInfoDetail ? 'default' : 'link'" size="small" @click="showBaseInfoDetail = !showBaseInfoDetail">
|
||||||
|
<Icon :icon="showBaseInfoDetail ? 'ant-design:up-outlined' : 'ant-design:down-outlined'" />
|
||||||
|
{{ showBaseInfoDetail ? '收起基础信息' : '展开全部信息' }}
|
||||||
|
</a-button>
|
||||||
|
</a-space>
|
||||||
|
</div>
|
||||||
|
<a-row class="base-info-row" :gutter="[12, 4]">
|
||||||
|
<a-col :span="12" v-if="hasPermission('xizhishi')">
|
||||||
|
<a-form-item label="重要讲话指示批示" name="speakStatus">
|
||||||
|
<a-textarea v-model:value="mainForm.speakStatus" :auto-size="{ minRows: 1, maxRows: 7 }" :disabled="isDisabledAuth('xizhishi')" allow-clear />
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
</a-col>
|
</a-col>
|
||||||
|
<a-col :span="12">
|
||||||
|
<a-form-item label="学习传达研究部署" name="status">
|
||||||
|
<a-textarea v-model:value="mainForm.status" :auto-size="{ minRows: 1, maxRows: 7 }" :disabled="mainDisabled" allow-clear />
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
<template v-if="showBaseInfoDetail">
|
||||||
<a-col :span="12" v-if="hasPermission('xitime')">
|
<a-col :span="12" v-if="hasPermission('xitime')">
|
||||||
<a-form-item label="时间" name="time">
|
<a-form-item label="时间" name="time">
|
||||||
<a-date-picker v-model:value="mainForm.time" value-format="YYYY-MM-DD" :disabled="mainDisabled" style="width: 100%" allow-clear />
|
<a-date-picker v-model:value="mainForm.time" value-format="YYYY-MM-DD" :disabled="isDisabledAuth('xitime')" style="width: 100%" allow-clear />
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
</a-col>
|
</a-col>
|
||||||
<a-col :span="12">
|
<a-col :span="12">
|
||||||
@@ -19,16 +37,11 @@
|
|||||||
<j-select-user v-model:value="mainForm.responsiblePerson" :disabled="mainDisabled" allow-clear />
|
<j-select-user v-model:value="mainForm.responsiblePerson" :disabled="mainDisabled" allow-clear />
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
</a-col>
|
</a-col>
|
||||||
<a-col :span="24">
|
<a-col :span="12">
|
||||||
<a-form-item label="企业负责同志批示情况" name="elmComment" :labelCol="wideLabelCol" :wrapperCol="wideWrapperCol">
|
<a-form-item label="企业负责同志批示情况" name="elmComment">
|
||||||
<a-input v-model:value="mainForm.elmComment" :disabled="mainDisabled" allow-clear />
|
<a-input v-model:value="mainForm.elmComment" :disabled="mainDisabled" allow-clear />
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
</a-col>
|
</a-col>
|
||||||
<a-col :span="24">
|
|
||||||
<a-form-item label="学习传达研究部署情况" name="status" :labelCol="wideLabelCol" :wrapperCol="wideWrapperCol">
|
|
||||||
<a-input v-model:value="mainForm.status" :disabled="mainDisabled" allow-clear />
|
|
||||||
</a-form-item>
|
|
||||||
</a-col>
|
|
||||||
<a-col :span="12">
|
<a-col :span="12">
|
||||||
<a-form-item label="牵头部门" name="leadDepartment">
|
<a-form-item label="牵头部门" name="leadDepartment">
|
||||||
<j-select-dept v-model:value="mainForm.leadDepartment" :disabled="mainDisabled" :multiple="true" checkStrictly allow-clear />
|
<j-select-dept v-model:value="mainForm.leadDepartment" :disabled="mainDisabled" :multiple="true" checkStrictly allow-clear />
|
||||||
@@ -39,13 +52,13 @@
|
|||||||
<j-select-dept v-model:value="mainForm.implDept" :disabled="mainDisabled" :multiple="true" checkStrictly allow-clear />
|
<j-select-dept v-model:value="mainForm.implDept" :disabled="mainDisabled" :multiple="true" checkStrictly allow-clear />
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
</a-col>
|
</a-col>
|
||||||
<a-col :span="24">
|
<a-col :span="12">
|
||||||
<a-form-item label="落实方案" name="implPlan" :labelCol="wideLabelCol" :wrapperCol="wideWrapperCol">
|
<a-form-item label="落实方案" name="implPlan">
|
||||||
<a-input v-model:value="mainForm.implPlan" :disabled="mainDisabled" allow-clear />
|
<a-input v-model:value="mainForm.implPlan" :disabled="mainDisabled" allow-clear />
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
</a-col>
|
</a-col>
|
||||||
<a-col :span="24">
|
<a-col :span="12">
|
||||||
<a-form-item label="贯彻落实措施" name="implMeasures" :labelCol="wideLabelCol" :wrapperCol="wideWrapperCol">
|
<a-form-item label="贯彻落实措施" name="implMeasures">
|
||||||
<a-input v-model:value="mainForm.implMeasures" :disabled="mainDisabled" allow-clear />
|
<a-input v-model:value="mainForm.implMeasures" :disabled="mainDisabled" allow-clear />
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
</a-col>
|
</a-col>
|
||||||
@@ -66,21 +79,16 @@
|
|||||||
</a-col>
|
</a-col>
|
||||||
<a-col :span="12">
|
<a-col :span="12">
|
||||||
<a-form-item label="完成状态" name="completionStatus">
|
<a-form-item label="完成状态" name="completionStatus">
|
||||||
<a-input v-model:value="mainForm.completionStatus" :disabled="mainDisabled" allow-clear />
|
<JDictSelectTag v-model:value="mainForm.completionStatus" dictCode="db_status" placeholder="请选择完成状态" type="radio" :disabled="mainDisabled" />
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
</a-col>
|
</a-col>
|
||||||
<a-col :span="24">
|
<a-col :span="12">
|
||||||
<a-form-item label="落实情况" name="implStatus" :labelCol="wideLabelCol" :wrapperCol="wideWrapperCol">
|
<a-form-item label="报告反馈情况" name="reportFeedbackStatus">
|
||||||
<a-textarea v-model:value="mainForm.implStatus" :rows="3" :disabled="mainDisabled" allow-clear />
|
|
||||||
</a-form-item>
|
|
||||||
</a-col>
|
|
||||||
<a-col :span="24">
|
|
||||||
<a-form-item label="报告反馈情况" name="reportFeedbackStatus" :labelCol="wideLabelCol" :wrapperCol="wideWrapperCol">
|
|
||||||
<a-input v-model:value="mainForm.reportFeedbackStatus" :disabled="mainDisabled" allow-clear />
|
<a-input v-model:value="mainForm.reportFeedbackStatus" :disabled="mainDisabled" allow-clear />
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
</a-col>
|
</a-col>
|
||||||
<a-col :span="24">
|
<a-col :span="12">
|
||||||
<a-form-item label="拖期风险应对措施" name="delayRiskMitigation" :labelCol="wideLabelCol" :wrapperCol="wideWrapperCol">
|
<a-form-item label="拖期风险应对措施" name="delayRiskMitigation">
|
||||||
<a-input v-model:value="mainForm.delayRiskMitigation" :disabled="mainDisabled" allow-clear />
|
<a-input v-model:value="mainForm.delayRiskMitigation" :disabled="mainDisabled" allow-clear />
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
</a-col>
|
</a-col>
|
||||||
@@ -94,183 +102,101 @@
|
|||||||
<j-tree-select v-model:value="mainForm.pid" dict="bg_xi_speak,impl_status,id" pidField="pid" pidValue="0" hasChildField="has_child" :disabled="mainDisabled" allow-clear />
|
<j-tree-select v-model:value="mainForm.pid" dict="bg_xi_speak,impl_status,id" pidField="pid" pidValue="0" hasChildField="has_child" :disabled="mainDisabled" allow-clear />
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
</a-col>
|
</a-col>
|
||||||
|
<a-col :span="12">
|
||||||
|
<a-form-item label="落实情况" name="implStatus">
|
||||||
|
<a-textarea v-model:value="mainForm.implStatus" :auto-size="{ minRows: 1, maxRows: 7 }" :disabled="mainDisabled" allow-clear />
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
</template>
|
||||||
</a-row>
|
</a-row>
|
||||||
<div v-if="!mainDisabled" class="main-actions">
|
|
||||||
<a-button type="primary" :loading="savingMain" @click="submitForm">保存主表数据</a-button>
|
|
||||||
</div>
|
|
||||||
</a-form>
|
</a-form>
|
||||||
|
|
||||||
<a-divider />
|
<a-divider />
|
||||||
|
|
||||||
<div class="feedback-header">
|
<div class="feedback-header section-toolbar">
|
||||||
<div class="section-title">反馈信息</div>
|
<div class="section-title">反馈信息</div>
|
||||||
<a-button v-if="hasPermission('xifankui')" type="primary" @click="showFeedbackForm = true">新增反馈</a-button>
|
<a-button v-if="showAddFeedback" class="section-action-button feedback-add-button" type="primary" @click="openFeedbackModal">
|
||||||
|
<Icon icon="ant-design:plus-outlined" />
|
||||||
|
新增反馈
|
||||||
|
</a-button>
|
||||||
</div>
|
</div>
|
||||||
<a-table rowKey="id" size="small" bordered :columns="feedbackColumns" :data-source="feedbackList" :pagination="false" :scroll="{ x: 900 }" />
|
<a-table
|
||||||
|
rowKey="id"
|
||||||
<a-form
|
size="small"
|
||||||
v-if="showFeedbackForm && !mainDisabled"
|
bordered
|
||||||
ref="feedbackFormRef"
|
:columns="feedbackColumns"
|
||||||
class="feedback-form"
|
:data-source="feedbackList"
|
||||||
:model="feedbackForm"
|
:pagination="false"
|
||||||
:rules="feedbackRules"
|
:scroll="{ x: 1400 }"
|
||||||
:labelCol="labelCol"
|
|
||||||
:wrapperCol="wrapperCol"
|
|
||||||
>
|
>
|
||||||
<div class="section-title">新增反馈</div>
|
<template #bodyCell="{ column, record }">
|
||||||
<a-row :gutter="16">
|
<template v-if="column.key === 'attachments'">
|
||||||
<a-col :span="12">
|
<SUploadFile
|
||||||
<a-form-item label="序号" name="num">
|
v-if="record.id"
|
||||||
<a-input-number v-model:value="feedbackForm.num" style="width: 100%" allow-clear />
|
class="feedback-attachment-list"
|
||||||
</a-form-item>
|
:bussiness-id="record.id"
|
||||||
</a-col>
|
:disabled="true"
|
||||||
<a-col :span="12">
|
:multiple="true"
|
||||||
<a-form-item label="反馈部门id" name="responDeptid">
|
/>
|
||||||
<a-input v-model:value="feedbackForm.responDeptid" allow-clear />
|
<span v-else>-</span>
|
||||||
</a-form-item>
|
</template>
|
||||||
</a-col>
|
</template>
|
||||||
<a-col :span="12">
|
</a-table>
|
||||||
<a-form-item label="反馈部门名称" name="responDeptname">
|
|
||||||
<a-input v-model:value="feedbackForm.responDeptname" allow-clear />
|
<BgXiSpeakBPMFeedbackModal ref="feedbackModalRef" @success="loadFeedbackList" />
|
||||||
</a-form-item>
|
|
||||||
</a-col>
|
|
||||||
<a-col :span="12">
|
|
||||||
<a-form-item label="反馈人id" name="responPersonid">
|
|
||||||
<a-input v-model:value="feedbackForm.responPersonid" allow-clear />
|
|
||||||
</a-form-item>
|
|
||||||
</a-col>
|
|
||||||
<a-col :span="12">
|
|
||||||
<a-form-item label="反馈人姓名" name="responPersonname">
|
|
||||||
<a-input v-model:value="feedbackForm.responPersonname" allow-clear />
|
|
||||||
</a-form-item>
|
|
||||||
</a-col>
|
|
||||||
<a-col :span="24">
|
|
||||||
<a-form-item label="措施内容" name="method" :labelCol="wideLabelCol" :wrapperCol="wideWrapperCol">
|
|
||||||
<a-textarea v-model:value="feedbackForm.method" :rows="3" allow-clear />
|
|
||||||
</a-form-item>
|
|
||||||
</a-col>
|
|
||||||
<a-col :span="12">
|
|
||||||
<a-form-item label="完成期限" name="deadline">
|
|
||||||
<a-date-picker v-model:value="feedbackForm.deadline" value-format="YYYY-MM-DD HH:mm:ss" style="width: 100%" allow-clear />
|
|
||||||
</a-form-item>
|
|
||||||
</a-col>
|
|
||||||
<a-col :span="12">
|
|
||||||
<a-form-item label="成果形式" name="outcomeForm">
|
|
||||||
<a-input v-model:value="feedbackForm.outcomeForm" allow-clear />
|
|
||||||
</a-form-item>
|
|
||||||
</a-col>
|
|
||||||
<a-col :span="24">
|
|
||||||
<a-form-item label="进展情况" name="progress" :labelCol="wideLabelCol" :wrapperCol="wideWrapperCol">
|
|
||||||
<a-textarea v-model:value="feedbackForm.progress" :rows="3" allow-clear />
|
|
||||||
</a-form-item>
|
|
||||||
</a-col>
|
|
||||||
<a-col :span="24">
|
|
||||||
<a-form-item label="落实情况" name="implStatus" :labelCol="wideLabelCol" :wrapperCol="wideWrapperCol">
|
|
||||||
<a-textarea v-model:value="feedbackForm.implStatus" :rows="3" allow-clear />
|
|
||||||
</a-form-item>
|
|
||||||
</a-col>
|
|
||||||
<a-col :span="12">
|
|
||||||
<a-form-item label="完成状态" name="completionStatus">
|
|
||||||
<a-input v-model:value="feedbackForm.completionStatus" allow-clear />
|
|
||||||
</a-form-item>
|
|
||||||
</a-col>
|
|
||||||
<a-col :span="24">
|
|
||||||
<a-form-item label="落实计划" name="completionPlan" :labelCol="wideLabelCol" :wrapperCol="wideWrapperCol">
|
|
||||||
<a-textarea v-model:value="feedbackForm.completionPlan" :rows="3" allow-clear />
|
|
||||||
</a-form-item>
|
|
||||||
</a-col>
|
|
||||||
<a-col :span="12">
|
|
||||||
<a-form-item label="总措施号" name="sumMethodNum">
|
|
||||||
<a-input v-model:value="feedbackForm.sumMethodNum" allow-clear />
|
|
||||||
</a-form-item>
|
|
||||||
</a-col>
|
|
||||||
<a-col :span="12">
|
|
||||||
<a-form-item label="检查情况" name="checkStatus">
|
|
||||||
<a-input v-model:value="feedbackForm.checkStatus" allow-clear />
|
|
||||||
</a-form-item>
|
|
||||||
</a-col>
|
|
||||||
<a-col :span="24">
|
|
||||||
<a-form-item label="监督意见" name="inspectionAdvice" :labelCol="wideLabelCol" :wrapperCol="wideWrapperCol">
|
|
||||||
<a-textarea v-model:value="feedbackForm.inspectionAdvice" :rows="3" allow-clear />
|
|
||||||
</a-form-item>
|
|
||||||
</a-col>
|
|
||||||
<a-col :span="12">
|
|
||||||
<a-form-item label="措施数量" name="measureNum">
|
|
||||||
<a-input-number v-model:value="feedbackForm.measureNum" style="width: 100%" allow-clear />
|
|
||||||
</a-form-item>
|
|
||||||
</a-col>
|
|
||||||
<a-col :span="12">
|
|
||||||
<a-form-item label="发起类型" name="launchType">
|
|
||||||
<a-select v-model:value="feedbackForm.launchType" placeholder="请选择发起类型" allow-clear>
|
|
||||||
<a-select-option :value="0">立即发起</a-select-option>
|
|
||||||
<a-select-option :value="1">周期发起</a-select-option>
|
|
||||||
</a-select>
|
|
||||||
</a-form-item>
|
|
||||||
</a-col>
|
|
||||||
<a-col :span="12">
|
|
||||||
<a-form-item label="周期类型" name="intervalType">
|
|
||||||
<a-select v-model:value="feedbackForm.intervalType" placeholder="请选择周期类型" allow-clear>
|
|
||||||
<a-select-option :value="1">日</a-select-option>
|
|
||||||
<a-select-option :value="2">周</a-select-option>
|
|
||||||
<a-select-option :value="3">两周</a-select-option>
|
|
||||||
<a-select-option :value="4">月</a-select-option>
|
|
||||||
<a-select-option :value="5">季</a-select-option>
|
|
||||||
</a-select>
|
|
||||||
</a-form-item>
|
|
||||||
</a-col>
|
|
||||||
<a-col :span="12">
|
|
||||||
<a-form-item label="周期任务数量" name="startCount">
|
|
||||||
<a-input-number v-model:value="feedbackForm.startCount" style="width: 100%" allow-clear />
|
|
||||||
</a-form-item>
|
|
||||||
</a-col>
|
|
||||||
<a-col :span="12">
|
|
||||||
<a-form-item label="周期开始时间" name="startTime">
|
|
||||||
<a-date-picker v-model:value="feedbackForm.startTime" showTime value-format="YYYY-MM-DD HH:mm:ss" style="width: 100%" placeholder="请选择周期开始时间" allow-clear />
|
|
||||||
</a-form-item>
|
|
||||||
</a-col>
|
|
||||||
</a-row>
|
|
||||||
<div class="main-actions">
|
|
||||||
<a-button @click="cancelFeedback">取消</a-button>
|
|
||||||
<a-button type="primary" :loading="savingFeedback" @click="saveFeedback">保存反馈</a-button>
|
|
||||||
</div>
|
|
||||||
</a-form>
|
|
||||||
|
|
||||||
<template v-if="showProcessHandle">
|
<template v-if="showProcessHandle">
|
||||||
<a-divider />
|
<a-divider />
|
||||||
|
<div class="process-header section-toolbar">
|
||||||
<div class="section-title">流程办理</div>
|
<div class="section-title">流程办理</div>
|
||||||
<a-form class="process-variable-form" :labelCol="labelCol" :wrapperCol="wrapperCol">
|
</div>
|
||||||
|
<a-form v-if="showSubApproveUser" class="process-variable-form" labelAlign="left" :labelCol="labelCol" :wrapperCol="wrapperCol">
|
||||||
<a-row :gutter="16">
|
<a-row :gutter="16">
|
||||||
<a-col :span="24">
|
<a-col :span="12">
|
||||||
<a-form-item label="子流程经办人" :labelCol="wideLabelCol" :wrapperCol="wideWrapperCol">
|
<a-form-item label="是否办结" :labelCol="wideLabelCol" :wrapperCol="wideWrapperCol">
|
||||||
<a-space class="sub-approve-user-row">
|
<a-radio-group v-model:value="isEnd" :disabled="savingSubApproveUser">
|
||||||
<a-input
|
<a-radio :value="0">否(分配部门经办人)</a-radio>
|
||||||
|
<a-radio :value="1">是(办结)</a-radio>
|
||||||
|
</a-radio-group>
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
<a-col v-if="showSubApproveUserSelector" :span="12">
|
||||||
|
<a-form-item label="部门经办人" :labelCol="wideLabelCol" :wrapperCol="wideWrapperCol">
|
||||||
|
<j-select-user
|
||||||
v-model:value="subApproveUser"
|
v-model:value="subApproveUser"
|
||||||
placeholder="输入username,多个用英文逗号分隔"
|
|
||||||
allow-clear
|
|
||||||
:disabled="savingSubApproveUser"
|
:disabled="savingSubApproveUser"
|
||||||
|
allow-clear
|
||||||
/>
|
/>
|
||||||
<a-button type="primary" :loading="savingSubApproveUser" @click="saveSubApproveUserVariable">保存经办人</a-button>
|
|
||||||
</a-space>
|
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
</a-col>
|
</a-col>
|
||||||
</a-row>
|
</a-row>
|
||||||
</a-form>
|
</a-form>
|
||||||
<TaskHandleInnerContent :form-data="formData" :claim="claim" @success="handleProcessSuccess" @claimSuccess="handleClaimSuccess" />
|
<TaskHandleInnerContent
|
||||||
|
:form-data="formData"
|
||||||
|
:claim="claim"
|
||||||
|
:beforeHandle="saveMainFormBeforeProcessHandle"
|
||||||
|
@success="handleProcessSuccess"
|
||||||
|
@claimSuccess="handleClaimSuccess"
|
||||||
|
/>
|
||||||
</template>
|
</template>
|
||||||
</div>
|
</div>
|
||||||
</a-spin>
|
</a-spin>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script lang="ts" setup>
|
<script lang="ts" setup>
|
||||||
import { computed, nextTick, onMounted, reactive, ref, watch } from 'vue';
|
import { computed, onMounted, reactive, ref, watch } from 'vue';
|
||||||
import { defHttp } from '/@/utils/http/axios';
|
import { defHttp } from '/@/utils/http/axios';
|
||||||
import { useMessage } from '/@/hooks/web/useMessage';
|
import { useMessage } from '/@/hooks/web/useMessage';
|
||||||
import JSelectDept from '/@/components/Form/src/jeecg/components/JSelectDept.vue';
|
import JSelectDept from '/@/components/Form/src/jeecg/components/JSelectDept.vue';
|
||||||
import JSelectUser from '/@/components/Form/src/jeecg/components/JSelectUser.vue';
|
import JSelectUser from '/@/components/Form/src/jeecg/components/JSelectUser.vue';
|
||||||
import JTreeSelect from '/@/components/Form/src/jeecg/components/JTreeSelect.vue';
|
import JTreeSelect from '/@/components/Form/src/jeecg/components/JTreeSelect.vue';
|
||||||
import { bgXiSpeakFeedbackList, bgXiSpeakFeedbackSaveOrUpdate, saveBpmForm, setProcessVariable } from '../BgXiSpeak.api';
|
import JDictSelectTag from '/@/components/Form/src/jeecg/components/JDictSelectTag.vue';
|
||||||
|
import Icon from '/@/components/Icon/index';
|
||||||
|
import { bgXiSpeakFeedbackList, saveBpmForm, setProcessVariable } from '../BgXiSpeak.api';
|
||||||
import { usePermission } from '/@/hooks/web/usePermission';
|
import { usePermission } from '/@/hooks/web/usePermission';
|
||||||
import TaskHandleInnerContent from '/@/views/super/bpm/process/personalOffice/myHandleTask/content/TaskHandleInnerContent.vue';
|
import TaskHandleInnerContent from '/@/views/super/bpm/process/personalOffice/myHandleTask/content/TaskHandleInnerContent.vue';
|
||||||
|
import BgXiSpeakBPMFeedbackModal from './BgXiSpeakBPMFeedbackModal.vue';
|
||||||
|
import SUploadFile from '/@/components/semri/fileComponent/SUploadFile.vue';
|
||||||
|
|
||||||
const { isDisabledAuth, hasPermission, initBpmFormData } = usePermission();
|
const { isDisabledAuth, hasPermission, initBpmFormData } = usePermission();
|
||||||
|
|
||||||
@@ -282,6 +208,8 @@
|
|||||||
});
|
});
|
||||||
|
|
||||||
initBpmFormData(props.formData);
|
initBpmFormData(props.formData);
|
||||||
|
console.log("@props.formData", props.formData);
|
||||||
|
console.log("@props", props);
|
||||||
|
|
||||||
const emit = defineEmits(['ok', 'success', 'claimSuccess']);
|
const emit = defineEmits(['ok', 'success', 'claimSuccess']);
|
||||||
const { createMessage } = useMessage();
|
const { createMessage } = useMessage();
|
||||||
@@ -291,15 +219,17 @@
|
|||||||
const wrapperCol = { xs: { span: 24 }, sm: { span: 17 } };
|
const wrapperCol = { xs: { span: 24 }, sm: { span: 17 } };
|
||||||
const wideLabelCol = { xs: { span: 24 }, sm: { span: 3 } };
|
const wideLabelCol = { xs: { span: 24 }, sm: { span: 3 } };
|
||||||
const wideWrapperCol = { xs: { span: 24 }, sm: { span: 21 } };
|
const wideWrapperCol = { xs: { span: 24 }, sm: { span: 21 } };
|
||||||
|
const compactLabelCol = { xs: { span: 24 }, sm: { span: 5 } };
|
||||||
|
const compactWrapperCol = { xs: { span: 24 }, sm: { span: 19 } };
|
||||||
|
|
||||||
const feedbackFormRef = ref();
|
const feedbackModalRef = ref();
|
||||||
const loading = ref(false);
|
const loading = ref(false);
|
||||||
const savingMain = ref(false);
|
const savingMain = ref(false);
|
||||||
const savingFeedback = ref(false);
|
|
||||||
const savingSubApproveUser = ref(false);
|
const savingSubApproveUser = ref(false);
|
||||||
const showFeedbackForm = ref(false);
|
const showBaseInfoDetail = ref(false);
|
||||||
const feedbackList = ref<any[]>([]);
|
const feedbackList = ref<any[]>([]);
|
||||||
const subApproveUser = ref('');
|
const subApproveUser = ref('');
|
||||||
|
const isEnd = ref(0);
|
||||||
|
|
||||||
const mainForm = reactive<Record<string, any>>({
|
const mainForm = reactive<Record<string, any>>({
|
||||||
id: '',
|
id: '',
|
||||||
@@ -329,106 +259,15 @@
|
|||||||
supervisionCount: undefined,
|
supervisionCount: undefined,
|
||||||
});
|
});
|
||||||
|
|
||||||
const feedbackForm = reactive<Record<string, any>>({
|
|
||||||
id: '',
|
|
||||||
responDeptid: '',
|
|
||||||
responDeptname: '',
|
|
||||||
responPersonid: '',
|
|
||||||
responPersonname: '',
|
|
||||||
implStatus: '',
|
|
||||||
completionStatus: '',
|
|
||||||
completionPlan: '',
|
|
||||||
mainId: '',
|
|
||||||
num: undefined,
|
|
||||||
method: '',
|
|
||||||
deadline: '',
|
|
||||||
outcomeForm: '',
|
|
||||||
progress: '',
|
|
||||||
sumMethodNum: '',
|
|
||||||
checkStatus: '',
|
|
||||||
inspectionAdvice: '',
|
|
||||||
measureNum: undefined,
|
|
||||||
launchType: undefined,
|
|
||||||
intervalType: undefined,
|
|
||||||
startCount: undefined,
|
|
||||||
startTime: '',
|
|
||||||
});
|
|
||||||
|
|
||||||
const feedbackRules = {
|
|
||||||
implStatus: [{ required: true, message: '请输入落实情况' }],
|
|
||||||
};
|
|
||||||
|
|
||||||
const feedbackColumns = [
|
const feedbackColumns = [
|
||||||
{ title: '序号', dataIndex: 'num', align: 'center', width: 60 },
|
{ title: '序号', dataIndex: 'num', align: 'center', width: 60 },
|
||||||
{ title: '反馈部门名称', dataIndex: 'responDeptname', align: 'center', width: 120 },
|
{ title: '反馈部门名称', dataIndex: 'responDeptname', align: 'center', width: 140 },
|
||||||
{ title: '反馈人姓名', dataIndex: 'responPersonname', align: 'center', width: 100 },
|
{ title: '反馈人姓名', dataIndex: 'responPersonname', align: 'center', width: 120 },
|
||||||
{ title: '措施内容', dataIndex: 'method', align: 'left', width: 200 },
|
{ title: '措施内容', dataIndex: 'method', align: 'left', width: 200 },
|
||||||
{
|
{ title: '完成状态', dataIndex: 'completionStatus_dictText', align: 'center', width: 100 },
|
||||||
title: '完成期限',
|
|
||||||
dataIndex: 'deadline',
|
|
||||||
align: 'center',
|
|
||||||
width: 120,
|
|
||||||
customRender: ({ text }) => {
|
|
||||||
if (!text) return '';
|
|
||||||
if (text instanceof Date) {
|
|
||||||
const y = text.getFullYear();
|
|
||||||
const m = String(text.getMonth() + 1).padStart(2, '0');
|
|
||||||
const d = String(text.getDate()).padStart(2, '0');
|
|
||||||
return `${y}-${m}-${d}`;
|
|
||||||
}
|
|
||||||
return String(text).substr(0, 10);
|
|
||||||
},
|
|
||||||
},
|
|
||||||
{ title: '成果形式', dataIndex: 'outcomeForm', align: 'center', width: 100 },
|
|
||||||
{ title: '进展情况', dataIndex: 'progress', align: 'left', width: 200 },
|
{ title: '进展情况', dataIndex: 'progress', align: 'left', width: 200 },
|
||||||
{ title: '落实情况', dataIndex: 'implStatus', align: 'left', width: 200 },
|
{ title: '落实情况', dataIndex: 'implStatus', align: 'left', width: 200 },
|
||||||
{ title: '完成状态', dataIndex: 'completionStatus', align: 'center', width: 100 },
|
{ title: '附件', dataIndex: 'id', key: 'attachments', align: 'left', width: 340 },
|
||||||
{ title: '落实计划', dataIndex: 'completionPlan', align: 'left', width: 200 },
|
|
||||||
{ title: '总措施号', dataIndex: 'sumMethodNum', align: 'center', width: 100 },
|
|
||||||
{ title: '检查情况', dataIndex: 'checkStatus', align: 'center', width: 120 },
|
|
||||||
{ title: '监督意见', dataIndex: 'inspectionAdvice', align: 'left', width: 200 },
|
|
||||||
{ title: '措施数量', dataIndex: 'measureNum', align: 'center', width: 80 },
|
|
||||||
{
|
|
||||||
title: '发起类型',
|
|
||||||
dataIndex: 'launchType',
|
|
||||||
align: 'center',
|
|
||||||
width: 100,
|
|
||||||
customRender: ({ text }) => {
|
|
||||||
if (text === 0) return '立即发起';
|
|
||||||
if (text === 1) return '周期发起';
|
|
||||||
return text || '';
|
|
||||||
},
|
|
||||||
},
|
|
||||||
{
|
|
||||||
title: '周期类型',
|
|
||||||
dataIndex: 'intervalType',
|
|
||||||
align: 'center',
|
|
||||||
width: 80,
|
|
||||||
customRender: ({ text }) => {
|
|
||||||
const map = { 1: '日', 2: '周', 3: '两周', 4: '月', 5: '季' };
|
|
||||||
return map[text] || text || '';
|
|
||||||
},
|
|
||||||
},
|
|
||||||
{ title: '周期任务数量', dataIndex: 'startCount', align: 'center', width: 100 },
|
|
||||||
{
|
|
||||||
title: '周期开始时间',
|
|
||||||
dataIndex: 'startTime',
|
|
||||||
align: 'center',
|
|
||||||
width: 160,
|
|
||||||
customRender: ({ text }) => {
|
|
||||||
if (!text) return '';
|
|
||||||
if (text instanceof Date) {
|
|
||||||
const y = text.getFullYear();
|
|
||||||
const m = String(text.getMonth() + 1).padStart(2, '0');
|
|
||||||
const d = String(text.getDate()).padStart(2, '0');
|
|
||||||
const h = String(text.getHours()).padStart(2, '0');
|
|
||||||
const min = String(text.getMinutes()).padStart(2, '0');
|
|
||||||
const s = String(text.getSeconds()).padStart(2, '0');
|
|
||||||
return `${y}-${m}-${d} ${h}:${min}:${s}`;
|
|
||||||
}
|
|
||||||
return String(text);
|
|
||||||
},
|
|
||||||
},
|
|
||||||
];
|
];
|
||||||
|
|
||||||
const mainDisabled = computed(() => {
|
const mainDisabled = computed(() => {
|
||||||
@@ -437,13 +276,22 @@
|
|||||||
}
|
}
|
||||||
return props.formDisabled;
|
return props.formDisabled;
|
||||||
});
|
});
|
||||||
|
|
||||||
const showProcessHandle = computed(() => props.formBpm && !!props.formData?.taskId);
|
const showProcessHandle = computed(() => props.formBpm && !!props.formData?.taskId);
|
||||||
|
const showAddFeedback = computed(() => String(props.formData?.extendUrlParams?.addfeedback ?? '') === '1');
|
||||||
|
const showSubApproveUser = computed(() => String(props.formData?.extendUrlParams?.selectuser ?? '') === '1');
|
||||||
|
const showSubApproveUserSelector = computed(() => showSubApproveUser.value && String(isEnd.value) !== '1');
|
||||||
|
|
||||||
const processInfo = computed(() => ({
|
const processInfo = computed(() => ({
|
||||||
taskId: props.formData?.taskId,
|
taskId: props.formData?.taskId,
|
||||||
taskDefKey: props.formData?.taskDefKey,
|
taskDefKey: props.formData?.taskDefKey,
|
||||||
processInstanceId: props.formData?.procInsId || props.formData?.processInstanceId || props.formData?.vars?.BPM_INST_ID,
|
processInstanceId:
|
||||||
|
props.formData?.procInsId ||
|
||||||
|
props.formData?.procInstId ||
|
||||||
|
props.formData?.processInstanceId ||
|
||||||
|
props.formData?.vars?.BPM_INST_ID ||
|
||||||
|
props.formData?.vars?.JG_LOCAL_PROCESS_ID ||
|
||||||
|
props.formData?.vars?.process_inst_id ||
|
||||||
|
props.formData?.vars?.processInstanceId,
|
||||||
processDataId: props.formData?.processDataId,
|
processDataId: props.formData?.processDataId,
|
||||||
processTableName: props.formData?.processTableName,
|
processTableName: props.formData?.processTableName,
|
||||||
}));
|
}));
|
||||||
@@ -453,15 +301,24 @@
|
|||||||
});
|
});
|
||||||
|
|
||||||
watch(
|
watch(
|
||||||
() => props.formData?.dataId,
|
[() => props.formData?.dataId, () => processInfo.value.processInstanceId],
|
||||||
() => initFormData()
|
() => initFormData()
|
||||||
);
|
);
|
||||||
|
|
||||||
|
watch(
|
||||||
|
() => props.formData?.vars?.isEnd,
|
||||||
|
(value) => {
|
||||||
|
isEnd.value = String(value ?? '0') === '1' ? 1 : 0;
|
||||||
|
},
|
||||||
|
{ immediate: true }
|
||||||
|
);
|
||||||
|
|
||||||
async function initFormData() {
|
async function initFormData() {
|
||||||
const dataId = props.formData?.dataId;
|
const dataId = props.formData?.dataId;
|
||||||
if (!dataId) {
|
if (!dataId) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
showBaseInfoDetail.value = false;
|
||||||
loading.value = true;
|
loading.value = true;
|
||||||
try {
|
try {
|
||||||
const data = await defHttp.get({ url: queryByIdUrl, params: { id: dataId } });
|
const data = await defHttp.get({ url: queryByIdUrl, params: { id: dataId } });
|
||||||
@@ -479,132 +336,126 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
async function loadFeedbackList() {
|
async function loadFeedbackList() {
|
||||||
if (!mainForm.id) {
|
const bpmProcessId = processInfo.value.processInstanceId;
|
||||||
|
if (!mainForm.id || !bpmProcessId) {
|
||||||
feedbackList.value = [];
|
feedbackList.value = [];
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
const res = await bgXiSpeakFeedbackList({ mainId: mainForm.id, pageNo: 1, pageSize: 999 });
|
const res = await bgXiSpeakFeedbackList({ mainId: mainForm.id, bpmProcessId, pageNo: 1, pageSize: 999 });
|
||||||
feedbackList.value = res?.records || res?.result?.records || [];
|
feedbackList.value = res?.records || res?.result?.records || [];
|
||||||
}
|
}
|
||||||
|
|
||||||
async function submitForm() {
|
async function submitForm() {
|
||||||
|
return saveMainForm();
|
||||||
|
}
|
||||||
|
|
||||||
|
async function saveMainForm(options: { showMessage?: boolean; emitOk?: boolean } = {}) {
|
||||||
|
const { showMessage = true, emitOk = true } = options;
|
||||||
savingMain.value = true;
|
savingMain.value = true;
|
||||||
try {
|
try {
|
||||||
const processInstanceId = processInfo.value.processInstanceId;
|
const processInstanceId = processInfo.value.processInstanceId;
|
||||||
|
console.log('BgXiSpeak BPM process info', { ...processInfo.value, processInstanceId });
|
||||||
const res = await saveBpmForm({
|
const res = await saveBpmForm({
|
||||||
processInstanceId,
|
processInstanceId,
|
||||||
varField: 'json_data',
|
varField: 'json_data',
|
||||||
formData: { ...mainForm },
|
formData: { ...mainForm },
|
||||||
});
|
});
|
||||||
if (res.success) {
|
if (res.success) {
|
||||||
if (processInstanceId && (mainForm.needSdwApproval != null || mainForm.sdwLeaderList)) {
|
if (showMessage) {
|
||||||
const varTasks = [];
|
|
||||||
if (mainForm.needSdwApproval != null) {
|
|
||||||
varTasks.push(
|
|
||||||
setProcessVariable({
|
|
||||||
processInstanceId,
|
|
||||||
taskId: processInfo.value.taskId,
|
|
||||||
local: true,
|
|
||||||
varField: 'needSdwApproval',
|
|
||||||
varVal: String(mainForm.needSdwApproval),
|
|
||||||
})
|
|
||||||
);
|
|
||||||
}
|
|
||||||
if (mainForm.sdwLeaderList) {
|
|
||||||
varTasks.push(
|
|
||||||
setProcessVariable({
|
|
||||||
processInstanceId,
|
|
||||||
taskId: processInfo.value.taskId,
|
|
||||||
local: true,
|
|
||||||
varField: 'sdwLeaderList',
|
|
||||||
varVal: mainForm.sdwLeaderList,
|
|
||||||
})
|
|
||||||
);
|
|
||||||
}
|
|
||||||
if (varTasks.length > 0) {
|
|
||||||
await Promise.all(varTasks);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
createMessage.success(res.message || '保存成功');
|
createMessage.success(res.message || '保存成功');
|
||||||
emit('ok');
|
|
||||||
} else {
|
|
||||||
createMessage.warning(res.message || '保存失败');
|
|
||||||
}
|
}
|
||||||
|
if (emitOk) {
|
||||||
|
emit('ok');
|
||||||
|
}
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
createMessage.warning(res.message || '保存失败');
|
||||||
|
return false;
|
||||||
|
} catch (error) {
|
||||||
|
createMessage.warning('保存失败');
|
||||||
|
return false;
|
||||||
} finally {
|
} finally {
|
||||||
savingMain.value = false;
|
savingMain.value = false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function cancelFeedback() {
|
async function saveMainFormBeforeProcessHandle() {
|
||||||
showFeedbackForm.value = false;
|
if (!mainDisabled.value) {
|
||||||
resetFeedbackForm();
|
const mainSaved = await saveMainForm({ showMessage: false, emitOk: false });
|
||||||
|
if (!mainSaved) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (showSubApproveUser.value) {
|
||||||
|
return saveSubApproveUserVariable({ showSuccessMessage: false });
|
||||||
|
}
|
||||||
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
function resetFeedbackForm() {
|
function openFeedbackModal() {
|
||||||
Object.keys(feedbackForm).forEach((key) => {
|
|
||||||
if (key === 'num' || key === 'measureNum' || key === 'launchType' || key === 'intervalType' || key === 'startCount') {
|
|
||||||
feedbackForm[key] = undefined;
|
|
||||||
} else {
|
|
||||||
feedbackForm[key] = '';
|
|
||||||
}
|
|
||||||
});
|
|
||||||
feedbackForm.mainId = mainForm.id;
|
|
||||||
nextTick(() => feedbackFormRef.value?.clearValidate?.());
|
|
||||||
}
|
|
||||||
|
|
||||||
async function saveFeedback() {
|
|
||||||
if (!mainForm.id) {
|
if (!mainForm.id) {
|
||||||
createMessage.warning('主表数据不存在,无法新增反馈');
|
createMessage.warning('主表数据不存在,无法新增反馈');
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
await feedbackFormRef.value?.validate?.();
|
const processInstanceId = processInfo.value.processInstanceId;
|
||||||
savingFeedback.value = true;
|
if (!processInstanceId) {
|
||||||
try {
|
createMessage.warning('流程实例ID不能为空,无法新增反馈');
|
||||||
feedbackForm.mainId = mainForm.id;
|
return;
|
||||||
const res = await bgXiSpeakFeedbackSaveOrUpdate({ ...feedbackForm }, false);
|
|
||||||
if (res.success) {
|
|
||||||
createMessage.success(res.message || '保存成功');
|
|
||||||
cancelFeedback();
|
|
||||||
await loadFeedbackList();
|
|
||||||
} else {
|
|
||||||
createMessage.warning(res.message || '保存失败');
|
|
||||||
}
|
|
||||||
} finally {
|
|
||||||
savingFeedback.value = false;
|
|
||||||
}
|
}
|
||||||
|
feedbackModalRef.value?.open(mainForm.id, undefined, processInstanceId);
|
||||||
}
|
}
|
||||||
|
|
||||||
async function saveSubApproveUserVariable() {
|
async function saveSubApproveUserVariable(options: { showSuccessMessage?: boolean } = {}) {
|
||||||
|
const { showSuccessMessage = true } = options;
|
||||||
const processInstanceId = processInfo.value.processInstanceId;
|
const processInstanceId = processInfo.value.processInstanceId;
|
||||||
|
const isEndValue = String(isEnd.value);
|
||||||
const usernameValue = normalizeUsernameList(subApproveUser.value);
|
const usernameValue = normalizeUsernameList(subApproveUser.value);
|
||||||
if (!processInstanceId) {
|
if (!processInstanceId) {
|
||||||
createMessage.warning('流程实例ID不能为空');
|
createMessage.warning('流程实例ID不能为空');
|
||||||
return;
|
return false;
|
||||||
}
|
}
|
||||||
if (!usernameValue) {
|
if (isEndValue !== '1' && !usernameValue) {
|
||||||
createMessage.warning('请输入子流程经办人username');
|
createMessage.warning('请选择部门经办人');
|
||||||
return;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
savingSubApproveUser.value = true;
|
savingSubApproveUser.value = true;
|
||||||
try {
|
try {
|
||||||
const res = await setProcessVariable({
|
const isEndResult = await saveProcessVariable('isEnd', isEndValue);
|
||||||
processInstanceId,
|
if (!isEndResult?.success) {
|
||||||
taskId: processInfo.value.taskId,
|
createMessage.warning(isEndResult.message || '保存失败');
|
||||||
local: true,
|
return false;
|
||||||
varField: 'subApproveUser',
|
|
||||||
varVal: usernameValue,
|
|
||||||
});
|
|
||||||
if (res.success) {
|
|
||||||
createMessage.success(res.message || '保存成功');
|
|
||||||
} else {
|
|
||||||
createMessage.warning(res.message || '保存失败');
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (isEndValue !== '1') {
|
||||||
|
const subApproveUserResult = await saveProcessVariable('subApproveUser', usernameValue);
|
||||||
|
if (!subApproveUserResult?.success) {
|
||||||
|
createMessage.warning(subApproveUserResult.message || '保存失败');
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (showSuccessMessage) {
|
||||||
|
createMessage.success('保存成功');
|
||||||
|
}
|
||||||
|
return true;
|
||||||
|
} catch (error) {
|
||||||
|
createMessage.warning('保存失败');
|
||||||
|
return false;
|
||||||
} finally {
|
} finally {
|
||||||
savingSubApproveUser.value = false;
|
savingSubApproveUser.value = false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function saveProcessVariable(varField: string, varVal: any) {
|
||||||
|
return setProcessVariable({
|
||||||
|
processInstanceId: processInfo.value.processInstanceId,
|
||||||
|
taskId: processInfo.value.taskId,
|
||||||
|
local: true,
|
||||||
|
varField,
|
||||||
|
varVal,
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
function normalizeUsernameList(value: string) {
|
function normalizeUsernameList(value: string) {
|
||||||
return String(value || '')
|
return String(value || '')
|
||||||
.split(',')
|
.split(',')
|
||||||
@@ -630,39 +481,193 @@
|
|||||||
|
|
||||||
<style lang="less" scoped>
|
<style lang="less" scoped>
|
||||||
.bg-xispeak-bpm-form {
|
.bg-xispeak-bpm-form {
|
||||||
padding: 12px 16px 20px;
|
padding: 8px 12px 14px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.main-form,
|
.main-form {
|
||||||
.feedback-form {
|
|
||||||
background: #fff;
|
background: #fff;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.main-form,
|
||||||
|
.process-variable-form {
|
||||||
|
:deep(.ant-form-item-label) {
|
||||||
|
text-align: left;
|
||||||
|
}
|
||||||
|
|
||||||
|
:deep(.ant-form-item-label > label) {
|
||||||
|
justify-content: flex-start;
|
||||||
|
color: #1f2937;
|
||||||
|
font-weight: 500;
|
||||||
|
}
|
||||||
|
|
||||||
|
:deep(.ant-form-item-control),
|
||||||
|
:deep(.ant-form-item-control-input),
|
||||||
|
:deep(.ant-form-item-control-input-content) {
|
||||||
|
text-align: left;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
.section-title {
|
.section-title {
|
||||||
margin-bottom: 12px;
|
margin-bottom: 8px;
|
||||||
padding-left: 8px;
|
padding-left: 8px;
|
||||||
border-left: 3px solid #1677ff;
|
border-left: 3px solid #1677ff;
|
||||||
color: #1f2937;
|
color: #1f2937;
|
||||||
font-size: 15px;
|
font-size: 14px;
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
line-height: 18px;
|
line-height: 16px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.feedback-header {
|
.section-toolbar {
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
margin-bottom: 12px;
|
margin-bottom: 8px;
|
||||||
|
padding: 6px 10px;
|
||||||
|
background: #f6fbff;
|
||||||
|
border: 1px solid #d6e8ff;
|
||||||
|
border-radius: 6px;
|
||||||
|
|
||||||
|
.section-title {
|
||||||
|
margin-bottom: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
.feedback-form {
|
.section-actions {
|
||||||
margin-top: 16px;
|
display: inline-flex;
|
||||||
padding-top: 16px;
|
align-items: center;
|
||||||
border-top: 1px solid #f0f0f0;
|
gap: 4px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.section-action-button {
|
||||||
|
display: inline-flex;
|
||||||
|
align-items: center;
|
||||||
|
gap: 4px;
|
||||||
|
min-width: 58px;
|
||||||
|
justify-content: center;
|
||||||
|
font-weight: 500;
|
||||||
|
box-shadow: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.base-save-button {
|
||||||
|
display: inline-flex;
|
||||||
|
align-items: center;
|
||||||
|
gap: 4px;
|
||||||
|
height: 24px;
|
||||||
|
padding: 0 6px;
|
||||||
|
color: #64748b;
|
||||||
|
font-weight: 400;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.base-info-header {
|
||||||
|
margin-top: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.base-info-row {
|
||||||
|
padding: 0 10px;
|
||||||
|
|
||||||
|
:deep(.ant-form-item) {
|
||||||
|
margin-bottom: 6px;
|
||||||
|
}
|
||||||
|
|
||||||
|
:deep(.ant-form-item-label) {
|
||||||
|
padding-bottom: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
:deep(.ant-form-item-label > label) {
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
|
:deep(.ant-input),
|
||||||
|
:deep(.ant-picker),
|
||||||
|
:deep(.ant-select-selector) {
|
||||||
|
min-height: 30px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.main-form-readonly {
|
||||||
|
:deep(.ant-input[disabled]),
|
||||||
|
:deep(.ant-input-disabled),
|
||||||
|
:deep(.ant-input-affix-wrapper-disabled),
|
||||||
|
:deep(.ant-input-affix-wrapper-disabled.ant-input-outlined),
|
||||||
|
:deep(.ant-input-affix-wrapper-disabled:hover),
|
||||||
|
:deep(.ant-input-affix-wrapper-disabled:focus),
|
||||||
|
:deep(.ant-input-affix-wrapper-disabled-focused),
|
||||||
|
:deep(.ant-input-outlined[disabled]),
|
||||||
|
:deep(.ant-input-outlined.ant-input-disabled),
|
||||||
|
:deep(textarea.ant-input[disabled]),
|
||||||
|
:deep(.ant-picker-disabled),
|
||||||
|
:deep(.ant-select-disabled .ant-select-selector) {
|
||||||
|
background: transparent !important;
|
||||||
|
border-color: transparent !important;
|
||||||
|
color: #1f2937 !important;
|
||||||
|
box-shadow: none !important;
|
||||||
|
cursor: default !important;
|
||||||
|
opacity: 1 !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
:deep(.ant-input[disabled]),
|
||||||
|
:deep(.ant-input-disabled),
|
||||||
|
:deep(.ant-input-affix-wrapper-disabled),
|
||||||
|
:deep(textarea.ant-input[disabled]) {
|
||||||
|
padding-left: 0 !important;
|
||||||
|
padding-right: 0 !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
:deep(.ant-input-affix-wrapper-disabled .ant-input) {
|
||||||
|
background: transparent !important;
|
||||||
|
color: #1f2937 !important;
|
||||||
|
cursor: default !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
:deep(.ant-input[disabled]::placeholder),
|
||||||
|
:deep(.ant-input-disabled::placeholder),
|
||||||
|
:deep(.ant-input-affix-wrapper-disabled .ant-input::placeholder) {
|
||||||
|
color: #9ca3af !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
:deep(.ant-picker-disabled input),
|
||||||
|
:deep(.ant-select-disabled .ant-select-selection-item),
|
||||||
|
:deep(.ant-select-disabled .ant-select-selection-item span),
|
||||||
|
:deep(.ant-select-disabled .ant-select-selection-placeholder),
|
||||||
|
:deep(.ant-select-disabled .ant-select-selection-placeholder span) {
|
||||||
|
color: #1f2937 !important;
|
||||||
|
-webkit-text-fill-color: #1f2937 !important;
|
||||||
|
cursor: default !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
:deep(.ant-picker-disabled),
|
||||||
|
:deep(.ant-select-disabled .ant-select-selector) {
|
||||||
|
padding-left: 0 !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
:deep(.ant-select-disabled),
|
||||||
|
:deep(.ant-select-disabled *),
|
||||||
|
:deep(.ant-select-disabled.ant-select-outlined),
|
||||||
|
:deep(.ant-select-disabled.ant-select-outlined .ant-select-selector) {
|
||||||
|
color: #1f2937 !important;
|
||||||
|
-webkit-text-fill-color: #1f2937 !important;
|
||||||
|
opacity: 1 !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
:deep(.ant-select-disabled .ant-select-arrow),
|
||||||
|
:deep(.ant-picker-disabled .ant-picker-suffix),
|
||||||
|
:deep(.ant-input-disabled .ant-input-clear-icon),
|
||||||
|
:deep(.ant-input-affix-wrapper-disabled .ant-input-clear-icon),
|
||||||
|
:deep(.ant-select-disabled .ant-select-clear) {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.feedback-header {
|
||||||
|
margin-bottom: 8px;
|
||||||
|
|
||||||
|
.feedback-add-button {
|
||||||
|
min-width: 104px;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.process-variable-form {
|
.process-variable-form {
|
||||||
margin-bottom: 12px;
|
margin-bottom: 8px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.sub-approve-user-row {
|
.sub-approve-user-row {
|
||||||
@@ -675,10 +680,30 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.main-actions {
|
:deep(.ant-divider-horizontal) {
|
||||||
display: flex;
|
margin: 10px 0;
|
||||||
justify-content: center;
|
}
|
||||||
gap: 12px;
|
|
||||||
margin-top: 8px;
|
.feedback-attachment-list {
|
||||||
|
min-width: 300px;
|
||||||
|
|
||||||
|
:deep(.file-list-wrapper) {
|
||||||
|
min-height: auto;
|
||||||
|
padding: 8px;
|
||||||
|
}
|
||||||
|
|
||||||
|
:deep(.file-list-header) {
|
||||||
|
margin-bottom: 6px;
|
||||||
|
padding-bottom: 6px;
|
||||||
|
}
|
||||||
|
|
||||||
|
:deep(.file-list .file-item) {
|
||||||
|
padding: 8px;
|
||||||
|
margin-bottom: 6px;
|
||||||
|
}
|
||||||
|
|
||||||
|
:deep(.ant-empty) {
|
||||||
|
margin: 0;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
@@ -3,118 +3,115 @@
|
|||||||
<JFormContainer :disabled="disabled">
|
<JFormContainer :disabled="disabled">
|
||||||
<template #detail>
|
<template #detail>
|
||||||
<a-form ref="formRef" class="antd-modal-form" :labelCol="labelCol" :wrapperCol="wrapperCol" name="BgXiSpeakForm">
|
<a-form ref="formRef" class="antd-modal-form" :labelCol="labelCol" :wrapperCol="wrapperCol" name="BgXiSpeakForm">
|
||||||
<a-row :gutter="20">
|
<a-row>
|
||||||
<a-col :span="24">
|
<a-col :span="12">
|
||||||
<a-form-item label="习近平总书记重要讲话指示批示情况" v-bind="validateInfos.speakStatus">
|
<a-form-item label="重要讲话指示批示" v-bind="validateInfos.speakStatus" id="BgXiSpeakForm-speakStatus" name="speakStatus">
|
||||||
<a-input v-model:value="formData.speakStatus" placeholder="请输入重要指示批示情况" allow-clear></a-input>
|
<a-textarea v-model:value="formData.speakStatus" :rows="4" placeholder="请输入重要指示批示情况" allow-clear />
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
</a-col>
|
</a-col>
|
||||||
<a-col :span="24">
|
<a-col :span="12">
|
||||||
<a-form-item label="时间" v-bind="validateInfos.time">
|
<a-form-item label="时间" v-bind="validateInfos.time" id="BgXiSpeakForm-time" name="time">
|
||||||
<a-date-picker placeholder="请选择时间" v-model:value="formData.time" value-format="YYYY-MM-DD" style="width: 100%" allow-clear />
|
<a-date-picker placeholder="请选择时间" v-model:value="formData.time" value-format="YYYY-MM-DD" style="width: 100%" allow-clear />
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
</a-col>
|
</a-col>
|
||||||
<a-col :span="24">
|
<a-col :span="12">
|
||||||
<a-form-item label="责任人" v-bind="validateInfos.responsiblePerson">
|
<a-form-item label="责任人" v-bind="validateInfos.responsiblePerson" id="BgXiSpeakForm-responsiblePerson" name="responsiblePerson">
|
||||||
<j-select-user v-model:value="formData.responsiblePerson" allow-clear />
|
<j-select-user v-model:value="formData.responsiblePerson" allow-clear />
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
</a-col>
|
</a-col>
|
||||||
<a-col :span="24">
|
<a-col :span="12">
|
||||||
<a-form-item label="是否需要督办领导" v-bind="validateInfos.needSdwApproval">
|
<a-form-item label="企业负责同志批示情况" v-bind="validateInfos.elmComment" id="BgXiSpeakForm-elmComment" name="elmComment">
|
||||||
<a-radio-group v-model:value="formData.needSdwApproval" class="radio-group">
|
<a-input v-model:value="formData.elmComment" placeholder="请输入" allow-clear></a-input>
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
<a-col :span="12">
|
||||||
|
<a-form-item label="学习传达研究部署情况" v-bind="validateInfos.status" id="BgXiSpeakForm-status" name="status">
|
||||||
|
<a-input v-model:value="formData.status" placeholder="请输入" allow-clear></a-input>
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
<a-col :span="12">
|
||||||
|
<a-form-item label="是否需要督办领导" v-bind="validateInfos.needSdwApproval" id="BgXiSpeakForm-needSdwApproval" name="needSdwApproval">
|
||||||
|
<a-radio-group v-model:value="formData.needSdwApproval">
|
||||||
<a-radio :value="1">是</a-radio>
|
<a-radio :value="1">是</a-radio>
|
||||||
<a-radio :value="0">否</a-radio>
|
<a-radio :value="0">否</a-radio>
|
||||||
</a-radio-group>
|
</a-radio-group>
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
</a-col>
|
</a-col>
|
||||||
<a-col :span="24" v-if="formData.needSdwApproval === 1">
|
<a-col v-if="formData.needSdwApproval === 1" :span="12">
|
||||||
<a-form-item label="督导领导列表" v-bind="validateInfos.sdwLeaderList">
|
<a-form-item label="督导领导列表" v-bind="validateInfos.sdwLeaderList" id="BgXiSpeakForm-sdwLeaderList" name="sdwLeaderList">
|
||||||
<j-select-user v-model:value="formData.sdwLeaderList" :multiple="true" allow-clear placeholder="请选择督导领导" />
|
<j-select-user v-model:value="formData.sdwLeaderList" :multiple="true" allow-clear placeholder="请选择督导领导" />
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
</a-col>
|
</a-col>
|
||||||
<a-col :span="24">
|
<a-col :span="12">
|
||||||
<a-form-item label="企业负责同志批示情况" v-bind="validateInfos.elmComment">
|
<a-form-item label="牵头部门" v-bind="validateInfos.leadDepartment" id="BgXiSpeakForm-leadDepartment" name="leadDepartment">
|
||||||
<a-input v-model:value="formData.elmComment" placeholder="请输入" allow-clear></a-input>
|
|
||||||
</a-form-item>
|
|
||||||
</a-col>
|
|
||||||
<a-col :span="24">
|
|
||||||
<a-form-item label="学习传达研究部署情况" v-bind="validateInfos.status">
|
|
||||||
<a-input v-model:value="formData.status" placeholder="请输入" allow-clear></a-input>
|
|
||||||
</a-form-item>
|
|
||||||
</a-col>
|
|
||||||
<a-col :span="24">
|
|
||||||
<a-form-item label="牵头部门" v-bind="validateInfos.leadDepartment">
|
|
||||||
<j-select-dept v-model:value="formData.leadDepartment" :multiple="true" checkStrictly allow-clear />
|
<j-select-dept v-model:value="formData.leadDepartment" :multiple="true" checkStrictly allow-clear />
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
</a-col>
|
</a-col>
|
||||||
<a-col :span="24">
|
<a-col :span="12">
|
||||||
<a-form-item label="落实部门" v-bind="validateInfos.implDept">
|
<a-form-item label="落实部门" v-bind="validateInfos.implDept" id="BgXiSpeakForm-implDept" name="implDept">
|
||||||
<j-select-dept v-model:value="formData.implDept" :multiple="true" checkStrictly allow-clear />
|
<j-select-dept v-model:value="formData.implDept" :multiple="true" checkStrictly allow-clear />
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
</a-col>
|
</a-col>
|
||||||
<a-col :span="24">
|
<a-col :span="12">
|
||||||
<a-form-item label="落实方案" v-bind="validateInfos.implPlan">
|
<a-form-item label="落实方案" v-bind="validateInfos.implPlan" id="BgXiSpeakForm-implPlan" name="implPlan">
|
||||||
<a-input v-model:value="formData.implPlan" placeholder="请输入" allow-clear></a-input>
|
<a-input v-model:value="formData.implPlan" placeholder="请输入" allow-clear></a-input>
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
</a-col>
|
</a-col>
|
||||||
<a-col :span="24">
|
<a-col :span="12">
|
||||||
<a-form-item label="贯彻落实措施" v-bind="validateInfos.implMeasures">
|
<a-form-item label="贯彻落实措施" v-bind="validateInfos.implMeasures" id="BgXiSpeakForm-implMeasures" name="implMeasures">
|
||||||
<a-input v-model:value="formData.implMeasures" placeholder="请输入" allow-clear></a-input>
|
<a-input v-model:value="formData.implMeasures" placeholder="请输入" allow-clear></a-input>
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
</a-col>
|
</a-col>
|
||||||
<a-col :span="24">
|
<a-col :span="12">
|
||||||
<a-form-item label="会议决策数" v-bind="validateInfos.numberOfResolutions">
|
<a-form-item label="会议决策数" v-bind="validateInfos.numberOfResolutions" id="BgXiSpeakForm-numberOfResolutions" name="numberOfResolutions">
|
||||||
<a-input-number v-model:value="formData.numberOfResolutions" placeholder="请输入" style="width: 100%" />
|
<a-input-number v-model:value="formData.numberOfResolutions" placeholder="请输入" style="width: 100%" />
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
</a-col>
|
</a-col>
|
||||||
<a-col :span="24">
|
<a-col :span="12">
|
||||||
<a-form-item label="落实条数" v-bind="validateInfos.implCount">
|
<a-form-item label="落实条数" v-bind="validateInfos.implCount" id="BgXiSpeakForm-implCount" name="implCount">
|
||||||
<a-input-number v-model:value="formData.implCount" placeholder="请输入" style="width: 100%" />
|
<a-input-number v-model:value="formData.implCount" placeholder="请输入" style="width: 100%" />
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
</a-col>
|
</a-col>
|
||||||
<a-col :span="24">
|
<a-col :span="12">
|
||||||
<a-form-item label="已闭环数量" v-bind="validateInfos.closedCount">
|
<a-form-item label="已闭环数量" v-bind="validateInfos.closedCount" id="BgXiSpeakForm-closedCount" name="closedCount">
|
||||||
<a-input-number v-model:value="formData.closedCount" placeholder="请输入" style="width: 100%" />
|
<a-input-number v-model:value="formData.closedCount" placeholder="请输入" style="width: 100%" />
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
</a-col>
|
</a-col>
|
||||||
<a-col :span="24">
|
<a-col :span="12">
|
||||||
<a-form-item label="落实情况" v-bind="validateInfos.implStatus">
|
<a-form-item label="落实情况" v-bind="validateInfos.implStatus" id="BgXiSpeakForm-implStatus" name="implStatus">
|
||||||
<a-input v-model:value="formData.implStatus" placeholder="请输入" allow-clear></a-input>
|
<a-textarea v-model:value="formData.implStatus" :rows="4" placeholder="请输入" allow-clear />
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
</a-col>
|
</a-col>
|
||||||
<a-col :span="24">
|
<a-col :span="12">
|
||||||
<a-form-item label="报告反馈情况" v-bind="validateInfos.reportFeedbackStatus">
|
<a-form-item label="报告反馈情况" v-bind="validateInfos.reportFeedbackStatus" id="BgXiSpeakForm-reportFeedbackStatus" name="reportFeedbackStatus">
|
||||||
<a-input v-model:value="formData.reportFeedbackStatus" placeholder="请输入" allow-clear></a-input>
|
<a-input v-model:value="formData.reportFeedbackStatus" placeholder="请输入" allow-clear></a-input>
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
</a-col>
|
</a-col>
|
||||||
<a-col :span="24">
|
<a-col :span="12">
|
||||||
<a-form-item label="是否存在完成风险">
|
<a-form-item label="是否存在完成风险" id="BgXiSpeakForm-isCompletionRisk" name="isCompletionRisk">
|
||||||
<a-radio-group v-model:value="formData.isCompletionRisk" class="radio-group">
|
<a-radio-group v-model:value="formData.isCompletionRisk">
|
||||||
<a-radio :value="0">不存在</a-radio>
|
<a-radio :value="0">不存在</a-radio>
|
||||||
<a-radio :value="1">存在</a-radio>
|
<a-radio :value="1">存在</a-radio>
|
||||||
</a-radio-group>
|
</a-radio-group>
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
</a-col>
|
</a-col>
|
||||||
<a-col :span="24">
|
<a-col :span="12">
|
||||||
<a-form-item label="完成状态">
|
<a-form-item label="完成状态" id="BgXiSpeakForm-completionStatus" name="completionStatus">
|
||||||
<a-radio-group v-model:value="formData.completionStatus" class="radio-group">
|
<JDictSelectTag v-model:value="formData.completionStatus" dictCode="db_status" placeholder="请选择完成状态" type="radio" />
|
||||||
<a-radio :value="0">推进中</a-radio>
|
|
||||||
<a-radio :value="1">已完成</a-radio>
|
|
||||||
</a-radio-group>
|
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
</a-col>
|
</a-col>
|
||||||
<a-col :span="24">
|
<a-col :span="12">
|
||||||
<a-form-item label="拖期风险应对措施" v-bind="validateInfos.delayRiskMitigation">
|
<a-form-item label="拖期风险应对措施" v-bind="validateInfos.delayRiskMitigation" id="BgXiSpeakForm-delayRiskMitigation" name="delayRiskMitigation">
|
||||||
<a-input v-model:value="formData.delayRiskMitigation" placeholder="请输入" allow-clear></a-input>
|
<a-input v-model:value="formData.delayRiskMitigation" placeholder="请输入" allow-clear></a-input>
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
</a-col>
|
</a-col>
|
||||||
<a-col :span="24">
|
<a-col :span="12">
|
||||||
<a-form-item label="督办次数" v-bind="validateInfos.supervisionCount">
|
<a-form-item label="督办次数" v-bind="validateInfos.supervisionCount" id="BgXiSpeakForm-supervisionCount" name="supervisionCount">
|
||||||
<a-input-number v-model:value="formData.supervisionCount" placeholder="请输入" style="width: 100%" />
|
<a-input-number v-model:value="formData.supervisionCount" placeholder="请输入" style="width: 100%" />
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
</a-col>
|
</a-col>
|
||||||
<a-col :span="24">
|
<a-col :span="12">
|
||||||
<a-form-item label="父级节点" v-bind="validateInfos.pid">
|
<a-form-item label="父级节点" v-bind="validateInfos.pid" id="BgXiSpeakForm-pid" name="pid">
|
||||||
<j-tree-select
|
<j-tree-select
|
||||||
v-model:value="formData.pid"
|
v-model:value="formData.pid"
|
||||||
dict="bg_xi_speak,impl_status,id"
|
dict="bg_xi_speak,impl_status,id"
|
||||||
@@ -125,8 +122,8 @@
|
|||||||
/>
|
/>
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
</a-col>
|
</a-col>
|
||||||
<a-col v-if="showFlowSubmitButton" :span="24" class="submit-area">
|
<a-col v-if="showFlowSubmitButton" :span="24" style="width: 100%; text-align: center">
|
||||||
<a-button preIcon="ant-design:check-outlined" style="width: 140px; height: 40px" type="primary" @click="submitForm">提 交</a-button>
|
<a-button preIcon="ant-design:check-outlined" style="width: 126px" type="primary" @click="submitForm">提 交</a-button>
|
||||||
</a-col>
|
</a-col>
|
||||||
</a-row>
|
</a-row>
|
||||||
</a-form>
|
</a-form>
|
||||||
@@ -142,6 +139,7 @@
|
|||||||
import JSelectDept from '/@/components/Form/src/jeecg/components/JSelectDept.vue';
|
import JSelectDept from '/@/components/Form/src/jeecg/components/JSelectDept.vue';
|
||||||
import JSelectUser from '/@/components/Form/src/jeecg/components/JSelectUser.vue';
|
import JSelectUser from '/@/components/Form/src/jeecg/components/JSelectUser.vue';
|
||||||
import JTreeSelect from '/@/components/Form/src/jeecg/components/JTreeSelect.vue';
|
import JTreeSelect from '/@/components/Form/src/jeecg/components/JTreeSelect.vue';
|
||||||
|
import JDictSelectTag from '/@/components/Form/src/jeecg/components/JDictSelectTag.vue';
|
||||||
import { getValueType } from '/@/utils';
|
import { getValueType } from '/@/utils';
|
||||||
import { loadTreeData, saveOrUpdateDict } from '../BgXiSpeak.api';
|
import { loadTreeData, saveOrUpdateDict } from '../BgXiSpeak.api';
|
||||||
import { Form } from 'ant-design-vue';
|
import { Form } from 'ant-design-vue';
|
||||||
@@ -156,7 +154,6 @@
|
|||||||
const emit = defineEmits(['register', 'ok']);
|
const emit = defineEmits(['register', 'ok']);
|
||||||
let model: Nullable<Recordable> = null;
|
let model: Nullable<Recordable> = null;
|
||||||
|
|
||||||
// 1. 初始化值修改:needSdwApproval 默认为 0
|
|
||||||
const formData = reactive<Record<string, any>>({
|
const formData = reactive<Record<string, any>>({
|
||||||
id: '',
|
id: '',
|
||||||
pid: '',
|
pid: '',
|
||||||
@@ -187,11 +184,10 @@
|
|||||||
});
|
});
|
||||||
|
|
||||||
const { createMessage } = useMessage();
|
const { createMessage } = useMessage();
|
||||||
const labelCol = ref<any>({ xs: { span: 24 }, sm: { span: 6 } });
|
const labelCol = ref<any>({ xs: { span: 24 }, sm: { span: 5 } });
|
||||||
const wrapperCol = ref<any>({ xs: { span: 24 }, sm: { span: 18 } });
|
const wrapperCol = ref<any>({ xs: { span: 24 }, sm: { span: 16 } });
|
||||||
const confirmLoading = ref<boolean>(false);
|
const confirmLoading = ref<boolean>(false);
|
||||||
|
|
||||||
// 2. 表单验证:明确 needSdwApproval 的验证
|
|
||||||
const validatorRules = reactive({
|
const validatorRules = reactive({
|
||||||
needSdwApproval: [{ required: true, message: '请选择是否需要督办领导' }],
|
needSdwApproval: [{ required: true, message: '请选择是否需要督办领导' }],
|
||||||
speakStatus: [{ required: true, message: '请输入指示批示情况' }],
|
speakStatus: [{ required: true, message: '请输入指示批示情况' }],
|
||||||
@@ -244,7 +240,6 @@
|
|||||||
|
|
||||||
const tmpData = {};
|
const tmpData = {};
|
||||||
Object.keys(formData).forEach((key) => {
|
Object.keys(formData).forEach((key) => {
|
||||||
// 3. 赋值增强:处理后端返回 null 的情况
|
|
||||||
if (record.hasOwnProperty(key)) {
|
if (record.hasOwnProperty(key)) {
|
||||||
tmpData[key] = record[key] === null ? (key === 'needSdwApproval' ? 0 : '') : record[key];
|
tmpData[key] = record[key] === null ? (key === 'needSdwApproval' ? 0 : '') : record[key];
|
||||||
}
|
}
|
||||||
@@ -278,7 +273,6 @@
|
|||||||
return Promise.reject(errorFields);
|
return Promise.reject(errorFields);
|
||||||
}
|
}
|
||||||
|
|
||||||
// 4. 提交兜底:确保数值有效
|
|
||||||
if (formData.needSdwApproval === undefined || formData.needSdwApproval === null) {
|
if (formData.needSdwApproval === undefined || formData.needSdwApproval === null) {
|
||||||
formData.needSdwApproval = 0;
|
formData.needSdwApproval = 0;
|
||||||
}
|
}
|
||||||
@@ -286,7 +280,6 @@
|
|||||||
confirmLoading.value = true;
|
confirmLoading.value = true;
|
||||||
const isUpdate = !!formData.id;
|
const isUpdate = !!formData.id;
|
||||||
|
|
||||||
// 拷贝一份数据进行转换,避免污染原始响应式对象
|
|
||||||
const params = { ...formData };
|
const params = { ...formData };
|
||||||
|
|
||||||
for (let key in params) {
|
for (let key in params) {
|
||||||
@@ -323,43 +316,7 @@
|
|||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style lang="less" scoped>
|
<style lang="less" scoped>
|
||||||
/* 保持原有样式不变 */
|
|
||||||
.antd-modal-form {
|
.antd-modal-form {
|
||||||
padding: 20px;
|
padding: 14px;
|
||||||
.submit-area {
|
|
||||||
text-align: center;
|
|
||||||
padding-top: 16px;
|
|
||||||
margin-top: 8px;
|
|
||||||
border-top: 1px dashed #e8e8e8;
|
|
||||||
}
|
|
||||||
:deep(.ant-form-item-label > label) {
|
|
||||||
font-weight: 500;
|
|
||||||
color: #333;
|
|
||||||
}
|
|
||||||
:deep(.ant-radio-group.radio-group .ant-radio-wrapper) {
|
|
||||||
margin-right: 16px;
|
|
||||||
font-size: 14px;
|
|
||||||
}
|
|
||||||
:deep(.ant-input),
|
|
||||||
:deep(.ant-input-number),
|
|
||||||
:deep(.ant-select),
|
|
||||||
:deep(.ant-picker) {
|
|
||||||
border-radius: 6px;
|
|
||||||
transition: all 0.3s ease;
|
|
||||||
&:hover {
|
|
||||||
border-color: #40a9ff;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
:deep(.ant-btn-primary) {
|
|
||||||
height: 40px;
|
|
||||||
padding: 0 32px;
|
|
||||||
border-radius: 6px;
|
|
||||||
background: linear-gradient(135deg, #1890ff 0%, #096dd9 100%);
|
|
||||||
border: none;
|
|
||||||
font-size: 15px;
|
|
||||||
&:hover {
|
|
||||||
background: linear-gradient(135deg, #40a9ff 0%, #1890ff 100%);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|||||||
@@ -0,0 +1,55 @@
|
|||||||
|
<template>
|
||||||
|
<JModal
|
||||||
|
title="发起督办计划收集流程"
|
||||||
|
:width="480"
|
||||||
|
:visible="visible"
|
||||||
|
:confirmLoading="confirming"
|
||||||
|
okText="确认"
|
||||||
|
cancelText="取消"
|
||||||
|
@ok="handleOk"
|
||||||
|
@cancel="handleCancel"
|
||||||
|
>
|
||||||
|
<a-form :label-col="{ style: { width: '100%' } }">
|
||||||
|
<a-form-item>
|
||||||
|
<a-radio-group v-model:value="feedbackRightNow">
|
||||||
|
<a-space direction="vertical">
|
||||||
|
<a-radio :value="1">督办计划收集流程结束后需要立即反馈</a-radio>
|
||||||
|
<a-radio :value="0">无需立即反馈</a-radio>
|
||||||
|
</a-space>
|
||||||
|
</a-radio-group>
|
||||||
|
</a-form-item>
|
||||||
|
</a-form>
|
||||||
|
</JModal>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script lang="ts" setup>
|
||||||
|
import { ref } from 'vue';
|
||||||
|
import JModal from '/@/components/Modal/src/JModal/JModal.vue';
|
||||||
|
|
||||||
|
const emit = defineEmits(['confirm']);
|
||||||
|
|
||||||
|
const visible = ref(false);
|
||||||
|
const confirming = ref(false);
|
||||||
|
const feedbackRightNow = ref(0);
|
||||||
|
const contextRecord = ref<any>(null);
|
||||||
|
|
||||||
|
function open(record: any) {
|
||||||
|
feedbackRightNow.value = 0;
|
||||||
|
contextRecord.value = record;
|
||||||
|
visible.value = true;
|
||||||
|
}
|
||||||
|
|
||||||
|
function handleCancel() {
|
||||||
|
visible.value = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
function handleOk() {
|
||||||
|
emit('confirm', {
|
||||||
|
record: contextRecord.value,
|
||||||
|
feedbackRightNow: feedbackRightNow.value,
|
||||||
|
});
|
||||||
|
visible.value = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
defineExpose({ open });
|
||||||
|
</script>
|
||||||
Reference in New Issue
Block a user