Commit 969ff9d1 authored by 廖旭伟's avatar 廖旭伟

Merge remote-tracking branch 'origin/master'

parents f67db33a cdd4bc61
......@@ -100,7 +100,7 @@
>
</el-switch>
</div>
<div class="history">
<!-- <div class="history">
<span>其他授权:</span>
<el-switch
:active-value="1"
......@@ -108,7 +108,7 @@
v-model="form.otherCheck"
>
</el-switch>
</div>
</div> -->
</div>
<form-buttons
......
......@@ -174,16 +174,50 @@
<profiles.hik.protocol>https://</profiles.hik.protocol>
<profiles.hik.appKey>25594054</profiles.hik.appKey>
<profiles.hik.appSecret>K12IkZoSLxpsJjrUPtfV</profiles.hik.appSecret>
<profiles.dingtalk.domain>https://oapi.dingtalk.com</profiles.dingtalk.domain>
<profiles.dingtalk.oaScheme>https</profiles.dingtalk.oaScheme>
<profiles.dingtalk.oaUrl>api.dingtalk.com</profiles.dingtalk.oaUrl>
<profiles.dingtalk.oaScheme>https</profiles.dingtalk.oaScheme>
<profiles.dingtalk.agentId>2652674890</profiles.dingtalk.agentId>
<profiles.dingtalk.appKey>dingpqzradgfr4efdi2j</profiles.dingtalk.appKey>
<profiles.dingtalk.appSecret>bF2WALmo5_Wuj3hg5gXeWqezrYnZChUJ88HjzNWpkA9ivdOxfBDGOGYcfVRfB3vd</profiles.dingtalk.appSecret>
<profiles.dingtalk.aesKey>1QcPYuSpAc98OS3qQwwx5HPH85CZDidxF95yBGad2fJ</profiles.dingtalk.aesKey>
<profiles.dingtalk.token>m3WeuVx5kcTY76kh22uWZOTSu0XjvcwNhd</profiles.dingtalk.token>
<profiles.dingtalk.opUserId>254868153920685466</profiles.dingtalk.opUserId>
<profiles.dingtalk.domain></profiles.dingtalk.domain>
<profiles.dingtalk.oaScheme></profiles.dingtalk.oaScheme>
<profiles.dingtalk.oaUrl></profiles.dingtalk.oaUrl>
<profiles.dingtalk.oaScheme></profiles.dingtalk.oaScheme>
<profiles.dingtalk.agentId></profiles.dingtalk.agentId>
<profiles.dingtalk.appKey></profiles.dingtalk.appKey>
<profiles.dingtalk.appSecret></profiles.dingtalk.appSecret>
<profiles.dingtalk.aesKey></profiles.dingtalk.aesKey>
<profiles.dingtalk.token></profiles.dingtalk.token>
<profiles.dingtalk.opUserId></profiles.dingtalk.opUserId>
<profiles.webUrl>https://ybswxxcx.zwfwhfgjjfzj.yibin.gov.cn/performance-h5</profiles.webUrl>
<package.environment>build</package.environment>
<skipUi>false</skipUi>
</properties>
</profile>
<profile>
<id>yanyuan</id>
<properties>
<profiles.active>yanyuan</profiles.active>
<profiles.server.port>17500</profiles.server.port>
<profiles.server.debug.port>51750</profiles.server.debug.port>
<profiles.server.path>/attendance</profiles.server.path>
<profiles.publish.path>/home/publish</profiles.publish.path>
<profiles.nacos.server-addr>192.168.106.6:8848</profiles.nacos.server-addr>
<profiles.nacos.group>DEFAULT_GROUP</profiles.nacos.group>
<profiles.nacos.namespace>smart-gov</profiles.nacos.namespace>
<profiles.log.path>/home/mortals/app/logs</profiles.log.path>
<profiles.log.level>INFO</profiles.log.level>
<profiles.sms.smsSendUrl>http://sms.wx3.com.cn/api/index/index</profiles.sms.smsSendUrl>
<profiles.sms.apiId>ADsUXLrS81vZDU95</profiles.sms.apiId>
<profiles.hik.host>10.207.153.105:443</profiles.hik.host>
<profiles.hik.protocol>https://</profiles.hik.protocol>
<profiles.hik.appKey>25594054</profiles.hik.appKey>
<profiles.hik.appSecret>K12IkZoSLxpsJjrUPtfV</profiles.hik.appSecret>
<profiles.dingtalk.domain></profiles.dingtalk.domain>
<profiles.dingtalk.oaScheme></profiles.dingtalk.oaScheme>
<profiles.dingtalk.oaUrl></profiles.dingtalk.oaUrl>
<profiles.dingtalk.agentId></profiles.dingtalk.agentId>
<profiles.dingtalk.appKey></profiles.dingtalk.appKey>
<profiles.dingtalk.appSecret></profiles.dingtalk.appSecret>
<profiles.dingtalk.aesKey></profiles.dingtalk.aesKey>
<profiles.dingtalk.token></profiles.dingtalk.token>
<profiles.dingtalk.opUserId></profiles.dingtalk.opUserId>
<profiles.webUrl>https://ybswxxcx.zwfwhfgjjfzj.yibin.gov.cn/performance-h5</profiles.webUrl>
<package.environment>build</package.environment>
<skipUi>false</skipUi>
......@@ -209,15 +243,15 @@
<profiles.hik.protocol>https://</profiles.hik.protocol>
<profiles.hik.appKey>25594054</profiles.hik.appKey>
<profiles.hik.appSecret>K12IkZoSLxpsJjrUPtfV</profiles.hik.appSecret>
<profiles.dingtalk.domain>https://oapi.dingtalk.com</profiles.dingtalk.domain>
<profiles.dingtalk.oaScheme>https</profiles.dingtalk.oaScheme>
<profiles.dingtalk.oaUrl>api.dingtalk.com</profiles.dingtalk.oaUrl>
<profiles.dingtalk.agentId>2652674890</profiles.dingtalk.agentId>
<profiles.dingtalk.appKey>dingpqzradgfr4efdi2j</profiles.dingtalk.appKey>
<profiles.dingtalk.appSecret>bF2WALmo5_Wuj3hg5gXeWqezrYnZChUJ88HjzNWpkA9ivdOxfBDGOGYcfVRfB3vd</profiles.dingtalk.appSecret>
<profiles.dingtalk.aesKey>1QcPYuSpAc98OS3qQwwx5HPH85CZDidxF95yBGad2fJ</profiles.dingtalk.aesKey>
<profiles.dingtalk.token>m3WeuVx5kcTY76kh22uWZOTSu0XjvcwNhd</profiles.dingtalk.token>
<profiles.dingtalk.opUserId>254868153920685466</profiles.dingtalk.opUserId>
<profiles.dingtalk.domain></profiles.dingtalk.domain>
<profiles.dingtalk.oaScheme></profiles.dingtalk.oaScheme>
<profiles.dingtalk.oaUrl></profiles.dingtalk.oaUrl>
<profiles.dingtalk.agentId></profiles.dingtalk.agentId>
<profiles.dingtalk.appKey></profiles.dingtalk.appKey>
<profiles.dingtalk.appSecret></profiles.dingtalk.appSecret>
<profiles.dingtalk.aesKey></profiles.dingtalk.aesKey>
<profiles.dingtalk.token></profiles.dingtalk.token>
<profiles.dingtalk.opUserId></profiles.dingtalk.opUserId>
<profiles.webUrl>https://ybswxxcx.zwfwhfgjjfzj.yibin.gov.cn/performance-h5</profiles.webUrl>
<package.environment>build</package.environment>
<skipUi>false</skipUi>
......
......@@ -15,8 +15,10 @@ import com.mortals.framework.util.ThreadPool;
import com.mortals.xhx.base.system.user.model.UserEntity;
import com.mortals.xhx.common.code.YesNoEnum;
import com.mortals.xhx.common.utils.AddAttendThread;
import com.mortals.xhx.module.attendance.model.AttendanceLeaveRecordQuery;
import com.mortals.xhx.module.attendance.model.AttendanceRecordHikEntity;
import com.mortals.xhx.module.attendance.model.AttendanceRecordHikQuery;
import com.mortals.xhx.module.attendance.service.AttendanceLeaveRecordService;
import com.mortals.xhx.module.attendance.service.AttendanceRecordHikService;
import com.mortals.xhx.module.attendance.service.AttendanceStatService;
import com.mortals.xhx.module.hik.door.model.req.door.DoorEventReq;
......@@ -25,7 +27,9 @@ import com.mortals.xhx.module.hik.door.service.IHikDoorService;
import com.mortals.xhx.module.staff.model.StaffEntity;
import com.mortals.xhx.module.staff.service.StaffService;
import lombok.extern.slf4j.Slf4j;
import org.checkerframework.checker.units.qual.A;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Service;
import org.springframework.util.ObjectUtils;
import org.springframework.util.StopWatch;
......@@ -45,6 +49,11 @@ public class SyncDoorsEventWeekTaskImpl implements ITaskExcuteService {
@Autowired
private AttendanceRecordHikService recordHikService;
@Autowired
private AttendanceLeaveRecordService attendanceLeaveRecordService;
@Value("${dingtalk.domain:}")
protected String domain;
@Override
public void excuteTask(ITask task) throws AppException {
......@@ -71,12 +80,26 @@ public class SyncDoorsEventWeekTaskImpl implements ITaskExcuteService {
stopWatch.stop();
log.info("考勤计算日期:{} 完成,耗时:{}ms", curDate.toDateStr(), stopWatch.getLastTaskTimeMillis());
}
AddAttendThread addAttendThread = new AddAttendThread(recordHikService, hikEntity, null);
ThreadPool.getInstance().execute(addAttendThread);
}
//同步最近钉钉请假事件
if(!ObjectUtils.isEmpty(domain)){
log.info("开始同步钉钉请假事件!");
long between = DateUtil.between(attendStart, attendEnd, DateUnit.DAY, true);
AttendanceLeaveRecordQuery query = new AttendanceLeaveRecordQuery();
query.setStartTimeStart(hikEntity.getAttendanceDateStart());
query.setEndTimeEnd(hikEntity.getAttendanceDateEnd());
if (between > 120) return;
Thread thread = new Thread(new Runnable() {
@Override
public void run() {
attendanceLeaveRecordService.syncLeaveRecord(query, null);
}
});
ThreadPool.getInstance().execute(thread);
}
}
@Override
......
......@@ -5,7 +5,7 @@ Content-Type: application/json
{
"loginName":"admin",
"password":"admin",
"password":"xhxADMIN8@a",
"securityCode":"admin"
}
......@@ -107,8 +107,8 @@ Authorization: {{authToken}}
Content-Type: application/json
{
"startTimeStart":"2024-01-01",
"endTimeEnd":"2024-02-29"
"startTimeStart":"2024-03-01",
"endTimeEnd":"2024-03-14"
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment