|
@@ -89,7 +89,7 @@
|
|
|
<!-- 双击线段 -->
|
|
|
<el-dialog v-model="dataflowshow" align-center :modal="false" :close-on-click-modal="false"
|
|
|
:append-to-body="true" draggable :fullscreen="false" :modal-append-to-body="false" modal-class="summary-dlg"
|
|
|
- width="500" class="dialog_style bgcolor colortext tianjia sel">
|
|
|
+ width="500" class=" bgcolor colortext tianjia sel">
|
|
|
<template #header="{ titleId, titleClass }">
|
|
|
<div class="my-header ">
|
|
|
<h4 :id="titleId" :class="titleClass">数据流</h4>
|
|
@@ -166,7 +166,7 @@
|
|
|
@change="handlecheckFlagchange"></el-checkbox>
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
- <el-table-column prop="name" label="" ></el-table-column>
|
|
|
+ <el-table-column prop="name" label="" show-overflow-tooltip></el-table-column>
|
|
|
<el-table-column prop="steamtype">
|
|
|
<template #default="{ row }">
|
|
|
<el-select v-model="row.steamtype">
|
|
@@ -220,7 +220,143 @@
|
|
|
</div>
|
|
|
</el-card>
|
|
|
</div>
|
|
|
-
|
|
|
+ <div v-if="datacontent === '5'">
|
|
|
+ <el-card :shadow="none" style="min-height: 240px; max-height: 480px;">
|
|
|
+ <el-checkbox v-model="checkAll"
|
|
|
+ :indeterminate="isIndeterminate"
|
|
|
+ @change="handlecheckAllchange">全选</el-checkbox>
|
|
|
+ <div class="eldesign classtable">
|
|
|
+ <el-table :data="ADflowMathfunctable" border :show-header="false">
|
|
|
+ <el-table-column
|
|
|
+ type="index"
|
|
|
+ label=""
|
|
|
+ ></el-table-column>
|
|
|
+ <el-table-column prop="steamflag" width="55">
|
|
|
+ <template #default="{ row }">
|
|
|
+ <el-checkbox
|
|
|
+ :false-label="0"
|
|
|
+ :true-label="1"
|
|
|
+ v-model="row.steamflag"
|
|
|
+ @change="handlecheckFlagchange"></el-checkbox>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column prop="name" label="" show-overflow-tooltip></el-table-column>
|
|
|
+ <el-table-column prop="steamtype">
|
|
|
+ <template #default="{ row }">
|
|
|
+ <el-select v-model="row.steamtype">
|
|
|
+ <el-option
|
|
|
+ v-for="item in steamtypeoptions"
|
|
|
+ :key="item.value"
|
|
|
+ :label="item.label"
|
|
|
+ :value="item.value"
|
|
|
+ />
|
|
|
+ </el-select>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ </el-table>
|
|
|
+ </div>
|
|
|
+ </el-card>
|
|
|
+ </div>
|
|
|
+ <div v-if="datacontent === '6'">
|
|
|
+ <el-card :shadow="none" style="min-height: 240px; max-height: 480px;">
|
|
|
+ <el-checkbox v-model="checkAll"
|
|
|
+ :indeterminate="isIndeterminate"
|
|
|
+ @change="handlecheckAllchange">全选</el-checkbox>
|
|
|
+ <div class="eldesign classtable">
|
|
|
+ <el-table :data="TacsMathFunctable" border :show-header="false">
|
|
|
+ <el-table-column
|
|
|
+ type="index"
|
|
|
+ label=""
|
|
|
+ ></el-table-column>
|
|
|
+ <el-table-column prop="steamflag" width="55">
|
|
|
+ <template #default="{ row }">
|
|
|
+ <el-checkbox
|
|
|
+ :false-label="0"
|
|
|
+ :true-label="1"
|
|
|
+ v-model="row.steamflag"
|
|
|
+ @change="handlecheckFlagchange"></el-checkbox>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column prop="name" label="" show-overflow-tooltip></el-table-column>
|
|
|
+ <el-table-column prop="steamtype">
|
|
|
+ <template #default="{ row }">
|
|
|
+ <el-select v-model="row.steamtype">
|
|
|
+ <el-option
|
|
|
+ v-for="item in steamtypeoptions"
|
|
|
+ :key="item.value"
|
|
|
+ :label="item.label"
|
|
|
+ :value="item.value"
|
|
|
+ />
|
|
|
+ </el-select>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ </el-table>
|
|
|
+ </div>
|
|
|
+ </el-card>
|
|
|
+ </div>
|
|
|
+ <div v-if="datacontent === '7'">
|
|
|
+ <el-card :shadow="none" style="min-height: 240px; max-height: 480px;">
|
|
|
+ <el-checkbox v-model="checkAll"
|
|
|
+ :indeterminate="isIndeterminate"
|
|
|
+ @change="handlecheckAllchange">全选</el-checkbox>
|
|
|
+ <div class="eldesign classtable">
|
|
|
+ <el-table :data="youhuaTACStable" border :show-header="false">
|
|
|
+ <el-table-column
|
|
|
+ type="index"
|
|
|
+ label=""
|
|
|
+ ></el-table-column>
|
|
|
+ <el-table-column prop="steamflag" width="55">
|
|
|
+ <template #default="{ row }">
|
|
|
+ <el-checkbox
|
|
|
+ :false-label="0"
|
|
|
+ :true-label="1"
|
|
|
+ v-model="row.steamflag"
|
|
|
+ @change="handlecheckFlagchange"></el-checkbox>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column prop="name" label="" ></el-table-column>
|
|
|
+ </el-table>
|
|
|
+ </div>
|
|
|
+ </el-card>
|
|
|
+ </div>
|
|
|
+ <div v-if="datacontent === '8'">
|
|
|
+ <el-card :shadow="none" style="min-height: 240px; max-height: 480px;">
|
|
|
+ <el-checkbox v-model="checkAll"
|
|
|
+ :indeterminate="isIndeterminate"
|
|
|
+ @change="handlecheckAllchange">全选</el-checkbox>
|
|
|
+ <div class="eldesign classtable">
|
|
|
+ <el-table :data="MathFuncyouhuatable" border :show-header="false">
|
|
|
+ <el-table-column
|
|
|
+ type="index"
|
|
|
+ label=""
|
|
|
+ ></el-table-column>
|
|
|
+ <el-table-column prop="steamflag" width="55">
|
|
|
+ <template #default="{ row }">
|
|
|
+ <el-checkbox
|
|
|
+ :false-label="0"
|
|
|
+ :true-label="1"
|
|
|
+ v-model="row.steamflag"
|
|
|
+ @change="handlecheckFlagchange"></el-checkbox>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column prop="name" label="" show-overflow-tooltip></el-table-column>
|
|
|
+ <el-table-column prop="steamtype">
|
|
|
+ <template #default="{ row }">
|
|
|
+ <el-select v-model="row.steamtype">
|
|
|
+ <el-option
|
|
|
+ v-for="item in steamtypeoptions"
|
|
|
+ :key="item.value"
|
|
|
+ :label="item.label"
|
|
|
+ :value="item.value"
|
|
|
+ />
|
|
|
+ </el-select>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ </el-table>
|
|
|
+ </div>
|
|
|
+ </el-card>
|
|
|
+ </div>
|
|
|
+
|
|
|
</div>
|
|
|
<template #footer>
|
|
|
<div class="dialog-footer">
|
|
@@ -636,6 +772,10 @@ let youhuaCSTtable = ref([
|
|
|
{ name:'下表面CST参数(lower)', steamflag:1 }
|
|
|
])
|
|
|
|
|
|
+let youhuaTACStable = ref([
|
|
|
+ { name:'TACS参数', steamflag:1 }
|
|
|
+])
|
|
|
+
|
|
|
let steamtypeoptions = ref([
|
|
|
{ label:'约束条件', value:1 },
|
|
|
{ label:'优化目标', value:2 }
|
|
@@ -648,6 +788,12 @@ let ADflowyouhuatable = ref([
|
|
|
|
|
|
])
|
|
|
|
|
|
+let ADflowMathfunctable = ref([])
|
|
|
+
|
|
|
+let TacsMathFunctable = ref([])
|
|
|
+
|
|
|
+let MathFuncyouhuatable = ref([])
|
|
|
+
|
|
|
let Xfoilyouhuatable = ref([
|
|
|
// { code:'', name:'升力系数Cl', comtype:2 , steamflag:1, steamtype:1 },
|
|
|
// { code:'', name:'阻力系数Cd', comtype:2 , steamflag:1, steamtype:1 },
|
|
@@ -663,7 +809,11 @@ const dataTables = {
|
|
|
'1': youhuaFFDtable,
|
|
|
'2': youhuaCSTtable,
|
|
|
'3': ADflowyouhuatable,
|
|
|
- '4': Xfoilyouhuatable
|
|
|
+ '4': Xfoilyouhuatable,
|
|
|
+ '5': ADflowMathfunctable,
|
|
|
+ '6': TacsMathFunctable,
|
|
|
+ '7': youhuaTACStable,
|
|
|
+ '8': MathFuncyouhuatable,
|
|
|
};
|
|
|
|
|
|
const handlecheckFlagchange = () => {
|
|
@@ -700,6 +850,8 @@ const confirmselection=()=>{
|
|
|
|
|
|
const xfid = ref('')
|
|
|
const adid = ref('')
|
|
|
+const mfcid = ref('')
|
|
|
+const tacsid = ref('')
|
|
|
// 监听组件xfoil返回的xfid
|
|
|
const handleXfid = (xfidFromB) => {
|
|
|
xfid.value = xfidFromB.value;
|
|
@@ -710,6 +862,15 @@ const handleAdid = (adidFromB) => {
|
|
|
adid.value = adidFromB.value;
|
|
|
noid.value.data.adid = adid.value;
|
|
|
}
|
|
|
+const handleMfcid = (mfcidFromB) => {
|
|
|
+ mfcid.value = mfcidFromB.value;
|
|
|
+ noid.value.data.mfcid = mfcid.value;
|
|
|
+};
|
|
|
+
|
|
|
+const handleTacsid = (tacsidFromB) => {
|
|
|
+ tacsid.value = tacsidFromB.value;
|
|
|
+ noid.value.data.tacsid = tacsid.value;
|
|
|
+};
|
|
|
|
|
|
|
|
|
let datacontent = ref('')
|
|
@@ -756,6 +917,36 @@ function onEdgeDoubleClick(e) {
|
|
|
}else{
|
|
|
ElMessage.error('Xfoil未初始化!')
|
|
|
}
|
|
|
+ }else if ( qidian === 'ADflow' && zhongdian ==='MathFunc' ) {
|
|
|
+ datacontent.value = '5';
|
|
|
+ adid.value = e.edge.sourceNode.data.adid;
|
|
|
+ if(adid.value) {
|
|
|
+ querydataFlow(adid);
|
|
|
+ dataflowshow.value = true;
|
|
|
+ }else{
|
|
|
+ ElMessage.error('ADflow未初始化!')
|
|
|
+ }
|
|
|
+ }else if ( qidian === 'TACS' && zhongdian ==='MathFunc' ) {
|
|
|
+ datacontent.value = '6';
|
|
|
+ tacsid.value = e.edge.sourceNode.data.tacsid;
|
|
|
+ if(tacsid.value) {
|
|
|
+ querydataFlow(tacsid);
|
|
|
+ dataflowshow.value = true;
|
|
|
+ }else{
|
|
|
+ ElMessage.error('TACS未初始化!')
|
|
|
+ }
|
|
|
+ }else if( youhualist.includes(qidian) && zhongdian ==='TACS') {
|
|
|
+ datacontent.value = '7';
|
|
|
+ dataflowshow.value = true;
|
|
|
+ }else if( qidian ==='MathFunc' && youhualist.includes(zhongdian)) {
|
|
|
+ datacontent.value = '8';
|
|
|
+ mfcid.value = e.edge.sourceNode.data.mfcid;
|
|
|
+ if(mfcid.value) {
|
|
|
+ querydataFlow(mfcid);
|
|
|
+ dataflowshow.value = true;
|
|
|
+ }else{
|
|
|
+ ElMessage.error('MathFunc未初始化!')
|
|
|
+ }
|
|
|
}
|
|
|
console.log('leixing:',datacontent.value);
|
|
|
|
|
@@ -779,6 +970,18 @@ const querydataFlow = (comid) => {
|
|
|
Xfoilyouhuatable.value = res.params;
|
|
|
handlecheckFlagchange();
|
|
|
}
|
|
|
+ if(datacontent.value === '5'){
|
|
|
+ ADflowMathfunctable.value = res.params;
|
|
|
+ handlecheckFlagchange();
|
|
|
+ }
|
|
|
+ if(datacontent.value === '6'){
|
|
|
+ TacsMathFunctable.value = res.params;
|
|
|
+ handlecheckFlagchange();
|
|
|
+ }
|
|
|
+ if(datacontent.value === '8'){
|
|
|
+ MathFuncyouhuatable.value = res.params;
|
|
|
+ handlecheckFlagchange();
|
|
|
+ }
|
|
|
|
|
|
})
|
|
|
.catch((err) => {
|
|
@@ -792,6 +995,12 @@ const dataFlowsave = () => {
|
|
|
stringArray = convertToStringArray([],ADflowyouhuatable.value);
|
|
|
}else if(datacontent.value === '4'){
|
|
|
stringArray = convertToStringArray([],Xfoilyouhuatable.value);
|
|
|
+ }else if(datacontent.value === '5'){
|
|
|
+ stringArray = convertToStringArray([],ADflowMathfunctable.value);
|
|
|
+ }else if(datacontent.value === '6'){
|
|
|
+ stringArray = convertToStringArray([],TacsMathFunctable.value);
|
|
|
+ }else if(datacontent.value === '8'){
|
|
|
+ stringArray = convertToStringArray([],MathFuncyouhuatable.value);
|
|
|
}else{
|
|
|
return;
|
|
|
}
|
|
@@ -1195,6 +1404,8 @@ onMounted(() => {
|
|
|
|
|
|
emitter.on("xfidFromxfoil", handleXfid);
|
|
|
emitter.on("adidFromadflow", handleAdid);
|
|
|
+ emitter.on("mfcidFromMathFunc", handleMfcid);
|
|
|
+ emitter.on("tacsidFromTACS", handleTacsid);
|
|
|
});
|
|
|
|
|
|
const cleanEdgeselect = () => {
|
|
@@ -1224,6 +1435,9 @@ onUnmounted(() => {
|
|
|
|
|
|
emitter.off("xfidFromxfoil", handleXfid);
|
|
|
emitter.off("adidFromadflow", handleAdid);
|
|
|
+ emitter.off("mfcidFromMathFunc", handleMfcid);
|
|
|
+ emitter.off("tacsidFromTACS", handleTacsid);
|
|
|
+
|
|
|
});
|
|
|
|
|
|
|