소스 검색

Merge branch 'optionSystem' of http://124.70.211.186:3000/zhangqi/yos_web into optionSystem

# Conflicts:
#	src/SDrpManagement/ProductGroup/index.vue
xiaohaizhao 1 년 전
부모
커밋
476c572a7a

+ 3 - 0
src/HDrpManagement/contractManage/components/productDetailList/productDetailList.vue

@@ -55,6 +55,9 @@
             </div>
             <div v-else>{{ scope.column.data.itemname }}</div>
           </div>
+          <div v-else-if="scope.column.columnname == 'itemno'">
+            <span :style="scope.column.data.itemid?'':'color:red'">{{ scope.column.data.itemno }}</span>
+          </div>
           <div v-else-if="scope.column.columnname == 'attinfos'">
             <previewImage
               v-if="scope.column.data.attinfos[0]"

+ 3 - 0
src/HDrpManagement/contractManage/components/productList/productBillno.vue

@@ -49,6 +49,9 @@
             <el-input size="mini" v-if="editIndex == scope.column.data.sa_contract_itemsid" v-model="form.remarks" @change="remarksChange($event,scope.column.data,scope.column.data.index)" ></el-input>
             <p v-else>{{$t(scope.column.data[scope.column.columnname])}}</p>
           </div>
+          <div v-else-if="scope.column.columnname == 'itemno'">
+            <span :style="scope.column.data.itemid?'':'color:red'">{{ scope.column.data.itemno }}</span>
+          </div>
           <div v-else-if="scope.column.columnname == 'discountrate'">
             <el-input size="mini"v-model="scope.column.data.discountrate" @change="discountrateChange($event,scope.column.data,scope.column.data.index)" :disabled="!tool.checkAuth($route.name,'productBillManage') || data.status !== '新建' || !isLeader"></el-input>
           </div>

+ 3 - 0
src/HDrpManagement/projectChange/modules/modules/productSet/index.vue

@@ -57,6 +57,9 @@
           <div v-else-if="scope.column.columnname == 'price'">
             <el-input v-model="scope.column.data.price" size="mini"    @change="priceChange(scope.column.data.price,scope.$index,scope.column.data)" :disabled="!disabled || !tool.checkAuth($route.name,'productSetManage') || data.status === '已失败' || data.status === '已结案' "></el-input>
           </div>
+          <div v-else-if="scope.column.columnname == 'itemno'">
+            <span :style="scope.column.data.itemid?'':'color:red'">{{ scope.column.data.itemno }}</span>
+          </div>
           <div v-else-if="scope.column.columnname == 'marketprice'">
             <span>{{tool.formatAmount((scope.column.data.marketprice),2)}}</span>
           </div>

+ 25 - 8
src/SDrpManagement/ProductGroup/index.vue

@@ -30,6 +30,9 @@
           ></el-input>
         </div>
       </selectPeople>
+      
+      <!--阀门选型-->
+      <selectOption position="单独选型" style="margin-left: 10px" @handleParam="handleOptionParam"  v-if="tool.checkAuth($route.name,'optionSystem')"></selectOption>
     </div>
     <selectClass
       ref="class"
@@ -99,9 +102,10 @@
 </template>
 
 <script>
