Browse Source

520样式

tangjunhao 3 months ago
parent
commit
eb83592683

+ 11 - 0
src/style/index.css

@@ -237,6 +237,17 @@ text-transform: none;
   .sel .el-select{
     width: 100%;
   }
+
+.el-select__wrapper {
+  display: inline-block !important;
+  box-shadow: none;
+}
+
+.el-select .el-input__inner {
+  display: block !important;
+  visibility: visible !important;
+}
+
   .el-form-item{
     margin-bottom: 8px;
   }

+ 1 - 1
src/views/threejsView/components/ThreeScene.vue

@@ -564,7 +564,7 @@ const adjustCameraForPlt = (scene, camera, params = {}) => {
 
 </script>
 
-<style>
+<style scoped>
 .three-container {
   width: 100%;
   /* height: calc(60vh - 6px);  */

+ 38 - 4
src/views/titlecomponent/TACS.vue

@@ -144,13 +144,24 @@
     <!-- 结构参数 v-show="currentTab=='0'"-->
     <div v-show="currentTab2 == '1'">
       <div class="eldesign classtable" style="margin-top: 10px">
+        <el-row :gutter="5">
+          <el-col :span="21">
+            <el-form-item label="个数:" :label-width="70">
+              <el-input v-model="jiegouNum" />
+            </el-form-item>
+          </el-col>
+          <el-col :span="3">
+            <el-button  @click="addJiegou" style="width: 100%;">应用</el-button>
+          </el-col>
+        </el-row>
+        
         <el-table
           :data="inParams"
           border
           style="width: 100%;height: 450px;"
         >
           <el-table-column label="启用">
-            <el-table-column type="index" width="70" label="编号">
+            <el-table-column type="index" width="170" label="编号">
             </el-table-column>
           </el-table-column>
           <el-table-column>
@@ -163,15 +174,15 @@
                 v-model="writesolution"
               />
             </template>
-            <el-table-column prop="value" label="厚度分布" width="100">
+            <el-table-column prop="value" label="厚度分布" >
               <template #default="{ row }">
                 <el-input v-model="row.value" />
               </template>
             </el-table-column>
           </el-table-column>
-          <el-table-column>
+          <!-- <el-table-column>
             <el-table-column prop="con" label=""> </el-table-column>
-          </el-table-column>
+          </el-table-column> -->
         </el-table>
       </div>
     </div>
@@ -248,6 +259,8 @@ const tacsfileSrc = new URL('@/assets/flowimg/ffdFileSave.png', import.meta.url)
 
 let TACSactiveNames = ref(['1','2']);
 
+let jiegouNum = ref(0);
+
 let tacsvalue = ref({
   proname:'CRM',
   rho:'2780.0',
@@ -443,6 +456,27 @@ const headerCellClassName = ({ column }) => {
   return '';
 };
 
+const addJiegou = () => {
+  const targetLength = jiegouNum.value
+  const currentLength = inParams.value.length
+
+  if (targetLength > currentLength) {
+    const diff = targetLength - currentLength
+    for (let i = 0; i < diff; i++) {
+      inParams.value.push({
+        code: 'thickness',
+        name: '厚度分布',
+        value: '0.003',
+        flag: 1,
+        con: ''
+      })
+    }
+  } else if (targetLength < currentLength) {
+    const diff = currentLength - targetLength
+    inParams.value.splice(-diff, diff)
+  }
+}
+
 const gettacs = (id,nowid) => {
   pid.value = id;
   if(nowid){

+ 6 - 6
src/views/vuetree/Sidebar.vue

@@ -67,12 +67,12 @@ const datatree = ref([
       label: '学科分析组件',
       img:'xkfx.png',
       children: [
-      {
-          id:'3-01',
-          label: '优化器',
-          img:'mob.png',
-          name:'optimizer'
-        },
+      // {
+      //     id:'3-01',
+      //     label: '优化器',
+      //     img:'mob.png',
+      //     name:'optimizer'
+      //   },
         {
           id:'3-02',
           label: '参数化',