|
|
@@ -195,7 +195,15 @@ function initQueryEmp(parent_dept_id, dept_id) {
|
|
|
function getEmployeeInfosClick(url, param, start_score, end_score, start_num, end_num) {
|
|
|
post_common_service(url, param, function(data) {
|
|
|
|
|
|
- // console.log(data)
|
|
|
+
|
|
|
+ var userChangeStations = data["userChangeStations"];
|
|
|
+ var userChangeStationMap = new HashMap();
|
|
|
+ for (var i in userChangeStations) {
|
|
|
+ var s = userChangeStations[i];
|
|
|
+ userChangeStationMap.set(s.userid, s);
|
|
|
+ }
|
|
|
+
|
|
|
+ data = data["lists"];
|
|
|
|
|
|
var strTbody = '';
|
|
|
var count = 0;
|
|
|
@@ -226,10 +234,26 @@ function getEmployeeInfosClick(url, param, start_score, end_score, start_num, en
|
|
|
html += "<button id=\"user_" + data[i].user.id + "\" onClick='addTask(" + data[i].user.id + ",\"" + data[i].user.truename + "\",\"" + data[i].user.fee_station_name + "\",\"" + data[i].checked_num + "\",\"" + param.start_date + "\",\"" + param.end_date + "\")' class=\"btn\" style='margin-left: 10px;padding: 0px;border: 0;background: none;' type=\"button\"><i class=\"icon icon-plus-sign\"></i></button>"
|
|
|
}
|
|
|
}
|
|
|
+
|
|
|
+ var userChangeStation = userChangeStationMap.get(data[i].user.id);
|
|
|
+ var ischage = false;
|
|
|
+ var tiptext = "";
|
|
|
+ if (userChangeStation != null) {
|
|
|
+ ischage = true;
|
|
|
+ tiptext = userChangeStation.old_dept_name + ":" + userChangeStation.old_dept_check_num + "次," +
|
|
|
+ userChangeStation.new_dept_name + ":" + userChangeStation.new_dept_check_num + "次";
|
|
|
+ }
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
var showNumberHtml = (isshownumber ? (filter(data[i].checked_num, '0') + (data[i].checked_num < 6 ? html : "")) : "-");
|
|
|
- if (hasRole(ROLE_ADMIN)){
|
|
|
- showNumberHtml = filter(data[i].checked_num, '0')+html;
|
|
|
+ if (hasRole(ROLE_ADMIN)) {
|
|
|
+ showNumberHtml = (ischage ? ("<span style='color:red;' data-toggle='tooltip' data-placement='right' title=" + tiptext + ">" + userChangeStation.old_dept_check_num + "+" + userChangeStation.new_dept_check_num + "</span>") : filter(data[i].checked_num, '0')) + html;
|
|
|
}
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
strTbody += "<tr><td width='4%;'>" + (count + 1) + "</td><td width='6%;'>" + data[i].user.fee_station_name + "</td>" +
|
|
|
"<td width='6%;'><a href='JavaScript:void(0)' onclick='jumpuser(\"" + data[i].user.id + "\",\"" + data[i].user.organid + "\")'>" + data[i].user.truename + "</a></td><td width='6%;'>" + data[i].user.position_name + "</td>" +
|
|
|
"<td width='7%;'>" + data[i].user.workno + "</td><td width='4%;'>" + filter(data[i].company_ranking, '/') + "</td>" +
|
|
|
@@ -245,6 +269,7 @@ function getEmployeeInfosClick(url, param, start_score, end_score, start_num, en
|
|
|
}
|
|
|
}
|
|
|
$(".table-tbody").append(strTbody);
|
|
|
+ $('[data-toggle="tooltip"]').tooltip();
|
|
|
$("tr:gt(1):odd").css("background", "#EFEFEF");
|
|
|
}, function(error) {
|
|
|
return "";
|