|
|
@@ -15,6 +15,7 @@
|
|
|
<view class="todayCheckIn" v-if="todayInfoShow">
|
|
|
<view class="check-in-container">
|
|
|
<text class="todayAttTitle">今日签到信息</text>
|
|
|
+ <text class="exceptionText" v-if="lackCardState" @click="toBuKa">处理异常</text>
|
|
|
<view class="info-row">
|
|
|
<view>
|
|
|
<text class="ygoa-icon icon-date"></text>
|
|
|
@@ -142,9 +143,11 @@
|
|
|
|
|
|
<script setup lang="ts">
|
|
|
import {ref,onMounted,reactive} from 'vue';
|
|
|
+ import { getProcessList } from '@/api/work.js'
|
|
|
import {checkAttendance,getMyTotalCount,getMyQDQtAttendance,getMyTotalMonthCount} from '@/api/mine.js'
|
|
|
import {useUserStore} from '@/store/user.js';
|
|
|
import { useConfigStore } from '@/store/config'
|
|
|
+ import $tab from '@/plugins/tab.js'
|
|
|
const userStore = useUserStore();
|
|
|
//考勤规则数据
|
|
|
const configStore = useConfigStore();
|
|
|
@@ -312,7 +315,6 @@
|
|
|
}
|
|
|
getCalenderData(params)
|
|
|
}
|
|
|
-
|
|
|
//日历数据的刷新
|
|
|
function getCalenderData(params){
|
|
|
getMyQDQtAttendance(params).then(({ returnParams }) => {
|
|
|
@@ -330,14 +332,26 @@
|
|
|
calenderData.value=thisCalenderData
|
|
|
})
|
|
|
}
|
|
|
-
|
|
|
+
|
|
|
+ const lackCardState=ref(false)//缺卡异常处理状态
|
|
|
//日历点击日期切换事件
|
|
|
function changeDate(e) {
|
|
|
// console.log('changeDate: ',e);
|
|
|
// console.log("3:calenderData.value " + JSON.stringify(calenderData.value));
|
|
|
+ lackCardState.value = !!e.extraInfo.info;//!!转布尔值
|
|
|
todayData.day = e.fulldate
|
|
|
getDayAttData()
|
|
|
}
|
|
|
+
|
|
|
+ //补卡页面跳转
|
|
|
+ function toBuKa(){
|
|
|
+ const bukaType=todayData.startTime?'下班':'上班'
|
|
|
+ getProcessList(userStore.user.useId, userStore.user.unitId).then(res => {
|
|
|
+ const { modelName, modelId, control } = res.returnParams.fList.find(item => item.modelName === "补卡申请")
|
|
|
+ $tab.navigateTo('/pages/work/edit/index?modelName=' + modelName + '&modelId=' + modelId + '&control=' + control+'&bukaDate='+todayData.day+'&bukaType='+bukaType)
|
|
|
+ })
|
|
|
+ // $tab.switchTab('/pages/work/index?bukaDate='+todayData.day+'&bukaType='+bukaType)
|
|
|
+ }
|
|
|
|
|
|
//传入年份月份,返回此月天数
|
|
|
function getDaysInMonth(year, month) {
|
|
|
@@ -811,6 +825,14 @@
|
|
|
flex-direction: column;
|
|
|
align-items: center;
|
|
|
justify-content: center;
|
|
|
+ position: relative;
|
|
|
+ .exceptionText{
|
|
|
+ position: absolute;
|
|
|
+ top: 10px;
|
|
|
+ right: 10px;
|
|
|
+ color: blue;
|
|
|
+ text-decoration: underline;
|
|
|
+ }
|
|
|
}
|
|
|
|
|
|
.todayAttTitle {
|