展示考勤人脸

This commit is contained in:
Your Name 2023-01-31 02:13:26 +08:00
parent 3025f5aa43
commit 99b9501c61
4 changed files with 18 additions and 7 deletions

View File

@ -1,4 +1,4 @@
<div id="todayAttendanceDetailModel" class="modal fade" tabindex="-1" role="dialog" aria-labelledby="todayAttendanceDetailModelLabel" aria-hidden="true">
<div id="todayAttendanceDetailModel" class="modal fade" role="dialog" aria-labelledby="todayAttendanceDetailModelLabel" aria-hidden="true">
<div class="modal-dialog modal-lg">
<div class="modal-content">
<div class="modal-header">
@ -34,10 +34,8 @@
<td class="text-center">{{detail.stateName}}</td>
<td class="text-center">{{detail.checkTime || '未打卡' }} </td>
<td class="text-right ">
<span v-for="_photo in detail.photos">
<img style="width: 60px; height: 60px;" v-bind:src="_photo.url"
v-on:click="openFile(_photo)">
</span>
<img style="width: 60px; height: 60px;" v-if="detail.facePath" v-bind:src="detail.facePath"
v-on:click="openFile(detail)">
</td>
</tr>
</tbody>

View File

@ -23,7 +23,7 @@
},
openFile: function (_photo) {
vc.emit('viewImage', 'showImage', {
url: _photo.url
url: _photo.facePath
});
}
}

View File

@ -70,6 +70,9 @@
<table class="footable table table-stripped toggle-arrow-tiny" data-page-size="15">
<thead>
<tr>
<th class="text-center">
<span><vc:i18n name="人脸" namespace="attendanceLogManage"></vc:i18n></span>
</th>
<th class="text-center">
<span><vc:i18n name="部门名称" namespace="attendanceLogManage"></vc:i18n></span>
</th>
@ -86,6 +89,10 @@
</thead>
<tbody>
<tr v-for="attendance in attendanceLogManageInfo.attendances">
<td class="text-center" style="white-space: nowrap;">
<img style="width: 60px; height: 60px;" class="border-radius" v-if="attendance.facePath" v-bind:src="attendance.facePath" v-on:click="_viewOwnerFace(attendance.facePath)" />
<img style="width: 60px; height: 60px;" class="border-radius" v-else src="/img/noPhoto.jpg" />
</td>
<td class="text-center">{{attendance.departmentName}}</td>
<td class="text-center">{{attendance.staffName}}</td>
<td class="text-center">{{attendance.staffId}}</td>
@ -106,4 +113,5 @@
</div>
</div>
</div>
<vc:create path="common/viewImage"></vc:create>
</div>

View File

@ -99,7 +99,12 @@
} else {
vc.component.attendanceLogManageInfo.moreCondition = true;
}
}
},
_viewOwnerFace: function(_url) {
vc.emit('viewImage', 'showImage', {
url: _url
});
},
}
});
})(window.vc);