Merge remote-tracking branch 'origin/master'

# Conflicts:
#	src/api/project-demand/index.js
#	src/views/projectdemand/demandcollection/add.vue
This commit is contained in:
2024-05-12 21:56:33 +08:00
3 changed files with 59 additions and 31 deletions

View File

@@ -19,6 +19,12 @@ export const getInfo = (requirementId) => {
method: "get"
});
};
export const getFormInfo = (requirementId) => {
return request({
url: `/workflow/mosr/requirement/form/${requirementId}`,
method: "get"
});
};
export const agreeTask = (data) => {
return request({
url: `/workflow/mosr/process/task/agree`,
@@ -41,6 +47,13 @@ export const addRequirement = (data) => {
data: data
});
};
export const resubmit = (data) => {
return request({
url: '/workflow/mosr/requirement/resubmit',
method: "post",
data: data
});
};
export const resubmitRequirement = (data) => {
return request({
url: '/workflow/mosr/requirement/resubmit',

View File

@@ -65,6 +65,7 @@
</div>
<div class="oper-page-btn">
<el-button color="#DED0B2" @click="handleSubmit">提交</el-button>
<el-button color="#DED0B2" @click="handleResubmit">重新提交</el-button>
<el-button @click="handleBack">返回</el-button>
</div>
</div>
@@ -73,7 +74,7 @@
<script setup lang="jsx">
import {useAuthStore} from '@/stores/userstore.js'
import {useProcessStore} from '@/stores/processStore.js';
import {getWorkflowInfo, addRequirement, getInfo} from "@/api/project-demand/index.js";
import {getWorkflowInfo, addRequirement, getFormInfo,resubmit} from "@/api/project-demand/index.js";
import FileUpload from "@/components/FileUpload.vue";
import ProcessDiagramViewer from '@/views/workflow/common/ProcessDiagramViewer.vue';
import {ElMessage, ElMessageBox} from "element-plus";
@@ -164,6 +165,8 @@ const getFile = (val) => {
fileList.value = newFileArray
}
}
const init = async () => {
const res = await getSubCompOpt()
companyOption.value = res.data
@@ -218,9 +221,11 @@ const handleSubmit = () => {
}
}
const getDetailInfo = async () => {
getInfo(route.query.id).then(res => {
getFormInfo(route.query.id).then(res => {
if (res.code === 1000) {
console.log(res)
ElMessage.success(res.msg)
// formData.value = res.data
formData.value = res.data.formData
// if (route.query.isAdd == undefined) {
// showTable.value = true

View File

@@ -23,31 +23,40 @@
<el-tooltip effect="dark" :content="user.name" placement="bottom-start">
<span class="username">{{ user.name }}</span>
</el-tooltip>
<template v-if="user.auditOpinion">
<div style="margin-top: 10px;background:#f5f5f5;padding: 10px;">
<div>
{{ user.auditOpinion }}
</div>
</div>
</template>
</div>
<div style="margin-left: 10px;">
<div style="color: #c0bebe">{{ operation.operationName }}</div>
<div style="font-size: 14px; font-weight: bold;">{{ operation.remark }}</div>
</div>
</div>
<template v-if="operation.comment">
<div style="margin-top: 10px;background:#f5f5f5;padding: 10px;">
<div>
{{ operation.comment.context }}
</div>
<div style="margin-top: 10px;" v-if="operation.comment.attachments && operation.comment.attachments.length > 0">
<template v-for="(item) in getAttachmentList(operation.comment.attachments,true)">
<el-image
style="width: 100px; height: 100px"
:src="item.url"
:preview-src-list="[item.url]">
</el-image>
</template>
<div v-for="(file) in getAttachmentList(operation.comment.attachments,false)">
<el-link style="color: #2a99ff" :href="file.url" icon="el-icon-document">{{ file.name }}</el-link>
</div>
</div>
</div>
</template>
<!-- <template v-if="operation.comment">-->
<!-- <div style="margin-top: 10px;background:#f5f5f5;padding: 10px;">-->
<!-- <div>-->
<!-- {{ operation.comment.context }}-->
<!-- </div>-->
<!-- <div style="margin-top: 10px;"-->
<!-- v-if="operation.comment.attachments && operation.comment.attachments.length > 0">-->
<!-- <template v-for="(item) in getAttachmentList(operation.comment.attachments,true)">-->
<!-- <el-image-->
<!-- style="width: 100px; height: 100px"-->
<!-- :src="item.url"-->
<!-- :preview-src-list="[item.url]">-->
<!-- </el-image>-->
<!-- </template>-->
<!-- <div v-for="(file) in getAttachmentList(operation.comment.attachments,false)">-->
<!-- <el-link style="color: #2a99ff" :href="file.url" icon="el-icon-document">{{ file.name }}</el-link>-->
<!-- </div>-->
<!-- </div>-->
<!-- </div>-->
<!-- </template>-->
</el-card>
</el-timeline-item>
<el-timeline-item :color="timeline.color" :icon="timeline.icon" size="large">
@@ -278,6 +287,7 @@ init()
position: relative;
margin-right: 5px;
}
.el-timeline-item__node {
position: absolute;
bottom: 20px;