Browse Source

选型表格优化

codeMan 8 months ago
parent
commit
6c7f5cc1e9

+ 14 - 2
src/optionSystem/FProductManage/modules/diefa/diefaAdd.vue

@@ -219,9 +219,21 @@
                             </div>
                             <div class="tips" v-if="guangtouParam.content.where.drivetype=='电动'" style="color:#3874F6;margin-top: 10px;"><i class="el-icon-warning" style="margin-right: 5px;"></i>建议开关阀时间{{ caliber.filter(v=>v.value==guangtouParam.content.where.caliber).length ? caliber.filter(v=>v.value==guangtouParam.content.where.caliber)[0].remarks:'-' }}秒</div>
                             <!--执行器-->
-                            <MyTable fixedName="operation" :height="tableHeight" :noQuery="true" ref="excelRef" :tableName="guangtouParam.content.where.drivetype=='电动'?'excelTable1':'excelTable2'" :layout="guangtouParam.content.where.drivetype=='电动'?tool.tabelCol($route.name)['excelTable1'].tablecols:tool.tabelCol($route.name)['excelTable2'].tablecols" :param="excelParam" :opwidth="200" :custom="true" style="margin-top: 14px">
+                            <div v-if="guangtouParam.content.where.drivetype=='电动'">
+                                <MyTable fixedName="operation" :height="tableHeight" :noQuery="true" ref="excelRef" :layout="tool.tabelCol($route.name)['excelTable1'].tablecols" :param="excelParam" :custom="true" style="margin-top: 14px">
+                                    <template v-slot:customcol="scope">
+                                        <span v-if="scope.column.columnname == 'matchratio'" style="color:red">{{scope.column.data[scope.column.columnname]}}</span>
+                                        <span v-else-if="scope.column.columnname == 'maxsquarewidth'">{{scope.column.data[scope.column.columnname].join(',')}}</span>
+                                        <span v-else-if="scope.column.columnname != 'operation'">{{scope.column.data[scope.column.columnname]}}</span>
+                                    </template>
+                                    <template v-slot:opreation="scope">
+                                        <el-button type="text" size="mini" @click="selectTarget(scope.data,'执行器')" :disabled="(loading) || (guangtouParam.content.where.drivetype=='电动' && resultArr.length == 2)">选择</el-button>
+                                    </template>
+                                </MyTable>
+                            </div>
+                            <MyTable v-else :height="tableHeight" fixedName="operation" :noQuery="true" ref="excelRef" :layout="tool.tabelCol($route.name)['excelTable2'].tablecols" :param="excelParam" :custom="true" style="margin-top: 14px">
                                 <template v-slot:customcol="scope">
-                                    <div v-if="scope.column.columnname == 'matchratio'" style="color:red">{{scope.column.data[scope.column.columnname]}}</div>
+                                    <span v-if="scope.column.columnname == 'matchratio'" style="color:red">{{scope.column.data[scope.column.columnname]}}</span>
                                     <span v-else-if="scope.column.columnname == 'maxsquarewidth'">{{scope.column.data[scope.column.columnname].join(',')}}</span>
                                     <span v-else-if="scope.column.columnname != 'operation'">{{scope.column.data[scope.column.columnname]}}</span>
                                 </template>

+ 14 - 2
src/optionSystem/FProductManage/modules/diefa/edit.vue

@@ -219,9 +219,21 @@
                             </div>
                             <div class="tips" v-if="guangtouParam.content.where.drivetype=='电动'" style="color:#3874F6;margin-top: 10px;"><i class="el-icon-warning" style="margin-right: 5px;"></i>建议开关阀时间{{ caliber.filter(v=>v.value==guangtouParam.content.where.caliber).length ? caliber.filter(v=>v.value==guangtouParam.content.where.caliber)[0].remarks:'-' }}秒</div>
                             <!--执行器-->
-                            <MyTable fixedName="operation" :height="tableHeight" :noQuery="true" ref="excelRef" :tableName="guangtouParam.content.where.drivetype=='电动'?'excelTable1':'excelTable2'" :layout="guangtouParam.content.where.drivetype=='电动'?tool.tabelCol($route.name)['excelTable1'].tablecols:tool.tabelCol($route.name)['excelTable2'].tablecols" :param="excelParam" :opwidth="200" :custom="true" style="margin-top: 14px">
+                            <div v-if="guangtouParam.content.where.drivetype=='电动'">
+                                <MyTable fixedName="operation" :height="tableHeight" :noQuery="true" ref="excelRef" :layout="tool.tabelCol($route.name)['excelTable1'].tablecols" :param="excelParam" :custom="true" style="margin-top: 14px">
+                                    <template v-slot:customcol="scope">
+                                        <span v-if="scope.column.columnname == 'matchratio'" style="color:red">{{scope.column.data[scope.column.columnname]}}</span>
+                                        <span v-else-if="scope.column.columnname == 'maxsquarewidth'">{{scope.column.data[scope.column.columnname].join(',')}}</span>
+                                        <span v-else-if="scope.column.columnname != 'operation'">{{scope.column.data[scope.column.columnname]}}</span>
+                                    </template>
+                                    <template v-slot:opreation="scope">
+                                        <el-button type="text" size="mini" @click="selectTarget(scope.data,'执行器')" :disabled="(loading) || (guangtouParam.content.where.drivetype=='电动' && resultArr.length == 2)">选择</el-button>
+                                    </template>
+                                </MyTable>
+                            </div>
+                            <MyTable v-else :height="tableHeight" fixedName="operation" :noQuery="true" ref="excelRef" :layout="tool.tabelCol($route.name)['excelTable2'].tablecols" :param="excelParam" :custom="true" style="margin-top: 14px">
                                 <template v-slot:customcol="scope">
