Commit 2c462840 by 邓实川

Merge branch 'develop' of http://120.24.24.239:8082/8timerv2/8timerapiv200.git into dsc

parents 7c365873 d02138a0
...@@ -7,11 +7,7 @@ import java.util.List; ...@@ -7,11 +7,7 @@ import java.util.List;
import org.aspectj.lang.JoinPoint; import org.aspectj.lang.JoinPoint;
import org.aspectj.lang.ProceedingJoinPoint; import org.aspectj.lang.ProceedingJoinPoint;
import org.aspectj.lang.Signature; import org.aspectj.lang.Signature;
import org.aspectj.lang.annotation.Around;
import org.aspectj.lang.annotation.Aspect;
import org.aspectj.lang.annotation.Pointcut;
import org.aspectj.lang.reflect.MethodSignature; import org.aspectj.lang.reflect.MethodSignature;
import org.springframework.stereotype.Component;
import org.springframework.validation.BeanPropertyBindingResult; import org.springframework.validation.BeanPropertyBindingResult;
import org.springframework.validation.ObjectError; import org.springframework.validation.ObjectError;
...@@ -25,12 +21,12 @@ import cn.timer.api.aspect.lang.bean.ValidationError; ...@@ -25,12 +21,12 @@ import cn.timer.api.aspect.lang.bean.ValidationError;
import cn.timer.api.utils.ResultUtil; import cn.timer.api.utils.ResultUtil;
/** /**
* 校验信息返回 * 校验信息返回-(闲置)
* *
* @author TZQ * @author TZQ
*/ */
@Aspect //@Aspect
@Component //@Component
public class BindingResultAspect { public class BindingResultAspect {
// @annotation配置织入点 // @annotation配置织入点
...@@ -40,7 +36,7 @@ public class BindingResultAspect { ...@@ -40,7 +36,7 @@ public class BindingResultAspect {
// } // }
// execution 配置织入点 -匹配 cn.timer.api.controller 包下的所有子包的类的方法 // execution 配置织入点 -匹配 cn.timer.api.controller 包下的所有子包的类的方法
@Pointcut("execution(* cn.timer.api.controller.spmk.*.*(..))") // @Pointcut("execution(* cn.timer.api.controller.spmk.*.*(..))")
public void clazzPointCut(){ public void clazzPointCut(){
} }
...@@ -53,45 +49,41 @@ public class BindingResultAspect { ...@@ -53,45 +49,41 @@ public class BindingResultAspect {
// } // }
// @Around("bindingResultPointCut() && args(..,bindingResult)") // @Around("bindingResultPointCut() && args(..,bindingResult)")
@Around("clazzPointCut()") // @Around("clazzPointCut()")
public Object doAround(ProceedingJoinPoint joinPoint) throws Throwable { // public Object doAround(ProceedingJoinPoint joinPoint) throws Throwable {
Long startTime = System.currentTimeMillis(); // Long startTime = System.currentTimeMillis();
Object retVal; // Object retVal;
Object[] objs = joinPoint.getArgs(); // Object[] objs = joinPoint.getArgs();
List<Object> listObj = CollectionUtil.toList(objs); // List<Object> listObj = CollectionUtil.toList(objs);
BeanPropertyBindingResult optional = (BeanPropertyBindingResult)listObj.stream() // BeanPropertyBindingResult optional = (BeanPropertyBindingResult)listObj.stream()
.filter(p -> "BeanPropertyBindingResult".equals(ClassUtil.getClassName(p, true))) // .filter(p -> "BeanPropertyBindingResult".equals(ClassUtil.getClassName(p, true)))
.findFirst() // .findFirst()
.orElse(null); // .orElse(null);
if(optional != null && optional.hasErrors()){ // if(optional != null && optional.hasErrors()){
List<ObjectError> ls = optional.getAllErrors(); // List<ObjectError> ls = optional.getAllErrors();
List<ValidationError> listVe = new ArrayList<ValidationError>(); // List<ValidationError> listVe = new ArrayList<ValidationError>();
ValidationError ve; // ValidationError ve;
for (ObjectError one : ls) { // for (ObjectError one : ls) {
//
String fieldString = one.getCodes().length >= 1 ? one.getCodes()[0] : ""; // String fieldString = one.getCodes().length >= 1 ? one.getCodes()[0] : "";
if (fieldString != null) { // if (fieldString != null) {
fieldString = fieldString.substring(fieldString.lastIndexOf(".") + 1); // fieldString = fieldString.substring(fieldString.lastIndexOf(".") + 1);
}
// for (String str : one.getCodes()) {
// System.err.println(str);
// } // }
//
ve = ValidationError.builder().field(fieldString).msg(one.getDefaultMessage()).build(); // ve = ValidationError.builder().field(fieldString).msg(one.getDefaultMessage()).build();
listVe.add(ve); // listVe.add(ve);
//
} // }
retVal = ResultUtil.error(listVe); // retVal = ResultUtil.error(listVe);
}else { // }else {
retVal = joinPoint.proceed(joinPoint.getArgs()); // retVal = joinPoint.proceed(joinPoint.getArgs());
} // }
Console.log("返回内容 {}: " ,JSONObject.toJSONString(retVal)); // Console.log("返回内容 {}: " ,JSONObject.toJSONString(retVal));
Long endtime = System.currentTimeMillis(); // Long endtime = System.currentTimeMillis();
Console.log("执行耗时为{}:" ,endtime-startTime + "ms"); // Console.log("执行耗时为{}:" ,endtime-startTime + "ms");
//
return retVal; // return retVal;
} // }
protected void handleDataScope(final JoinPoint joinPoint) protected void handleDataScope(final JoinPoint joinPoint)
{ {
......
package cn.timer.api.bean.kqmk;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Table;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
/**
* @author LAL 2020-05-07
*/
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@Table(name = "kqgl_ass_overtime_vice")
@ApiModel("加班规则-扣除休息时间")
public class KqglAssOvertimeVice extends Model<KqglAssOvertimeVice> {
/**
*
*/
private static final long serialVersionUID = 1L;
@Id
@GeneratedValue
@TableId(type = IdType.AUTO)
@ApiModelProperty(value = "id id", example = "1")
private Integer id;
@ApiModelProperty(value = "加班规则id 加班规则id", example = "101")
private Integer overtimeRulesId;
@ApiModelProperty(value = "休息开始时间 ", example = "休息开始时间")
private String breakStartTime;
@ApiModelProperty(value = "休息结束时间 ", example = "休息结束时间")
private String breakEndTime;
@ApiModelProperty(value = "类型 1:工作日;2:休息日;3:节假日", example = "101")
private Integer overType;
}
\ No newline at end of file
package cn.timer.api.bean.kqmk;
import javax.persistence.*;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
/**
* @author LAL 2020-05-07
*/
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@Table(name = "kqgl_asso_bcsz")
@ApiModel("班次表")
public class KqglAssoBcsz extends Model<KqglAssoBcsz> {
/**
*
*/
private static final long serialVersionUID = 1L;
@Id
@GeneratedValue
@TableId(type = IdType.AUTO)
@ApiModelProperty(value = "id id", example = "101")
private Integer id;
@ApiModelProperty(value = "班次名称 ", example = "班次名称")
private String name;
@ApiModelProperty(value = "上班1 ", example = "上班1")
private String sbdk1;
@ApiModelProperty(value = "上班1是否次日(0:否;1:是) 上班1是否次日(0:否;1:是)", example = "101")
private Integer isSbdk1Cr;
@ApiModelProperty(value = "上班1区间开始 ", example = "上班1区间开始")
private String sbqjks1;
@ApiModelProperty(value = "上班1区间结束 ", example = "上班1区间结束")
private String sbqjjs1;
@ApiModelProperty(value = "下班1 ", example = "下班1")
private String xbdk1;
@ApiModelProperty(value = "下班1是否次日(0:否;1:是) 下班1是否次日(0:否;1:是)", example = "101")
private Integer isXbdk1Cr;
@ApiModelProperty(value = "下班1区间开始 ", example = "下班1区间开始")
private String xbqjks1;
@ApiModelProperty(value = "下班1区间结束 ", example = "下班1区间结束")
private String xbqjjs1;
@ApiModelProperty(value = "上班2 ", example = "上班2")
private String sbdk2;
@ApiModelProperty(value = "上班2是否次日(0:否;1:是) 上班2是否次日(0:否;1:是)", example = "101")
private Integer isSbdk2Cr;
@ApiModelProperty(value = "上班2区间开始 ", example = "上班2区间开始")
private String sbqjks2;
@ApiModelProperty(value = "上班2区间结束 ", example = "上班2区间结束")
private String sbqjjs2;
@ApiModelProperty(value = "下班2 ", example = "下班2")
private String xbdk2;
@ApiModelProperty(value = "下班2是否次日(0:否;1:是) 下班2是否次日(0:否;1:是)", example = "101")
private Integer isXbdk2Cr;
@ApiModelProperty(value = "下班2区间开始 ", example = "下班2区间开始")
private String xbqjks2;
@ApiModelProperty(value = "下班2区间结束 ", example = "下班2区间结束")
private String xbqjjs2;
@ApiModelProperty(value = "上班3 ", example = "上班3")
private String sbdk3;
@ApiModelProperty(value = "上班3是否次日(0:否;1:是) 上班3是否次日(0:否;1:是)", example = "101")
private Integer isSbdk3Cr;
@ApiModelProperty(value = "上班3区间开始 ", example = "上班3区间开始")
private String sbqjks3;
@ApiModelProperty(value = "上班3区间结束 ", example = "上班3区间结束")
private String sbqjjs3;
@ApiModelProperty(value = "下班3 ", example = "下班3")
private String xbdk3;
@ApiModelProperty(value = "下班3是否次日(0:否;1:是) 下班3是否次日(0:否;1:是)", example = "101")
private Integer isXbdk3Cr;
@ApiModelProperty(value = "下班3区间开始 ", example = "下班3区间开始")
private String xbqjks3;
@ApiModelProperty(value = "下班3区间结束 ", example = "下班3区间结束")
private String xbqjjs3;
@ApiModelProperty(value = "是否开启休息时间(0:否;1:是) 是否开启休息时间(0:否;1:是)", example = "101")
private Integer isXiuxi;
@ApiModelProperty(value = "休息开始时间 休息开始时间", example = "101")
private Long startTime;
@ApiModelProperty(value = "休息结束时间 休息结束时间", example = "101")
private Long endTime;
@ApiModelProperty(value = "上下班次数(1/2/3 最大值为3)", example = "101")
private Integer sxbcs;
@ApiModelProperty(value = "是否允许下班打卡(0:否;1:是) 是否允许下班打卡(0:否;1:是)", example = "101")
private Integer isXbdk;
@ApiModelProperty(value = "允许迟到分钟数 允许迟到分钟数", example = "101")
private Integer yxcdfzs;
@ApiModelProperty(value = "严重迟到分钟数 严重迟到分钟数", example = "101")
private Integer yzcdfzs;
@ApiModelProperty(value = "旷工迟到分钟数 旷工迟到分钟数", example = "101")
private Integer kgcdfzs;
@ApiModelProperty(value = "是否开启晚走晚到(0:否;1:是) 是否开启晚走晚到(0:否;1:是)", example = "101")
private Integer isWzwd;
@ApiModelProperty(value = "下班晚走1(0:不启用 ", example = " 大于0启用 ---> 1/2/3 最大值为3)")
private String xbwz1;
@ApiModelProperty(value = "上班晚到1(0:不启用 ", example = " 大于0启用 ---> 1/2/3 最大值为3)")
private String sbwd1;
@ApiModelProperty(value = "下班晚走2(0:不启用 ", example = " 大于0启用 ---> 1/2/3 最大值为3)")
private String xbwz2;
@ApiModelProperty(value = "上班晚到2(0:不启用 ", example = " 大于0启用 ---> 1/2/3 最大值为3)")
private String sbwd2;
@ApiModelProperty(value = "下班晚走3(0:不启用 ", example = " 大于0启用 ---> 1/2/3 最大值为3)")
private String xbwz3;
@ApiModelProperty(value = "上班晚到3(0:不启用 ", example = " 大于0启用 ---> 1/2/3 最大值为3)")
private String sbwd3;
@ApiModelProperty(value = "备注 ", example = "备注")
private String beiz;
@ApiModelProperty(value = "企业id 企业id", example = "101")
private Integer qyid;
@ApiModelProperty(value = "录入时间 录入时间", example = "101")
private Long lusjTime;
@ApiModelProperty(value = "录入人员 录入人员", example = "101")
private Integer luryid;
}
\ No newline at end of file
package cn.timer.api.bean.kqmk;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Table;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
/**
* @author LAL 2020-05-09
*/
@Entity
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@Table(name = "kqgl_asso_dkdz")
@ApiModel("考勤打卡地址")
public class KqglAssoDkdz extends Model<KqglAssoDkdz> {
/**
*
*/
private static final long serialVersionUID = 1L;
@Id
@GeneratedValue
@TableId(type = IdType.AUTO)
@ApiModelProperty(value = "id id", example = "101")
private Integer id;
@ApiModelProperty(value = "打卡地址-名称 ", example = "打卡地址-名称")
private String name;
@ApiModelProperty(value = "详细地址 ", example = "详细地址")
private String address;
@ApiModelProperty(value = "打卡范围 打卡范围", example = "101")
private Integer dkfw;
@ApiModelProperty(value = "经度 ", example = "经度")
private Double lon;
@ApiModelProperty(value = "纬度 ", example = "纬度")
private Double lat;
@ApiModelProperty(value = "企业id 企业id", example = "101")
private Integer qyid;
@ApiModelProperty(value = "录入时间 录入时间", example = "101")
private Long lusjTime;
@ApiModelProperty(value = "录入人员 录入人员", example = "101")
private Integer luryid;
}
\ No newline at end of file
package cn.timer.api.bean.kqmk;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Table;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
/**
* @author LAL 2020-05-11
*/
@Entity
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@Table(name = "kqgl_asso_dkjl")
@ApiModel("打卡记录表")
public class KqglAssoDkjl extends Model<KqglAssoDkjl> {
/**
*
*/
private static final long serialVersionUID = 1L;
@Id
@GeneratedValue
@TableId(type = IdType.AUTO)
@ApiModelProperty(value = "id id", example = "101")
private Integer id;
@ApiModelProperty(value = "打卡时间 打卡时间", example = "101")
private Long dktime;
@ApiModelProperty(value = "经度 ", example = "经度")
private Double lon;
@ApiModelProperty(value = "纬度 ", example = "纬度")
private Double lat;
@ApiModelProperty(value = "定位地址 ", example = "定位地址")
private String address;
@ApiModelProperty(value = "打卡结果 打卡结果", example = "101")
private Integer results;
@ApiModelProperty(value = "用户id 用户id", example = "101")
private Integer userId;
@ApiModelProperty(value = "类型(0:无排班打卡 1:上班 2:下班)", example = "101")
private Integer type;
@ApiModelProperty(value = "(0:打卡无效:此记录已被更新 1:正常 2:异常 3:迟到 4:早退 5:补卡 6:请假 7:加班 8:调休)", example = "101")
private Integer status;
@ApiModelProperty(value = "序号(0:打卡无效:此记录已被更新) 序号(0:打卡无效:此记录已被更新)", example = "101")
private Integer sort;
@ApiModelProperty(value = "打卡类型(1:GPS 2:WIFI 3:考勤机)", example = "101")
private Integer cardType;
@ApiModelProperty(value = "mac地址 ", example = "mac地址")
private String mac;
@ApiModelProperty(value = "wifi名称 ", example = "wifi名称")
private String macname;
@ApiModelProperty(value = "企业id 企业id", example = "101")
private Integer qyid;
@ApiModelProperty(value = "考勤日期 ", example = "考勤日期")
private String attdate;
@ApiModelProperty(value = "考勤时间 ", example = "考勤时间")
private Long attime;
@ApiModelProperty(value = "打卡明细id 打卡明细id", example = "101")
private Integer dkmxid;
@ApiModelProperty(value = "班次id 班次id", example = "101")
private Integer bcid;
@ApiModelProperty(value = "考勤备注 ", example = "考勤备注")
private String remarks;
@ApiModelProperty(value = "考勤机打卡方式==>1:指紋;2:人脸;3:密码;4:ID卡 考勤机打卡方式==>1:指紋;2:人脸;3:密码;4:ID卡", example = "101")
private Integer punchmode;
@ApiModelProperty(value = "打卡设备 ", example = "打卡设备")
private String punchequipment;
}
\ No newline at end of file
package cn.timer.api.bean.kqmk;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Table;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
/**
* @author LAL 2020-05-11
*/
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@Table(name = "kqgl_asso_dkmx")
@ApiModel("打卡明细表")
public class KqglAssoDkmx extends Model<KqglAssoDkmx> {
/**
*
*/
private static final long serialVersionUID = 1L;
@Id
@GeneratedValue
@TableId(type = IdType.AUTO)
@ApiModelProperty(value = "id id", example = "101")
private Integer id;
@ApiModelProperty(value = "用户id 用户id", example = "101")
private Integer userid;
@ApiModelProperty(value = "日期 ", example = "日期")
private String data;
@ApiModelProperty(value = "上班1打卡时间 上班1打卡时间", example = "101")
private Long sbdk1;
@ApiModelProperty(value = "上班1打卡结果 上班1打卡结果", example = "101")
private Integer sbdk1jg;
@ApiModelProperty(value = "下班1打卡时间 下班1打卡时间", example = "101")
private Long xbdk1;
@ApiModelProperty(value = "下班1打卡结果 下班1打卡结果", example = "101")
private Integer xbdk1jg;
@ApiModelProperty(value = "上班2打卡时间 上班2打卡时间", example = "101")
private Long sbdk2;
@ApiModelProperty(value = "上班2打卡结果 上班2打卡结果", example = "101")
private Integer sbdk2jg;
@ApiModelProperty(value = "下班2打卡时间 下班2打卡时间", example = "101")
private Long xbdk2;
@ApiModelProperty(value = "下班2打卡结果 下班2打卡结果", example = "101")
private Integer xbdk2jg;
@ApiModelProperty(value = "上班3打卡时间 上班3打卡时间", example = "101")
private Long sbdk3;
@ApiModelProperty(value = "上班3打卡结果 上班3打卡结果", example = "101")
private Integer sbdk3jg;
@ApiModelProperty(value = "下班3打卡时间 下班3打卡时间", example = "101")
private Long xbdk3;
@ApiModelProperty(value = "下班3打卡结果 下班3打卡结果", example = "101")
private Integer xbdk3jg;
@ApiModelProperty(value = "应打卡次数 应打卡次数", example = "101")
private Integer ydkcs;
@ApiModelProperty(value = "工作时长 ", example = "工作时长")
private Double gzsc;
@ApiModelProperty(value = "企业id 企业id", example = "101")
private Integer qyid;
@ApiModelProperty(value = "打卡时间 打卡时间", example = "101")
private Long dksj;
}
\ No newline at end of file
package cn.timer.api.bean.kqmk;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Table;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
/**
* @author LAL 2020-05-09
*/
@Entity
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@Table(name = "kqgl_asso_dkwx")
@ApiModel("考勤打卡wifi")
public class KqglAssoDkwx extends Model<KqglAssoDkwx> {
/**
*
*/
private static final long serialVersionUID = 1L;
@Id
@GeneratedValue
@TableId(type = IdType.AUTO)
@ApiModelProperty(value = "id id", example = "101")
private Integer id;
@ApiModelProperty(value = "名称 ", example = "名称")
private String name;
@ApiModelProperty(value = "mac地址 ", example = "mac地址")
private String mac;
@ApiModelProperty(value = "企业id 企业id", example = "101")
private Integer qyid;
@ApiModelProperty(value = "录入时间 录入时间", example = "101")
private Long lusjTime;
@ApiModelProperty(value = "录入人员 录入人员", example = "101")
private Integer luryid;
}
\ No newline at end of file
package cn.timer.api.bean.kqmk;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Table;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
/**
* @author LAL 2020-05-09
*/
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@Table(name = "kqgl_asso_kqj")
@ApiModel("考勤机表")
public class KqglAssoKqj extends Model<KqglAssoKqj> {
/**
*
*/
private static final long serialVersionUID = 1L;
@Id
@GeneratedValue
@TableId(type = IdType.AUTO)
@ApiModelProperty(value = "id id", example = "1")
private Integer id;
@ApiModelProperty(value = "名称 ", example = "考勤机测试")
private String name;
@ApiModelProperty(value = "设备编码 ", example = "45654HF565HY5")
private String code;
@ApiModelProperty(value = "企业id 企业id", example = "117")
private Integer qyid;
@ApiModelProperty(value = "录入时间 录入时间", example = "1588988847000")
private Long lusjTime;
@ApiModelProperty(value = "录入人员 录入人员", example = "201")
private Integer luryid;
@ApiModelProperty(value = "类型(1:浩顺考勤机;2:中控考勤机) 类型(1:浩顺考勤机;2:中控考勤机)", example = "1")
private Integer type;
}
\ No newline at end of file
package cn.timer.api.bean.kqmk;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Table;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
import lombok.experimental.Tolerate;
/**
* @author LAL 2020-05-09
*/
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@Table(name = "kqgl_asso_kqzdkfs")
@ApiModel("考勤组绑定的打卡方式")
public class KqglAssoKqzdkfs extends Model<KqglAssoKqzdkfs> {
/**
*
*/
private static final long serialVersionUID = 1L;
@Id
@GeneratedValue
@TableId(type = IdType.AUTO)
@ApiModelProperty(value = "id id", example = "101")
private Integer id;
@ApiModelProperty(value = "打卡方式id(考勤机、WIFI、地址) 打卡方式id(考勤机、WIFI、地址)", example = "101")
private Integer dkfsid;
@ApiModelProperty(value = "考勤组ID 考勤组ID", example = "101")
private Integer kqzId;
@ApiModelProperty(value = "类型(1:考勤机;2:地址;3:WIFI) 类型(1:考勤机;2:地址;3:WIFI)", example = "101")
private Integer type;
@ApiModelProperty(value = "企业id 企业id", example = "101")
private Integer qyid;
@ApiModelProperty(value = "状态(0:停用;1:启用) 状态(0:停用;1:启用)", example = "101")
private Integer state;
}
\ No newline at end of file
package cn.timer.api.bean.kqmk;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Table;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
/**
* @author LAL 2020-05-09
*/
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@Table(name = "kqgl_asso_leave_balance")
@ApiModel("员工假期余额")
public class KqglAssoLeaveBalance extends Model<KqglAssoLeaveBalance> {
/**
*
*/
private static final long serialVersionUID = 1L;
@Id
@GeneratedValue
@TableId(type = IdType.AUTO)
@ApiModelProperty(value = "id id", example = "101")
private Integer id;
@ApiModelProperty(value = "假期规则id 假期规则id", example = "101")
private Integer leaveRulesId;
@ApiModelProperty(value = "员工id 员工id", example = "101")
private Integer userid;
@ApiModelProperty(value = "修改动作 1:增加;2:减少", example = "101")
private Integer modifyAction;
@ApiModelProperty(value = "余额天数 ", example = "余额天数")
private String balanceDays;
@ApiModelProperty(value = "理由 ", example = "理由")
private String reason;
@ApiModelProperty(value = "修改人 修改人", example = "101")
private Integer modifyUserid;
@ApiModelProperty(value = "修改时间 修改时间", example = "101")
private Long modifyTimer;
@ApiModelProperty(value = "修改序号 修改序号", example = "101")
private Integer modifyNumber;
@ApiModelProperty(value="企业组织代码 企业组织代码",example="101")
private Integer orgCode;
}
\ No newline at end of file
package cn.timer.api.bean.kqmk;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Table;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
/**
* @author LAL 2020-05-08
*/
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@Table(name = "kqgl_asso_leave_rules")
@ApiModel("假期规则")
public class KqglAssoLeaveRules extends Model<KqglAssoLeaveRules> {
/**
*
*/
private static final long serialVersionUID = 1L;
@Id
@GeneratedValue
@TableId(type = IdType.AUTO)
@ApiModelProperty(value = "假期规则编号 假期规则编号", example = "101")
private Integer id;
@ApiModelProperty(value = "假期名称 ", example = "假期名称")
private String name;
@ApiModelProperty(value = "请假单位 ", example = "1:按天请假;2:按半天;3:按小时")
private Integer company;
@ApiModelProperty(value = "假期类型 ", example = "1:系统项;2:自定义项")
private Integer leaveType;
@ApiModelProperty(value = "适用范围 ", example = "0:全公司 >0:考勤组id")
private String apply;
@ApiModelProperty(value = "创建时间 创建时间", example = "101")
private Long createTime;
@ApiModelProperty(value = "创建人员id 创建人员id", example = "101")
private Integer createUserid;
@ApiModelProperty(value = "企业组织代码 企业组织代码", example = "101")
private Integer orgCode;
@ApiModelProperty(value = "是否开启 0:否;1:是", example = "101")
private Integer isOpen;
@ApiModelProperty(value = "假期余额 0:关(该项余额为“不限余额”);1:开(该项余额为“0”)", example = "101")
private Integer leaveBalance;
}
\ No newline at end of file
package cn.timer.api.bean.kqmk;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Table;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
/**
* @author LAL 2020-05-08
*/
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@Table(name = "kqgl_asso_overtime_basics")
@ApiModel("加班基础设置")
public class KqglAssoOvertimeBasics extends Model<KqglAssoOvertimeBasics> {
/**
*
*/
private static final long serialVersionUID = 1L;
@Id
@GeneratedValue
@TableId(type = IdType.AUTO)
@ApiModelProperty(value = "id id", example = "1")
private Integer id;
@ApiModelProperty(value = "最小加班单位 1:按分钟加班、2:按半小时加班、3:按小时加班、4:按半天加班、5:按天加班", example = "1")
private Integer minimumUnit;
@ApiModelProperty(value = "修改人 修改人", example = "224")
private Integer modifyUserid;
@ApiModelProperty(value = "修改时间 修改时间", example = "1588902915035")
private Long modifyTime;
@ApiModelProperty(value = "企业组织代码 企业组织代码", example = "117")
private Integer orgCode;
}
\ No newline at end of file
package cn.timer.api.bean.kqmk;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Table;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
/**
* @author LAL 2020-05-07
*/
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@Table(name = "kqgl_asso_overtime_rules")
@ApiModel("加班规则")
public class KqglAssoOvertimeRules extends Model<KqglAssoOvertimeRules> {
/**
*
*/
private static final long serialVersionUID = 1L;
@Id
@GeneratedValue
@TableId(type = IdType.AUTO)
@ApiModelProperty(value = "加班规则编号 加班规则编号", example = "1")
private Integer id;
@ApiModelProperty(value = "规则名称 ", example = "以审批时间计算加班")
private String name;
@ApiModelProperty(value = "应用范围", example = "1")
private String appliedScope;
@ApiModelProperty(value = "工作日是否允许加班 0:否;1:是", example = "1")
private Integer isWorkovertime;
@ApiModelProperty(value = "计算方式 1:按审批时长计算", example = "1")
private Integer workMode;
@ApiModelProperty(value = "扣除休息时间开关 0:关;1:开", example = "0")
private Integer workBuckleRest;
@ApiModelProperty(value = "计为调休或加班费开关 0:关;1:开", example = "0")
private Integer workSwitch;
@ApiModelProperty(value = "1:按n计为调休 ", example = "1")
private String workOne;
@ApiModelProperty(value = "2:计为加班费 0:未选择;1:已选择", example = "0")
private Integer workTwo;
@ApiModelProperty(value = "3:多种选择 ", example = "1")
private String workThree;
@ApiModelProperty(value = "休息日是否允许加班 0:否;1:是", example = "0")
private Integer isRestovertime;
@ApiModelProperty(value = "计算方式 1:按审批时长计算", example = "1")
private Integer restMode;
@ApiModelProperty(value = "扣除休息时间开关 0:关;1:开", example = "0")
private Integer restBuckleRest;
@ApiModelProperty(value = "计为调休或加班费开关 0:关;1:开", example = "0")
private Integer restSwitch;
@ApiModelProperty(value = "1:按n计为调休 ", example = "1")
private String restOne;
@ApiModelProperty(value = "2:计为加班费 0:未选择;1:已选择", example = "0")
private Integer restTwo;
@ApiModelProperty(value = "3:多种选择 ", example = "1")
private String restThree;
@ApiModelProperty(value = "节假日是否允许加班 0:否;1:是", example = "0")
private Integer isHolidays;
@ApiModelProperty(value = "计算方式 ", example = "1")
private Double holidaysMode;
@ApiModelProperty(value = "扣除休息时间开关 0:关;1:开", example = "0")
private Integer holidaysBuckleRest;
@ApiModelProperty(value = "计为调休或加班费开关 0:关;1:开", example = "0")
private Integer holidaysSwitch;
@ApiModelProperty(value = "1:按n计为调休 ", example = "1")
private String holidaysOne;
@ApiModelProperty(value = "2:计为加班费 0:未选择;1:已选择", example = "0")
private Integer holidaysTwo;
@ApiModelProperty(value = "3:多种选择 ", example = "1")
private String holidaysThree;
@ApiModelProperty(value = "创建时间 ", example = "创建时间")
private Long createTime;
@ApiModelProperty(value = "创建人员 创建人员", example = "101")
private Integer createUserid;
@ApiModelProperty(value = "企业组织代码 企业组织代码", example = "117")
private Integer orgCode;
}
\ No newline at end of file
package cn.timer.api.bean.kqmk;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Table;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
/**
* @author LAL 2020-05-11
*/
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@Table(name = "kqgl_asso_pbmx")
@ApiModel("排班明细表")
public class KqglAssoPbmx extends Model<KqglAssoPbmx> {
/**
*
*/
private static final long serialVersionUID = 1L;
@Id
@GeneratedValue
@TableId(type = IdType.AUTO)
@ApiModelProperty(value = "id id", example = "101")
private Integer id;
@ApiModelProperty(value = "用户id 用户id", example = "101")
private Integer userid;
@ApiModelProperty(value = "日期 ", example = "日期")
private String data;
@ApiModelProperty(value = "班次id 班次id", example = "101")
private Integer bcid;
@ApiModelProperty(value = "考勤组id 考勤组id", example = "101")
private Integer kqzid;
}
\ No newline at end of file
package cn.timer.api.bean.kqmk;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Table;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
/**
* @author LAL 2020-05-08
*/
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@Table(name = "kqgl_asso_rules_vice")
@ApiModel("假期规则-适用范围")
public class KqglAssoRulesVice extends Model<KqglAssoRulesVice> {
/**
*
*/
private static final long serialVersionUID = 1L;
@Id
@GeneratedValue
@TableId(type = IdType.AUTO)
@ApiModelProperty(value = "编号 编号", example = "101")
private Integer id;
@ApiModelProperty(value = "假期规则id 假期规则id", example = "101")
private Integer leaveRulesId;
@ApiModelProperty(value = "适用的考勤组id 适用的考勤组id", example = "101")
private Integer attgroupId;
}
\ No newline at end of file
package cn.timer.api.bean.kqmk;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Table;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
/**
* @author LAL 2020-05-11
*/
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@Table(name = "kqgl_asso_teshu")
@ApiModel("特殊日期表")
public class KqglAssoTeshu extends Model<KqglAssoTeshu> {
/**
*
*/
private static final long serialVersionUID = 1L;
@Id
@GeneratedValue
@TableId(type = IdType.AUTO)
@ApiModelProperty(value = "id id", example = "101")
private Integer id;
@ApiModelProperty(value = "考勤组id 考勤组id", example = "101")
private Integer kqzid;
@ApiModelProperty(value = "日期 ", example = "日期")
private String tsrq;
@ApiModelProperty(value = "班次id 班次id", example = "101")
private Integer bcid;
@ApiModelProperty(value = "录入时间 录入时间", example = "101")
private Integer lusjTime;
@ApiModelProperty(value = "录入人员 录入人员", example = "101")
private Integer luryid;
@ApiModelProperty(value = "类型(1:必须打卡日期;2:不用打卡日期(扩展字段)) 类型(1:必须打卡日期;2:不用打卡日期(扩展字段))", example = "101")
private Integer type;
}
\ No newline at end of file
package cn.timer.api.bean.kqmk;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Table;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
/**
* @author LAL 2020-05-09
*/
@Entity
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@Table(name = "kqgl_asso_yhsb")
@ApiModel("用户与设备关系表")
public class KqglAssoYhsb extends Model<KqglAssoYhsb> {
/**
*
*/
private static final long serialVersionUID = 1L;
@Id
@GeneratedValue
@TableId(type = IdType.AUTO)
@ApiModelProperty(value = "id id", example = "101")
private Integer id;
@ApiModelProperty(value = "用户id 用户id", example = "101")
private Integer userId;
@ApiModelProperty(value = "设备id 设备id", example = "101")
private Integer kqjid;
@ApiModelProperty(value = "类型(类型 1:考勤机)", example = "101")
private Integer type;
@ApiModelProperty(value = "是否为管理员--0:否;1:是 是否为管理员--0:否;1:是", example = "101")
private Integer isGly;
}
\ No newline at end of file
package cn.timer.api.bean.kqmk;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Table;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
/**
* @author LAL 2020-05-11
*/
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@Table(name = "kqgl_asso_zhoupaiban")
@ApiModel("考勤周排班")
public class KqglAssoZhoupaiban extends Model<KqglAssoZhoupaiban> {
/**
*
*/
private static final long serialVersionUID = 1L;
@Id
@GeneratedValue
@TableId(type = IdType.AUTO)
@ApiModelProperty(value = "id id", example = "101")
private Integer id;
@ApiModelProperty(value = "考勤组id 考勤组id", example = "101")
private Integer kqzid;
@ApiModelProperty(value = "类型(1:周一、2:周二、3:周三。。。。、8:周一到周日统一班次、9:排班制) 类型(1:周一、2:周二、3:周三。。。。、8:周一到周日统一班次、9:排班制)", example = "101")
private Integer type;
@ApiModelProperty(value = "班次id(0:自由工时 班次id【大于0为:固定排班和排班制】)", example = "101")
private Integer bcid;
}
\ No newline at end of file
package cn.timer.api.bean.kqmk;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Table;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
/**
* @author LAL 2020-05-09
*/
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@Table(name = "kqgl_main_kqz")
@ApiModel("考勤组")
public class KqglMainKqz extends Model<KqglMainKqz> {
/**
*
*/
private static final long serialVersionUID = 1L;
@Id
@GeneratedValue
@TableId(type = IdType.AUTO)
@ApiModelProperty(value = "id id", example = "101")
private Integer id;
@ApiModelProperty(value = "名称 ", example = "名称")
private String name;
@ApiModelProperty(value = "考勤备注 ", example = "考勤备注")
private String kqbz;
@ApiModelProperty(value = "排班方式(1:固定排班;2:自由排班;3:自由工时) 排班方式(1:固定排班;2:自由排班;3:自由工时)", example = "101")
private Integer pbfs;
@ApiModelProperty(value = "企业id 企业id", example = "101")
private Integer qyid;
@ApiModelProperty(value = "是否开启法定节假日休息 是否开启法定节假日休息", example = "101")
private Integer isFdjjr;
@ApiModelProperty(value = "考勤开始时间(自由工时专用) ", example = "考勤开始时间(自由工时专用)")
private String kqkssjTime;
@ApiModelProperty(value = "至少工作时长(自由工时专用--【已去掉】) ", example = "至少工作时长(自由工时专用--【已去掉】)")
private String zsgzsc;
@ApiModelProperty(value = "正常工作时长(自由工时专用--【已去掉】) ", example = "正常工作时长(自由工时专用--【已去掉】)")
private String zcgzsc;
@ApiModelProperty(value = "上班后多久可打下班卡(自由工时专用) ", example = "上班后多久可打下班卡(自由工时专用)")
private String jbzdsc;
@ApiModelProperty(value = "是否开启到期提醒([排班制专用]0:否;1:是) 是否开启到期提醒([排班制专用]0:否;1:是)", example = "101")
private Integer isDqtx;
@ApiModelProperty(value = "提醒人员([排班制专用]员工id以[“,”]连接 ", example = "json数组)")
private String txry;
@ApiModelProperty(value = "提醒方式([排班制专用]提前15天、7天、3天、1天) 提醒方式([排班制专用]提前15天、7天、3天、1天)", example = "101")
private Integer txfs;
@ApiModelProperty(value = "提醒循环天数([排班制专用]) 提醒循环天数([排班制专用])", example = "101")
private Integer txxhts;
@ApiModelProperty(value = "提醒时间([排班制专用]) ", example = "提醒时间([排班制专用])")
private String txsjTime;
@ApiModelProperty(value = "提示方式([排班制专用]PC端、APP客户端、短信、邮件 ", example = "以[“,”]连接 json数组)")
private String tsfs;
@ApiModelProperty(value = "是否开启未排班时打卡([排班制专用]0:否;1:是;未排班时,员工可以选择班次打卡) 是否开启未排班时打卡([排班制专用]0:否;1:是;未排班时,员工可以选择班次打卡)", example = "101")
private Integer isWpbsdk;
@ApiModelProperty(value = "使用班次【排班制使用】 ", example = "使用班次【排班制使用】")
private String sybc;
@ApiModelProperty(value = "是否开启未排班时,员工可选择班次打卡 是否开启未排班时,员工可选择班次打卡", example = "101")
private Integer isXzbcdk;
@ApiModelProperty(value = "外勤 外勤", example = "101")
private Integer isWq;
}
\ No newline at end of file
package cn.timer.api.config.exception; package cn.timer.api.config.exception;
import java.util.ArrayList;
import java.util.List;
import org.slf4j.Logger; import org.slf4j.Logger;
import org.slf4j.LoggerFactory; import org.slf4j.LoggerFactory;
import org.springframework.validation.ObjectError;
import org.springframework.web.bind.MethodArgumentNotValidException;
import org.springframework.web.bind.annotation.ExceptionHandler; import org.springframework.web.bind.annotation.ExceptionHandler;
import org.springframework.web.bind.annotation.RestControllerAdvice; import org.springframework.web.bind.annotation.RestControllerAdvice;
import cn.hutool.core.util.StrUtil; import cn.hutool.core.util.StrUtil;
import cn.hutool.json.JSONObject;
import cn.hutool.json.JSONUtil;
import cn.timer.api.aspect.lang.bean.ValidationError;
import cn.timer.api.utils.Result; import cn.timer.api.utils.Result;
import cn.timer.api.utils.ResultUtil; import cn.timer.api.utils.ResultUtil;
...@@ -57,4 +65,31 @@ public class GlobalExceptionHandler { ...@@ -57,4 +65,31 @@ public class GlobalExceptionHandler {
} }
return ResultUtil.error(e.getCode(), e.getMessage()); return ResultUtil.error(e.getCode(), e.getMessage());
} }
/**
* 自定义验证异常
*/
@ExceptionHandler(MethodArgumentNotValidException.class)
public Object validExceptionHandler(MethodArgumentNotValidException e)
{
// log.error("1--------"+e.getMessage());
// log.error("2--------"+JSONUtil.parse(e.getBindingResult().getAllErrors()));
// String message = e.getBindingResult().getFieldError().getDefaultMessage();
// String field = e.getBindingResult().getFieldError().getField();
List<ObjectError> ls = e.getBindingResult().getAllErrors();
List<ValidationError> listVe = new ArrayList<ValidationError>();
ValidationError ve;
for (ObjectError one : ls) {
String fieldString = one.getCodes().length >= 1 ? one.getCodes()[0] : "";
if (fieldString != null) {
fieldString = fieldString.substring(fieldString.lastIndexOf(".") + 1);
}
ve = ValidationError.builder().field(fieldString).msg(one.getDefaultMessage()).build();
listVe.add(ve);
}
return ResultUtil.error(listVe);
}
} }
package cn.timer.api.config.exception;
public class ValidationMsg {
public static final String NULL = "参数必须为空";
public static final String NOTNULL = "参数值不能为空";
public static final String NOTEMPTY = "参数值不能为空";
public static final String NOTBLANK = "参数键值不能为空";
public static final String ASSERTTRUE = "参数值必须为true";
public static final String ASSERTFALSE = "参数值必须为false";
public static final String PATTERN = "参数值格式不符";
public static final String SIZE = "参数长度不符";
public static final String MIN = "参数值太小";
public static final String MAX = "参数值太大";
public static final String DECIMALMIN = "参数值太小";
public static final String DECIMALMAX = "参数值太大";
public static final String DIGITS = "参数值大小不在有效范围内";
public static final String PAST = "参数值必须为过去日期";
public static final String FUTURE = "参数值必须为未来日期";
public static final String EMAIL = "参数值格式必须为邮箱地址";
public static final String LENGTH = "参数值长度不在有效范围内";
public static final String RANGE = "参数值不在有效范围内";
}
...@@ -22,9 +22,10 @@ public class MyConfiguration { ...@@ -22,9 +22,10 @@ public class MyConfiguration {
// 创建配置类 // 创建配置类
FastJsonConfig config = new FastJsonConfig(); FastJsonConfig config = new FastJsonConfig();
config.setSerializerFeatures( config.setSerializerFeatures(
SerializerFeature.WriteNullListAsEmpty, SerializerFeature.PrettyFormat
SerializerFeature.WriteMapNullValue, // SerializerFeature.WriteNullListAsEmpty,
SerializerFeature.WriteNullStringAsEmpty // SerializerFeature.WriteMapNullValue,
// SerializerFeature.WriteNullStringAsEmpty
); );
//此处是全局处理方式 //此处是全局处理方式
......
...@@ -45,7 +45,7 @@ public class WebSecurityConfig implements WebMvcConfigurer { ...@@ -45,7 +45,7 @@ public class WebSecurityConfig implements WebMvcConfigurer {
.excludePathPatterns("/v2/**") .excludePathPatterns("/v2/**")
.excludePathPatterns("/**/*.js") .excludePathPatterns("/**/*.js")
.excludePathPatterns("/8timer/**") .excludePathPatterns("/8timer/**")
.excludePathPatterns("/kqz/punchclock/**") .excludePathPatterns("/kqdk/punchclock/**")
.excludePathPatterns("/kqz/sauserregdata/**") .excludePathPatterns("/kqz/sauserregdata/**")
.excludePathPatterns("/login/*") .excludePathPatterns("/login/*")
.excludePathPatterns("/swagger*/**") .excludePathPatterns("/swagger*/**")
...@@ -75,7 +75,7 @@ public class WebSecurityConfig implements WebMvcConfigurer { ...@@ -75,7 +75,7 @@ public class WebSecurityConfig implements WebMvcConfigurer {
// 2.添加fastJson的配置信息,比如,是否需要格式化返回的json数据 // 2.添加fastJson的配置信息,比如,是否需要格式化返回的json数据
FastJsonConfig fastJsonConfig = new FastJsonConfig(); FastJsonConfig fastJsonConfig = new FastJsonConfig();
// 时间格式化 // 时间格式化
// fastJsonConfig.setDateFormat("yyyy-MM-dd HH:mm:ss"); fastJsonConfig.setDateFormat("yyyy-MM-dd HH:mm:ss");
// fastJsonConfig.setDateFormat("yyyy-MM-dd"); // fastJsonConfig.setDateFormat("yyyy-MM-dd");
// 空值特别处理 // 空值特别处理
// WriteNullListAsEmpty 将Collection类型字段的字段空值输出为[] // WriteNullListAsEmpty 将Collection类型字段的字段空值输出为[]
......
package cn.timer.api.controller.kqgl;
import java.text.DateFormat;
import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.Calendar;
import java.util.Date;
import java.util.Locale;
/**
* @author Yl123 2020-05-11
*
*/
public class ClockInTool {
public static String dateToWeek2(String datetime) {
SimpleDateFormat f = new SimpleDateFormat("yyyy-MM-dd");
String[] weekDays = { "星期日", "星期一", "星期二", "星期三", "星期四", "星期五", "星期六" };
// String[] weekDays = {"7", "1", "2", "3", "4", "5", "6"};
Calendar cal = Calendar.getInstance();
Date date;
try {
date = f.parse(datetime);
cal.setTime(date);
} catch (ParseException e) {
e.printStackTrace();
}
// 一周的第几天
int w = cal.get(Calendar.DAY_OF_WEEK) - 1;
if (w < 0)
w = 0;
return weekDays[w];
}
/**
*
* @param nowDate 要比较的时间
* @param startDate 开始时间
* @param endDate 结束时间
* @return true在时间段内,false不在时间段内
* @throws Exception
*/
public static boolean hourMinuteBetween(String nowDate, String startDate, String endDate) throws Exception {
SimpleDateFormat format = new SimpleDateFormat("HH:mm");
Date now = format.parse(nowDate);
Date start = format.parse(startDate);
Date end = format.parse(endDate);
long nowTime = now.getTime();
long startTime = start.getTime();
long endTime = end.getTime();
return nowTime >= startTime && nowTime <= endTime;
}
/**
* 根据日期获取 星期 (2019-05-06 ——> 星期一)
*
* @param datetime
* @return
*/
public static String dateToWeek(String datetime) {
SimpleDateFormat f = new SimpleDateFormat("yyyy-MM-dd");
// String[] weekDays = {"星期日", "星期一", "星期二", "星期三", "星期四", "星期五", "星期六"};
String[] weekDays = { "7", "1", "2", "3", "4", "5", "6" };
Calendar cal = Calendar.getInstance();
Date date;
try {
date = f.parse(datetime);
cal.setTime(date);
} catch (ParseException e) {
e.printStackTrace();
}
// 一周的第几天
int w = cal.get(Calendar.DAY_OF_WEEK) - 1;
if (w < 0)
w = 0;
return weekDays[w];
}
/**
* 2019-10-24T00:30:23.000Z 转化时间
*/
public static String dealDateFormat(String oldDateStr, int num) {
DateFormat df = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss.SSSXXX"); // yyyy-MM-dd'T'HH:mm:ss.SSSZ
Date date = null;
try {
date = df.parse(oldDateStr);
} catch (ParseException e) {
e.printStackTrace();
}
SimpleDateFormat df1 = new SimpleDateFormat("EEE MMM dd HH:mm:ss Z yyyy", Locale.UK);
Date date1 = null;
try {
date1 = df1.parse(date.toString());
} catch (ParseException e) {
e.printStackTrace();
}
DateFormat df2 = null;
if (num == 1) {
df2 = new SimpleDateFormat("yyyy-MM-dd' 'HH:mm:ss");
} else if (num == 2) {
df2 = new SimpleDateFormat("HH:mm");
}
return df2.format(date1);
}
/**
* 时间转换时间戳
*/
public static String dateToStamp(String s) {
String res;
SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
Date date = null;
try {
date = simpleDateFormat.parse(s);
} catch (ParseException e) {
e.printStackTrace();
}
long ts = date.getTime();
res = String.valueOf(ts);
return res;
}
}
...@@ -9,6 +9,8 @@ import javax.validation.Valid; ...@@ -9,6 +9,8 @@ import javax.validation.Valid;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.transaction.annotation.Transactional; import org.springframework.transaction.annotation.Transactional;
import org.springframework.validation.BindingResult; import org.springframework.validation.BindingResult;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.MethodArgumentNotValidException;
import org.springframework.web.bind.annotation.DeleteMapping; import org.springframework.web.bind.annotation.DeleteMapping;
import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable; import org.springframework.web.bind.annotation.PathVariable;
...@@ -167,7 +169,7 @@ public class SpmkController { ...@@ -167,7 +169,7 @@ public class SpmkController {
@PostMapping(value = "/save_approval_template") @PostMapping(value = "/save_approval_template")
@ApiOperation(value = "5.新增或编辑-审批模板", httpMethod = "POST", notes = "新增或编辑-审批模板") @ApiOperation(value = "5.新增或编辑-审批模板", httpMethod = "POST", notes = "新增或编辑-审批模板")
@ApiOperationSupport(order = 5) @ApiOperationSupport(order = 5)
public Result<Object> saveAt(@Valid @RequestBody SpmkApprovalTemplateDto spmkApprovalTemplateDto,BindingResult bindingResult){ public Result<Object> saveAt(@Validated @RequestBody SpmkApprovalTemplateDto spmkApprovalTemplateDto){
Integer approvalTemplateGId = spmkApprovalTemplateDto.getApprovalTemplateGId(); Integer approvalTemplateGId = spmkApprovalTemplateDto.getApprovalTemplateGId();
if (ObjectUtil.isNull(approvalTemplateGId)) if (ObjectUtil.isNull(approvalTemplateGId))
return ResultUtil.error("操作失败!-1"); return ResultUtil.error("操作失败!-1");
...@@ -415,8 +417,7 @@ public class SpmkController { ...@@ -415,8 +417,7 @@ public class SpmkController {
@ApiOperation(value = "17.发起审批", httpMethod = "POST", notes = "发起审批") @ApiOperation(value = "17.发起审批", httpMethod = "POST", notes = "发起审批")
@ApiOperationSupport(order = 17) @ApiOperationSupport(order = 17)
@Transactional(rollbackFor = Exception.class) @Transactional(rollbackFor = Exception.class)
// @BindingResultCtrol(title = "发起审批") public Result<Object> saveCa(@CurrentUser UserBean userBean,@Validated @RequestBody SpmkApproveSummaryDto spmkApproveSummaryDto) throws Exception{
public Result<Object> saveCa(@CurrentUser UserBean userBean,@Valid @RequestBody SpmkApproveSummaryDto spmkApproveSummaryDto,BindingResult bindingResult) throws Exception{
YgglMainEmp ygglMainEmp = YgglMainEmp.builder().build().selectOne(new QueryWrapper<YgglMainEmp>() YgglMainEmp ygglMainEmp = YgglMainEmp.builder().build().selectOne(new QueryWrapper<YgglMainEmp>()
.lambda() .lambda()
.select(YgglMainEmp::getHeadUrl,YgglMainEmp::getName) .select(YgglMainEmp::getHeadUrl,YgglMainEmp::getName)
...@@ -545,7 +546,7 @@ public class SpmkController { ...@@ -545,7 +546,7 @@ public class SpmkController {
@Transactional(rollbackFor = Exception.class) @Transactional(rollbackFor = Exception.class)
@ApiOperationSupport(order = 20) @ApiOperationSupport(order = 20)
// @BindingResultCtrol(title = "审批人审批") // @BindingResultCtrol(title = "审批人审批")
public Result<Object> approving(@Valid @RequestBody ApprovingDto approvingDto, BindingResult bindingResult) throws Exception { public Result<Object> approving(@Validated @RequestBody ApprovingDto approvingDto) throws Exception {
SpmkApproveDetail ad = SpmkApproveDetail.builder().build().selectOne(new QueryWrapper<SpmkApproveDetail>() SpmkApproveDetail ad = SpmkApproveDetail.builder().build().selectOne(new QueryWrapper<SpmkApproveDetail>()
.lambda() .lambda()
.select(SpmkApproveDetail::getId, .select(SpmkApproveDetail::getId,
...@@ -615,7 +616,7 @@ public class SpmkController { ...@@ -615,7 +616,7 @@ public class SpmkController {
@PostMapping(value = "/select_my_approve") @PostMapping(value = "/select_my_approve")
@ApiOperation(value = "21.查询列表-我审批的/抄送我的-分页", httpMethod = "POST", notes = "查询列表-我审批的-关键字、审批状态、发起时间-分页") @ApiOperation(value = "21.查询列表-我审批的/抄送我的-分页", httpMethod = "POST", notes = "查询列表-我审批的-关键字、审批状态、发起时间-分页")
@ApiOperationSupport(order = 21) @ApiOperationSupport(order = 21)
public Result<Object> selectMyAs(@CurrentUser UserBean userBean, @RequestBody MySummaryQueryDto mySummaryQueryDto) { public Result<Object> selectMyAs(@CurrentUser UserBean userBean, @Validated @RequestBody MySummaryQueryDto mySummaryQueryDto) throws MethodArgumentNotValidException{
IPage<SpmkApproveSummary> page = new Page<SpmkApproveSummary>( IPage<SpmkApproveSummary> page = new Page<SpmkApproveSummary>(
mySummaryQueryDto.getCurrentPage() == null ? 1 : mySummaryQueryDto.getCurrentPage(), mySummaryQueryDto.getCurrentPage() == null ? 1 : mySummaryQueryDto.getCurrentPage(),
mySummaryQueryDto.getTotalPage() == null ? 10 : mySummaryQueryDto.getTotalPage()); mySummaryQueryDto.getTotalPage() == null ? 10 : mySummaryQueryDto.getTotalPage());
...@@ -625,7 +626,6 @@ public class SpmkController { ...@@ -625,7 +626,6 @@ public class SpmkController {
IPage<SpmkApproveSummary> pageAs = spmkApproveSummaryMapper.selectPageByQueryForEmpNum(page, mySummaryQueryDto); IPage<SpmkApproveSummary> pageAs = spmkApproveSummaryMapper.selectPageByQueryForEmpNum(page, mySummaryQueryDto);
List<SpmkApproveSummary> listAs = pageAs.getRecords(); List<SpmkApproveSummary> listAs = pageAs.getRecords();
return ResultUtil.data(pageAs, listAs, "操作成功!"); return ResultUtil.data(pageAs, listAs, "操作成功!");
} }
...@@ -681,7 +681,6 @@ public class SpmkController { ...@@ -681,7 +681,6 @@ public class SpmkController {
@ApiOperation(value = "90.(开发使用)删除-审批数据", httpMethod = "DELETE", notes = "审批组、自定义审批、审批汇总、审批详情、审批执行记录、审批执行人记录 所有数据") @ApiOperation(value = "90.(开发使用)删除-审批数据", httpMethod = "DELETE", notes = "审批组、自定义审批、审批汇总、审批详情、审批执行记录、审批执行人记录 所有数据")
@ApiOperationSupport(order = 90) @ApiOperationSupport(order = 90)
public Result<Object> deleteApprovalData(@CurrentUser UserBean userBean){ public Result<Object> deleteApprovalData(@CurrentUser UserBean userBean){
spmkApprovalGMapper.delete(null); spmkApprovalGMapper.delete(null);
spmkCustomApprovalMapper.delete(null); spmkCustomApprovalMapper.delete(null);
spmkApproveSummaryMapper.delete(null); spmkApproveSummaryMapper.delete(null);
......
...@@ -1546,7 +1546,7 @@ public class YgglController { ...@@ -1546,7 +1546,7 @@ public class YgglController {
updateWrapper.eq("emp_num", empNum); updateWrapper.eq("emp_num", empNum);
UpdateWrapper<YgglMainLzb> updateWrapper1 = new UpdateWrapper<YgglMainLzb>(); UpdateWrapper<YgglMainLzb> updateWrapper1 = new UpdateWrapper<YgglMainLzb>();
updateWrapper1.eq("emp_num", empNum); updateWrapper1.eq("emp_num", empNum);
YgglMainEmp.builder().empNum(lzygQueryDto.getEmpNum()).jobStatus(3).build().update(updateWrapper); YgglMainEmp.builder().empNum(lzygQueryDto.getEmpNum()).jobStatus(YgEnumInterface.jobStatus.LIZHIZHONG.getType()).build().update(updateWrapper);
YgglMainLzb.builder().jobStatus(YgEnumInterface.jobStatus.LIZHIZHONG.getType()).lzTime(lzygQueryDto.getLzTime()) YgglMainLzb.builder().jobStatus(YgEnumInterface.jobStatus.LIZHIZHONG.getType()).lzTime(lzygQueryDto.getLzTime())
.lzyy(lzygQueryDto.getLzyy()).lzbz(lzygQueryDto.getLzbz()).build().update(updateWrapper1); .lzyy(lzygQueryDto.getLzyy()).lzbz(lzygQueryDto.getLzbz()).build().update(updateWrapper1);
...@@ -1813,7 +1813,7 @@ public class YgglController { ...@@ -1813,7 +1813,7 @@ public class YgglController {
@ApiOperation(value = "查询员工列表", httpMethod = "GET", notes = "接口发布说明") @ApiOperation(value = "查询员工列表", httpMethod = "GET", notes = "接口发布说明")
@ApiOperationSupport(order = 62) @ApiOperationSupport(order = 62)
public Result<List<YgQueryDto>> queryEmpMessage(@CurrentUser UserBean userBean) { public Result<List<YgQueryDto>> queryEmpMessage(@CurrentUser UserBean userBean) {
List<YgQueryDto> ygQueryDto = ygglMainEmpMapper.queryEmpMessage(userBean); List<YgQueryDto> ygQueryDto = ygglMainEmpMapper.queryEmpMessage(userBean.getOrgCode());
for (YgQueryDto yg : ygQueryDto) { for (YgQueryDto yg : ygQueryDto) {
if (StringUtil.isEmpty(yg.getHeadUrl())) { if (StringUtil.isEmpty(yg.getHeadUrl())) {
yg.setHeadUrl(""); yg.setHeadUrl("");
......
package cn.timer.api.dao.kqmk;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import java.util.List;
import org.springframework.stereotype.Repository;
import cn.timer.api.bean.kqmk.KqglAssOvertimeVice;
/**
* 加班规则-扣除休息时间
*
* @author LAL 2020-05-07
*/
@Repository
public interface KqglAssOvertimeViceMapper extends BaseMapper<KqglAssOvertimeVice> {
int insertovertimeviceList(List<KqglAssOvertimeVice> kqglassovertimevice);
}
package cn.timer.api.dao.kqmk;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.springframework.stereotype.Repository;
import cn.timer.api.bean.kqmk.KqglAssoBcsz;
/**
* 班次表
* @author LAL 2020-05-07
*/
@Repository
public interface KqglAssoBcszMapper extends BaseMapper<KqglAssoBcsz> {
int insert(KqglAssoBcsz kqglassobcsz);
int update(KqglAssoBcsz kqglassobcsz);
}
package cn.timer.api.dao.kqmk;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.springframework.stereotype.Repository;
import cn.timer.api.bean.kqmk.KqglAssoDkdz;
/**
* 考勤打卡地址
*
* @author LAL 2020-05-09
*/
@Repository
public interface KqglAssoDkdzMapper extends BaseMapper<KqglAssoDkdz> {
}
package cn.timer.api.dao.kqmk;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.springframework.stereotype.Repository;
import cn.timer.api.bean.kqmk.KqglAssoDkjl;
/**
* 打卡记录表
*
* @author LAL 2020-05-11
*/
@Repository
public interface KqglAssoDkjlMapper extends BaseMapper<KqglAssoDkjl> {
}
package cn.timer.api.dao.kqmk;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.springframework.stereotype.Repository;
import cn.timer.api.bean.kqmk.KqglAssoDkmx;
/**
* 打卡明细表
*
* @author LAL 2020-05-11
*/
@Repository
public interface KqglAssoDkmxMapper extends BaseMapper<KqglAssoDkmx> {
}
package cn.timer.api.dao.kqmk;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.springframework.stereotype.Repository;
import cn.timer.api.bean.kqmk.KqglAssoDkwx;
/**
* 考勤打卡wifi
*
* @author LAL 2020-05-09
*/
@Repository
public interface KqglAssoDkwxMapper extends BaseMapper<KqglAssoDkwx> {
}
package cn.timer.api.dao.kqmk;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.springframework.stereotype.Repository;
import cn.timer.api.bean.kqmk.KqglAssoKqj;
/**
* 考勤机表
*
* @author LAL 2020-05-09
*/
@Repository
public interface KqglAssoKqjMapper extends BaseMapper<KqglAssoKqj> {
}
package cn.timer.api.dao.kqmk;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.springframework.stereotype.Repository;
import cn.timer.api.bean.kqmk.KqglAssoKqzdkfs;
/**
* 考勤组绑定的打卡方式
*
* @author LAL 2020-05-09
*/
@Repository
public interface KqglAssoKqzdkfsMapper extends BaseMapper<KqglAssoKqzdkfs> {
}
package cn.timer.api.dao.kqmk;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.springframework.stereotype.Repository;
import cn.timer.api.bean.kqmk.KqglAssoLeaveBalance;
/**
* 员工假期余额
*
* @author LAL 2020-05-09
*/
@Repository
public interface KqglAssoLeaveBalanceMapper extends BaseMapper<KqglAssoLeaveBalance> {
}
package cn.timer.api.dao.kqmk;
import java.util.List;
import org.springframework.stereotype.Repository;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import cn.timer.api.bean.kqmk.KqglAssoLeaveRules;
/**
* 假期规则
*
* @author LAL 2020-05-08
*/
@Repository
public interface KqglAssoLeaveRulesMapper extends BaseMapper<KqglAssoLeaveRules> {
int insertleaverulesList(List<KqglAssoLeaveRules> kqglassoleaverules);
}
package cn.timer.api.dao.kqmk;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.springframework.stereotype.Repository;
import cn.timer.api.bean.kqmk.KqglAssoOvertimeBasics;
/**
* 加班基础设置
* @author LAL 2020-05-08
*/
@Repository
public interface KqglAssoOvertimeBasicsMapper extends BaseMapper<KqglAssoOvertimeBasics> {
}
package cn.timer.api.dao.kqmk;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.springframework.stereotype.Repository;
import cn.timer.api.bean.kqmk.KqglAssoOvertimeRules;
/**
* 加班规则
*
* @author LAL 2020-05-07
*/
@Repository
public interface KqglAssoOvertimeRulesMapper extends BaseMapper<KqglAssoOvertimeRules> {
}
package cn.timer.api.dao.kqmk;
import org.springframework.stereotype.Repository;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import cn.timer.api.bean.kqmk.KqglAssoPbmx;
import cn.timer.api.dto.kqmk.KqglAssoPbmxDto;
/**
* 排班明细表
*
* @author LAL 2020-05-11
*/
@Repository
public interface KqglAssoPbmxMapper extends BaseMapper<KqglAssoPbmx> {
KqglAssoPbmxDto getScheduleSpecificAttendance(Integer kqzid, Integer userid, String date);
}
package cn.timer.api.dao.kqmk;
import java.util.List;
import org.springframework.stereotype.Repository;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import cn.timer.api.bean.kqmk.KqglAssoRulesVice;
/**
* 假期规则-适用范围
* @author LAL 2020-05-08
*/
@Repository
public interface KqglAssoRulesViceMapper extends BaseMapper<KqglAssoRulesVice> {
int insertrulesviceList(List<KqglAssoRulesVice> kqglassorulesvice);
}
package cn.timer.api.dao.kqmk;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.springframework.stereotype.Repository;
import cn.timer.api.bean.kqmk.KqglAssoTeshu;
/**
* 特殊日期表
*
* @author LAL 2020-05-11
*/
@Repository
public interface KqglAssoTeshuMapper extends BaseMapper<KqglAssoTeshu> {
}
package cn.timer.api.dao.kqmk;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import java.util.List;
import org.springframework.stereotype.Repository;
import cn.timer.api.bean.kqmk.KqglAssoYhsb;
import cn.timer.api.dto.kqmk.MachinememberDto;
/**
* 用户与设备关系表
* @author LAL 2020-05-09
*/
@Repository
public interface KqglAssoYhsbMapper extends BaseMapper<KqglAssoYhsb> {
List<MachinememberDto> selectAircraftMembers(int kqjid,int orgcode);
}
package cn.timer.api.dao.kqmk;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.springframework.stereotype.Repository;
import cn.timer.api.bean.kqmk.KqglAssoZhoupaiban;
/**
* 考勤周排班
*
* @author LAL 2020-05-11
*/
@Repository
public interface KqglAssoZhoupaibanMapper extends BaseMapper<KqglAssoZhoupaiban> {
}
package cn.timer.api.dao.kqmk;
import java.util.List;
import org.springframework.stereotype.Repository;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import cn.timer.api.bean.kqmk.KqglMainKqz;
import cn.timer.api.dto.kqmk.KqglMainKqzDto;
/**
* 考勤组
*
* @author LAL 2020-05-09
*/
@Repository
public interface KqglMainKqzMapper extends BaseMapper<KqglMainKqz> {
List<KqglMainKqzDto> selectAttGroupMachineByQyid(int qyid);
KqglMainKqz getAttendanceGroupInformationByUserid(int userid,int qyid);
}
...@@ -2,6 +2,7 @@ package cn.timer.api.dao.yggl; ...@@ -2,6 +2,7 @@ package cn.timer.api.dao.yggl;
import java.util.List; import java.util.List;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository; import org.springframework.stereotype.Repository;
import org.springframework.web.bind.annotation.PathVariable; import org.springframework.web.bind.annotation.PathVariable;
...@@ -46,7 +47,7 @@ public interface YgglMainEmpMapper extends BaseMapper<YgglMainEmp> { ...@@ -46,7 +47,7 @@ public interface YgglMainEmpMapper extends BaseMapper<YgglMainEmp> {
* @param userBean * @param userBean
* @return * @return
*/ */
List<YgQueryDto> queryEmpMessage(UserBean userBean); List<YgQueryDto> queryEmpMessage(@Param("orgCode") Integer orgCode);
/** /**
......
package cn.timer.api.dto.kqmk;
import java.io.Serializable;
import io.swagger.annotations.ApiModel;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
/**
* @author lalqq 打卡方式
*/
@Data
@Builder
@AllArgsConstructor
@NoArgsConstructor
@ApiModel("打卡方式")
public class AttClockMethod implements Serializable{
private static final long serialVersionUID = 1495564336178422116L;
private String name;// 打卡名称
private String mac;// wifi【wifi】
private Integer attrange;// 范围【地址】
private Integer type;// 类型(1:考勤机;2:地址;3:WIFI)
private double longitude;// 经度【地址】
private double latitude;// 纬度【地址】
}
package cn.timer.api.dto.kqmk;
import java.io.Serializable;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
/**
* @author lalqq 晚走晚到
*/
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
public class AttLateLate implements Serializable{
private static final long serialVersionUID = 5733260865781069938L;
private String latewalk;// 晚走
private String arrivelate;// 晚到
}
package cn.timer.api.dto.kqmk;
import java.io.Serializable;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
/**
* @author lalqq 考勤班次
*/
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
public class AttSchedule implements Serializable{
private static final long serialVersionUID = 2301555360668389960L;
private Integer id;
private Integer sort;// 1:上班;2:下班; 3:上班;4:下班;5:上班;6:下班
private Long time;
private Long starttime;
private Long endtime;
}
package cn.timer.api.dto.kqmk;
import java.io.Serializable;
import java.util.List;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
public class AttendanceCardListDto implements Serializable {
private static final long serialVersionUID = -5736914818628419342L;
private List<AttSchedule> attsch;// 考勤班次
private boolean attmachine;// 考勤机
private boolean attaddress;// 考勤地址
private boolean attwifi;// 考勤WIFI
private List<AttClockMethod> machine;// 详细打卡方式
private List<PunchRecord> attpr;// 打卡记录
private boolean optscheduling;// 未排班时,员工可选择班次打卡
private boolean fieldpersonnel;// 外勤 true:开 false:关
private Long stapclotime;// 自由排班开始时间
private double canpunchworkdate;// 上班打卡后多久大下班卡
private boolean noclockout;// 下班不用打卡
private Integer allowlate;// 允许迟到分钟数
private Integer seriouslate;// 严重迟到分钟数
private Integer absenteeismlate;// 旷工迟到分钟数
private boolean islatelate;// 晚走晚到
private List<AttLateLate> attlat;// 晚走晚到时间
private String latetime;// 前一天晚走小时****
private List<SystemShift> ssfh;// 无排班时获取的系统班次
private Integer attgrouptype;// 1:固定排班;2:自由排班;3:自由工时
}
package cn.timer.api.dto.kqmk;
import java.io.Serializable;
import java.util.ArrayList;
import java.util.List;
import cn.timer.api.bean.kqgl.AttGroupBinPunchMode;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
public class AttendanceGroupDto implements Serializable{
private static final long serialVersionUID = -5573272776427338217L;
private Integer id;
private String name;// 名称
private String kqbz;// 考勤备注
private Integer pbfs;// 排班方式 1:固定排班;2:自由排班;3:自由工时
private Integer qyid;// 企业id
private Integer isFdjjr;// 是否开启法定节假日休息
private String kqkssjTime;// 考勤开始时间【自由工时专用】
private String zsgzsc;// 至少工作时长【自由工时专用】
private String zcgzsc;// 正常工作时长【自由工时专用】
private String jbzdsc;// 加班最大时长【自由工时专用】
private Integer isDqtx;// 是否开启到期提醒 [排班制专用]0:否;1:是
private String txry;// 提醒人员 [排班制专用]
private Integer txfs;// 提醒天数提醒 [排班制专用]
private Integer txxhts;// 提醒循环天数 [排班制专用]
private String txsjTime;// 提醒时间 [排班制专用]
private String tsfs;// 提示方式 [排班制专用]PC端、APP客户端、短信、邮件 以[“,”]连接 json数组
private Integer isWpbsdk;// 是否开启未排班时打卡 [排班制专用]0:否;1:是;未排班时,员工可以选择班次打卡
private String sybc;// 使用班次【排班制使用】
private Integer isXzbcdk;// 是否开启未排班时,员工可选择班次打卡
private Integer kqznum;// 考勤组人员数
private String pbfsnm;// 排班方式
private String dkfs;// 打卡方式
private Integer isWq;//外勤
private Integer kqjid;
private List<AttGroupBinPunchMode> kqzdkfslist = new ArrayList<AttGroupBinPunchMode>();
}
\ No newline at end of file
package cn.timer.api.dto.kqmk;
import cn.timer.api.utils.Page;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
public class AttqueryCriteriaDto extends Page {
private Integer orgCode;
private Integer empNum;
@ApiModelProperty(value = "关键字", example = "")
private String query;
}
package cn.timer.api.dto.kqmk;
import java.io.Serializable;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
/**
* @author lalqq APP 打卡数据
*/
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
public class ClockCollectData implements Serializable {
private static final long serialVersionUID = -7658009549305902379L;
@ApiModelProperty(value = "用户id", example = "字段说明")
private Integer userid;
@ApiModelProperty(value = "打卡类型", example = "1:上班1 2:下班1 3:上班2 4:下班2 5:上班3 6:下班3......")
private Integer type;
@ApiModelProperty(value = "打卡时间", example = "字段说明")
private String punchtime;
@ApiModelProperty(value = "应打卡时间 \"\"", example = "字段说明")
private String punchcardtime;
@ApiModelProperty(value = "打卡类型", example = "1:GPS,2:WIFI,3:考勤机,4:外勤")
private Integer punchcardtype;
@ApiModelProperty(value = "纬度", example = "字段说明")
private String lat;
@ApiModelProperty(value = "经度", example = "字段说明")
private String lon;
@ApiModelProperty(value = "地址", example = "字段说明")
private String address;
@ApiModelProperty(value = "WIFI mac地址", example = "字段说明")
private String mac;
@ApiModelProperty(value = "WIFI名称", example = "字段说明")
private String macname;
@ApiModelProperty(value = "班次id", example = "无排班时 为“0”")
private Integer shifid;
@ApiModelProperty(value = "打卡状态", example = "状态,1:正常 2:异常 3:补卡 4:请假")
private Integer status;
@ApiModelProperty(value = "手机唯一ID", example = "字段说明")
private String registrationid;
@ApiModelProperty(value = "打卡类型", example = "1:打卡 2:更新打卡")
private Integer differ;
}
package cn.timer.api.dto.kqmk;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
public class CompensateDto {
@ApiModelProperty(value = "加班补偿记录id", example = "1", required = true)
private Integer id;
@ApiModelProperty(value = "加班补偿名称", example = "加班费、调休")
private String value;
}
package cn.timer.api.dto.kqmk;
import java.util.List;
import cn.timer.api.bean.kqmk.KqglAssOvertimeVice;
import cn.timer.api.bean.kqmk.KqglAssoOvertimeRules;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
public class IndividualOvertimeRuleDto {
@ApiModelProperty(value = "加班规则数据 ", example = "字段说明")
KqglAssoOvertimeRulesDto rules;
@ApiModelProperty(value = "加班规则-扣除休息时间 ", example = "字段说明")
List<KqglAssOvertimeVice> starttime;
}
package cn.timer.api.dto.kqmk;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
/**
* @author LAL 2020-05-08
*/
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
public class KqglAssoLeaveRulesDto {
@ApiModelProperty(value = "假期规则编号 假期规则编号", example = "101")
private Integer id;
@ApiModelProperty(value = "假期名称 ", example = "假期名称")
private String name;
@ApiModelProperty(value = "请假单位 ", example = "1:按天请假;2:按半天;3:按小时")
private Integer company;
@ApiModelProperty(value = "假期类型 ", example = "1:系统项;2:自定义项")
private Integer leaveType;
@ApiModelProperty(value = "适用范围 ", example = "0:全公司 -1:考勤组id")
private String apply;
@ApiModelProperty(value = "创建时间 创建时间", example = "101")
private Long createTime;
@ApiModelProperty(value = "创建人员id 创建人员id", example = "101")
private Integer createUserid;
@ApiModelProperty(value = "企业组织代码 企业组织代码", example = "101")
private Integer orgCode;
@ApiModelProperty(value = "是否开启 0:否;1:是", example = "1")
private Integer isOpen;
@ApiModelProperty(value = "假期余额 0:关(该项余额为“不限余额”);1:开(该项余额为“0”)", example = "101")
private Integer leaveBalance;
@ApiModelProperty(value = "适用范围集合", example = "101")
private String[] range;
}
\ No newline at end of file
package cn.timer.api.dto.kqmk;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
public class KqglAssoOvertimeRulesDto {
@ApiModelProperty(value = "加班规则编号 加班规则编号", example = "1")
private Integer id;
@ApiModelProperty(value = "规则名称 ", example = "以审批时间计算加班")
private String name;
@ApiModelProperty(value = "应用范围", example = "1")
private String appliedScope;
@ApiModelProperty(value = "工作日是否允许加班 0:否;1:是", example = "1")
private Integer isWorkovertime;
@ApiModelProperty(value = "计算方式 1:按审批时长计算", example = "1")
private Integer workMode;
@ApiModelProperty(value = "扣除休息时间开关 0:关;1:开", example = "0")
private Integer workBuckleRest;
@ApiModelProperty(value = "计为调休或加班费开关 0:关;1:开", example = "0")
private Integer workSwitch;
@ApiModelProperty(value = "1:按n计为调休 ", example = "1")
private String workOne;
@ApiModelProperty(value = "2:计为加班费 0:未选择;1:已选择", example = "0")
private Integer workTwo;
@ApiModelProperty(value = "3:多种选择 ", example = "1")
private String workThree;
@ApiModelProperty(value = "休息日是否允许加班 0:否;1:是", example = "0")
private Integer isRestovertime;
@ApiModelProperty(value = "计算方式 1:按审批时长计算", example = "1")
private Integer restMode;
@ApiModelProperty(value = "扣除休息时间开关 0:关;1:开", example = "0")
private Integer restBuckleRest;
@ApiModelProperty(value = "计为调休或加班费开关 0:关;1:开", example = "0")
private Integer restSwitch;
@ApiModelProperty(value = "1:按n计为调休 ", example = "1")
private String restOne;
@ApiModelProperty(value = "2:计为加班费 0:未选择;1:已选择", example = "0")
private Integer restTwo;
@ApiModelProperty(value = "3:多种选择 ", example = "1")
private String restThree;
@ApiModelProperty(value = "节假日是否允许加班 0:否;1:是", example = "0")
private Integer isHolidays;
@ApiModelProperty(value = "计算方式 ", example = "1")
private Double holidaysMode;
@ApiModelProperty(value = "扣除休息时间开关 0:关;1:开", example = "0")
private Integer holidaysBuckleRest;
@ApiModelProperty(value = "计为调休或加班费开关 0:关;1:开", example = "0")
private Integer holidaysSwitch;
@ApiModelProperty(value = "1:按n计为调休 ", example = "1")
private String holidaysOne;
@ApiModelProperty(value = "2:计为加班费 0:未选择;1:已选择", example = "0")
private Integer holidaysTwo;
@ApiModelProperty(value = "3:多种选择 ", example = "1")
private String holidaysThree;
@ApiModelProperty(value = "创建时间 ", example = "创建时间")
private Long createTime;
@ApiModelProperty(value = "创建人员 创建人员", example = "101")
private Integer createUserid;
@ApiModelProperty(value = "企业组织代码 企业组织代码", example = "117")
private Integer orgCode;
@ApiModelProperty(value = "扣除休息时间段", example = "12:00-13:30")
private StartTimeRestDto[] starttime;
@ApiModelProperty(value = "应用范围", example = "[]")
private String[] applyrange;
}
\ No newline at end of file
package cn.timer.api.dto.kqmk;
import java.util.Date;
import java.util.List;
import org.springframework.format.annotation.DateTimeFormat;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
public class KqglAssoPbmxDto {
@ApiModelProperty(value = "id id", example = "101")
private Integer id;
@ApiModelProperty(value = "用户id 用户id", example = "101")
private Integer userid;
@ApiModelProperty(value = "日期 ", example = "日期")
@DateTimeFormat(pattern = "yyyy-MM-dd")
@JsonFormat(pattern = "yyyy-MM-dd")
private Date data;
@ApiModelProperty(value = "班次id 班次id", example = "101")
private Integer bcid;
@ApiModelProperty(value = "考勤组id 考勤组id", example = "101")
private Integer kqzid;
private String username;
private String bcname;
private String yemo;
private String xsrq;
private String sbdk1;
private String sbqjks1;
private String sbqjjs1;
private String xbdk1;
private String xbqjks1;
private String xbqjjs1;
private String sbdk2;
private String sbqjks2;
private String sbqjjs2;
private String xbdk2;
private String xbqjks2;
private String xbqjjs2;
private String sbdk3;
private String sbqjks3;
private String sbqjjs3;
private String xbdk3;
private String xbqjks3;
private String xbqjjs3;
private Integer isxbdk;
private Integer sxbcs;
private List<PunchRecord> attpr;// 打卡记录
}
package cn.timer.api.dto.kqmk;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
public class KqglAssoZhoupaibanDto {
@ApiModelProperty(value = "id id", example = "101")
private Integer id;
@ApiModelProperty(value = "考勤组id 考勤组id", example = "101")
private Integer kqzid;
@ApiModelProperty(value = "类型(1:周一、2:周二、3:周三。。。。、8:周一到周日统一班次、9:排班制) 类型(1:周一、2:周二、3:周三。。。。、8:周一到周日统一班次、9:排班制)", example = "101")
private Integer type;
@ApiModelProperty(value = "班次id(0:自由工时 班次id【大于0为:固定排班和排班制】)", example = "101")
private Integer bcid;
private String bcname;
private String sbdk1;
private String xbdk1;
private String sbdk2;
private String xbdk2;
private String sbdk3;
private String xbdk3;
private String weektime;
private String wekmc;
}
package cn.timer.api.dto.kqmk;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
/**
* @author LAL 2020-05-09
*/
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
public class KqglMainKqzDto {
@ApiModelProperty(value = "id id", example = "101")
private Integer id;
@ApiModelProperty(value = "名称 ", example = "名称")
private String name;
@ApiModelProperty(value = "考勤备注 ", example = "考勤备注")
private String kqbz;
@ApiModelProperty(value = "排班方式(1:固定排班;2:自由排班;3:自由工时) 排班方式(1:固定排班;2:自由排班;3:自由工时)", example = "101")
private Integer pbfs;
@ApiModelProperty(value = "企业id 企业id", example = "101")
private Integer qyid;
@ApiModelProperty(value = "是否开启法定节假日休息 是否开启法定节假日休息", example = "101")
private Integer isFdjjr;
@ApiModelProperty(value = "考勤开始时间(自由工时专用) ", example = "考勤开始时间(自由工时专用)")
private String kqkssjTime;
@ApiModelProperty(value = "至少工作时长(自由工时专用--【已去掉】) ", example = "至少工作时长(自由工时专用--【已去掉】)")
private String zsgzsc;
@ApiModelProperty(value = "正常工作时长(自由工时专用--【已去掉】) ", example = "正常工作时长(自由工时专用--【已去掉】)")
private String zcgzsc;
@ApiModelProperty(value = "上班后多久可打下班卡(自由工时专用) ", example = "上班后多久可打下班卡(自由工时专用)")
private String jbzdsc;
@ApiModelProperty(value = "是否开启到期提醒([排班制专用]0:否;1:是) 是否开启到期提醒([排班制专用]0:否;1:是)", example = "101")
private Integer isDqtx;
@ApiModelProperty(value = "提醒人员([排班制专用]员工id以[“,”]连接 ", example = "json数组)")
private String txry;
@ApiModelProperty(value = "提醒方式([排班制专用]提前15天、7天、3天、1天) 提醒方式([排班制专用]提前15天、7天、3天、1天)", example = "101")
private Integer txfs;
@ApiModelProperty(value = "提醒循环天数([排班制专用]) 提醒循环天数([排班制专用])", example = "101")
private Integer txxhts;
@ApiModelProperty(value = "提醒时间([排班制专用]) ", example = "提醒时间([排班制专用])")
private String txsjTime;
@ApiModelProperty(value = "提示方式([排班制专用]PC端、APP客户端、短信、邮件 ", example = "以[“,”]连接 json数组)")
private String tsfs;
@ApiModelProperty(value = "是否开启未排班时打卡([排班制专用]0:否;1:是;未排班时,员工可以选择班次打卡) 是否开启未排班时打卡([排班制专用]0:否;1:是;未排班时,员工可以选择班次打卡)", example = "101")
private Integer isWpbsdk;
@ApiModelProperty(value = "使用班次【排班制使用】 ", example = "使用班次【排班制使用】")
private String sybc;
@ApiModelProperty(value = "是否开启未排班时,员工可选择班次打卡 是否开启未排班时,员工可选择班次打卡", example = "101")
private Integer isXzbcdk;
@ApiModelProperty(value = "外勤 外勤", example = "101")
private Integer isWq;
@ApiModelProperty(value = "考勤组人员数", example = "100")
private Integer kqznum;
@ApiModelProperty(value = "排班方式", example = "1")
private String pbfsnm;
@ApiModelProperty(value = "打卡方式", example = "2")
private String dkfs;
@ApiModelProperty(value = "考勤机id", example = "3")
private Integer kqjid;
}
\ No newline at end of file
package cn.timer.api.dto.kqmk;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
public class LeaveTypeDto {
@ApiModelProperty(value = "假期记录id", example = "1", required = true)
private Integer id;
@ApiModelProperty(value = "假期名称", example = "事假、调休...")
private String value;
}
package cn.timer.api.dto.kqmk;
import java.io.Serializable;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
public class MachinememberDto implements Serializable {
/**
*
*/
private static final long serialVersionUID = 6595051268318648078L;
@ApiModelProperty(value = "部门 ", example = "字段说明")
private String dept;
@ApiModelProperty(value = "岗位 ", example = "字段说明")
private String post;
@ApiModelProperty(value = "姓名", example = "字段说明")
private String name;
@ApiModelProperty(value = "id", example = "字段说明")
private Integer id;
@ApiModelProperty(value = "员工ID", example = "字段说明")
private Integer userId;
@ApiModelProperty(value = "考勤机ID", example = "字段说明")
private Integer kqjid;
@ApiModelProperty(value = "类型(类型 1:考勤机) ", example = "字段说明")
private Integer type;
@ApiModelProperty(value = "是否为管理员--0:否;1:是 ", example = "字段说明")
private String isgly;
}
package cn.timer.api.dto.kqmk;
import java.io.Serializable;
import java.text.SimpleDateFormat;
import lombok.AllArgsConstructor;
import lombok.NoArgsConstructor;
/**
* @author lalqq 打卡记录
*/
@AllArgsConstructor
@NoArgsConstructor
public class PunchRecord implements Serializable {
private static final long serialVersionUID = -1674107232385310352L;
private Integer id;
private Long dktime;// 打卡时间
private String Strdktime = "";//
private Double lon;// 经度
private Double lat;// 纬度
private String address;// 定位地址
private Integer results;// 打卡结果
private Integer userId;// 用户id
private Integer type;// 类型(类型 0:无排班打卡 1:上班 2:下班)
private Integer status;// 状态(0:打卡无效:此记录已被更新 1:正常 2:异常 3:迟到 4:早退 5:补卡 6:请假 7:加班 8:请假迟到 9:请假早退 10:调休)',
private Integer sort;// 序号
private Integer cardType;// 打卡类型(1:GPS,2:WIFI,3:考勤机)
private String mac;// mac地址
private String macname;// WIFI名称
private Integer qyid;// 企业id
private String attdate;// 考勤日期
private Long attime;// 考勤时间
private String Strattime = "";//
private Integer dkmxid;// 打卡明细id
private Integer bcid;// 班次id
private String remarks;// 考勤备注
private Integer punchmode;// 考勤机打卡方式==>1:指紋;2:人脸;3:密码;4:ID卡
private String punchequipment;// 打卡设备
private String username = "";
private String dept = "";
private String post = "";
SimpleDateFormat format = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
public Integer getId() {
return id;
}
public void setId(Integer id) {
this.id = id;
}
public Long getDktime() {
return dktime;
}
@SuppressWarnings("unlikely-arg-type")
public void setDktime(Long dktime) {
this.dktime = dktime;
if (dktime != null && !dktime.equals("")) {
this.Strdktime = format.format(dktime);
}
}
public String getStrdktime() {
return Strdktime;
}
public void setStrdktime(String strdktime) {
Strdktime = strdktime;
}
public Double getLon() {
return lon;
}
public void setLon(Double lon) {
this.lon = lon;
}
public Double getLat() {
return lat;
}
public void setLat(Double lat) {
this.lat = lat;
}
public String getAddress() {
return address;
}
public void setAddress(String address) {
this.address = address == null ? "" : address.trim();
}
public Integer getResults() {
return results;
}
public void setResults(Integer results) {
this.results = results;
}
public Integer getUserId() {
return userId;
}
public void setUserId(Integer userId) {
this.userId = userId;
}
public Integer getType() {
return type;
}
public void setType(Integer type) {
this.type = type;
}
public Integer getStatus() {
return status;
}
public void setStatus(Integer status) {
this.status = status;
}
public Integer getSort() {
return sort;
}
public void setSort(Integer sort) {
this.sort = sort;
}
public Integer getCardType() {
return cardType;
}
public void setCardType(Integer cardType) {
this.cardType = cardType;
}
public String getMacname() {
return macname;
}
public void setMacname(String macname) {
this.macname = macname == null ? "" : macname.trim();
}
public String getMac() {
return mac;
}
public void setMac(String mac) {
this.mac = mac == null ? "" : mac.trim();
}
public Integer getQyid() {
return qyid;
}
public void setQyid(Integer qyid) {
this.qyid = qyid;
}
public String getAttdate() {
return attdate;
}
public void setAttdate(String attdate) {
this.attdate = attdate == null ? "" : attdate.trim();
}
public Long getAttime() {
return attime;
}
@SuppressWarnings("unlikely-arg-type")
public void setAttime(Long attime) {
this.attime = attime;
if (attime != null && !attime.equals("")) {
this.Strattime = format.format(attime);
}
}
public String getStrattime() {
return Strattime;
}
public void setStrattime(String strattime) {
Strattime = strattime;
}
public Integer getDkmxid() {
return dkmxid;
}
public void setDkmxid(Integer dkmxid) {
this.dkmxid = dkmxid;
}
public String getUsername() {
return username;
}
public void setUsername(String username) {
this.username = username;
}
public Integer getBcid() {
return bcid;
}
public void setBcid(Integer bcid) {
this.bcid = bcid;
}
public String getRemarks() {
return remarks;
}
public void setRemarks(String remarks) {
this.remarks = remarks;
}
public Integer getPunchmode() {
return punchmode;
}
public void setPunchmode(Integer punchmode) {
this.punchmode = punchmode;
}
public String getPunchequipment() {
return punchequipment;
}
public void setPunchequipment(String punchequipment) {
this.punchequipment = punchequipment;
}
public String getDept() {
return dept;
}
public void setDept(String dept) {
this.dept = dept;
}
public String getPost() {
return post;
}
public void setPost(String post) {
this.post = post;
}
}
\ No newline at end of file
package cn.timer.api.dto.kqmk;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
public class StartTimeRestDto {
@ApiModelProperty(value = "休息开始时间 ", example = "字段说明")
String starttime;
@ApiModelProperty(value = "休息结束时间 ", example = "字段说明")
String endtime;
@ApiModelProperty(value = "类型 1:工作日;2:休息日;3:节假日 ", example = "字段说明")
Integer overtype;
}
package cn.timer.api.dto.kqmk;
import java.io.Serializable;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
/**
* @author lalqq 无排班时 返回班次
*/
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
public class SystemShift implements Serializable{
private static final long serialVersionUID = -1558779986672010849L;
private Integer id;
private String context;
}
package cn.timer.api.dto.kqmk;
import java.util.List;
import cn.timer.api.bean.kqmk.KqglAssoLeaveRules;
import cn.timer.api.bean.kqmk.KqglAssoRulesVice;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
public class VacationInformationDto {
@ApiModelProperty(value = "假期规则数据 ", example = "字段说明")
KqglAssoLeaveRules rules;
@ApiModelProperty(value = "假期规则-适用范围 ", example = "字段说明")
List<KqglAssoRulesVice> range;
}
...@@ -2,6 +2,7 @@ package cn.timer.api.dto.spmk; ...@@ -2,6 +2,7 @@ package cn.timer.api.dto.spmk;
import javax.validation.constraints.NotNull; import javax.validation.constraints.NotNull;
import cn.timer.api.config.exception.ValidationMsg;
import io.swagger.annotations.ApiModelProperty; import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor; import lombok.AllArgsConstructor;
import lombok.Builder; import lombok.Builder;
...@@ -14,22 +15,22 @@ import lombok.NoArgsConstructor; ...@@ -14,22 +15,22 @@ import lombok.NoArgsConstructor;
@AllArgsConstructor @AllArgsConstructor
public class ApprovingDto { public class ApprovingDto {
@NotNull(message = "asId为空") @NotNull(message = ValidationMsg.NOTNULL)
@ApiModelProperty(value = "审批汇总id", example = "2", required = true) @ApiModelProperty(value = "审批汇总id", example = "2", required = true)
private Integer asId; private Integer asId;
@NotNull(message = "executeRecordId为空") @NotNull(message = ValidationMsg.NOTNULL)
@ApiModelProperty(value = "审批执行记录id", example = "10", required = true) @ApiModelProperty(value = "审批执行记录id", example = "10", required = true)
private Integer executeRecordId; private Integer executeRecordId;
@NotNull(message = "executorId为空") @NotNull(message = ValidationMsg.NOTNULL)
@ApiModelProperty(value = "执行人记录id", example = "10", required = true) @ApiModelProperty(value = "执行人记录id", example = "10", required = true)
private Integer executorId; private Integer executorId;
@ApiModelProperty(value = "意见", example = "同意、拒绝") @ApiModelProperty(value = "意见", example = "同意、拒绝")
private String opinion; private String opinion;
@NotNull(message = "sts为空") @NotNull(message = ValidationMsg.NOTNULL)
@ApiModelProperty(value = "状态 2同意 3拒绝 4转派", example = "2", required = true) @ApiModelProperty(value = "状态 2同意 3拒绝 4转派", example = "2", required = true)
private Integer sts; private Integer sts;
......
...@@ -2,9 +2,11 @@ package cn.timer.api.dto.spmk; ...@@ -2,9 +2,11 @@ package cn.timer.api.dto.spmk;
import javax.validation.constraints.DecimalMax; import javax.validation.constraints.DecimalMax;
import javax.validation.constraints.DecimalMin; import javax.validation.constraints.DecimalMin;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull; import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size; import javax.validation.constraints.Size;
import cn.timer.api.config.exception.ValidationMsg;
import cn.timer.api.utils.Page; import cn.timer.api.utils.Page;
import io.swagger.annotations.ApiModelProperty; import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor; import lombok.AllArgsConstructor;
...@@ -34,9 +36,9 @@ public class MySummaryQueryDto extends Page{ ...@@ -34,9 +36,9 @@ public class MySummaryQueryDto extends Page{
@ApiModelProperty(value = "结束时间 ", example = "2020-10-10 10:10:10") @ApiModelProperty(value = "结束时间 ", example = "2020-10-10 10:10:10")
private String endTime; private String endTime;
@NotNull(message = "type为空") @NotNull(message = ValidationMsg.NOTNULL)
@DecimalMax(value = "2",message = "type 只能为 0我发起的 1抄送我的 2我审批的") @DecimalMax(value = "2",message = ValidationMsg.DECIMALMAX+" 只能为 0我发起的 1抄送我的 2我审批的")
@DecimalMin(value = "0",message = "type 只能为 0我发起的 1抄送我的 2我审批的") @DecimalMin(value = "0",message = ValidationMsg.DECIMALMIN+" 只能为 0我发起的 1抄送我的 2我审批的")
@ApiModelProperty(value = "0我发起的 1抄送我的 2我审批的", example = "0") @ApiModelProperty(value = "0我发起的 1抄送我的 2我审批的", example = "0")
private Integer type; private Integer type;
......
...@@ -11,6 +11,7 @@ import javax.validation.constraints.NotEmpty; ...@@ -11,6 +11,7 @@ import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull; import javax.validation.constraints.NotNull;
import cn.hutool.json.JSONObject; import cn.hutool.json.JSONObject;
import cn.timer.api.config.exception.ValidationMsg;
import io.swagger.annotations.ApiModelProperty; import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor; import lombok.AllArgsConstructor;
import lombok.Builder; import lombok.Builder;
...@@ -26,15 +27,15 @@ public class SpmkApprovalTemplateDto { ...@@ -26,15 +27,15 @@ public class SpmkApprovalTemplateDto {
@ApiModelProperty(value = "编号 编号", example = "101") @ApiModelProperty(value = "编号 编号", example = "101")
private Integer id; private Integer id;
@NotNull(message = "approvalTemplateGId为空") @NotNull(message = ValidationMsg.NOTNULL)
@ApiModelProperty(value = "审批模板组id 当前用户ID", example = "101") @ApiModelProperty(value = "审批模板组id 当前用户ID", example = "101")
private Integer approvalTemplateGId; private Integer approvalTemplateGId;
@NotBlank(message = "iconUrl为空") @NotBlank(message = ValidationMsg.NOTBLANK)
@ApiModelProperty(value = "审批图标地址 ", example = "审批图标地址") @ApiModelProperty(value = "审批图标地址 ", example = "审批图标地址")
private String iconUrl; private String iconUrl;
@NotBlank(message = "name为空") @NotBlank(message = ValidationMsg.NOTBLANK)
@ApiModelProperty(value = "审批名称 ", example = "审批名称") @ApiModelProperty(value = "审批名称 ", example = "审批名称")
private String name; private String name;
...@@ -47,7 +48,7 @@ public class SpmkApprovalTemplateDto { ...@@ -47,7 +48,7 @@ public class SpmkApprovalTemplateDto {
@ApiModelProperty(value = "排序 由于区分关键字,命名后缀加s", example = "101") @ApiModelProperty(value = "排序 由于区分关键字,命名后缀加s", example = "101")
private Integer ranks; private Integer ranks;
@NotBlank(message = "isOpinion为空 是否必填 意见 0是 1否") @NotBlank(message = ValidationMsg.NOTBLANK)
@ApiModelProperty(value = "审批意见 是否必填 意见 0是 1否", example = "101") @ApiModelProperty(value = "审批意见 是否必填 意见 0是 1否", example = "101")
private Integer isOpinion; private Integer isOpinion;
...@@ -57,17 +58,17 @@ public class SpmkApprovalTemplateDto { ...@@ -57,17 +58,17 @@ public class SpmkApprovalTemplateDto {
@ApiModelProperty(value = "创建时间 ", example = "创建时间") @ApiModelProperty(value = "创建时间 ", example = "创建时间")
private Date createTime; private Date createTime;
@NotNull(message = "assoType为空") @NotNull(message = ValidationMsg.NOTNULL)
@DecimalMax(value = "9",message = "assoType 只能为 0无 1转正 2离职 3调岗 4招聘 5加班 6请假 7出差 8外出 9补卡 ") @DecimalMax(value = "9",message = ValidationMsg.DECIMALMAX +" 只能为 0无 1转正 2离职 3调岗 4招聘 5加班 6请假 7出差 8外出 9补卡 ")
@DecimalMin(value = "0",message = "assoType 只能为 0无 1转正 2离职 3调岗 4招聘 5加班 6请假 7出差 8外出 9补卡 ") @DecimalMin(value = "0",message = ValidationMsg.DECIMALMIN +" 只能为 0无 1转正 2离职 3调岗 4招聘 5加班 6请假 7出差 8外出 9补卡 ")
@ApiModelProperty(value = "关联类型 0无 1转正 2离职 3调岗 4加班 5请假 6出差 7外出 8补卡 9调薪", example = "1") @ApiModelProperty(value = "关联类型 0无 1转正 2离职 3调岗 4加班 5请假 6出差 7外出 8补卡 9调薪", example = "1")
private Integer assoType; private Integer assoType;
@NotEmpty(message = "froms为空") @NotEmpty(message = ValidationMsg.NOTEMPTY)
@ApiModelProperty(value = "审批表单 ", example = "审批表单") @ApiModelProperty(value = "审批表单 ", example = "审批表单")
private List<JSONObject> froms; private List<JSONObject> froms;
@NotNull(message = "router为空") @NotNull(message = ValidationMsg.NOTNULL)
@ApiModelProperty(value = "审批流程 ", example = "审批流程") @ApiModelProperty(value = "审批流程 ", example = "审批流程")
private Router router; private Router router;
......
...@@ -8,6 +8,7 @@ import javax.validation.constraints.NotBlank; ...@@ -8,6 +8,7 @@ import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull; import javax.validation.constraints.NotNull;
import cn.hutool.json.JSONObject; import cn.hutool.json.JSONObject;
import cn.timer.api.config.exception.ValidationMsg;
import io.swagger.annotations.ApiModelProperty; import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor; import lombok.AllArgsConstructor;
import lombok.Builder; import lombok.Builder;
...@@ -23,36 +24,36 @@ import lombok.NoArgsConstructor; ...@@ -23,36 +24,36 @@ import lombok.NoArgsConstructor;
@AllArgsConstructor @AllArgsConstructor
public class SpmkApproveSummaryDto{ public class SpmkApproveSummaryDto{
@NotBlank(message = "title为空") @NotBlank(message = ValidationMsg.NOTBLANK)
@ApiModelProperty(value = "标题 ", example = "标题", required = true) @ApiModelProperty(value = "标题 ", example = "标题", required = true)
private String title; private String title;
@NotBlank(message = "approveName为空") @NotBlank(message = ValidationMsg.NOTBLANK)
@ApiModelProperty(value = "审批名称 ", example = "审批名称", required = true) @ApiModelProperty(value = "审批名称 ", example = "审批名称", required = true)
private String approveName; private String approveName;
@ApiModelProperty(value = "摘要", example = "摘要", required = true) @ApiModelProperty(value = "摘要", example = "摘要", required = true)
private String digest; private String digest;
@NotBlank(message = "initiator为空") @NotBlank(message = ValidationMsg.NOTBLANK)
@ApiModelProperty(value = "发起人名称 ", example = "发起人名称", required = true) @ApiModelProperty(value = "发起人名称 ", example = "发起人名称", required = true)
private String initiator; private String initiator;
@NotNull(message = "assoType为空") @NotNull(message = ValidationMsg.NOTNULL)
@DecimalMax(value = "9",message = "assoType 只能为 0无 1转正 2离职 3调岗 4招聘 5加班 6请假 7出差 8外出 9补卡 ") @DecimalMax(value = "9",message = ValidationMsg.DECIMALMAX +" 只能为 0无 1转正 2离职 3调岗 4招聘 5加班 6请假 7出差 8外出 9补卡 ")
@DecimalMin(value = "0",message = "assoType 只能为 0无 1转正 2离职 3调岗 4招聘 5加班 6请假 7出差 8外出 9补卡 ") @DecimalMin(value = "0",message = ValidationMsg.DECIMALMIN +" 只能为 0无 1转正 2离职 3调岗 4招聘 5加班 6请假 7出差 8外出 9补卡 ")
@ApiModelProperty(value = "关联类型 0无 1转正 2离职 3调岗 4招聘 5加班 6请假 7出差 8外出 9补卡", example = "1") @ApiModelProperty(value = "关联类型 0无 1转正 2离职 3调岗 4招聘 5加班 6请假 7出差 8外出 9补卡", example = "1")
private Integer assoType; private Integer assoType;
@NotNull(message = "requestData为空") @NotNull(message = ValidationMsg.NOTNULL)
@ApiModelProperty(value = "申请数据 ", example = "申请数据", required = true) @ApiModelProperty(value = "申请数据 ", example = "申请数据", required = true)
private JSONObject requestData; private JSONObject requestData;
@NotNull(message = "froms为空") @NotNull(message = ValidationMsg.NOTNULL)
@ApiModelProperty(value = "审批表单 ", example = "数组", required = true) @ApiModelProperty(value = "审批表单 ", example = "数组", required = true)
private List<JSONObject> froms; private List<JSONObject> froms;
@NotNull(message = "router为空") @NotNull(message = ValidationMsg.NOTNULL)
@ApiModelProperty(value = "审批流程", example = "审批流程", required = true) @ApiModelProperty(value = "审批流程", example = "审批流程", required = true)
private Router router; private Router router;
......
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="cn.timer.api.dao.kqmk.KqglAssOvertimeViceMapper">
<resultMap id="BaseResultMap" type="cn.timer.api.bean.kqmk.KqglAssOvertimeVice" >
<id column="id" property="id" />
<result column="overtime_rules_id" property="overtimeRulesId" />
<result column="break_start_time" property="breakStartTime" />
<result column="break_end_time" property="breakEndTime" />
<result column="over_type" property="overType" />
</resultMap>
<sql id="Base_Column_List">
id,
overtime_rules_id,
break_start_time,
break_end_time,
over_type
</sql>
<sql id="Base_Column_List_Alias">
id KqglAssOvertimeVice_id,
overtime_rules_id KqglAssOvertimeVice_overtime_rules_id,
break_start_time KqglAssOvertimeVice_break_start_time,
break_end_time KqglAssOvertimeVice_break_end_time,
over_type KqglAssOvertimeVice_over_type
</sql>
<insert id="insertovertimeviceList" parameterType="java.util.List" >
insert into kqgl_ass_overtime_vice (overtime_rules_id, break_start_time, break_end_time,over_type)
<foreach collection="list" item="item" index="index" open="values " close="" separator=",">
(
<if test="item.overtimeRulesId != null" >
#{item.overtimeRulesId,jdbcType=INTEGER},
</if>
<if test="item.breakStartTime != null" >
#{item.breakStartTime,jdbcType=VARCHAR},
</if>
<if test="item.breakEndTime != null" >
#{item.breakEndTime,jdbcType=VARCHAR},
</if>
<if test="item.overType != null" >
#{item.overType,jdbcType=INTEGER}
</if>
)
</foreach>
</insert>
<!--
<insert id="insert" useGeneratedKeys="true" keyColumn="id" parameterType="cn.timer.api.bean.kqmk.KqglAssOvertimeVice">
INSERT INTO kqgl_ass_overtime_vice
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test ='null != overtimeRulesId'>
overtime_rules_id,
</if>
<if test ='null != breakStartTime'>
break_start_time,
</if>
<if test ='null != breakEndTime'>
break_end_time,
</if>
<if test ='null != overType'>
over_type
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test ='null != overtimeRulesId'>
#{overtimeRulesId},
</if>
<if test ='null != breakStartTime'>
#{breakStartTime},
</if>
<if test ='null != breakEndTime'>
#{breakEndTime},
</if>
<if test ='null != overType'>
#{overType}
</if>
</trim>
</insert>
<delete id="delete" >
DELETE FROM kqgl_ass_overtime_vice
WHERE id = #{id}
</delete>
<update id="update" parameterType="cn.timer.api.bean.kqmk.KqglAssOvertimeVice">
UPDATE kqgl_ass_overtime_vice
<set>
<if test ='null != overtimeRulesId'>overtime_rules_id = #{overtimeRulesId},</if>
<if test ='null != breakStartTime'>break_start_time = #{breakStartTime},</if>
<if test ='null != breakEndTime'>break_end_time = #{breakEndTime},</if>
<if test ='null != overType'>over_type = #{overType}</if>
</set>
WHERE id = #{id}
</update>
<select id="load" resultMap="BaseResultMap">
SELECT <include refid="Base_Column_List" />
FROM kqgl_ass_overtime_vice
WHERE id = #{id}
</select>
<select id="pageList" resultMap="BaseResultMap">
SELECT <include refid="Base_Column_List" />
FROM kqgl_ass_overtime_vice
LIMIT #{offset}, #{pageSize}
</select>
<select id="pageListCount" resultType="java.lang.Integer">
SELECT count(1)
FROM kqgl_ass_overtime_vice
</select>
-->
</mapper>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="cn.timer.api.dao.kqmk.KqglAssoDkdzMapper">
<resultMap id="BaseResultMap" type="cn.timer.api.bean.kqmk.KqglAssoDkdz" >
<id column="id" property="id" />
<result column="name" property="name" />
<result column="address" property="address" />
<result column="dkfw" property="dkfw" />
<result column="lon" property="lon" />
<result column="lat" property="lat" />
<result column="qyid" property="qyid" />
<result column="lusj_time" property="lusjTime" />
<result column="luryid" property="luryid" />
</resultMap>
<sql id="Base_Column_List">
id,
name,
address,
dkfw,
lon,
lat,
qyid,
lusj_time,
luryid
</sql>
<sql id="Base_Column_List_Alias">
id KqglAssoDkdz_id,
name KqglAssoDkdz_name,
address KqglAssoDkdz_address,
dkfw KqglAssoDkdz_dkfw,
lon KqglAssoDkdz_lon,
lat KqglAssoDkdz_lat,
qyid KqglAssoDkdz_qyid,
lusj_time KqglAssoDkdz_lusj_time,
luryid KqglAssoDkdz_luryid
</sql>
<!--
<insert id="insert" useGeneratedKeys="true" keyColumn="id" parameterType="cn.timer.api.bean.kqmk.KqglAssoDkdz">
INSERT INTO kqgl_asso_dkdz
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test ='null != name'>
name,
</if>
<if test ='null != address'>
address,
</if>
<if test ='null != dkfw'>
dkfw,
</if>
<if test ='null != lon'>
lon,
</if>
<if test ='null != lat'>
lat,
</if>
<if test ='null != qyid'>
qyid,
</if>
<if test ='null != lusjTime'>
lusj_time,
</if>
<if test ='null != luryid'>
luryid
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test ='null != name'>
#{name},
</if>
<if test ='null != address'>
#{address},
</if>
<if test ='null != dkfw'>
#{dkfw},
</if>
<if test ='null != lon'>
#{lon},
</if>
<if test ='null != lat'>
#{lat},
</if>
<if test ='null != qyid'>
#{qyid},
</if>
<if test ='null != lusjTime'>
#{lusjTime},
</if>
<if test ='null != luryid'>
#{luryid}
</if>
</trim>
</insert>
<delete id="delete" >
DELETE FROM kqgl_asso_dkdz
WHERE id = #{id}
</delete>
<update id="update" parameterType="cn.timer.api.bean.kqmk.KqglAssoDkdz">
UPDATE kqgl_asso_dkdz
<set>
<if test ='null != name'>name = #{name},</if>
<if test ='null != address'>address = #{address},</if>
<if test ='null != dkfw'>dkfw = #{dkfw},</if>
<if test ='null != lon'>lon = #{lon},</if>
<if test ='null != lat'>lat = #{lat},</if>
<if test ='null != qyid'>qyid = #{qyid},</if>
<if test ='null != lusjTime'>lusj_time = #{lusjTime},</if>
<if test ='null != luryid'>luryid = #{luryid}</if>
</set>
WHERE id = #{id}
</update>
<select id="load" resultMap="BaseResultMap">
SELECT <include refid="Base_Column_List" />
FROM kqgl_asso_dkdz
WHERE id = #{id}
</select>
<select id="pageList" resultMap="BaseResultMap">
SELECT <include refid="Base_Column_List" />
FROM kqgl_asso_dkdz
LIMIT #{offset}, #{pageSize}
</select>
<select id="pageListCount" resultType="java.lang.Integer">
SELECT count(1)
FROM kqgl_asso_dkdz
</select>
-->
</mapper>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="cn.timer.api.dao.kqmk.KqglAssoDkmxMapper">
<resultMap id="BaseResultMap" type="cn.timer.api.bean.kqmk.KqglAssoDkmx" >
<id column="id" property="id" />
<result column="userid" property="userid" />
<result column="data" property="data" />
<result column="sbdk1" property="sbdk1" />
<result column="sbdk1jg" property="sbdk1jg" />
<result column="xbdk1" property="xbdk1" />
<result column="xbdk1jg" property="xbdk1jg" />
<result column="sbdk2" property="sbdk2" />
<result column="sbdk2jg" property="sbdk2jg" />
<result column="xbdk2" property="xbdk2" />
<result column="xbdk2jg" property="xbdk2jg" />
<result column="sbdk3" property="sbdk3" />
<result column="sbdk3jg" property="sbdk3jg" />
<result column="xbdk3" property="xbdk3" />
<result column="xbdk3jg" property="xbdk3jg" />
<result column="ydkcs" property="ydkcs" />
<result column="gzsc" property="gzsc" />
<result column="qyid" property="qyid" />
<result column="dksj" property="dksj" />
</resultMap>
<sql id="Base_Column_List">
id,
userid,
data,
sbdk1,
sbdk1jg,
xbdk1,
xbdk1jg,
sbdk2,
sbdk2jg,
xbdk2,
xbdk2jg,
sbdk3,
sbdk3jg,
xbdk3,
xbdk3jg,
ydkcs,
gzsc,
qyid,
dksj
</sql>
<sql id="Base_Column_List_Alias">
id KqglAssoDkmx_id,
userid KqglAssoDkmx_userid,
data KqglAssoDkmx_data,
sbdk1 KqglAssoDkmx_sbdk1,
sbdk1jg KqglAssoDkmx_sbdk1jg,
xbdk1 KqglAssoDkmx_xbdk1,
xbdk1jg KqglAssoDkmx_xbdk1jg,
sbdk2 KqglAssoDkmx_sbdk2,
sbdk2jg KqglAssoDkmx_sbdk2jg,
xbdk2 KqglAssoDkmx_xbdk2,
xbdk2jg KqglAssoDkmx_xbdk2jg,
sbdk3 KqglAssoDkmx_sbdk3,
sbdk3jg KqglAssoDkmx_sbdk3jg,
xbdk3 KqglAssoDkmx_xbdk3,
xbdk3jg KqglAssoDkmx_xbdk3jg,
ydkcs KqglAssoDkmx_ydkcs,
gzsc KqglAssoDkmx_gzsc,
qyid KqglAssoDkmx_qyid,
dksj KqglAssoDkmx_dksj
</sql>
<!--
<insert id="insert" useGeneratedKeys="true" keyColumn="id" parameterType="cn.timer.api.bean.kqmk.KqglAssoDkmx">
INSERT INTO kqgl_asso_dkmx
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test ='null != userid'>
userid,
</if>
<if test ='null != data'>
data,
</if>
<if test ='null != sbdk1'>
sbdk1,
</if>
<if test ='null != sbdk1jg'>
sbdk1jg,
</if>
<if test ='null != xbdk1'>
xbdk1,
</if>
<if test ='null != xbdk1jg'>
xbdk1jg,
</if>
<if test ='null != sbdk2'>
sbdk2,
</if>
<if test ='null != sbdk2jg'>
sbdk2jg,
</if>
<if test ='null != xbdk2'>
xbdk2,
</if>
<if test ='null != xbdk2jg'>
xbdk2jg,
</if>
<if test ='null != sbdk3'>
sbdk3,
</if>
<if test ='null != sbdk3jg'>
sbdk3jg,
</if>
<if test ='null != xbdk3'>
xbdk3,
</if>
<if test ='null != xbdk3jg'>
xbdk3jg,
</if>
<if test ='null != ydkcs'>
ydkcs,
</if>
<if test ='null != gzsc'>
gzsc,
</if>
<if test ='null != qyid'>
qyid,
</if>
<if test ='null != dksj'>
dksj
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test ='null != userid'>
#{userid},
</if>
<if test ='null != data'>
#{data},
</if>
<if test ='null != sbdk1'>
#{sbdk1},
</if>
<if test ='null != sbdk1jg'>
#{sbdk1jg},
</if>
<if test ='null != xbdk1'>
#{xbdk1},
</if>
<if test ='null != xbdk1jg'>
#{xbdk1jg},
</if>
<if test ='null != sbdk2'>
#{sbdk2},
</if>
<if test ='null != sbdk2jg'>
#{sbdk2jg},
</if>
<if test ='null != xbdk2'>
#{xbdk2},
</if>
<if test ='null != xbdk2jg'>
#{xbdk2jg},
</if>
<if test ='null != sbdk3'>
#{sbdk3},
</if>
<if test ='null != sbdk3jg'>
#{sbdk3jg},
</if>
<if test ='null != xbdk3'>
#{xbdk3},
</if>
<if test ='null != xbdk3jg'>
#{xbdk3jg},
</if>
<if test ='null != ydkcs'>
#{ydkcs},
</if>
<if test ='null != gzsc'>
#{gzsc},
</if>
<if test ='null != qyid'>
#{qyid},
</if>
<if test ='null != dksj'>
#{dksj}
</if>
</trim>
</insert>
<delete id="delete" >
DELETE FROM kqgl_asso_dkmx
WHERE id = #{id}
</delete>
<update id="update" parameterType="cn.timer.api.bean.kqmk.KqglAssoDkmx">
UPDATE kqgl_asso_dkmx
<set>
<if test ='null != userid'>userid = #{userid},</if>
<if test ='null != data'>data = #{data},</if>
<if test ='null != sbdk1'>sbdk1 = #{sbdk1},</if>
<if test ='null != sbdk1jg'>sbdk1jg = #{sbdk1jg},</if>
<if test ='null != xbdk1'>xbdk1 = #{xbdk1},</if>
<if test ='null != xbdk1jg'>xbdk1jg = #{xbdk1jg},</if>
<if test ='null != sbdk2'>sbdk2 = #{sbdk2},</if>
<if test ='null != sbdk2jg'>sbdk2jg = #{sbdk2jg},</if>
<if test ='null != xbdk2'>xbdk2 = #{xbdk2},</if>
<if test ='null != xbdk2jg'>xbdk2jg = #{xbdk2jg},</if>
<if test ='null != sbdk3'>sbdk3 = #{sbdk3},</if>
<if test ='null != sbdk3jg'>sbdk3jg = #{sbdk3jg},</if>
<if test ='null != xbdk3'>xbdk3 = #{xbdk3},</if>
<if test ='null != xbdk3jg'>xbdk3jg = #{xbdk3jg},</if>
<if test ='null != ydkcs'>ydkcs = #{ydkcs},</if>
<if test ='null != gzsc'>gzsc = #{gzsc},</if>
<if test ='null != qyid'>qyid = #{qyid},</if>
<if test ='null != dksj'>dksj = #{dksj}</if>
</set>
WHERE id = #{id}
</update>
<select id="load" resultMap="BaseResultMap">
SELECT <include refid="Base_Column_List" />
FROM kqgl_asso_dkmx
WHERE id = #{id}
</select>
<select id="pageList" resultMap="BaseResultMap">
SELECT <include refid="Base_Column_List" />
FROM kqgl_asso_dkmx
LIMIT #{offset}, #{pageSize}
</select>
<select id="pageListCount" resultType="java.lang.Integer">
SELECT count(1)
FROM kqgl_asso_dkmx
</select>
-->
</mapper>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="cn.timer.api.dao.kqmk.KqglAssoDkwxMapper">
<resultMap id="BaseResultMap" type="cn.timer.api.bean.kqmk.KqglAssoDkwx" >
<id column="id" property="id" />
<result column="name" property="name" />
<result column="mac" property="mac" />
<result column="qyid" property="qyid" />
<result column="lusj_time" property="lusjTime" />
<result column="luryid" property="luryid" />
</resultMap>
<sql id="Base_Column_List">
id,
name,
mac,
qyid,
lusj_time,
luryid
</sql>
<sql id="Base_Column_List_Alias">
id KqglAssoDkwx_id,
name KqglAssoDkwx_name,
mac KqglAssoDkwx_mac,
qyid KqglAssoDkwx_qyid,
lusj_time KqglAssoDkwx_lusj_time,
luryid KqglAssoDkwx_luryid
</sql>
<!--
<insert id="insert" useGeneratedKeys="true" keyColumn="id" parameterType="cn.timer.api.bean.kqmk.KqglAssoDkwx">
INSERT INTO kqgl_asso_dkwx
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test ='null != name'>
name,
</if>
<if test ='null != mac'>
mac,
</if>
<if test ='null != qyid'>
qyid,
</if>
<if test ='null != lusjTime'>
lusj_time,
</if>
<if test ='null != luryid'>
luryid
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test ='null != name'>
#{name},
</if>
<if test ='null != mac'>
#{mac},
</if>
<if test ='null != qyid'>
#{qyid},
</if>
<if test ='null != lusjTime'>
#{lusjTime},
</if>
<if test ='null != luryid'>
#{luryid}
</if>
</trim>
</insert>
<delete id="delete" >
DELETE FROM kqgl_asso_dkwx
WHERE id = #{id}
</delete>
<update id="update" parameterType="cn.timer.api.bean.kqmk.KqglAssoDkwx">
UPDATE kqgl_asso_dkwx
<set>
<if test ='null != name'>name = #{name},</if>
<if test ='null != mac'>mac = #{mac},</if>
<if test ='null != qyid'>qyid = #{qyid},</if>
<if test ='null != lusjTime'>lusj_time = #{lusjTime},</if>
<if test ='null != luryid'>luryid = #{luryid}</if>
</set>
WHERE id = #{id}
</update>
<select id="load" resultMap="BaseResultMap">
SELECT <include refid="Base_Column_List" />
FROM kqgl_asso_dkwx
WHERE id = #{id}
</select>
<select id="pageList" resultMap="BaseResultMap">
SELECT <include refid="Base_Column_List" />
FROM kqgl_asso_dkwx
LIMIT #{offset}, #{pageSize}
</select>
<select id="pageListCount" resultType="java.lang.Integer">
SELECT count(1)
FROM kqgl_asso_dkwx
</select>
-->
</mapper>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="cn.timer.api.dao.kqmk.KqglAssoKqjMapper">
<resultMap id="BaseResultMap" type="cn.timer.api.bean.kqmk.KqglAssoKqj" >
<id column="id" property="id" />
<result column="name" property="name" />
<result column="code" property="code" />
<result column="qyid" property="qyid" />
<result column="lusj_time" property="lusjTime" />
<result column="luryid" property="luryid" />
<result column="type" property="type" />
</resultMap>
<sql id="Base_Column_List">
id,
name,
code,
qyid,
lusj_time,
luryid,
type
</sql>
<sql id="Base_Column_List_Alias">
id KqglAssoKqj_id,
name KqglAssoKqj_name,
code KqglAssoKqj_code,
qyid KqglAssoKqj_qyid,
lusj_time KqglAssoKqj_lusj_time,
luryid KqglAssoKqj_luryid,
type KqglAssoKqj_type
</sql>
<!--
<insert id="insert" useGeneratedKeys="true" keyColumn="id" parameterType="cn.timer.api.bean.kqmk.KqglAssoKqj">
INSERT INTO kqgl_asso_kqj
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test ='null != name'>
name,
</if>
<if test ='null != code'>
code,
</if>
<if test ='null != qyid'>
qyid,
</if>
<if test ='null != lusjTime'>
lusj_time,
</if>
<if test ='null != luryid'>
luryid,
</if>
<if test ='null != type'>
type
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test ='null != name'>
#{name},
</if>
<if test ='null != code'>
#{code},
</if>
<if test ='null != qyid'>
#{qyid},
</if>
<if test ='null != lusjTime'>
#{lusjTime},
</if>
<if test ='null != luryid'>
#{luryid},
</if>
<if test ='null != type'>
#{type}
</if>
</trim>
</insert>
<delete id="delete" >
DELETE FROM kqgl_asso_kqj
WHERE id = #{id}
</delete>
<update id="update" parameterType="cn.timer.api.bean.kqmk.KqglAssoKqj">
UPDATE kqgl_asso_kqj
<set>
<if test ='null != name'>name = #{name},</if>
<if test ='null != code'>code = #{code},</if>
<if test ='null != qyid'>qyid = #{qyid},</if>
<if test ='null != lusjTime'>lusj_time = #{lusjTime},</if>
<if test ='null != luryid'>luryid = #{luryid},</if>
<if test ='null != type'>type = #{type}</if>
</set>
WHERE id = #{id}
</update>
<select id="load" resultMap="BaseResultMap">
SELECT <include refid="Base_Column_List" />
FROM kqgl_asso_kqj
WHERE id = #{id}
</select>
<select id="pageList" resultMap="BaseResultMap">
SELECT <include refid="Base_Column_List" />
FROM kqgl_asso_kqj
LIMIT #{offset}, #{pageSize}
</select>
<select id="pageListCount" resultType="java.lang.Integer">
SELECT count(1)
FROM kqgl_asso_kqj
</select>
-->
</mapper>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="cn.timer.api.dao.kqmk.KqglAssoKqzdkfsMapper">
<resultMap id="BaseResultMap" type="cn.timer.api.bean.kqmk.KqglAssoKqzdkfs" >
<id column="id" property="id" />
<result column="dkfsid" property="dkfsid" />
<result column="kqz_id" property="kqzId" />
<result column="type" property="type" />
<result column="qyid" property="qyid" />
<result column="state" property="state" />
</resultMap>
<sql id="Base_Column_List">
id,
dkfsid,
kqz_id,
type,
qyid,
state
</sql>
<sql id="Base_Column_List_Alias">
id KqglAssoKqzdkfs_id,
dkfsid KqglAssoKqzdkfs_dkfsid,
kqz_id KqglAssoKqzdkfs_kqz_id,
type KqglAssoKqzdkfs_type,
qyid KqglAssoKqzdkfs_qyid,
state KqglAssoKqzdkfs_state
</sql>
<!--
<insert id="insert" useGeneratedKeys="true" keyColumn="id" parameterType="cn.timer.api.bean.kqmk.KqglAssoKqzdkfs">
INSERT INTO kqgl_asso_kqzdkfs
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test ='null != dkfsid'>
dkfsid,
</if>
<if test ='null != kqzId'>
kqz_id,
</if>
<if test ='null != type'>
type,
</if>
<if test ='null != qyid'>
qyid,
</if>
<if test ='null != state'>
state
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test ='null != dkfsid'>
#{dkfsid},
</if>
<if test ='null != kqzId'>
#{kqzId},
</if>
<if test ='null != type'>
#{type},
</if>
<if test ='null != qyid'>
#{qyid},
</if>
<if test ='null != state'>
#{state}
</if>
</trim>
</insert>
<delete id="delete" >
DELETE FROM kqgl_asso_kqzdkfs
WHERE id = #{id}
</delete>
<update id="update" parameterType="cn.timer.api.bean.kqmk.KqglAssoKqzdkfs">
UPDATE kqgl_asso_kqzdkfs
<set>
<if test ='null != dkfsid'>dkfsid = #{dkfsid},</if>
<if test ='null != kqzId'>kqz_id = #{kqzId},</if>
<if test ='null != type'>type = #{type},</if>
<if test ='null != qyid'>qyid = #{qyid},</if>
<if test ='null != state'>state = #{state}</if>
</set>
WHERE id = #{id}
</update>
<select id="load" resultMap="BaseResultMap">
SELECT <include refid="Base_Column_List" />
FROM kqgl_asso_kqzdkfs
WHERE id = #{id}
</select>
<select id="pageList" resultMap="BaseResultMap">
SELECT <include refid="Base_Column_List" />
FROM kqgl_asso_kqzdkfs
LIMIT #{offset}, #{pageSize}
</select>
<select id="pageListCount" resultType="java.lang.Integer">
SELECT count(1)
FROM kqgl_asso_kqzdkfs
</select>
-->
</mapper>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="cn.timer.api.dao.kqmk.KqglAssoLeaveBalanceMapper">
<resultMap id="BaseResultMap" type="cn.timer.api.bean.kqmk.KqglAssoLeaveBalance" >
<id column="id" property="id" />
<result column="leave_rules_id" property="leaveRulesId" />
<result column="userid" property="userid" />
<result column="modify_action" property="modifyAction" />
<result column="balance_days" property="balanceDays" />
<result column="reason" property="reason" />
<result column="modify_userid" property="modifyUserid" />
<result column="modify_timer" property="modifyTimer" />
<result column="modify_number" property="modifyNumber" />
<result column="org_code" property="orgCode" />
</resultMap>
<sql id="Base_Column_List">
id,
leave_rules_id,
userid,
modify_action,
balance_days,
reason,
modify_userid,
modify_timer,
modify_number,
org_code
</sql>
<sql id="Base_Column_List_Alias">
id KqglAssoLeaveBalance_id,
leave_rules_id KqglAssoLeaveBalance_leave_rules_id,
userid KqglAssoLeaveBalance_userid,
modify_action KqglAssoLeaveBalance_modify_action,
balance_days KqglAssoLeaveBalance_balance_days,
reason KqglAssoLeaveBalance_reason,
modify_userid KqglAssoLeaveBalance_modify_userid,
modify_timer KqglAssoLeaveBalance_modify_timer,
modify_number KqglAssoLeaveBalance_modify_number,
org_code KqglAssoLeaveBalance_org_code
</sql>
<!--
<insert id="insert" useGeneratedKeys="true" keyColumn="id" parameterType="cn.timer.api.bean.kqmk.KqglAssoLeaveBalance">
INSERT INTO kqgl_asso_leave_balance
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test ='null != leaveRulesId'>
leave_rules_id,
</if>
<if test ='null != userid'>
userid,
</if>
<if test ='null != modifyAction'>
modify_action,
</if>
<if test ='null != balanceDays'>
balance_days,
</if>
<if test ='null != reason'>
reason,
</if>
<if test ='null != modifyUserid'>
modify_userid,
</if>
<if test ='null != modifyTimer'>
modify_timer,
</if>
<if test ='null != modifyNumber'>
modify_number,
</if>
<if test ='null != orgCode'>
org_code
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test ='null != leaveRulesId'>
#{leaveRulesId},
</if>
<if test ='null != userid'>
#{userid},
</if>
<if test ='null != modifyAction'>
#{modifyAction},
</if>
<if test ='null != balanceDays'>
#{balanceDays},
</if>
<if test ='null != reason'>
#{reason},
</if>
<if test ='null != modifyUserid'>
#{modifyUserid},
</if>
<if test ='null != modifyTimer'>
#{modifyTimer},
</if>
<if test ='null != modifyNumber'>
#{modifyNumber},
</if>
<if test ='null != orgCode'>
#{orgCode}
</if>
</trim>
</insert>
<delete id="delete" >
DELETE FROM kqgl_asso_leave_balance
WHERE id = #{id}
</delete>
<update id="update" parameterType="cn.timer.api.bean.kqmk.KqglAssoLeaveBalance">
UPDATE kqgl_asso_leave_balance
<set>
<if test ='null != leaveRulesId'>leave_rules_id = #{leaveRulesId},</if>
<if test ='null != userid'>userid = #{userid},</if>
<if test ='null != modifyAction'>modify_action = #{modifyAction},</if>
<if test ='null != balanceDays'>balance_days = #{balanceDays},</if>
<if test ='null != reason'>reason = #{reason},</if>
<if test ='null != modifyUserid'>modify_userid = #{modifyUserid},</if>
<if test ='null != modifyTimer'>modify_timer = #{modifyTimer},</if>
<if test ='null != modifyNumber'>modify_number = #{modifyNumber},</if>
<if test ='null != orgCode'>org_code = #{orgCode}</if>
</set>
WHERE id = #{id}
</update>
<select id="load" resultMap="BaseResultMap">
SELECT <include refid="Base_Column_List" />
FROM kqgl_asso_leave_balance
WHERE id = #{id}
</select>
<select id="pageList" resultMap="BaseResultMap">
SELECT <include refid="Base_Column_List" />
FROM kqgl_asso_leave_balance
LIMIT #{offset}, #{pageSize}
</select>
<select id="pageListCount" resultType="java.lang.Integer">
SELECT count(1)
FROM kqgl_asso_leave_balance
</select>
-->
</mapper>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="cn.timer.api.dao.kqmk.KqglAssoLeaveRulesMapper">
<resultMap id="BaseResultMap" type="cn.timer.api.bean.kqmk.KqglAssoLeaveRules" >
<id column="id" property="id" />
<result column="name" property="name" />
<result column="company" property="company" />
<result column="leave_type" property="leaveType" />
<result column="apply" property="apply" />
<result column="create_time" property="createTime" />
<result column="create_userid" property="createUserid" />
<result column="org_code" property="orgCode" />
<result column="is_open" property="isOpen" />
<result column="leave_balance" property="leaveBalance" />
</resultMap>
<sql id="Base_Column_List">
id,
name,
company,
leave_type,
apply,
create_time,
create_userid,
org_code,
is_open,
leave_balance
</sql>
<sql id="Base_Column_List_Alias">
id KqglAssoLeaveRules_id,
name KqglAssoLeaveRules_name,
company KqglAssoLeaveRules_company,
leave_type KqglAssoLeaveRules_leave_type,
apply KqglAssoLeaveRules_apply,
create_time KqglAssoLeaveRules_create_time,
create_userid KqglAssoLeaveRules_create_userid,
org_code KqglAssoLeaveRules_org_code,
is_open KqglAssoLeaveRules_is_open,
leave_balance KqglAssoLeaveRules_leave_balance
</sql>
<insert id="insertleaverulesList" parameterType="java.util.List" >
insert into kqgl_asso_leave_rules (name,company,leave_type,apply,create_time,create_userid,org_code,is_open,leave_balance)
<foreach collection="list" item="item" index="index" open="values " close="" separator=",">
(
<if test="item.name != null" >
#{item.name,jdbcType=VARCHAR},
</if>
<if test="item.company != null" >
#{item.company,jdbcType=VARCHAR},
</if>
<if test="item.leaveType != null" >
#{item.leaveType,jdbcType=INTEGER},
</if>
<if test="item.apply != null" >
#{item.apply,jdbcType=INTEGER},
</if>
<if test="item.createTime != null" >
#{item.createTime,jdbcType=VARCHAR},
</if>
<if test="item.createUserid != null" >
#{item.createUserid,jdbcType=INTEGER},
</if>
<if test="item.orgCode != null" >
#{item.orgCode,jdbcType=INTEGER},
</if>
<if test="item.isOpen != null" >
#{item.isOpen,jdbcType=INTEGER},
</if>
<if test="item.leaveBalance != null" >
#{item.leaveBalance,jdbcType=INTEGER}
</if>
)
</foreach>
</insert>
<!--
<insert id="insert" useGeneratedKeys="true" keyColumn="id" parameterType="cn.timer.api.bean.kqmk.KqglAssoLeaveRules">
INSERT INTO kqgl_asso_leave_rules
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test ='null != name'>
name,
</if>
<if test ='null != company'>
company,
</if>
<if test ='null != leaveType'>
leave_type,
</if>
<if test ='null != apply'>
apply,
</if>
<if test ='null != createTime'>
create_time,
</if>
<if test ='null != createUserid'>
create_userid,
</if>
<if test ='null != orgCode'>
org_code,
</if>
<if test ='null != isOpen'>
is_open,
</if>
<if test ='null != leaveBalance'>
leave_balance
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test ='null != name'>
#{name},
</if>
<if test ='null != company'>
#{company},
</if>
<if test ='null != leaveType'>
#{leaveType},
</if>
<if test ='null != apply'>
#{apply},
</if>
<if test ='null != createTime'>
#{createTime},
</if>
<if test ='null != createUserid'>
#{createUserid},
</if>
<if test ='null != orgCode'>
#{orgCode},
</if>
<if test ='null != isOpen'>
#{isOpen},
</if>
<if test ='null != leaveBalance'>
#{leaveBalance}
</if>
</trim>
</insert>
<delete id="delete" >
DELETE FROM kqgl_asso_leave_rules
WHERE id = #{id}
</delete>
<update id="update" parameterType="cn.timer.api.bean.kqmk.KqglAssoLeaveRules">
UPDATE kqgl_asso_leave_rules
<set>
<if test ='null != name'>name = #{name},</if>
<if test ='null != company'>company = #{company},</if>
<if test ='null != leaveType'>leave_type = #{leaveType},</if>
<if test ='null != apply'>apply = #{apply},</if>
<if test ='null != createTime'>create_time = #{createTime},</if>
<if test ='null != createUserid'>create_userid = #{createUserid},</if>
<if test ='null != orgCode'>org_code = #{orgCode},</if>
<if test ='null != isOpen'>is_open = #{isOpen},</if>
<if test ='null != leaveBalance'>leave_balance = #{leaveBalance}</if>
</set>
WHERE id = #{id}
</update>
<select id="load" resultMap="BaseResultMap">
SELECT <include refid="Base_Column_List" />
FROM kqgl_asso_leave_rules
WHERE id = #{id}
</select>
<select id="pageList" resultMap="BaseResultMap">
SELECT <include refid="Base_Column_List" />
FROM kqgl_asso_leave_rules
LIMIT #{offset}, #{pageSize}
</select>
<select id="pageListCount" resultType="java.lang.Integer">
SELECT count(1)
FROM kqgl_asso_leave_rules
</select>
-->
</mapper>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="cn.timer.api.dao.kqmk.KqglAssoOvertimeBasicsMapper">
<resultMap id="BaseResultMap" type="cn.timer.api.bean.kqmk.KqglAssoOvertimeBasics" >
<id column="id" property="id" />
<result column="minimum_unit" property="minimumUnit" />
<result column="modify_userid" property="modifyUserid" />
<result column="modify_time" property="modifyTime" />
<result column="org_code" property="orgCode" />
</resultMap>
<sql id="Base_Column_List">
id,
minimum_unit,
modify_userid,
modify_time,
org_code
</sql>
<sql id="Base_Column_List_Alias">
id KqglAssoOvertimeBasics_id,
minimum_unit KqglAssoOvertimeBasics_minimum_unit,
modify_userid KqglAssoOvertimeBasics_modify_userid,
modify_time KqglAssoOvertimeBasics_modify_time,
org_code KqglAssoOvertimeBasics_org_code
</sql>
<!--
<insert id="insert" useGeneratedKeys="true" keyColumn="id" parameterType="cn.timer.api.bean.kqmk.KqglAssoOvertimeBasics">
INSERT INTO kqgl_asso_overtime_basics
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test ='null != minimumUnit'>
minimum_unit,
</if>
<if test ='null != modifyUserid'>
modify_userid,
</if>
<if test ='null != modifyTime'>
modify_time,
</if>
<if test ='null != orgCode'>
org_code
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test ='null != minimumUnit'>
#{minimumUnit},
</if>
<if test ='null != modifyUserid'>
#{modifyUserid},
</if>
<if test ='null != modifyTime'>
#{modifyTime},
</if>
<if test ='null != orgCode'>
#{orgCode}
</if>
</trim>
</insert>
<delete id="delete" >
DELETE FROM kqgl_asso_overtime_basics
WHERE id = #{id}
</delete>
<update id="update" parameterType="cn.timer.api.bean.kqmk.KqglAssoOvertimeBasics">
UPDATE kqgl_asso_overtime_basics
<set>
<if test ='null != minimumUnit'>minimum_unit = #{minimumUnit},</if>
<if test ='null != modifyUserid'>modify_userid = #{modifyUserid},</if>
<if test ='null != modifyTime'>modify_time = #{modifyTime},</if>
<if test ='null != orgCode'>org_code = #{orgCode}</if>
</set>
WHERE id = #{id}
</update>
<select id="load" resultMap="BaseResultMap">
SELECT <include refid="Base_Column_List" />
FROM kqgl_asso_overtime_basics
WHERE id = #{id}
</select>
<select id="pageList" resultMap="BaseResultMap">
SELECT <include refid="Base_Column_List" />
FROM kqgl_asso_overtime_basics
LIMIT #{offset}, #{pageSize}
</select>
<select id="pageListCount" resultType="java.lang.Integer">
SELECT count(1)
FROM kqgl_asso_overtime_basics
</select>
-->
</mapper>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="cn.timer.api.dao.kqmk.KqglAssoPbmxMapper">
<resultMap id="BaseResultMap" type="cn.timer.api.bean.kqmk.KqglAssoPbmx" >
<id column="id" property="id" />
<result column="userid" property="userid" />
<result column="data" property="data" />
<result column="bcid" property="bcid" />
<result column="kqzid" property="kqzid" />
</resultMap>
<resultMap id="AssoPbmxMap" type="cn.timer.api.dto.kqmk.KqglAssoPbmxDto" >
<id column="id" property="id" />
<result column="userid" property="userid" />
<result column="data" property="data" />
<result column="bcid" property="bcid" />
<result column="kqzid" property="kqzid" />
<result column="bcname" property="bcname" />
<result column="sbdk1" property="sbdk1" />
<result column="sbqjks1" property="sbqjks1" />
<result column="sbqjjs1" property="sbqjjs1" />
<result column="xbdk1" property="xbdk1" />
<result column="xbqjks1" property="xbqjks1" />
<result column="xbqjjs1" property="xbqjjs1" />
<result column="sbdk2" property="sbdk2" />
<result column="sbqjks2" property="sbqjks2" />
<result column="sbqjjs2" property="sbqjjs2" />
<result column="xbdk2" property="xbdk2" />
<result column="xbqjks2" property="xbqjks2" />
<result column="xbqjjs2" property="xbqjjs2" />
<result column="sbdk3" property="sbdk3" />
<result column="sbqjks3" property="sbqjks3" />
<result column="sbqjjs3" property="sbqjjs3" />
<result column="xbdk3" property="xbdk3" />
<result column="xbqjks3" property="xbqjks3" />
<result column="xbqjjs3" property="xbqjjs3" />
<result column="isxbdk" property="isxbdk" />
<result column="sxbcs" property="sxbcs" />
</resultMap>
<sql id="Base_Column_List">
id,
userid,
data,
bcid,
kqzid
</sql>
<sql id="Base_Column_List_Alias">
id KqglAssoPbmx_id,
userid KqglAssoPbmx_userid,
data KqglAssoPbmx_data,
bcid KqglAssoPbmx_bcid,
kqzid KqglAssoPbmx_kqzid
</sql>
<select id="getScheduleSpecificAttendance" resultMap="AssoPbmxMap">
select pbmx.*,
bcsz.`name` bcname,
bcsz.sbdk1,
bcsz.sbqjks1,
bcsz.sbqjjs1,
bcsz.xbdk1,
bcsz.xbqjks1,
bcsz.xbqjjs1,
bcsz.sbdk2,
bcsz.sbqjks2,
bcsz.sbqjjs2,
bcsz.xbdk2,
bcsz.xbqjks2,
bcsz.xbqjjs2,
bcsz.sbdk3,
bcsz.sbqjks3,
bcsz.sbqjjs3,
bcsz.xbdk3,
bcsz.xbqjks3,
bcsz.xbqjjs3,
bcsz.sxbcs,
bcsz.is_xbdk as isxbdk
from kqgl_asso_pbmx pbmx
LEFT JOIN kqgl_asso_bcsz as bcsz on bcsz.id = pbmx.bcid
where pbmx.kqzid = #{kqzid}
and pbmx.userid = #{userid}
and pbmx.`data` = #{date}
</select>
<!--
<insert id="insert" useGeneratedKeys="true" keyColumn="id" parameterType="cn.timer.api.bean.kqmk.KqglAssoPbmx">
INSERT INTO kqgl_asso_pbmx
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test ='null != userid'>
userid,
</if>
<if test ='null != data'>
data,
</if>
<if test ='null != bcid'>
bcid,
</if>
<if test ='null != kqzid'>
kqzid
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test ='null != userid'>
#{userid},
</if>
<if test ='null != data'>
#{data},
</if>
<if test ='null != bcid'>
#{bcid},
</if>
<if test ='null != kqzid'>
#{kqzid}
</if>
</trim>
</insert>
<delete id="delete" >
DELETE FROM kqgl_asso_pbmx
WHERE id = #{id}
</delete>
<update id="update" parameterType="cn.timer.api.bean.kqmk.KqglAssoPbmx">
UPDATE kqgl_asso_pbmx
<set>
<if test ='null != userid'>userid = #{userid},</if>
<if test ='null != data'>data = #{data},</if>
<if test ='null != bcid'>bcid = #{bcid},</if>
<if test ='null != kqzid'>kqzid = #{kqzid}</if>
</set>
WHERE id = #{id}
</update>
<select id="load" resultMap="BaseResultMap">
SELECT <include refid="Base_Column_List" />
FROM kqgl_asso_pbmx
WHERE id = #{id}
</select>
<select id="pageList" resultMap="BaseResultMap">
SELECT <include refid="Base_Column_List" />
FROM kqgl_asso_pbmx
LIMIT #{offset}, #{pageSize}
</select>
<select id="pageListCount" resultType="java.lang.Integer">
SELECT count(1)
FROM kqgl_asso_pbmx
</select>
-->
</mapper>
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment