mirror of
https://github.com/hpd840321/starRiverProperty.git
synced 2026-06-09 08:20:31 +08:00
feat: add service config templates and extraction script
Former-commit-id: 1de24b7eb79676d1aba9d799a58c5a753290cf52
This commit is contained in:
@@ -0,0 +1,61 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project xmlns="http://maven.apache.org/POM/4.0.0"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<parent>
|
||||
<groupId>cn.cloudwalk.ninca</groupId>
|
||||
<artifactId>ninca-crk-from-lib-reactor</artifactId>
|
||||
<version>2.9.1_210630-SNAPSHOT</version>
|
||||
<relativePath>../pom.xml</relativePath>
|
||||
</parent>
|
||||
<artifactId>ninca-crk-smart-attendance-web</artifactId>
|
||||
<name>ninca-crk-smart-attendance-web</name>
|
||||
<description>CFR from ninca-crk-smart-attendance-web-2.9.1_210630-SNAPSHOT.jar (embedded pom: none)</description>
|
||||
<properties>
|
||||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||
</properties>
|
||||
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>cn.cloudwalk.ninca</groupId>
|
||||
<artifactId>ninca-crk-smart-attendance-service</artifactId>
|
||||
<version>${project.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>cn.cloudwalk.ninca</groupId>
|
||||
<artifactId>ninca-crk-smart-attendance-interface</artifactId>
|
||||
<version>${project.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>cn.cloudwalk.intelligent</groupId>
|
||||
<artifactId>intelligent-cwoscomponent-interface</artifactId>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>cn.cloudwalk.cloud</groupId>
|
||||
<artifactId>cloudwalk-common-result</artifactId>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.springframework</groupId>
|
||||
<artifactId>spring-webmvc</artifactId>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>javax.servlet</groupId>
|
||||
<artifactId>javax.servlet-api</artifactId>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>javax.validation</groupId>
|
||||
<artifactId>validation-api</artifactId>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>cn.cloudwalk.ninca</groupId>
|
||||
<artifactId>ninca-crk-portal-resource-stubs</artifactId>
|
||||
<version>${project.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>cn.cloudwalk.intelligent</groupId>
|
||||
<artifactId>davinci-manager-storage</artifactId>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
</project>
|
||||
+39
@@ -0,0 +1,39 @@
|
||||
/*
|
||||
* Decompiled with CFR 0.152.
|
||||
*
|
||||
* Could not load the following classes:
|
||||
* cn.cloudwalk.cloud.result.CloudwalkResult
|
||||
* javax.servlet.http.HttpServletRequest
|
||||
* org.slf4j.Logger
|
||||
* org.slf4j.LoggerFactory
|
||||
* org.springframework.web.bind.annotation.ExceptionHandler
|
||||
* org.springframework.web.bind.annotation.ResponseBody
|
||||
* org.springframework.web.bind.annotation.RestControllerAdvice
|
||||
* org.springframework.web.servlet.NoHandlerFoundException
|
||||
*/
|
||||
package cn.cloudwalk.web.ninca.attendance;
|
||||
|
||||
import cn.cloudwalk.cloud.result.CloudwalkResult;
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
import org.springframework.web.bind.annotation.ExceptionHandler;
|
||||
import org.springframework.web.bind.annotation.ResponseBody;
|
||||
import org.springframework.web.bind.annotation.RestControllerAdvice;
|
||||
import org.springframework.web.servlet.NoHandlerFoundException;
|
||||
|
||||
@RestControllerAdvice(basePackages={"cn.cloudwalk.web.ninca.attendance"})
|
||||
public class AttendGlobalExceptionHandler {
|
||||
private final Logger logger = LoggerFactory.getLogger(this.getClass());
|
||||
|
||||
@ExceptionHandler(value={Exception.class})
|
||||
@ResponseBody
|
||||
public CloudwalkResult<Void> exceptionHandler(HttpServletRequest req, Exception e) {
|
||||
this.logger.error("\u670d\u52a1\u5f02\u5e38\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
if (e instanceof NoHandlerFoundException) {
|
||||
return CloudwalkResult.fail((String)"76240001", (String)"\u670d\u52a1\u4e0d\u5b58\u5728");
|
||||
}
|
||||
return CloudwalkResult.fail((String)"76240000", (String)"\u670d\u52a1\u5185\u90e8\u9519\u8bef");
|
||||
}
|
||||
}
|
||||
|
||||
+123
@@ -0,0 +1,123 @@
|
||||
/*
|
||||
* Decompiled with CFR 0.152.
|
||||
*
|
||||
* Could not load the following classes:
|
||||
* cn.cloudwalk.cloud.page.CloudwalkPageAble
|
||||
* cn.cloudwalk.cloud.result.CloudwalkResult
|
||||
* cn.cloudwalk.common.ninca.attendance.annotation.DavinciPic
|
||||
* cn.cloudwalk.common.ninca.attendance.util.CollectionUtils
|
||||
* cn.cloudwalk.common.ninca.attendance.util.StringUtils
|
||||
* cn.cloudwalk.service.ninca.attendance.common.AttendanceProperties
|
||||
* javax.annotation.Resource
|
||||
* org.aspectj.lang.JoinPoint
|
||||
* org.aspectj.lang.annotation.AfterReturning
|
||||
* org.aspectj.lang.annotation.Aspect
|
||||
* org.aspectj.lang.annotation.Pointcut
|
||||
* org.slf4j.Logger
|
||||
* org.slf4j.LoggerFactory
|
||||
* org.springframework.stereotype.Component
|
||||
*/
|
||||
package cn.cloudwalk.web.ninca.attendance.aspect;
|
||||
|
||||
import cn.cloudwalk.cloud.page.CloudwalkPageAble;
|
||||
import cn.cloudwalk.cloud.result.CloudwalkResult;
|
||||
import cn.cloudwalk.common.ninca.attendance.annotation.DavinciPic;
|
||||
import cn.cloudwalk.common.ninca.attendance.util.CollectionUtils;
|
||||
import cn.cloudwalk.common.ninca.attendance.util.StringUtils;
|
||||
import cn.cloudwalk.service.ninca.attendance.common.AttendanceProperties;
|
||||
import java.lang.reflect.Field;
|
||||
import java.lang.reflect.Method;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Collection;
|
||||
import java.util.List;
|
||||
import java.util.regex.Pattern;
|
||||
import javax.annotation.Resource;
|
||||
import org.aspectj.lang.JoinPoint;
|
||||
import org.aspectj.lang.annotation.AfterReturning;
|
||||
import org.aspectj.lang.annotation.Aspect;
|
||||
import org.aspectj.lang.annotation.Pointcut;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
import org.springframework.stereotype.Component;
|
||||
|
||||
@Aspect
|
||||
@Component
|
||||
public class AttendControllerAspect {
|
||||
private Logger logger = LoggerFactory.getLogger(AttendControllerAspect.class);
|
||||
@Resource
|
||||
private AttendanceProperties attendanceProperties;
|
||||
|
||||
@Pointcut(value="execution(public * cn.cloudwalk.web.ninca.attendance..*.controller..*(..))")
|
||||
public void controllerPointcut() {
|
||||
}
|
||||
|
||||
@AfterReturning(returning="ret", value="controllerPointcut()")
|
||||
public void doAfter(JoinPoint joinPoint, Object ret) {
|
||||
if (ret instanceof CloudwalkResult) {
|
||||
CloudwalkResult cloudwalkResult = (CloudwalkResult)ret;
|
||||
Object o = cloudwalkResult.getData();
|
||||
if (o == null) {
|
||||
return;
|
||||
}
|
||||
if (o instanceof CloudwalkPageAble) {
|
||||
CloudwalkPageAble cloudwalkPageAble = (CloudwalkPageAble)o;
|
||||
List tList = (List)cloudwalkPageAble.getDatas();
|
||||
if (CollectionUtils.isNotEmpty((Collection)tList)) {
|
||||
for (Object obj : tList) {
|
||||
this.genFullPicUrl(obj);
|
||||
}
|
||||
}
|
||||
} else if (o instanceof ArrayList) {
|
||||
List tList = (List)o;
|
||||
if (CollectionUtils.isNotEmpty((Collection)tList)) {
|
||||
for (Object obj : tList) {
|
||||
this.genFullPicUrl(obj);
|
||||
}
|
||||
}
|
||||
} else {
|
||||
this.genFullPicUrl(o);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void genFullPicUrl(Object o) {
|
||||
Field[] allFields;
|
||||
if (o == null) {
|
||||
return;
|
||||
}
|
||||
Class<?> clazz = o.getClass();
|
||||
for (Field field : allFields = clazz.getDeclaredFields()) {
|
||||
if (!field.isAnnotationPresent(DavinciPic.class)) continue;
|
||||
String getMethodName = "get" + StringUtils.toUpperCase((String)field.getName(), (int)1);
|
||||
String setMethodName = "set" + StringUtils.toUpperCase((String)field.getName(), (int)1);
|
||||
try {
|
||||
if (field.getType() == List.class) {
|
||||
ArrayList<String> urls = new ArrayList<String>();
|
||||
Method getMethod = clazz.getMethod(getMethodName, new Class[0]);
|
||||
List paths = (List)getMethod.invoke(o, new Object[0]);
|
||||
if (!CollectionUtils.isNotEmpty((Collection)paths)) continue;
|
||||
for (String path : paths) {
|
||||
urls.add(this.isFullPath(path) ? path : this.attendanceProperties.getCwosPicUrl() + path);
|
||||
}
|
||||
Method setMethod = clazz.getMethod(setMethodName, field.getType());
|
||||
setMethod.invoke(o, urls);
|
||||
continue;
|
||||
}
|
||||
Method getMethod = clazz.getMethod(getMethodName, new Class[0]);
|
||||
String path = (String)getMethod.invoke(o, new Object[0]);
|
||||
if (!StringUtils.isNotBlank((String)path)) continue;
|
||||
Method setMethod = clazz.getMethod(setMethodName, field.getType());
|
||||
setMethod.invoke(o, this.isFullPath(path) ? path : this.attendanceProperties.getCwosPicUrl() + path);
|
||||
}
|
||||
catch (Exception e) {
|
||||
this.logger.error("", (Throwable)e);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private boolean isFullPath(String path) {
|
||||
String pattern = "^http[s]{0,1}:\\/\\/([\\w.]+\\/?)\\S*";
|
||||
return Pattern.matches("^http[s]{0,1}:\\/\\/([\\w.]+\\/?)\\S*", path);
|
||||
}
|
||||
}
|
||||
|
||||
+33
@@ -0,0 +1,33 @@
|
||||
/*
|
||||
* Decompiled with CFR 0.152.
|
||||
*
|
||||
* Could not load the following classes:
|
||||
* cn.cloudwalk.client.davinci.portal.user.result.PortalUserDetailResult
|
||||
* cn.cloudwalk.client.davinci.portal.user.service.PortalUserService
|
||||
* cn.cloudwalk.cloud.exception.ServiceException
|
||||
* cn.cloudwalk.cloud.result.CloudwalkResult
|
||||
* org.springframework.beans.factory.annotation.Autowired
|
||||
*/
|
||||
package cn.cloudwalk.web.ninca.attendance.common;
|
||||
|
||||
import cn.cloudwalk.client.davinci.portal.user.result.PortalUserDetailResult;
|
||||
import cn.cloudwalk.client.davinci.portal.user.service.PortalUserService;
|
||||
import cn.cloudwalk.cloud.exception.ServiceException;
|
||||
import cn.cloudwalk.cloud.result.CloudwalkResult;
|
||||
import cn.cloudwalk.web.ninca.attendance.common.AbstractCloudwalkController;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
|
||||
public abstract class AbstractAttendanceController
|
||||
extends AbstractCloudwalkController {
|
||||
@Autowired
|
||||
private PortalUserService portalUserService;
|
||||
|
||||
protected PortalUserDetailResult currentUserPersonId() throws ServiceException {
|
||||
CloudwalkResult currentUserDetail = this.portalUserService.getCurrentUserDetail(this.getCloudwalkContext());
|
||||
if (currentUserDetail.isSuccess() && currentUserDetail.getData() != null) {
|
||||
return (PortalUserDetailResult)currentUserDetail.getData();
|
||||
}
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
+108
@@ -0,0 +1,108 @@
|
||||
/*
|
||||
* Decompiled with CFR 0.152.
|
||||
*
|
||||
* Could not load the following classes:
|
||||
* cn.cloudwalk.cloud.context.CloudwalkCallContext
|
||||
* cn.cloudwalk.cloud.context.CloudwalkCallContextBuilder
|
||||
* cn.cloudwalk.cloud.context.CloudwalkSessionContextHolder
|
||||
* cn.cloudwalk.cloud.session.extend.DefaultExtendContext
|
||||
* cn.cloudwalk.cloud.session.extend.ExtendContext
|
||||
* cn.cloudwalk.common.ninca.attendance.bean.context.CloudWalkExtendContextValue
|
||||
* cn.cloudwalk.common.ninca.attendance.common.ExcelCallback
|
||||
* javax.servlet.http.HttpServletRequest
|
||||
* javax.servlet.http.HttpServletResponse
|
||||
* org.slf4j.Logger
|
||||
* org.slf4j.LoggerFactory
|
||||
* org.springframework.beans.factory.annotation.Autowired
|
||||
* org.springframework.context.MessageSource
|
||||
* org.springframework.context.i18n.LocaleContextHolder
|
||||
* org.springframework.web.context.request.RequestContextHolder
|
||||
* org.springframework.web.context.request.ServletRequestAttributes
|
||||
*/
|
||||
package cn.cloudwalk.web.ninca.attendance.common;
|
||||
|
||||
import cn.cloudwalk.cloud.context.CloudwalkCallContext;
|
||||
import cn.cloudwalk.cloud.context.CloudwalkCallContextBuilder;
|
||||
import cn.cloudwalk.cloud.context.CloudwalkSessionContextHolder;
|
||||
import cn.cloudwalk.cloud.session.extend.DefaultExtendContext;
|
||||
import cn.cloudwalk.cloud.session.extend.ExtendContext;
|
||||
import cn.cloudwalk.common.ninca.attendance.bean.context.CloudWalkExtendContextValue;
|
||||
import cn.cloudwalk.common.ninca.attendance.common.ExcelCallback;
|
||||
import cn.cloudwalk.web.ninca.attendance.common.ExcelUtilExtend;
|
||||
import java.io.IOException;
|
||||
import java.io.OutputStream;
|
||||
import java.net.URLEncoder;
|
||||
import java.util.List;
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.context.MessageSource;
|
||||
import org.springframework.context.i18n.LocaleContextHolder;
|
||||
import org.springframework.web.context.request.RequestContextHolder;
|
||||
import org.springframework.web.context.request.ServletRequestAttributes;
|
||||
|
||||
public abstract class AbstractCloudwalkController {
|
||||
protected final Logger logger = LoggerFactory.getLogger(this.getClass());
|
||||
@Autowired
|
||||
private MessageSource messageSource;
|
||||
@Autowired
|
||||
private ExcelUtilExtend excelUtilExtend;
|
||||
@Autowired
|
||||
private CloudwalkSessionContextHolder cloudwalkSessionContextHolder;
|
||||
|
||||
public CloudwalkCallContext getCloudwalkContext() {
|
||||
CloudwalkCallContext cloudwalkCallContext = CloudwalkCallContextBuilder.buildContext((CloudwalkSessionContextHolder)this.cloudwalkSessionContextHolder);
|
||||
ServletRequestAttributes attributes = (ServletRequestAttributes)RequestContextHolder.getRequestAttributes();
|
||||
if (null != attributes) {
|
||||
DefaultExtendContext extendContext = new DefaultExtendContext();
|
||||
CloudWalkExtendContextValue cloudWalkExtendContextValue = new CloudWalkExtendContextValue();
|
||||
HttpServletRequest request = attributes.getRequest();
|
||||
cloudWalkExtendContextValue.setLoginId(request.getHeader("loginid"));
|
||||
cloudWalkExtendContextValue.setAuthorization(request.getHeader("authorization"));
|
||||
extendContext.setValue((Object)cloudWalkExtendContextValue);
|
||||
cloudwalkCallContext.setExt((ExtendContext)extendContext);
|
||||
}
|
||||
return cloudwalkCallContext;
|
||||
}
|
||||
|
||||
protected HttpServletRequest getHttpServletRequest() {
|
||||
return ((ServletRequestAttributes)RequestContextHolder.getRequestAttributes()).getRequest();
|
||||
}
|
||||
|
||||
public String getMessage(String code, String defaultMsg) {
|
||||
return this.messageSource.getMessage(code, null, defaultMsg, LocaleContextHolder.getLocale());
|
||||
}
|
||||
|
||||
public String getMessage(String code) {
|
||||
return this.getMessage(code, "");
|
||||
}
|
||||
|
||||
protected void makeExcelresponse(HttpServletRequest request, HttpServletResponse response, String fileName) {
|
||||
response.setContentType("application/vnd.ms-excel;charset=utf-8");
|
||||
response.setHeader("Content-Disposition", "attachment;filename=" + this.encodeFileName(fileName, request));
|
||||
}
|
||||
|
||||
protected String encodeFileName(String fileNames, HttpServletRequest request) {
|
||||
String codedFilename = null;
|
||||
try {
|
||||
codedFilename = URLEncoder.encode(fileNames, "UTF-8");
|
||||
}
|
||||
catch (Exception e) {
|
||||
this.logger.error("\u8f6c\u6362\u6587\u4ef6\u540d\u5b57\u7b26\u7c7b\u578b\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
}
|
||||
return codedFilename;
|
||||
}
|
||||
|
||||
protected <T> void exportExcel(String fileName, HttpServletRequest request, HttpServletResponse response, Class<T> clazz, List<T> result) throws IOException, Exception {
|
||||
this.makeExcelresponse(request, response, fileName);
|
||||
this.excelUtilExtend.exportFromList(result, fileName, (OutputStream)response.getOutputStream(), clazz);
|
||||
}
|
||||
|
||||
protected <T> void exportExcel(String fileName, HttpServletRequest request, HttpServletResponse response, Class<T> clazz, List<T> result, Integer startRow, ExcelCallback callback) throws IOException, Exception {
|
||||
this.makeExcelresponse(request, response, fileName);
|
||||
this.excelUtilExtend.exportFromList(result, fileName, (OutputStream)response.getOutputStream(), clazz, startRow, callback);
|
||||
}
|
||||
}
|
||||
|
||||
+76
@@ -0,0 +1,76 @@
|
||||
/*
|
||||
* Decompiled with CFR 0.152.
|
||||
*
|
||||
* Could not load the following classes:
|
||||
* cn.cloudwalk.cloud.exception.ServiceException
|
||||
* cn.cloudwalk.cloud.utils.ApplicationContextUtils
|
||||
* cn.cloudwalk.common.ninca.attendance.util.StringUtils
|
||||
* cn.cloudwalk.intelligent.davinci.common.exception.DavinciServiceException
|
||||
* cn.cloudwalk.intelligent.davinci.storage.manager.FileStorageManager
|
||||
* org.slf4j.Logger
|
||||
* org.slf4j.LoggerFactory
|
||||
*/
|
||||
package cn.cloudwalk.web.ninca.attendance.common;
|
||||
|
||||
import cn.cloudwalk.cloud.exception.ServiceException;
|
||||
import cn.cloudwalk.cloud.utils.ApplicationContextUtils;
|
||||
import cn.cloudwalk.common.ninca.attendance.util.StringUtils;
|
||||
import cn.cloudwalk.intelligent.davinci.common.exception.DavinciServiceException;
|
||||
import cn.cloudwalk.intelligent.davinci.storage.manager.FileStorageManager;
|
||||
import java.lang.reflect.Field;
|
||||
import java.lang.reflect.InvocationTargetException;
|
||||
import java.lang.reflect.Method;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.concurrent.RecursiveAction;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
|
||||
public class BatchDownloadTask<T>
|
||||
extends RecursiveAction {
|
||||
private static final Logger logger = LoggerFactory.getLogger(BatchDownloadTask.class);
|
||||
private static final Integer SIZE = 50;
|
||||
private Map<String, Field> fileField;
|
||||
private Class cls;
|
||||
private List<T> list;
|
||||
|
||||
public BatchDownloadTask(Map<String, Field> fileField, Class cls, List<T> list) {
|
||||
this.fileField = fileField;
|
||||
this.cls = cls;
|
||||
this.list = list;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void compute() {
|
||||
if (this.list.size() <= SIZE) {
|
||||
for (T entry : this.list) {
|
||||
try {
|
||||
this.computeSingle(entry, this.fileField, this.cls);
|
||||
}
|
||||
catch (ServiceException | DavinciServiceException | IllegalAccessException | NoSuchMethodException | InvocationTargetException e) {
|
||||
logger.error("\u5e76\u884c\u5904\u7406\u6587\u4ef6\u4e0b\u8f7d\u51fa\u73b0\u5f02\u5e38", e);
|
||||
}
|
||||
}
|
||||
return;
|
||||
}
|
||||
int middle = this.list.size() / 2;
|
||||
BatchDownloadTask<T> taskLeft = new BatchDownloadTask<T>(this.fileField, this.cls, this.list.subList(0, middle));
|
||||
BatchDownloadTask<T> taskRight = new BatchDownloadTask<T>(this.fileField, this.cls, this.list.subList(middle, this.list.size()));
|
||||
BatchDownloadTask.invokeAll(taskLeft, taskRight);
|
||||
}
|
||||
|
||||
private void computeSingle(T obj, Map<String, Field> fileField, Class cls) throws NoSuchMethodException, InvocationTargetException, IllegalAccessException, ServiceException, DavinciServiceException {
|
||||
for (Map.Entry<String, Field> fieldEntry : fileField.entrySet()) {
|
||||
Method getMethod = cls.getMethod(fieldEntry.getKey(), new Class[0]);
|
||||
Object filePathObj = getMethod.invoke(obj, new Object[0]);
|
||||
String filePath = null;
|
||||
if (filePathObj == null || !StringUtils.isNotBlank((String)(filePath = (String)filePathObj))) continue;
|
||||
FileStorageManager fileStorageManager = (FileStorageManager)ApplicationContextUtils.getContext().getBean(FileStorageManager.class);
|
||||
byte[] bytes = fileStorageManager.fileDownload(filePath);
|
||||
String setMethodName = "set" + StringUtils.toUpperCase((String)fieldEntry.getValue().getName(), (int)1);
|
||||
Method setMethod = cls.getMethod(setMethodName, fieldEntry.getValue().getType());
|
||||
setMethod.invoke(obj, new Object[]{bytes});
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
+76
@@ -0,0 +1,76 @@
|
||||
/*
|
||||
* Decompiled with CFR 0.152.
|
||||
*
|
||||
* Could not load the following classes:
|
||||
* cn.cloudwalk.common.ninca.attendance.annotation.ExcelAttribute
|
||||
* cn.cloudwalk.common.ninca.attendance.annotation.ExcelBytesAttribute
|
||||
* cn.cloudwalk.common.ninca.attendance.common.ExcelCallback
|
||||
* cn.cloudwalk.common.ninca.attendance.util.ExcelUtil
|
||||
* cn.cloudwalk.common.ninca.attendance.util.StringUtils
|
||||
* com.google.common.base.Stopwatch
|
||||
* javax.annotation.PreDestroy
|
||||
* org.slf4j.Logger
|
||||
* org.slf4j.LoggerFactory
|
||||
* org.springframework.stereotype.Component
|
||||
*/
|
||||
package cn.cloudwalk.web.ninca.attendance.common;
|
||||
|
||||
import cn.cloudwalk.common.ninca.attendance.annotation.ExcelAttribute;
|
||||
import cn.cloudwalk.common.ninca.attendance.annotation.ExcelBytesAttribute;
|
||||
import cn.cloudwalk.common.ninca.attendance.common.ExcelCallback;
|
||||
import cn.cloudwalk.common.ninca.attendance.util.ExcelUtil;
|
||||
import cn.cloudwalk.common.ninca.attendance.util.StringUtils;
|
||||
import cn.cloudwalk.web.ninca.attendance.common.BatchDownloadTask;
|
||||
import com.google.common.base.Stopwatch;
|
||||
import java.io.OutputStream;
|
||||
import java.lang.reflect.Field;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.concurrent.ForkJoinPool;
|
||||
import java.util.concurrent.TimeUnit;
|
||||
import javax.annotation.PreDestroy;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
import org.springframework.stereotype.Component;
|
||||
|
||||
@Component(value="attendExcelUtilExtend")
|
||||
public class ExcelUtilExtend
|
||||
extends ExcelUtil {
|
||||
protected final Logger logger = LoggerFactory.getLogger(ExcelUtilExtend.class);
|
||||
private static ForkJoinPool forkJoinPool = new ForkJoinPool(8);
|
||||
|
||||
@PreDestroy
|
||||
public void destory() {
|
||||
forkJoinPool.shutdown();
|
||||
}
|
||||
|
||||
public <T> boolean exportFromList(List<T> list, String sheetName, OutputStream output, Class<T> clazz) throws Exception {
|
||||
this.resolveFilePath(list, clazz);
|
||||
return ExcelUtilExtend.getListToExcel(list, (String)sheetName, (OutputStream)output, clazz);
|
||||
}
|
||||
|
||||
public <T> boolean exportFromList(List<T> list, String sheetName, OutputStream output, Class<T> clazz, Integer startRow, ExcelCallback callback) throws Exception {
|
||||
this.resolveFilePath(list, clazz);
|
||||
return ExcelUtilExtend.getListToExcel(list, (String)sheetName, (OutputStream)output, clazz, (Integer)startRow, (ExcelCallback)callback);
|
||||
}
|
||||
|
||||
private <T> void resolveFilePath(List<T> list, Class<T> clazz) throws Exception {
|
||||
Field[] allFields = clazz.getDeclaredFields();
|
||||
HashMap<String, Field> fieldMap = new HashMap<String, Field>();
|
||||
for (Field field : allFields) {
|
||||
ExcelBytesAttribute bytesAttribute;
|
||||
String pathField;
|
||||
if (!field.isAnnotationPresent(ExcelAttribute.class) || !field.isAnnotationPresent(ExcelBytesAttribute.class) || !StringUtils.isNotBlank((String)(pathField = (bytesAttribute = field.getAnnotation(ExcelBytesAttribute.class)).pathField()))) continue;
|
||||
String getMethod = "get" + StringUtils.toUpperCase((String)pathField, (int)1);
|
||||
fieldMap.put(getMethod, field);
|
||||
}
|
||||
if (fieldMap.size() == 0) {
|
||||
return;
|
||||
}
|
||||
Stopwatch stopwatch = Stopwatch.createStarted();
|
||||
BatchDownloadTask<T> batchDownloadTask = new BatchDownloadTask<T>(fieldMap, clazz, list);
|
||||
forkJoinPool.submit(batchDownloadTask).get();
|
||||
this.logger.info("\u4e0b\u8f7d\u56fe\u7247\u8017\u65f6:{},\u8bb0\u5f55\u6761\u6570:{}", (Object)stopwatch.elapsed(TimeUnit.SECONDS), (Object)list.size());
|
||||
}
|
||||
}
|
||||
|
||||
+192
@@ -0,0 +1,192 @@
|
||||
/*
|
||||
* Decompiled with CFR 0.152.
|
||||
*
|
||||
* Could not load the following classes:
|
||||
* cn.cloudwalk.client.ninca.attendance.config.param.AttendClassAddParam
|
||||
* cn.cloudwalk.client.ninca.attendance.config.param.AttendClassDeleteParam
|
||||
* cn.cloudwalk.client.ninca.attendance.config.param.AttendClassEdParam
|
||||
* cn.cloudwalk.client.ninca.attendance.config.param.AttendClassEditParam
|
||||
* cn.cloudwalk.client.ninca.attendance.config.param.AttendClassPageParam
|
||||
* cn.cloudwalk.client.ninca.attendance.config.param.AttendClassQueryParam
|
||||
* cn.cloudwalk.client.ninca.attendance.config.param.AttendClassSubDetailQueryParam
|
||||
* cn.cloudwalk.client.ninca.attendance.config.result.AttendClassDeviceQueryResult
|
||||
* cn.cloudwalk.client.ninca.attendance.config.result.AttendClassImagestoreQueryResult
|
||||
* cn.cloudwalk.client.ninca.attendance.config.result.AttendClassOrgQueryResult
|
||||
* cn.cloudwalk.client.ninca.attendance.config.result.AttendClassPageResult
|
||||
* cn.cloudwalk.client.ninca.attendance.config.result.AttendClassQueryResult
|
||||
* cn.cloudwalk.client.ninca.attendance.config.service.AttendClassDeviceService
|
||||
* cn.cloudwalk.client.ninca.attendance.config.service.AttendClassImagestoreService
|
||||
* cn.cloudwalk.client.ninca.attendance.config.service.AttendClassOrgService
|
||||
* cn.cloudwalk.client.ninca.attendance.config.service.AttendClassService
|
||||
* cn.cloudwalk.cloud.exception.ServiceException
|
||||
* cn.cloudwalk.cloud.page.CloudwalkPageAble
|
||||
* cn.cloudwalk.cloud.page.CloudwalkPageInfo
|
||||
* cn.cloudwalk.cloud.result.CloudwalkResult
|
||||
* cn.cloudwalk.cloud.utils.BeanCopyUtils
|
||||
* javax.annotation.Resource
|
||||
* org.springframework.web.bind.annotation.PostMapping
|
||||
* org.springframework.web.bind.annotation.RequestBody
|
||||
* org.springframework.web.bind.annotation.RequestMapping
|
||||
* org.springframework.web.bind.annotation.RestController
|
||||
*/
|
||||
package cn.cloudwalk.web.ninca.attendance.config.controller;
|
||||
|
||||
import cn.cloudwalk.client.ninca.attendance.config.param.AttendClassAddParam;
|
||||
import cn.cloudwalk.client.ninca.attendance.config.param.AttendClassDeleteParam;
|
||||
import cn.cloudwalk.client.ninca.attendance.config.param.AttendClassEdParam;
|
||||
import cn.cloudwalk.client.ninca.attendance.config.param.AttendClassEditParam;
|
||||
import cn.cloudwalk.client.ninca.attendance.config.param.AttendClassPageParam;
|
||||
import cn.cloudwalk.client.ninca.attendance.config.param.AttendClassQueryParam;
|
||||
import cn.cloudwalk.client.ninca.attendance.config.param.AttendClassSubDetailQueryParam;
|
||||
import cn.cloudwalk.client.ninca.attendance.config.result.AttendClassDeviceQueryResult;
|
||||
import cn.cloudwalk.client.ninca.attendance.config.result.AttendClassImagestoreQueryResult;
|
||||
import cn.cloudwalk.client.ninca.attendance.config.result.AttendClassOrgQueryResult;
|
||||
import cn.cloudwalk.client.ninca.attendance.config.result.AttendClassPageResult;
|
||||
import cn.cloudwalk.client.ninca.attendance.config.result.AttendClassQueryResult;
|
||||
import cn.cloudwalk.client.ninca.attendance.config.service.AttendClassDeviceService;
|
||||
import cn.cloudwalk.client.ninca.attendance.config.service.AttendClassImagestoreService;
|
||||
import cn.cloudwalk.client.ninca.attendance.config.service.AttendClassOrgService;
|
||||
import cn.cloudwalk.client.ninca.attendance.config.service.AttendClassService;
|
||||
import cn.cloudwalk.cloud.exception.ServiceException;
|
||||
import cn.cloudwalk.cloud.page.CloudwalkPageAble;
|
||||
import cn.cloudwalk.cloud.page.CloudwalkPageInfo;
|
||||
import cn.cloudwalk.cloud.result.CloudwalkResult;
|
||||
import cn.cloudwalk.cloud.utils.BeanCopyUtils;
|
||||
import cn.cloudwalk.web.ninca.attendance.common.AbstractCloudwalkController;
|
||||
import cn.cloudwalk.web.ninca.attendance.config.form.AttendClassAddForm;
|
||||
import cn.cloudwalk.web.ninca.attendance.config.form.AttendClassDeleteForm;
|
||||
import cn.cloudwalk.web.ninca.attendance.config.form.AttendClassEdForm;
|
||||
import cn.cloudwalk.web.ninca.attendance.config.form.AttendClassEditForm;
|
||||
import cn.cloudwalk.web.ninca.attendance.config.form.AttendClassPageForm;
|
||||
import cn.cloudwalk.web.ninca.attendance.config.form.AttendClassQueryForm;
|
||||
import cn.cloudwalk.web.ninca.attendance.config.form.AttendClassSubDetailQueryForm;
|
||||
import java.util.List;
|
||||
import javax.annotation.Resource;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestBody;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
@RestController
|
||||
@RequestMapping(value={"/intelligent/api/attend/class"})
|
||||
public class AttendClassController
|
||||
extends AbstractCloudwalkController {
|
||||
@Resource
|
||||
private AttendClassService attendClassService;
|
||||
@Resource
|
||||
private AttendClassDeviceService attendClassDeviceService;
|
||||
@Resource
|
||||
private AttendClassImagestoreService attendClassImagestoreService;
|
||||
@Resource
|
||||
private AttendClassOrgService attendClassOrgService;
|
||||
|
||||
@PostMapping(value={"/page"})
|
||||
public CloudwalkResult<CloudwalkPageAble<AttendClassPageResult>> page(@RequestBody AttendClassPageForm form) {
|
||||
try {
|
||||
AttendClassPageParam param = (AttendClassPageParam)BeanCopyUtils.copyProperties((Object)((Object)form), AttendClassPageParam.class);
|
||||
CloudwalkPageInfo pageInfo = new CloudwalkPageInfo(form.getCurrentPage(), form.getRowsOfPage());
|
||||
return this.attendClassService.page(param, pageInfo, this.getCloudwalkContext());
|
||||
}
|
||||
catch (ServiceException e) {
|
||||
this.logger.error("\u73ed\u7ec4\u5206\u9875\u67e5\u8be2\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240301", (String)this.getMessage("76240301"));
|
||||
}
|
||||
}
|
||||
|
||||
@PostMapping(value={"/add"})
|
||||
public CloudwalkResult<Boolean> add(@RequestBody AttendClassAddForm form) {
|
||||
try {
|
||||
AttendClassAddParam param = (AttendClassAddParam)BeanCopyUtils.copyProperties((Object)form, AttendClassAddParam.class);
|
||||
return this.attendClassService.add(param, this.getCloudwalkContext());
|
||||
}
|
||||
catch (ServiceException e) {
|
||||
this.logger.error("\u73ed\u7ec4\u65b0\u589e\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240302", (String)this.getMessage("76240302"));
|
||||
}
|
||||
}
|
||||
|
||||
@PostMapping(value={"/edit"})
|
||||
public CloudwalkResult<Boolean> edit(@RequestBody AttendClassEditForm form) {
|
||||
try {
|
||||
AttendClassEditParam param = (AttendClassEditParam)BeanCopyUtils.copyProperties((Object)form, AttendClassEditParam.class);
|
||||
return this.attendClassService.edit(param, this.getCloudwalkContext());
|
||||
}
|
||||
catch (ServiceException e) {
|
||||
this.logger.error("\u73ed\u7ec4\u7f16\u8f91\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240303", (String)this.getMessage("76240303"));
|
||||
}
|
||||
}
|
||||
|
||||
@PostMapping(value={"/ed"})
|
||||
public CloudwalkResult<Boolean> ed(@RequestBody AttendClassEdForm form) {
|
||||
try {
|
||||
AttendClassEdParam param = (AttendClassEdParam)BeanCopyUtils.copyProperties((Object)form, AttendClassEdParam.class);
|
||||
return this.attendClassService.ed(param, this.getCloudwalkContext());
|
||||
}
|
||||
catch (ServiceException e) {
|
||||
this.logger.error("\u73ed\u7ec4\u542f\u7528\u3001\u7981\u7528\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240304", (String)this.getMessage("76240304"));
|
||||
}
|
||||
}
|
||||
|
||||
@PostMapping(value={"/delete"})
|
||||
public CloudwalkResult<Boolean> delete(@RequestBody AttendClassDeleteForm form) {
|
||||
try {
|
||||
AttendClassDeleteParam param = (AttendClassDeleteParam)BeanCopyUtils.copyProperties((Object)form, AttendClassDeleteParam.class);
|
||||
return this.attendClassService.delete(param, this.getCloudwalkContext());
|
||||
}
|
||||
catch (ServiceException e) {
|
||||
this.logger.error("\u73ed\u7ec4\u5220\u9664\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240305", (String)this.getMessage("76240305"));
|
||||
}
|
||||
}
|
||||
|
||||
@PostMapping(value={"/device/get"})
|
||||
public CloudwalkResult<List<AttendClassDeviceQueryResult>> getDevice(@RequestBody AttendClassSubDetailQueryForm form) {
|
||||
AttendClassSubDetailQueryParam param = (AttendClassSubDetailQueryParam)BeanCopyUtils.copyProperties((Object)form, AttendClassSubDetailQueryParam.class);
|
||||
try {
|
||||
return this.attendClassDeviceService.query(param, this.getCloudwalkContext());
|
||||
}
|
||||
catch (ServiceException e) {
|
||||
this.logger.error("\u73ed\u7ec4\u8bbe\u5907\u67e5\u8be2\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240311", (String)this.getMessage("76240311"));
|
||||
}
|
||||
}
|
||||
|
||||
@PostMapping(value={"/imagestore/get"})
|
||||
public CloudwalkResult<List<AttendClassImagestoreQueryResult>> getImagestore(@RequestBody AttendClassSubDetailQueryForm form) {
|
||||
AttendClassSubDetailQueryParam param = (AttendClassSubDetailQueryParam)BeanCopyUtils.copyProperties((Object)form, AttendClassSubDetailQueryParam.class);
|
||||
try {
|
||||
return this.attendClassImagestoreService.query(param, this.getCloudwalkContext());
|
||||
}
|
||||
catch (ServiceException e) {
|
||||
this.logger.error("\u73ed\u7ec4\u56fe\u5e93\u67e5\u8be2\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240312", (String)this.getMessage("76240312"));
|
||||
}
|
||||
}
|
||||
|
||||
@PostMapping(value={"/query"})
|
||||
public CloudwalkResult<List<AttendClassQueryResult>> query(@RequestBody AttendClassQueryForm form) {
|
||||
try {
|
||||
AttendClassQueryParam param = (AttendClassQueryParam)BeanCopyUtils.copyProperties((Object)form, AttendClassQueryParam.class);
|
||||
return this.attendClassService.query(param, this.getCloudwalkContext());
|
||||
}
|
||||
catch (ServiceException e) {
|
||||
this.logger.error("\u73ed\u7ec4\u67e5\u8be2\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240314", (String)this.getMessage("76240314"));
|
||||
}
|
||||
}
|
||||
|
||||
@PostMapping(value={"/org/get"})
|
||||
public CloudwalkResult<List<AttendClassOrgQueryResult>> getOrg(@RequestBody AttendClassSubDetailQueryForm form) {
|
||||
AttendClassSubDetailQueryParam param = (AttendClassSubDetailQueryParam)BeanCopyUtils.copyProperties((Object)form, AttendClassSubDetailQueryParam.class);
|
||||
try {
|
||||
return this.attendClassOrgService.query(param, this.getCloudwalkContext());
|
||||
}
|
||||
catch (ServiceException e) {
|
||||
this.logger.error("\u73ed\u7ec4\u7ec4\u7ec7\u67e5\u8be2\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240224", (String)this.getMessage("76240224"));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
+215
@@ -0,0 +1,215 @@
|
||||
/*
|
||||
* Decompiled with CFR 0.152.
|
||||
*
|
||||
* Could not load the following classes:
|
||||
* cn.cloudwalk.client.davinci.portal.user.result.PortalUserDetailResult
|
||||
* cn.cloudwalk.client.davinci.portal.user.service.PortalUserService
|
||||
* cn.cloudwalk.client.ninca.attendance.config.param.AttendClassSchedulingDetailParam
|
||||
* cn.cloudwalk.client.ninca.attendance.config.param.AttendClassSchedulingExecuteParam
|
||||
* cn.cloudwalk.client.ninca.attendance.config.param.AttendClassSchedulingSelfParam
|
||||
* cn.cloudwalk.client.ninca.attendance.config.param.AttendClassSchedulingWorkDaySetParam
|
||||
* cn.cloudwalk.client.ninca.attendance.config.result.AttendClassSchedulingDetailResult
|
||||
* cn.cloudwalk.client.ninca.attendance.config.result.AttendClassSchedulingExcelResult
|
||||
* cn.cloudwalk.client.ninca.attendance.config.result.AttendClassSchedulingPublishResult
|
||||
* cn.cloudwalk.client.ninca.attendance.config.result.AttendClassSchedulingSelfResult
|
||||
* cn.cloudwalk.client.ninca.attendance.config.result.AttendClassSchedulingWorkDayResult
|
||||
* cn.cloudwalk.client.ninca.attendance.config.service.AttendClassSchedulingService
|
||||
* cn.cloudwalk.cloud.exception.ServiceException
|
||||
* cn.cloudwalk.cloud.page.CloudwalkPageInfo
|
||||
* cn.cloudwalk.cloud.result.CloudwalkResult
|
||||
* cn.cloudwalk.cloud.utils.BeanCopyUtils
|
||||
* cn.cloudwalk.service.ninca.attendance.export.AttendSchedulingExportAsyncService
|
||||
* javax.annotation.Resource
|
||||
* org.springframework.beans.factory.annotation.Autowired
|
||||
* org.springframework.validation.BindingResult
|
||||
* org.springframework.validation.ObjectError
|
||||
* org.springframework.web.bind.annotation.PostMapping
|
||||
* org.springframework.web.bind.annotation.RequestBody
|
||||
* org.springframework.web.bind.annotation.RequestMapping
|
||||
* org.springframework.web.bind.annotation.RestController
|
||||
*/
|
||||
package cn.cloudwalk.web.ninca.attendance.config.controller;
|
||||
|
||||
import cn.cloudwalk.client.davinci.portal.user.result.PortalUserDetailResult;
|
||||
import cn.cloudwalk.client.davinci.portal.user.service.PortalUserService;
|
||||
import cn.cloudwalk.client.ninca.attendance.config.param.AttendClassSchedulingDetailParam;
|
||||
import cn.cloudwalk.client.ninca.attendance.config.param.AttendClassSchedulingExecuteParam;
|
||||
import cn.cloudwalk.client.ninca.attendance.config.param.AttendClassSchedulingSelfParam;
|
||||
import cn.cloudwalk.client.ninca.attendance.config.param.AttendClassSchedulingWorkDaySetParam;
|
||||
import cn.cloudwalk.client.ninca.attendance.config.result.AttendClassSchedulingDetailResult;
|
||||
import cn.cloudwalk.client.ninca.attendance.config.result.AttendClassSchedulingExcelResult;
|
||||
import cn.cloudwalk.client.ninca.attendance.config.result.AttendClassSchedulingPublishResult;
|
||||
import cn.cloudwalk.client.ninca.attendance.config.result.AttendClassSchedulingSelfResult;
|
||||
import cn.cloudwalk.client.ninca.attendance.config.result.AttendClassSchedulingWorkDayResult;
|
||||
import cn.cloudwalk.client.ninca.attendance.config.service.AttendClassSchedulingService;
|
||||
import cn.cloudwalk.cloud.exception.ServiceException;
|
||||
import cn.cloudwalk.cloud.page.CloudwalkPageInfo;
|
||||
import cn.cloudwalk.cloud.result.CloudwalkResult;
|
||||
import cn.cloudwalk.cloud.utils.BeanCopyUtils;
|
||||
import cn.cloudwalk.service.ninca.attendance.export.AttendSchedulingExportAsyncService;
|
||||
import cn.cloudwalk.web.ninca.attendance.common.AbstractCloudwalkController;
|
||||
import cn.cloudwalk.web.ninca.attendance.config.form.AttendClassSchedulingDetailForm;
|
||||
import cn.cloudwalk.web.ninca.attendance.config.form.AttendClassSchedulingExecuteForm;
|
||||
import cn.cloudwalk.web.ninca.attendance.config.form.AttendClassSchedulingSelfForm;
|
||||
import cn.cloudwalk.web.ninca.attendance.config.form.AttendClassSchedulingWorkDaySetForm;
|
||||
import java.util.List;
|
||||
import javax.annotation.Resource;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.validation.BindingResult;
|
||||
import org.springframework.validation.ObjectError;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestBody;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
@RestController
|
||||
@RequestMapping(value={"/intelligent/api/attend/class/scheduling"})
|
||||
public class AttendSchedulingController
|
||||
extends AbstractCloudwalkController {
|
||||
@Resource
|
||||
private AttendClassSchedulingService classSchedulingService;
|
||||
@Autowired
|
||||
private PortalUserService portalUserService;
|
||||
@Autowired
|
||||
private AttendSchedulingExportAsyncService attendSchedulingExportAsyncService;
|
||||
|
||||
@PostMapping(value={"/query"})
|
||||
public CloudwalkResult<List<AttendClassSchedulingDetailResult>> detail(@RequestBody AttendClassSchedulingDetailForm form) {
|
||||
AttendClassSchedulingDetailParam param = (AttendClassSchedulingDetailParam)BeanCopyUtils.copyProperties((Object)form, AttendClassSchedulingDetailParam.class);
|
||||
CloudwalkPageInfo pageInfo = new CloudwalkPageInfo(form.getCurrentPage(), form.getRowsOfPage());
|
||||
try {
|
||||
return this.classSchedulingService.queryDetail(param, pageInfo, this.getCloudwalkContext(), false);
|
||||
}
|
||||
catch (ServiceException e) {
|
||||
this.logger.error("\u6392\u73ed\u8be6\u60c5\u67e5\u8be2\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240305", (String)this.getMessage("76240305"));
|
||||
}
|
||||
}
|
||||
|
||||
@PostMapping(value={"/self/query"})
|
||||
public CloudwalkResult<List<AttendClassSchedulingSelfResult>> selfetail(@RequestBody AttendClassSchedulingSelfForm form) {
|
||||
AttendClassSchedulingSelfParam param = (AttendClassSchedulingSelfParam)BeanCopyUtils.copyProperties((Object)form, AttendClassSchedulingSelfParam.class);
|
||||
try {
|
||||
param.setPersonId(this.currentUserPersonId());
|
||||
return this.classSchedulingService.querySelfDetail(param, this.getCloudwalkContext(), false);
|
||||
}
|
||||
catch (ServiceException e) {
|
||||
this.logger.error("\u6392\u73ed\u8be6\u60c5\u67e5\u8be2\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240305", (String)this.getMessage("76240305"));
|
||||
}
|
||||
}
|
||||
|
||||
private String currentUserPersonId() throws ServiceException {
|
||||
CloudwalkResult currentUserDetail = this.portalUserService.getCurrentUserDetail(this.getCloudwalkContext());
|
||||
if (currentUserDetail.isSuccess() && currentUserDetail.getData() != null) {
|
||||
return ((PortalUserDetailResult)currentUserDetail.getData()).getPersonId();
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
@PostMapping(value={"/query/export"})
|
||||
public CloudwalkResult<Boolean> detailExport(@RequestBody AttendClassSchedulingDetailForm form, BindingResult bindingResult) {
|
||||
try {
|
||||
if (bindingResult.hasErrors()) {
|
||||
ObjectError objectError = (ObjectError)bindingResult.getAllErrors().get(0);
|
||||
String code = objectError.getDefaultMessage();
|
||||
return CloudwalkResult.fail((String)code, (String)this.getMessage(code));
|
||||
}
|
||||
AttendClassSchedulingDetailParam param = (AttendClassSchedulingDetailParam)BeanCopyUtils.copyProperties((Object)form, AttendClassSchedulingDetailParam.class);
|
||||
return this.attendSchedulingExportAsyncService.startExportTask((Object)param, AttendClassSchedulingExcelResult.class, null, this.getCloudwalkContext());
|
||||
}
|
||||
catch (Exception e) {
|
||||
this.logger.error("\u6392\u73ed\u660e\u7ec6\u5bfc\u51fa\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240404", (String)"76240404");
|
||||
}
|
||||
}
|
||||
|
||||
@PostMapping(value={"/execute"})
|
||||
public CloudwalkResult<Boolean> schedulingExecute(@RequestBody AttendClassSchedulingExecuteForm form) {
|
||||
AttendClassSchedulingExecuteParam param = (AttendClassSchedulingExecuteParam)BeanCopyUtils.copyProperties((Object)form, AttendClassSchedulingExecuteParam.class);
|
||||
CloudwalkPageInfo pageInfo = new CloudwalkPageInfo(form.getCurrentPage(), form.getRowsOfPage());
|
||||
try {
|
||||
return this.classSchedulingService.schedulingExecute(param, pageInfo, this.getCloudwalkContext(), this.currentUserPersonId());
|
||||
}
|
||||
catch (ServiceException e) {
|
||||
this.logger.error("\u6392\u73ed\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240305", (String)this.getMessage("76240305"));
|
||||
}
|
||||
}
|
||||
|
||||
@PostMapping(value={"/get/pubilsh/time"})
|
||||
public CloudwalkResult<Long> getPublishTime(@RequestBody AttendClassSchedulingDetailForm form) {
|
||||
AttendClassSchedulingDetailParam param = (AttendClassSchedulingDetailParam)BeanCopyUtils.copyProperties((Object)form, AttendClassSchedulingDetailParam.class);
|
||||
CloudwalkPageInfo pageInfo = new CloudwalkPageInfo(form.getCurrentPage(), form.getRowsOfPage());
|
||||
try {
|
||||
return this.classSchedulingService.getPublishTime(param, pageInfo, this.getCloudwalkContext());
|
||||
}
|
||||
catch (ServiceException e) {
|
||||
this.logger.error("\u6392\u73ed\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240305", (String)this.getMessage("76240305"));
|
||||
}
|
||||
}
|
||||
|
||||
@PostMapping(value={"/get/publish"})
|
||||
public CloudwalkResult<Boolean> getPublish(@RequestBody AttendClassSchedulingDetailForm form) {
|
||||
AttendClassSchedulingDetailParam param = (AttendClassSchedulingDetailParam)BeanCopyUtils.copyProperties((Object)form, AttendClassSchedulingDetailParam.class);
|
||||
CloudwalkPageInfo pageInfo = new CloudwalkPageInfo(form.getCurrentPage(), form.getRowsOfPage());
|
||||
try {
|
||||
return this.classSchedulingService.getPublish(param, pageInfo, this.getCloudwalkContext());
|
||||
}
|
||||
catch (ServiceException e) {
|
||||
this.logger.error("\u6392\u73ed\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240305", (String)this.getMessage("76240305"));
|
||||
}
|
||||
}
|
||||
|
||||
@PostMapping(value={"/publish"})
|
||||
public CloudwalkResult<List<AttendClassSchedulingPublishResult>> schedulingPublish(@RequestBody AttendClassSchedulingDetailForm form) {
|
||||
AttendClassSchedulingDetailParam param = (AttendClassSchedulingDetailParam)BeanCopyUtils.copyProperties((Object)form, AttendClassSchedulingDetailParam.class);
|
||||
CloudwalkPageInfo pageInfo = new CloudwalkPageInfo(form.getCurrentPage(), form.getRowsOfPage());
|
||||
try {
|
||||
return this.classSchedulingService.schedulingPublish(param, pageInfo, this.getCloudwalkContext(), false, this.currentUserPersonId());
|
||||
}
|
||||
catch (ServiceException e) {
|
||||
this.logger.error("\u6392\u73ed\u53d1\u5e03\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240305", (String)this.getMessage("76240305"));
|
||||
}
|
||||
}
|
||||
|
||||
@PostMapping(value={"/workDay/set"})
|
||||
public CloudwalkResult<Boolean> workDaySet(@RequestBody AttendClassSchedulingWorkDaySetForm form) {
|
||||
AttendClassSchedulingWorkDaySetParam param = (AttendClassSchedulingWorkDaySetParam)BeanCopyUtils.copyProperties((Object)form, AttendClassSchedulingWorkDaySetParam.class);
|
||||
try {
|
||||
return this.classSchedulingService.workDaySet(param, this.getCloudwalkContext(), this.currentUserPersonId());
|
||||
}
|
||||
catch (ServiceException e) {
|
||||
this.logger.error("\u73ed\u79cd\u7f16\u8f91\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240305", (String)this.getMessage("76240305"));
|
||||
}
|
||||
}
|
||||
|
||||
@PostMapping(value={"/workDay/query"})
|
||||
public CloudwalkResult<AttendClassSchedulingWorkDayResult> workDayQuery() {
|
||||
try {
|
||||
return this.classSchedulingService.workDayQuery(this.getCloudwalkContext(), this.currentUserPersonId());
|
||||
}
|
||||
catch (ServiceException e) {
|
||||
this.logger.error("\u73ed\u79cd\u7f16\u8f91\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240305", (String)this.getMessage("76240305"));
|
||||
}
|
||||
}
|
||||
|
||||
@PostMapping(value={"/cancel"})
|
||||
public CloudwalkResult<Boolean> schedulingCancel(@RequestBody AttendClassSchedulingDetailForm form) {
|
||||
AttendClassSchedulingDetailParam param = (AttendClassSchedulingDetailParam)BeanCopyUtils.copyProperties((Object)form, AttendClassSchedulingDetailParam.class);
|
||||
CloudwalkPageInfo pageInfo = new CloudwalkPageInfo(form.getCurrentPage(), form.getRowsOfPage());
|
||||
try {
|
||||
return this.classSchedulingService.cancel(param, pageInfo, this.getCloudwalkContext(), this.currentUserPersonId());
|
||||
}
|
||||
catch (ServiceException e) {
|
||||
this.logger.error("\u6392\u73ed\u53d6\u6d88\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240315", (String)this.getMessage("76240315"));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
+125
@@ -0,0 +1,125 @@
|
||||
/*
|
||||
* Decompiled with CFR 0.152.
|
||||
*
|
||||
* Could not load the following classes:
|
||||
* cn.cloudwalk.client.ninca.attendance.config.param.AttendShiftAddParam
|
||||
* cn.cloudwalk.client.ninca.attendance.config.param.AttendShiftDeleteParam
|
||||
* cn.cloudwalk.client.ninca.attendance.config.param.AttendShiftEditParam
|
||||
* cn.cloudwalk.client.ninca.attendance.config.result.AttendShiftDetailResult
|
||||
* cn.cloudwalk.client.ninca.attendance.config.service.AttendShiftService
|
||||
* cn.cloudwalk.cloud.exception.ServiceException
|
||||
* cn.cloudwalk.cloud.page.CloudwalkBasePageForm
|
||||
* cn.cloudwalk.cloud.page.CloudwalkPageAble
|
||||
* cn.cloudwalk.cloud.page.CloudwalkPageInfo
|
||||
* cn.cloudwalk.cloud.result.CloudwalkResult
|
||||
* cn.cloudwalk.cloud.utils.BeanCopyUtils
|
||||
* javax.annotation.Resource
|
||||
* org.springframework.web.bind.annotation.PostMapping
|
||||
* org.springframework.web.bind.annotation.RequestBody
|
||||
* org.springframework.web.bind.annotation.RequestMapping
|
||||
* org.springframework.web.bind.annotation.RestController
|
||||
*/
|
||||
package cn.cloudwalk.web.ninca.attendance.config.controller;
|
||||
|
||||
import cn.cloudwalk.client.ninca.attendance.config.param.AttendShiftAddParam;
|
||||
import cn.cloudwalk.client.ninca.attendance.config.param.AttendShiftDeleteParam;
|
||||
import cn.cloudwalk.client.ninca.attendance.config.param.AttendShiftEditParam;
|
||||
import cn.cloudwalk.client.ninca.attendance.config.result.AttendShiftDetailResult;
|
||||
import cn.cloudwalk.client.ninca.attendance.config.service.AttendShiftService;
|
||||
import cn.cloudwalk.cloud.exception.ServiceException;
|
||||
import cn.cloudwalk.cloud.page.CloudwalkBasePageForm;
|
||||
import cn.cloudwalk.cloud.page.CloudwalkPageAble;
|
||||
import cn.cloudwalk.cloud.page.CloudwalkPageInfo;
|
||||
import cn.cloudwalk.cloud.result.CloudwalkResult;
|
||||
import cn.cloudwalk.cloud.utils.BeanCopyUtils;
|
||||
import cn.cloudwalk.web.ninca.attendance.common.AbstractCloudwalkController;
|
||||
import cn.cloudwalk.web.ninca.attendance.config.form.AttendClassShiftAddForm;
|
||||
import cn.cloudwalk.web.ninca.attendance.config.form.AttendClassShiftDeleteForm;
|
||||
import cn.cloudwalk.web.ninca.attendance.config.form.AttendClassShiftEditForm;
|
||||
import java.util.List;
|
||||
import javax.annotation.Resource;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestBody;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
@RestController
|
||||
@RequestMapping(value={"/intelligent/api/attend/shift"})
|
||||
public class AttendShiftController
|
||||
extends AbstractCloudwalkController {
|
||||
@Resource
|
||||
private AttendShiftService attendShiftService;
|
||||
|
||||
@PostMapping(value={"/query/page"})
|
||||
public CloudwalkResult<CloudwalkPageAble<AttendShiftDetailResult>> queryPage(@RequestBody CloudwalkBasePageForm form) {
|
||||
CloudwalkPageInfo pageInfo = new CloudwalkPageInfo(form.getCurrentPage(), form.getRowsOfPage());
|
||||
try {
|
||||
return this.attendShiftService.queryShiftPage(pageInfo, this.getCloudwalkContext());
|
||||
}
|
||||
catch (ServiceException e) {
|
||||
this.logger.error("\u73ed\u79cd\u8be6\u60c5\u67e5\u8be2\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240305", (String)this.getMessage("76240305"));
|
||||
}
|
||||
}
|
||||
|
||||
@PostMapping(value={"/query"})
|
||||
public CloudwalkResult<List<AttendShiftDetailResult>> query(@RequestBody CloudwalkBasePageForm form) {
|
||||
try {
|
||||
List list = this.attendShiftService.queryShift(this.getCloudwalkContext());
|
||||
return CloudwalkResult.success((Object)list);
|
||||
}
|
||||
catch (ServiceException e) {
|
||||
this.logger.error("\u73ed\u79cd\u8be6\u60c5\u67e5\u8be2\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240305", (String)this.getMessage("76240305"));
|
||||
}
|
||||
}
|
||||
|
||||
@PostMapping(value={"/add"})
|
||||
public CloudwalkResult<Boolean> add(@RequestBody AttendClassShiftAddForm form) {
|
||||
AttendShiftAddParam param = (AttendShiftAddParam)BeanCopyUtils.copyProperties((Object)form, AttendShiftAddParam.class);
|
||||
try {
|
||||
return this.attendShiftService.addShift(param, this.getCloudwalkContext());
|
||||
}
|
||||
catch (ServiceException e) {
|
||||
this.logger.error("\u73ed\u79cd\u6dfb\u52a0\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240305", (String)this.getMessage("76240305"));
|
||||
}
|
||||
}
|
||||
|
||||
@PostMapping(value={"/delete"})
|
||||
public CloudwalkResult<Boolean> delete(@RequestBody AttendClassShiftDeleteForm form) {
|
||||
AttendShiftDeleteParam param = (AttendShiftDeleteParam)BeanCopyUtils.copyProperties((Object)form, AttendShiftDeleteParam.class);
|
||||
try {
|
||||
return this.attendShiftService.deleteShift(param, this.getCloudwalkContext());
|
||||
}
|
||||
catch (ServiceException e) {
|
||||
this.logger.error("\u73ed\u79cd\u5220\u9664\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240305", (String)this.getMessage("76240305"));
|
||||
}
|
||||
}
|
||||
|
||||
@PostMapping(value={"/edit"})
|
||||
public CloudwalkResult<Boolean> edit(@RequestBody AttendClassShiftEditForm form) {
|
||||
AttendShiftEditParam param = (AttendShiftEditParam)BeanCopyUtils.copyProperties((Object)form, AttendShiftEditParam.class);
|
||||
try {
|
||||
return this.attendShiftService.editShift(param, this.getCloudwalkContext());
|
||||
}
|
||||
catch (ServiceException e) {
|
||||
this.logger.error("\u73ed\u79cd\u7f16\u8f91\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240305", (String)this.getMessage("76240305"));
|
||||
}
|
||||
}
|
||||
|
||||
@PostMapping(value={"/enable"})
|
||||
public CloudwalkResult<Boolean> enable(@RequestBody AttendClassShiftEditForm form) {
|
||||
AttendShiftEditParam param = (AttendShiftEditParam)BeanCopyUtils.copyProperties((Object)form, AttendShiftEditParam.class);
|
||||
try {
|
||||
return this.attendShiftService.enableShift(param, this.getCloudwalkContext());
|
||||
}
|
||||
catch (ServiceException e) {
|
||||
this.logger.error("\u73ed\u79cd\u7f16\u8f91\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240305", (String)this.getMessage("76240305"));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
+40
@@ -0,0 +1,40 @@
|
||||
/*
|
||||
* Decompiled with CFR 0.152.
|
||||
*/
|
||||
package cn.cloudwalk.web.ninca.attendance.config.form;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.List;
|
||||
|
||||
public class AttendClassAddForm
|
||||
implements Serializable {
|
||||
private static final long serialVersionUID = -7023015253349235979L;
|
||||
private String name;
|
||||
private List<String> deviceIds;
|
||||
private List<String> orgIds;
|
||||
|
||||
public String getName() {
|
||||
return this.name;
|
||||
}
|
||||
|
||||
public void setName(String name) {
|
||||
this.name = name;
|
||||
}
|
||||
|
||||
public List<String> getDeviceIds() {
|
||||
return this.deviceIds;
|
||||
}
|
||||
|
||||
public void setDeviceIds(List<String> deviceIds) {
|
||||
this.deviceIds = deviceIds;
|
||||
}
|
||||
|
||||
public List<String> getOrgIds() {
|
||||
return this.orgIds;
|
||||
}
|
||||
|
||||
public void setOrgIds(List<String> orgIds) {
|
||||
this.orgIds = orgIds;
|
||||
}
|
||||
}
|
||||
|
||||
+22
@@ -0,0 +1,22 @@
|
||||
/*
|
||||
* Decompiled with CFR 0.152.
|
||||
*/
|
||||
package cn.cloudwalk.web.ninca.attendance.config.form;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.List;
|
||||
|
||||
public class AttendClassDeleteForm
|
||||
implements Serializable {
|
||||
private static final long serialVersionUID = -8142458216101013028L;
|
||||
private List<String> ids;
|
||||
|
||||
public List<String> getIds() {
|
||||
return this.ids;
|
||||
}
|
||||
|
||||
public void setIds(List<String> ids) {
|
||||
this.ids = ids;
|
||||
}
|
||||
}
|
||||
|
||||
+30
@@ -0,0 +1,30 @@
|
||||
/*
|
||||
* Decompiled with CFR 0.152.
|
||||
*/
|
||||
package cn.cloudwalk.web.ninca.attendance.config.form;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
public class AttendClassEdForm
|
||||
implements Serializable {
|
||||
private static final long serialVersionUID = 9214249789726487160L;
|
||||
private String id;
|
||||
private Integer isEnable;
|
||||
|
||||
public String getId() {
|
||||
return this.id;
|
||||
}
|
||||
|
||||
public void setId(String id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public Integer getIsEnable() {
|
||||
return this.isEnable;
|
||||
}
|
||||
|
||||
public void setIsEnable(Integer isEnable) {
|
||||
this.isEnable = isEnable;
|
||||
}
|
||||
}
|
||||
|
||||
+49
@@ -0,0 +1,49 @@
|
||||
/*
|
||||
* Decompiled with CFR 0.152.
|
||||
*/
|
||||
package cn.cloudwalk.web.ninca.attendance.config.form;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.List;
|
||||
|
||||
public class AttendClassEditForm
|
||||
implements Serializable {
|
||||
private static final long serialVersionUID = 3461474304587729941L;
|
||||
private String id;
|
||||
private String name;
|
||||
private List<String> deviceIds;
|
||||
private List<String> orgIds;
|
||||
|
||||
public String getId() {
|
||||
return this.id;
|
||||
}
|
||||
|
||||
public void setId(String id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public String getName() {
|
||||
return this.name;
|
||||
}
|
||||
|
||||
public void setName(String name) {
|
||||
this.name = name;
|
||||
}
|
||||
|
||||
public List<String> getDeviceIds() {
|
||||
return this.deviceIds;
|
||||
}
|
||||
|
||||
public void setDeviceIds(List<String> deviceIds) {
|
||||
this.deviceIds = deviceIds;
|
||||
}
|
||||
|
||||
public List<String> getOrgIds() {
|
||||
return this.orgIds;
|
||||
}
|
||||
|
||||
public void setOrgIds(List<String> orgIds) {
|
||||
this.orgIds = orgIds;
|
||||
}
|
||||
}
|
||||
|
||||
+24
@@ -0,0 +1,24 @@
|
||||
/*
|
||||
* Decompiled with CFR 0.152.
|
||||
*
|
||||
* Could not load the following classes:
|
||||
* cn.cloudwalk.cloud.page.CloudwalkBasePageForm
|
||||
*/
|
||||
package cn.cloudwalk.web.ninca.attendance.config.form;
|
||||
|
||||
import cn.cloudwalk.cloud.page.CloudwalkBasePageForm;
|
||||
|
||||
public class AttendClassPageForm
|
||||
extends CloudwalkBasePageForm {
|
||||
private static final long serialVersionUID = -5585227812212747955L;
|
||||
private String name;
|
||||
|
||||
public String getName() {
|
||||
return this.name;
|
||||
}
|
||||
|
||||
public void setName(String name) {
|
||||
this.name = name;
|
||||
}
|
||||
}
|
||||
|
||||
+21
@@ -0,0 +1,21 @@
|
||||
/*
|
||||
* Decompiled with CFR 0.152.
|
||||
*/
|
||||
package cn.cloudwalk.web.ninca.attendance.config.form;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
public class AttendClassQueryForm
|
||||
implements Serializable {
|
||||
private static final long serialVersionUID = -5814862202862355272L;
|
||||
private Integer isEnable;
|
||||
|
||||
public Integer getIsEnable() {
|
||||
return this.isEnable;
|
||||
}
|
||||
|
||||
public void setIsEnable(Integer isEnable) {
|
||||
this.isEnable = isEnable;
|
||||
}
|
||||
}
|
||||
|
||||
+53
@@ -0,0 +1,53 @@
|
||||
/*
|
||||
* Decompiled with CFR 0.152.
|
||||
*
|
||||
* Could not load the following classes:
|
||||
* cn.cloudwalk.cloud.page.CloudwalkBasePageForm
|
||||
*/
|
||||
package cn.cloudwalk.web.ninca.attendance.config.form;
|
||||
|
||||
import cn.cloudwalk.cloud.page.CloudwalkBasePageForm;
|
||||
import java.io.Serializable;
|
||||
|
||||
public class AttendClassSchedulingDetailForm
|
||||
extends CloudwalkBasePageForm
|
||||
implements Serializable {
|
||||
private static final long serialVersionUID = 3682847271299774846L;
|
||||
private String personName;
|
||||
private String classId;
|
||||
private Long schedulingStartDate;
|
||||
private Long schedulingEndDate;
|
||||
|
||||
public String getPersonName() {
|
||||
return this.personName;
|
||||
}
|
||||
|
||||
public void setPersonName(String personName) {
|
||||
this.personName = personName;
|
||||
}
|
||||
|
||||
public String getClassId() {
|
||||
return this.classId;
|
||||
}
|
||||
|
||||
public void setClassId(String classId) {
|
||||
this.classId = classId;
|
||||
}
|
||||
|
||||
public Long getSchedulingStartDate() {
|
||||
return this.schedulingStartDate;
|
||||
}
|
||||
|
||||
public void setSchedulingStartDate(Long schedulingStartDate) {
|
||||
this.schedulingStartDate = schedulingStartDate;
|
||||
}
|
||||
|
||||
public Long getSchedulingEndDate() {
|
||||
return this.schedulingEndDate;
|
||||
}
|
||||
|
||||
public void setSchedulingEndDate(Long schedulingEndDate) {
|
||||
this.schedulingEndDate = schedulingEndDate;
|
||||
}
|
||||
}
|
||||
|
||||
+71
@@ -0,0 +1,71 @@
|
||||
/*
|
||||
* Decompiled with CFR 0.152.
|
||||
*
|
||||
* Could not load the following classes:
|
||||
* cn.cloudwalk.cloud.page.CloudwalkBasePageForm
|
||||
*/
|
||||
package cn.cloudwalk.web.ninca.attendance.config.form;
|
||||
|
||||
import cn.cloudwalk.cloud.page.CloudwalkBasePageForm;
|
||||
import java.io.Serializable;
|
||||
|
||||
public class AttendClassSchedulingExecuteForm
|
||||
extends CloudwalkBasePageForm
|
||||
implements Serializable {
|
||||
private static final long serialVersionUID = -3758620645452667597L;
|
||||
private Integer schedulingType;
|
||||
private String classId;
|
||||
private String personId;
|
||||
private long schedulingDate;
|
||||
private String shiftName;
|
||||
private String shiftId;
|
||||
|
||||
public Integer getSchedulingType() {
|
||||
return this.schedulingType;
|
||||
}
|
||||
|
||||
public void setSchedulingType(Integer schedulingType) {
|
||||
this.schedulingType = schedulingType;
|
||||
}
|
||||
|
||||
public String getClassId() {
|
||||
return this.classId;
|
||||
}
|
||||
|
||||
public void setClassId(String classId) {
|
||||
this.classId = classId;
|
||||
}
|
||||
|
||||
public String getPersonId() {
|
||||
return this.personId;
|
||||
}
|
||||
|
||||
public void setPersonId(String personId) {
|
||||
this.personId = personId;
|
||||
}
|
||||
|
||||
public long getSchedulingDate() {
|
||||
return this.schedulingDate;
|
||||
}
|
||||
|
||||
public void setSchedulingDate(long schedulingDate) {
|
||||
this.schedulingDate = schedulingDate;
|
||||
}
|
||||
|
||||
public String getShiftName() {
|
||||
return this.shiftName;
|
||||
}
|
||||
|
||||
public void setShiftName(String shiftName) {
|
||||
this.shiftName = shiftName;
|
||||
}
|
||||
|
||||
public String getShiftId() {
|
||||
return this.shiftId;
|
||||
}
|
||||
|
||||
public void setShiftId(String shiftId) {
|
||||
this.shiftId = shiftId;
|
||||
}
|
||||
}
|
||||
|
||||
+35
@@ -0,0 +1,35 @@
|
||||
/*
|
||||
* Decompiled with CFR 0.152.
|
||||
*
|
||||
* Could not load the following classes:
|
||||
* cn.cloudwalk.cloud.page.CloudwalkBasePageForm
|
||||
*/
|
||||
package cn.cloudwalk.web.ninca.attendance.config.form;
|
||||
|
||||
import cn.cloudwalk.cloud.page.CloudwalkBasePageForm;
|
||||
import java.io.Serializable;
|
||||
|
||||
public class AttendClassSchedulingSelfForm
|
||||
extends CloudwalkBasePageForm
|
||||
implements Serializable {
|
||||
private static final long serialVersionUID = -7670102137549681764L;
|
||||
private long schedulingStartDate;
|
||||
private long schedulingEndDate;
|
||||
|
||||
public long getSchedulingStartDate() {
|
||||
return this.schedulingStartDate;
|
||||
}
|
||||
|
||||
public void setSchedulingStartDate(long schedulingStartDate) {
|
||||
this.schedulingStartDate = schedulingStartDate;
|
||||
}
|
||||
|
||||
public long getSchedulingEndDate() {
|
||||
return this.schedulingEndDate;
|
||||
}
|
||||
|
||||
public void setSchedulingEndDate(long schedulingEndDate) {
|
||||
this.schedulingEndDate = schedulingEndDate;
|
||||
}
|
||||
}
|
||||
|
||||
+26
@@ -0,0 +1,26 @@
|
||||
/*
|
||||
* Decompiled with CFR 0.152.
|
||||
*
|
||||
* Could not load the following classes:
|
||||
* cn.cloudwalk.cloud.page.CloudwalkBasePageForm
|
||||
*/
|
||||
package cn.cloudwalk.web.ninca.attendance.config.form;
|
||||
|
||||
import cn.cloudwalk.cloud.page.CloudwalkBasePageForm;
|
||||
import java.io.Serializable;
|
||||
|
||||
public class AttendClassSchedulingWorkDaySetForm
|
||||
extends CloudwalkBasePageForm
|
||||
implements Serializable {
|
||||
private static final long serialVersionUID = 2105282092016854136L;
|
||||
private String workDays;
|
||||
|
||||
public String getWorkDays() {
|
||||
return this.workDays;
|
||||
}
|
||||
|
||||
public void setWorkDays(String workDays) {
|
||||
this.workDays = workDays;
|
||||
}
|
||||
}
|
||||
|
||||
+98
@@ -0,0 +1,98 @@
|
||||
/*
|
||||
* Decompiled with CFR 0.152.
|
||||
*
|
||||
* Could not load the following classes:
|
||||
* cn.cloudwalk.cloud.page.CloudwalkBasePageForm
|
||||
*/
|
||||
package cn.cloudwalk.web.ninca.attendance.config.form;
|
||||
|
||||
import cn.cloudwalk.cloud.page.CloudwalkBasePageForm;
|
||||
import java.io.Serializable;
|
||||
|
||||
public class AttendClassShiftAddForm
|
||||
extends CloudwalkBasePageForm
|
||||
implements Serializable {
|
||||
private static final long serialVersionUID = -5199224299641961303L;
|
||||
private String shiftName;
|
||||
private int shiftType;
|
||||
private String startWorkTime;
|
||||
private String endWorkTime;
|
||||
private String isNextDay;
|
||||
private int attendDays;
|
||||
private String endAdaptTime;
|
||||
private String startAdaptTime;
|
||||
private String periodDesc;
|
||||
|
||||
public String getPeriodDesc() {
|
||||
return this.periodDesc;
|
||||
}
|
||||
|
||||
public void setPeriodDesc(String periodDesc) {
|
||||
this.periodDesc = periodDesc;
|
||||
}
|
||||
|
||||
public String getShiftName() {
|
||||
return this.shiftName;
|
||||
}
|
||||
|
||||
public void setShiftName(String shiftName) {
|
||||
this.shiftName = shiftName;
|
||||
}
|
||||
|
||||
public int getShiftType() {
|
||||
return this.shiftType;
|
||||
}
|
||||
|
||||
public void setShiftType(int shiftType) {
|
||||
this.shiftType = shiftType;
|
||||
}
|
||||
|
||||
public String getIsNextDay() {
|
||||
return this.isNextDay;
|
||||
}
|
||||
|
||||
public void setIsNextDay(String isNextDay) {
|
||||
this.isNextDay = isNextDay;
|
||||
}
|
||||
|
||||
public int getAttendDays() {
|
||||
return this.attendDays;
|
||||
}
|
||||
|
||||
public void setAttendDays(int attendDays) {
|
||||
this.attendDays = attendDays;
|
||||
}
|
||||
|
||||
public String getStartWorkTime() {
|
||||
return this.startWorkTime;
|
||||
}
|
||||
|
||||
public void setStartWorkTime(String startWorkTime) {
|
||||
this.startWorkTime = startWorkTime;
|
||||
}
|
||||
|
||||
public String getEndWorkTime() {
|
||||
return this.endWorkTime;
|
||||
}
|
||||
|
||||
public void setEndWorkTime(String endWorkTime) {
|
||||
this.endWorkTime = endWorkTime;
|
||||
}
|
||||
|
||||
public String getEndAdaptTime() {
|
||||
return this.endAdaptTime;
|
||||
}
|
||||
|
||||
public void setEndAdaptTime(String endAdaptTime) {
|
||||
this.endAdaptTime = endAdaptTime;
|
||||
}
|
||||
|
||||
public String getStartAdaptTime() {
|
||||
return this.startAdaptTime;
|
||||
}
|
||||
|
||||
public void setStartAdaptTime(String startAdaptTime) {
|
||||
this.startAdaptTime = startAdaptTime;
|
||||
}
|
||||
}
|
||||
|
||||
+35
@@ -0,0 +1,35 @@
|
||||
/*
|
||||
* Decompiled with CFR 0.152.
|
||||
*
|
||||
* Could not load the following classes:
|
||||
* cn.cloudwalk.cloud.page.CloudwalkBasePageForm
|
||||
*/
|
||||
package cn.cloudwalk.web.ninca.attendance.config.form;
|
||||
|
||||
import cn.cloudwalk.cloud.page.CloudwalkBasePageForm;
|
||||
import java.io.Serializable;
|
||||
|
||||
public class AttendClassShiftDeleteForm
|
||||
extends CloudwalkBasePageForm
|
||||
implements Serializable {
|
||||
private static final long serialVersionUID = 5883759360763878655L;
|
||||
private String shiftId;
|
||||
private String shiftName;
|
||||
|
||||
public String getShiftId() {
|
||||
return this.shiftId;
|
||||
}
|
||||
|
||||
public void setShiftId(String shiftId) {
|
||||
this.shiftId = shiftId;
|
||||
}
|
||||
|
||||
public String getShiftName() {
|
||||
return this.shiftName;
|
||||
}
|
||||
|
||||
public void setShiftName(String shiftName) {
|
||||
this.shiftName = shiftName;
|
||||
}
|
||||
}
|
||||
|
||||
+188
@@ -0,0 +1,188 @@
|
||||
/*
|
||||
* Decompiled with CFR 0.152.
|
||||
*
|
||||
* Could not load the following classes:
|
||||
* cn.cloudwalk.cloud.page.CloudwalkBasePageForm
|
||||
*/
|
||||
package cn.cloudwalk.web.ninca.attendance.config.form;
|
||||
|
||||
import cn.cloudwalk.cloud.page.CloudwalkBasePageForm;
|
||||
import java.io.Serializable;
|
||||
|
||||
public class AttendClassShiftEditForm
|
||||
extends CloudwalkBasePageForm
|
||||
implements Serializable {
|
||||
private static final long serialVersionUID = -7455068338673375730L;
|
||||
private String shiftId;
|
||||
private String shiftName;
|
||||
private int shiftType;
|
||||
private String startWorkTime;
|
||||
private String endWorkTime;
|
||||
private String isNextDay;
|
||||
private int attendDays;
|
||||
private String endAdaptTime;
|
||||
private String startAdaptTime;
|
||||
private int afterTime;
|
||||
private int beforeTime;
|
||||
private int absentTime;
|
||||
private String periodDesc;
|
||||
private String standardTime;
|
||||
private int overTime;
|
||||
private int sortValue;
|
||||
private long lastUpdateTime;
|
||||
private String lastUpdateUserId;
|
||||
private int isEnable;
|
||||
|
||||
public int getIsEnable() {
|
||||
return this.isEnable;
|
||||
}
|
||||
|
||||
public void setIsEnable(int isEnable) {
|
||||
this.isEnable = isEnable;
|
||||
}
|
||||
|
||||
public String getLastUpdateUserId() {
|
||||
return this.lastUpdateUserId;
|
||||
}
|
||||
|
||||
public void setLastUpdateUserId(String lastUpdateUserId) {
|
||||
this.lastUpdateUserId = lastUpdateUserId;
|
||||
}
|
||||
|
||||
public String getPeriodDesc() {
|
||||
return this.periodDesc;
|
||||
}
|
||||
|
||||
public void setPeriodDesc(String periodDesc) {
|
||||
this.periodDesc = periodDesc;
|
||||
}
|
||||
|
||||
public String getStandardTime() {
|
||||
return this.standardTime;
|
||||
}
|
||||
|
||||
public void setStandardTime(String standardTime) {
|
||||
this.standardTime = standardTime;
|
||||
}
|
||||
|
||||
public int getOverTime() {
|
||||
return this.overTime;
|
||||
}
|
||||
|
||||
public void setOverTime(int overTime) {
|
||||
this.overTime = overTime;
|
||||
}
|
||||
|
||||
public int getSortValue() {
|
||||
return this.sortValue;
|
||||
}
|
||||
|
||||
public void setSortValue(int sortValue) {
|
||||
this.sortValue = sortValue;
|
||||
}
|
||||
|
||||
public long getLastUpdateTime() {
|
||||
return this.lastUpdateTime;
|
||||
}
|
||||
|
||||
public void setLastUpdateTime(long lastUpdateTime) {
|
||||
this.lastUpdateTime = lastUpdateTime;
|
||||
}
|
||||
|
||||
public int getAbsentTime() {
|
||||
return this.absentTime;
|
||||
}
|
||||
|
||||
public void setAbsentTime(int absentTime) {
|
||||
this.absentTime = absentTime;
|
||||
}
|
||||
|
||||
public int getAfterTime() {
|
||||
return this.afterTime;
|
||||
}
|
||||
|
||||
public void setAfterTime(int afterTime) {
|
||||
this.afterTime = afterTime;
|
||||
}
|
||||
|
||||
public int getBeforeTime() {
|
||||
return this.beforeTime;
|
||||
}
|
||||
|
||||
public void setBeforeTime(int beforeTime) {
|
||||
this.beforeTime = beforeTime;
|
||||
}
|
||||
|
||||
public String getShiftId() {
|
||||
return this.shiftId;
|
||||
}
|
||||
|
||||
public void setShiftId(String shiftId) {
|
||||
this.shiftId = shiftId;
|
||||
}
|
||||
|
||||
public String getShiftName() {
|
||||
return this.shiftName;
|
||||
}
|
||||
|
||||
public void setShiftName(String shiftName) {
|
||||
this.shiftName = shiftName;
|
||||
}
|
||||
|
||||
public int getShiftType() {
|
||||
return this.shiftType;
|
||||
}
|
||||
|
||||
public void setShiftType(int shiftType) {
|
||||
this.shiftType = shiftType;
|
||||
}
|
||||
|
||||
public String getStartWorkTime() {
|
||||
return this.startWorkTime;
|
||||
}
|
||||
|
||||
public void setStartWorkTime(String startWorkTime) {
|
||||
this.startWorkTime = startWorkTime;
|
||||
}
|
||||
|
||||
public String getEndWorkTime() {
|
||||
return this.endWorkTime;
|
||||
}
|
||||
|
||||
public void setEndWorkTime(String endWorkTime) {
|
||||
this.endWorkTime = endWorkTime;
|
||||
}
|
||||
|
||||
public String getIsNextDay() {
|
||||
return this.isNextDay;
|
||||
}
|
||||
|
||||
public void setIsNextDay(String isNextDay) {
|
||||
this.isNextDay = isNextDay;
|
||||
}
|
||||
|
||||
public int getAttendDays() {
|
||||
return this.attendDays;
|
||||
}
|
||||
|
||||
public void setAttendDays(int attendDays) {
|
||||
this.attendDays = attendDays;
|
||||
}
|
||||
|
||||
public String getEndAdaptTime() {
|
||||
return this.endAdaptTime;
|
||||
}
|
||||
|
||||
public void setEndAdaptTime(String endAdaptTime) {
|
||||
this.endAdaptTime = endAdaptTime;
|
||||
}
|
||||
|
||||
public String getStartAdaptTime() {
|
||||
return this.startAdaptTime;
|
||||
}
|
||||
|
||||
public void setStartAdaptTime(String startAdaptTime) {
|
||||
this.startAdaptTime = startAdaptTime;
|
||||
}
|
||||
}
|
||||
|
||||
+21
@@ -0,0 +1,21 @@
|
||||
/*
|
||||
* Decompiled with CFR 0.152.
|
||||
*/
|
||||
package cn.cloudwalk.web.ninca.attendance.config.form;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
public class AttendClassSubDetailQueryForm
|
||||
implements Serializable {
|
||||
private static final long serialVersionUID = -4734562268296827583L;
|
||||
private String classId;
|
||||
|
||||
public String getClassId() {
|
||||
return this.classId;
|
||||
}
|
||||
|
||||
public void setClassId(String classId) {
|
||||
this.classId = classId;
|
||||
}
|
||||
}
|
||||
|
||||
+57
@@ -0,0 +1,57 @@
|
||||
/*
|
||||
* Decompiled with CFR 0.152.
|
||||
*
|
||||
* Could not load the following classes:
|
||||
* cn.cloudwalk.client.ninca.attendance.device.param.AttendDeviceNewPageParam
|
||||
* cn.cloudwalk.client.ninca.attendance.device.result.AttendDeviceResult
|
||||
* cn.cloudwalk.client.ninca.attendance.device.service.AttendDeviceService
|
||||
* cn.cloudwalk.cloud.exception.ServiceException
|
||||
* cn.cloudwalk.cloud.page.CloudwalkPageAble
|
||||
* cn.cloudwalk.cloud.page.CloudwalkPageInfo
|
||||
* cn.cloudwalk.cloud.result.CloudwalkResult
|
||||
* cn.cloudwalk.cloud.utils.BeanCopyUtils
|
||||
* javax.annotation.Resource
|
||||
* org.springframework.web.bind.annotation.PostMapping
|
||||
* org.springframework.web.bind.annotation.RequestBody
|
||||
* org.springframework.web.bind.annotation.RequestMapping
|
||||
* org.springframework.web.bind.annotation.RestController
|
||||
*/
|
||||
package cn.cloudwalk.web.ninca.attendance.device.controller;
|
||||
|
||||
import cn.cloudwalk.client.ninca.attendance.device.param.AttendDeviceNewPageParam;
|
||||
import cn.cloudwalk.client.ninca.attendance.device.result.AttendDeviceResult;
|
||||
import cn.cloudwalk.client.ninca.attendance.device.service.AttendDeviceService;
|
||||
import cn.cloudwalk.cloud.exception.ServiceException;
|
||||
import cn.cloudwalk.cloud.page.CloudwalkPageAble;
|
||||
import cn.cloudwalk.cloud.page.CloudwalkPageInfo;
|
||||
import cn.cloudwalk.cloud.result.CloudwalkResult;
|
||||
import cn.cloudwalk.cloud.utils.BeanCopyUtils;
|
||||
import cn.cloudwalk.web.ninca.attendance.common.AbstractCloudwalkController;
|
||||
import cn.cloudwalk.web.ninca.attendance.device.form.AttendDeviceNewPageForm;
|
||||
import javax.annotation.Resource;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestBody;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
@RestController
|
||||
@RequestMapping(value={"/intelligent/api/attend/device"})
|
||||
public class AttendDeviceController
|
||||
extends AbstractCloudwalkController {
|
||||
@Resource
|
||||
private AttendDeviceService attendDeviceService;
|
||||
|
||||
@PostMapping(value={"/page"})
|
||||
public CloudwalkResult<CloudwalkPageAble<AttendDeviceResult>> page(@RequestBody AttendDeviceNewPageForm form) {
|
||||
AttendDeviceNewPageParam param = (AttendDeviceNewPageParam)BeanCopyUtils.copyProperties((Object)form, AttendDeviceNewPageParam.class);
|
||||
CloudwalkPageInfo page = new CloudwalkPageInfo(form.getCurrentPage(), form.getRowsOfPage());
|
||||
try {
|
||||
return this.attendDeviceService.page(param, page, this.getCloudwalkContext());
|
||||
}
|
||||
catch (ServiceException e) {
|
||||
this.logger.error("\u8003\u52e4\u8bbe\u5907\u5206\u9875\u67e5\u8be2\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240201", (String)this.getMessage("76240201"));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
+58
@@ -0,0 +1,58 @@
|
||||
/*
|
||||
* Decompiled with CFR 0.152.
|
||||
*
|
||||
* Could not load the following classes:
|
||||
* cn.cloudwalk.cloud.page.CloudwalkBasePageForm
|
||||
*/
|
||||
package cn.cloudwalk.web.ninca.attendance.device.form;
|
||||
|
||||
import cn.cloudwalk.cloud.page.CloudwalkBasePageForm;
|
||||
import java.io.Serializable;
|
||||
import java.util.List;
|
||||
|
||||
public class AttendDeviceNewPageForm
|
||||
extends CloudwalkBasePageForm
|
||||
implements Serializable {
|
||||
private static final long serialVersionUID = 5688215744877695100L;
|
||||
private String areaId;
|
||||
private String deviceName;
|
||||
private String districtId;
|
||||
private List<String> districtIds;
|
||||
|
||||
public static long getSerialVersionUID() {
|
||||
return 5688215744877695100L;
|
||||
}
|
||||
|
||||
public String getAreaId() {
|
||||
return this.areaId;
|
||||
}
|
||||
|
||||
public void setAreaId(String areaId) {
|
||||
this.areaId = areaId;
|
||||
}
|
||||
|
||||
public String getDeviceName() {
|
||||
return this.deviceName;
|
||||
}
|
||||
|
||||
public void setDeviceName(String deviceName) {
|
||||
this.deviceName = deviceName;
|
||||
}
|
||||
|
||||
public String getDistrictId() {
|
||||
return this.districtId;
|
||||
}
|
||||
|
||||
public void setDistrictId(String districtId) {
|
||||
this.districtId = districtId;
|
||||
}
|
||||
|
||||
public List<String> getDistrictIds() {
|
||||
return this.districtIds;
|
||||
}
|
||||
|
||||
public void setDistrictIds(List<String> districtIds) {
|
||||
this.districtIds = districtIds;
|
||||
}
|
||||
}
|
||||
|
||||
+102
@@ -0,0 +1,102 @@
|
||||
/*
|
||||
* Decompiled with CFR 0.152.
|
||||
*
|
||||
* Could not load the following classes:
|
||||
* cn.cloudwalk.client.cwoscomponent.intelligent.device.param.DeviceAreaQueryParam
|
||||
* cn.cloudwalk.client.cwoscomponent.intelligent.device.param.DeviceQueryParam
|
||||
* cn.cloudwalk.client.cwoscomponent.intelligent.device.result.DeviceAreaResult
|
||||
* cn.cloudwalk.client.cwoscomponent.intelligent.device.result.DeviceResult
|
||||
* cn.cloudwalk.client.cwoscomponent.intelligent.device.service.DeviceAreaService
|
||||
* cn.cloudwalk.client.cwoscomponent.intelligent.device.service.DeviceService
|
||||
* cn.cloudwalk.client.ninca.attendance.result.param.AttendResultSignParam
|
||||
* cn.cloudwalk.cloud.context.CloudwalkCallContext
|
||||
* cn.cloudwalk.cloud.exception.ServiceException
|
||||
* cn.cloudwalk.cloud.result.CloudwalkResult
|
||||
* cn.cloudwalk.cloud.session.company.CompanyContext
|
||||
* cn.cloudwalk.cloud.session.user.UserContext
|
||||
* cn.cloudwalk.cloud.utils.CloudwalkDateUtils
|
||||
* cn.cloudwalk.common.ninca.attendance.config.FeignRequestUtil
|
||||
* cn.cloudwalk.common.ninca.attendance.util.CollectionUtils
|
||||
* javax.annotation.Resource
|
||||
* org.slf4j.Logger
|
||||
* org.slf4j.LoggerFactory
|
||||
*/
|
||||
package cn.cloudwalk.web.ninca.attendance.handler;
|
||||
|
||||
import cn.cloudwalk.client.cwoscomponent.intelligent.device.param.DeviceAreaQueryParam;
|
||||
import cn.cloudwalk.client.cwoscomponent.intelligent.device.param.DeviceQueryParam;
|
||||
import cn.cloudwalk.client.cwoscomponent.intelligent.device.result.DeviceAreaResult;
|
||||
import cn.cloudwalk.client.cwoscomponent.intelligent.device.result.DeviceResult;
|
||||
import cn.cloudwalk.client.cwoscomponent.intelligent.device.service.DeviceAreaService;
|
||||
import cn.cloudwalk.client.cwoscomponent.intelligent.device.service.DeviceService;
|
||||
import cn.cloudwalk.client.ninca.attendance.result.param.AttendResultSignParam;
|
||||
import cn.cloudwalk.cloud.context.CloudwalkCallContext;
|
||||
import cn.cloudwalk.cloud.exception.ServiceException;
|
||||
import cn.cloudwalk.cloud.result.CloudwalkResult;
|
||||
import cn.cloudwalk.cloud.session.company.CompanyContext;
|
||||
import cn.cloudwalk.cloud.session.user.UserContext;
|
||||
import cn.cloudwalk.cloud.utils.CloudwalkDateUtils;
|
||||
import cn.cloudwalk.common.ninca.attendance.config.FeignRequestUtil;
|
||||
import cn.cloudwalk.common.ninca.attendance.util.CollectionUtils;
|
||||
import java.util.Collection;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import javax.annotation.Resource;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
|
||||
public abstract class AbstractEventHandler {
|
||||
protected static final Logger LOGGER = LoggerFactory.getLogger(AbstractEventHandler.class);
|
||||
private static final String DEFAULT_CALLER = "defaultUserId";
|
||||
private static final String DEFAULT_CALLER_NAME = "defaultUserName";
|
||||
@Resource
|
||||
private DeviceService deviceService;
|
||||
@Resource
|
||||
private DeviceAreaService deviceAreaService;
|
||||
|
||||
public CloudwalkCallContext getCloudwalkContext(String businessId) throws ServiceException {
|
||||
CloudwalkCallContext context = new CloudwalkCallContext();
|
||||
CompanyContext companyContext = new CompanyContext();
|
||||
companyContext.setCompanyId(businessId);
|
||||
context.setCompany(companyContext);
|
||||
UserContext userContext = new UserContext();
|
||||
userContext.setCaller(DEFAULT_CALLER);
|
||||
userContext.setCallerName(DEFAULT_CALLER_NAME);
|
||||
context.setUser(userContext);
|
||||
context.setCallTime(CloudwalkDateUtils.getCurrentDate());
|
||||
Map defaultRequestHeader = FeignRequestUtil.getDefaultRequestHeader((String)businessId);
|
||||
FeignRequestUtil.setRequestHeader((Map)defaultRequestHeader);
|
||||
return context;
|
||||
}
|
||||
|
||||
DeviceResult queryDeviceResult(String deviceCode, CloudwalkCallContext context) throws ServiceException {
|
||||
DeviceQueryParam deviceQueryParam = new DeviceQueryParam();
|
||||
deviceQueryParam.setDeviceCode(deviceCode);
|
||||
CloudwalkResult deviceQueryResult = this.deviceService.list(deviceQueryParam, context);
|
||||
if (deviceQueryResult.isSuccess() && CollectionUtils.isNotEmpty((Collection)((Collection)deviceQueryResult.getData()))) {
|
||||
DeviceResult deviceResult = (DeviceResult)((List)deviceQueryResult.getData()).get(0);
|
||||
DeviceAreaQueryParam deviceAreaQueryParam = new DeviceAreaQueryParam();
|
||||
deviceAreaQueryParam.setId(deviceResult.getAreaId());
|
||||
CloudwalkResult deviceAreaResult = this.deviceAreaService.list(deviceAreaQueryParam);
|
||||
if (deviceAreaResult.isSuccess() && CollectionUtils.isNotEmpty((Collection)((Collection)deviceAreaResult.getData()))) {
|
||||
deviceResult.setAreaName(((DeviceAreaResult)((List)deviceAreaResult.getData()).get(0)).getName());
|
||||
}
|
||||
return deviceResult;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
void setDevice(AttendResultSignParam signParam, DeviceResult deviceResult) {
|
||||
signParam.setDeviceId(deviceResult.getId());
|
||||
signParam.setDevType(deviceResult.getDeviceTypeId());
|
||||
signParam.setDevTypeName(deviceResult.getDeviceTypeName());
|
||||
signParam.setDeviceCode(deviceResult.getDeviceCode());
|
||||
signParam.setDeviceName(deviceResult.getDeviceName());
|
||||
signParam.setDeviceAreaId(deviceResult.getAreaId());
|
||||
signParam.setDeviceAreaName(deviceResult.getAreaName());
|
||||
signParam.setDistrictId(deviceResult.getDistrictId());
|
||||
signParam.setDistrictName(deviceResult.getDistrictName());
|
||||
signParam.setDistrictMergeName(deviceResult.getDistrictMergeName());
|
||||
}
|
||||
}
|
||||
|
||||
+169
@@ -0,0 +1,169 @@
|
||||
/*
|
||||
* Decompiled with CFR 0.152.
|
||||
*
|
||||
* Could not load the following classes:
|
||||
* cn.cloudwalk.client.cwoscomponent.intelligent.biology.result.FeatureQueryResult
|
||||
* cn.cloudwalk.client.cwoscomponent.intelligent.device.result.DeviceResult
|
||||
* cn.cloudwalk.client.ninca.attendance.capture.param.CaptureFeatureQueryParam
|
||||
* cn.cloudwalk.client.ninca.attendance.capture.service.BiologyFeatureService
|
||||
* cn.cloudwalk.client.ninca.attendance.common.AttendCommonDeviceService
|
||||
* cn.cloudwalk.client.ninca.attendance.result.param.AttendResultSignParam
|
||||
* cn.cloudwalk.client.ninca.attendance.result.service.AttendResultGenService
|
||||
* cn.cloudwalk.cloud.context.CloudwalkCallContext
|
||||
* cn.cloudwalk.cloud.exception.ServiceException
|
||||
* cn.cloudwalk.cloud.result.CloudwalkResult
|
||||
* cn.cloudwalk.cloud.utils.BeanCopyUtils
|
||||
* cn.cloudwalk.common.ninca.attendance.config.FeignThreadLocalUtil
|
||||
* cn.cloudwalk.common.ninca.attendance.em.YesNoTypeEnum
|
||||
* cn.cloudwalk.cwos.client.event.event.BaseEvent
|
||||
* cn.cloudwalk.cwos.client.event.event.FaceCaptureEvent
|
||||
* cn.cloudwalk.cwos.client.event.event.app.OpendoorFaceCaptureRecordEvent
|
||||
* cn.cloudwalk.cwos.client.event.event.mode.FaceCapture
|
||||
* cn.cloudwalk.event.CloudwalkEventManager
|
||||
* cn.cloudwalk.event.annotation.EventTopicSuffix
|
||||
* cn.cloudwalk.event.handler.EventHandler
|
||||
* cn.cloudwalk.service.ninca.attendance.common.AttendanceProperties
|
||||
* com.alibaba.fastjson.JSON
|
||||
* javax.annotation.Resource
|
||||
* org.springframework.stereotype.Component
|
||||
*/
|
||||
package cn.cloudwalk.web.ninca.attendance.handler;
|
||||
|
||||
import cn.cloudwalk.client.cwoscomponent.intelligent.biology.result.FeatureQueryResult;
|
||||
import cn.cloudwalk.client.cwoscomponent.intelligent.device.result.DeviceResult;
|
||||
import cn.cloudwalk.client.ninca.attendance.capture.param.CaptureFeatureQueryParam;
|
||||
import cn.cloudwalk.client.ninca.attendance.capture.service.BiologyFeatureService;
|
||||
import cn.cloudwalk.client.ninca.attendance.common.AttendCommonDeviceService;
|
||||
import cn.cloudwalk.client.ninca.attendance.result.param.AttendResultSignParam;
|
||||
import cn.cloudwalk.client.ninca.attendance.result.service.AttendResultGenService;
|
||||
import cn.cloudwalk.cloud.context.CloudwalkCallContext;
|
||||
import cn.cloudwalk.cloud.exception.ServiceException;
|
||||
import cn.cloudwalk.cloud.result.CloudwalkResult;
|
||||
import cn.cloudwalk.cloud.utils.BeanCopyUtils;
|
||||
import cn.cloudwalk.common.ninca.attendance.config.FeignThreadLocalUtil;
|
||||
import cn.cloudwalk.common.ninca.attendance.em.YesNoTypeEnum;
|
||||
import cn.cloudwalk.cwos.client.event.event.BaseEvent;
|
||||
import cn.cloudwalk.cwos.client.event.event.FaceCaptureEvent;
|
||||
import cn.cloudwalk.cwos.client.event.event.app.OpendoorFaceCaptureRecordEvent;
|
||||
import cn.cloudwalk.cwos.client.event.event.mode.FaceCapture;
|
||||
import cn.cloudwalk.event.CloudwalkEventManager;
|
||||
import cn.cloudwalk.event.annotation.EventTopicSuffix;
|
||||
import cn.cloudwalk.event.handler.EventHandler;
|
||||
import cn.cloudwalk.service.ninca.attendance.common.AttendanceProperties;
|
||||
import cn.cloudwalk.web.ninca.attendance.handler.AbstractEventHandler;
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import java.math.BigDecimal;
|
||||
import javax.annotation.Resource;
|
||||
import org.springframework.stereotype.Component;
|
||||
|
||||
@Component
|
||||
@EventTopicSuffix(value={"smart-attendance"})
|
||||
public class AttendFaceCaptureEventHandler
|
||||
extends AbstractEventHandler
|
||||
implements EventHandler<FaceCaptureEvent> {
|
||||
@Resource
|
||||
private BiologyFeatureService biologyFeatureService;
|
||||
@Resource
|
||||
private AttendResultGenService attendResultGenService;
|
||||
@Resource
|
||||
private AttendCommonDeviceService attendCommonDeviceService;
|
||||
@Resource
|
||||
private CloudwalkEventManager cloudwalkEventManager;
|
||||
@Resource
|
||||
private AttendanceProperties attendanceProperties;
|
||||
|
||||
/*
|
||||
* WARNING - Removed try catching itself - possible behaviour change.
|
||||
*/
|
||||
public void onEvent(FaceCaptureEvent event) {
|
||||
LOGGER.info("\u6536\u5230FaceCaptureEvent\u6d88\u606f:{}", (Object)JSON.toJSONString((Object)event));
|
||||
try {
|
||||
CloudwalkCallContext context = this.getCloudwalkContext(event.getBusinessId());
|
||||
DeviceResult deviceResult = super.queryDeviceResult(event.getDeviceId(), context);
|
||||
if (deviceResult == null) {
|
||||
LOGGER.error("\u67e5\u8be2\u8bbe\u5907\u5931\u8d25\uff0c\u6ca1\u6709\u627e\u5230\u8bbe\u5907\u4fe1\u606f\uff0c\u8bbe\u5907\u7f16\u7801\uff1a{}", (Object)event.getDeviceId());
|
||||
return;
|
||||
}
|
||||
for (FaceCapture face : event.getFace()) {
|
||||
try {
|
||||
FeatureQueryResult queryResult = this.featureQuery(event, face, context);
|
||||
BigDecimal threshold = BigDecimal.valueOf(this.attendanceProperties.getCaptureDeviceThreshold());
|
||||
if (queryResult == null) {
|
||||
LOGGER.info("\u8003\u52e4\u7ed3\u679c\u751f\u6210\uff0c1:N \u5931\u8d25\u6ca1\u6709\u627e\u5230\u4eba\u5458\u4fe1\u606f,captureId\uff1a{}", (Object)face.getCaptureId());
|
||||
continue;
|
||||
}
|
||||
if (!this.compareSuccess(queryResult, threshold)) {
|
||||
LOGGER.info("\u9608\u503c\u6821\u9a8c\u5931\u8d25\uff0ccaptureId\uff1a{},\u9608\u503c\uff1a{}\uff0c\u6bd4\u5bf9\u5206\u6570\uff1a{}", new Object[]{face.getCaptureId(), threshold, queryResult.getScore()});
|
||||
continue;
|
||||
}
|
||||
AttendResultSignParam signParam = this.setSignParam(event, face, queryResult, deviceResult, threshold);
|
||||
LOGGER.info("\u8003\u52e4\u7ed3\u679c\u751f\u6210\uff0c\u540e\u7aef\u8bc6\u522b\u5206\u6570\uff1a{},\u7b7e\u5230\u5165\u53c2\uff1a{}", (Object)queryResult.getScore(), (Object)signParam);
|
||||
CloudwalkResult genResult = this.attendResultGenService.gen(signParam, context);
|
||||
if (!genResult.isSuccess()) continue;
|
||||
this.publish(event, face, queryResult, threshold);
|
||||
}
|
||||
catch (Exception e) {
|
||||
LOGGER.error("\u751f\u6210\u8003\u52e4\u7ed3\u679c\u5931\u8d25\uff0ccaptureId\uff1a{}\uff0c\u539f\u56e0\uff1a", (Object)face.getCaptureId(), (Object)e);
|
||||
}
|
||||
}
|
||||
}
|
||||
catch (Exception e) {
|
||||
LOGGER.error("\u6d88\u8d39\u4eba\u8138\u6293\u62cd\u8bb0\u5f55\u5931\u8d25\uff0c\u539f\u56e0:", (Throwable)e);
|
||||
}
|
||||
finally {
|
||||
FeignThreadLocalUtil.remove();
|
||||
}
|
||||
}
|
||||
|
||||
private boolean compareSuccess(FeatureQueryResult queryResult, BigDecimal threshold) {
|
||||
return BigDecimal.valueOf(queryResult.getScore() * 100.0).compareTo(threshold) >= 0;
|
||||
}
|
||||
|
||||
private FeatureQueryResult featureQuery(FaceCaptureEvent event, FaceCapture face, CloudwalkCallContext context) throws ServiceException {
|
||||
CaptureFeatureQueryParam param = new CaptureFeatureQueryParam();
|
||||
param.setDeviceCode(event.getDeviceId());
|
||||
param.setImagePath(face.getImagePath());
|
||||
return this.biologyFeatureService.featureQuery(param, context);
|
||||
}
|
||||
|
||||
private AttendResultSignParam setSignParam(FaceCaptureEvent event, FaceCapture face, FeatureQueryResult result, DeviceResult deviceResult, BigDecimal threshold) {
|
||||
AttendResultSignParam signParam = new AttendResultSignParam();
|
||||
signParam.setImageId(result.getImageId());
|
||||
signParam.setBusinessId(event.getBusinessId());
|
||||
signParam.setDeviceCode(event.getDeviceId());
|
||||
signParam.setSignTime(Long.valueOf(face.getCaptureTime()));
|
||||
signParam.setFaceUrl(face.getImagePath());
|
||||
if (event.getPanorama() != null) {
|
||||
signParam.setPanoramaPath(event.getPanorama().getPanoramaImagePath());
|
||||
}
|
||||
signParam.setScore(BigDecimal.valueOf(result.getScore()));
|
||||
signParam.setThreshold(threshold);
|
||||
signParam.setStatus(YesNoTypeEnum.Y.getCode());
|
||||
super.setDevice(signParam, deviceResult);
|
||||
return signParam;
|
||||
}
|
||||
|
||||
private void publish(FaceCaptureEvent captureEvent, FaceCapture face, FeatureQueryResult result, BigDecimal threshold) {
|
||||
OpendoorFaceCaptureRecordEvent event;
|
||||
event.setLogId((event = (OpendoorFaceCaptureRecordEvent)BeanCopyUtils.copyProperties((Object)captureEvent, OpendoorFaceCaptureRecordEvent.class)).getLogId() != null ? event.getLogId() : "" + System.currentTimeMillis());
|
||||
event.setMessageId("" + System.currentTimeMillis());
|
||||
event.setAppServiceCode("smart-attendance");
|
||||
event.setOpenDoorType("FACE");
|
||||
event.setRecognitionNo(face.getCaptureId());
|
||||
event.setRecognitionTime(Long.valueOf(face.getCaptureTime()));
|
||||
event.setFaceImagePath(face.getImagePath());
|
||||
event.setServiceCode("access-control");
|
||||
if (captureEvent.getPanorama() != null) {
|
||||
event.setPanoramaImagePath(captureEvent.getPanorama().getPanoramaImagePath());
|
||||
}
|
||||
event.setThreshold(threshold.floatValue());
|
||||
event.setFaceId(result.getImageId());
|
||||
event.setScore(new Float(result.getScore()));
|
||||
if (face.getFaceQuality() != null) {
|
||||
event.setQualityScore(face.getFaceQuality().getQualityScore());
|
||||
}
|
||||
event.setGroupId(result.getImageStoreId());
|
||||
this.cloudwalkEventManager.publish((BaseEvent)event);
|
||||
}
|
||||
}
|
||||
|
||||
+114
@@ -0,0 +1,114 @@
|
||||
/*
|
||||
* Decompiled with CFR 0.152.
|
||||
*
|
||||
* Could not load the following classes:
|
||||
* cn.cloudwalk.client.cwoscomponent.intelligent.device.result.DeviceResult
|
||||
* cn.cloudwalk.client.ninca.attendance.result.param.AttendResultSignParam
|
||||
* cn.cloudwalk.client.ninca.attendance.result.service.AttendResultGenService
|
||||
* cn.cloudwalk.cloud.context.CloudwalkCallContext
|
||||
* cn.cloudwalk.common.ninca.attendance.config.FeignThreadLocalUtil
|
||||
* cn.cloudwalk.cwos.client.event.event.PersonRecordUploadEvent
|
||||
* cn.cloudwalk.cwos.client.event.event.mode.Face
|
||||
* cn.cloudwalk.event.annotation.EventTopicSuffix
|
||||
* cn.cloudwalk.event.handler.EventHandler
|
||||
* com.alibaba.fastjson.JSON
|
||||
* org.slf4j.Logger
|
||||
* org.slf4j.LoggerFactory
|
||||
* org.springframework.beans.factory.annotation.Autowired
|
||||
* org.springframework.stereotype.Component
|
||||
*/
|
||||
package cn.cloudwalk.web.ninca.attendance.handler;
|
||||
|
||||
import cn.cloudwalk.client.cwoscomponent.intelligent.device.result.DeviceResult;
|
||||
import cn.cloudwalk.client.ninca.attendance.result.param.AttendResultSignParam;
|
||||
import cn.cloudwalk.client.ninca.attendance.result.service.AttendResultGenService;
|
||||
import cn.cloudwalk.cloud.context.CloudwalkCallContext;
|
||||
import cn.cloudwalk.common.ninca.attendance.config.FeignThreadLocalUtil;
|
||||
import cn.cloudwalk.cwos.client.event.event.PersonRecordUploadEvent;
|
||||
import cn.cloudwalk.cwos.client.event.event.mode.Face;
|
||||
import cn.cloudwalk.event.annotation.EventTopicSuffix;
|
||||
import cn.cloudwalk.event.handler.EventHandler;
|
||||
import cn.cloudwalk.web.ninca.attendance.handler.AbstractEventHandler;
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import java.math.BigDecimal;
|
||||
import java.util.ArrayList;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Component;
|
||||
|
||||
@Component
|
||||
@EventTopicSuffix(value={"smart-attendance"})
|
||||
public class AttendPersonRecordEventHandler
|
||||
extends AbstractEventHandler
|
||||
implements EventHandler<PersonRecordUploadEvent> {
|
||||
private static final Logger LOGGER = LoggerFactory.getLogger(AttendPersonRecordEventHandler.class);
|
||||
@Autowired
|
||||
private AttendResultGenService attendResultGenService;
|
||||
|
||||
/*
|
||||
* WARNING - Removed try catching itself - possible behaviour change.
|
||||
*/
|
||||
public void onEvent(PersonRecordUploadEvent personRecordUploadEvent) {
|
||||
LOGGER.info("\u6536\u5230personRecordUploadEvent\u6d88\u606f:{}", (Object)JSON.toJSONString((Object)personRecordUploadEvent));
|
||||
try {
|
||||
CloudwalkCallContext context = this.getCloudwalkContext(personRecordUploadEvent.getBusinessId());
|
||||
DeviceResult deviceResult = super.queryDeviceResult(personRecordUploadEvent.getDeviceId(), context);
|
||||
if (deviceResult == null) {
|
||||
LOGGER.error("\u67e5\u8be2\u8bbe\u5907\u5931\u8d25\uff0c\u6ca1\u6709\u627e\u5230\u8bbe\u5907\u4fe1\u606f\uff0c\u8bbe\u5907\u7f16\u7801\uff1a{}", (Object)personRecordUploadEvent.getDeviceId());
|
||||
return;
|
||||
}
|
||||
List<Face> faces = this.filter(personRecordUploadEvent.getFaces());
|
||||
for (Face face : faces) {
|
||||
try {
|
||||
if (face.getRecognitionResult() != null && face.getRecognitionResult().equals(2)) {
|
||||
LOGGER.info("\u8be5\u4eba\u8138\u8bc6\u522b\u7ed3\u679c\u4e0d\u7a7a\uff0c\u4e14\u8bc6\u522b\u7ed3\u679c\u5931\u8d25\uff0c\u5ffd\u7565\u8be5\u6d88\u606f\uff0cfaceId={}", (Object)face.getFaceId());
|
||||
continue;
|
||||
}
|
||||
AttendResultSignParam signParam = this.setSignParam(personRecordUploadEvent, face, deviceResult);
|
||||
LOGGER.info("\u8003\u52e4\u7ed3\u679c\u751f\u6210\uff0c\u7b7e\u5230\u5165\u53c2\uff1a{}", (Object)signParam);
|
||||
this.attendResultGenService.gen(signParam, context);
|
||||
}
|
||||
catch (Exception e) {
|
||||
LOGGER.error("\u751f\u6210\u8003\u52e4\u7ed3\u679c\u5931\u8d25\uff0cfaceId\uff1a{}\uff0c\u539f\u56e0\uff1a", (Object)face.getFaceId(), (Object)e);
|
||||
}
|
||||
}
|
||||
}
|
||||
catch (Exception e) {
|
||||
LOGGER.error("\u6d88\u8d39\u4eba\u5458\u8bc6\u522b\u8bb0\u5f55\u5931\u8d25\uff0c\u539f\u56e0:", (Throwable)e);
|
||||
}
|
||||
finally {
|
||||
FeignThreadLocalUtil.remove();
|
||||
}
|
||||
}
|
||||
|
||||
private List<Face> filter(List<Face> faces) {
|
||||
HashMap<String, Face> tmpMap = new HashMap<String, Face>(faces.size());
|
||||
for (Face face : faces) {
|
||||
tmpMap.put(face.getFaceId() + face.getRecognitionTime(), face);
|
||||
}
|
||||
ArrayList<Face> list = new ArrayList<Face>(tmpMap.size());
|
||||
tmpMap.forEach((k, v) -> list.add((Face)v));
|
||||
return list;
|
||||
}
|
||||
|
||||
private AttendResultSignParam setSignParam(PersonRecordUploadEvent event, Face face, DeviceResult deviceResult) {
|
||||
AttendResultSignParam signParam = new AttendResultSignParam();
|
||||
signParam.setImageId(face.getFaceId());
|
||||
signParam.setBusinessId(event.getBusinessId());
|
||||
signParam.setDeviceCode(event.getDeviceId());
|
||||
signParam.setSignTime(face.getRecognitionTime());
|
||||
signParam.setFaceUrl(face.getFaceImagePath());
|
||||
if (event.getPanoramaData() != null) {
|
||||
signParam.setPanoramaPath(event.getPanoramaData().getPanoramaImagePath());
|
||||
}
|
||||
signParam.setScore(BigDecimal.valueOf(face.getScore().floatValue()));
|
||||
signParam.setThreshold(BigDecimal.valueOf(event.getThreshold()));
|
||||
signParam.setStatus(face.getRecognitionResult());
|
||||
super.setDevice(signParam, deviceResult);
|
||||
return signParam;
|
||||
}
|
||||
}
|
||||
|
||||
+53
@@ -0,0 +1,53 @@
|
||||
/*
|
||||
* Decompiled with CFR 0.152.
|
||||
*
|
||||
* Could not load the following classes:
|
||||
* cn.cloudwalk.client.ninca.attendance.holiday.param.HolidayListParam
|
||||
* cn.cloudwalk.client.ninca.attendance.holiday.service.HolidayService
|
||||
* cn.cloudwalk.client.ninca.attendance.rule.result.AttendRuleHolidayQueryResult
|
||||
* cn.cloudwalk.cloud.exception.ServiceException
|
||||
* cn.cloudwalk.cloud.result.CloudwalkResult
|
||||
* cn.cloudwalk.cloud.utils.BeanCopyUtils
|
||||
* javax.annotation.Resource
|
||||
* org.springframework.web.bind.annotation.PostMapping
|
||||
* org.springframework.web.bind.annotation.RequestBody
|
||||
* org.springframework.web.bind.annotation.RequestMapping
|
||||
* org.springframework.web.bind.annotation.RestController
|
||||
*/
|
||||
package cn.cloudwalk.web.ninca.attendance.holiday.controller;
|
||||
|
||||
import cn.cloudwalk.client.ninca.attendance.holiday.param.HolidayListParam;
|
||||
import cn.cloudwalk.client.ninca.attendance.holiday.service.HolidayService;
|
||||
import cn.cloudwalk.client.ninca.attendance.rule.result.AttendRuleHolidayQueryResult;
|
||||
import cn.cloudwalk.cloud.exception.ServiceException;
|
||||
import cn.cloudwalk.cloud.result.CloudwalkResult;
|
||||
import cn.cloudwalk.cloud.utils.BeanCopyUtils;
|
||||
import cn.cloudwalk.web.ninca.attendance.common.AbstractCloudwalkController;
|
||||
import cn.cloudwalk.web.ninca.attendance.holiday.form.HolidayListForm;
|
||||
import java.util.List;
|
||||
import javax.annotation.Resource;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestBody;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
@RestController
|
||||
@RequestMapping(value={"/intelligent/api/sys/holiday"})
|
||||
public class HolidayController
|
||||
extends AbstractCloudwalkController {
|
||||
@Resource
|
||||
private HolidayService holidayService;
|
||||
|
||||
@PostMapping(value={"/list"})
|
||||
public CloudwalkResult<List<AttendRuleHolidayQueryResult>> list(@RequestBody HolidayListForm form) {
|
||||
HolidayListParam param = (HolidayListParam)BeanCopyUtils.copyProperties((Object)form, HolidayListParam.class);
|
||||
try {
|
||||
return this.holidayService.list(param, this.getCloudwalkContext());
|
||||
}
|
||||
catch (ServiceException e) {
|
||||
this.logger.error("\u67e5\u8be2\u7cfb\u7edf\u8282\u5047\u65e5\u914d\u7f6e\u5931\u8d25\uff0c\u539f\u56e0", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76241101", (String)this.getMessage("76241101"));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
+30
@@ -0,0 +1,30 @@
|
||||
/*
|
||||
* Decompiled with CFR 0.152.
|
||||
*/
|
||||
package cn.cloudwalk.web.ninca.attendance.holiday.form;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
public class HolidayListForm
|
||||
implements Serializable {
|
||||
private static final long serialVersionUID = -7055271489503586640L;
|
||||
private Long startDate;
|
||||
private Long endDate;
|
||||
|
||||
public Long getStartDate() {
|
||||
return this.startDate;
|
||||
}
|
||||
|
||||
public void setStartDate(Long startDate) {
|
||||
this.startDate = startDate;
|
||||
}
|
||||
|
||||
public Long getEndDate() {
|
||||
return this.endDate;
|
||||
}
|
||||
|
||||
public void setEndDate(Long endDate) {
|
||||
this.endDate = endDate;
|
||||
}
|
||||
}
|
||||
|
||||
+66
@@ -0,0 +1,66 @@
|
||||
/*
|
||||
* Decompiled with CFR 0.152.
|
||||
*
|
||||
* Could not load the following classes:
|
||||
* cn.cloudwalk.client.ninca.attendance.report.param.AttendReportDetailParam
|
||||
* cn.cloudwalk.client.ninca.attendance.report.service.AttendReportService
|
||||
* cn.cloudwalk.cloud.exception.ServiceException
|
||||
* cn.cloudwalk.cloud.page.CloudwalkPageAble
|
||||
* cn.cloudwalk.cloud.page.CloudwalkPageInfo
|
||||
* cn.cloudwalk.cloud.result.CloudwalkResult
|
||||
* cn.cloudwalk.cloud.utils.BeanCopyUtils
|
||||
* cn.cloudwalk.common.ninca.attendance.util.CollectionUtils
|
||||
* javax.annotation.Resource
|
||||
* org.springframework.web.bind.annotation.PostMapping
|
||||
* org.springframework.web.bind.annotation.RequestBody
|
||||
* org.springframework.web.bind.annotation.RequestMapping
|
||||
* org.springframework.web.bind.annotation.RestController
|
||||
*/
|
||||
package cn.cloudwalk.web.ninca.attendance.open.controller;
|
||||
|
||||
import cn.cloudwalk.client.ninca.attendance.report.param.AttendReportDetailParam;
|
||||
import cn.cloudwalk.client.ninca.attendance.report.service.AttendReportService;
|
||||
import cn.cloudwalk.cloud.exception.ServiceException;
|
||||
import cn.cloudwalk.cloud.page.CloudwalkPageAble;
|
||||
import cn.cloudwalk.cloud.page.CloudwalkPageInfo;
|
||||
import cn.cloudwalk.cloud.result.CloudwalkResult;
|
||||
import cn.cloudwalk.cloud.utils.BeanCopyUtils;
|
||||
import cn.cloudwalk.common.ninca.attendance.util.CollectionUtils;
|
||||
import cn.cloudwalk.web.ninca.attendance.common.AbstractAttendanceController;
|
||||
import cn.cloudwalk.web.ninca.attendance.open.form.AttendReportDetailOpenForm;
|
||||
import cn.cloudwalk.web.ninca.attendance.open.result.AttendReportDetailOpenResult;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Collection;
|
||||
import java.util.List;
|
||||
import javax.annotation.Resource;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestBody;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
@RestController
|
||||
@RequestMapping(value={"/intelligent/open/report/attend"})
|
||||
public class AttendReportOpenController
|
||||
extends AbstractAttendanceController {
|
||||
@Resource
|
||||
private AttendReportService attendReportService;
|
||||
|
||||
@PostMapping(value={"/detail"})
|
||||
public CloudwalkResult<CloudwalkPageAble<AttendReportDetailOpenResult>> detail(@RequestBody AttendReportDetailOpenForm form) {
|
||||
AttendReportDetailParam param = (AttendReportDetailParam)BeanCopyUtils.copyProperties((Object)form, AttendReportDetailParam.class);
|
||||
CloudwalkPageInfo pageInfo = new CloudwalkPageInfo(form.getCurrentPage(), form.getRowsOfPage());
|
||||
try {
|
||||
CloudwalkResult detail = this.attendReportService.detail(param, pageInfo, this.getCloudwalkContext());
|
||||
if (!detail.isSuccess() || CollectionUtils.isEmpty((Collection)((CloudwalkPageAble)detail.getData()).getDatas())) {
|
||||
return CloudwalkResult.success((Object)new CloudwalkPageAble(new ArrayList(), pageInfo, 0L));
|
||||
}
|
||||
List resultList = BeanCopyUtils.copy((Collection)((CloudwalkPageAble)detail.getData()).getDatas(), AttendReportDetailOpenResult.class);
|
||||
return CloudwalkResult.success((Object)new CloudwalkPageAble((Collection)resultList, pageInfo, ((CloudwalkPageAble)detail.getData()).getTotalRows()));
|
||||
}
|
||||
catch (ServiceException e) {
|
||||
this.logger.error("\u8003\u52e4\u8bb0\u5f55\u8be6\u60c5\u5bf9\u5916\u63a5\u53e3\u67e5\u8be2\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240600", (String)this.getMessage("76240600"));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
+53
@@ -0,0 +1,53 @@
|
||||
/*
|
||||
* Decompiled with CFR 0.152.
|
||||
*
|
||||
* Could not load the following classes:
|
||||
* cn.cloudwalk.cloud.page.CloudwalkBasePageForm
|
||||
*/
|
||||
package cn.cloudwalk.web.ninca.attendance.open.form;
|
||||
|
||||
import cn.cloudwalk.cloud.page.CloudwalkBasePageForm;
|
||||
import java.io.Serializable;
|
||||
|
||||
public class AttendReportDetailOpenForm
|
||||
extends CloudwalkBasePageForm
|
||||
implements Serializable {
|
||||
private static final long serialVersionUID = -6495205794517646452L;
|
||||
private Long startDay;
|
||||
private Long endDay;
|
||||
private Integer state;
|
||||
private Integer initStatus;
|
||||
|
||||
public Long getStartDay() {
|
||||
return this.startDay;
|
||||
}
|
||||
|
||||
public void setStartDay(Long startDay) {
|
||||
this.startDay = startDay;
|
||||
}
|
||||
|
||||
public Long getEndDay() {
|
||||
return this.endDay;
|
||||
}
|
||||
|
||||
public void setEndDay(Long endDay) {
|
||||
this.endDay = endDay;
|
||||
}
|
||||
|
||||
public Integer getState() {
|
||||
return this.state;
|
||||
}
|
||||
|
||||
public void setState(Integer state) {
|
||||
this.state = state;
|
||||
}
|
||||
|
||||
public Integer getInitStatus() {
|
||||
return this.initStatus;
|
||||
}
|
||||
|
||||
public void setInitStatus(Integer initStatus) {
|
||||
this.initStatus = initStatus;
|
||||
}
|
||||
}
|
||||
|
||||
+264
@@ -0,0 +1,264 @@
|
||||
/*
|
||||
* Decompiled with CFR 0.152.
|
||||
*/
|
||||
package cn.cloudwalk.web.ninca.attendance.open.result;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
public class AttendReportDetailOpenResult
|
||||
implements Serializable {
|
||||
private static final long serialVersionUID = 2068768406163986494L;
|
||||
private String id;
|
||||
private String orgName;
|
||||
private String personName;
|
||||
private String personId;
|
||||
private Long attDay;
|
||||
private Long startWorkTime;
|
||||
private Long endWorkTime;
|
||||
private String ruleName;
|
||||
private String ruleId;
|
||||
private Integer ruleType;
|
||||
private Integer reason;
|
||||
private Long correctTime;
|
||||
private Integer initStatus;
|
||||
private Integer endStatus;
|
||||
private String workHours;
|
||||
private Integer startWorkState;
|
||||
private Integer endWorkState;
|
||||
private Long ruleStartWorkTime;
|
||||
private Long ruleEndWorkTime;
|
||||
private String telephone;
|
||||
private Integer isOverTime;
|
||||
private String overTime;
|
||||
private Integer signCount;
|
||||
private String reasonDesc;
|
||||
private String startDeviceName;
|
||||
private String startDeviceAddress;
|
||||
private String endDeviceName;
|
||||
private String endDeviceAddress;
|
||||
|
||||
public String getId() {
|
||||
return this.id;
|
||||
}
|
||||
|
||||
public void setId(String id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public String getOrgName() {
|
||||
return this.orgName;
|
||||
}
|
||||
|
||||
public void setOrgName(String orgName) {
|
||||
this.orgName = orgName;
|
||||
}
|
||||
|
||||
public String getPersonName() {
|
||||
return this.personName;
|
||||
}
|
||||
|
||||
public void setPersonName(String personName) {
|
||||
this.personName = personName;
|
||||
}
|
||||
|
||||
public String getPersonId() {
|
||||
return this.personId;
|
||||
}
|
||||
|
||||
public void setPersonId(String personId) {
|
||||
this.personId = personId;
|
||||
}
|
||||
|
||||
public Long getAttDay() {
|
||||
return this.attDay;
|
||||
}
|
||||
|
||||
public void setAttDay(Long attDay) {
|
||||
this.attDay = attDay;
|
||||
}
|
||||
|
||||
public Long getStartWorkTime() {
|
||||
return this.startWorkTime;
|
||||
}
|
||||
|
||||
public void setStartWorkTime(Long startWorkTime) {
|
||||
this.startWorkTime = startWorkTime;
|
||||
}
|
||||
|
||||
public Long getEndWorkTime() {
|
||||
return this.endWorkTime;
|
||||
}
|
||||
|
||||
public void setEndWorkTime(Long endWorkTime) {
|
||||
this.endWorkTime = endWorkTime;
|
||||
}
|
||||
|
||||
public String getRuleName() {
|
||||
return this.ruleName;
|
||||
}
|
||||
|
||||
public void setRuleName(String ruleName) {
|
||||
this.ruleName = ruleName;
|
||||
}
|
||||
|
||||
public String getRuleId() {
|
||||
return this.ruleId;
|
||||
}
|
||||
|
||||
public void setRuleId(String ruleId) {
|
||||
this.ruleId = ruleId;
|
||||
}
|
||||
|
||||
public Integer getRuleType() {
|
||||
return this.ruleType;
|
||||
}
|
||||
|
||||
public void setRuleType(Integer ruleType) {
|
||||
this.ruleType = ruleType;
|
||||
}
|
||||
|
||||
public Integer getReason() {
|
||||
return this.reason;
|
||||
}
|
||||
|
||||
public void setReason(Integer reason) {
|
||||
this.reason = reason;
|
||||
}
|
||||
|
||||
public Long getCorrectTime() {
|
||||
return this.correctTime;
|
||||
}
|
||||
|
||||
public void setCorrectTime(Long correctTime) {
|
||||
this.correctTime = correctTime;
|
||||
}
|
||||
|
||||
public Integer getInitStatus() {
|
||||
return this.initStatus;
|
||||
}
|
||||
|
||||
public void setInitStatus(Integer initStatus) {
|
||||
this.initStatus = initStatus;
|
||||
}
|
||||
|
||||
public Integer getEndStatus() {
|
||||
return this.endStatus;
|
||||
}
|
||||
|
||||
public void setEndStatus(Integer endStatus) {
|
||||
this.endStatus = endStatus;
|
||||
}
|
||||
|
||||
public String getWorkHours() {
|
||||
return this.workHours;
|
||||
}
|
||||
|
||||
public void setWorkHours(String workHours) {
|
||||
this.workHours = workHours;
|
||||
}
|
||||
|
||||
public Integer getStartWorkState() {
|
||||
return this.startWorkState;
|
||||
}
|
||||
|
||||
public void setStartWorkState(Integer startWorkState) {
|
||||
this.startWorkState = startWorkState;
|
||||
}
|
||||
|
||||
public Integer getEndWorkState() {
|
||||
return this.endWorkState;
|
||||
}
|
||||
|
||||
public void setEndWorkState(Integer endWorkState) {
|
||||
this.endWorkState = endWorkState;
|
||||
}
|
||||
|
||||
public Long getRuleStartWorkTime() {
|
||||
return this.ruleStartWorkTime;
|
||||
}
|
||||
|
||||
public void setRuleStartWorkTime(Long ruleStartWorkTime) {
|
||||
this.ruleStartWorkTime = ruleStartWorkTime;
|
||||
}
|
||||
|
||||
public Long getRuleEndWorkTime() {
|
||||
return this.ruleEndWorkTime;
|
||||
}
|
||||
|
||||
public void setRuleEndWorkTime(Long ruleEndWorkTime) {
|
||||
this.ruleEndWorkTime = ruleEndWorkTime;
|
||||
}
|
||||
|
||||
public String getTelephone() {
|
||||
return this.telephone;
|
||||
}
|
||||
|
||||
public void setTelephone(String telephone) {
|
||||
this.telephone = telephone;
|
||||
}
|
||||
|
||||
public Integer getIsOverTime() {
|
||||
return this.isOverTime;
|
||||
}
|
||||
|
||||
public void setIsOverTime(Integer isOverTime) {
|
||||
this.isOverTime = isOverTime;
|
||||
}
|
||||
|
||||
public String getOverTime() {
|
||||
return this.overTime;
|
||||
}
|
||||
|
||||
public void setOverTime(String overTime) {
|
||||
this.overTime = overTime;
|
||||
}
|
||||
|
||||
public Integer getSignCount() {
|
||||
return this.signCount;
|
||||
}
|
||||
|
||||
public void setSignCount(Integer signCount) {
|
||||
this.signCount = signCount;
|
||||
}
|
||||
|
||||
public String getReasonDesc() {
|
||||
return this.reasonDesc;
|
||||
}
|
||||
|
||||
public void setReasonDesc(String reasonDesc) {
|
||||
this.reasonDesc = reasonDesc;
|
||||
}
|
||||
|
||||
public String getStartDeviceName() {
|
||||
return this.startDeviceName;
|
||||
}
|
||||
|
||||
public void setStartDeviceName(String startDeviceName) {
|
||||
this.startDeviceName = startDeviceName;
|
||||
}
|
||||
|
||||
public String getStartDeviceAddress() {
|
||||
return this.startDeviceAddress;
|
||||
}
|
||||
|
||||
public void setStartDeviceAddress(String startDeviceAddress) {
|
||||
this.startDeviceAddress = startDeviceAddress;
|
||||
}
|
||||
|
||||
public String getEndDeviceName() {
|
||||
return this.endDeviceName;
|
||||
}
|
||||
|
||||
public void setEndDeviceName(String endDeviceName) {
|
||||
this.endDeviceName = endDeviceName;
|
||||
}
|
||||
|
||||
public String getEndDeviceAddress() {
|
||||
return this.endDeviceAddress;
|
||||
}
|
||||
|
||||
public void setEndDeviceAddress(String endDeviceAddress) {
|
||||
this.endDeviceAddress = endDeviceAddress;
|
||||
}
|
||||
}
|
||||
|
||||
+331
@@ -0,0 +1,331 @@
|
||||
/*
|
||||
* Decompiled with CFR 0.152.
|
||||
*
|
||||
* Could not load the following classes:
|
||||
* cn.cloudwalk.client.cwoscomponent.intelligent.organization.result.OrganizationResult
|
||||
* cn.cloudwalk.client.davinci.portal.user.result.PortalUserDetailResult
|
||||
* cn.cloudwalk.client.ninca.attendance.report.param.AttendDayReportQueryParam
|
||||
* cn.cloudwalk.client.ninca.attendance.report.param.AttendReportCorrectionParam
|
||||
* cn.cloudwalk.client.ninca.attendance.report.param.AttendReportDetailParam
|
||||
* cn.cloudwalk.client.ninca.attendance.report.param.AttendReportRecordParam
|
||||
* cn.cloudwalk.client.ninca.attendance.report.param.AttendReportStatisticalParam
|
||||
* cn.cloudwalk.client.ninca.attendance.report.result.AttendReportDetailExcelResult
|
||||
* cn.cloudwalk.client.ninca.attendance.report.result.AttendReportDetailResult
|
||||
* cn.cloudwalk.client.ninca.attendance.report.result.AttendReportRecordResult
|
||||
* cn.cloudwalk.client.ninca.attendance.report.result.AttendReportStatisticalExcelResult
|
||||
* cn.cloudwalk.client.ninca.attendance.report.result.AttendReportStatisticalResult
|
||||
* cn.cloudwalk.client.ninca.attendance.report.service.AttendReportQueryService
|
||||
* cn.cloudwalk.client.ninca.attendance.report.service.AttendReportService
|
||||
* cn.cloudwalk.cloud.exception.ServiceException
|
||||
* cn.cloudwalk.cloud.page.CloudwalkPageAble
|
||||
* cn.cloudwalk.cloud.page.CloudwalkPageInfo
|
||||
* cn.cloudwalk.cloud.result.CloudwalkResult
|
||||
* cn.cloudwalk.cloud.utils.BeanCopyUtils
|
||||
* cn.cloudwalk.common.ninca.attendance.util.CollectionUtils
|
||||
* cn.cloudwalk.service.ninca.attendance.export.AttendResultDetailExportAsyncService
|
||||
* cn.cloudwalk.service.ninca.attendance.export.AttendResultStatisticalExportAsyncService
|
||||
* javax.annotation.Resource
|
||||
* org.springframework.beans.factory.annotation.Autowired
|
||||
* org.springframework.validation.BindingResult
|
||||
* org.springframework.validation.ObjectError
|
||||
* org.springframework.web.bind.annotation.PostMapping
|
||||
* org.springframework.web.bind.annotation.RequestBody
|
||||
* org.springframework.web.bind.annotation.RequestMapping
|
||||
* org.springframework.web.bind.annotation.RestController
|
||||
*/
|
||||
package cn.cloudwalk.web.ninca.attendance.report.controller;
|
||||
|
||||
import cn.cloudwalk.client.cwoscomponent.intelligent.organization.result.OrganizationResult;
|
||||
import cn.cloudwalk.client.davinci.portal.user.result.PortalUserDetailResult;
|
||||
import cn.cloudwalk.client.ninca.attendance.report.param.AttendDayReportQueryParam;
|
||||
import cn.cloudwalk.client.ninca.attendance.report.param.AttendReportCorrectionParam;
|
||||
import cn.cloudwalk.client.ninca.attendance.report.param.AttendReportDetailParam;
|
||||
import cn.cloudwalk.client.ninca.attendance.report.param.AttendReportRecordParam;
|
||||
import cn.cloudwalk.client.ninca.attendance.report.param.AttendReportStatisticalParam;
|
||||
import cn.cloudwalk.client.ninca.attendance.report.result.AttendReportDetailExcelResult;
|
||||
import cn.cloudwalk.client.ninca.attendance.report.result.AttendReportDetailResult;
|
||||
import cn.cloudwalk.client.ninca.attendance.report.result.AttendReportRecordResult;
|
||||
import cn.cloudwalk.client.ninca.attendance.report.result.AttendReportStatisticalExcelResult;
|
||||
import cn.cloudwalk.client.ninca.attendance.report.result.AttendReportStatisticalResult;
|
||||
import cn.cloudwalk.client.ninca.attendance.report.service.AttendReportQueryService;
|
||||
import cn.cloudwalk.client.ninca.attendance.report.service.AttendReportService;
|
||||
import cn.cloudwalk.cloud.exception.ServiceException;
|
||||
import cn.cloudwalk.cloud.page.CloudwalkPageAble;
|
||||
import cn.cloudwalk.cloud.page.CloudwalkPageInfo;
|
||||
import cn.cloudwalk.cloud.result.CloudwalkResult;
|
||||
import cn.cloudwalk.cloud.utils.BeanCopyUtils;
|
||||
import cn.cloudwalk.common.ninca.attendance.util.CollectionUtils;
|
||||
import cn.cloudwalk.service.ninca.attendance.export.AttendResultDetailExportAsyncService;
|
||||
import cn.cloudwalk.service.ninca.attendance.export.AttendResultStatisticalExportAsyncService;
|
||||
import cn.cloudwalk.web.ninca.attendance.common.AbstractAttendanceController;
|
||||
import cn.cloudwalk.web.ninca.attendance.report.form.AttendReportCorrectionForm;
|
||||
import cn.cloudwalk.web.ninca.attendance.report.form.AttendReportDetailForm;
|
||||
import cn.cloudwalk.web.ninca.attendance.report.form.AttendReportRecordForm;
|
||||
import cn.cloudwalk.web.ninca.attendance.report.form.AttendReportStatisticalForm;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Collection;
|
||||
import java.util.Collections;
|
||||
import java.util.List;
|
||||
import javax.annotation.Resource;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.validation.BindingResult;
|
||||
import org.springframework.validation.ObjectError;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestBody;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
@RestController
|
||||
@RequestMapping(value={"/intelligent/api/report/attend"})
|
||||
public class AttendReportController
|
||||
extends AbstractAttendanceController {
|
||||
@Resource
|
||||
private AttendReportService attendReportService;
|
||||
@Resource
|
||||
private AttendResultDetailExportAsyncService attendResultDetailExportAsyncService;
|
||||
@Resource
|
||||
private AttendResultStatisticalExportAsyncService attendResultStatisticalExportAsyncService;
|
||||
@Autowired
|
||||
private AttendReportQueryService attendReportQueryService;
|
||||
|
||||
@PostMapping(value={"/detail"})
|
||||
public CloudwalkResult<CloudwalkPageAble<AttendReportDetailResult>> detail(@RequestBody AttendReportDetailForm form) {
|
||||
AttendReportDetailParam param = (AttendReportDetailParam)BeanCopyUtils.copyProperties((Object)form, AttendReportDetailParam.class);
|
||||
CloudwalkPageInfo pageInfo = new CloudwalkPageInfo(form.getCurrentPage(), form.getRowsOfPage());
|
||||
try {
|
||||
PortalUserDetailResult userDetail = super.currentUserPersonId();
|
||||
if (userDetail == null) {
|
||||
return CloudwalkResult.success((Object)new CloudwalkPageAble(new ArrayList(), pageInfo, 0L));
|
||||
}
|
||||
param.setRoleIds(userDetail.getRoleIds());
|
||||
return this.attendReportService.detail(param, pageInfo, this.getCloudwalkContext());
|
||||
}
|
||||
catch (ServiceException e) {
|
||||
this.logger.error("\u8003\u52e4\u8bb0\u5f55\u8be6\u60c5\u67e5\u8be2\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240214", (String)this.getMessage("76240214"));
|
||||
}
|
||||
}
|
||||
|
||||
@PostMapping(value={"/detail/self"})
|
||||
public CloudwalkResult<CloudwalkPageAble<AttendReportDetailResult>> detailSelf(@RequestBody AttendReportDetailForm form) {
|
||||
AttendReportDetailParam param = (AttendReportDetailParam)BeanCopyUtils.copyProperties((Object)form, AttendReportDetailParam.class);
|
||||
CloudwalkPageInfo pageInfo = new CloudwalkPageInfo(form.getCurrentPage(), form.getRowsOfPage());
|
||||
try {
|
||||
PortalUserDetailResult userDetail = super.currentUserPersonId();
|
||||
if (userDetail == null) {
|
||||
return CloudwalkResult.success((Object)new CloudwalkPageAble(new ArrayList(), pageInfo, 0L));
|
||||
}
|
||||
param.setPersonIds(Collections.singletonList(userDetail.getPersonId()));
|
||||
param.setRoleIds(userDetail.getRoleIds());
|
||||
return this.attendReportService.detail(param, pageInfo, this.getCloudwalkContext());
|
||||
}
|
||||
catch (ServiceException e) {
|
||||
this.logger.error("\u4e2a\u4eba\u8003\u52e4\u8bb0\u5f55\u8be6\u60c5\u67e5\u8be2\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240236", (String)this.getMessage("76240236"));
|
||||
}
|
||||
}
|
||||
|
||||
@PostMapping(value={"/statistical"})
|
||||
public CloudwalkResult<CloudwalkPageAble<AttendReportStatisticalResult>> statistical(@RequestBody AttendReportStatisticalForm form) {
|
||||
AttendReportStatisticalParam param = (AttendReportStatisticalParam)BeanCopyUtils.copyProperties((Object)form, AttendReportStatisticalParam.class);
|
||||
try {
|
||||
CloudwalkPageInfo pageInfo = new CloudwalkPageInfo(form.getCurrentPage(), form.getRowsOfPage());
|
||||
PortalUserDetailResult userDetail = super.currentUserPersonId();
|
||||
if (userDetail == null) {
|
||||
return CloudwalkResult.success((Object)new CloudwalkPageAble(new ArrayList(), pageInfo, 0L));
|
||||
}
|
||||
param.setRoleIds(userDetail.getRoleIds());
|
||||
return this.attendReportService.statistical(param, pageInfo, this.getCloudwalkContext());
|
||||
}
|
||||
catch (ServiceException e) {
|
||||
this.logger.error("\u8003\u52e4\u8bb0\u5f55\u7edf\u8ba1\u67e5\u8be2\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240215", (String)this.getMessage("76240215"));
|
||||
}
|
||||
}
|
||||
|
||||
@PostMapping(value={"/statistical/self"})
|
||||
public CloudwalkResult<List<AttendReportStatisticalResult>> statisticalSelf(@RequestBody AttendReportStatisticalForm form) {
|
||||
AttendReportStatisticalParam param = (AttendReportStatisticalParam)BeanCopyUtils.copyProperties((Object)form, AttendReportStatisticalParam.class);
|
||||
try {
|
||||
PortalUserDetailResult userDetail = super.currentUserPersonId();
|
||||
if (userDetail == null) {
|
||||
return CloudwalkResult.success(new ArrayList());
|
||||
}
|
||||
param.setPersonIds(Collections.singletonList(userDetail.getPersonId()));
|
||||
param.setRoleIds(userDetail.getRoleIds());
|
||||
CloudwalkPageInfo pageInfo = new CloudwalkPageInfo(form.getCurrentPage(), 999);
|
||||
CloudwalkResult cloudwalkResult = this.attendReportService.statistical(param, pageInfo, this.getCloudwalkContext());
|
||||
if (CollectionUtils.isNotEmpty((Collection)((CloudwalkPageAble)cloudwalkResult.getData()).getDatas())) {
|
||||
return CloudwalkResult.success((Object)((List)((CloudwalkPageAble)cloudwalkResult.getData()).getDatas()));
|
||||
}
|
||||
return CloudwalkResult.success(new ArrayList());
|
||||
}
|
||||
catch (ServiceException e) {
|
||||
this.logger.error("\u4e2a\u4eba\u8003\u52e4\u8bb0\u5f55\u7edf\u8ba1\u67e5\u8be2\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240215", (String)this.getMessage("76240215"));
|
||||
}
|
||||
}
|
||||
|
||||
@PostMapping(value={"/record"})
|
||||
public CloudwalkResult<List<AttendReportRecordResult>> record(@RequestBody AttendReportRecordForm form) {
|
||||
AttendReportRecordParam param = (AttendReportRecordParam)BeanCopyUtils.copyProperties((Object)form, AttendReportRecordParam.class);
|
||||
CloudwalkPageInfo pageInfo = new CloudwalkPageInfo(form.getCurrentPage(), form.getRowsOfPage());
|
||||
try {
|
||||
PortalUserDetailResult userDetail = super.currentUserPersonId();
|
||||
if (userDetail == null) {
|
||||
return CloudwalkResult.success(new ArrayList());
|
||||
}
|
||||
param.setRoleIds(userDetail.getRoleIds());
|
||||
return this.attendReportService.record(param, pageInfo, this.getCloudwalkContext());
|
||||
}
|
||||
catch (ServiceException e) {
|
||||
this.logger.error("\u8003\u52e4\u8d8b\u52bf\u67e5\u8be2\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240216", (String)this.getMessage("76240216"));
|
||||
}
|
||||
}
|
||||
|
||||
@PostMapping(value={"/correction"})
|
||||
public CloudwalkResult<Boolean> correction(@RequestBody AttendReportCorrectionForm form) {
|
||||
AttendReportCorrectionParam param = (AttendReportCorrectionParam)BeanCopyUtils.copyProperties((Object)form, AttendReportCorrectionParam.class);
|
||||
try {
|
||||
return this.attendReportService.correction(param, this.getCloudwalkContext());
|
||||
}
|
||||
catch (ServiceException e) {
|
||||
this.logger.error("\u8003\u52e4\u4fee\u6b63\u52e4\u5f02\u5e38\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240225", (String)this.getMessage("76240225"));
|
||||
}
|
||||
}
|
||||
|
||||
@RequestMapping(value={"/statistical/export"})
|
||||
public CloudwalkResult<Boolean> statisticalExport(@RequestBody AttendReportStatisticalForm form, BindingResult bindingResult) {
|
||||
try {
|
||||
if (bindingResult.hasErrors()) {
|
||||
ObjectError objectError = (ObjectError)bindingResult.getAllErrors().get(0);
|
||||
String code = objectError.getDefaultMessage();
|
||||
return CloudwalkResult.fail((String)code, (String)this.getMessage(code));
|
||||
}
|
||||
AttendReportStatisticalParam param = (AttendReportStatisticalParam)BeanCopyUtils.copyProperties((Object)form, AttendReportStatisticalParam.class);
|
||||
PortalUserDetailResult userDetail = super.currentUserPersonId();
|
||||
if (userDetail == null) {
|
||||
this.logger.info("\u4e2a\u4eba\u6708\u62a5\u8868\u5bfc\u51fa\u8be5\u7528\u6237\u6ca1\u6709\u4eba\u5458\u4fe1\u606f");
|
||||
return CloudwalkResult.fail((String)"76240403", (String)this.getMessage("76240403"));
|
||||
}
|
||||
param.setRoleIds(userDetail.getRoleIds());
|
||||
return this.attendResultStatisticalExportAsyncService.startExportTask((Object)param, AttendReportStatisticalExcelResult.class, null, this.getCloudwalkContext());
|
||||
}
|
||||
catch (Exception e) {
|
||||
this.logger.error("\u8003\u52e4\u7edf\u8ba1\u5bfc\u51fa\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240401", (String)"76240401");
|
||||
}
|
||||
}
|
||||
|
||||
@RequestMapping(value={"/statistical/export/self"})
|
||||
public CloudwalkResult<Boolean> statisticalExportSelf(@RequestBody AttendReportStatisticalForm form, BindingResult bindingResult) {
|
||||
try {
|
||||
if (bindingResult.hasErrors()) {
|
||||
ObjectError objectError = (ObjectError)bindingResult.getAllErrors().get(0);
|
||||
String code = objectError.getDefaultMessage();
|
||||
return CloudwalkResult.fail((String)code, (String)this.getMessage(code));
|
||||
}
|
||||
PortalUserDetailResult userDetail = super.currentUserPersonId();
|
||||
if (userDetail == null) {
|
||||
this.logger.info("\u4e2a\u4eba\u6708\u62a5\u8868\u5bfc\u51fa\u8be5\u7528\u6237\u6ca1\u6709\u4eba\u5458\u4fe1\u606f");
|
||||
return CloudwalkResult.fail((String)"76240403", (String)this.getMessage("76240403"));
|
||||
}
|
||||
AttendReportStatisticalParam param = (AttendReportStatisticalParam)BeanCopyUtils.copyProperties((Object)form, AttendReportStatisticalParam.class);
|
||||
param.setPersonIds(Collections.singletonList(userDetail.getPersonId()));
|
||||
param.setRoleIds(userDetail.getRoleIds());
|
||||
return this.attendResultStatisticalExportAsyncService.startExportTask((Object)param, AttendReportStatisticalExcelResult.class, null, this.getCloudwalkContext());
|
||||
}
|
||||
catch (Exception e) {
|
||||
this.logger.error("\u8003\u52e4\u4e2a\u4eba\u6309\u6708\u62a5\u8868\u67e5\u8be2\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240401", (String)this.getMessage("76240401"));
|
||||
}
|
||||
}
|
||||
|
||||
@RequestMapping(value={"/detail/export"})
|
||||
public CloudwalkResult<Boolean> detailExport(@RequestBody AttendReportDetailForm form, BindingResult bindingResult) {
|
||||
try {
|
||||
if (bindingResult.hasErrors()) {
|
||||
ObjectError objectError = (ObjectError)bindingResult.getAllErrors().get(0);
|
||||
String code = objectError.getDefaultMessage();
|
||||
return CloudwalkResult.fail((String)code, (String)this.getMessage(code));
|
||||
}
|
||||
AttendReportDetailParam param = (AttendReportDetailParam)BeanCopyUtils.copyProperties((Object)form, AttendReportDetailParam.class);
|
||||
PortalUserDetailResult userDetail = super.currentUserPersonId();
|
||||
if (userDetail == null) {
|
||||
this.logger.info("\u8be6\u60c5\u62a5\u8868\u5bfc\u51fa\u8be5\u7528\u6237\u6ca1\u6709\u4eba\u5458\u4fe1\u606f");
|
||||
return CloudwalkResult.fail((String)"76240403", (String)this.getMessage("76240403"));
|
||||
}
|
||||
param.setRoleIds(userDetail.getRoleIds());
|
||||
return this.attendResultDetailExportAsyncService.startExportTask((Object)param, AttendReportDetailExcelResult.class, null, this.getCloudwalkContext());
|
||||
}
|
||||
catch (Exception e) {
|
||||
this.logger.error("\u8003\u52e4\u8be6\u60c5\u5bfc\u51fa\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240402", (String)"76240402");
|
||||
}
|
||||
}
|
||||
|
||||
@RequestMapping(value={"/detail/export/self"})
|
||||
public CloudwalkResult<Boolean> detailExportSelf(@RequestBody AttendReportDetailForm form, BindingResult bindingResult) {
|
||||
try {
|
||||
if (bindingResult.hasErrors()) {
|
||||
ObjectError objectError = (ObjectError)bindingResult.getAllErrors().get(0);
|
||||
String code = objectError.getDefaultMessage();
|
||||
return CloudwalkResult.fail((String)code, (String)this.getMessage(code));
|
||||
}
|
||||
AttendReportDetailParam param = (AttendReportDetailParam)BeanCopyUtils.copyProperties((Object)form, AttendReportDetailParam.class);
|
||||
PortalUserDetailResult userDetail = super.currentUserPersonId();
|
||||
if (userDetail == null) {
|
||||
this.logger.info("\u4e2a\u4eba\u8be6\u60c5\u62a5\u8868\u5bfc\u51fa\u8be5\u7528\u6237\u6ca1\u6709\u4eba\u5458\u4fe1\u606f");
|
||||
return CloudwalkResult.fail((String)"76240403", (String)this.getMessage("76240403"));
|
||||
}
|
||||
param.setPersonIds(Collections.singletonList(userDetail.getPersonId()));
|
||||
param.setRoleIds(userDetail.getRoleIds());
|
||||
return this.attendResultDetailExportAsyncService.startExportTask((Object)param, AttendReportDetailExcelResult.class, null, this.getCloudwalkContext());
|
||||
}
|
||||
catch (Exception e) {
|
||||
this.logger.error("\u8003\u52e4\u4e2a\u4eba\u8be6\u60c5\u62a5\u8868\u5bfc\u51fa\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240402", (String)this.getMessage("76240402"));
|
||||
}
|
||||
}
|
||||
|
||||
@PostMapping(value={"/org/list"})
|
||||
public CloudwalkResult<List<OrganizationResult>> orgList() {
|
||||
try {
|
||||
PortalUserDetailResult userDetail = super.currentUserPersonId();
|
||||
if (userDetail == null) {
|
||||
this.logger.info("\u7ec4\u7ec7\u5217\u8868\u67e5\u8be2\u8be5\u7528\u6237\u6ca1\u6709\u4eba\u5458\u4fe1\u606f");
|
||||
return CloudwalkResult.fail((String)"76240403", (String)this.getMessage("76240403"));
|
||||
}
|
||||
return this.attendReportService.orgList(userDetail.getRoleIds(), this.getCloudwalkContext());
|
||||
}
|
||||
catch (Exception e) {
|
||||
this.logger.error("\u8003\u52e4\u7ec4\u7ec7\u5217\u8868\u67e5\u8be2\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240402", (String)this.getMessage("76240402"));
|
||||
}
|
||||
}
|
||||
|
||||
@RequestMapping(value={"/report/export/count"})
|
||||
public CloudwalkResult<Integer> exportCount() throws ServiceException {
|
||||
try {
|
||||
return this.attendResultStatisticalExportAsyncService.exportCount();
|
||||
}
|
||||
catch (ServiceException e) {
|
||||
this.logger.error("\u83b7\u53d6\u6700\u5927\u5bfc\u51fa\u8bb0\u5f55\u5931\u8d25", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240504", (String)this.getMessage("76240504"));
|
||||
}
|
||||
}
|
||||
|
||||
@PostMapping(value={"statistics"})
|
||||
public CloudwalkResult<?> queryDay(@RequestBody AttendDayReportQueryParam param) {
|
||||
try {
|
||||
return this.attendReportQueryService.queryDay(param, this.getCloudwalkContext());
|
||||
}
|
||||
catch (Exception e) {
|
||||
this.logger.error("\u6309\u5929\u7edf\u8ba1\u6570\u636e\u4fe1\u606f\u5931\u8d25", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240505", (String)this.getMessage("76240505"));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
+30
@@ -0,0 +1,30 @@
|
||||
/*
|
||||
* Decompiled with CFR 0.152.
|
||||
*/
|
||||
package cn.cloudwalk.web.ninca.attendance.report.form;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
public class AttendReportCorrectionForm
|
||||
implements Serializable {
|
||||
private static final long serialVersionUID = -4324358285746716401L;
|
||||
private String id;
|
||||
private Integer reason;
|
||||
|
||||
public String getId() {
|
||||
return this.id;
|
||||
}
|
||||
|
||||
public void setId(String id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public Integer getReason() {
|
||||
return this.reason;
|
||||
}
|
||||
|
||||
public void setReason(Integer reason) {
|
||||
this.reason = reason;
|
||||
}
|
||||
}
|
||||
|
||||
+81
@@ -0,0 +1,81 @@
|
||||
/*
|
||||
* Decompiled with CFR 0.152.
|
||||
*
|
||||
* Could not load the following classes:
|
||||
* cn.cloudwalk.cloud.page.CloudwalkBasePageForm
|
||||
*/
|
||||
package cn.cloudwalk.web.ninca.attendance.report.form;
|
||||
|
||||
import cn.cloudwalk.cloud.page.CloudwalkBasePageForm;
|
||||
import java.io.Serializable;
|
||||
import java.util.List;
|
||||
|
||||
public class AttendReportDetailForm
|
||||
extends CloudwalkBasePageForm
|
||||
implements Serializable {
|
||||
private static final long serialVersionUID = -6495205794517646452L;
|
||||
private Long startDay;
|
||||
private Long endDay;
|
||||
private List<String> orgIds;
|
||||
private List<String> personIds;
|
||||
private Integer state;
|
||||
private Integer initStatus;
|
||||
private List<String> labelIds;
|
||||
|
||||
public Long getStartDay() {
|
||||
return this.startDay;
|
||||
}
|
||||
|
||||
public void setStartDay(Long startDay) {
|
||||
this.startDay = startDay;
|
||||
}
|
||||
|
||||
public Long getEndDay() {
|
||||
return this.endDay;
|
||||
}
|
||||
|
||||
public void setEndDay(Long endDay) {
|
||||
this.endDay = endDay;
|
||||
}
|
||||
|
||||
public List<String> getOrgIds() {
|
||||
return this.orgIds;
|
||||
}
|
||||
|
||||
public void setOrgIds(List<String> orgIds) {
|
||||
this.orgIds = orgIds;
|
||||
}
|
||||
|
||||
public List<String> getPersonIds() {
|
||||
return this.personIds;
|
||||
}
|
||||
|
||||
public void setPersonIds(List<String> personIds) {
|
||||
this.personIds = personIds;
|
||||
}
|
||||
|
||||
public Integer getState() {
|
||||
return this.state;
|
||||
}
|
||||
|
||||
public void setState(Integer state) {
|
||||
this.state = state;
|
||||
}
|
||||
|
||||
public Integer getInitStatus() {
|
||||
return this.initStatus;
|
||||
}
|
||||
|
||||
public void setInitStatus(Integer initStatus) {
|
||||
this.initStatus = initStatus;
|
||||
}
|
||||
|
||||
public List<String> getLabelIds() {
|
||||
return this.labelIds;
|
||||
}
|
||||
|
||||
public void setLabelIds(List<String> labelIds) {
|
||||
this.labelIds = labelIds;
|
||||
}
|
||||
}
|
||||
|
||||
+45
@@ -0,0 +1,45 @@
|
||||
/*
|
||||
* Decompiled with CFR 0.152.
|
||||
*
|
||||
* Could not load the following classes:
|
||||
* cn.cloudwalk.cloud.page.CloudwalkBasePageForm
|
||||
*/
|
||||
package cn.cloudwalk.web.ninca.attendance.report.form;
|
||||
|
||||
import cn.cloudwalk.cloud.page.CloudwalkBasePageForm;
|
||||
import java.io.Serializable;
|
||||
import java.util.List;
|
||||
|
||||
public class AttendReportRecordForm
|
||||
extends CloudwalkBasePageForm
|
||||
implements Serializable {
|
||||
private static final long serialVersionUID = 8573454070860162024L;
|
||||
private Long startDay;
|
||||
private Long endDay;
|
||||
private List<String> orgIds;
|
||||
|
||||
public Long getStartDay() {
|
||||
return this.startDay;
|
||||
}
|
||||
|
||||
public void setStartDay(Long startDay) {
|
||||
this.startDay = startDay;
|
||||
}
|
||||
|
||||
public Long getEndDay() {
|
||||
return this.endDay;
|
||||
}
|
||||
|
||||
public void setEndDay(Long endDay) {
|
||||
this.endDay = endDay;
|
||||
}
|
||||
|
||||
public List<String> getOrgIds() {
|
||||
return this.orgIds;
|
||||
}
|
||||
|
||||
public void setOrgIds(List<String> orgIds) {
|
||||
this.orgIds = orgIds;
|
||||
}
|
||||
}
|
||||
|
||||
+72
@@ -0,0 +1,72 @@
|
||||
/*
|
||||
* Decompiled with CFR 0.152.
|
||||
*
|
||||
* Could not load the following classes:
|
||||
* cn.cloudwalk.cloud.page.CloudwalkBasePageForm
|
||||
*/
|
||||
package cn.cloudwalk.web.ninca.attendance.report.form;
|
||||
|
||||
import cn.cloudwalk.cloud.page.CloudwalkBasePageForm;
|
||||
import java.io.Serializable;
|
||||
import java.util.List;
|
||||
|
||||
public class AttendReportStatisticalForm
|
||||
extends CloudwalkBasePageForm
|
||||
implements Serializable {
|
||||
private static final long serialVersionUID = -8377158990720818821L;
|
||||
private Long startDay;
|
||||
private Long endDay;
|
||||
private List<String> orgIds;
|
||||
private List<String> personIds;
|
||||
private Integer state;
|
||||
private List<String> labelIds;
|
||||
|
||||
public Long getStartDay() {
|
||||
return this.startDay;
|
||||
}
|
||||
|
||||
public void setStartDay(Long startDay) {
|
||||
this.startDay = startDay;
|
||||
}
|
||||
|
||||
public Long getEndDay() {
|
||||
return this.endDay;
|
||||
}
|
||||
|
||||
public void setEndDay(Long endDay) {
|
||||
this.endDay = endDay;
|
||||
}
|
||||
|
||||
public List<String> getOrgIds() {
|
||||
return this.orgIds;
|
||||
}
|
||||
|
||||
public void setOrgIds(List<String> orgIds) {
|
||||
this.orgIds = orgIds;
|
||||
}
|
||||
|
||||
public List<String> getPersonIds() {
|
||||
return this.personIds;
|
||||
}
|
||||
|
||||
public void setPersonIds(List<String> personIds) {
|
||||
this.personIds = personIds;
|
||||
}
|
||||
|
||||
public Integer getState() {
|
||||
return this.state;
|
||||
}
|
||||
|
||||
public void setState(Integer state) {
|
||||
this.state = state;
|
||||
}
|
||||
|
||||
public List<String> getLabelIds() {
|
||||
return this.labelIds;
|
||||
}
|
||||
|
||||
public void setLabelIds(List<String> labelIds) {
|
||||
this.labelIds = labelIds;
|
||||
}
|
||||
}
|
||||
|
||||
+237
@@ -0,0 +1,237 @@
|
||||
/*
|
||||
* Decompiled with CFR 0.152.
|
||||
*
|
||||
* Could not load the following classes:
|
||||
* cn.cloudwalk.client.ninca.attendance.rule.param.AttendRuleAddParam
|
||||
* cn.cloudwalk.client.ninca.attendance.rule.param.AttendRuleDeleteParam
|
||||
* cn.cloudwalk.client.ninca.attendance.rule.param.AttendRuleEditParam
|
||||
* cn.cloudwalk.client.ninca.attendance.rule.param.AttendRuleHolidayParam
|
||||
* cn.cloudwalk.client.ninca.attendance.rule.param.AttendRulePageQueryParam
|
||||
* cn.cloudwalk.client.ninca.attendance.rule.param.AttendRuleQueryParam
|
||||
* cn.cloudwalk.client.ninca.attendance.rule.param.AttendRuleSchedulingSaveParam
|
||||
* cn.cloudwalk.client.ninca.attendance.rule.result.AttendRuleDeviceQueryResult
|
||||
* cn.cloudwalk.client.ninca.attendance.rule.result.AttendRuleHolidayQueryResult
|
||||
* cn.cloudwalk.client.ninca.attendance.rule.result.AttendRuleImagestoreQueryResult
|
||||
* cn.cloudwalk.client.ninca.attendance.rule.result.AttendRuleInfoQueryResult
|
||||
* cn.cloudwalk.client.ninca.attendance.rule.result.AttendRuleLabelQueryResult
|
||||
* cn.cloudwalk.client.ninca.attendance.rule.result.AttendRuleOrgQueryResult
|
||||
* cn.cloudwalk.client.ninca.attendance.rule.result.AttendRulePageResult
|
||||
* cn.cloudwalk.client.ninca.attendance.rule.result.AttendRuleScheduleQueryResult
|
||||
* cn.cloudwalk.client.ninca.attendance.rule.service.AttendRuleDeviceService
|
||||
* cn.cloudwalk.client.ninca.attendance.rule.service.AttendRuleHolidayService
|
||||
* cn.cloudwalk.client.ninca.attendance.rule.service.AttendRuleImagestoreService
|
||||
* cn.cloudwalk.client.ninca.attendance.rule.service.AttendRuleLabelService
|
||||
* cn.cloudwalk.client.ninca.attendance.rule.service.AttendRuleOrgService
|
||||
* cn.cloudwalk.client.ninca.attendance.rule.service.AttendRuleSchedulingService
|
||||
* cn.cloudwalk.client.ninca.attendance.rule.service.AttendRuleService
|
||||
* cn.cloudwalk.cloud.exception.ServiceException
|
||||
* cn.cloudwalk.cloud.page.CloudwalkPageAble
|
||||
* cn.cloudwalk.cloud.page.CloudwalkPageInfo
|
||||
* cn.cloudwalk.cloud.result.CloudwalkResult
|
||||
* cn.cloudwalk.cloud.utils.BeanCopyUtils
|
||||
* javax.annotation.Resource
|
||||
* org.springframework.web.bind.annotation.PostMapping
|
||||
* org.springframework.web.bind.annotation.RequestBody
|
||||
* org.springframework.web.bind.annotation.RequestMapping
|
||||
* org.springframework.web.bind.annotation.RestController
|
||||
*/
|
||||
package cn.cloudwalk.web.ninca.attendance.rule.controller;
|
||||
|
||||
import cn.cloudwalk.client.ninca.attendance.rule.param.AttendRuleAddParam;
|
||||
import cn.cloudwalk.client.ninca.attendance.rule.param.AttendRuleDeleteParam;
|
||||
import cn.cloudwalk.client.ninca.attendance.rule.param.AttendRuleEditParam;
|
||||
import cn.cloudwalk.client.ninca.attendance.rule.param.AttendRuleHolidayParam;
|
||||
import cn.cloudwalk.client.ninca.attendance.rule.param.AttendRulePageQueryParam;
|
||||
import cn.cloudwalk.client.ninca.attendance.rule.param.AttendRuleQueryParam;
|
||||
import cn.cloudwalk.client.ninca.attendance.rule.param.AttendRuleSchedulingSaveParam;
|
||||
import cn.cloudwalk.client.ninca.attendance.rule.result.AttendRuleDeviceQueryResult;
|
||||
import cn.cloudwalk.client.ninca.attendance.rule.result.AttendRuleHolidayQueryResult;
|
||||
import cn.cloudwalk.client.ninca.attendance.rule.result.AttendRuleImagestoreQueryResult;
|
||||
import cn.cloudwalk.client.ninca.attendance.rule.result.AttendRuleInfoQueryResult;
|
||||
import cn.cloudwalk.client.ninca.attendance.rule.result.AttendRuleLabelQueryResult;
|
||||
import cn.cloudwalk.client.ninca.attendance.rule.result.AttendRuleOrgQueryResult;
|
||||
import cn.cloudwalk.client.ninca.attendance.rule.result.AttendRulePageResult;
|
||||
import cn.cloudwalk.client.ninca.attendance.rule.result.AttendRuleScheduleQueryResult;
|
||||
import cn.cloudwalk.client.ninca.attendance.rule.service.AttendRuleDeviceService;
|
||||
import cn.cloudwalk.client.ninca.attendance.rule.service.AttendRuleHolidayService;
|
||||
import cn.cloudwalk.client.ninca.attendance.rule.service.AttendRuleImagestoreService;
|
||||
import cn.cloudwalk.client.ninca.attendance.rule.service.AttendRuleLabelService;
|
||||
import cn.cloudwalk.client.ninca.attendance.rule.service.AttendRuleOrgService;
|
||||
import cn.cloudwalk.client.ninca.attendance.rule.service.AttendRuleSchedulingService;
|
||||
import cn.cloudwalk.client.ninca.attendance.rule.service.AttendRuleService;
|
||||
import cn.cloudwalk.cloud.exception.ServiceException;
|
||||
import cn.cloudwalk.cloud.page.CloudwalkPageAble;
|
||||
import cn.cloudwalk.cloud.page.CloudwalkPageInfo;
|
||||
import cn.cloudwalk.cloud.result.CloudwalkResult;
|
||||
import cn.cloudwalk.cloud.utils.BeanCopyUtils;
|
||||
import cn.cloudwalk.web.ninca.attendance.common.AbstractCloudwalkController;
|
||||
import cn.cloudwalk.web.ninca.attendance.rule.form.AttendRuleAddForm;
|
||||
import cn.cloudwalk.web.ninca.attendance.rule.form.AttendRuleDeleteForm;
|
||||
import cn.cloudwalk.web.ninca.attendance.rule.form.AttendRuleEditForm;
|
||||
import cn.cloudwalk.web.ninca.attendance.rule.form.AttendRuleLabelQueryForm;
|
||||
import cn.cloudwalk.web.ninca.attendance.rule.form.AttendRulePageQueryForm;
|
||||
import cn.cloudwalk.web.ninca.attendance.rule.form.AttendRuleQueryForm;
|
||||
import java.util.List;
|
||||
import javax.annotation.Resource;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestBody;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
@RestController
|
||||
@RequestMapping(value={"/intelligent/api/attend/rule"})
|
||||
public class AttendRuleController
|
||||
extends AbstractCloudwalkController {
|
||||
@Resource
|
||||
private AttendRuleService attendRuleService;
|
||||
@Resource
|
||||
private AttendRuleHolidayService attendRuleHolidayService;
|
||||
@Resource
|
||||
private AttendRuleSchedulingService attendRuleSchedulingService;
|
||||
@Resource
|
||||
private AttendRuleDeviceService attendRuleDeviceService;
|
||||
@Resource
|
||||
private AttendRuleImagestoreService attendRuleImagestoreService;
|
||||
@Resource
|
||||
private AttendRuleOrgService attendRuleOrgService;
|
||||
@Resource
|
||||
private AttendRuleLabelService attendRuleLabelService;
|
||||
|
||||
@PostMapping(value={"/page"})
|
||||
public CloudwalkResult<CloudwalkPageAble<AttendRulePageResult>> page(@RequestBody AttendRulePageQueryForm form) {
|
||||
AttendRulePageQueryParam param = (AttendRulePageQueryParam)BeanCopyUtils.copyProperties((Object)form, AttendRulePageQueryParam.class);
|
||||
CloudwalkPageInfo page = new CloudwalkPageInfo(form.getCurrentPage(), form.getRowsOfPage());
|
||||
try {
|
||||
return this.attendRuleService.page(param, page, this.getCloudwalkContext());
|
||||
}
|
||||
catch (ServiceException e) {
|
||||
this.logger.error("\u8003\u52e4\u89c4\u5219\u5206\u9875\u67e5\u8be2\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240201", (String)this.getMessage("76240201"));
|
||||
}
|
||||
}
|
||||
|
||||
@PostMapping(value={"/delete"})
|
||||
public CloudwalkResult<Boolean> delete(@RequestBody AttendRuleDeleteForm form) {
|
||||
AttendRuleDeleteParam param = (AttendRuleDeleteParam)BeanCopyUtils.copyProperties((Object)form, AttendRuleDeleteParam.class);
|
||||
try {
|
||||
return this.attendRuleService.delete(param, this.getCloudwalkContext());
|
||||
}
|
||||
catch (ServiceException e) {
|
||||
this.logger.error("\u8003\u52e4\u89c4\u5219\u5220\u9664\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240202", (String)this.getMessage("76240202"));
|
||||
}
|
||||
}
|
||||
|
||||
@PostMapping(value={"/info/get"})
|
||||
public CloudwalkResult<AttendRuleInfoQueryResult> queryInfo(@RequestBody AttendRuleQueryForm form) {
|
||||
AttendRuleQueryParam param = (AttendRuleQueryParam)BeanCopyUtils.copyProperties((Object)form, AttendRuleQueryParam.class);
|
||||
try {
|
||||
return this.attendRuleService.queryInfo(param, this.getCloudwalkContext());
|
||||
}
|
||||
catch (ServiceException e) {
|
||||
this.logger.error("\u8003\u52e4\u89c4\u5219\u57fa\u672c\u4fe1\u606f\u67e5\u8be2\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240203", (String)this.getMessage("76240203"));
|
||||
}
|
||||
}
|
||||
|
||||
@PostMapping(value={"/holiday/get"})
|
||||
public CloudwalkResult<List<AttendRuleHolidayQueryResult>> queryHoliday(@RequestBody AttendRuleQueryForm form) {
|
||||
AttendRuleQueryParam param = (AttendRuleQueryParam)BeanCopyUtils.copyProperties((Object)form, AttendRuleQueryParam.class);
|
||||
try {
|
||||
return this.attendRuleHolidayService.query(param, this.getCloudwalkContext());
|
||||
}
|
||||
catch (ServiceException e) {
|
||||
this.logger.error("\u8003\u52e4\u89c4\u5219\u8282\u5047\u65e5\u67e5\u8be2\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240204", (String)this.getMessage("76240204"));
|
||||
}
|
||||
}
|
||||
|
||||
@PostMapping(value={"/scheduling/get"})
|
||||
public CloudwalkResult<List<AttendRuleScheduleQueryResult>> getScheduling(@RequestBody AttendRuleQueryForm form) {
|
||||
AttendRuleQueryParam param = (AttendRuleQueryParam)BeanCopyUtils.copyProperties((Object)form, AttendRuleQueryParam.class);
|
||||
try {
|
||||
return this.attendRuleSchedulingService.query(param, this.getCloudwalkContext());
|
||||
}
|
||||
catch (ServiceException e) {
|
||||
this.logger.error("\u8003\u52e4\u89c4\u5219\u6392\u73ed\u65f6\u95f4\u67e5\u8be2\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240205", (String)this.getMessage("76240205"));
|
||||
}
|
||||
}
|
||||
|
||||
@PostMapping(value={"/device/get"})
|
||||
public CloudwalkResult<List<AttendRuleDeviceQueryResult>> getDevice(@RequestBody AttendRuleQueryForm form) {
|
||||
AttendRuleQueryParam param = (AttendRuleQueryParam)BeanCopyUtils.copyProperties((Object)form, AttendRuleQueryParam.class);
|
||||
try {
|
||||
return this.attendRuleDeviceService.query(param, this.getCloudwalkContext());
|
||||
}
|
||||
catch (ServiceException e) {
|
||||
this.logger.error("\u8003\u52e4\u89c4\u5219\u8bbe\u5907\u67e5\u8be2\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240237", (String)this.getMessage("76240237"));
|
||||
}
|
||||
}
|
||||
|
||||
@PostMapping(value={"/imagestore/get"})
|
||||
public CloudwalkResult<List<AttendRuleImagestoreQueryResult>> getImagestore(@RequestBody AttendRuleQueryForm form) {
|
||||
AttendRuleQueryParam param = (AttendRuleQueryParam)BeanCopyUtils.copyProperties((Object)form, AttendRuleQueryParam.class);
|
||||
try {
|
||||
return this.attendRuleImagestoreService.query(param, this.getCloudwalkContext());
|
||||
}
|
||||
catch (ServiceException e) {
|
||||
this.logger.error("\u8003\u52e4\u89c4\u5219\u8bbe\u5907\u67e5\u8be2\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240238", (String)this.getMessage("76240238"));
|
||||
}
|
||||
}
|
||||
|
||||
@PostMapping(value={"/add"})
|
||||
public CloudwalkResult<Boolean> add(@RequestBody AttendRuleAddForm form) {
|
||||
AttendRuleAddParam param = (AttendRuleAddParam)BeanCopyUtils.copyProperties((Object)form, AttendRuleAddParam.class);
|
||||
param.setSchedulings(BeanCopyUtils.copy(form.getSchedulings(), AttendRuleSchedulingSaveParam.class));
|
||||
param.setHolidays(BeanCopyUtils.copy(form.getHolidays(), AttendRuleHolidayParam.class));
|
||||
try {
|
||||
return this.attendRuleService.add(param, this.getCloudwalkContext());
|
||||
}
|
||||
catch (ServiceException e) {
|
||||
this.logger.error("\u8003\u52e4\u89c4\u5219\u65b0\u589e\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240206", (String)this.getMessage("76240206"));
|
||||
}
|
||||
}
|
||||
|
||||
@PostMapping(value={"/edit"})
|
||||
public CloudwalkResult<Boolean> edit(@RequestBody AttendRuleEditForm form) {
|
||||
AttendRuleEditParam param = (AttendRuleEditParam)BeanCopyUtils.copyProperties((Object)form, AttendRuleEditParam.class);
|
||||
param.setSchedulings(BeanCopyUtils.copy(form.getSchedulings(), AttendRuleSchedulingSaveParam.class));
|
||||
param.setHolidays(BeanCopyUtils.copy(form.getHolidays(), AttendRuleHolidayParam.class));
|
||||
try {
|
||||
return this.attendRuleService.edit(param, this.getCloudwalkContext());
|
||||
}
|
||||
catch (ServiceException e) {
|
||||
this.logger.error("\u8003\u52e4\u89c4\u5219\u7f16\u8f91\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240207", (String)this.getMessage("76240207"));
|
||||
}
|
||||
}
|
||||
|
||||
@PostMapping(value={"/org/get"})
|
||||
public CloudwalkResult<List<AttendRuleOrgQueryResult>> getOrg(@RequestBody AttendRuleQueryForm form) {
|
||||
AttendRuleQueryParam param = (AttendRuleQueryParam)BeanCopyUtils.copyProperties((Object)form, AttendRuleQueryParam.class);
|
||||
try {
|
||||
return this.attendRuleOrgService.query(param, this.getCloudwalkContext());
|
||||
}
|
||||
catch (ServiceException e) {
|
||||
this.logger.error("\u8003\u52e4\u89c4\u5219\u7ec4\u7ec7\u67e5\u8be2\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240224", (String)this.getMessage("76240224"));
|
||||
}
|
||||
}
|
||||
|
||||
@PostMapping(value={"/label/get"})
|
||||
public CloudwalkResult<List<AttendRuleLabelQueryResult>> getLabel(@RequestBody AttendRuleLabelQueryForm form) {
|
||||
AttendRuleQueryParam param = (AttendRuleQueryParam)BeanCopyUtils.copyProperties((Object)form, AttendRuleQueryParam.class);
|
||||
try {
|
||||
return this.attendRuleLabelService.query(param, this.getCloudwalkContext());
|
||||
}
|
||||
catch (ServiceException e) {
|
||||
this.logger.error("\u8003\u52e4\u89c4\u5219\u6807\u7b7e\u67e5\u8be2\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
|
||||
return CloudwalkResult.fail((String)"76240254", (String)this.getMessage("76240254"));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
+22
@@ -0,0 +1,22 @@
|
||||
/*
|
||||
* Decompiled with CFR 0.152.
|
||||
*/
|
||||
package cn.cloudwalk.web.ninca.attendance.rule.form;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.List;
|
||||
|
||||
public class AttendImagestoreCheckForm
|
||||
implements Serializable {
|
||||
private static final long serialVersionUID = 6459568880184890818L;
|
||||
private List<String> imagestoreIds;
|
||||
|
||||
public List<String> getImagestoreIds() {
|
||||
return this.imagestoreIds;
|
||||
}
|
||||
|
||||
public void setImagestoreIds(List<String> imagestoreIds) {
|
||||
this.imagestoreIds = imagestoreIds;
|
||||
}
|
||||
}
|
||||
|
||||
+150
@@ -0,0 +1,150 @@
|
||||
/*
|
||||
* Decompiled with CFR 0.152.
|
||||
*/
|
||||
package cn.cloudwalk.web.ninca.attendance.rule.form;
|
||||
|
||||
import cn.cloudwalk.web.ninca.attendance.rule.form.AttendRuleHolidayForm;
|
||||
import cn.cloudwalk.web.ninca.attendance.rule.form.AttendRuleSchedulingSaveForm;
|
||||
import java.io.Serializable;
|
||||
import java.util.List;
|
||||
|
||||
public class AttendRuleAddForm
|
||||
implements Serializable {
|
||||
private static final long serialVersionUID = -4341540577086874655L;
|
||||
private String name;
|
||||
private Integer type;
|
||||
private String remark;
|
||||
private Integer allowDayoffOvertime;
|
||||
private Integer dayoffMinOvertime;
|
||||
private Integer allowWorkingOvertime;
|
||||
private Integer startOvertime;
|
||||
private Integer minOvertime;
|
||||
private Integer maxOvertime;
|
||||
private List<AttendRuleHolidayForm> holidays;
|
||||
private List<AttendRuleSchedulingSaveForm> schedulings;
|
||||
private List<String> deviceIds;
|
||||
private List<String> includeOrganizations;
|
||||
private List<String> includeLabels;
|
||||
private List<String> excludeLabels;
|
||||
|
||||
public String getName() {
|
||||
return this.name;
|
||||
}
|
||||
|
||||
public void setName(String name) {
|
||||
this.name = name;
|
||||
}
|
||||
|
||||
public Integer getType() {
|
||||
return this.type;
|
||||
}
|
||||
|
||||
public void setType(Integer type) {
|
||||
this.type = type;
|
||||
}
|
||||
|
||||
public String getRemark() {
|
||||
return this.remark;
|
||||
}
|
||||
|
||||
public void setRemark(String remark) {
|
||||
this.remark = remark;
|
||||
}
|
||||
|
||||
public Integer getAllowDayoffOvertime() {
|
||||
return this.allowDayoffOvertime;
|
||||
}
|
||||
|
||||
public void setAllowDayoffOvertime(Integer allowDayoffOvertime) {
|
||||
this.allowDayoffOvertime = allowDayoffOvertime;
|
||||
}
|
||||
|
||||
public Integer getDayoffMinOvertime() {
|
||||
return this.dayoffMinOvertime;
|
||||
}
|
||||
|
||||
public void setDayoffMinOvertime(Integer dayoffMinOvertime) {
|
||||
this.dayoffMinOvertime = dayoffMinOvertime;
|
||||
}
|
||||
|
||||
public Integer getAllowWorkingOvertime() {
|
||||
return this.allowWorkingOvertime;
|
||||
}
|
||||
|
||||
public void setAllowWorkingOvertime(Integer allowWorkingOvertime) {
|
||||
this.allowWorkingOvertime = allowWorkingOvertime;
|
||||
}
|
||||
|
||||
public Integer getStartOvertime() {
|
||||
return this.startOvertime;
|
||||
}
|
||||
|
||||
public void setStartOvertime(Integer startOvertime) {
|
||||
this.startOvertime = startOvertime;
|
||||
}
|
||||
|
||||
public Integer getMinOvertime() {
|
||||
return this.minOvertime;
|
||||
}
|
||||
|
||||
public void setMinOvertime(Integer minOvertime) {
|
||||
this.minOvertime = minOvertime;
|
||||
}
|
||||
|
||||
public Integer getMaxOvertime() {
|
||||
return this.maxOvertime;
|
||||
}
|
||||
|
||||
public void setMaxOvertime(Integer maxOvertime) {
|
||||
this.maxOvertime = maxOvertime;
|
||||
}
|
||||
|
||||
public List<AttendRuleHolidayForm> getHolidays() {
|
||||
return this.holidays;
|
||||
}
|
||||
|
||||
public void setHolidays(List<AttendRuleHolidayForm> holidays) {
|
||||
this.holidays = holidays;
|
||||
}
|
||||
|
||||
public List<AttendRuleSchedulingSaveForm> getSchedulings() {
|
||||
return this.schedulings;
|
||||
}
|
||||
|
||||
public void setSchedulings(List<AttendRuleSchedulingSaveForm> schedulings) {
|
||||
this.schedulings = schedulings;
|
||||
}
|
||||
|
||||
public List<String> getDeviceIds() {
|
||||
return this.deviceIds;
|
||||
}
|
||||
|
||||
public void setDeviceIds(List<String> deviceIds) {
|
||||
this.deviceIds = deviceIds;
|
||||
}
|
||||
|
||||
public List<String> getIncludeOrganizations() {
|
||||
return this.includeOrganizations;
|
||||
}
|
||||
|
||||
public void setIncludeOrganizations(List<String> includeOrganizations) {
|
||||
this.includeOrganizations = includeOrganizations;
|
||||
}
|
||||
|
||||
public List<String> getIncludeLabels() {
|
||||
return this.includeLabels;
|
||||
}
|
||||
|
||||
public void setIncludeLabels(List<String> includeLabels) {
|
||||
this.includeLabels = includeLabels;
|
||||
}
|
||||
|
||||
public List<String> getExcludeLabels() {
|
||||
return this.excludeLabels;
|
||||
}
|
||||
|
||||
public void setExcludeLabels(List<String> excludeLabels) {
|
||||
this.excludeLabels = excludeLabels;
|
||||
}
|
||||
}
|
||||
|
||||
+22
@@ -0,0 +1,22 @@
|
||||
/*
|
||||
* Decompiled with CFR 0.152.
|
||||
*/
|
||||
package cn.cloudwalk.web.ninca.attendance.rule.form;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.List;
|
||||
|
||||
public class AttendRuleDeleteForm
|
||||
implements Serializable {
|
||||
private static final long serialVersionUID = -82569291052280989L;
|
||||
private List<String> ids;
|
||||
|
||||
public List<String> getIds() {
|
||||
return this.ids;
|
||||
}
|
||||
|
||||
public void setIds(List<String> ids) {
|
||||
this.ids = ids;
|
||||
}
|
||||
}
|
||||
|
||||
+158
@@ -0,0 +1,158 @@
|
||||
/*
|
||||
* Decompiled with CFR 0.152.
|
||||
*/
|
||||
package cn.cloudwalk.web.ninca.attendance.rule.form;
|
||||
|
||||
import cn.cloudwalk.web.ninca.attendance.rule.form.AttendRuleHolidayForm;
|
||||
import cn.cloudwalk.web.ninca.attendance.rule.form.AttendRuleSchedulingSaveForm;
|
||||
import java.io.Serializable;
|
||||
import java.util.List;
|
||||
|
||||
public class AttendRuleEditForm
|
||||
implements Serializable {
|
||||
private String id;
|
||||
private String name;
|
||||
private Integer type;
|
||||
private String remark;
|
||||
private Integer allowDayoffOvertime;
|
||||
private Integer dayoffMinOvertime;
|
||||
private Integer allowWorkingOvertime;
|
||||
private Integer startOvertime;
|
||||
private Integer minOvertime;
|
||||
private Integer maxOvertime;
|
||||
private List<AttendRuleHolidayForm> holidays;
|
||||
private List<AttendRuleSchedulingSaveForm> schedulings;
|
||||
private List<String> deviceIds;
|
||||
private List<String> includeOrganizations;
|
||||
private List<String> includeLabels;
|
||||
private List<String> excludeLabels;
|
||||
|
||||
public String getId() {
|
||||
return this.id;
|
||||
}
|
||||
|
||||
public void setId(String id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public String getName() {
|
||||
return this.name;
|
||||
}
|
||||
|
||||
public void setName(String name) {
|
||||
this.name = name;
|
||||
}
|
||||
|
||||
public Integer getType() {
|
||||
return this.type;
|
||||
}
|
||||
|
||||
public void setType(Integer type) {
|
||||
this.type = type;
|
||||
}
|
||||
|
||||
public String getRemark() {
|
||||
return this.remark;
|
||||
}
|
||||
|
||||
public void setRemark(String remark) {
|
||||
this.remark = remark;
|
||||
}
|
||||
|
||||
public Integer getAllowDayoffOvertime() {
|
||||
return this.allowDayoffOvertime;
|
||||
}
|
||||
|
||||
public void setAllowDayoffOvertime(Integer allowDayoffOvertime) {
|
||||
this.allowDayoffOvertime = allowDayoffOvertime;
|
||||
}
|
||||
|
||||
public Integer getDayoffMinOvertime() {
|
||||
return this.dayoffMinOvertime;
|
||||
}
|
||||
|
||||
public void setDayoffMinOvertime(Integer dayoffMinOvertime) {
|
||||
this.dayoffMinOvertime = dayoffMinOvertime;
|
||||
}
|
||||
|
||||
public Integer getAllowWorkingOvertime() {
|
||||
return this.allowWorkingOvertime;
|
||||
}
|
||||
|
||||
public void setAllowWorkingOvertime(Integer allowWorkingOvertime) {
|
||||
this.allowWorkingOvertime = allowWorkingOvertime;
|
||||
}
|
||||
|
||||
public Integer getStartOvertime() {
|
||||
return this.startOvertime;
|
||||
}
|
||||
|
||||
public void setStartOvertime(Integer startOvertime) {
|
||||
this.startOvertime = startOvertime;
|
||||
}
|
||||
|
||||
public Integer getMinOvertime() {
|
||||
return this.minOvertime;
|
||||
}
|
||||
|
||||
public void setMinOvertime(Integer minOvertime) {
|
||||
this.minOvertime = minOvertime;
|
||||
}
|
||||
|
||||
public Integer getMaxOvertime() {
|
||||
return this.maxOvertime;
|
||||
}
|
||||
|
||||
public void setMaxOvertime(Integer maxOvertime) {
|
||||
this.maxOvertime = maxOvertime;
|
||||
}
|
||||
|
||||
public List<AttendRuleHolidayForm> getHolidays() {
|
||||
return this.holidays;
|
||||
}
|
||||
|
||||
public void setHolidays(List<AttendRuleHolidayForm> holidays) {
|
||||
this.holidays = holidays;
|
||||
}
|
||||
|
||||
public List<AttendRuleSchedulingSaveForm> getSchedulings() {
|
||||
return this.schedulings;
|
||||
}
|
||||
|
||||
public void setSchedulings(List<AttendRuleSchedulingSaveForm> schedulings) {
|
||||
this.schedulings = schedulings;
|
||||
}
|
||||
|
||||
public List<String> getDeviceIds() {
|
||||
return this.deviceIds;
|
||||
}
|
||||
|
||||
public void setDeviceIds(List<String> deviceIds) {
|
||||
this.deviceIds = deviceIds;
|
||||
}
|
||||
|
||||
public List<String> getIncludeOrganizations() {
|
||||
return this.includeOrganizations;
|
||||
}
|
||||
|
||||
public void setIncludeOrganizations(List<String> includeOrganizations) {
|
||||
this.includeOrganizations = includeOrganizations;
|
||||
}
|
||||
|
||||
public List<String> getIncludeLabels() {
|
||||
return this.includeLabels;
|
||||
}
|
||||
|
||||
public void setIncludeLabels(List<String> includeLabels) {
|
||||
this.includeLabels = includeLabels;
|
||||
}
|
||||
|
||||
public List<String> getExcludeLabels() {
|
||||
return this.excludeLabels;
|
||||
}
|
||||
|
||||
public void setExcludeLabels(List<String> excludeLabels) {
|
||||
this.excludeLabels = excludeLabels;
|
||||
}
|
||||
}
|
||||
|
||||
+30
@@ -0,0 +1,30 @@
|
||||
/*
|
||||
* Decompiled with CFR 0.152.
|
||||
*/
|
||||
package cn.cloudwalk.web.ninca.attendance.rule.form;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
public class AttendRuleHolidayForm
|
||||
implements Serializable {
|
||||
private static final long serialVersionUID = -6006220983425724531L;
|
||||
private String holiday;
|
||||
private Integer type;
|
||||
|
||||
public String getHoliday() {
|
||||
return this.holiday;
|
||||
}
|
||||
|
||||
public void setHoliday(String holiday) {
|
||||
this.holiday = holiday;
|
||||
}
|
||||
|
||||
public Integer getType() {
|
||||
return this.type;
|
||||
}
|
||||
|
||||
public void setType(Integer type) {
|
||||
this.type = type;
|
||||
}
|
||||
}
|
||||
|
||||
+30
@@ -0,0 +1,30 @@
|
||||
/*
|
||||
* Decompiled with CFR 0.152.
|
||||
*/
|
||||
package cn.cloudwalk.web.ninca.attendance.rule.form;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
public class AttendRuleLabelQueryForm
|
||||
implements Serializable {
|
||||
private static final long serialVersionUID = 5740662633593246519L;
|
||||
private String ruleId;
|
||||
private Integer type;
|
||||
|
||||
public String getRuleId() {
|
||||
return this.ruleId;
|
||||
}
|
||||
|
||||
public void setRuleId(String ruleId) {
|
||||
this.ruleId = ruleId;
|
||||
}
|
||||
|
||||
public Integer getType() {
|
||||
return this.type;
|
||||
}
|
||||
|
||||
public void setType(Integer type) {
|
||||
this.type = type;
|
||||
}
|
||||
}
|
||||
|
||||
+35
@@ -0,0 +1,35 @@
|
||||
/*
|
||||
* Decompiled with CFR 0.152.
|
||||
*
|
||||
* Could not load the following classes:
|
||||
* cn.cloudwalk.cloud.page.CloudwalkBasePageForm
|
||||
*/
|
||||
package cn.cloudwalk.web.ninca.attendance.rule.form;
|
||||
|
||||
import cn.cloudwalk.cloud.page.CloudwalkBasePageForm;
|
||||
import java.io.Serializable;
|
||||
|
||||
public class AttendRulePageQueryForm
|
||||
extends CloudwalkBasePageForm
|
||||
implements Serializable {
|
||||
private static final long serialVersionUID = -4627256381671887329L;
|
||||
private String ruleName;
|
||||
private Integer ruleType;
|
||||
|
||||
public String getRuleName() {
|
||||
return this.ruleName;
|
||||
}
|
||||
|
||||
public void setRuleName(String ruleName) {
|
||||
this.ruleName = ruleName;
|
||||
}
|
||||
|
||||
public Integer getRuleType() {
|
||||
return this.ruleType;
|
||||
}
|
||||
|
||||
public void setRuleType(Integer ruleType) {
|
||||
this.ruleType = ruleType;
|
||||
}
|
||||
}
|
||||
|
||||
+21
@@ -0,0 +1,21 @@
|
||||
/*
|
||||
* Decompiled with CFR 0.152.
|
||||
*/
|
||||
package cn.cloudwalk.web.ninca.attendance.rule.form;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
public class AttendRuleQueryForm
|
||||
implements Serializable {
|
||||
private static final long serialVersionUID = 5740662633593246519L;
|
||||
private String ruleId;
|
||||
|
||||
public String getRuleId() {
|
||||
return this.ruleId;
|
||||
}
|
||||
|
||||
public void setRuleId(String ruleId) {
|
||||
this.ruleId = ruleId;
|
||||
}
|
||||
}
|
||||
|
||||
+102
@@ -0,0 +1,102 @@
|
||||
/*
|
||||
* Decompiled with CFR 0.152.
|
||||
*/
|
||||
package cn.cloudwalk.web.ninca.attendance.rule.form;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
public class AttendRuleSchedulingSaveForm
|
||||
implements Serializable {
|
||||
private static final long serialVersionUID = 4830713265001024447L;
|
||||
private String startworkTime;
|
||||
private String endworkTime;
|
||||
private Integer afterTime;
|
||||
private Integer beforeTime;
|
||||
private Integer standardTime;
|
||||
private Integer absentTime;
|
||||
private Integer overTime;
|
||||
private String startAdaptTime;
|
||||
private String endAdaptTime;
|
||||
private Integer sortValue;
|
||||
|
||||
public String getStartworkTime() {
|
||||
return this.startworkTime;
|
||||
}
|
||||
|
||||
public void setStartworkTime(String startworkTime) {
|
||||
this.startworkTime = startworkTime;
|
||||
}
|
||||
|
||||
public String getEndworkTime() {
|
||||
return this.endworkTime;
|
||||
}
|
||||
|
||||
public void setEndworkTime(String endworkTime) {
|
||||
this.endworkTime = endworkTime;
|
||||
}
|
||||
|
||||
public Integer getAfterTime() {
|
||||
return this.afterTime;
|
||||
}
|
||||
|
||||
public void setAfterTime(Integer afterTime) {
|
||||
this.afterTime = afterTime;
|
||||
}
|
||||
|
||||
public Integer getBeforeTime() {
|
||||
return this.beforeTime;
|
||||
}
|
||||
|
||||
public void setBeforeTime(Integer beforeTime) {
|
||||
this.beforeTime = beforeTime;
|
||||
}
|
||||
|
||||
public Integer getStandardTime() {
|
||||
return this.standardTime;
|
||||
}
|
||||
|
||||
public void setStandardTime(Integer standardTime) {
|
||||
this.standardTime = standardTime;
|
||||
}
|
||||
|
||||
public Integer getAbsentTime() {
|
||||
return this.absentTime;
|
||||
}
|
||||
|
||||
public void setAbsentTime(Integer absentTime) {
|
||||
this.absentTime = absentTime;
|
||||
}
|
||||
|
||||
public Integer getOverTime() {
|
||||
return this.overTime;
|
||||
}
|
||||
|
||||
public void setOverTime(Integer overTime) {
|
||||
this.overTime = overTime;
|
||||
}
|
||||
|
||||
public String getStartAdaptTime() {
|
||||
return this.startAdaptTime;
|
||||
}
|
||||
|
||||
public void setStartAdaptTime(String startAdaptTime) {
|
||||
this.startAdaptTime = startAdaptTime;
|
||||
}
|
||||
|
||||
public String getEndAdaptTime() {
|
||||
return this.endAdaptTime;
|
||||
}
|
||||
|
||||
public void setEndAdaptTime(String endAdaptTime) {
|
||||
this.endAdaptTime = endAdaptTime;
|
||||
}
|
||||
|
||||
public Integer getSortValue() {
|
||||
return this.sortValue;
|
||||
}
|
||||
|
||||
public void setSortValue(Integer sortValue) {
|
||||
this.sortValue = sortValue;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,2 @@
|
||||
Summary for /tmp/crk_lib_extract_6o_f40r3/ninca-crk-smart-attendance-web-2.9.1_210630-SNAPSHOT.jar
|
||||
Decompiled with CFR 0.152
|
||||
Reference in New Issue
Block a user