|
@@ -205,6 +205,23 @@ let calcTools = {
|
|
treeNode.data.gljList = projectObj.project.ration_glj.getGatherGljArrByRations(rations, needOneBill, q);
|
|
treeNode.data.gljList = projectObj.project.ration_glj.getGatherGljArrByRations(rations, needOneBill, q);
|
|
};
|
|
};
|
|
},
|
|
},
|
|
|
|
+ getLeafBills: function (treeNode){
|
|
|
|
+ let leafBills = [];
|
|
|
|
+
|
|
|
|
+ function getBill(node){
|
|
|
|
+ if (!node) return;
|
|
|
|
+ if (calcTools.isLeafBill(node))
|
|
|
|
+ leafBills.push(node);
|
|
|
|
+
|
|
|
|
+ if (node.firstChild()) getBill(node.firstChild());
|
|
|
|
+ if (node.nextSibling) getBill(node.nextSibling);
|
|
|
|
+ };
|
|
|
|
+
|
|
|
|
+ let fc = treeNode.firstChild();
|
|
|
|
+ if (fc) getBill(fc);
|
|
|
|
+
|
|
|
|
+ return leafBills;
|
|
|
|
+ },
|
|
|
|
|
|
initFees: function (treeNode){
|
|
initFees: function (treeNode){
|
|
if (!treeNode.data.fees) {
|
|
if (!treeNode.data.fees) {
|