|
@@ -260,7 +260,8 @@ class StatisticsService extends CrudService {
|
|
else if (!start) obj.name = `${end}岁以下`;
|
|
else if (!start) obj.name = `${end}岁以下`;
|
|
else if (!end) obj.name = `${start}岁以上`;
|
|
else if (!end) obj.name = `${start}岁以上`;
|
|
const l = list.filter(f => {
|
|
const l = list.filter(f => {
|
|
- const age = _.get(f, 'student_id.age');
|
|
|
|
|
|
+ const birth = _.get(f, 'sstudent_id.birth');
|
|
|
|
+ const age = moment().diff(birth, 'years');
|
|
if (start && end) return age >= start && age <= end;
|
|
if (start && end) return age >= start && age <= end;
|
|
else if (!start) return age <= end;
|
|
else if (!start) return age <= end;
|
|
else if (!end) return age >= start;
|
|
else if (!end) return age >= start;
|