修改bpm审批表单,使用jeecg提供的方式控制字段是否可见可编辑
This commit is contained in:
@@ -4,12 +4,12 @@
|
||||
<a-form class="main-form" :labelCol="labelCol" :wrapperCol="wrapperCol" :model="mainForm">
|
||||
<div class="section-title">基础信息</div>
|
||||
<a-row :gutter="16">
|
||||
<a-col :span="24">
|
||||
<a-col :span="24" v-if="hasPermission('xizhishi')">
|
||||
<a-form-item label="习近平总书记重要讲话指示批示情况" name="speakStatus" :labelCol="wideLabelCol" :wrapperCol="wideWrapperCol">
|
||||
<a-input v-model:value="mainForm.speakStatus" :disabled="mainDisabled" allow-clear />
|
||||
<a-input v-model:value="mainForm.speakStatus" :disabled="isDisabledAuth('xizhishi')" allow-clear />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<a-col :span="12" v-if="hasPermission('xitime')">
|
||||
<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-form-item>
|
||||
@@ -89,6 +89,11 @@
|
||||
<a-input-number v-model:value="mainForm.supervisionCount" :disabled="mainDisabled" style="width: 100%" />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<a-form-item label="父级节点" name="pid">
|
||||
<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-col>
|
||||
</a-row>
|
||||
<div v-if="!mainDisabled" class="main-actions">
|
||||
<a-button type="primary" :loading="savingMain" @click="submitForm">保存主表数据</a-button>
|
||||
@@ -99,9 +104,7 @@
|
||||
|
||||
<div class="feedback-header">
|
||||
<div class="section-title">反馈信息</div>
|
||||
<a-button v-if="!mainDisabled && hasPermission('test:BgXiSpeakBPM:name')" type="primary" @click="showFeedbackForm = true"
|
||||
>新增反馈</a-button
|
||||
>
|
||||
<a-button v-if="hasPermission('xifankui')" type="primary" @click="showFeedbackForm = true">新增反馈</a-button>
|
||||
</div>
|
||||
<a-table rowKey="id" size="small" bordered :columns="feedbackColumns" :data-source="feedbackList" :pagination="false" :scroll="{ x: 900 }" />
|
||||
|
||||
@@ -185,12 +188,11 @@
|
||||
import { useMessage } from '/@/hooks/web/useMessage';
|
||||
import JSelectDept from '/@/components/Form/src/jeecg/components/JSelectDept.vue';
|
||||
import JSelectUser from '/@/components/Form/src/jeecg/components/JSelectUser.vue';
|
||||
import JTreeSelect from '/@/components/Form/src/jeecg/components/JTreeSelect.vue';
|
||||
import { bgXiSpeakFeedbackList, bgXiSpeakFeedbackSaveOrUpdate, saveBpmForm, setProcessVariable } from '../BgXiSpeak.api';
|
||||
import { usePermission } from '/@/hooks/web/usePermission';
|
||||
import TaskHandleInnerContent from '/@/views/super/bpm/process/personalOffice/myHandleTask/content/TaskHandleInnerContent.vue';
|
||||
const { isDisabledAuth, hasPermission, initBpmFormData } = usePermission();
|
||||
|
||||
import { usePermission } from '/@/hooks/web/usePermission';
|
||||
const { isDisabledAuth, hasPermission, initBpmFormData } = usePermission();
|
||||
|
||||
const props = defineProps({
|
||||
@@ -330,14 +332,12 @@
|
||||
savingMain.value = true;
|
||||
try {
|
||||
const processInstanceId = processInfo.value.processInstanceId;
|
||||
console.log('BgXiSpeak BPM process info', { ...processInfo.value, processInstanceId });
|
||||
const res = await saveBpmForm({
|
||||
processInstanceId,
|
||||
varField: 'json_data',
|
||||
formData: { ...mainForm },
|
||||
});
|
||||
if (res.success) {
|
||||
// 保存 BPM 变量:needSdwApproval 和 sdwLeaderList
|
||||
if (processInstanceId && (mainForm.needSdwApproval != null || mainForm.sdwLeaderList)) {
|
||||
const varTasks = [];
|
||||
if (mainForm.needSdwApproval != null) {
|
||||
@@ -518,4 +518,4 @@
|
||||
gap: 12px;
|
||||
margin-top: 8px;
|
||||
}
|
||||
</style>
|
||||
</style>
|
||||
Reference in New Issue
Block a user