详情请求文件接口添加await
This commit is contained in:
@@ -351,12 +351,11 @@ const getInfo = async () => {
|
|||||||
}
|
}
|
||||||
const proviteData = ref()
|
const proviteData = ref()
|
||||||
//判断userType选择取用的对象
|
//判断userType选择取用的对象
|
||||||
const getProviteData = async() => {
|
const getProviteData = async () => {
|
||||||
if (detailData.value.userType == '0' || detailData.value.userType == '1') {
|
if (detailData.value.userType == '0' || detailData.value.userType == '1') {
|
||||||
proviteData.value = detailData.value.userReportProjectPO
|
proviteData.value = detailData.value.userReportProjectPO
|
||||||
//查询非线性设备类型
|
//查询非线性设备类型
|
||||||
// proviteData.value.nonlinearDeviceType
|
await getDictTreeById(proviteData.value.nonlinearDeviceType).then(res => {
|
||||||
await getDictTreeById(proviteData.value.nonlinearDeviceType).then(res => {
|
|
||||||
console.log(res, '==========')
|
console.log(res, '==========')
|
||||||
proviteData.value.nonlinearDeviceType = res.data?.name
|
proviteData.value.nonlinearDeviceType = res.data?.name
|
||||||
})
|
})
|
||||||
@@ -367,6 +366,11 @@ const getProviteData = async() => {
|
|||||||
detailData.value.userType == '5'
|
detailData.value.userType == '5'
|
||||||
) {
|
) {
|
||||||
proviteData.value = detailData.value.userReportSubstationPO
|
proviteData.value = detailData.value.userReportSubstationPO
|
||||||
|
//查询非线性负荷类型
|
||||||
|
await getDictTreeById(proviteData.value.nonlinearLoadType).then(res => {
|
||||||
|
console.log(res, '==========')
|
||||||
|
proviteData.value.nonlinearLoadType = res.data?.name
|
||||||
|
})
|
||||||
} else {
|
} else {
|
||||||
proviteData.value = detailData.value.userReportSensitivePO
|
proviteData.value = detailData.value.userReportSensitivePO
|
||||||
}
|
}
|
||||||
@@ -386,7 +390,10 @@ const getProviteData = async() => {
|
|||||||
|
|
||||||
//预测评估评审意见报告
|
//预测评估评审意见报告
|
||||||
if (proviteData.value.predictionEvaluationReviewOpinions) {
|
if (proviteData.value.predictionEvaluationReviewOpinions) {
|
||||||
await getFileNamePath(proviteData.value.predictionEvaluationReviewOpinions, 'predictionEvaluationReviewOpinions')
|
await getFileNamePath(
|
||||||
|
proviteData.value.predictionEvaluationReviewOpinions,
|
||||||
|
'predictionEvaluationReviewOpinions'
|
||||||
|
)
|
||||||
}
|
}
|
||||||
//用户接入变电站主接线示意图
|
//用户接入变电站主接线示意图
|
||||||
if (proviteData.value.substationMainWiringDiagram) {
|
if (proviteData.value.substationMainWiringDiagram) {
|
||||||
@@ -415,9 +422,8 @@ const getProviteData = async() => {
|
|||||||
}
|
}
|
||||||
//根据文件名请求
|
//根据文件名请求
|
||||||
const getFileNamePath = async (val: any, pathName: any) => {
|
const getFileNamePath = async (val: any, pathName: any) => {
|
||||||
|
await getFileNameAndFilePath({ filePath: val }).then(res => {
|
||||||
await getFileNameAndFilePath({ filePath: val }).then(res => {
|
console.log(111111111)
|
||||||
console.log(111111111)
|
|
||||||
if (res.data && res.data.name && res.data.url) {
|
if (res.data && res.data.name && res.data.url) {
|
||||||
//可研报告
|
//可研报告
|
||||||
if (pathName == 'feasibilityReport' && proviteData.value.feasibilityReport) {
|
if (pathName == 'feasibilityReport' && proviteData.value.feasibilityReport) {
|
||||||
|
|||||||
@@ -27,7 +27,7 @@
|
|||||||
<!-- 上传 -->
|
<!-- 上传 -->
|
||||||
<Audit ref='AuditRef' @onSubmit='tableStore.index()' />
|
<Audit ref='AuditRef' @onSubmit='tableStore.index()' />
|
||||||
<!-- 查看详情 detail 新增/修改 create-->
|
<!-- 查看详情 detail 新增/修改 create-->
|
||||||
<addForm ref='addForms' @onSubmit='tableStore.index()' openType='create'></addForm>
|
<addForm ref='addForms' v-if="show" @onSubmit='show=false;tableStore.index()' openType='create'></addForm>
|
||||||
</template>
|
</template>
|
||||||
<script setup lang='ts'>
|
<script setup lang='ts'>
|
||||||
import { ref, onMounted, provide, nextTick } from 'vue'
|
import { ref, onMounted, provide, nextTick } from 'vue'
|
||||||
@@ -54,6 +54,7 @@ const istatusList = dictData.getBasicData('On-network_Status')
|
|||||||
const addRef = ref()
|
const addRef = ref()
|
||||||
const AuditRef = ref()
|
const AuditRef = ref()
|
||||||
const ruleFormRef = ref()
|
const ruleFormRef = ref()
|
||||||
|
const show:any=ref(false)
|
||||||
const fileList = ref([])
|
const fileList = ref([])
|
||||||
const tableStore = new TableStore({
|
const tableStore = new TableStore({
|
||||||
url: '/supervision-boot/userReport/getUserReport',
|
url: '/supervision-boot/userReport/getUserReport',
|
||||||
@@ -144,7 +145,12 @@ const addList = () => {
|
|||||||
//三个表单
|
//三个表单
|
||||||
const addForms = ref()
|
const addForms = ref()
|
||||||
const addFormModel = () => {
|
const addFormModel = () => {
|
||||||
addForms.value.open()
|
show.value=true
|
||||||
|
setTimeout(() => {
|
||||||
|
|
||||||
|
addForms.value.open()
|
||||||
|
}, 0);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// 导出
|
// 导出
|
||||||
|
|||||||
Reference in New Issue
Block a user