-                                    <div v-if="scope.column.columnname == 'matchratio'" style="color:red">{{scope.column.data[scope.column.columnname]}}</div>
+                                    <span v-if="scope.column.columnname == 'matchratio'" style="color:red">{{scope.column.data[scope.column.columnname]}}</span>
                                     <span v-else-if="scope.column.columnname == 'maxsquarewidth'">{{scope.column.data[scope.column.columnname].join(',')}}</span>
                                     <span v-else-if="scope.column.columnname != 'operation'">{{scope.column.data[scope.column.columnname]}}</span>
                                 </template>

+ 14 - 2
src/optionSystem/optionOrder/detail/modules/components/DieFa.vue

@@ -255,9 +255,21 @@
             <div class="tips" v-if="guangtouParam.content.where.drivetype=='电动'" style="color:#3874F6;margin-top: 10px;"><i class="el-icon-warning" style="margin-right: 5px;"></i>建议开关阀时间{{ caliber.filter(v=>v.value==guangtouParam.content.where.caliber).length ? caliber.filter(v=>v.value==guangtouParam.content.where.caliber)[0].remarks:'-' }}秒</div>
 
             <!--执行器-->
-            <MyTable fixedName="operation" :height="tableHeight" :noQuery="true" ref="excelRef" :tableName="guangtouParam.content.where.drivetype=='电动'?'excelTable1':'excelTable2'" :layout="guangtouParam.content.where.drivetype=='电动'?tool.tabelCol($route.name)['excelTable1'].tablecols:tool.tabelCol($route.name)['excelTable2'].tablecols" :param="excelParam" :opwidth="200" :custom="true" style="margin-top: 14px">
+            <div v-if="guangtouParam.content.where.drivetype=='电动'">
+                <MyTable fixedName="operation" :height="tableHeight" :noQuery="true" ref="excelRef" :layout="tool.tabelCol($route.name)['excelTable1'].tablecols" :param="excelParam" :custom="true" style="margin-top: 14px">
+                    <template v-slot:customcol="scope">
+                        <span v-if="scope.column.columnname == 'matchratio'" style="color:red">{{scope.column.data[scope.column.columnname]}}</span>
+                        <span v-else-if="scope.column.columnname == 'maxsquarewidth'">{{scope.column.data[scope.column.columnname].join(',')}}</span>
+                        <span v-else-if="scope.column.columnname != 'operation'">{{scope.column.data[scope.column.columnname]}}</span>
+                    </template>
+                    <template v-slot:opreation="scope">
+                        <el-button type="text" size="mini" @click="selectTarget(scope.data,'执行器')" :disabled="(loading) || (guangtouParam.content.where.drivetype=='电动' && resultArr.length == 2)">选择</el-button>
+                    </template>
+                </MyTable>
+            </div>
+            <MyTable v-else :height="tableHeight" fixedName="operation" :noQuery="true" ref="excelRef" :layout="tool.tabelCol($route.name)['excelTable2'].tablecols" :param="excelParam" :custom="true" style="margin-top: 14px">
                 <template v-slot:customcol="scope">
-                    <p v-if="scope.column.columnname == 'matchratio'" style="color:red">{{scope.column.data[scope.column.columnname]}}</p>
+                    <span v-if="scope.column.columnname == 'matchratio'" style="color:red">{{scope.column.data[scope.column.columnname]}}</span>
                     <span v-else-if="scope.column.columnname == 'maxsquarewidth'">{{scope.column.data[scope.column.columnname].join(',')}}</span>
                     <span v-else-if="scope.column.columnname != 'operation'">{{scope.column.data[scope.column.columnname]}}</span>
                 </template>

+ 13 - 1
src/optionSystem/selectOption/components/DieFa.vue

@@ -129,7 +129,19 @@
             </div>
             <div class="tips" v-if="guangtouParam.content.where.drivetype=='电动' && resultArr.length" style="color:#3874F6;margin-top: 10px;"><i class="el-icon-warning" style="margin-right: 5px;"></i>建议开关阀时间{{ caliber.filter(v=>v.value==resultArr[0].caliber).length ? caliber.filter(v=>v.value==resultArr[0].caliber)[0].remarks:'-' }}秒</div>
             <!--执行器-->
