|
@@ -10,7 +10,7 @@
|
|
</SearchForm>
|
|
</SearchForm>
|
|
|
|
|
|
<div class="flex-1 page-wrap">
|
|
<div class="flex-1 page-wrap">
|
|
- <p class="page-wrap-tips">
|
|
|
|
|
|
+ <p v-if="statisticsInfo" class="page-wrap-tips">
|
|
<t-space :size="0">
|
|
<t-space :size="0">
|
|
<span>
|
|
<span>
|
|
<ErrorCircleFilledIcon /> 考勤总计:{{ statisticsInfo.total }}
|
|
<ErrorCircleFilledIcon /> 考勤总计:{{ statisticsInfo.total }}
|
|
@@ -55,7 +55,7 @@
|
|
</template>
|
|
</template>
|
|
|
|
|
|
<script setup name="WorkAttendanceDetail">
|
|
<script setup name="WorkAttendanceDetail">
|
|
-import { reactive, ref } from 'vue';
|
|
|
|
|
|
+import { reactive, ref, computed } from 'vue';
|
|
import { omit } from 'lodash';
|
|
import { omit } from 'lodash';
|
|
import { ErrorCircleFilledIcon } from 'tdesign-icons-vue-next';
|
|
import { ErrorCircleFilledIcon } from 'tdesign-icons-vue-next';
|
|
|
|
|
|
@@ -119,7 +119,7 @@ const fields = ref([
|
|
prop: 'supplierId',
|
|
prop: 'supplierId',
|
|
label: '所属供应商',
|
|
label: '所属供应商',
|
|
type: 'select',
|
|
type: 'select',
|
|
- labelWidth: 120,
|
|
|
|
|
|
+ labelWidth: 100,
|
|
colSpan: 5,
|
|
colSpan: 5,
|
|
cell: 'supplier',
|
|
cell: 'supplier',
|
|
},
|
|
},
|
|
@@ -144,22 +144,23 @@ const fields = ref([
|
|
{
|
|
{
|
|
prop: 'abnormal',
|
|
prop: 'abnormal',
|
|
type: 'number',
|
|
type: 'number',
|
|
- label: '考勤异常数>',
|
|
|
|
- labelWidth: 120,
|
|
|
|
|
|
+ label: '考勤异常数',
|
|
|
|
+ labelWidth: 100,
|
|
colSpan: 5,
|
|
colSpan: 5,
|
|
attrs: {
|
|
attrs: {
|
|
theme: 'column',
|
|
theme: 'column',
|
|
decimalPlaces: 0,
|
|
decimalPlaces: 0,
|
|
max: 1000000,
|
|
max: 1000000,
|
|
min: 0,
|
|
min: 0,
|
|
- style: 'width: 120px',
|
|
|
|
|
|
+ style: 'width: 100%',
|
|
|
|
+ label: '>',
|
|
},
|
|
},
|
|
},
|
|
},
|
|
{
|
|
{
|
|
prop: 'type',
|
|
prop: 'type',
|
|
- type: 'number',
|
|
|
|
|
|
+ type: 'select',
|
|
label: '考勤类型',
|
|
label: '考勤类型',
|
|
- labelWidth: 120,
|
|
|
|
|
|
+ labelWidth: 100,
|
|
colSpan: 5,
|
|
colSpan: 5,
|
|
options: dictToOptionList(ATTENDANCE_TYPE),
|
|
options: dictToOptionList(ATTENDANCE_TYPE),
|
|
attrs: {
|
|
attrs: {
|
|
@@ -168,9 +169,9 @@ const fields = ref([
|
|
},
|
|
},
|
|
{
|
|
{
|
|
prop: 'status',
|
|
prop: 'status',
|
|
- type: 'number',
|
|
|
|
|
|
+ type: 'select',
|
|
label: '考勤结果',
|
|
label: '考勤结果',
|
|
- labelWidth: 120,
|
|
|
|
|
|
+ labelWidth: 100,
|
|
colSpan: 5,
|
|
colSpan: 5,
|
|
options: dictToOptionList(ATTENDANCE_RESULT),
|
|
options: dictToOptionList(ATTENDANCE_RESULT),
|
|
attrs: {
|
|
attrs: {
|
|
@@ -197,19 +198,19 @@ const computedParams = computed(() => {
|
|
});
|
|
});
|
|
|
|
|
|
const columns = [
|
|
const columns = [
|
|
- { colKey: 'service', title: '服务单元' },
|
|
|
|
- { colKey: 'sopNo', title: 'SOP流水号' },
|
|
|
|
- { colKey: 'custom', title: '客户名称' },
|
|
|
|
- { colKey: 'province', title: '省份', minWidth: 60 },
|
|
|
|
- { colKey: 'city', title: '城市', minWidth: 60 },
|
|
|
|
- { colKey: 'userName', title: '姓名', width: 150 },
|
|
|
|
- { colKey: 'roleName', title: '项目角色' },
|
|
|
|
- { colKey: 'supplier', title: '所属供应商' },
|
|
|
|
- { colKey: 'signDate', title: '考勤日期', width: 120 },
|
|
|
|
- { colKey: 'type', title: '考勤类型', cell: 'type', width: 80 },
|
|
|
|
- { colKey: 'signTime', title: '打卡时间', cell: 'sign-time', width: 170 },
|
|
|
|
- { colKey: 'address', title: '打卡地址' },
|
|
|
|
- { colKey: 'status', title: '考勤结果', cell: 'status', width: 80 },
|
|
|
|
|
|
+ { colKey: 'service', title: '服务单元', width: 140 },
|
|
|
|
+ { colKey: 'sopNo', title: 'SOP流水号', width: 200 },
|
|
|
|
+ { colKey: 'custom', title: '客户名称', width: 140 },
|
|
|
|
+ { colKey: 'province', title: '省份', minWidth: 100 },
|
|
|
|
+ { colKey: 'city', title: '城市', minWidth: 100 },
|
|
|
|
+ { colKey: 'userName', title: '姓名', width: 140 },
|
|
|
|
+ { colKey: 'roleName', title: '项目角色', width: 140 },
|
|
|
|
+ { colKey: 'supplier', title: '所属供应商', width: 140 },
|
|
|
|
+ { colKey: 'signDate', title: '考勤日期', width: 180 },
|
|
|
|
+ { colKey: 'type', title: '考勤类型', cell: 'type', width: 100 },
|
|
|
|
+ { colKey: 'signTime', title: '打卡时间', cell: 'sign-time', width: 180 },
|
|
|
|
+ { colKey: 'address', title: '打卡地址', minWidth: 200 },
|
|
|
|
+ { colKey: 'status', title: '考勤结果', cell: 'status', width: 100 },
|
|
];
|
|
];
|
|
const { pagination, tableData, search, onChange } = useFetchTable(
|
|
const { pagination, tableData, search, onChange } = useFetchTable(
|
|
workAttendanceDetailListApi,
|
|
workAttendanceDetailListApi,
|
|
@@ -217,9 +218,11 @@ const { pagination, tableData, search, onChange } = useFetchTable(
|
|
params: computedParams,
|
|
params: computedParams,
|
|
}
|
|
}
|
|
);
|
|
);
|
|
-let statisticsInfo = ref({});
|
|
|
|
|
|
+let statisticsInfo = ref(null);
|
|
const getStatisticsInfo = async () => {
|
|
const getStatisticsInfo = async () => {
|
|
- const res = await workStatisticsDetailInfoApi(params);
|
|
|
|
- statisticsInfo.value = res || {};
|
|
|
|
|
|
+ const res = await workStatisticsDetailInfoApi(computedParams.value).catch(
|
|
|
|
+ () => {}
|
|
|
|
+ );
|
|
|
|
+ statisticsInfo.value = res || null;
|
|
};
|
|
};
|
|
</script>
|
|
</script>
|