李天标 4 gadi atpakaļ
vecāks
revīzija
d30164cd4d

+ 3 - 0
pom.xml

@@ -74,7 +74,10 @@
 		<dependency>
 			<groupId>org.springframework.boot</groupId>
 			<artifactId>spring-boot-starter-tomcat</artifactId>
+			<!--线上-->
 			<scope>provided</scope>
+			<!--<scope>compile</scope>-->
+			<!--<version>1.5.2.RELEASE</version>-->
 		</dependency>
 
 		<dependency>

+ 24 - 0
src/main/java/com/shawn/model/Bean/SignBean.java

@@ -0,0 +1,24 @@
+package com.shawn.model.Bean;
+
+import io.swagger.annotations.ApiModelProperty;
+import lombok.Getter;
+import lombok.NoArgsConstructor;
+import lombok.Setter;
+import lombok.ToString;
+import lombok.experimental.Accessors;
+
+@Accessors(chain = true)
+@NoArgsConstructor
+@Getter
+@Setter
+@ToString
+public class SignBean {
+
+    @ApiModelProperty(value="类目")
+    private String title;
+
+    @ApiModelProperty(value="")
+    private String desc;
+
+
+}

+ 3 - 0
src/main/java/com/shawn/model/entity/TAdmin.java

@@ -102,6 +102,9 @@ public class TAdmin {
 	@ApiModelProperty(value="")
 	private String ifForeign;
 
+	@ApiModelProperty(value="")
+	private String level;
+
 	/**自定义统一方法设置主键**/
 	public void setPrimaryKey(Long primaryKey) {
 		 setId(primaryKey);

+ 83 - 0
src/main/java/com/shawn/model/entity/TSign.java

@@ -0,0 +1,83 @@
+package com.shawn.model.entity;
+
+import com.fasterxml.jackson.annotation.JsonFormat;
+import com.fasterxml.jackson.annotation.JsonIgnore;
+import io.swagger.annotations.ApiModelProperty;
+import lombok.Getter;
+import lombok.NoArgsConstructor;
+import lombok.Setter;
+import lombok.ToString;
+import lombok.experimental.Accessors;
+import org.springframework.format.annotation.DateTimeFormat;
+
+import java.util.Date;
+
+@Accessors(chain = true)
+@NoArgsConstructor
+@Getter
+@Setter
+@ToString
+public class TSign {
+    
+	@ApiModelProperty(value="")
+	private Integer id;
+
+	@ApiModelProperty(value="")
+	private Long adminId;
+
+
+	@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
+	@JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
+	@ApiModelProperty(value="")
+	private Date createDate;
+
+	@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
+	@JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
+	@ApiModelProperty(value="")
+	private Date modifyDate;
+	@ApiModelProperty(value="")
+	private String code;
+	/**
+	 *
+	 */
+	@ApiModelProperty(value="")
+	private String clientId;
+
+	/**
+	 *
+	 */
+	@ApiModelProperty(value="")
+	private String workName;
+
+	/**
+	 * 状态  0:创建状态 1:已签到
+	 */
+	private String status;
+
+	/**
+	 *
+	 */
+	@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
+	@JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
+	@ApiModelProperty(value="打卡时间")
+	private Date payDate;
+	@ApiModelProperty(value="")
+	private Long weixinId;
+
+	/**自定义统一方法设置主键**/
+	public void setPrimaryKey(Integer primaryKey) {
+		 setId(primaryKey);
+	}
+
+	/**自定义统一方法获取主键**/
+	@JsonIgnore
+	public Integer getPrimaryKey() {
+		 return getId();
+	}
+
+	/**判断该实体是否存在主键**/
+	public boolean hasPrimaryKey() {
+		return true;
+	}
+
+}

+ 969 - 0
src/main/java/com/shawn/model/entity/TSignExample.java

@@ -0,0 +1,969 @@
+package com.shawn.model.entity;
+
+import java.util.ArrayList;
+import java.util.Date;
+import java.util.List;
+
+public class TSignExample {
+    /**
+     * t_weixin
+     */
+    protected String orderByClause;
+
+    /**
+     * t_weixin
+     */
+    protected boolean distinct;
+
+    /**
+     * t_weixin
+     */
+    protected List<Criteria> oredCriteria;
+
+    private Integer limit;
+
+    private Integer offset;
+
+    public TSignExample() {
+        oredCriteria = new ArrayList<Criteria>();
+    }
+
+    public void setOrderByClause(String orderByClause) {
+        this.orderByClause = orderByClause;
+    }
+
+    public String getOrderByClause() {
+        return orderByClause;
+    }
+
+    public void setDistinct(boolean distinct) {
+        this.distinct = distinct;
+    }
+
+    public boolean isDistinct() {
+        return distinct;
+    }
+
+    public List<Criteria> getOredCriteria() {
+        return oredCriteria;
+    }
+
+    public void or(Criteria criteria) {
+        oredCriteria.add(criteria);
+    }
+
+    public Criteria or() {
+        Criteria criteria = createCriteriaInternal();
+        oredCriteria.add(criteria);
+        return criteria;
+    }
+
+    public Criteria createCriteria() {
+        Criteria criteria = createCriteriaInternal();
+        if (oredCriteria.size() == 0) {
+            oredCriteria.add(criteria);
+        }
+        return criteria;
+    }
+
+    protected Criteria createCriteriaInternal() {
+        Criteria criteria = new Criteria();
+        return criteria;
+    }
+
+    public void clear() {
+        oredCriteria.clear();
+        orderByClause = null;
+        distinct = false;
+    }
+
+    public void setLimit(Integer limit) {
+        this.limit = limit;
+    }
+
+    public Integer getLimit() {
+        return limit;
+    }
+
+    public void setOffset(Integer offset) {
+        this.offset = offset;
+    }
+
+    public Integer getOffset() {
+        return offset;
+    }
+
+    /**
+     * t_weixin 2019-10-25
+     */
+    protected abstract static class GeneratedCriteria {
+        protected List<Criterion> criteria;
+
+        protected GeneratedCriteria() {
+            super();
+            criteria = new ArrayList<Criterion>();
+        }
+
+        public boolean isValid() {
+            return criteria.size() > 0;
+        }
+
+        public List<Criterion> getAllCriteria() {
+            return criteria;
+        }
+
+        public List<Criterion> getCriteria() {
+            return criteria;
+        }
+
+        protected void addCriterion(String condition) {
+            if (condition == null) {
+                throw new RuntimeException("Value for condition cannot be null");
+            }
+            criteria.add(new Criterion(condition));
+        }
+
+        protected void addCriterion(String condition, Object value, String property) {
+            if (value == null) {
+                throw new RuntimeException("Value for " + property + " cannot be null");
+            }
+            criteria.add(new Criterion(condition, value));
+        }
+
+        protected void addCriterion(String condition, Object value1, Object value2, String property) {
+            if (value1 == null || value2 == null) {
+                throw new RuntimeException("Between values for " + property + " cannot be null");
+            }
+            criteria.add(new Criterion(condition, value1, value2));
+        }
+
+        public Criteria andIdIsNull() {
+            addCriterion("id is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdIsNotNull() {
+            addCriterion("id is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdEqualTo(Integer value) {
+            addCriterion("id =", value, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdNotEqualTo(Integer value) {
+            addCriterion("id <>", value, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdGreaterThan(Integer value) {
+            addCriterion("id >", value, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdGreaterThanOrEqualTo(Integer value) {
+            addCriterion("id >=", value, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdLessThan(Integer value) {
+            addCriterion("id <", value, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdLessThanOrEqualTo(Integer value) {
+            addCriterion("id <=", value, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdIn(List<Integer> values) {
+            addCriterion("id in", values, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdNotIn(List<Integer> values) {
+            addCriterion("id not in", values, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdBetween(Integer value1, Integer value2) {
+            addCriterion("id between", value1, value2, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdNotBetween(Integer value1, Integer value2) {
+            addCriterion("id not between", value1, value2, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andAdminIdIsNull() {
+            addCriterion("admin_id is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andAdminIdIsNotNull() {
+            addCriterion("admin_id is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andAdminIdEqualTo(Long value) {
+            addCriterion("admin_id =", value, "adminId");
+            return (Criteria) this;
+        }
+
+        public Criteria andAdminIdNotEqualTo(Long value) {
+            addCriterion("admin_id <>", value, "adminId");
+            return (Criteria) this;
+        }
+
+        public Criteria andAdminIdGreaterThan(Long value) {
+            addCriterion("admin_id >", value, "adminId");
+            return (Criteria) this;
+        }
+
+        public Criteria andAdminIdGreaterThanOrEqualTo(Long value) {
+            addCriterion("admin_id >=", value, "adminId");
+            return (Criteria) this;
+        }
+
+        public Criteria andAdminIdLessThan(Long value) {
+            addCriterion("admin_id <", value, "adminId");
+            return (Criteria) this;
+        }
+
+        public Criteria andAdminIdLessThanOrEqualTo(Long value) {
+            addCriterion("admin_id <=", value, "adminId");
+            return (Criteria) this;
+        }
+
+        public Criteria andAdminIdLike(Long value) {
+            addCriterion("admin_id like", value, "adminId");
+            return (Criteria) this;
+        }
+
+        public Criteria andAdminIdNotLike(Long value) {
+            addCriterion("admin_id not like", value, "adminId");
+            return (Criteria) this;
+        }
+
+        public Criteria andAdminIdIn(List<Long> values) {
+            addCriterion("admin_id in", values, "adminId");
+            return (Criteria) this;
+        }
+
+        public Criteria andAdminIdNotIn(List<Long> values) {
+            addCriterion("admin_id not in", values, "adminId");
+            return (Criteria) this;
+        }
+
+        public Criteria andAdminIdBetween(Long value1, Long value2) {
+            addCriterion("admin_id between", value1, value2, "adminId");
+            return (Criteria) this;
+        }
+
+        public Criteria andAdminIdNotBetween(Long value1, Long value2) {
+            addCriterion("admin_id not between", value1, value2, "adminId");
+            return (Criteria) this;
+        }
+
+        public Criteria andClientIdIsNull() {
+            addCriterion("client_id is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andClientIdIsNotNull() {
+            addCriterion("client_id is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andClientIdEqualTo(String value) {
+            addCriterion("client_id =", value, "clientId");
+            return (Criteria) this;
+        }
+
+        public Criteria andClientIdNotEqualTo(String value) {
+            addCriterion("client_id <>", value, "clientId");
+            return (Criteria) this;
+        }
+
+        public Criteria andClientIdGreaterThan(String value) {
+            addCriterion("client_id >", value, "clientId");
+            return (Criteria) this;
+        }
+
+        public Criteria andClientIdGreaterThanOrEqualTo(String value) {
+            addCriterion("client_id >=", value, "clientId");
+            return (Criteria) this;
+        }
+
+        public Criteria andClientIdLessThan(String value) {
+            addCriterion("client_id <", value, "clientId");
+            return (Criteria) this;
+        }
+
+        public Criteria andClientIdLessThanOrEqualTo(String value) {
+            addCriterion("client_id <=", value, "clientId");
+            return (Criteria) this;
+        }
+
+        public Criteria andClientIdLike(String value) {
+            addCriterion("client_id like", value, "clientId");
+            return (Criteria) this;
+        }
+
+        public Criteria andClientIdNotLike(String value) {
+            addCriterion("client_id not like", value, "clientId");
+            return (Criteria) this;
+        }
+
+        public Criteria andClientIdIn(List<String> values) {
+            addCriterion("client_id in", values, "clientId");
+            return (Criteria) this;
+        }
+
+        public Criteria andClientIdNotIn(List<String> values) {
+            addCriterion("client_id not in", values, "clientId");
+            return (Criteria) this;
+        }
+
+        public Criteria andClientIdBetween(String value1, String value2) {
+            addCriterion("client_id between", value1, value2, "clientId");
+            return (Criteria) this;
+        }
+
+        public Criteria andClientIdNotBetween(String value1, String value2) {
+            addCriterion("client_id not between", value1, value2, "clientId");
+            return (Criteria) this;
+        }
+
+        public Criteria andCreateDateIsNull() {
+            addCriterion("create_date is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andCreateDateIsNotNull() {
+            addCriterion("create_date is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andCreateDateEqualTo(Date value) {
+            addCriterion("create_date =", value, "createDate");
+            return (Criteria) this;
+        }
+
+        public Criteria andCreateDateNotEqualTo(Date value) {
+            addCriterion("create_date <>", value, "createDate");
+            return (Criteria) this;
+        }
+
+        public Criteria andCreateDateGreaterThan(Date value) {
+            addCriterion("create_date >", value, "createDate");
+            return (Criteria) this;
+        }
+
+        public Criteria andCreateDateGreaterThanOrEqualTo(Date value) {
+            addCriterion("create_date >=", value, "createDate");
+            return (Criteria) this;
+        }
+
+        public Criteria andCreateDateLessThan(Date value) {
+            addCriterion("create_date <", value, "createDate");
+            return (Criteria) this;
+        }
+
+        public Criteria andCreateDateLessThanOrEqualTo(Date value) {
+            addCriterion("create_date <=", value, "createDate");
+            return (Criteria) this;
+        }
+
+        public Criteria andCreateDateIn(List<Date> values) {
+            addCriterion("create_date in", values, "createDate");
+            return (Criteria) this;
+        }
+
+        public Criteria andCreateDateNotIn(List<Date> values) {
+            addCriterion("create_date not in", values, "createDate");
+            return (Criteria) this;
+        }
+
+        public Criteria andCreateDateBetween(Date value1, Date value2) {
+            addCriterion("create_date between", value1, value2, "createDate");
+            return (Criteria) this;
+        }
+
+        public Criteria andCreateDateNotBetween(Date value1, Date value2) {
+            addCriterion("create_date not between", value1, value2, "createDate");
+            return (Criteria) this;
+        }
+
+        public Criteria andModifyDateIsNull() {
+            addCriterion("modify_date is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andModifyDateIsNotNull() {
+            addCriterion("modify_date is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andModifyDateEqualTo(Date value) {
+            addCriterion("modify_date =", value, "modifyDate");
+            return (Criteria) this;
+        }
+
+        public Criteria andModifyDateNotEqualTo(Date value) {
+            addCriterion("modify_date <>", value, "modifyDate");
+            return (Criteria) this;
+        }
+
+        public Criteria andModifyDateGreaterThan(Date value) {
+            addCriterion("modify_date >", value, "modifyDate");
+            return (Criteria) this;
+        }
+
+        public Criteria andModifyDateGreaterThanOrEqualTo(Date value) {
+            addCriterion("modify_date >=", value, "modifyDate");
+            return (Criteria) this;
+        }
+
+        public Criteria andModifyDateLessThan(Date value) {
+            addCriterion("modify_date <", value, "modifyDate");
+            return (Criteria) this;
+        }
+
+        public Criteria andModifyDateLessThanOrEqualTo(Date value) {
+            addCriterion("modify_date <=", value, "modifyDate");
+            return (Criteria) this;
+        }
+
+        public Criteria andModifyDateIn(List<Date> values) {
+            addCriterion("modify_date in", values, "modifyDate");
+            return (Criteria) this;
+        }
+
+        public Criteria andModifyDateNotIn(List<Date> values) {
+            addCriterion("modify_date not in", values, "modifyDate");
+            return (Criteria) this;
+        }
+
+        public Criteria andModifyDateBetween(Date value1, Date value2) {
+            addCriterion("modify_date between", value1, value2, "modifyDate");
+            return (Criteria) this;
+        }
+
+        public Criteria andModifyDateNotBetween(Date value1, Date value2) {
+            addCriterion("modify_date not between", value1, value2, "modifyDate");
+            return (Criteria) this;
+        }
+
+        public Criteria andWeixinIdIsNull() {
+            addCriterion("weixin_id is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andWeixinIdIsNotNull() {
+            addCriterion("weixin_id is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andWeixinIdEqualTo(Long value) {
+            addCriterion("weixin_id =", value, "weixinId");
+            return (Criteria) this;
+        }
+
+        public Criteria andWeixinIdNotEqualTo(Long value) {
+            addCriterion("weixin_id <>", value, "weixinId");
+            return (Criteria) this;
+        }
+
+        public Criteria andWeixinIdGreaterThan(Long value) {
+            addCriterion("weixin_id >", value, "weixinId");
+            return (Criteria) this;
+        }
+
+        public Criteria andWeixinIdGreaterThanOrEqualTo(Long value) {
+            addCriterion("weixin_id >=", value, "weixinId");
+            return (Criteria) this;
+        }
+
+        public Criteria andWeixinIdLessThan(Long value) {
+            addCriterion("weixin_id <", value, "weixinId");
+            return (Criteria) this;
+        }
+
+        public Criteria andWeixinIdLessThanOrEqualTo(Long value) {
+            addCriterion("weixin_id <=", value, "weixinId");
+            return (Criteria) this;
+        }
+
+        public Criteria andWeixinIdLike(Long value) {
+            addCriterion("weixin_id like", value, "weixinId");
+            return (Criteria) this;
+        }
+
+        public Criteria andWeixinIdNotLike(Long value) {
+            addCriterion("weixin_id not like", value, "weixinId");
+            return (Criteria) this;
+        }
+
+        public Criteria andWeixinIdIn(List<Long> values) {
+            addCriterion("weixin_id in", values, "weixinId");
+            return (Criteria) this;
+        }
+
+        public Criteria andWeixinIdNotIn(List<Long> values) {
+            addCriterion("weixin_id not in", values, "weixinId");
+            return (Criteria) this;
+        }
+
+        public Criteria andWeixinIdBetween(Long value1, Long value2) {
+            addCriterion("weixin_id between", value1, value2, "weixinId");
+            return (Criteria) this;
+        }
+
+        public Criteria andWeixinIdNotBetween(Long value1, Long value2) {
+            addCriterion("weixin_id not between", value1, value2, "weixinId");
+            return (Criteria) this;
+        }
+
+        public Criteria andWorkNameIsNull() {
+            addCriterion("work_name is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andWorkNameIsNotNull() {
+            addCriterion("work_name is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andWorkNameEqualTo(String value) {
+            addCriterion("work_name =", value, "workName");
+            return (Criteria) this;
+        }
+
+        public Criteria andWorkNameNotEqualTo(String value) {
+            addCriterion("work_name <>", value, "workName");
+            return (Criteria) this;
+        }
+
+        public Criteria andWorkNameGreaterThan(String value) {
+            addCriterion("work_name >", value, "workName");
+            return (Criteria) this;
+        }
+
+        public Criteria andWorkNameGreaterThanOrEqualTo(String value) {
+            addCriterion("work_name >=", value, "workName");
+            return (Criteria) this;
+        }
+
+        public Criteria andWorkNameLessThan(String value) {
+            addCriterion("work_name <", value, "workName");
+            return (Criteria) this;
+        }
+
+        public Criteria andWorkNameLessThanOrEqualTo(String value) {
+            addCriterion("work_name <=", value, "workName");
+            return (Criteria) this;
+        }
+
+        public Criteria andWorkNameLike(String value) {
+            addCriterion("work_name like", value, "workName");
+            return (Criteria) this;
+        }
+
+        public Criteria andWorkNameNotLike(String value) {
+            addCriterion("work_name not like", value, "workName");
+            return (Criteria) this;
+        }
+
+        public Criteria andWorkNameIn(List<String> values) {
+            addCriterion("work_name in", values, "workName");
+            return (Criteria) this;
+        }
+
+        public Criteria andWorkNameNotIn(List<String> values) {
+            addCriterion("work_name not in", values, "workName");
+            return (Criteria) this;
+        }
+
+        public Criteria andWorkNameBetween(String value1, String value2) {
+            addCriterion("work_name between", value1, value2, "workName");
+            return (Criteria) this;
+        }
+
+        public Criteria andWorkNameNotBetween(String value1, String value2) {
+            addCriterion("work_name not between", value1, value2, "workName");
+            return (Criteria) this;
+        }
+
+        public Criteria andPayDateIsNull() {
+            addCriterion("pay_date is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andPayDateIsNotNull() {
+            addCriterion("pay_date is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andPayDateEqualTo(Date value) {
+            addCriterion("pay_date =", value, "payDate");
+            return (Criteria) this;
+        }
+
+        public Criteria andPayDateNotEqualTo(Date value) {
+            addCriterion("pay_date <>", value, "payDate");
+            return (Criteria) this;
+        }
+
+        public Criteria andPayDateGreaterThan(Date value) {
+            addCriterion("pay_date >", value, "payDate");
+            return (Criteria) this;
+        }
+
+        public Criteria andPayDateGreaterThanOrEqualTo(Date value) {
+            addCriterion("pay_date >=", value, "payDate");
+            return (Criteria) this;
+        }
+
+        public Criteria andPayDateLessThan(Date value) {
+            addCriterion("pay_date <", value, "payDate");
+            return (Criteria) this;
+        }
+
+        public Criteria andPayDateLessThanOrEqualTo(Date value) {
+            addCriterion("pay_date <=", value, "payDate");
+            return (Criteria) this;
+        }
+
+        public Criteria andPayDateIn(List<Date> values) {
+            addCriterion("pay_date in", values, "payDate");
+            return (Criteria) this;
+        }
+
+        public Criteria andPayDateNotIn(List<Date> values) {
+            addCriterion("pay_date not in", values, "payDate");
+            return (Criteria) this;
+        }
+
+        public Criteria andPayDateBetween(Date value1, Date value2) {
+            addCriterion("pay_date between", value1, value2, "payDate");
+            return (Criteria) this;
+        }
+
+        public Criteria andPayDateNotBetween(Date value1, Date value2) {
+            addCriterion("pay_date not between", value1, value2, "payDate");
+            return (Criteria) this;
+        }
+
+        public Criteria andNickNameIsNull() {
+            addCriterion("nick_name is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andNickNameIsNotNull() {
+            addCriterion("nick_name is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andNickNameEqualTo(String value) {
+            addCriterion("nick_name =", value, "nickName");
+            return (Criteria) this;
+        }
+
+        public Criteria andNickNameNotEqualTo(String value) {
+            addCriterion("nick_name <>", value, "nickName");
+            return (Criteria) this;
+        }
+
+        public Criteria andNickNameGreaterThan(String value) {
+            addCriterion("nick_name >", value, "nickName");
+            return (Criteria) this;
+        }
+
+        public Criteria andNickNameGreaterThanOrEqualTo(String value) {
+            addCriterion("nick_name >=", value, "nickName");
+            return (Criteria) this;
+        }
+
+        public Criteria andNickNameLessThan(String value) {
+            addCriterion("nick_name <", value, "nickName");
+            return (Criteria) this;
+        }
+
+        public Criteria andNickNameLessThanOrEqualTo(String value) {
+            addCriterion("nick_name <=", value, "nickName");
+            return (Criteria) this;
+        }
+
+        public Criteria andNickNameLike(String value) {
+            addCriterion("nick_name like", value, "nickName");
+            return (Criteria) this;
+        }
+
+        public Criteria andNickNameNotLike(String value) {
+            addCriterion("nick_name not like", value, "nickName");
+            return (Criteria) this;
+        }
+
+        public Criteria andNickNameIn(List<String> values) {
+            addCriterion("nick_name in", values, "nickName");
+            return (Criteria) this;
+        }
+
+        public Criteria andNickNameNotIn(List<String> values) {
+            addCriterion("nick_name not in", values, "nickName");
+            return (Criteria) this;
+        }
+
+        public Criteria andNickNameBetween(String value1, String value2) {
+            addCriterion("nick_name between", value1, value2, "nickName");
+            return (Criteria) this;
+        }
+
+        public Criteria andNickNameNotBetween(String value1, String value2) {
+            addCriterion("nick_name not between", value1, value2, "nickName");
+            return (Criteria) this;
+        }
+
+        public Criteria andStatusIsNull() {
+            addCriterion("status is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andStatusIsNotNull() {
+            addCriterion("status is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andStatusEqualTo(String value) {
+            addCriterion("status =", value, "status");
+            return (Criteria) this;
+        }
+
+        public Criteria andStatusNotEqualTo(String value) {
+            addCriterion("status <>", value, "status");
+            return (Criteria) this;
+        }
+
+        public Criteria andStatusGreaterThan(String value) {
+            addCriterion("status >", value, "status");
+            return (Criteria) this;
+        }
+
+        public Criteria andStatusGreaterThanOrEqualTo(String value) {
+            addCriterion("status >=", value, "status");
+            return (Criteria) this;
+        }
+
+        public Criteria andStatusLessThan(String value) {
+            addCriterion("status <", value, "status");
+            return (Criteria) this;
+        }
+
+        public Criteria andStatusLessThanOrEqualTo(String value) {
+            addCriterion("status <=", value, "status");
+            return (Criteria) this;
+        }
+
+        public Criteria andStatusLike(String value) {
+            addCriterion("status like", value, "status");
+            return (Criteria) this;
+        }
+
+        public Criteria andStatusNotLike(String value) {
+            addCriterion("status not like", value, "status");
+            return (Criteria) this;
+        }
+
+        public Criteria andStatusIn(List<String> values) {
+            addCriterion("status in", values, "status");
+            return (Criteria) this;
+        }
+
+        public Criteria andStatusNotIn(List<String> values) {
+            addCriterion("status not in", values, "status");
+            return (Criteria) this;
+        }
+
+        public Criteria andStatusBetween(String value1, String value2) {
+            addCriterion("status between", value1, value2, "status");
+            return (Criteria) this;
+        }
+
+        public Criteria andStatusNotBetween(String value1, String value2) {
+            addCriterion("status not between", value1, value2, "status");
+            return (Criteria) this;
+        }
+
+        public Criteria andLevelIsNull() {
+            addCriterion("level is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andLevelIsNotNull() {
+            addCriterion("level is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andLevelEqualTo(String value) {
+            addCriterion("level =", value, "level");
+            return (Criteria) this;
+        }
+
+        public Criteria andLevelNotEqualTo(String value) {
+            addCriterion("level <>", value, "level");
+            return (Criteria) this;
+        }
+
+        public Criteria andLevelGreaterThan(String value) {
+            addCriterion("level >", value, "level");
+            return (Criteria) this;
+        }
+
+        public Criteria andLevelGreaterThanOrEqualTo(String value) {
+            addCriterion("level >=", value, "level");
+            return (Criteria) this;
+        }
+
+        public Criteria andLevelLessThan(String value) {
+            addCriterion("level <", value, "level");
+            return (Criteria) this;
+        }
+
+        public Criteria andLevelLessThanOrEqualTo(String value) {
+            addCriterion("level <=", value, "level");
+            return (Criteria) this;
+        }
+
+        public Criteria andLevelLike(String value) {
+            addCriterion("level like", value, "level");
+            return (Criteria) this;
+        }
+
+        public Criteria andLevelNotLike(String value) {
+            addCriterion("level not like", value, "level");
+            return (Criteria) this;
+        }
+
+        public Criteria andLevelIn(List<String> values) {
+            addCriterion("level in", values, "level");
+            return (Criteria) this;
+        }
+
+        public Criteria andLevelNotIn(List<String> values) {
+            addCriterion("level not in", values, "level");
+            return (Criteria) this;
+        }
+
+        public Criteria andLevelBetween(String value1, String value2) {
+            addCriterion("level between", value1, value2, "level");
+            return (Criteria) this;
+        }
+
+        public Criteria andLevelNotBetween(String value1, String value2) {
+            addCriterion("level not between", value1, value2, "level");
+            return (Criteria) this;
+        }
+    }
+
+    /**
+     * t_weixin
+     */
+    public static class Criteria extends GeneratedCriteria {
+
+        protected Criteria() {
+            super();
+        }
+    }
+
+    /**
+     * t_weixin 2019-10-25
+     */
+    public static class Criterion {
+        private String condition;
+
+        private Object value;
+
+        private Object secondValue;
+
+        private boolean noValue;
+
+        private boolean singleValue;
+
+        private boolean betweenValue;
+
+        private boolean listValue;
+
+        private String typeHandler;
+
+        public String getCondition() {
+            return condition;
+        }
+
+        public Object getValue() {
+            return value;
+        }
+
+        public Object getSecondValue() {
+            return secondValue;
+        }
+
+        public boolean isNoValue() {
+            return noValue;
+        }
+
+        public boolean isSingleValue() {
+            return singleValue;
+        }
+
+        public boolean isBetweenValue() {
+            return betweenValue;
+        }
+
+        public boolean isListValue() {
+            return listValue;
+        }
+
+        public String getTypeHandler() {
+            return typeHandler;
+        }
+
+        protected Criterion(String condition) {
+            super();
+            this.condition = condition;
+            this.typeHandler = null;
+            this.noValue = true;
+        }
+
+        protected Criterion(String condition, Object value, String typeHandler) {
+            super();
+            this.condition = condition;
+            this.value = value;
+            this.typeHandler = typeHandler;
+            if (value instanceof List<?>) {
+                this.listValue = true;
+            } else {
+                this.singleValue = true;
+            }
+        }
+
+        protected Criterion(String condition, Object value) {
+            this(condition, value, null);
+        }
+
+        protected Criterion(String condition, Object value, Object secondValue, String typeHandler) {
+            super();
+            this.condition = condition;
+            this.value = value;
+            this.secondValue = secondValue;
+            this.typeHandler = typeHandler;
+            this.betweenValue = true;
+        }
+
+        protected Criterion(String condition, Object value, Object secondValue) {
+            this(condition, value, secondValue, null);
+        }
+    }
+}

+ 4 - 0
src/main/java/com/shawn/model/entity/TWeixin.java

@@ -44,7 +44,11 @@ public class TWeixin {
 	@ApiModelProperty(value="微信头像")
 	private String avatarUrl;
 
+	@ApiModelProperty(value="员工昵称")
+	private String workName;
 
+	@ApiModelProperty(value="等级")
+	private String level;
 
 	/**自定义统一方法设置主键**/
 	public void setPrimaryKey(Integer primaryKey) {

+ 140 - 0
src/main/java/com/shawn/model/entity/TWeixinExample.java

@@ -457,6 +457,76 @@ public class TWeixinExample {
             return (Criteria) this;
         }
 
+        public Criteria andWorkNameIsNull() {
+            addCriterion("work_name is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andWorkNameIsNotNull() {
+            addCriterion("work_name is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andWorkNameEqualTo(String value) {
+            addCriterion("work_name =", value, "workName");
+            return (Criteria) this;
+        }
+
+        public Criteria andWorkNameNotEqualTo(String value) {
+            addCriterion("work_name <>", value, "workName");
+            return (Criteria) this;
+        }
+
+        public Criteria andWorkNameGreaterThan(String value) {
+            addCriterion("work_name >", value, "workName");
+            return (Criteria) this;
+        }
+
+        public Criteria andWorkNameGreaterThanOrEqualTo(String value) {
+            addCriterion("work_name >=", value, "workName");
+            return (Criteria) this;
+        }
+
+        public Criteria andWorkNameLessThan(String value) {
+            addCriterion("work_name <", value, "workName");
+            return (Criteria) this;
+        }
+
+        public Criteria andWorkNameLessThanOrEqualTo(String value) {
+            addCriterion("work_name <=", value, "workName");
+            return (Criteria) this;
+        }
+
+        public Criteria andWorkNameLike(String value) {
+            addCriterion("work_name like", value, "workName");
+            return (Criteria) this;
+        }
+
+        public Criteria andWorkNameNotLike(String value) {
+            addCriterion("work_name not like", value, "workName");
+            return (Criteria) this;
+        }
+
+        public Criteria andWorkNameIn(List<String> values) {
+            addCriterion("work_name in", values, "workName");
+            return (Criteria) this;
+        }
+
+        public Criteria andWorkNameNotIn(List<String> values) {
+            addCriterion("work_name not in", values, "workName");
+            return (Criteria) this;
+        }
+
+        public Criteria andWorkNameBetween(String value1, String value2) {
+            addCriterion("work_name between", value1, value2, "workName");
+            return (Criteria) this;
+        }
+
+        public Criteria andWorkNameNotBetween(String value1, String value2) {
+            addCriterion("work_name not between", value1, value2, "workName");
+            return (Criteria) this;
+        }
+
         public Criteria andNickNameIsNull() {
             addCriterion("nick_name is null");
             return (Criteria) this;
@@ -596,6 +666,76 @@ public class TWeixinExample {
             addCriterion("avatar_url not between", value1, value2, "avatarUrl");
             return (Criteria) this;
         }
+
+        public Criteria andLevelIsNull() {
+            addCriterion("level is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andLevelIsNotNull() {
+            addCriterion("level is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andLevelEqualTo(String value) {
+            addCriterion("level =", value, "level");
+            return (Criteria) this;
+        }
+
+        public Criteria andLevelNotEqualTo(String value) {
+            addCriterion("level <>", value, "level");
+            return (Criteria) this;
+        }
+
+        public Criteria andLevelGreaterThan(String value) {
+            addCriterion("level >", value, "level");
+            return (Criteria) this;
+        }
+
+        public Criteria andLevelGreaterThanOrEqualTo(String value) {
+            addCriterion("level >=", value, "level");
+            return (Criteria) this;
+        }
+
+        public Criteria andLevelLessThan(String value) {
+            addCriterion("level <", value, "level");
+            return (Criteria) this;
+        }
+
+        public Criteria andLevelLessThanOrEqualTo(String value) {
+            addCriterion("level <=", value, "level");
+            return (Criteria) this;
+        }
+
+        public Criteria andLevelLike(String value) {
+            addCriterion("level like", value, "level");
+            return (Criteria) this;
+        }
+
+        public Criteria andLevelNotLike(String value) {
+            addCriterion("level not like", value, "level");
+            return (Criteria) this;
+        }
+
+        public Criteria andLevelIn(List<String> values) {
+            addCriterion("level in", values, "level");
+            return (Criteria) this;
+        }
+
+        public Criteria andLevelNotIn(List<String> values) {
+            addCriterion("level not in", values, "level");
+            return (Criteria) this;
+        }
+
+        public Criteria andLevelBetween(String value1, String value2) {
+            addCriterion("level between", value1, value2, "level");
+            return (Criteria) this;
+        }
+
+        public Criteria andLevelNotBetween(String value1, String value2) {
+            addCriterion("level not between", value1, value2, "level");
+            return (Criteria) this;
+        }
     }
 
     /**

+ 5 - 0
src/main/java/com/shawn/model/entity/weixinParm.java

@@ -33,5 +33,10 @@ public class weixinParm {
     @ApiModelProperty(value="密码")
     private String password;
 
+    @ApiModelProperty(value="等级")
+    private String level;
+
+    @ApiModelProperty(value="员工名")
+    private String workName;
 
 }

+ 52 - 0
src/main/java/com/shawn/model/param/TSignParam.java

@@ -0,0 +1,52 @@
+/**
+ * Date:2019-12-25 11:12:55
+ * author:吴洪双
+*/
+
+package com.shawn.model.param;
+
+import com.shawn.model.entity.TSign;
+import com.shawn.model.entity.TWeixin;
+import io.swagger.annotations.ApiModelProperty;
+import lombok.Getter;
+import lombok.NoArgsConstructor;
+import lombok.Setter;
+import lombok.ToString;
+import lombok.experimental.Accessors;
+import org.springframework.format.annotation.DateTimeFormat;
+
+import java.util.Date;
+import java.util.List;
+
+@SuppressWarnings("serial")
+@Accessors(chain = true)
+@NoArgsConstructor
+@Getter
+@Setter
+@ToString
+public class TSignParam extends TSign {
+	// @CamelCaseToUnderscore
+    // @ApiModelProperty(value = "排序,如:id desc")
+    // private String orderByClause;
+    @ApiModelProperty(value = "是否distinct")
+    private boolean distinct;
+    @ApiModelProperty(value = "分页,展示多少条记录")
+    private Integer limit;
+    @ApiModelProperty(value = "分页,从第几条开始,默认从0开始")
+    private Integer offset;
+    @ApiModelProperty(value = "主键id 集合,用于批量删除和批量修改")
+    private List primaryKeyList;
+    private List<TWeixin> entityList;//实体集合,用于批量新增
+    
+	@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
+	private Date createDate_start;
+	@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
+	private Date createDate_end;
+	@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
+	private Date modifyDate_start;
+	@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
+	private Date modifyDate_end;
+
+/*==================================以上是自动生成部分字段======================================*/
+	
+}

+ 18 - 0
src/main/java/com/shawn/repository/TSignMapper.java

@@ -0,0 +1,18 @@
+/**
+ * Date:2019-12-25 11:12:55
+ * author:吴洪双
+*/
+
+package com.shawn.repository;
+
+import com.shawn.model.entity.TSign;
+import com.shawn.model.entity.TSignExample;
+import com.shawn.model.entity.TWeixin;
+import com.shawn.model.entity.TWeixinExample;
+import com.shawn.model.param.TSignParam;
+import com.shawn.model.param.TWeixinParam;
+import com.shawn.repository.base.BaseDaoInterface;
+
+public interface TSignMapper extends BaseDaoInterface<TSign,TSignExample,TSignParam, Integer>{
+    TSign findByEntity(TSign sign);
+}

+ 36 - 0
src/main/java/com/shawn/service/impl/TSignServiceImpl.java

@@ -0,0 +1,36 @@
+/**
+ * Date:2019-12-25 11:12:55
+ * author:吴洪双
+*/
+
+package com.shawn.service.impl;
+
+import com.shawn.model.entity.TSign;
+import com.shawn.model.entity.TSignExample;
+import com.shawn.model.param.TSignParam;
+import com.shawn.repository.TSignMapper;
+import com.shawn.service.base.BaseService;
+import com.shawn.service.interfac.TSignServiceInterface;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+@Service
+public class TSignServiceImpl extends BaseService<TSign,TSignExample,TSignParam,Integer> implements TSignServiceInterface {
+	@Autowired
+	private TSignMapper tSignMapper;
+	@Autowired
+	public TSignServiceImpl(TSignMapper dao) {
+		super(dao);
+	}
+
+	@Override
+	public String getResourceName() {
+		return "TSign";
+	}
+
+	@Override
+	public TSign findByEntity(TSign sign) {
+
+		return tSignMapper.findByEntity(sign);
+	}
+}

+ 18 - 0
src/main/java/com/shawn/service/interfac/TSignServiceInterface.java

@@ -0,0 +1,18 @@
+/**
+ * Date:2019-12-25 11:12:55
+ * author:吴洪双
+*/
+
+package com.shawn.service.interfac;
+
+import com.shawn.model.entity.TSign;
+import com.shawn.model.entity.TSignExample;
+import com.shawn.model.entity.TWeixin;
+import com.shawn.model.entity.TWeixinExample;
+import com.shawn.model.param.TSignParam;
+import com.shawn.model.param.TWeixinParam;
+import com.shawn.service.base.BaseServiceInterface;
+
+public interface TSignServiceInterface extends BaseServiceInterface<TSign,TSignExample,TSignParam,Integer>{
+   TSign findByEntity(TSign sign);
+}

+ 6 - 3
src/main/java/com/shawn/util/JoinpayConstant.java

@@ -39,15 +39,18 @@ public class JoinpayConstant {
     /**
      *  支付成功回调
      */
-    public final static String Notify_Url = "http://app.sunzee.com.cn/api/order/notify.htm";
+//    public final static String Notify_Url = "http://slb.sunzee.com.cn/api/order/notify.htm";
+    public final static String Notify_Url = "http://clean.sunzee.com.cn/api/order/notify.htm";
 
-    public final static String Notify_Url_PromoCode = "https://app.sunzee.com.cn/cleanMachineServer/TPromoCode/promoCodeNotify";
+//    public final static String Notify_Url_PromoCode = "https://slb.sunzee.com.cn/cleanMachineServer/TPromoCode/promoCodeNotify";
+    public final static String Notify_Url_PromoCode = "https://clean.sunzee.com.cn/cleanMachineServer/TPromoCode/promoCodeNotify";
 
     public final static Map<String,String> Result_status = new HashMap<>();
     /**
      *  退款成功回调
      */
-    public final static String Notify_Refund_Url = "http://app.sunzee.com.cn/api/order/notifyRefund.htm";
+//    public final static String Notify_Refund_Url = "http://slb.sunzee.com.cn/api/order/notifyRefund.htm";
+    public final static String Notify_Refund_Url = "http://clean.sunzee.com.cn/api/order/notifyRefund.htm";
 
 
     /**

+ 17 - 2
src/main/java/com/shawn/web/controller/TEquipmentController.java

@@ -195,12 +195,27 @@ public class TEquipmentController extends BaseController<TEquipment, TEquipmentE
 
 
     //远程开门
-    @PostMapping("/openDoor")
+    @PostMapping("/clean")
     public ResponseEntity<?> openDoor(@RequestBody StatisticsParam param) {
         String equipmentId = param.getEquipmentId();
         Long id = Long.valueOf(equipmentId);
         TEquipment equipment = tEquipmentService.selectEntityById(id);
-        PushUtils.push(equipment.getGtClientId(), "", "", PushUtils.buildJson("openDoor", "0").toString());
+        PushUtils.push(equipment.getGtClientId(), "", "", PushUtils.buildJson("clean", "0").toString());
+        return ResponseEntity
+                .status(HttpStatus.OK)
+                .body(new ResultMessage()
+                        .setCode(true)
+                        .setData("SUCCESS")
+                        .setMessage("SUCCESS"));
+    }
+
+    //远程开机
+    @PostMapping("/openEquipment")
+    public ResponseEntity<?> openEquipment(@RequestBody StatisticsParam param) {
+        String equipmentId = param.getEquipmentId();
+        Long id = Long.valueOf(equipmentId);
+        TEquipment equipment = tEquipmentService.selectEntityById(id);
+        PushUtils.push(equipment.getGtClientId(), "", "", PushUtils.buildJson("eqeStatus", "1").toString());
         return ResponseEntity
                 .status(HttpStatus.OK)
                 .body(new ResultMessage()

+ 197 - 0
src/main/java/com/shawn/web/controller/TSignController.java

@@ -0,0 +1,197 @@
+/**
+ * Date:2019-12-25 11:12:55
+ * author:吴洪双
+*/
+
+package com.shawn.web.controller;
+
+import com.alibaba.fastjson.JSONObject;
+import com.shawn.model.Bean.SignBean;
+import com.shawn.model.dto.ResultMessage;
+import com.shawn.model.entity.*;
+import com.shawn.model.param.TSignParam;
+import com.shawn.model.param.TWeixinParam;
+import com.shawn.service.interfac.TAdminServiceInterface;
+import com.shawn.service.interfac.TEquipmentServiceInterface;
+import com.shawn.service.interfac.TSignServiceInterface;
+import com.shawn.service.interfac.TWeixinServiceInterface;
+import com.shawn.util.JavaWebToken;
+import com.shawn.util.PushUtils;
+import com.shawn.util.WeChatUtil;
+import com.shawn.web.controller.base.BaseController;
+import com.shawn.web.exception.MyException;
+import lombok.extern.apachecommons.CommonsLog;
+import org.apache.commons.lang.StringUtils;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.http.HttpStatus;
+import org.springframework.http.ResponseEntity;
+import org.springframework.web.bind.annotation.*;
+
+import java.text.ParseException;
+import java.text.SimpleDateFormat;
+import java.util.*;
+
+//import com.paytm.pg.merchant.CheckSumServiceHelper;
+
+@CommonsLog
+@RestController
+@RequestMapping("TSign")
+public class TSignController extends BaseController<TSign,TSignExample,TSignParam,Integer>{
+	@Autowired
+	private TWeixinServiceInterface tWeixinService;
+	@Autowired
+	public TSignController(TSignServiceInterface service) {
+		super(service);
+	}
+    @Autowired
+    private TSignServiceInterface tSignService;
+    @Autowired
+    private TAdminServiceInterface tAdminService;
+    @Autowired
+    private TEquipmentServiceInterface tEquipmentService;
+	@Override
+	protected TSignExample createNewExample() {
+		return new TSignExample();
+	}
+    /**
+     * 签到
+     * @param
+     * @return
+     */
+    @GetMapping("/sign")
+    public ResponseEntity<?> sign(String code,String openId) {
+        if(StringUtils.isEmpty(code)){
+            return ResponseEntity.status(HttpStatus.OK)
+                    .body(new ResultMessage().setCode(false).setData("").setMessage("扫码错误,请重扫!"));
+        }
+        if(StringUtils.isEmpty(openId)){
+            return ResponseEntity.status(HttpStatus.OK)
+                    .body(new ResultMessage().setCode(false).setData("").setMessage("微信登录才能打卡!"));
+        }
+        TWeixin weixin = new TWeixin();
+        weixin.setOpenId(openId);
+        TWeixin tWeixin = tWeixinService.findByEntity(weixin);
+        if(StringUtils.isEmpty(tWeixin.getOpenId())){
+            return ResponseEntity.status(HttpStatus.OK)
+                    .body(new ResultMessage().setCode(false).setData("").setMessage("请重新退出并用微信登录!"));
+        }
+        if(StringUtils.isEmpty(tWeixin.getWorkName())){
+            return ResponseEntity.status(HttpStatus.OK)
+                    .body(new ResultMessage().setCode(false).setData("").setMessage("请完善用户名!"));
+        }
+        TSign sign = new TSign();
+        sign.setCode(code);
+        TSign tSign = tSignService.findByEntity(sign);
+        if(StringUtils.isEmpty(tSign.getCode())){
+            return ResponseEntity.status(HttpStatus.OK)
+                    .body(new ResultMessage().setCode(false).setData("").setMessage("扫码错误,请重扫!!"));
+        }
+        if(tSign.getStatus().equals("1")){
+            return ResponseEntity.status(HttpStatus.OK)
+                    .body(new ResultMessage().setCode(false).setData("").setMessage("该二维码已被签到,请重新生成"));
+        }
+        String si1gn = String.valueOf(tSign.getAdminId());
+        if(si1gn.equals(tWeixin.getAdminId())){
+            tSign.setWeixinId(Long.valueOf(tWeixin.getId()));
+            tSign.setPayDate(new Date());
+            tSign.setWorkName(tWeixin.getWorkName());
+            tSign.setStatus("1");
+            tSignService.updateById(tSign);
+            String clientId = tSign.getClientId();
+            TEquipmentExample example = new TEquipmentExample();
+            TEquipmentExample.Criteria criteria = example.createCriteria();
+            criteria.andClientIdEqualTo(clientId);
+            List<TEquipment> tEquipments = tEquipmentService.selectByOption(example);
+            if(tEquipments.size()>0){
+                TEquipment equipment = tEquipments.get(0);
+                PushUtils.push(equipment.getGtClientId(), "", "", PushUtils.buildJson("signed", code).toString());
+            }
+
+        }else{
+            return ResponseEntity.status(HttpStatus.OK)
+                    .body(new ResultMessage().setCode(false).setData("").setMessage("您不是这机器下的员工"));
+        }
+        return ResponseEntity.status(HttpStatus.OK)
+                .body(new ResultMessage().setCode(true).setData("").setMessage("SUCCESS"));
+
+    }
+    /**
+     * 获取签到记录
+     * @param
+     * @return
+     */
+    @GetMapping("/getSignList")
+    public ResponseEntity<?> getSignList(String workName,String openId,String clientId,String startDate,String endDate) throws ParseException {
+        if(StringUtils.isEmpty(openId)){
+            return ResponseEntity.status(HttpStatus.OK)
+                    .body(new ResultMessage().setCode(false).setData(null).setMessage("请绑定微信"));
+        }
+        if(workName.equals("0")){
+            workName = "0";
+        }
+        SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");//注意月份是MM
+        Date start = simpleDateFormat.parse(startDate);
+        Date end = simpleDateFormat.parse(endDate);
+        //获取微信信息
+        TWeixinExample example = new TWeixinExample();
+        TWeixinExample.Criteria criteria = example.createCriteria();
+        criteria.andOpenIdEqualTo(openId);
+        List<TWeixin> tWeixins = tWeixinService.selectByOption(example);
+        if(tWeixins.size()>0){
+            TWeixin weixin = tWeixins.get(0);
+            int le = Integer.parseInt(weixin.getLevel());
+            String adminId = weixin.getAdminId();
+            TSignExample tSignExample = new TSignExample();
+            TSignExample.Criteria criteria2 = tSignExample.createCriteria();
+            criteria2.andAdminIdEqualTo(Long.valueOf(adminId));
+            if(le<2){
+                if(!workName.equals("0")){
+                    criteria2.andWeixinIdEqualTo(Long.valueOf(weixin.getId()));
+                }
+                if(!clientId.equals("0")){
+                    criteria2.andClientIdEqualTo(clientId);
+                }
+            }
+            if(le>=2){
+                criteria2.andWeixinIdEqualTo(Long.valueOf(weixin.getId()));
+                if(!clientId.equals("0")){
+                    criteria2.andClientIdEqualTo(clientId);
+                }
+            }
+            criteria2.andStatusEqualTo("1");
+            criteria2.andPayDateGreaterThanOrEqualTo(start);
+            criteria2.andPayDateLessThanOrEqualTo(end);
+            List<TSign> tSigns = tSignService.selectByOption(tSignExample);
+            if(tSigns.size()>0){
+                List<SignBean> signBeanList = new ArrayList<>();
+                for(int i = 0; i < tSigns.size();i++){
+                    SignBean signBean = new SignBean();
+                    String clientId1 = tSigns.get(i).getClientId();
+                    TEquipmentExample tEquipmentExample = new TEquipmentExample();
+                    TEquipmentExample.Criteria criteria3 = tEquipmentExample.createCriteria();
+                    criteria3.andClientIdEqualTo(clientId1);
+                    List<TEquipment> tEquipments = tEquipmentService.selectByOption(tEquipmentExample);
+                    if(tEquipments.size()>0){
+                        String name = tEquipments.get(0).getName();
+                        signBean.setTitle(tSigns.get(i).getWorkName()+" "+name+" 设备编号:"+clientId1.substring(clientId1.length()-6,clientId1.length()));
+                    }else{
+                        break;
+                    }
+                    SimpleDateFormat formatter = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
+                    String date = formatter.format(tSigns.get(i).getPayDate());
+                    signBean.setDesc("签到时间:"+date);
+                    signBeanList.add(signBean);
+                }
+                return ResponseEntity.status(HttpStatus.OK)
+                        .body(new ResultMessage().setCode(true).setData(signBeanList).setMessage("SUCCESS"));
+            }else{
+                return ResponseEntity.status(HttpStatus.OK)
+                        .body(new ResultMessage().setCode(false).setData(null).setMessage("该时间段内无记录"));
+            }
+        }else {
+            return ResponseEntity.status(HttpStatus.OK)
+                    .body(new ResultMessage().setCode(false).setData(null).setMessage("没有绑定微信"));
+        }
+
+    }
+}

+ 71 - 2
src/main/java/com/shawn/web/controller/TWeixinController.java

@@ -80,8 +80,10 @@ public class TWeixinController extends BaseController<TWeixin,TWeixinExample,TWe
                     m.put("userId",list.get(0).getId());
                     // 根据存在用户的id生成token字符串
                     String token = JavaWebToken.createJavaWebToken(m);
+                    TAdmin admin = list.get(0);
+                    admin.setLevel(tWeixin.getLevel());
                     return ResponseEntity.status(HttpStatus.OK)
-                            .body(new ResultMessage().setCode(true).setData(list.get(0)).setMessage("SUCCESS").setToken(token));
+                            .body(new ResultMessage().setCode(true).setData(admin).setMessage("SUCCESS").setToken(token));
                 }
             }
         }else {
@@ -107,7 +109,9 @@ public class TWeixinController extends BaseController<TWeixin,TWeixinExample,TWe
         TAdminExample example = new TAdminExample();
         TAdminExample.Criteria criteria = example.createCriteria();
         criteria.andUsernameEqualTo(weiXin.getUsername());
-        criteria.andPasswordEqualTo(weiXin.getPassword());
+        if(!weiXin.getLevel().equals("3")){
+            criteria.andPasswordEqualTo(weiXin.getPassword());
+        }
         List<TAdmin> list = tAdminService.selectByOption(example);
         if(list.size()>0){
             Long adminId = list.get(0).getId();
@@ -117,6 +121,8 @@ public class TWeixinController extends BaseController<TWeixin,TWeixinExample,TWe
             newWeixin.setNickName(weiXin.getNickName());
             newWeixin.setAvatarUrl(weiXin.getAvatarUrl());
             newWeixin.setOpenId(weiXin.getOpenId());
+            newWeixin.setLevel(weiXin.getLevel());
+            newWeixin.setWorkName(weiXin.getWorkName());
             newWeixin.setCreateDate(new Date());
             newWeixin.setModifyDate(new Date());
             Integer integer = tWeixinService.insert(newWeixin);
@@ -149,7 +155,70 @@ public class TWeixinController extends BaseController<TWeixin,TWeixinExample,TWe
                     .body(new ResultMessage().setCode(true).setData(null).setMessage("没有绑定微信"));
         }
     }
+    /**
+     * 修改微信信息
+     * @param
+     * @return
+     */
+    @PostMapping("/updateWeixin")
+    public ResponseEntity<?> updateWeixin(String id,String workName) {
+        if(StringUtils.isEmpty(id)){
+            return ResponseEntity.status(HttpStatus.OK)
+                    .body(new ResultMessage().setCode(true).setData(null).setMessage("修改失败"));
+        }
+        if(StringUtils.isEmpty(workName)){
+            return ResponseEntity.status(HttpStatus.OK)
+                    .body(new ResultMessage().setCode(true).setData(null).setMessage("名称不为空"));
+        }
+        TWeixinExample example = new TWeixinExample();
+        TWeixinExample.Criteria criteria = example.createCriteria();
+        criteria.andIdEqualTo(Integer.valueOf(id));
+        List<TWeixin> tWeixins = tWeixinService.selectByOption(example);
+        if(tWeixins.size()>0){
+            TWeixin weixin = tWeixins.get(0);
+            weixin.setWorkName(workName);
+            tWeixinService.updateById(weixin);
+            return ResponseEntity.status(HttpStatus.OK)
+                    .body(new ResultMessage().setCode(true).setData(null).setMessage("修改成功"));
+        }else {
+            return ResponseEntity.status(HttpStatus.OK)
+                    .body(new ResultMessage().setCode(true).setData(null).setMessage("修改失败"));
+        }
+    }
+    /**
+     * 微信列表
+     * @param
+     * @return
+     */
+    @GetMapping("/getWeixinList")
+    public ResponseEntity<?> getWeixinList(String openId) {
+        TWeixinExample example = new TWeixinExample();
+        TWeixinExample.Criteria criteria = example.createCriteria();
+        criteria.andOpenIdEqualTo(openId);
+        List<TWeixin> tWeixins = tWeixinService.selectByOption(example);
+        if(tWeixins.size()>0){
+            TWeixin weixin = tWeixins.get(0);
+            int le = Integer.parseInt(weixin.getLevel());
+            if(le<2){
+                TWeixinExample example2 = new TWeixinExample();
+                TWeixinExample.Criteria criteria2 = example2.createCriteria();
+                criteria2.andAdminIdEqualTo(weixin.getAdminId());
+                List<TWeixin> tWeixins2 = tWeixinService.selectByOption(example2);
+                return ResponseEntity.status(HttpStatus.OK)
+                        .body(new ResultMessage().setCode(true).setData(tWeixins2).setMessage("SUCCESS"));
+            }
+            if(le>=2){
+                return ResponseEntity.status(HttpStatus.OK)
+                        .body(new ResultMessage().setCode(true).setData(tWeixins).setMessage("SUCCESS"));
+            }
 
+        }else {
+            return ResponseEntity.status(HttpStatus.OK)
+                    .body(new ResultMessage().setCode(false).setData(null).setMessage("没有绑定微信"));
+        }
+        return ResponseEntity.status(HttpStatus.OK)
+                .body(new ResultMessage().setCode(true).setData(null).setMessage("SUCCESS"));
+    }
     /**
      * 解除微信绑定
      * @param

+ 10 - 3
src/main/resources/application.properties

@@ -20,9 +20,16 @@ mybatis.type-aliases-package=com.shawn.model
 swagger.enable=true
 
 spring.datasource.driver-class-name=com.mysql.jdbc.Driver
-spring.datasource.url=jdbc:mysql://47.112.127.131:3306/clean_machine?characterEncoding=utf-8&useSSL=false
-spring.datasource.username=hboxs
-spring.datasource.password=hboxs@mysql
+#spring.datasource.url=jdbc:mysql://47.112.127.131:3306/clean_machine?characterEncoding=utf-8&useSSL=false
+#spring.datasource.username=hboxs
+#spring.datasource.password=hboxs@mysql
+## RDS连接库                            rm-wz995mu26a1479kz0.mysql.rds.aliyuncs.com
+#内网
+spring.datasource.url=jdbc:mysql://rm-wz995mu26a1479kz0.mysql.rds.aliyuncs.com:3306/clean_machine?characterEncoding=utf-8&useSSL=false
+#公网
+#spring.datasource.url=jdbc:mysql://rm-wz995mu26a1479kz0so.mysql.rds.aliyuncs.com:3306/mianhuatang?characterEncoding=utf-8&useSSL=false
+spring.datasource.username=root
+spring.datasource.password=sunzee@020
 #spring.datasource.url=jdbc:mysql://127.0.0.1:3306/clean_machine?characterEncoding=utf-8&useSSL=false
 #spring.datasource.username=root
 #spring.datasource.password=123456

+ 330 - 0
src/main/resources/com/shawn/repository/mybatis/TSignMapper.xml

@@ -0,0 +1,330 @@
+<?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="com.shawn.repository.TSignMapper">
+  <resultMap id="BaseResultMap" type="com.shawn.model.entity.TSign">
+    <id column="id" jdbcType="INTEGER" property="id" />
+    <result column="admin_id" jdbcType="VARCHAR" property="adminId" />
+    <result column="client_id" jdbcType="VARCHAR" property="clientId" />
+    <result column="create_date" jdbcType="TIMESTAMP" property="createDate" />
+    <result column="pay_date" jdbcType="TIMESTAMP" property="payDate" />
+    <result column="modify_date" jdbcType="TIMESTAMP" property="modifyDate" />
+    <result column="code" jdbcType="VARCHAR" property="code" />
+    <result column="status" jdbcType="VARCHAR" property="status" />
+    <result column="work_name" jdbcType="VARCHAR" property="workName" />
+    <result column="weixin_id" jdbcType="INTEGER" property="weixinId" />
+  </resultMap>
+  <sql id="Example_Where_Clause">
+    <where>
+      <foreach collection="oredCriteria" item="criteria" separator="or">
+        <if test="criteria.valid">
+          <trim prefix="(" prefixOverrides="and" suffix=")">
+            <foreach collection="criteria.criteria" item="criterion">
+              <choose>
+                <when test="criterion.noValue">
+                  and ${criterion.condition}
+                </when>
+                <when test="criterion.singleValue">
+                  and ${criterion.condition} #{criterion.value}
+                </when>
+                <when test="criterion.betweenValue">
+                  and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
+                </when>
+                <when test="criterion.listValue">
+                  and ${criterion.condition}
+                  <foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
+                    #{listItem}
+                  </foreach>
+                </when>
+              </choose>
+            </foreach>
+          </trim>
+        </if>
+      </foreach>
+    </where>
+  </sql>
+  <sql id="Update_By_Example_Where_Clause">
+    <where>
+      <foreach collection="example.oredCriteria" item="criteria" separator="or">
+        <if test="criteria.valid">
+          <trim prefix="(" prefixOverrides="and" suffix=")">
+            <foreach collection="criteria.criteria" item="criterion">
+              <choose>
+                <when test="criterion.noValue">
+                  and ${criterion.condition}
+                </when>
+                <when test="criterion.singleValue">
+                  and ${criterion.condition} #{criterion.value}
+                </when>
+                <when test="criterion.betweenValue">
+                  and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
+                </when>
+                <when test="criterion.listValue">
+                  and ${criterion.condition}
+                  <foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
+                    #{listItem}
+                  </foreach>
+                </when>
+              </choose>
+            </foreach>
+          </trim>
+        </if>
+      </foreach>
+    </where>
+  </sql>
+  <sql id="Base_Column_List">
+    id, admin_id, weixin_id, create_date, modify_date, status, pay_date,work_name,client_id,code
+  </sql>
+  <select id="selectByExample" parameterType="com.shawn.model.entity.TSignExample" resultMap="BaseResultMap">
+    select
+    <if test="distinct">
+      distinct
+    </if>
+    <include refid="Base_Column_List" />
+    from t_sign
+    <if test="_parameter != null">
+      <include refid="Example_Where_Clause" />
+    </if>
+    <if test="orderByClause != null">
+      order by ${orderByClause}
+    </if>
+    <if test="limit != null">
+      <if test="offset != null">
+        limit ${offset}, ${limit}
+      </if>
+      <if test="offset == null">
+        limit ${limit}
+      </if>
+    </if>
+  </select>
+  <select id="selectByPrimaryKey" parameterType="java.lang.Integer" resultMap="BaseResultMap">
+    select 
+    <include refid="Base_Column_List" />
+    from t_sign
+    where id = #{id,jdbcType=INTEGER}
+  </select>
+  <select id="findByEntity" parameterType="com.shawn.model.entity.TSign" resultMap="BaseResultMap">
+    select
+    <include refid="Base_Column_List" />
+    from t_sign
+    where code = #{code,jdbcType=VARCHAR}
+  </select>
+  <delete id="deleteByPrimaryKey" parameterType="java.lang.Integer">
+    delete from t_sign
+    where id = #{id,jdbcType=INTEGER}
+  </delete>
+  <delete id="deleteByExample" parameterType="com.shawn.model.entity.TSignExample">
+    delete from t_sign
+    <if test="_parameter != null">
+      <include refid="Example_Where_Clause" />
+    </if>
+  </delete>
+  <insert id="insert" parameterType="com.shawn.model.entity.TSign">
+    insert into t_sign (id, admin_id, weixin_id,
+      create_date, modify_date, pay_date,
+      status,work_name,client_id)
+    values (#{id,jdbcType=INTEGER}, #{adminId,jdbcType=VARCHAR}, #{clientId,jdbcType=VARCHAR},
+      #{createDate,jdbcType=TIMESTAMP}, #{modifyDate,jdbcType=TIMESTAMP}, #{payDate,jdbcType=TIMESTAMP},
+      #{status,jdbcType=VARCHAR},#{workName,jdbcType=VARCHAR},#{clientId,jdbcType=VARCHAR})
+  </insert>
+  <insert id="insertSelective" parameterType="com.shawn.model.entity.TSign">
+    insert into t_sign
+    <trim prefix="(" suffix=")" suffixOverrides=",">
+      <if test="id != null">
+        id,
+      </if>
+      <if test="adminId != null">
+        admin_id,
+      </if>
+      <if test="openId != null">
+        open_id,
+      </if>
+      <if test="createDate != null">
+        create_date,
+      </if>
+      <if test="modifyDate != null">
+        modify_date,
+      </if>
+      <if test="nickName != null">
+        nick_name,
+      </if>
+      <if test="avatarUrl != null">
+        avatar_url,
+      </if>
+      <if test="workName != null">
+        work_name,
+      </if>
+      <if test="level != null">
+        level,
+      </if>
+    </trim>
+    <trim prefix="values (" suffix=")" suffixOverrides=",">
+      <if test="id != null">
+        #{id,jdbcType=INTEGER},
+      </if>
+      <if test="adminId != null">
+        #{adminId,jdbcType=VARCHAR},
+      </if>
+      <if test="openId != null">
+        #{openId,jdbcType=VARCHAR},
+      </if>
+      <if test="createDate != null">
+        #{createDate,jdbcType=TIMESTAMP},
+      </if>
+      <if test="modifyDate != null">
+        #{modifyDate,jdbcType=TIMESTAMP},
+      </if>
+      <if test="nickName != null">
+        #{nickName,jdbcType=VARCHAR},
+      </if>
+      <if test="avatarUrl != null">
+        #{avatarUrl,jdbcType=VARCHAR},
+      </if>
+      <if test="workName != null">
+        #{workName,jdbcType=VARCHAR},
+      </if>
+      <if test="level != null">
+        #{level,jdbcType=VARCHAR},
+      </if>
+    </trim>
+  </insert>
+  <select id="countByExample" parameterType="com.shawn.model.entity.TSignExample" resultType="java.lang.Long">
+    select count(*) from t_sign
+    <if test="_parameter != null">
+      <include refid="Example_Where_Clause" />
+    </if>
+  </select>
+  <update id="updateByExampleSelective" parameterType="map">
+    update t_sign
+    <set>
+      <if test="record.id != null">
+        id = #{record.id,jdbcType=INTEGER},
+      </if>
+      <if test="record.adminId != null">
+        admin_id = #{record.adminId,jdbcType=VARCHAR},
+      </if>
+      <if test="record.weixinId != null">
+        weixin_id = #{record.weixinId,jdbcType=INTEGER},
+      </if>
+      <if test="record.createDate != null">
+        create_date = #{record.createDate,jdbcType=TIMESTAMP},
+      </if>
+      <if test="record.modifyDate != null">
+        modify_date = #{record.modifyDate,jdbcType=TIMESTAMP},
+      </if>
+      <if test="record.payDate != null">
+        pay_date = #{record.payDate,jdbcType=TIMESTAMP},
+      </if>
+      <if test="record.status != null">
+        status = #{record.status,jdbcType=VARCHAR},
+      </if>
+      <if test="record.clientId != null">
+        client_id = #{record.clientId,jdbcType=VARCHAR},
+      </if>
+      <if test="record.workName != null">
+        work_name = #{record.workName,jdbcType=VARCHAR},
+      </if>
+    </set>
+    <if test="_parameter != null">
+      <include refid="Update_By_Example_Where_Clause" />
+    </if>
+  </update>
+  <update id="updateByExample" parameterType="map">
+    update t_sign
+    set id = #{record.id,jdbcType=INTEGER},
+      admin_id = #{record.adminId,jdbcType=VARCHAR},
+    weixin_id = #{record.weixinId,jdbcType=INTEGER},
+      create_date = #{record.createDate,jdbcType=TIMESTAMP},
+      modify_date = #{record.modifyDate,jdbcType=TIMESTAMP},
+    pay_date = #{record.payDate,jdbcType=TIMESTAMP},
+    status = #{record.status,jdbcType=VARCHAR},
+    client_id = #{record.clientId,jdbcType=VARCHAR},
+    work_name = #{record.workName,jdbcType=VARCHAR}
+    <if test="_parameter != null">
+      <include refid="Update_By_Example_Where_Clause" />
+    </if>
+  </update>
+  <update id="updateByPrimaryKeySelective" parameterType="com.shawn.model.entity.TSign">
+    update t_sign
+    <set>
+      <if test="adminId != null">
+        admin_id = #{adminId,jdbcType=VARCHAR},
+      </if>
+      <if test="payDate != null">
+        pay_date = #{payDate,jdbcType=TIMESTAMP},
+      </if>
+      <if test="createDate != null">
+        create_date = #{createDate,jdbcType=TIMESTAMP},
+      </if>
+      <if test="modifyDate != null">
+        modify_date = #{modifyDate,jdbcType=TIMESTAMP},
+      </if>
+      <if test="status != null">
+        status = #{status,jdbcType=VARCHAR},
+      </if>
+      <if test="clientId != null">
+        client_id = #{clientId,jdbcType=VARCHAR},
+      </if>
+      <if test="workName != null">
+        work_name = #{workName,jdbcType=VARCHAR},
+      </if>
+      <if test="weixinId != null">
+        weixin_id = #{weixinId,jdbcType=INTEGER},
+      </if>
+    </set>
+    where id = #{id,jdbcType=INTEGER}
+  </update>
+  <update id="updateByPrimaryKey" parameterType="com.shawn.model.entity.TSign">
+    update t_sign
+    set admin_id = #{adminId,jdbcType=VARCHAR},
+      create_date = #{createDate,jdbcType=TIMESTAMP},
+      modify_date = #{modifyDate,jdbcType=TIMESTAMP},
+      weixin_id = #{weixinId,jdbcType=INTEGER},
+    pay_date = #{payDate,jdbcType=TIMESTAMP},
+    status = #{status,jdbcType=VARCHAR},
+    client_id = #{clientId,jdbcType=VARCHAR},
+    work_name = #{workName,jdbcType=VARCHAR},
+    where id = #{id,jdbcType=INTEGER}
+  </update>
+  <insert id="insertBatch" parameterType="java.util.List">
+    insert into t_sign (id,admin_id,open_id,create_date,modify_date,nick_name,avatar_url)
+    <foreach collection="list" index="index" item="item" separator="union all">
+      select #{item.id,jdbcType=INTEGER},#{item.adminId,jdbcType=VARCHAR},#{item.openId,jdbcType=VARCHAR},#{item.createDate,jdbcType=TIMESTAMP},#{item.modifyDate,jdbcType=TIMESTAMP},#{item.nickName,jdbcType=VARCHAR},#{item.avatarUrl,jdbcType=VARCHAR} from dual
+    </foreach>
+  </insert>
+  <delete id="deleteBatchByIdList" parameterType="java.util.List">
+    DELETE FROM t_sign where id in
+    <foreach close=")" collection="list" item="item" open="(" separator=",">
+      #{item}
+    </foreach>
+  </delete>
+  <update id="updateBatchByIdList" parameterType="com.shawn.model.param.TSignParam">
+    update t_sign
+    <trim prefix="set" suffixOverrides=",">
+      <if test="id != null">
+        id = #{id},
+      </if>
+      <if test="adminId != null">
+        admin_id = #{adminId},
+      </if>
+      <if test="openId != null">
+        open_id = #{openId},
+      </if>
+      <if test="createDate != null">
+        create_date = #{createDate},
+      </if>
+      <if test="modifyDate != null">
+        modify_date = #{modifyDate},
+      </if>
+      <if test="nickName != null">
+        nick_name = #{nickName},
+      </if>
+      <if test="avatarUrl != null">
+        avatar_url = #{avatarUrl},
+      </if>
+    </trim>
+     where id in 
+    <foreach close=")" collection="primaryKeyList" item="item" open="(" separator=",">
+      #{item}
+    </foreach>
+  </update>
+</mapper>

+ 35 - 5
src/main/resources/com/shawn/repository/mybatis/TWeixinMapper.xml

@@ -9,6 +9,8 @@
     <result column="modify_date" jdbcType="TIMESTAMP" property="modifyDate" />
     <result column="nick_name" jdbcType="VARCHAR" property="nickName" />
     <result column="avatar_url" jdbcType="VARCHAR" property="avatarUrl" />
+    <result column="work_name" jdbcType="VARCHAR" property="workName" />
+    <result column="level" jdbcType="VARCHAR" property="level" />
   </resultMap>
   <sql id="Example_Where_Clause">
     <where>
@@ -69,7 +71,7 @@
     </where>
   </sql>
   <sql id="Base_Column_List">
-    id, admin_id, open_id, create_date, modify_date, nick_name, avatar_url
+    id, admin_id, open_id, create_date, modify_date, nick_name, avatar_url,work_name,level
   </sql>
   <select id="selectByExample" parameterType="com.shawn.model.entity.TWeixinExample" resultMap="BaseResultMap">
     select
@@ -118,10 +120,10 @@
   <insert id="insert" parameterType="com.shawn.model.entity.TWeixin">
     insert into t_weixin (id, admin_id, open_id, 
       create_date, modify_date, nick_name, 
-      avatar_url)
+      avatar_url,work_name,level)
     values (#{id,jdbcType=INTEGER}, #{adminId,jdbcType=VARCHAR}, #{openId,jdbcType=VARCHAR}, 
       #{createDate,jdbcType=TIMESTAMP}, #{modifyDate,jdbcType=TIMESTAMP}, #{nickName,jdbcType=VARCHAR}, 
-      #{avatarUrl,jdbcType=VARCHAR})
+      #{avatarUrl,jdbcType=VARCHAR},#{workName,jdbcType=VARCHAR},#{level,jdbcType=VARCHAR})
   </insert>
   <insert id="insertSelective" parameterType="com.shawn.model.entity.TWeixin">
     insert into t_weixin
@@ -147,6 +149,12 @@
       <if test="avatarUrl != null">
         avatar_url,
       </if>
+      <if test="workName != null">
+        work_name,
+      </if>
+      <if test="level != null">
+        level,
+      </if>
     </trim>
     <trim prefix="values (" suffix=")" suffixOverrides=",">
       <if test="id != null">
@@ -170,6 +178,12 @@
       <if test="avatarUrl != null">
         #{avatarUrl,jdbcType=VARCHAR},
       </if>
+      <if test="workName != null">
+        #{workName,jdbcType=VARCHAR},
+      </if>
+      <if test="level != null">
+        #{level,jdbcType=VARCHAR},
+      </if>
     </trim>
   </insert>
   <select id="countByExample" parameterType="com.shawn.model.entity.TWeixinExample" resultType="java.lang.Long">
@@ -202,6 +216,12 @@
       <if test="record.avatarUrl != null">
         avatar_url = #{record.avatarUrl,jdbcType=VARCHAR},
       </if>
+      <if test="record.workName != null">
+        work_name = #{record.workName,jdbcType=VARCHAR},
+      </if>
+      <if test="record.level != null">
+        level = #{record.level,jdbcType=VARCHAR},
+      </if>
     </set>
     <if test="_parameter != null">
       <include refid="Update_By_Example_Where_Clause" />
@@ -215,7 +235,9 @@
       create_date = #{record.createDate,jdbcType=TIMESTAMP},
       modify_date = #{record.modifyDate,jdbcType=TIMESTAMP},
       nick_name = #{record.nickName,jdbcType=VARCHAR},
-      avatar_url = #{record.avatarUrl,jdbcType=VARCHAR}
+      avatar_url = #{record.avatarUrl,jdbcType=VARCHAR},
+    work_name = #{record.workName,jdbcType=VARCHAR},
+    level = #{record.level,jdbcType=VARCHAR}
     <if test="_parameter != null">
       <include refid="Update_By_Example_Where_Clause" />
     </if>
@@ -241,6 +263,12 @@
       <if test="avatarUrl != null">
         avatar_url = #{avatarUrl,jdbcType=VARCHAR},
       </if>
+      <if test="workName != null">
+        work_name = #{workName,jdbcType=VARCHAR},
+      </if>
+      <if test="level != null">
+        level = #{level,jdbcType=VARCHAR},
+      </if>
     </set>
     where id = #{id,jdbcType=INTEGER}
   </update>
@@ -251,7 +279,9 @@
       create_date = #{createDate,jdbcType=TIMESTAMP},
       modify_date = #{modifyDate,jdbcType=TIMESTAMP},
       nick_name = #{nickName,jdbcType=VARCHAR},
-      avatar_url = #{avatarUrl,jdbcType=VARCHAR}
+      avatar_url = #{avatarUrl,jdbcType=VARCHAR},
+    work_name = #{workName,jdbcType=VARCHAR},
+    level = #{level,jdbcType=VARCHAR},
     where id = #{id,jdbcType=INTEGER}
   </update>
   <insert id="insertBatch" parameterType="java.util.List">