-import selectClass from "./modules/Select2.vue";
-import selectPeople from "./modules/selectPeople";
-import { log } from "@antv/g2plot/lib/utils";
+import selectClass from './modules/Select2.vue'
+import selectPeople from './modules/selectPeople'
+import SelectOption from '@/optionSystem/selectOption/add.vue'
+import { log } from '@antv/g2plot/lib/utils';
 export default {
   name: "productgroup",
   data() {
@@ -134,8 +138,14 @@ export default {
   },
   provide() {
     return {
-      sys_enterpriseid: () => this.sys_enterpriseid,
-    };
+      sys_enterpriseid:() => this.sys_enterpriseid,
+      detailData:() => false,
+    }
+  },
+  components:{selectClass,selectPeople,SelectOption},
+  computed:{
+  },
+  watch:{
   },
   components: { selectClass, selectPeople },
   computed: {},
@@ -147,9 +157,16 @@ export default {
     ).productGroupTable.tablecols;
   },
   methods: {
-    selectRow(data) {
-      this.enterprisename = data.enterprisename;
-      this.sys_enterpriseid = data.sys_enterpriseid;
+    //处理选型请求参数
+    handleOptionParam (param) {
+      param.content.enterprisename = ''
+      param.content.projectname = ''
+      param.content.sourcetable = ''
+      param.content.source = `单独选型`
+    },
+    selectRow (data) {
+      this.enterprisename = data.enterprisename
+      this.sys_enterpriseid = data.sys_enterpriseid
 
       this.$refs.class.queryBrands(() => {
         this.$refs.class.queryClass();

+ 3 - 0
src/SDrpManagement/QuotedPrice/detail/modules/productInventory/index.vue

@@ -71,6 +71,9 @@
             </div>
             <div v-else>{{ scope.column.data.itemname }}</div>
           </div>
+          <div v-else-if="scope.column.columnname == 'itemno'">
+            <span :style="scope.column.data.itemid?'':'color:red'">{{ scope.column.data.itemno }}</span>
+          </div>
           <div v-else-if="scope.column.columnname == 'discountrate'" >
             <el-input  :disabled="data.status !== '新建' || !tool.checkAuth($route.name,'productDetails') || !disabled || scope.column.data.pricetype === '指定单价'"  v-model="scope.column.data.discountrate" size="mini" placeholder="请输入折扣" @change="onChangeDiscountrate(scope.column.data.discountrate,scope.column.data,scope.$index)"></el-input>
           </div>

+ 66 - 17
src/optionSystem/selectOption/components/DieFa.vue

@@ -127,7 +127,7 @@
                     <MySelect :disabled="!excelParam.content.where.func"  @click="Search('excelParam','bodystructure')" :options="bodystructure" v-model="excelParam.content.where.bodystructure"></MySelect>
                 </div>
             </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>
+            <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.split(';')[0]:'-' }}秒</div>
             <!--执行器-->
             <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">
@@ -245,7 +245,7 @@
         <div class="fixed__btn__panel">
             <el-button size="small" @click="close" class="normal-btn-width">{{$t(`取 消`)}}</el-button>
             <el-button size="small" @click="guangtouParam.content.where.drivetype == '电动' ? active = 2 : active = 3" type="primary" v-if="active == 4" class="normal-btn-width">上一步</el-button>
-            <el-button size="small" type="primary" @click="onSubmit" class="normal-btn-width" v-if="active == 4">确认添加</el-button>
+            <el-button size="small" type="primary" @click="onSubmit" class="normal-btn-width" v-if="active == 4">{{ position == '单独选型' ? '保存选型单':'确认添加' }}</el-button>
         </div>
     </div>
   </div>
@@ -402,7 +402,7 @@ export default {
                 this.$api.requested({
                     "id": 2024071916224702,
                     "content": {
-                        "sa_projectid": this.detailData().sa_projectid,
+                        "sa_projectid": this.detailData() ? this.detailData().sa_projectid : 0,
                         "part_itemids": this.resultArr.map(item => {
                             return {
                                 parttype:item.parttype,
@@ -656,6 +656,9 @@ export default {
                 this.excelParam.content.where.flh = data.flh
                 this.excelParam.content.where.maxsquarewidth = data.maxsquarewidth
                 this.excelParam.content.where.maxrounddiameter = data.maxrounddiameter
+                if (this.guangtouParam.content.where.drivetype == '电动') {
+                    this.excelParam.content.where.caliber = this.resultArr[0].caliber
+                }
                 this.$nextTick(() => {
                     this.$refs.excelRef.listData(() => {
                         if (!this.$refs.excelRef.list.length) return
@@ -666,21 +669,67 @@ export default {
                 })
             this.active = 2
             } else if (type == '执行器') {
-                this.resultArr[1].itenname = this.resultArr[1].actuatorname
-                this.resultArr[1].itemno = this.resultArr[1].actuatorno
-
-                if (this.excelParam.content.where.drivetype == '气动调节') {
-                    this.fujianParam.content.othertypes = ['定位器','过滤减压阀']
-                } else {
-                    this.fujianParam.content.othertypes = ['电磁阀','限位开关','过滤减压阀']
-                }
-                data.itemid = data.actuatorid
-                data.itemname = data.actuatorname
-                if (this.guangtouParam.content.where.drivetype == '气动') {
-                    this.active = 3
-                    this.$refs.fujianRef.listData()
+                if (this.guangtouParam.content.where.drivetype == '电动') {
+                    let times = this.caliber.filter(v=>v.value==this.resultArr[0].caliber)[0].remarks.split(';')[0].split('-')
+                    if (parseInt(data.maxruntime) > parseInt(times[1]) || parseInt(data.maxruntime) < parseInt(times[0])) {
+                        this.$confirm(`当前选择执行器开关时间为${data.maxruntime}秒,超出建议值${times.join('-')},是否确认?`, "提示", {
+                            confirmButtonText: "确定",
+                            cancelButtonText: "取消",
+                            type: "warning",
+                        })
+                            .then(() => {
+                                this.resultArr[1].itenname = this.resultArr[1].actuatorname
+                                this.resultArr[1].itemno = this.resultArr[1].actuatorno
+                                if (this.excelParam.content.where.drivetype == '气动调节') {
+                                    this.fujianParam.content.othertypes = ['定位器','过滤减压阀']
+                                } else {
+                                    this.fujianParam.content.othertypes = ['电磁阀','限位开关','过滤减压阀']
+                                }
+                                data.itemid = data.actuatorid
+                                data.itemname = data.actuatorname
+                                if (this.guangtouParam.content.where.drivetype == '气动') {
+                                    this.active = 3
+                                    this.$refs.fujianRef.listData()
+                                } else {
+                                    this.active = 4
+                                }
+                            })
+                            .catch(() => {
+                                this.resultArr.pop()
+                            });
+                    } else {
+                        this.resultArr[1].itenname = this.resultArr[1].actuatorname
+                        this.resultArr[1].itemno = this.resultArr[1].actuatorno
+                        if (this.excelParam.content.where.drivetype == '气动调节') {
+                            this.fujianParam.content.othertypes = ['定位器','过滤减压阀']
+                        } else {
+                            this.fujianParam.content.othertypes = ['电磁阀','限位开关','过滤减压阀']
+                        }
+                        data.itemid = data.actuatorid
+                        data.itemname = data.actuatorname
+                        if (this.guangtouParam.content.where.drivetype == '气动') {
+                            this.active = 3
+                            this.$refs.fujianRef.listData()
+                        } else {
+                            this.active = 4
+                        }
+                    }
                 } else {
-                    this.active = 4
+                    this.resultArr[1].itenname = this.resultArr[1].actuatorname
+                    this.resultArr[1].itemno = this.resultArr[1].actuatorno
+                    if (this.excelParam.content.where.drivetype == '气动调节') {
+                        this.fujianParam.content.othertypes = ['定位器','过滤减压阀']
+                    } else {
+                        this.fujianParam.content.othertypes = ['电磁阀','限位开关','过滤减压阀']
+                    }
+                    data.itemid = data.actuatorid
+                    data.itemname = data.actuatorname
+                    if (this.guangtouParam.content.where.drivetype == '气动') {
+                        this.active = 3
+                        this.$refs.fujianRef.listData()
+                    } else {
+                        this.active = 4
+                    }
                 }
             } else {
                 if (this.fujianArr.filter(item=>item.itemid==data.itemid).length) return

+ 1 - 1
src/optionSystem/selectOption/components/setOrder.vue

@@ -11,7 +11,7 @@
                     <div class="descript">
                         <div class="item" v-if="result.主阀.torque"><span style="color: #888888;">料号:</span>{{result.主阀.itemno }}</div>
                         <div class="item" v-if="result.主阀.caliber"><span style="color: #888888;">公称通径:</span>{{result.主阀.caliber }}</div>
-                        <div class="item" v-if="result.主阀.nominalpressure"><span style="color: #888888;">公称压力:</span>{{result.主阀.nominalpressure }}</div>
+                        <div class="item" v-if="result.主阀.nominalpressure"><span style="color: #888888;">公称压力:</span>{{result.主阀.nominalpressure.join(',') }}</div>
                         <div class="item" v-if="result.主阀.stemmaterial"><span style="color: #888888;">阀杆材质:</span>{{result.主阀.stemmaterial }}</div>
                         <div class="item" v-if="result.主阀.mainmaterial"><span style="color: #888888;">主体材质:</span>{{result.主阀.mainmaterial }}</div>
                     </div>