-            <MyTable fixedName="operation" :height="tableHeight" :noQuery="true" ref="excelRef" :tableName="guangtouParam.content.where.drivetype=='电动'?'excelTable1':'excelTable2'" :layout="guangtouParam.content.where.drivetype=='电动'?tool.tabelCol($route.name)['excelTable1'].tablecols:tool.tabelCol($route.name)['excelTable2'].tablecols" :param="excelParam" :opwidth="200" :custom="true" style="margin-top: 14px">
+            <div v-if="guangtouParam.content.where.drivetype=='电动'">
+                <MyTable fixedName="operation" :height="tableHeight" :noQuery="true" ref="excelRef" :layout="tool.tabelCol($route.name)['excelTable1'].tablecols" :param="excelParam" :custom="true" style="margin-top: 14px">
+                    <template v-slot:customcol="scope">
+                        <span v-if="scope.column.columnname == 'matchratio'" style="color:red">{{scope.column.data[scope.column.columnname]}}</span>
+                        <span v-else-if="scope.column.columnname == 'maxsquarewidth'">{{scope.column.data[scope.column.columnname].join(',')}}</span>
+                        <span v-else-if="scope.column.columnname != 'operation'">{{scope.column.data[scope.column.columnname]}}</span>
+                    </template>
+                    <template v-slot:opreation="scope">
+                        <el-button type="text" size="mini" @click="selectTarget(scope.data,'执行器')" :disabled="(loading) || (guangtouParam.content.where.drivetype=='电动' && resultArr.length == 2)">选择</el-button>
+                    </template>
+                </MyTable>
+            </div>
+            <MyTable v-else :height="tableHeight" fixedName="operation" :noQuery="true" ref="excelRef" :layout="tool.tabelCol($route.name)['excelTable2'].tablecols" :param="excelParam" :custom="true" style="margin-top: 14px">
                 <template v-slot:customcol="scope">
                     <span v-if="scope.column.columnname == 'matchratio'" style="color:red">{{scope.column.data[scope.column.columnname]}}</span>
                     <span v-else-if="scope.column.columnname == 'maxsquarewidth'">{{scope.column.data[scope.column.columnname].join(',')}}</span>

+ 14 - 2
src/optionSystem/valveOption/DieFa.vue

@@ -228,7 +228,19 @@
             </div>
             <div class="tips" v-if="guangtouParam.content.where.drivetype=='电动' && resultArr.length" style="color:#3874F6;margin-top: 10px;"><i class="el-icon-warning" style="margin-right: 5px;"></i>建议开关阀时间{{ caliber.filter(v=>v.value==resultArr[0].caliber).length ? caliber.filter(v=>v.value==resultArr[0].caliber)[0].remarks:'-' }}秒</div>
             <!--执行器-->
-            <MyTable fixedName="operation" :height="tableHeight" :noQuery="true" ref="excelRef" :tableName="guangtouParam.content.where.drivetype=='电动'?'excelTable1':'excelTable2'" :layout="guangtouParam.content.where.drivetype=='电动'?tool.tabelCol($route.name)['excelTable1'].tablecols:tool.tabelCol($route.name)['excelTable2'].tablecols" :param="excelParam" :opwidth="200" :custom="true" style="margin-top: 14px">
+            <div v-if="guangtouParam.content.where.drivetype=='电动'">
+                <MyTable fixedName="operation" :height="tableHeight" :noQuery="true" ref="excelRef" :layout="tool.tabelCol($route.name)['excelTable1'].tablecols" :param="excelParam" :custom="true" style="margin-top: 14px">
+                    <template v-slot:customcol="scope">
+                        <span v-if="scope.column.columnname == 'matchratio'" style="color:red">{{scope.column.data[scope.column.columnname]}}</span>
+                        <span v-else-if="scope.column.columnname == 'maxsquarewidth'">{{scope.column.data[scope.column.columnname].join(',')}}</span>
+                        <span v-else-if="scope.column.columnname != 'operation'">{{scope.column.data[scope.column.columnname]}}</span>
+                    </template>
+                    <template v-slot:opreation="scope">
+                        <el-button type="text" size="mini" @click="selectTarget(scope.data,'执行器')" :disabled="(loading) || (guangtouParam.content.where.drivetype=='电动' && resultArr.length == 2)">选择</el-button>
+                    </template>
+                </MyTable>
+            </div>
+            <MyTable v-else :height="tableHeight" fixedName="operation" :noQuery="true" ref="excelRef" :layout="tool.tabelCol($route.name)['excelTable2'].tablecols" :param="excelParam" :custom="true" style="margin-top: 14px">
                 <template v-slot:customcol="scope">
                     <span v-if="scope.column.columnname == 'matchratio'" style="color:red">{{scope.column.data[scope.column.columnname]}}</span>
                     <span v-else-if="scope.column.columnname == 'maxsquarewidth'">{{scope.column.data[scope.column.columnname].join(',')}}</span>
@@ -338,7 +350,7 @@
 </template>
 
 <script>
-import './index.css'
+import '@/optionSystem/valveOption/index.css'
 import MySelect from '@/optionSystem/FProductManage/modules/select.vue'
 import MyTable from '@/optionSystem/FProductManage/modules/table.vue'
 import SelectBar from '@/optionSystem/FProductManage/modules/selectBar.vue'