소스 검색

计量审批流程

Tony Kang 2 년 전
부모
커밋
140a341e96

+ 1 - 0
app/public/report/js/jpc_output_value_define.js

@@ -75,6 +75,7 @@ let JV = {
     PROP_SIGNATURE_CELLS: 'signature_cells',
     PROP_SIGNATURE_DATE_CELLS: 'signature_date_cells',
     PROP_SIGNATURE_AUDIT_CELLS: 'signature_audit_cells',
+    PROP_INTERACT_CELLS: 'interact_cells',
     PAGE_SPECIAL_MERGE_POS: "page_merge_pos",
 
     PAGES_SIZE_STR: ['A3', 'A4', 'A5', 'B4', 'B5', 'LETTER', 'LEGAL', 'EXECUTIVE', '16K'],

+ 21 - 7
app/reports/rpt_component/helper/jpc_helper_discrete.js

@@ -9,7 +9,7 @@ const JpcFieldHelper = require('./jpc_helper_field');
 const SEG_PAGE_SPLIT_STR = '`';
 
 const JpcDiscreteHelper = {
-    outputDiscreteInfo: function(discreteArray, bands, dataObj, unitFactor, pageStatus, segIdx, segPageIdx, multiCols, multiColIdx, $CURRENT_RPT, customizeCfg, signatureRst, signatureDateRst, signatureAuditRst) {
+    outputDiscreteInfo(discreteArray, bands, dataObj, unitFactor, pageStatus, segIdx, segPageIdx, multiCols, multiColIdx, $CURRENT_RPT, customizeCfg, signatureRst, signatureDateRst, signatureAuditRst, interactRst = []) {
         const rst = [];
         if (discreteArray && dataObj) {
             for (let i = 0; i < discreteArray.length; i++) {
@@ -28,7 +28,7 @@ const JpcDiscreteHelper = {
                         let flexibleRefField = null;
                         for (let j = 0; j < discreteArray[i][JV.PROP_DISCRETE_FIELDS].length; j++) {
                             const df = discreteArray[i][JV.PROP_DISCRETE_FIELDS][j];
-                            if (!this.setupSignatureFieldParam(signatureRst, signatureDateRst, signatureAuditRst, $CURRENT_RPT, band, unitFactor, df)) {
+                            if (!this.setupSignatureFieldParam(signatureRst, signatureDateRst, signatureAuditRst, interactRst, $CURRENT_RPT, band, unitFactor, df)) {
                                 let value = '';
                                 let isPic = false;
                                 if (df[JV.PROP_FIELD_ID]) {
@@ -165,7 +165,7 @@ const JpcDiscreteHelper = {
         }
         return rst;
     },
-    setupSignatureFieldParam: function(signatureRst, signatureDateRst, signatureAuditRst, $CURRENT_RPT, band, unitFactor, df) {
+    setupSignatureFieldParam(signatureRst, signatureDateRst, signatureAuditRst, interactRst, $CURRENT_RPT, band, unitFactor, df) {
         let rst = false;
         if (JE.isSignature(df[JV.PROP_FIELD_ID], $CURRENT_RPT)) {
             // 这里输出到signatureRst
@@ -216,10 +216,24 @@ const JpcDiscreteHelper = {
                 signatureAuditRst.push(signatureAuditItem);
                 rst = true;
             }
+        } else if (JE.isInterActionParam(df[JV.PROP_PARAM_ID], $CURRENT_RPT)) {
+            if (Array.isArray(interactRst)) {
+                let pID = 0;
+                if (df.hasOwnProperty(JV.PROP_PARAM_ID)) {
+                    pID = df[JV.PROP_PARAM_ID];
+                } else {
+                    pID = df[JV.PROP_ID];
+                }
+                const interactItem = JpcCommonOutputHelper.createCommonOutputWithoutDecorate(df, df[JV.PROP_DFT_VALUE], true);
+                interactItem[JV.PROP_AREA] = JpcAreaHelper.outputArea(df[JV.PROP_AREA], band, unitFactor, 1, 0, 1, 0, 1, 0, false, false);
+                interactItem[JV.PROP_BAND_NAME] = band.Name;
+                interactRst.push(interactItem);
+                rst = true;
+            }
         }
         return rst;
     },
-    _getSegPageValue: function(orgData, segPageIdx) {
+    _getSegPageValue(orgData, segPageIdx) {
         let rst = orgData;
         if (typeof orgData === 'string') {
             const splitStrs = orgData.split(SEG_PAGE_SPLIT_STR);
@@ -233,7 +247,7 @@ const JpcDiscreteHelper = {
         }
         return rst;
     },
-    outputPreviewDiscreteInfo: function(discreteArray, bands, unitFactor, pageStatus) {
+    outputPreviewDiscreteInfo(discreteArray, bands, unitFactor, pageStatus) {
         const rst = [];
         for (let i = 0; i < discreteArray.length; i++) {
             const band = bands[discreteArray[i][JV.PROP_BAND_NAME]];
@@ -264,7 +278,7 @@ const JpcDiscreteHelper = {
         }
         return rst;
     },
-    outputPreviewSumInfoOutput: function(band, unitFactor, tab) {
+    outputPreviewSumInfoOutput(band, unitFactor, tab) {
         const rst = [];
         if (tab[JV.PROP_TEXT]) {
             rst.push(JpcTextHelper.outputText(tab[JV.PROP_TEXT], band, unitFactor, 1, 0, 1, 0, 1, 0));
@@ -289,6 +303,6 @@ const JpcDiscreteHelper = {
         }
         return rst;
     },
-}
+};
 
 module.exports = JpcDiscreteHelper;

+ 14 - 12
app/reports/rpt_component/jpc_band.js

@@ -1,11 +1,13 @@
-let JV = require('./jpc_value_define');
-let JpcCommonHelper = require('./helper/jpc_helper_common');
-let JpcBandHelper = require('./helper/jpc_helper_band');
+'use strict';
 
-let JpcBand = {
-    createNew: function(rptTpl, defProperties) {
-        let me = this;
-        let JpcBandResult = {};
+const JV = require('./jpc_value_define');
+const JpcCommonHelper = require('./helper/jpc_helper_common');
+const JpcBandHelper = require('./helper/jpc_helper_band');
+
+const JpcBand = {
+    createNew(rptTpl, defProperties) {
+        const me = this;
+        const JpcBandResult = {};
         if (rptTpl[JV.NODE_BAND_COLLECTION]) {
             for (let i = 0; i < rptTpl[JV.NODE_BAND_COLLECTION].length; i++) {
                 me.createSingle(rptTpl[JV.NODE_BAND_COLLECTION][i], JpcBandResult, rptTpl, defProperties);
@@ -13,10 +15,10 @@ let JpcBand = {
         }
         return JpcBandResult;
     },
-    createSingle: function(bandNode, parentObj, rptTpl, defProperties) {
-        let me = this;
+    createSingle(bandNode, parentObj, rptTpl, defProperties) {
+        const me = this;
         if (bandNode && bandNode[JV.BAND_PROP_NAME]) {
-            let item = {Left:0, Right:0, Top:0, Bottom:0};
+            const item = { Left: 0, Right: 0, Top: 0, Bottom: 0, Name: bandNode[JV.BAND_PROP_NAME] };
             item[JV.BAND_PROP_STYLE] = JpcCommonHelper.getStyle(bandNode[JV.BAND_PROP_STYLE], defProperties.styles, null);
             item[JV.BAND_PROP_CONTROL] = JpcCommonHelper.getControl(bandNode[JV.BAND_PROP_CONTROL], defProperties.ctrls, null);
             if (bandNode[JV.BAND_PROP_HEIGHT]) {
@@ -52,7 +54,7 @@ let JpcBand = {
                 parentObj[JV.BAND_PROP_MERGE_BAND] = item;
             }
         }
-    }
+    },
 };
 
-module.exports = JpcBand;
+module.exports = JpcBand;

+ 4 - 41
app/reports/rpt_component/jpc_bill_tab.js

@@ -67,6 +67,7 @@ JpcBillTabSrv.prototype.createNew = function() {
         me.signatureRst = [];
         me.signatureDateRst = [];
         me.signatureAuditRst = [];
+        me.interactRst = [];
         const tabRstLst = [];
         // 1. calculate the band position
         const pageStatus = [true, false, false, false, false, false, false, false];
@@ -84,7 +85,7 @@ JpcBillTabSrv.prototype.createNew = function() {
         //  2.1 output content
         tabRstLst.push(me.outputContent(rptTpl, dataObj, page, bands, unitFactor, controls, pageStatus, $CURRENT_RPT, customizeCfg));
         //  2.2 output discrete
-        tabRstLst.push(JpcDiscreteHelper.outputDiscreteInfo(rptTpl[JV.NODE_BILL_INFO][JV.NODE_DISCRETE_INFO], bands, dataObj, unitFactor, pageStatus, page - 1, 0, 1, 0, $CURRENT_RPT, customizeCfg, me.signatureRst, me.signatureDateRst, me.signatureAuditRst));
+        tabRstLst.push(JpcDiscreteHelper.outputDiscreteInfo(rptTpl[JV.NODE_BILL_INFO][JV.NODE_DISCRETE_INFO], bands, dataObj, unitFactor, pageStatus, page - 1, 0, 1, 0, $CURRENT_RPT, customizeCfg, me.signatureRst, me.signatureDateRst, me.signatureAuditRst, me.interactRst));
         for (let i = 0; i < tabRstLst.length; i++) {
             rst = rst.concat(tabRstLst[i]);
             tabRstLst[i] = null;
@@ -141,7 +142,7 @@ JpcBillTabSrv.prototype.createNew = function() {
                 let isPic = false;
                 for (let i = 0; i < tab_fields.length; i++) {
                     const tab_field = tab_fields[i];
-                    if (!JpcDiscreteHelper.setupSignatureFieldParam(me.signatureRst, me.signatureDateRst, me.signatureAuditRst, $CURRENT_RPT, band, unitFactor, tab_field)) {
+                    if (!JpcDiscreteHelper.setupSignatureFieldParam(me.signatureRst, me.signatureDateRst, me.signatureAuditRst, me.interactRst, $CURRENT_RPT, band, unitFactor, tab_field)) {
                         let data_field = null;
                         const map_data_field = JE.F(tab_field[JV.PROP_FIELD_ID], $CURRENT_RPT);
                         isPic = (map_data_field.isPic !== undefined && map_data_field.isPic);
@@ -186,44 +187,6 @@ JpcBillTabSrv.prototype.createNew = function() {
                             rst.push(cellItem); // 不管是不是Pic,都得保留一个壳子
                         }
                     }
-                    /*
-                    if (JE.isSignature(tab_field[JV.PROP_FIELD_ID], $CURRENT_RPT)) {
-                        // 这里输出到signatureRst
-                        const map_data_field = JE.F(tab_field[JV.PROP_FIELD_ID], $CURRENT_RPT);
-                        const signatureItem = { signature_name: map_data_field[JV.PROP_NAME], path: null, pic: null };
-                        signatureItem[JV.PROP_CONTROL] = tab_field[[JV.PROP_CONTROL]];
-                        signatureItem[JV.PROP_STYLE] = tab_field[[JV.PROP_STYLE]];
-                        signatureItem[JV.PROP_AREA] = JpcAreaHelper.outputArea(tab_field[JV.PROP_AREA], band, unitFactor, 1, 0, 1, 0, 1, 0, false, false);
-                        me.signatureRst.push(signatureItem);
-                    } else if (JE.isDynamicParam(tab_field[JV.PROP_PARAM_ID], $CURRENT_RPT)) {
-                        // 这里输出到signatureDateRst
-                        let pID = 0;
-                        if (tab_field.hasOwnProperty(JV.PROP_PARAM_ID)) {
-                            pID = tab_field[JV.PROP_PARAM_ID];
-                        } else {
-                            pID = tab_field[JV.PROP_ID];
-                        }
-                        const param = JE.P(pID, $CURRENT_RPT);
-                        const signatureDateItem = JpcCommonOutputHelper.createCommonOutputWithoutDecorate(tab_field, tab_field[JV.PROP_DFT_VALUE], true);
-                        signatureDateItem.signature_name = param[JV.PROP_NAME];
-                        signatureDateItem[JV.PROP_AREA] = JpcAreaHelper.outputArea(tab_field[JV.PROP_AREA], band, unitFactor, 1, 0, 1, 0, 1, 0, false, false);
-                        me.signatureDateRst.push(signatureDateItem);
-                    } else if (JE.isSignatureAudit(tab_field[JV.PROP_PARAM_ID], $CURRENT_RPT)) {
-                        let pID = 0;
-                        if (tab_field.hasOwnProperty(JV.PROP_PARAM_ID)) {
-                            pID = tab_field[JV.PROP_PARAM_ID];
-                        } else {
-                            pID = tab_field[JV.PROP_ID];
-                        }
-                        const param = JE.P(pID, $CURRENT_RPT);
-                        const signatureAuditItem = JpcCommonOutputHelper.createCommonOutputWithoutDecorate(tab_field, tab_field[JV.PROP_DFT_VALUE], true);
-                        signatureAuditItem.signature_name = param[JV.PROP_NAME];
-                        signatureAuditItem[JV.PROP_AREA] = JpcAreaHelper.outputArea(tab_field[JV.PROP_AREA], band, unitFactor, 1, 0, 1, 0, 1, 0, false, false);
-                        me.signatureAuditRst.push(signatureAuditItem);
-                    } else {
-                        //
-                    }
-                    */
                 }
                 if (tab[JV.PROP_TEXT]) {
                     rst.push(JpcTextHelper.outputText(tab[JV.PROP_TEXT], band, unitFactor, 1, 0, 1, 0, 1, 0));
@@ -234,7 +197,7 @@ JpcBillTabSrv.prototype.createNew = function() {
                     }
                 }
                 if (tab[JV.NODE_DISCRETE_INFO]) {
-                    rst = rst.concat(JpcDiscreteHelper.outputDiscreteInfo(tab[JV.NODE_DISCRETE_INFO], bands, dataObj, unitFactor, pageStatus, page - 1, 0, 1, 0, customizeCfg, me.signatureRst, me.signatureDateRst, me.signatureAuditRst));
+                    rst = rst.concat(JpcDiscreteHelper.outputDiscreteInfo(tab[JV.NODE_DISCRETE_INFO], bands, dataObj, unitFactor, pageStatus, page - 1, 0, 1, 0, customizeCfg, me.signatureRst, me.signatureDateRst, me.signatureAuditRst, me.interactRst));
                 }
             }
         }

+ 3 - 29
app/reports/rpt_component/jpc_cross_tab.js

@@ -220,6 +220,7 @@ JpcCrossTabSrv.prototype.createNew = function() {
         me.signatureRst = [];
         me.signatureDateRst = [];
         me.signatureAuditRst = [];
+        me.interactRst = [];
     };
     JpcCrossTabResult.sorting = function(rptTpl, dataObj, dataSeq, $CURRENT_RPT) {
         const me = this;
@@ -578,34 +579,7 @@ JpcCrossTabSrv.prototype.createNew = function() {
         const tabRstLst = [];
         const unitFactor = JpcCommonHelper.getUnitFactor(rptTpl);
         if (me.paging_option === JV.PAGING_OPTION_INFINITY) {
-            /*
-             let segIdx = page - 1;
-             //1 calculate the band position
-             JpcBandHelper.setBandArea(bands, rptTpl, me.pageStatusLst[page - 1]);
-             //2. then reset the band height
-             let tab = rptTpl[JV.NODE_CROSS_INFO][JV.NODE_CROSS_CONTENT];
-             let crossContentBand = bands[tab[JV.PROP_BAND_NAME]];
-             let actH = JpcCrossTabHelper.getActualRowsHeight(bands, rptTpl, me.sortedRowSequence, page);
-             let actW = JpcCrossTabHelper.getActualColsWidth(bands, rptTpl, me.sortedColSequence, page);
-             let offsetY = actH - (crossContentBand.Bottom - crossContentBand.Top);
-             let offsetX = actW - (crossContentBand.Right - crossContentBand.Left);
-             JpcBandHelper.resetBandPos(rptTpl[JV.NODE_BAND_COLLECTION], bands, crossContentBand, offsetX, offsetY);
-
-             //2.1 Row-Tab
-             tabRstLst.push(me.outputRowTab(rptTpl, dataObj, page, bands, unitFactor, controls));
-             //2.2 Col-Tab
-             tabRstLst.push(me.outputColTab(rptTpl, dataObj, page, bands, unitFactor, controls));
-             //2.3 Content-Tab
-             tabRstLst.push(me.outputContent(rptTpl, dataObj, page, bands, unitFactor, controls));
-             //2.4 Sum-Tab Row
-             //2.4 Sum-tab Col
-             tabRstLst.push(me.outputTabSumCol(rptTpl, dataObj, page, bands, unitFactor, JV.NODE_CROSS_COL_SUM, controls));
-             //2.x row tab ext
-             tabRstLst.push(me.outputTabExt(rptTpl, dataObj, page, bands, unitFactor, controls));
-             tabRstLst.push(me.outputSumTabExt(rptTpl, dataObj, page, bands, unitFactor, segIdx, controls));
-             //2.5 Discrete
-             tabRstLst.push(JpcDiscreteHelper.outputDiscreteInfo(rptTpl[JV.NODE_CROSS_INFO][JV.NODE_DISCRETE_INFO], bands, dataObj, unitFactor, me.pageStatusLst[page - 1], segIdx, 1, 0, $CURRENT_RPT, customizeCfg));
-             //*/
+            // 交叉表不支持这种方式
         } else {
             const segIdx = JpcCommonHelper.getSegIdxByPageIdx(page, me.page_seg_map);
             const segPageIdx = 0; // 暂时设置为0
@@ -629,7 +603,7 @@ JpcCrossTabSrv.prototype.createNew = function() {
             tabRstLst.push(me.outputTabExt(rptTpl, dataObj, page, bands, unitFactor, controls, $CURRENT_RPT, customizeCfg));
             tabRstLst.push(me.outputSumTabExt(rptTpl, dataObj, page, bands, unitFactor, segIdx, controls, $CURRENT_RPT, customizeCfg));
             //  2.5 Discrete
-            tabRstLst.push(JpcDiscreteHelper.outputDiscreteInfo(rptTpl[JV.NODE_CROSS_INFO][JV.NODE_DISCRETE_INFO], bands, dataObj, unitFactor, me.pageStatusLst[page - 1], segIdx, segPageIdx, 1, 0, $CURRENT_RPT, customizeCfg, me.signatureRst, me.signatureDateRst, me.signatureAuditRst));
+            tabRstLst.push(JpcDiscreteHelper.outputDiscreteInfo(rptTpl[JV.NODE_CROSS_INFO][JV.NODE_DISCRETE_INFO], bands, dataObj, unitFactor, me.pageStatusLst[page - 1], segIdx, segPageIdx, 1, 0, $CURRENT_RPT, customizeCfg, me.signatureRst, me.signatureDateRst, me.signatureAuditRst, me.interactRst));
         }
         for (let i = 0; i < tabRstLst.length; i++) {
             rst = rst.concat(tabRstLst[i]);

+ 5 - 0
app/reports/rpt_component/jpc_ex.js

@@ -303,6 +303,7 @@ JpcExSrv.prototype.createNew = function() {
             rstPage[JV.PROP_SIGNATURE_CELLS] = [];
             rstPage[JV.PROP_SIGNATURE_DATE_CELLS] = [];
             rstPage[JV.PROP_SIGNATURE_AUDIT_CELLS] = [];
+            rstPage[JV.PROP_INTERACT_CELLS] = [];
             rst.items.push(rstPage);
             // 2.
             if (bands[JV.BAND_PROP_MERGE_BAND]) {
@@ -392,6 +393,7 @@ JpcExSrv.prototype.createNew = function() {
                     rst[JV.PROP_SIGNATURE_CELLS] = me.flowTab.signatureRst;
                     rst[JV.PROP_SIGNATURE_DATE_CELLS] = me.flowTab.signatureDateRst;
                     rst[JV.PROP_SIGNATURE_AUDIT_CELLS] = me.flowTab.signatureAuditRst;
+                    rst[JV.PROP_INTERACT_CELLS] = me.flowTab.interactRst;
                     if (adHocMergePos) {
                         adHocMergePos[JV.NODE_PAGE_SIZE] = JpcCommonHelper.getPageSize(rptTpl);
                         rst[JV.PAGE_SPECIAL_MERGE_POS] = adHocMergePos;
@@ -403,6 +405,7 @@ JpcExSrv.prototype.createNew = function() {
                         rst[JV.PROP_SIGNATURE_CELLS] = me.flowTabEx.signatureRst;
                         rst[JV.PROP_SIGNATURE_DATE_CELLS] = me.flowTabEx.signatureDateRst;
                         rst[JV.PROP_SIGNATURE_AUDIT_CELLS] = me.flowTabEx.signatureAuditRst;
+                        rst[JV.PROP_INTERACT_CELLS] = me.flowTab.interactRst;
                     }
                 }
             } else if (me.crossTab) {
@@ -410,11 +413,13 @@ JpcExSrv.prototype.createNew = function() {
                 rst[JV.PROP_SIGNATURE_CELLS] = me.crossTab.signatureRst;
                 rst[JV.PROP_SIGNATURE_DATE_CELLS] = me.crossTab.signatureDateRst;
                 rst[JV.PROP_SIGNATURE_AUDIT_CELLS] = me.crossTab.signatureAuditRst;
+                rst[JV.PROP_INTERACT_CELLS] = me.flowTab.interactRst;
             } else if (me.billTab) {
                 rst[JV.PROP_CELLS] = me.billTab.outputAsSimpleJSONPage(rptTpl, dataObj, page, bands, controls, fonts, me, customizeCfg);
                 rst[JV.PROP_SIGNATURE_CELLS] = me.billTab.signatureRst;
                 rst[JV.PROP_SIGNATURE_DATE_CELLS] = me.billTab.signatureDateRst;
                 rst[JV.PROP_SIGNATURE_AUDIT_CELLS] = me.billTab.signatureAuditRst;
+                rst[JV.PROP_INTERACT_CELLS] = me.flowTab.interactRst;
             }
             if (!(me.flowTab && me.flowTab.paging_option === JV.PAGING_OPTION_INFINITY)) {
                 const pageMergeBorder = getPageMergeBorder();

+ 5 - 3
app/reports/rpt_component/jpc_flow_tab.js

@@ -186,6 +186,7 @@ JpcFlowTabSrv.prototype.createNew = function() {
         me.signatureRst = [];
         me.signatureDateRst = [];
         me.signatureAuditRst = [];
+        me.interactRst = [];
 
         me.hasBreakFlowArr = [];
     };
@@ -891,6 +892,7 @@ JpcFlowTabSrv.prototype.createNew = function() {
         me.signatureRst = [];
         me.signatureDateRst = [];
         me.signatureAuditRst = [];
+        me.interactRst = [];
         if (me.paging_option === JV.PAGING_OPTION_INFINITY) {
             const segIdx = page - 1;
             // 1 calculate the band position
@@ -922,7 +924,7 @@ JpcFlowTabSrv.prototype.createNew = function() {
             tabRstLst.push(me.outputPageSum(rptTpl, dataObj, page, segIdx, bands, unitFactor, controls, $CURRENT_RPT, customizeCfg));
             // 2.5 Group
             // 2.6 Discrete
-            tabRstLst.push(JpcDiscreteHelper.outputDiscreteInfo(rptTpl[FLOW_NODE_STR][JV.NODE_DISCRETE_INFO], bands, dataObj, unitFactor, me.pageStatusLst[page - 1], segIdx, 0, 1, 0, $CURRENT_RPT, customizeCfg, me.signatureRst, me.signatureDateRst, me.signatureAuditRst));
+            tabRstLst.push(JpcDiscreteHelper.outputDiscreteInfo(rptTpl[FLOW_NODE_STR][JV.NODE_DISCRETE_INFO], bands, dataObj, unitFactor, me.pageStatusLst[page - 1], segIdx, 0, 1, 0, $CURRENT_RPT, customizeCfg, me.signatureRst, me.signatureDateRst, me.signatureAuditRst, me.interactRst));
             // 3. reset merge band position
             if (bands[JV.BAND_PROP_MERGE_BAND] && adHocMergePos) {
                 const mergedBand = bands[JV.BAND_PROP_MERGE_BAND];
@@ -958,7 +960,7 @@ JpcFlowTabSrv.prototype.createNew = function() {
                 // 2.5 Group
                 // 2.6 Discrete
                 if (pi === 0) {
-                    tabRstLst.push(JpcDiscreteHelper.outputDiscreteInfo(rptTpl[FLOW_NODE_STR][JV.NODE_DISCRETE_INFO], bands, dataObj, unitFactor, me.pageStatusLst[actualPage - 1], segIdx, segPageIdx, 1, pi, $CURRENT_RPT, customizeCfg, me.signatureRst, me.signatureDateRst, me.signatureAuditRst));
+                    tabRstLst.push(JpcDiscreteHelper.outputDiscreteInfo(rptTpl[FLOW_NODE_STR][JV.NODE_DISCRETE_INFO], bands, dataObj, unitFactor, me.pageStatusLst[actualPage - 1], segIdx, segPageIdx, 1, pi, $CURRENT_RPT, customizeCfg, me.signatureRst, me.signatureDateRst, me.signatureAuditRst, me.interactRst));
                 }
             }
         }
@@ -1616,7 +1618,7 @@ JpcFlowTabSrv.prototype.createNew = function() {
             }
         }
         if (tab[JV.NODE_DISCRETE_INFO]) {
-            rst = rst.concat(JpcDiscreteHelper.outputDiscreteInfo(tab[JV.NODE_DISCRETE_INFO], bands, dataObj, unitFactor, me.pageStatusLst[page - 1], segIdx, segPageIdx, 1, 0, $CURRENT_RPT, customizeCfg, me.signatureRst, me.signatureDateRst, me.signatureAuditRst));
+            rst = rst.concat(JpcDiscreteHelper.outputDiscreteInfo(tab[JV.NODE_DISCRETE_INFO], bands, dataObj, unitFactor, me.pageStatusLst[page - 1], segIdx, segPageIdx, 1, 0, $CURRENT_RPT, customizeCfg, me.signatureRst, me.signatureDateRst, me.signatureAuditRst, me.interactRst));
         }
         return rst;
     };

+ 8 - 2
app/reports/rpt_component/jpc_param.js

@@ -2,7 +2,7 @@
 
 const JV = require('./jpc_value_define');
 const JpcParam = {
-    createNew: function(rptTpl) {
+    createNew(rptTpl) {
         const JpcParamResult = {};
         JpcParamResult[JV.NODE_DYNAMIC_DATE_PARAMS] = {};
         JpcParamResult[JV.NODE_SIGNATURE_AUDIT_PARAMS] = {};
@@ -22,9 +22,14 @@ const JpcParam = {
                 me.createSingle(rptTpl[JV.NODE_SIGNATURE_AUDIT_PARAMS][i], JpcParamResult[JV.NODE_SIGNATURE_AUDIT_PARAMS], rptTpl, i);
             }
         }
+        if (rptTpl[JV.NODE_INTERACTION_PARAMS]) {
+            for (let i = 0; i < rptTpl[JV.NODE_INTERACTION_PARAMS].length; i++) {
+                me.createSingle(rptTpl[JV.NODE_INTERACTION_PARAMS][i], JpcParamResult[JV.NODE_INTERACTION_PARAMS], rptTpl, i);
+            }
+        }
         return JpcParamResult;
     },
-    createSingle: function(paramNode, parentObj, rptTpl, sequence) {
+    createSingle(paramNode, parentObj, rptTpl, sequence, isInterAct = false) {
         if (paramNode && paramNode[JV.PROP_ID]) {
             const item = {};
             item[JV.PROP_ID] = paramNode[JV.PROP_ID];
@@ -32,6 +37,7 @@ const JpcParam = {
             item[JV.PROP_DATA_TYPE] = paramNode[JV.PROP_DATA_TYPE];
             if (paramNode[JV.PROP_DFT_VALUE]) item[JV.PROP_DFT_VALUE] = paramNode[JV.PROP_DFT_VALUE];
             item.DataSeq = sequence;
+            item.isInterAction = isInterAct;
             parentObj[JV.PROP_ID + '_' + paramNode[JV.PROP_ID]] = item;
         }
     },

+ 9 - 0
app/reports/rpt_component/jpc_rte.js

@@ -38,6 +38,8 @@ const JE = {
             rst = $CURRENT_RPT.params[JV.NODE_DYNAMIC_DATE_PARAMS][JV.PROP_ID + '_' + pID];
         } else if ($CURRENT_RPT && $CURRENT_RPT.params[JV.NODE_SIGNATURE_AUDIT_PARAMS] && $CURRENT_RPT.params[JV.NODE_SIGNATURE_AUDIT_PARAMS][JV.PROP_ID + '_' + pID]) {
             rst = $CURRENT_RPT.params[JV.NODE_SIGNATURE_AUDIT_PARAMS][JV.PROP_ID + '_' + pID];
+        } else if ($CURRENT_RPT && $CURRENT_RPT.params[JV.NODE_INTERACTION_PARAMS] && $CURRENT_RPT.params[JV.NODE_INTERACTION_PARAMS][JV.PROP_ID + '_' + pID]) {
+            rst = $CURRENT_RPT.params[JV.NODE_INTERACTION_PARAMS][JV.PROP_ID + '_' + pID];
         } else {
             rst = { msg: 'the Param-ID is not valid, no result was found!' };
         }
@@ -203,6 +205,13 @@ const JE = {
         }
         return rst;
     },
+    isInterActionParam(pID, $CURRENT_RPT) {
+        let rst = false;
+        if ($CURRENT_RPT.params[JV.NODE_INTERACTION_PARAMS]) {
+            rst = $CURRENT_RPT.params[JV.NODE_INTERACTION_PARAMS][JV.PROP_ID + '_' + pID] !== undefined;
+        }
+        return rst;
+    },
 };
 
 module.exports = JE;

+ 2 - 0
app/reports/rpt_component/jpc_value_define.js

@@ -16,6 +16,7 @@ module.exports = {
     NODE_SIGNATURE_FIELDS: '电子签名离散指标_集合',
     NODE_DYNAMIC_DATE_PARAMS: '动态日期离散参数_集合',
     NODE_SIGNATURE_AUDIT_PARAMS: '电子签名审核意见指标_集合',
+    NODE_INTERACTION_PARAMS: '动态交互指标_集合',
     NODE_DISCRETE_PARAMS: '离散参数_集合',
     NODE_MASTER_FIELDS: '主数据指标_集合',
     NODE_MASTER_FIELDS_EX: '主数据指标_拓展集合',
@@ -323,6 +324,7 @@ module.exports = {
     PROP_SIGNATURE_CELLS: 'signature_cells',
     PROP_SIGNATURE_DATE_CELLS: 'signature_date_cells',
     PROP_SIGNATURE_AUDIT_CELLS: 'signature_audit_cells',
+    PROP_INTERACT_CELLS: 'interact_cells',
 
     PAGING_OPTION_NORMAL: 'normal',
     PAGING_OPTION_INFINITY: 'infinity',

+ 20 - 3
app/reports/util/rpt_excel_util.js

@@ -359,6 +359,7 @@ function _setupPgBrks(pageData) {
         _insertMaxBottom(page[JV.PROP_SIGNATURE_CELLS], maxBottomArr);
         _insertMaxBottom(page[JV.PROP_SIGNATURE_DATE_CELLS], maxBottomArr);
         _insertMaxBottom(page[JV.PROP_SIGNATURE_AUDIT_CELLS], maxBottomArr);
+        _insertMaxBottom(page[JV.PROP_INTERACT_CELLS], maxBottomArr);
         _insertMaxBottom(page[JV.PROP_WATERMARK_CELLS], maxBottomArr, true);
         pgBrkIdx += maxBottomArr.length;
         pgBrk.push(pgBrkIdx);
@@ -520,6 +521,10 @@ function preAnalyzePos(pageData, sheetData, xPos, yPos, yMultiPos) {
             cell = theShtData[JV.PROP_SIGNATURE_AUDIT_CELLS][i];
             private_set_cell_pos(cell, theXPos, theYPos);
         }
+        for (let i = 0; i < theShtData[JV.PROP_INTERACT_CELLS].length; i++) {
+            cell = theShtData[JV.PROP_INTERACT_CELLS][i];
+            private_set_cell_pos(cell, theXPos, theYPos);
+        }
         for (let i = 0; i < theShtData[JV.PROP_WATERMARK_CELLS].length; i++) {
             cell = theShtData[JV.PROP_WATERMARK_CELLS][i];
             // private_set_cell_pos(cell, theXPos, theYPos);
@@ -849,6 +854,7 @@ function writeSheet(pageData, sheetData, paperSize, sharedStrList, stylesObj, ap
             self_setMergedCells(sheetData[JV.PROP_CELLS], yPos, 0);
             if (sheetData[JV.PROP_SIGNATURE_DATE_CELLS]) self_setMergedCells(sheetData[JV.PROP_SIGNATURE_DATE_CELLS], yPos, 0);
             if (sheetData[JV.PROP_SIGNATURE_AUDIT_CELLS]) self_setMergedCells(sheetData[JV.PROP_SIGNATURE_AUDIT_CELLS], yPos, 0);
+            if (sheetData[JV.PROP_INTERACT_CELLS]) self_setMergedCells(sheetData[JV.PROP_INTERACT_CELLS], yPos, 0);
         } else {
             let osY = 0;
             for (let i = 0; i < pageData.items.length; i++) {
@@ -858,6 +864,7 @@ function writeSheet(pageData, sheetData, paperSize, sharedStrList, stylesObj, ap
                 self_setMergedCells(shtItemData[JV.PROP_CELLS], tmpPos, osY);
                 if (shtItemData[JV.PROP_SIGNATURE_DATE_CELLS]) self_setMergedCells(shtItemData[JV.PROP_SIGNATURE_DATE_CELLS], tmpPos, osY);
                 if (shtItemData[JV.PROP_SIGNATURE_AUDIT_CELLS]) self_setMergedCells(shtItemData[JV.PROP_SIGNATURE_AUDIT_CELLS], tmpPos, osY);
+                if (shtItemData[JV.PROP_INTERACT_CELLS]) self_setMergedCells(shtItemData[JV.PROP_INTERACT_CELLS], tmpPos, osY);
                 osY += tmpPos.length - 2;
             }
         }
@@ -927,9 +934,8 @@ function writeSheet(pageData, sheetData, paperSize, sharedStrList, stylesObj, ap
             self_create_cell(theShtData[JV.PROP_CELLS], rows, theYPos);
             self_create_cell(theShtData[JV.PROP_SIGNATURE_DATE_CELLS], rows, theYPos);
             self_create_cell(theShtData[JV.PROP_SIGNATURE_AUDIT_CELLS], rows, theYPos);
+            self_create_cell(theShtData[JV.PROP_INTERACT_CELLS], rows, theYPos);
             // fsUtil.writeObjToFile(newPageData, 'D:/GitHome/ConstructionOperation/tmp/combinedHeader.js');
-            // console.log('theShtData[JV.PROP_SIGNATURE_AUDIT_CELLS]: ');
-            // console.log(theShtData[JV.PROP_SIGNATURE_AUDIT_CELLS]);
 
             // 3. then fill up rst
             for (let i = 0; i < rows.length; i++) {
@@ -1331,6 +1337,9 @@ function createDummySignatureCell(pageData) {
         if (page[JV.PROP_SIGNATURE_AUDIT_CELLS] && page[JV.PROP_SIGNATURE_AUDIT_CELLS].length > 0) {
             _createDummyCell(page[JV.PROP_SIGNATURE_AUDIT_CELLS], page);
         }
+        if (page[JV.PROP_INTERACT_CELLS] && page[JV.PROP_INTERACT_CELLS].length > 0) {
+            _createDummyCell(page[JV.PROP_INTERACT_CELLS], page);
+        }
     }
 }
 
@@ -1827,7 +1836,9 @@ module.exports = {
                     checkAndResetCellYPos(pageDataArray[i].items[j][JV.PROP_SIGNATURE_DATE_CELLS]);
                     // 1.2.4 重置电子签名审核意见cells的Top Bottom坐标
                     checkAndResetCellYPos(pageDataArray[i].items[j][JV.PROP_SIGNATURE_AUDIT_CELLS]);
-                    // 1.2.5 重置水印的Top Bottom坐标
+                    // 1.2.5 重置交互cells的Top Bottom坐标
+                    checkAndResetCellYPos(pageDataArray[i].items[j][JV.PROP_INTERACT_CELLS]);
+                    // 1.2.6 重置水印的Top Bottom坐标
                     checkAndResetCellYPos(pageDataArray[i].items[j][JV.PROP_WATERMARK_CELLS]);
 
                     const bottomGap = Math.round((pageDataArray[i][JV.NODE_PAGE_INFO][JV.NODE_PAGE_SIZE][1] - parseFloat(pageDataArray[i][JV.NODE_PAGE_INFO][JV.NODE_MARGINS][JV.PROP_BOTTOM]) / 2.54) * DPI) - maxY;
@@ -1867,6 +1878,12 @@ module.exports = {
                         pageItem[JV.PROP_SIGNATURE_AUDIT_CELLS].push(pageDataArray[i].items[j][JV.PROP_SIGNATURE_AUDIT_CELLS][k]);
                     }
                 }
+                pageItem[JV.PROP_INTERACT_CELLS] = [];
+                for (let j = 0; j < pageDataArray[i].items.length; j++) {
+                    for (let k = 0; k < pageDataArray[i].items[j][JV.PROP_INTERACT_CELLS].length; k++) {
+                        pageItem[JV.PROP_INTERACT_CELLS].push(pageDataArray[i].items[j][JV.PROP_INTERACT_CELLS][k]);
+                    }
+                }
                 pageItem[JV.PROP_WATERMARK_CELLS] = [];
                 for (let j = 0; j < pageDataArray[i].items.length; j++) {
                     for (let k = 0; k < pageDataArray[i].items[j][JV.PROP_WATERMARK_CELLS].length; k++) {