diff --git a/web-admin/weight-management/action-record.html b/web-admin/weight-management/action-record.html
index 61d51ed..0c76fe3 100644
--- a/web-admin/weight-management/action-record.html
+++ b/web-admin/weight-management/action-record.html
@@ -1046,7 +1046,7 @@ tbody tr:hover td:nth-child(4){background:#F8FBFF;}
- | 序号 | 活动名称 | 姓名 | 员工编号 | 单位 | 部门 | 体重记录 | 饮食记录 | 运动记录 | 三测完成 |
+ | 序号 | 活动名称 | 姓名 | 员工编号 | 单位 | 部门 | 体重记录 | 体脂记录 | 腰围记录 | 三测完成 |
@@ -2967,10 +2967,9 @@ function openUnitDetailDialog(org, type){
measureData.weight.forEach(function(w,i){
if(w.org !== org) return;
if(selectedPlanId && w.planId !== selectedPlanId) return;
- var dRec = measureData.diet[i], exRec = measureData.exercise[i];
var key = w.empId;
if(!empMap[key]){
- empMap[key] = {planName:w.planName,name:w.name,empId:w.empId,org:w.org,dept:w.dept,hasWeight:false,hasDiet:false,hasExercise:false};
+ empMap[key] = {planName:w.planName,name:w.name,empId:w.empId,org:w.org,dept:w.dept,hasWeight:false,hasFat:false,hasWaist:false};
}
function inRange(rec){
if(!rec.hasRecord) return false;
@@ -2978,12 +2977,17 @@ function openUnitDetailDialog(org, type){
if(dateTo && rec.firstDate > dateTo) return false;
return true;
}
- if(inRange(w)) empMap[key].hasWeight = true;
- if(inRange(dRec)) empMap[key].hasDiet = true;
- if(inRange(exRec)) empMap[key].hasExercise = true;
+ // 三测 = 体重/体脂/腰围,均来自体重测量记录;是否含体脂/腰围取决于记录来源
+ if(inRange(w)){
+ empMap[key].hasWeight = true;
+ // 蓝牙称只有体重;身高称缺体脂;体脂仪/体重秤/自记数据完整
+ if(w.source !== '蓝牙称' && w.source !== '身高称') empMap[key].hasFat = true;
+ if(w.source === '体脂仪' || w.source === '自记') empMap[key].hasWaist = true;
+ }
});
var empList = [];
- for(var k in empMap){ empMap[k].allDone = empMap[k].hasWeight && empMap[k].hasDiet && empMap[k].hasExercise; empList.push(empMap[k]); }
+ // 体重/体脂/腰围中有任一项记录即视为三测完成
+ for(var k in empMap){ empMap[k].allDone = empMap[k].hasWeight || empMap[k].hasFat || empMap[k].hasWaist; empList.push(empMap[k]); }
// 三测人数弹窗只显示三测完成的员工
if(type === 'measured'){ empList = empList.filter(function(e){ return e.allDone; }); }
var tbody = document.getElementById('unitDetailTbody');
@@ -3000,9 +3004,9 @@ function openUnitDetailDialog(org, type){
html += ''+esc(e.org)+' | ';
html += ''+esc(e.dept)+' | ';
html += ''+(e.hasWeight?'●':'○')+' | ';
- html += ''+(e.hasDiet?'●':'○')+' | ';
- html += ''+(e.hasExercise?'●':'○')+' | ';
- html += ''+(e.allDone?'是':'否')+' | ';
+ html += ''+(e.hasFat?'●':'○')+' | ';
+ html += ''+(e.hasWaist?'●':'○')+' | ';
+ html += ''+(e.allDone?'是':'否')+' | ';
html += '';
});
tbody.innerHTML = html;
diff --git a/web-admin/weight-management/bluetooth-device-add.html b/web-admin/weight-management/bluetooth-device-add.html
index a5ef9e2..ac0d008 100644
--- a/web-admin/weight-management/bluetooth-device-add.html
+++ b/web-admin/weight-management/bluetooth-device-add.html
@@ -137,7 +137,7 @@
-
+