Browse Source

广东安装增加费调整,材料信息价回车,搜索响应

zhangweicheng 5 years ago
parent
commit
d54c358c3c

+ 3 - 3
web/building_saas/main/js/models/bills.js

@@ -675,7 +675,7 @@ var Bills = {
             }
         };
         bills.prototype.getMeasureNode = function (controller) {//取措施项目工程节点
-            let roots =  controller.tree.roots;
+            let roots = controller?controller.tree.roots:projectObj.project.mainTree.roots;
             for(let root of roots){
                 if(isFlag(root.data)&&root.data.flagsIndex.fixed.flag==fixedFlag.MEASURE){
                     return root;
@@ -954,7 +954,7 @@ var Bills = {
             let controller = projectObj.mainController;
             let parentNode;
             if(type == '措施费用'){
-                parentNode = this.getTechNode();
+                parentNode = installationFeeObj.getMeasureParentNode();
             }else {
                 let rootNode = this.getFBFXNode(controller);
                 parentNode =getLeaveBill(rootNode.source);
@@ -987,7 +987,7 @@ var Bills = {
                 code : this.newFormatCode(code),
                 name:'安装增加费',
                 unit:'元',
-                stdCode:code,
+                stdCode:code.substring(0,9),
                 userID:userID,
                 billsLibId:projectObj.project.projectInfo.engineeringInfo.bill_lib[0].id,
                 quantity:'1'

+ 3 - 0
web/building_saas/main/js/views/installation_fee_view.js

@@ -857,6 +857,9 @@ let installationFeeObj={
             }
         }
     },
+    getMeasureParentNode:function(){
+      return projectObj.project.Bills.getTechNode();//默认取技术措施项目
+    },
     updateModifyFeeRulePosition:function (recode) {
         let me = this;
         let riselection = me.modifyFeeRuleSheet.getSelections()[0];

+ 2 - 2
web/building_saas/main/js/views/project_glj_view.js

@@ -1736,13 +1736,13 @@ $(function () {
     $('#info_area').change(function () {
       projectGljObject.searchInfoPrice();
     });
-   /*  $('#info_search_name').on('keypress', function (e) {
+    $('#info_search_name').on('keypress', function (e) {
       if (e.keyCode === 13) {
         projectGljObject.searchInfoPrice();
       }
     });
     $('#info_search_btn').on('click', function (e) {
       projectGljObject.searchInfoPrice();
-    }); */
+    });
 
 });

+ 3 - 0
web/over_write/js/guangdong_2018.js

@@ -174,6 +174,9 @@ if (typeof gljOprObj !== 'undefined') {
 }
 
 if (typeof installationFeeObj !== 'undefined') {
+  installationFeeObj.getMeasureParentNode=function(){
+    return projectObj.project.Bills.getMeasureNode();//取措施项目
+  },
   installationFeeObj.feeRateMap={
     "AZF0101":"39.86",
     "AZF0102":"39.92",