[update] 企标制修订和企标更改流程的在线编辑

This commit is contained in:
lideqin
2024-01-24 13:43:25 +08:00
parent a4523b6aed
commit f777d43cca
18 changed files with 309 additions and 78 deletions
@@ -1,6 +1,20 @@
<template>
<div>
<base-info-form ref="baseInfoForm" v-bind="$attrs" disabled></base-info-form>
<!-- 标准文本 -->
<div class="box-title-text form-flex-item">
<div class="title-text">
<span class="title-text-text" :title="$t('workCenter.enStandardRevision.standardText')">
{{ $t('workCenter.enStandardRevision.standardText') }}
</span>
</div>
<a-form-model-item class="item-model">
<div class="online-edit-wrapper">
<p>{{ $t('enterpriseStandard') }}</p>
<a-button type="primary" @click="toOnlineEditor">{{ $t('workCenter.enStandardRevision.onLineEditing') }}</a-button>
</div>
</a-form-model-item>
</div>
<div>
<j-table
:can-drag="true"
@@ -46,6 +60,7 @@ import BaseInfoForm from './BaseInfoForm'
import UploadFile from '@/components/UploadFile'
import Vue from 'vue'
import { USER_INFO } from '@/store/mutation-types'
import { onlineEditor } from '../../../../utils/onlyOfficeUtils'
export default {
name: 'OtherDrafterUploadStandardBaseInfo',
@@ -112,7 +127,8 @@ export default {
loading: false,
userInfo: {}, // 当前登录人信息
currentDate: '',
uploadUid: undefined // 正在上传企标的行uid
uploadUid: undefined, // 正在上传企标的行uid
onEditFile: '' // 在线编辑的文件
}
},
mounted () {
@@ -132,6 +148,7 @@ export default {
...item
}
})
this.onEditFile = data.onEditFile
// 给表单赋值
this.$nextTick(() => {
this.$refs.baseInfoForm.initData(data)
@@ -188,6 +205,15 @@ export default {
/** 赋值给对应行的企标 */
const dataIndex = this.dataSource.findIndex(item => item.uid === this.uploadUid)
this.dataSource[dataIndex].fileId = attIdList.join(',')
},
/**
* 跳转在线编辑
*/
toOnlineEditor () {
// 获取参数(用于自动生成封面)
const params = this.$refs.baseInfoForm.getOnlineEditorParams()
// 已经有的在线编辑文件
onlineEditor(params, this.onEditFile)
}
}
}