Bläddra i källkod

导出标准接口时自检
清单项目编码,唯一性更改成在建设项目下唯一

zhongzewei 6 år sedan
förälder
incheckning
22f923d82b

+ 3 - 2
web/building_saas/main/js/models/exportStandardInterface.js

@@ -168,6 +168,7 @@ const XMLStandard = (function () {
             this.constraints = {
                 engCode: [],    //单项工程编号
                 tenderCode: [], //单位工程编号
+                billsCode: [],  //清单项目项目编码(修改成了建设项目下唯一)
             };
             XML_EXPORT_BASE.Element.call(this, '标段', attrs);
         }
@@ -1222,8 +1223,8 @@ const XMLStandard = (function () {
                 remark: node.data.remark
             };
             let bills = new FXbills(source);
-            //清单项目项目编码要在单位工程中唯一
-            _util.checkUnique(curTenderEle.constraints.billsCode, source.code, `第${source.row}行`,`清单项目编码${source.code}`);
+            //清单项目项目编码要在建设项目中唯一
+            _util.checkUnique(curProjectEle.constraints.billsCode, source.code, `第${source.row}行`,`清单项目编码${source.code}`);
             //加载特征及内容
             function loadFeatureContent() {
                 let job = [],

+ 5 - 5
web/building_saas/main/js/views/export_view.js

@@ -102,6 +102,7 @@ const ExportView = (() => {
 
         //导出接口,如果没有错误,弹出工程编号设置窗口
         $('#export-confirm').click(async function () {
+            let failList = _cache.getItem('failList');
             let checkedDatas = $('#export input[type="checkbox"]:checked');
             if (!checkedDatas.length) {
                 return;
@@ -125,13 +126,12 @@ const ExportView = (() => {
                     pr.end();
                 }
                 //错误-设置提示弹窗
-                //不弹出
-                /*if (_failList.length * 20 > 400) {
+                if (failList.length * 20 > 400) {
                     $('#hintBox_caption').addClass('export-check');
                 }
-                if (_failList.length) {
-                    throw _failList.join('<br/>');
-                }*/
+                if (failList.length) {
+                    throw failList.join('<br/>');
+                }
                 //弹出工程编号设置窗口
                 if (isPring) {
                     setTimeout(() => {