From df45b7b837c110694f0579f74f8656b0fc7785b3 Mon Sep 17 00:00:00 2001 From: jiangyong27 Date: Fri, 18 Aug 2023 18:33:48 +0800 Subject: [PATCH] onduty exception --- worker/autopay.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/worker/autopay.go b/worker/autopay.go index 6f0d41a..e90c4a7 100644 --- a/worker/autopay.go +++ b/worker/autopay.go @@ -21,6 +21,7 @@ var ( ) func NotifyCheckinOnDuty(checkin *model.Checkin) { + message := make([]string, 0) message = append(message, "【上班提醒】") message = append(message, fmt.Sprintf("员工名称:%s", checkin.Username)) @@ -40,7 +41,7 @@ func NotifyCheckinOnDuty(checkin *model.Checkin) { return } - if isOndutyPay(checkin, userConfig) { + if isOndutyPay(checkin, userConfig) && checkin.Exception != "" { payMoney := cast.ToInt64(userConfig.Get(model.CheckinOndutyMoney)) if payMoney == 0 { payMoney = 2000