Browse Source

합계행 중복제거하여 카운트 되도록

SH 8 months ago
parent
commit
8616b28be5
1 changed files with 16 additions and 2 deletions
  1. 16 2
      src/main/webapp/ux/cw/cw0606/CW06060001U.xml

+ 16 - 2
src/main/webapp/ux/cw/cw0606/CW06060001U.xml

@@ -673,6 +673,20 @@
 	        });
         }
 	};
+
+	scwin.people = function() {
+		//var jsonData = dcdataList1.getMatchedJSON("empNo", targetCol);
+		var jsonData = dcdataList1.getAllJSON();
+		var returnData = [];
+		//debugger;
+		for ( var index in jsonData) {
+			if (returnData.indexOf(jsonData[index].empNo) < 0) {
+				returnData.push(jsonData[index].empNo);
+			}
+		}
+
+		return returnData.length;
+	};
     ]]></script>
 	</head>
 	<body>
@@ -1024,7 +1038,7 @@
 									blockSelect="false" displayMode="label">
 								</w2:column>
 								<w2:column removeBorderStyle="false" width="100" inputType="expression" style="" id="pointTotal" value=""
-									blockSelect="false" displayMode="label" expression="Math.ceil(count('empNo')*3.1)" dataType="number" displayFormat="#,###[ceil]">
+									blockSelect="false" displayMode="label" expression="Math.ceil(scwin.people()*3.1)" dataType="number" displayFormat="#,###[ceil]">
 								</w2:column>
 								<w2:column removeBorderStyle="false" width="100" inputType="text" style="" id="column16" value=""
 									blockSelect="false" displayMode="label">
@@ -1054,7 +1068,7 @@
 									blockSelect="false" displayMode="label">
 								</w2:column>
 								<w2:column removeBorderStyle="false" width="100" inputType="expression" style="" id="pointCal" value=""
-									blockSelect="false" displayMode="label" expression="Math.ceil(count('empNo')*3.1)-sum('evalPoint')" dataType="number">
+									blockSelect="false" displayMode="label" expression="Math.ceil(scwin.people()*3.1)-sum('evalPoint')" dataType="number">
 								</w2:column>
 								<w2:column removeBorderStyle="false" width="100" inputType="text" style="" id="column24" value=""
 									blockSelect="false" displayMode="label">