Commit 93c2722f by xmh

完成代码生成,完成feign调试

1 parent bae0b47e
Showing 152 changed files with 3706 additions and 194 deletions
......@@ -11,7 +11,7 @@
</parent>
<artifactId>fanxing-code</artifactId>
<version>3.0.0-SNAPSHOT</version>
<version>${project.parent.version}</version>
<dependencies>
<dependency>
......@@ -31,33 +31,6 @@
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-starter-consul-config</artifactId>
</dependency>
<dependency>
<groupId>org.mybatis.spring.boot</groupId>
<artifactId>mybatis-spring-boot-starter</artifactId>
<version>2.1.4</version>
<exclusions>
<exclusion>
<artifactId>mybatis</artifactId>
<groupId>org.mybatis</groupId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>com.github.pagehelper</groupId>
<artifactId>pagehelper-spring-boot-starter</artifactId>
<version>1.2.3</version>
<exclusions>
<exclusion>
<artifactId>mybatis-spring-boot-starter</artifactId>
<groupId>org.mybatis.spring.boot</groupId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>org.mybatis</groupId>
<artifactId>mybatis</artifactId>
<version>3.5.2</version>
</dependency>
</dependencies>
<build>
......
package com.viontech.fanxing.code.controller.base;
import com.viontech.fanxing.code.base.BaseController;
import com.viontech.fanxing.code.base.BaseExample;
import com.viontech.fanxing.code.base.BaseMapper;
import com.viontech.fanxing.code.base.BaseService;
import com.viontech.fanxing.code.mapper.DictCateMapper;
import com.viontech.fanxing.code.model.DictCate;
import com.viontech.fanxing.code.model.DictCateExample;
import com.viontech.fanxing.commons.base.BaseController;
import com.viontech.fanxing.commons.base.BaseExample;
import com.viontech.fanxing.commons.base.BaseService;
import com.viontech.fanxing.commons.model.DictCate;
import com.viontech.fanxing.commons.model.DictCateExample;
import com.viontech.fanxing.code.service.adapter.DictCateService;
import com.viontech.fanxing.code.vo.DictCateVo;
import com.viontech.fanxing.commons.vo.DictCateVo;
import javax.annotation.Resource;
public abstract class DictCateBaseController extends BaseController<DictCate, DictCateVo> {
......
package com.viontech.fanxing.code.controller.base;
import com.viontech.fanxing.code.mapper.DictCodeMapper;
import com.viontech.fanxing.code.model.DictCode;
import com.viontech.fanxing.code.model.DictCodeExample;
import com.viontech.fanxing.commons.model.DictCode;
import com.viontech.fanxing.commons.model.DictCodeExample;
import com.viontech.fanxing.code.service.adapter.DictCodeService;
import com.viontech.fanxing.code.vo.DictCodeVo;
import com.viontech.fanxing.code.base.BaseController;
import com.viontech.fanxing.code.base.BaseExample;
import com.viontech.fanxing.code.base.BaseMapper;
import com.viontech.fanxing.code.base.BaseService;
import com.viontech.fanxing.commons.vo.DictCodeVo;
import com.viontech.fanxing.commons.base.BaseController;
import com.viontech.fanxing.commons.base.BaseExample;
import com.viontech.fanxing.commons.base.BaseService;
import javax.annotation.Resource;
public abstract class DictCodeBaseController extends BaseController<DictCode, DictCodeVo> {
......
package com.viontech.fanxing.code.controller.web;
import com.viontech.fanxing.code.base.BaseExample;
import com.viontech.fanxing.code.model.DictCateExample;
import com.viontech.fanxing.code.vo.DictCateVo;
import com.viontech.fanxing.commons.base.BaseExample;
import com.viontech.fanxing.commons.model.DictCateExample;
import com.viontech.fanxing.commons.vo.DictCateVo;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import com.viontech.fanxing.code.controller.base.DictCateBaseController;
......
package com.viontech.fanxing.code.controller.web;
import com.viontech.fanxing.code.base.BaseExample;
import com.viontech.fanxing.commons.base.BaseExample;
import com.viontech.fanxing.code.controller.base.DictCodeBaseController;
import com.viontech.fanxing.code.model.DictCode;
import com.viontech.fanxing.code.model.DictCodeExample;
import com.viontech.fanxing.code.vo.DictCodeVo;
import com.viontech.fanxing.commons.model.DictCode;
import com.viontech.fanxing.commons.model.DictCodeExample;
import com.viontech.fanxing.commons.vo.DictCodeVo;
import com.viontech.keliu.util.JsonMessageUtil;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Controller;
......
package com.viontech.fanxing.code.mapper;
import com.viontech.fanxing.code.base.BaseMapper;
import com.viontech.fanxing.code.model.DictCate;
import com.viontech.fanxing.code.model.DictCateExample;
import com.viontech.fanxing.commons.base.BaseMapper;
import com.viontech.fanxing.commons.model.DictCate;
import com.viontech.fanxing.commons.model.DictCateExample;
import java.util.List;
import org.apache.ibatis.annotations.Param;
......
package com.viontech.fanxing.code.mapper;
import com.viontech.fanxing.code.base.BaseMapper;
import com.viontech.fanxing.code.model.DictCode;
import com.viontech.fanxing.code.model.DictCodeExample;
import com.viontech.fanxing.commons.base.BaseMapper;
import com.viontech.fanxing.commons.model.DictCode;
import com.viontech.fanxing.commons.model.DictCodeExample;
import java.util.List;
import org.apache.ibatis.annotations.Param;
......
<?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.viontech.fanxing.code.mapper.DictCateMapper" >
<resultMap id="BaseResultMapRoot" type="com.viontech.fanxing.code.model.DictCate" >
<resultMap id="BaseResultMapRoot" type="com.viontech.fanxing.commons.model.DictCate" >
<id column="dictCate_id" property="id" />
<result column="dictCate_unid" property="unid" />
<result column="dictCate_code" property="code" />
......@@ -9,7 +9,7 @@
<result column="dictCate_note" property="note" />
<result column="dictCate_type" property="type" />
</resultMap>
<resultMap id="BaseResultMap" type="com.viontech.fanxing.code.model.DictCate" extends="BaseResultMapRoot" />
<resultMap id="BaseResultMap" type="com.viontech.fanxing.commons.model.DictCate" extends="BaseResultMapRoot" />
<sql id="Example_Where_Clause" >
<where >
<foreach collection="oredCriteria" item="criteria" separator="or" >
......@@ -91,7 +91,7 @@
</foreach>
</if>
</sql>
<select id="selectByExample" resultMap="BaseResultMap" parameterType="com.viontech.fanxing.code.model.DictCateExample" >
<select id="selectByExample" resultMap="BaseResultMap" parameterType="com.viontech.fanxing.commons.model.DictCateExample" >
select
<if test="distinct" >
distinct
......@@ -118,19 +118,19 @@
delete from `s_dict_cate` `dictCate`
where id = #{id,jdbcType=BIGINT}
</delete>
<delete id="deleteByExample" parameterType="com.viontech.fanxing.code.model.DictCateExample" >
<delete id="deleteByExample" parameterType="com.viontech.fanxing.commons.model.DictCateExample" >
delete from `s_dict_cate` `dictCate`
<if test="_parameter != null" >
<include refid="Example_Where_Clause" />
</if>
</delete>
<insert id="insert" parameterType="com.viontech.fanxing.code.model.DictCate" useGeneratedKeys="true" keyProperty="id" keyColumn="id" >
<insert id="insert" parameterType="com.viontech.fanxing.commons.model.DictCate" useGeneratedKeys="true" keyProperty="id" keyColumn="id" >
insert into `s_dict_cate` (unid, code, `name`,
note, `type`)
values (#{unid,jdbcType=VARCHAR}, #{code,jdbcType=VARCHAR}, #{name,jdbcType=VARCHAR},
#{note,jdbcType=VARCHAR}, #{type,jdbcType=VARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.viontech.fanxing.code.model.DictCate" useGeneratedKeys="true" keyProperty="id" keyColumn="id" >
<insert id="insertSelective" parameterType="com.viontech.fanxing.commons.model.DictCate" useGeneratedKeys="true" keyProperty="id" keyColumn="id" >
insert into `s_dict_cate`
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="unid != null" >
......@@ -167,7 +167,7 @@
</if>
</trim>
</insert>
<select id="countByExample" parameterType="com.viontech.fanxing.code.model.DictCateExample" resultType="java.lang.Integer" >
<select id="countByExample" parameterType="com.viontech.fanxing.commons.model.DictCateExample" resultType="java.lang.Integer" >
select count(*) from `s_dict_cate` `dictCate`
<if test="_parameter != null" >
<include refid="Example_Where_Clause" />
......@@ -211,7 +211,7 @@
<include refid="Update_By_Example_Where_Clause" />
</if>
</update>
<update id="updateByPrimaryKeySelective" parameterType="com.viontech.fanxing.code.model.DictCate" >
<update id="updateByPrimaryKeySelective" parameterType="com.viontech.fanxing.commons.model.DictCate" >
update `s_dict_cate`
<set >
<if test="unid != null" >
......@@ -232,7 +232,7 @@
</set>
where id = #{id,jdbcType=BIGINT}
</update>
<update id="updateByPrimaryKey" parameterType="com.viontech.fanxing.code.model.DictCate" >
<update id="updateByPrimaryKey" parameterType="com.viontech.fanxing.commons.model.DictCate" >
update `s_dict_cate`
set unid = #{unid,jdbcType=VARCHAR},
code = #{code,jdbcType=VARCHAR},
......
<?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.viontech.fanxing.code.mapper.DictCodeMapper" >
<resultMap id="BaseResultMapRoot" type="com.viontech.fanxing.code.model.DictCode" >
<resultMap id="BaseResultMapRoot" type="com.viontech.fanxing.commons.model.DictCode" >
<id column="dictCode_id" property="id" />
<result column="dictCode_unid" property="unid" />
<result column="dictCode_cate_id" property="cateId" />
......@@ -10,7 +10,7 @@
<result column="dictCode_name" property="name" />
<result column="dictCode_note" property="note" />
</resultMap>
<resultMap id="BaseResultMap" type="com.viontech.fanxing.code.model.DictCode" extends="BaseResultMapRoot" />
<resultMap id="BaseResultMap" type="com.viontech.fanxing.commons.model.DictCode" extends="BaseResultMapRoot" />
<sql id="Example_Where_Clause" >
<where >
<foreach collection="oredCriteria" item="criteria" separator="or" >
......@@ -93,7 +93,7 @@
</foreach>
</if>
</sql>
<select id="selectByExample" resultMap="BaseResultMap" parameterType="com.viontech.fanxing.code.model.DictCodeExample" >
<select id="selectByExample" resultMap="BaseResultMap" parameterType="com.viontech.fanxing.commons.model.DictCodeExample" >
select
<if test="distinct" >
distinct
......@@ -120,19 +120,19 @@
delete from `s_dict_code` `dictCode`
where id = #{id,jdbcType=BIGINT}
</delete>
<delete id="deleteByExample" parameterType="com.viontech.fanxing.code.model.DictCodeExample" >
<delete id="deleteByExample" parameterType="com.viontech.fanxing.commons.model.DictCodeExample" >
delete from `s_dict_code` `dictCode`
<if test="_parameter != null" >
<include refid="Example_Where_Clause" />
</if>
</delete>
<insert id="insert" parameterType="com.viontech.fanxing.code.model.DictCode" useGeneratedKeys="true" keyProperty="id" keyColumn="id" >
<insert id="insert" parameterType="com.viontech.fanxing.commons.model.DictCode" useGeneratedKeys="true" keyProperty="id" keyColumn="id" >
insert into `s_dict_code` (unid, cate_id, parent_id,
code, `name`, note)
values (#{unid,jdbcType=VARCHAR}, #{cateId,jdbcType=BIGINT}, #{parentId,jdbcType=BIGINT},
#{code,jdbcType=VARCHAR}, #{name,jdbcType=VARCHAR}, #{note,jdbcType=VARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.viontech.fanxing.code.model.DictCode" useGeneratedKeys="true" keyProperty="id" keyColumn="id" >
<insert id="insertSelective" parameterType="com.viontech.fanxing.commons.model.DictCode" useGeneratedKeys="true" keyProperty="id" keyColumn="id" >
insert into `s_dict_code`
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="unid != null" >
......@@ -175,7 +175,7 @@
</if>
</trim>
</insert>
<select id="countByExample" parameterType="com.viontech.fanxing.code.model.DictCodeExample" resultType="java.lang.Integer" >
<select id="countByExample" parameterType="com.viontech.fanxing.commons.model.DictCodeExample" resultType="java.lang.Integer" >
select count(*) from `s_dict_code` `dictCode`
<if test="_parameter != null" >
<include refid="Example_Where_Clause" />
......@@ -223,7 +223,7 @@
<include refid="Update_By_Example_Where_Clause" />
</if>
</update>
<update id="updateByPrimaryKeySelective" parameterType="com.viontech.fanxing.code.model.DictCode" >
<update id="updateByPrimaryKeySelective" parameterType="com.viontech.fanxing.commons.model.DictCode" >
update `s_dict_code`
<set >
<if test="unid != null" >
......@@ -247,7 +247,7 @@
</set>
where id = #{id,jdbcType=BIGINT}
</update>
<update id="updateByPrimaryKey" parameterType="com.viontech.fanxing.code.model.DictCode" >
<update id="updateByPrimaryKey" parameterType="com.viontech.fanxing.commons.model.DictCode" >
update `s_dict_code`
set unid = #{unid,jdbcType=VARCHAR},
cate_id = #{cateId,jdbcType=BIGINT},
......
package com.viontech.fanxing.code.service.adapter;
import com.viontech.fanxing.code.model.DictCate;
import com.viontech.fanxing.code.base.BaseService;
import com.viontech.fanxing.commons.model.DictCate;
import com.viontech.fanxing.commons.base.BaseService;
public interface DictCateService extends BaseService<DictCate> {
}
\ No newline at end of file
package com.viontech.fanxing.code.service.adapter;
import com.viontech.fanxing.code.model.DictCode;
import com.viontech.fanxing.code.base.BaseService;
import com.viontech.fanxing.commons.model.DictCode;
import com.viontech.fanxing.commons.base.BaseService;
public interface DictCodeService extends BaseService<DictCode> {
}
\ No newline at end of file
package com.viontech.fanxing.code.service.impl;
import com.viontech.fanxing.code.mapper.DictCateMapper;
import com.viontech.fanxing.code.model.DictCate;
import com.viontech.fanxing.commons.model.DictCate;
import com.viontech.fanxing.code.service.adapter.DictCateService;
import com.viontech.fanxing.code.base.BaseMapper;
import com.viontech.fanxing.code.base.BaseServiceImpl;
import com.viontech.fanxing.commons.base.BaseMapper;
import com.viontech.fanxing.commons.base.BaseServiceImpl;
import javax.annotation.Resource;
import org.springframework.stereotype.Service;
......
package com.viontech.fanxing.code.service.impl;
import com.viontech.fanxing.code.mapper.DictCodeMapper;
import com.viontech.fanxing.code.model.DictCode;
import com.viontech.fanxing.commons.model.DictCode;
import com.viontech.fanxing.code.service.adapter.DictCodeService;
import com.viontech.fanxing.code.base.BaseMapper;
import com.viontech.fanxing.code.base.BaseServiceImpl;
import com.viontech.fanxing.commons.base.BaseMapper;
import com.viontech.fanxing.commons.base.BaseServiceImpl;
import javax.annotation.Resource;
import org.springframework.stereotype.Service;
......
......@@ -37,7 +37,7 @@ spring:
logging:
config: classpath:logback-${spring.profiles.active}.xml
mybatis:
type-aliases-package: com.viontech.lable.model
type-aliases-package: com.viontech.fanxing.commons.model
mapper-locations: classpath:com/viontech/fanxing/code/mapping/*.xml
pagehelper:
helper-dialect: mysql
......
......@@ -66,5 +66,32 @@
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>org.mybatis.spring.boot</groupId>
<artifactId>mybatis-spring-boot-starter</artifactId>
<version>2.1.4</version>
<exclusions>
<exclusion>
<artifactId>mybatis</artifactId>
<groupId>org.mybatis</groupId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>com.github.pagehelper</groupId>
<artifactId>pagehelper-spring-boot-starter</artifactId>
<version>1.2.3</version>
<exclusions>
<exclusion>
<artifactId>mybatis-spring-boot-starter</artifactId>
<groupId>org.mybatis.spring.boot</groupId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>org.mybatis</groupId>
<artifactId>mybatis</artifactId>
<version>3.5.2</version>
</dependency>
</dependencies>
</project>
\ No newline at end of file
package com.viontech.fanxing.code.base;
package com.viontech.fanxing.commons.base;
import com.github.pagehelper.PageInfo;
import com.viontech.keliu.util.FileUtil;
......@@ -6,7 +6,6 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.web.bind.annotation.*;
import javax.servlet.http.HttpServletResponse;
import java.io.File;
import java.io.FileInputStream;
import java.io.IOException;
......@@ -180,53 +179,6 @@ public abstract class BaseController<O extends BaseModel, T extends VoInterface<
}
}
/**
* 根据参数获取图片,对前后获取图片的不同参数方式进行兼容
*/
@RequestMapping(value = "/img/{location}/{picture:.+}")
public void getIMG(@PathVariable("picture") String picture, @PathVariable("location") String location, HttpServletResponse response) {
if (picture.contains("svg")) {
response.setContentType("image/svg+xml;charset=UTF-8");
response.addHeader("Accept-Ranges", "bytes");
} else {
response.setContentType("image/jpeg");
}
FileInputStream fis = null;
OutputStream out = null;
try {
String basePath = FileUtil.getBasePath();
File file = new File(basePath + "/" + location, picture);
if (!file.exists()) {
System.out.println(file.getAbsolutePath());
return;
}
out = response.getOutputStream();
fis = new FileInputStream(file);
byte[] b = new byte[fis.available()];
response.setContentLength(b.length);
fis.read(b);
out.write(b);
out.flush();
} catch (IOException e) {
e.printStackTrace();
} finally {
try {
if (fis != null) {
fis.close();
}
} catch (Exception e) {
e.printStackTrace();
}
try {
if (out != null) {
out.close();
}
} catch (Exception e) {
e.printStackTrace();
}
}
}
/**
* 获取到执行各项操作需要的service
......
package com.viontech.fanxing.code.base;
package com.viontech.fanxing.commons.base;
import org.apache.ibatis.annotations.Param;
......
package com.viontech.fanxing.code.base;
package com.viontech.fanxing.commons.base;
import java.io.Serializable;
......
package com.viontech.fanxing.code.base;
package com.viontech.fanxing.commons.base;
import com.github.pagehelper.PageInfo;
......@@ -15,7 +15,7 @@ public interface BaseService<T extends BaseModel>{
* 获取service对应的Mapper来进行操作
* @return
*/
public abstract com.viontech.fanxing.code.base.BaseMapper<T> getMapper();
public abstract com.viontech.fanxing.commons.base.BaseMapper<T> getMapper();
/**
* 通过查询条件获取满足条件的数据数量
......
package com.viontech.fanxing.code.base;
package com.viontech.fanxing.commons.base;
import com.github.pagehelper.Page;
import com.github.pagehelper.PageHelper;
......
package com.viontech.fanxing.commons.base;
import org.springframework.core.convert.converter.Converter;
import java.text.DateFormat;
import java.text.SimpleDateFormat;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;
/**
* @author xmh
* @date 2021-06-17
*/
public class DateConverter implements Converter<String, Date> {
/**
* 可格式化 的日期 字串
*/
private static final List<String> formarts = new ArrayList<>();
static {
formarts.add("yyyy-MM");
formarts.add("yyyy-MM-dd");
formarts.add("yyyy-MM-dd HH:mm");
formarts.add("yyyy-MM-dd HH:mm:ss");
formarts.add("HH:mm:ss");
formarts.add("HH:mm");
formarts.add("yyyy-MM-dd'T'HH:mm:ss");
}
@Override
public Date convert(String source) {
String value = source.trim();
if ("".equals(value)) {
return null;
}
if (source.matches("^\\d{4}-\\d{1,2}$")) {
return parseDate(source, formarts.get(0));
} else if (source.matches("^\\d{4}-\\d{1,2}-\\d{1,2}$")) {
return parseDate(source, formarts.get(1));
} else if (source.matches("^\\d{4}-\\d{1,2}-\\d{1,2} {1}\\d{1,2}:\\d{1,2}$")) {
return parseDate(source, formarts.get(2));
} else if (source.matches("^\\d{4}-\\d{1,2}-\\d{1,2} {1}\\d{1,2}:\\d{1,2}:\\d{1,2}$")) {
return parseDate(source, formarts.get(3));
} else if (source.matches("([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9]")) {
return parseDate(source, formarts.get(4));
} else if (source.matches("([01][0-9]|2[0-3]):[0-5][0-9]")) {
return parseDate(source, formarts.get(5));
} else if (source.matches("^\\d{4}-\\d{1,2}-\\d{1,2}T\\d{1,2}:\\d{1,2}:\\d{1,2}[-,+]\\d{1,2}:\\d{1,2}$")) {
return parseDate(source, formarts.get(6));
} else {
throw new IllegalArgumentException("Invalid boolean value '" + source + "'");
}
}
/**
* 功能描述:格式化日期
*
* @param dateStr String 字符型日期
* @param format String 格式
*
* @return Date 日期
*/
public Date parseDate(String dateStr, String format) {
Date date = null;
try {
DateFormat dateFormat = new SimpleDateFormat(format);
date = (Date) dateFormat.parse(dateStr);
} catch (Exception e) {
}
return date;
}
}
\ No newline at end of file
package com.viontech.fanxing.commons.base;
import com.viontech.keliu.util.JsonMessageUtil;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.web.bind.annotation.ExceptionHandler;
import org.springframework.web.bind.annotation.RestControllerAdvice;
/**
* .
*
* @author 谢明辉
* @date 2020/6/4
*/
@RestControllerAdvice
public class GlobalExceptionHandler {
private static final Logger log = LoggerFactory.getLogger(GlobalExceptionHandler.class);
@ExceptionHandler
public Object exceptionHandler(Exception e) {
log.info("", e);
return JsonMessageUtil.getErrorJsonMsg(e.getMessage());
}
}
package com.viontech.fanxing.code.base;
package com.viontech.fanxing.commons.base;
public interface VoInterface<T> {
public T getModel();
......
package com.viontech.fanxing.commons.config;
import com.viontech.fanxing.commons.base.DateConverter;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.core.convert.converter.Converter;
import org.springframework.web.cors.CorsConfiguration;
import org.springframework.web.cors.UrlBasedCorsConfigurationSource;
import org.springframework.web.filter.CorsFilter;
import java.util.Date;
/**
* .
*
* @author 谢明辉
* @date 2021/5/26
*/
@Configuration
public class WebConfig {
@Bean
public Converter<String, Date> addNewConvert() {
return new DateConverter();
}
@Bean
public CorsFilter corsFilter() {
CorsConfiguration config = new CorsConfiguration();
config.addAllowedOrigin("*");
config.setAllowCredentials(true);
config.addAllowedMethod("*");
config.addAllowedHeader("*");
config.setMaxAge(3600L);
UrlBasedCorsConfigurationSource configSource = new UrlBasedCorsConfigurationSource();
configSource.registerCorsConfiguration("/**", config);
return new CorsFilter(configSource);
}
}
package com.viontech.fanxing.commons.feing;
import com.viontech.fanxing.commons.model.Task;
import com.viontech.keliu.util.JsonMessageUtil;
/**
* .
*
* @author 谢明辉
* @date 2021/7/12
*/
public interface TaskSchedulingTasksAdapter {
JsonMessageUtil.JsonMessage add(Task task);
JsonMessageUtil.JsonMessage update(Task task);
JsonMessageUtil.JsonMessage delete(Task task);
}
package com.viontech.fanxing.commons.model;
import com.viontech.fanxing.commons.base.BaseModel;
import java.util.Date;
public class Behavior extends BaseModel {
private Long id;
private String unid;
private Long taskId;
private String eventType;
private String eventCate;
private String eventRefid;
private Date eventTime;
private String channelUnid;
private String testPicFile;
private String testFrameNo;
private String taskName;
private String eventDataNum;
private String auxDevInfo;
private String eventData;
private String pics;
private String video;
public Long getId() {
return id;
}
public void setId(Long id) {
this.id = id;
}
public String getUnid() {
return unid;
}
public void setUnid(String unid) {
this.unid = unid == null ? null : unid.trim();
}
public Long getTaskId() {
return taskId;
}
public void setTaskId(Long taskId) {
this.taskId = taskId;
}
public String getEventType() {
return eventType;
}
public void setEventType(String eventType) {
this.eventType = eventType == null ? null : eventType.trim();
}
public String getEventCate() {
return eventCate;
}
public void setEventCate(String eventCate) {
this.eventCate = eventCate == null ? null : eventCate.trim();
}
public String getEventRefid() {
return eventRefid;
}
public void setEventRefid(String eventRefid) {
this.eventRefid = eventRefid == null ? null : eventRefid.trim();
}
public Date getEventTime() {
return eventTime;
}
public void setEventTime(Date eventTime) {
this.eventTime = eventTime;
}
public String getChannelUnid() {
return channelUnid;
}
public void setChannelUnid(String channelUnid) {
this.channelUnid = channelUnid == null ? null : channelUnid.trim();
}
public String getTestPicFile() {
return testPicFile;
}
public void setTestPicFile(String testPicFile) {
this.testPicFile = testPicFile == null ? null : testPicFile.trim();
}
public String getTestFrameNo() {
return testFrameNo;
}
public void setTestFrameNo(String testFrameNo) {
this.testFrameNo = testFrameNo == null ? null : testFrameNo.trim();
}
public String getTaskName() {
return taskName;
}
public void setTaskName(String taskName) {
this.taskName = taskName == null ? null : taskName.trim();
}
public String getEventDataNum() {
return eventDataNum;
}
public void setEventDataNum(String eventDataNum) {
this.eventDataNum = eventDataNum == null ? null : eventDataNum.trim();
}
public String getAuxDevInfo() {
return auxDevInfo;
}
public void setAuxDevInfo(String auxDevInfo) {
this.auxDevInfo = auxDevInfo == null ? null : auxDevInfo.trim();
}
public String getEventData() {
return eventData;
}
public void setEventData(String eventData) {
this.eventData = eventData == null ? null : eventData.trim();
}
public String getPics() {
return pics;
}
public void setPics(String pics) {
this.pics = pics == null ? null : pics.trim();
}
public String getVideo() {
return video;
}
public void setVideo(String video) {
this.video = video == null ? null : video.trim();
}
}
\ No newline at end of file
package com.viontech.fanxing.code.model;
package com.viontech.fanxing.commons.model;
import com.viontech.fanxing.code.base.BaseModel;
import com.viontech.fanxing.commons.base.BaseModel;
public class DictCate extends BaseModel {
private Long id;
......
package com.viontech.fanxing.code.model;
package com.viontech.fanxing.commons.model;
import com.viontech.fanxing.commons.base.BaseExample;
import com.viontech.fanxing.code.base.BaseExample;
import java.util.ArrayList;
import java.util.HashSet;
import java.util.List;
import java.util.Set;
public class DictCateExample extends BaseExample {
......
package com.viontech.fanxing.code.model;
package com.viontech.fanxing.commons.model;
import com.viontech.fanxing.code.base.BaseModel;
import com.viontech.fanxing.commons.base.BaseModel;
public class DictCode extends BaseModel {
private Long id;
......
package com.viontech.fanxing.code.model;
package com.viontech.fanxing.commons.model;
import com.viontech.fanxing.commons.base.BaseExample;
import com.viontech.fanxing.code.base.BaseExample;
import java.util.ArrayList;
import java.util.HashSet;
import java.util.List;
import java.util.Set;
public class DictCodeExample extends BaseExample {
......
package com.viontech.fanxing.commons.model;
import com.viontech.fanxing.commons.base.BaseModel;
import java.util.Date;
public class FlowData extends BaseModel {
private Long id;
private String unid;
private String eventId;
private Long taskId;
private String detectionType;
private String roadCode;
private String directionCode;
private Long sampleDura;
private Float sampleNum;
private Float velocity;
private String velocityUnit;
private Float occupy;
private Float distance;
private Float queueLength;
private String regionId;
private String regionName;
private Float area;
private Float density;
private Float sampleNumIn;
private Float sampleNumOut;
private Date eventTime;
private Float distTime;
private Float timeOccupy;
private Integer status;
private String positionContent;
private String headContent;
public Long getId() {
return id;
}
public void setId(Long id) {
this.id = id;
}
public String getUnid() {
return unid;
}
public void setUnid(String unid) {
this.unid = unid == null ? null : unid.trim();
}
public String getEventId() {
return eventId;
}
public void setEventId(String eventId) {
this.eventId = eventId == null ? null : eventId.trim();
}
public Long getTaskId() {
return taskId;
}
public void setTaskId(Long taskId) {
this.taskId = taskId;
}
public String getDetectionType() {
return detectionType;
}
public void setDetectionType(String detectionType) {
this.detectionType = detectionType == null ? null : detectionType.trim();
}
public String getRoadCode() {
return roadCode;
}
public void setRoadCode(String roadCode) {
this.roadCode = roadCode == null ? null : roadCode.trim();
}
public String getDirectionCode() {
return directionCode;
}
public void setDirectionCode(String directionCode) {
this.directionCode = directionCode == null ? null : directionCode.trim();
}
public Long getSampleDura() {
return sampleDura;
}
public void setSampleDura(Long sampleDura) {
this.sampleDura = sampleDura;
}
public Float getSampleNum() {
return sampleNum;
}
public void setSampleNum(Float sampleNum) {
this.sampleNum = sampleNum;
}
public Float getVelocity() {
return velocity;
}
public void setVelocity(Float velocity) {
this.velocity = velocity;
}
public String getVelocityUnit() {
return velocityUnit;
}
public void setVelocityUnit(String velocityUnit) {
this.velocityUnit = velocityUnit == null ? null : velocityUnit.trim();
}
public Float getOccupy() {
return occupy;
}
public void setOccupy(Float occupy) {
this.occupy = occupy;
}
public Float getDistance() {
return distance;
}
public void setDistance(Float distance) {
this.distance = distance;
}
public Float getQueueLength() {
return queueLength;
}
public void setQueueLength(Float queueLength) {
this.queueLength = queueLength;
}
public String getRegionId() {
return regionId;
}
public void setRegionId(String regionId) {
this.regionId = regionId == null ? null : regionId.trim();
}
public String getRegionName() {
return regionName;
}
public void setRegionName(String regionName) {
this.regionName = regionName == null ? null : regionName.trim();
}
public Float getArea() {
return area;
}
public void setArea(Float area) {
this.area = area;
}
public Float getDensity() {
return density;
}
public void setDensity(Float density) {
this.density = density;
}
public Float getSampleNumIn() {
return sampleNumIn;
}
public void setSampleNumIn(Float sampleNumIn) {
this.sampleNumIn = sampleNumIn;
}
public Float getSampleNumOut() {
return sampleNumOut;
}
public void setSampleNumOut(Float sampleNumOut) {
this.sampleNumOut = sampleNumOut;
}
public Date getEventTime() {
return eventTime;
}
public void setEventTime(Date eventTime) {
this.eventTime = eventTime;
}
public Float getDistTime() {
return distTime;
}
public void setDistTime(Float distTime) {
this.distTime = distTime;
}
public Float getTimeOccupy() {
return timeOccupy;
}
public void setTimeOccupy(Float timeOccupy) {
this.timeOccupy = timeOccupy;
}
public Integer getStatus() {
return status;
}
public void setStatus(Integer status) {
this.status = status;
}
public String getPositionContent() {
return positionContent;
}
public void setPositionContent(String positionContent) {
this.positionContent = positionContent == null ? null : positionContent.trim();
}
public String getHeadContent() {
return headContent;
}
public void setHeadContent(String headContent) {
this.headContent = headContent == null ? null : headContent.trim();
}
}
\ No newline at end of file
package com.viontech.fanxing.commons.model;
import com.viontech.fanxing.commons.base.BaseModel;
import java.util.Date;
public class FlowEvent extends BaseModel {
private Long id;
private String unid;
private Long taskId;
private String eventType;
private Date eventTime;
private String deviceCode;
private String deviceName;
private String locationCode;
private String locationName;
private String picName;
private String videoName;
private String jsonData;
public Long getId() {
return id;
}
public void setId(Long id) {
this.id = id;
}
public String getUnid() {
return unid;
}
public void setUnid(String unid) {
this.unid = unid == null ? null : unid.trim();
}
public Long getTaskId() {
return taskId;
}
public void setTaskId(Long taskId) {
this.taskId = taskId;
}
public String getEventType() {
return eventType;
}
public void setEventType(String eventType) {
this.eventType = eventType == null ? null : eventType.trim();
}
public Date getEventTime() {
return eventTime;
}
public void setEventTime(Date eventTime) {
this.eventTime = eventTime;
}
public String getDeviceCode() {
return deviceCode;
}
public void setDeviceCode(String deviceCode) {
this.deviceCode = deviceCode == null ? null : deviceCode.trim();
}
public String getDeviceName() {
return deviceName;
}
public void setDeviceName(String deviceName) {
this.deviceName = deviceName == null ? null : deviceName.trim();
}
public String getLocationCode() {
return locationCode;
}
public void setLocationCode(String locationCode) {
this.locationCode = locationCode == null ? null : locationCode.trim();
}
public String getLocationName() {
return locationName;
}
public void setLocationName(String locationName) {
this.locationName = locationName == null ? null : locationName.trim();
}
public String getPicName() {
return picName;
}
public void setPicName(String picName) {
this.picName = picName == null ? null : picName.trim();
}
public String getVideoName() {
return videoName;
}
public void setVideoName(String videoName) {
this.videoName = videoName == null ? null : videoName.trim();
}
public String getJsonData() {
return jsonData;
}
public void setJsonData(String jsonData) {
this.jsonData = jsonData == null ? null : jsonData.trim();
}
}
\ No newline at end of file
package com.viontech.fanxing.commons.model;
import com.viontech.fanxing.commons.base.BaseModel;
import java.util.Date;
public class Forward extends BaseModel {
private Long id;
private String unid;
private String name;
private String url;
private Long total;
private Long failed;
private Date lastSendTime;
private Date createTime;
private Integer status;
public Long getId() {
return id;
}
public void setId(Long id) {
this.id = id;
}
public String getUnid() {
return unid;
}
public void setUnid(String unid) {
this.unid = unid == null ? null : unid.trim();
}
public String getName() {
return name;
}
public void setName(String name) {
this.name = name == null ? null : name.trim();
}
public String getUrl() {
return url;
}
public void setUrl(String url) {
this.url = url == null ? null : url.trim();
}
public Long getTotal() {
return total;
}
public void setTotal(Long total) {
this.total = total;
}
public Long getFailed() {
return failed;
}
public void setFailed(Long failed) {
this.failed = failed;
}
public Date getLastSendTime() {
return lastSendTime;
}
public void setLastSendTime(Date lastSendTime) {
this.lastSendTime = lastSendTime;
}
public Date getCreateTime() {
return createTime;
}
public void setCreateTime(Date createTime) {
this.createTime = createTime;
}
public Integer getStatus() {
return status;
}
public void setStatus(Integer status) {
this.status = status;
}
}
\ No newline at end of file
package com.viontech.fanxing.commons.model;
import com.viontech.fanxing.commons.base.BaseModel;
public class ForwardConfig extends BaseModel {
private Long id;
private String unid;
private Long forwardId;
private String eventCate;
private String eventType;
public Long getId() {
return id;
}
public void setId(Long id) {
this.id = id;
}
public String getUnid() {
return unid;
}
public void setUnid(String unid) {
this.unid = unid == null ? null : unid.trim();
}
public Long getForwardId() {
return forwardId;
}
public void setForwardId(Long forwardId) {
this.forwardId = forwardId;
}
public String getEventCate() {
return eventCate;
}
public void setEventCate(String eventCate) {
this.eventCate = eventCate == null ? null : eventCate.trim();
}
public String getEventType() {
return eventType;
}
public void setEventType(String eventType) {
this.eventType = eventType == null ? null : eventType.trim();
}
}
\ No newline at end of file
package com.viontech.fanxing.commons.model;
import com.viontech.fanxing.commons.base.BaseModel;
import java.util.Date;
public class StoreConfig extends BaseModel {
private Long id;
private String unid;
private String name;
private Integer contentFormat;
private Date createTime;
private Integer status;
private String content;
public Long getId() {
return id;
}
public void setId(Long id) {
this.id = id;
}
public String getUnid() {
return unid;
}
public void setUnid(String unid) {
this.unid = unid == null ? null : unid.trim();
}
public String getName() {
return name;
}
public void setName(String name) {
this.name = name == null ? null : name.trim();
}
public Integer getContentFormat() {
return contentFormat;
}
public void setContentFormat(Integer contentFormat) {
this.contentFormat = contentFormat;
}
public Date getCreateTime() {
return createTime;
}
public void setCreateTime(Date createTime) {
this.createTime = createTime;
}
public Integer getStatus() {
return status;
}
public void setStatus(Integer status) {
this.status = status;
}
public String getContent() {
return content;
}
public void setContent(String content) {
this.content = content == null ? null : content.trim();
}
}
\ No newline at end of file
package com.viontech.fanxing.commons.model;
import com.viontech.fanxing.commons.base.BaseModel;
import java.util.Date;
public class Task extends BaseModel {
private Long id;
private String unid;
private String name;
private String algType;
private Float resourceNeed;
private Integer priority;
private Long storeConfigId;
private String vaType;
private Integer runtimeType;
private String deviceUnid;
private String channelUnid;
private String streamPath;
private Integer streamType;
private Date createTime;
private Integer status;
private String runtimeConf;
private String scene;
public Long getId() {
return id;
}
public void setId(Long id) {
this.id = id;
}
public String getUnid() {
return unid;
}
public void setUnid(String unid) {
this.unid = unid == null ? null : unid.trim();
}
public String getName() {
return name;
}
public void setName(String name) {
this.name = name == null ? null : name.trim();
}
public String getAlgType() {
return algType;
}
public void setAlgType(String algType) {
this.algType = algType == null ? null : algType.trim();
}
public Float getResourceNeed() {
return resourceNeed;
}
public void setResourceNeed(Float resourceNeed) {
this.resourceNeed = resourceNeed;
}
public Integer getPriority() {
return priority;
}
public void setPriority(Integer priority) {
this.priority = priority;
}
public Long getStoreConfigId() {
return storeConfigId;
}
public void setStoreConfigId(Long storeConfigId) {
this.storeConfigId = storeConfigId;
}
public String getVaType() {
return vaType;
}
public void setVaType(String vaType) {
this.vaType = vaType == null ? null : vaType.trim();
}
public Integer getRuntimeType() {
return runtimeType;
}
public void setRuntimeType(Integer runtimeType) {
this.runtimeType = runtimeType;
}
public String getDeviceUnid() {
return deviceUnid;
}
public void setDeviceUnid(String deviceUnid) {
this.deviceUnid = deviceUnid == null ? null : deviceUnid.trim();
}
public String getChannelUnid() {
return channelUnid;
}
public void setChannelUnid(String channelUnid) {
this.channelUnid = channelUnid == null ? null : channelUnid.trim();
}
public String getStreamPath() {
return streamPath;
}
public void setStreamPath(String streamPath) {
this.streamPath = streamPath == null ? null : streamPath.trim();
}
public Integer getStreamType() {
return streamType;
}
public void setStreamType(Integer streamType) {
this.streamType = streamType;
}
public Date getCreateTime() {
return createTime;
}
public void setCreateTime(Date createTime) {
this.createTime = createTime;
}
public Integer getStatus() {
return status;
}
public void setStatus(Integer status) {
this.status = status;
}
public String getRuntimeConf() {
return runtimeConf;
}
public void setRuntimeConf(String runtimeConf) {
this.runtimeConf = runtimeConf == null ? null : runtimeConf.trim();
}
public String getScene() {
return scene;
}
public void setScene(String scene) {
this.scene = scene == null ? null : scene.trim();
}
}
\ No newline at end of file
package com.viontech.fanxing.commons.model;
import com.viontech.fanxing.commons.base.BaseModel;
import java.util.Date;
public class Traffic extends BaseModel {
private Long id;
private String unid;
private Long taskId;
private String eventCate;
private String eventType;
private Date eventTime;
private String channelUnid;
private String plateColor;
private String plateNumber;
private String locationCode;
private String laneCode;
private String directionCode;
private String vehicleType;
private String illegalCode;
private Integer illegalState;
private String vehicleColor;
private String vehicleLogo;
private String annualInspectionMark;
private String pendant;
private String decoration;
private String sunShield;
private String xcycleType;
private String eventId;
private Date shootTime;
private String specialType;
private Integer withHelmet;
private String picName;
private String videoName;
private Integer status;
private String jsonData;
public Long getId() {
return id;
}
public void setId(Long id) {
this.id = id;
}
public String getUnid() {
return unid;
}
public void setUnid(String unid) {
this.unid = unid == null ? null : unid.trim();
}
public Long getTaskId() {
return taskId;
}
public void setTaskId(Long taskId) {
this.taskId = taskId;
}
public String getEventCate() {
return eventCate;
}
public void setEventCate(String eventCate) {
this.eventCate = eventCate == null ? null : eventCate.trim();
}
public String getEventType() {
return eventType;
}
public void setEventType(String eventType) {
this.eventType = eventType == null ? null : eventType.trim();
}
public Date getEventTime() {
return eventTime;
}
public void setEventTime(Date eventTime) {
this.eventTime = eventTime;
}
public String getChannelUnid() {
return channelUnid;
}
public void setChannelUnid(String channelUnid) {
this.channelUnid = channelUnid == null ? null : channelUnid.trim();
}
public String getPlateColor() {
return plateColor;
}
public void setPlateColor(String plateColor) {
this.plateColor = plateColor == null ? null : plateColor.trim();
}
public String getPlateNumber() {
return plateNumber;
}
public void setPlateNumber(String plateNumber) {
this.plateNumber = plateNumber == null ? null : plateNumber.trim();
}
public String getLocationCode() {
return locationCode;
}
public void setLocationCode(String locationCode) {
this.locationCode = locationCode == null ? null : locationCode.trim();
}
public String getLaneCode() {
return laneCode;
}
public void setLaneCode(String laneCode) {
this.laneCode = laneCode == null ? null : laneCode.trim();
}
public String getDirectionCode() {
return directionCode;
}
public void setDirectionCode(String directionCode) {
this.directionCode = directionCode == null ? null : directionCode.trim();
}
public String getVehicleType() {
return vehicleType;
}
public void setVehicleType(String vehicleType) {
this.vehicleType = vehicleType == null ? null : vehicleType.trim();
}
public String getIllegalCode() {
return illegalCode;
}
public void setIllegalCode(String illegalCode) {
this.illegalCode = illegalCode == null ? null : illegalCode.trim();
}
public Integer getIllegalState() {
return illegalState;
}
public void setIllegalState(Integer illegalState) {
this.illegalState = illegalState;
}
public String getVehicleColor() {
return vehicleColor;
}
public void setVehicleColor(String vehicleColor) {
this.vehicleColor = vehicleColor == null ? null : vehicleColor.trim();
}
public String getVehicleLogo() {
return vehicleLogo;
}
public void setVehicleLogo(String vehicleLogo) {
this.vehicleLogo = vehicleLogo == null ? null : vehicleLogo.trim();
}
public String getAnnualInspectionMark() {
return annualInspectionMark;
}
public void setAnnualInspectionMark(String annualInspectionMark) {
this.annualInspectionMark = annualInspectionMark == null ? null : annualInspectionMark.trim();
}
public String getPendant() {
return pendant;
}
public void setPendant(String pendant) {
this.pendant = pendant == null ? null : pendant.trim();
}
public String getDecoration() {
return decoration;
}
public void setDecoration(String decoration) {
this.decoration = decoration == null ? null : decoration.trim();
}
public String getSunShield() {
return sunShield;
}
public void setSunShield(String sunShield) {
this.sunShield = sunShield == null ? null : sunShield.trim();
}
public String getXcycleType() {
return xcycleType;
}
public void setXcycleType(String xcycleType) {
this.xcycleType = xcycleType == null ? null : xcycleType.trim();
}
public String getEventId() {
return eventId;
}
public void setEventId(String eventId) {
this.eventId = eventId == null ? null : eventId.trim();
}
public Date getShootTime() {
return shootTime;
}
public void setShootTime(Date shootTime) {
this.shootTime = shootTime;
}
public String getSpecialType() {
return specialType;
}
public void setSpecialType(String specialType) {
this.specialType = specialType == null ? null : specialType.trim();
}
public Integer getWithHelmet() {
return withHelmet;
}
public void setWithHelmet(Integer withHelmet) {
this.withHelmet = withHelmet;
}
public String getPicName() {
return picName;
}
public void setPicName(String picName) {
this.picName = picName == null ? null : picName.trim();
}
public String getVideoName() {
return videoName;
}
public void setVideoName(String videoName) {
this.videoName = videoName == null ? null : videoName.trim();
}
public Integer getStatus() {
return status;
}
public void setStatus(Integer status) {
this.status = status;
}
public String getJsonData() {
return jsonData;
}
public void setJsonData(String jsonData) {
this.jsonData = jsonData == null ? null : jsonData.trim();
}
}
\ No newline at end of file
package com.viontech.fanxing.commons.vo;
import com.viontech.fanxing.commons.model.Behavior;
import com.viontech.fanxing.commons.vobase.BehaviorVoBase;
public class BehaviorVo extends BehaviorVoBase {
public BehaviorVo() {
super();
}
public BehaviorVo(Behavior behavior) {
super(behavior);
}
}
\ No newline at end of file
package com.viontech.fanxing.code.vo;
package com.viontech.fanxing.commons.vo;
import com.viontech.fanxing.code.model.DictCate;
import com.viontech.fanxing.code.vobase.DictCateVoBase;
import com.viontech.fanxing.commons.model.DictCate;
import com.viontech.fanxing.commons.vobase.DictCateVoBase;
public class DictCateVo extends DictCateVoBase {
......
package com.viontech.fanxing.code.vo;
package com.viontech.fanxing.commons.vo;
import com.viontech.fanxing.code.model.DictCode;
import com.viontech.fanxing.code.vobase.DictCodeVoBase;
import com.viontech.fanxing.commons.model.DictCode;
import com.viontech.fanxing.commons.vobase.DictCodeVoBase;
import java.util.List;
......
package com.viontech.fanxing.commons.vo;
import com.viontech.fanxing.commons.model.FlowData;
import com.viontech.fanxing.commons.vobase.FlowDataVoBase;
public class FlowDataVo extends FlowDataVoBase {
public FlowDataVo() {
super();
}
public FlowDataVo(FlowData flowData) {
super(flowData);
}
}
\ No newline at end of file
package com.viontech.fanxing.commons.vo;
import com.viontech.fanxing.commons.model.FlowEvent;
import com.viontech.fanxing.commons.vobase.FlowEventVoBase;
public class FlowEventVo extends FlowEventVoBase {
public FlowEventVo() {
super();
}
public FlowEventVo(FlowEvent flowEvent) {
super(flowEvent);
}
}
\ No newline at end of file
package com.viontech.fanxing.commons.vo;
import com.viontech.fanxing.commons.model.ForwardConfig;
import com.viontech.fanxing.commons.vobase.ForwardConfigVoBase;
public class ForwardConfigVo extends ForwardConfigVoBase {
public ForwardConfigVo() {
super();
}
public ForwardConfigVo(ForwardConfig forwardConfig) {
super(forwardConfig);
}
}
\ No newline at end of file
package com.viontech.fanxing.commons.vo;
import com.viontech.fanxing.commons.model.Forward;
import com.viontech.fanxing.commons.vobase.ForwardVoBase;
public class ForwardVo extends ForwardVoBase {
public ForwardVo() {
super();
}
public ForwardVo(Forward forward) {
super(forward);
}
}
\ No newline at end of file
package com.viontech.fanxing.commons.vo;
import com.viontech.fanxing.commons.model.StoreConfig;
import com.viontech.fanxing.commons.vobase.StoreConfigVoBase;
public class StoreConfigVo extends StoreConfigVoBase {
public StoreConfigVo() {
super();
}
public StoreConfigVo(StoreConfig storeConfig) {
super(storeConfig);
}
}
\ No newline at end of file
package com.viontech.fanxing.commons.vo;
import com.viontech.fanxing.commons.model.Task;
import com.viontech.fanxing.commons.vobase.TaskVoBase;
public class TaskVo extends TaskVoBase {
public TaskVo() {
super();
}
public TaskVo(Task task) {
super(task);
}
}
\ No newline at end of file
package com.viontech.fanxing.commons.vo;
import com.viontech.fanxing.commons.model.Traffic;
import com.viontech.fanxing.commons.vobase.TrafficVoBase;
public class TrafficVo extends TrafficVoBase {
public TrafficVo() {
super();
}
public TrafficVo(Traffic traffic) {
super(traffic);
}
}
\ No newline at end of file
package com.viontech.fanxing.code.vobase;
package com.viontech.fanxing.commons.vobase;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.viontech.fanxing.code.base.VoInterface;
import com.viontech.fanxing.code.model.DictCate;
import com.viontech.fanxing.commons.base.VoInterface;
import com.viontech.fanxing.commons.model.DictCate;
import java.util.ArrayList;
public class DictCateVoBase extends DictCate implements VoInterface<DictCate> {
......
package com.viontech.fanxing.code.vobase;
package com.viontech.fanxing.commons.vobase;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.viontech.fanxing.code.base.VoInterface;
import com.viontech.fanxing.code.model.DictCode;
import com.viontech.fanxing.commons.base.VoInterface;
import com.viontech.fanxing.commons.model.DictCode;
import java.util.ArrayList;
public class DictCodeVoBase extends DictCode implements VoInterface<DictCode> {
......
package com.viontech.fanxing.commons.vobase;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.viontech.fanxing.commons.base.VoInterface;
import com.viontech.fanxing.commons.model.ForwardConfig;
import java.util.ArrayList;
public class ForwardConfigVoBase extends ForwardConfig implements VoInterface<ForwardConfig> {
private ForwardConfig forwardConfig;
@JsonIgnore
private ArrayList<Long> id_arr;
@JsonIgnore
private Long id_gt;
@JsonIgnore
private Long id_lt;
@JsonIgnore
private Long id_gte;
@JsonIgnore
private Long id_lte;
@JsonIgnore
private ArrayList<String> unid_arr;
@JsonIgnore
private String unid_like;
@JsonIgnore
private ArrayList<Long> forwardId_arr;
@JsonIgnore
private Long forwardId_gt;
@JsonIgnore
private Long forwardId_lt;
@JsonIgnore
private Long forwardId_gte;
@JsonIgnore
private Long forwardId_lte;
@JsonIgnore
private ArrayList<String> eventCate_arr;
@JsonIgnore
private String eventCate_like;
@JsonIgnore
private ArrayList<String> eventType_arr;
@JsonIgnore
private String eventType_like;
public ForwardConfigVoBase() {
this(null);
}
public ForwardConfigVoBase(ForwardConfig forwardConfig) {
if(forwardConfig == null) {
forwardConfig = new ForwardConfig();
}
this.forwardConfig = forwardConfig;
}
@JsonIgnore
public ForwardConfig getModel() {
return forwardConfig;
}
public void setModel(ForwardConfig forwardConfig) {
this.forwardConfig = forwardConfig;
}
public ArrayList<Long> getId_arr() {
return id_arr;
}
public void setId_arr(ArrayList<Long> id_arr) {
this.id_arr = id_arr;
}
public Long getId_gt() {
return id_gt;
}
public void setId_gt(Long id_gt) {
this.id_gt = id_gt;
}
public Long getId_lt() {
return id_lt;
}
public void setId_lt(Long id_lt) {
this.id_lt = id_lt;
}
public Long getId_gte() {
return id_gte;
}
public void setId_gte(Long id_gte) {
this.id_gte = id_gte;
}
public Long getId_lte() {
return id_lte;
}
public void setId_lte(Long id_lte) {
this.id_lte = id_lte;
}
public Long getId() {
if(getModel() == null ){
throw new RuntimeException("model is null");
}
return this.getModel().getId();
}
public void setId(Long id) {
if(getModel() == null ){
throw new RuntimeException("model is null");
}
this.getModel().setId(id);
}
public ArrayList<String> getUnid_arr() {
return unid_arr;
}
public void setUnid_arr(ArrayList<String> unid_arr) {
this.unid_arr = unid_arr;
}
public String getUnid_like() {
return unid_like;
}
public void setUnid_like(String unid_like) {
this.unid_like = unid_like;
}
public String getUnid() {
if(getModel() == null ){
throw new RuntimeException("model is null");
}
return this.getModel().getUnid();
}
public void setUnid(String unid) {
if(getModel() == null ){
throw new RuntimeException("model is null");
}
this.getModel().setUnid(unid);
}
public ArrayList<Long> getForwardId_arr() {
return forwardId_arr;
}
public void setForwardId_arr(ArrayList<Long> forwardId_arr) {
this.forwardId_arr = forwardId_arr;
}
public Long getForwardId_gt() {
return forwardId_gt;
}
public void setForwardId_gt(Long forwardId_gt) {
this.forwardId_gt = forwardId_gt;
}
public Long getForwardId_lt() {
return forwardId_lt;
}
public void setForwardId_lt(Long forwardId_lt) {
this.forwardId_lt = forwardId_lt;
}
public Long getForwardId_gte() {
return forwardId_gte;
}
public void setForwardId_gte(Long forwardId_gte) {
this.forwardId_gte = forwardId_gte;
}
public Long getForwardId_lte() {
return forwardId_lte;
}
public void setForwardId_lte(Long forwardId_lte) {
this.forwardId_lte = forwardId_lte;
}
public Long getForwardId() {
if(getModel() == null ){
throw new RuntimeException("model is null");
}
return this.getModel().getForwardId();
}
public void setForwardId(Long forwardId) {
if(getModel() == null ){
throw new RuntimeException("model is null");
}
this.getModel().setForwardId(forwardId);
}
public ArrayList<String> getEventCate_arr() {
return eventCate_arr;
}
public void setEventCate_arr(ArrayList<String> eventCate_arr) {
this.eventCate_arr = eventCate_arr;
}
public String getEventCate_like() {
return eventCate_like;
}
public void setEventCate_like(String eventCate_like) {
this.eventCate_like = eventCate_like;
}
public String getEventCate() {
if(getModel() == null ){
throw new RuntimeException("model is null");
}
return this.getModel().getEventCate();
}
public void setEventCate(String eventCate) {
if(getModel() == null ){
throw new RuntimeException("model is null");
}
this.getModel().setEventCate(eventCate);
}
public ArrayList<String> getEventType_arr() {
return eventType_arr;
}
public void setEventType_arr(ArrayList<String> eventType_arr) {
this.eventType_arr = eventType_arr;
}
public String getEventType_like() {
return eventType_like;
}
public void setEventType_like(String eventType_like) {
this.eventType_like = eventType_like;
}
public String getEventType() {
if(getModel() == null ){
throw new RuntimeException("model is null");
}
return this.getModel().getEventType();
}
public void setEventType(String eventType) {
if(getModel() == null ){
throw new RuntimeException("model is null");
}
this.getModel().setEventType(eventType);
}
}
\ No newline at end of file
package com.viontech.fanxing.commons.vobase;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.viontech.fanxing.commons.base.VoInterface;
import com.viontech.fanxing.commons.model.StoreConfig;
import java.util.ArrayList;
import java.util.Date;
public class StoreConfigVoBase extends StoreConfig implements VoInterface<StoreConfig> {
private StoreConfig storeConfig;
@JsonIgnore
private ArrayList<Long> id_arr;
@JsonIgnore
private Long id_gt;
@JsonIgnore
private Long id_lt;
@JsonIgnore
private Long id_gte;
@JsonIgnore
private Long id_lte;
@JsonIgnore
private ArrayList<String> unid_arr;
@JsonIgnore
private String unid_like;
@JsonIgnore
private ArrayList<String> name_arr;
@JsonIgnore
private String name_like;
@JsonIgnore
private ArrayList<Integer> contentFormat_arr;
@JsonIgnore
private Integer contentFormat_gt;
@JsonIgnore
private Integer contentFormat_lt;
@JsonIgnore
private Integer contentFormat_gte;
@JsonIgnore
private Integer contentFormat_lte;
@JsonIgnore
private ArrayList<Date> createTime_arr;
@JsonIgnore
private Date createTime_gt;
@JsonIgnore
private Date createTime_lt;
@JsonIgnore
private Date createTime_gte;
@JsonIgnore
private Date createTime_lte;
@JsonIgnore
private ArrayList<Integer> status_arr;
@JsonIgnore
private Integer status_gt;
@JsonIgnore
private Integer status_lt;
@JsonIgnore
private Integer status_gte;
@JsonIgnore
private Integer status_lte;
@JsonIgnore
private ArrayList<String> content_arr;
@JsonIgnore
private String content_like;
public StoreConfigVoBase() {
this(null);
}
public StoreConfigVoBase(StoreConfig storeConfig) {
if(storeConfig == null) {
storeConfig = new StoreConfig();
}
this.storeConfig = storeConfig;
}
@JsonIgnore
public StoreConfig getModel() {
return storeConfig;
}
public void setModel(StoreConfig storeConfig) {
this.storeConfig = storeConfig;
}
public ArrayList<Long> getId_arr() {
return id_arr;
}
public void setId_arr(ArrayList<Long> id_arr) {
this.id_arr = id_arr;
}
public Long getId_gt() {
return id_gt;
}
public void setId_gt(Long id_gt) {
this.id_gt = id_gt;
}
public Long getId_lt() {
return id_lt;
}
public void setId_lt(Long id_lt) {
this.id_lt = id_lt;
}
public Long getId_gte() {
return id_gte;
}
public void setId_gte(Long id_gte) {
this.id_gte = id_gte;
}
public Long getId_lte() {
return id_lte;
}
public void setId_lte(Long id_lte) {
this.id_lte = id_lte;
}
public Long getId() {
if(getModel() == null ){
throw new RuntimeException("model is null");
}
return this.getModel().getId();
}
public void setId(Long id) {
if(getModel() == null ){
throw new RuntimeException("model is null");
}
this.getModel().setId(id);
}
public ArrayList<String> getUnid_arr() {
return unid_arr;
}
public void setUnid_arr(ArrayList<String> unid_arr) {
this.unid_arr = unid_arr;
}
public String getUnid_like() {
return unid_like;
}
public void setUnid_like(String unid_like) {
this.unid_like = unid_like;
}
public String getUnid() {
if(getModel() == null ){
throw new RuntimeException("model is null");
}
return this.getModel().getUnid();
}
public void setUnid(String unid) {
if(getModel() == null ){
throw new RuntimeException("model is null");
}
this.getModel().setUnid(unid);
}
public ArrayList<String> getName_arr() {
return name_arr;
}
public void setName_arr(ArrayList<String> name_arr) {
this.name_arr = name_arr;
}
public String getName_like() {
return name_like;
}
public void setName_like(String name_like) {
this.name_like = name_like;
}
public String getName() {
if(getModel() == null ){
throw new RuntimeException("model is null");
}
return this.getModel().getName();
}
public void setName(String name) {
if(getModel() == null ){
throw new RuntimeException("model is null");
}
this.getModel().setName(name);
}
public ArrayList<Integer> getContentFormat_arr() {
return contentFormat_arr;
}
public void setContentFormat_arr(ArrayList<Integer> contentFormat_arr) {
this.contentFormat_arr = contentFormat_arr;
}
public Integer getContentFormat_gt() {
return contentFormat_gt;
}
public void setContentFormat_gt(Integer contentFormat_gt) {
this.contentFormat_gt = contentFormat_gt;
}
public Integer getContentFormat_lt() {
return contentFormat_lt;
}
public void setContentFormat_lt(Integer contentFormat_lt) {
this.contentFormat_lt = contentFormat_lt;
}
public Integer getContentFormat_gte() {
return contentFormat_gte;
}
public void setContentFormat_gte(Integer contentFormat_gte) {
this.contentFormat_gte = contentFormat_gte;
}
public Integer getContentFormat_lte() {
return contentFormat_lte;
}
public void setContentFormat_lte(Integer contentFormat_lte) {
this.contentFormat_lte = contentFormat_lte;
}
public Integer getContentFormat() {
if(getModel() == null ){
throw new RuntimeException("model is null");
}
return this.getModel().getContentFormat();
}
public void setContentFormat(Integer contentFormat) {
if(getModel() == null ){
throw new RuntimeException("model is null");
}
this.getModel().setContentFormat(contentFormat);
}
public ArrayList<Date> getCreateTime_arr() {
return createTime_arr;
}
public void setCreateTime_arr(ArrayList<Date> createTime_arr) {
this.createTime_arr = createTime_arr;
}
public Date getCreateTime_gt() {
return createTime_gt;
}
public void setCreateTime_gt(Date createTime_gt) {
this.createTime_gt = createTime_gt;
}
public Date getCreateTime_lt() {
return createTime_lt;
}
public void setCreateTime_lt(Date createTime_lt) {
this.createTime_lt = createTime_lt;
}
public Date getCreateTime_gte() {
return createTime_gte;
}
public void setCreateTime_gte(Date createTime_gte) {
this.createTime_gte = createTime_gte;
}
public Date getCreateTime_lte() {
return createTime_lte;
}
public void setCreateTime_lte(Date createTime_lte) {
this.createTime_lte = createTime_lte;
}
public Date getCreateTime() {
if(getModel() == null ){
throw new RuntimeException("model is null");
}
return this.getModel().getCreateTime();
}
public void setCreateTime(Date createTime) {
if(getModel() == null ){
throw new RuntimeException("model is null");
}
this.getModel().setCreateTime(createTime);
}
public ArrayList<Integer> getStatus_arr() {
return status_arr;
}
public void setStatus_arr(ArrayList<Integer> status_arr) {
this.status_arr = status_arr;
}
public Integer getStatus_gt() {
return status_gt;
}
public void setStatus_gt(Integer status_gt) {
this.status_gt = status_gt;
}
public Integer getStatus_lt() {
return status_lt;
}
public void setStatus_lt(Integer status_lt) {
this.status_lt = status_lt;
}
public Integer getStatus_gte() {
return status_gte;
}
public void setStatus_gte(Integer status_gte) {
this.status_gte = status_gte;
}
public Integer getStatus_lte() {
return status_lte;
}
public void setStatus_lte(Integer status_lte) {
this.status_lte = status_lte;
}
public Integer getStatus() {
if(getModel() == null ){
throw new RuntimeException("model is null");
}
return this.getModel().getStatus();
}
public void setStatus(Integer status) {
if(getModel() == null ){
throw new RuntimeException("model is null");
}
this.getModel().setStatus(status);
}
public ArrayList<String> getContent_arr() {
return content_arr;
}
public void setContent_arr(ArrayList<String> content_arr) {
this.content_arr = content_arr;
}
public String getContent_like() {
return content_like;
}
public void setContent_like(String content_like) {
this.content_like = content_like;
}
public String getContent() {
if(getModel() == null ){
throw new RuntimeException("model is null");
}
return this.getModel().getContent();
}
public void setContent(String content) {
if(getModel() == null ){
throw new RuntimeException("model is null");
}
this.getModel().setContent(content);
}
}
\ No newline at end of file
......@@ -41,5 +41,19 @@
<artifactId>spring-boot-maven-plugin</artifactId>
</plugin>
</plugins>
<resources>
<resource>
<directory>src/main/java</directory>
<includes>
<include>**/*.xml</include>
</includes>
</resource>
<resource>
<directory>src/main/resources</directory>
<includes>
<include>*</include>
</includes>
</resource>
</resources>
</build>
</project>
\ No newline at end of file
package com.viontech.fanxing.forward.controller;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.cloud.context.config.annotation.RefreshScope;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;
/**
* .
*
* @author 谢明辉
* @date 2021/6/11
*/
@RestController
@RefreshScope
public class MainController {
@Value("${name:default}")
private String name;
@GetMapping("test")
public String test() {
return name;
}
}
package com.viontech.fanxing.forward.controller.base;
import com.viontech.fanxing.commons.base.BaseController;
import com.viontech.fanxing.commons.base.BaseExample;
import com.viontech.fanxing.commons.base.BaseMapper;
import com.viontech.fanxing.commons.base.BaseService;
import com.viontech.fanxing.forward.mapper.BehaviorMapper;
import com.viontech.fanxing.commons.model.Behavior;
import com.viontech.fanxing.commons.model.BehaviorExample;
import com.viontech.fanxing.forward.service.adapter.BehaviorService;
import com.viontech.fanxing.commons.vo.BehaviorVo;
import javax.annotation.Resource;
public abstract class BehaviorBaseController extends BaseController<Behavior, BehaviorVo> {
@Resource
protected BehaviorService behaviorService;
@Override
protected BaseExample getExample(BehaviorVo behaviorVo, int type) {
BehaviorExample behaviorExample = new BehaviorExample();
BehaviorExample.Criteria criteria = behaviorExample.createCriteria();
if(behaviorVo.getId() != null) {
criteria.andIdEqualTo(behaviorVo.getId());
}
if(behaviorVo.getId_arr() != null) {
criteria.andIdIn(behaviorVo.getId_arr());
}
if(behaviorVo.getId_gt() != null) {
criteria.andIdGreaterThan(behaviorVo.getId_gt());
}
if(behaviorVo.getId_lt() != null) {
criteria.andIdLessThan(behaviorVo.getId_lt());
}
if(behaviorVo.getId_gte() != null) {
criteria.andIdGreaterThanOrEqualTo(behaviorVo.getId_gte());
}
if(behaviorVo.getId_lte() != null) {
criteria.andIdLessThanOrEqualTo(behaviorVo.getId_lte());
}
if(behaviorVo.getUnid() != null) {
criteria.andUnidEqualTo(behaviorVo.getUnid());
}
if(behaviorVo.getUnid_arr() != null) {
criteria.andUnidIn(behaviorVo.getUnid_arr());
}
if(behaviorVo.getUnid_like() != null) {
criteria.andUnidLike(behaviorVo.getUnid_like());
}
if(behaviorVo.getTaskId() != null) {
criteria.andTaskIdEqualTo(behaviorVo.getTaskId());
}
if(behaviorVo.getTaskId_null() != null) {
if(behaviorVo.getTaskId_null().booleanValue()) {
criteria.andTaskIdIsNull();
} else {
criteria.andTaskIdIsNotNull();
}
}
if(behaviorVo.getTaskId_arr() != null) {
criteria.andTaskIdIn(behaviorVo.getTaskId_arr());
}
if(behaviorVo.getTaskId_gt() != null) {
criteria.andTaskIdGreaterThan(behaviorVo.getTaskId_gt());
}
if(behaviorVo.getTaskId_lt() != null) {
criteria.andTaskIdLessThan(behaviorVo.getTaskId_lt());
}
if(behaviorVo.getTaskId_gte() != null) {
criteria.andTaskIdGreaterThanOrEqualTo(behaviorVo.getTaskId_gte());
}
if(behaviorVo.getTaskId_lte() != null) {
criteria.andTaskIdLessThanOrEqualTo(behaviorVo.getTaskId_lte());
}
if(behaviorVo.getEventType() != null) {
criteria.andEventTypeEqualTo(behaviorVo.getEventType());
}
if(behaviorVo.getEventType_null() != null) {
if(behaviorVo.getEventType_null().booleanValue()) {
criteria.andEventTypeIsNull();
} else {
criteria.andEventTypeIsNotNull();
}
}
if(behaviorVo.getEventType_arr() != null) {
criteria.andEventTypeIn(behaviorVo.getEventType_arr());
}
if(behaviorVo.getEventType_like() != null) {
criteria.andEventTypeLike(behaviorVo.getEventType_like());
}
if(behaviorVo.getEventCate() != null) {
criteria.andEventCateEqualTo(behaviorVo.getEventCate());
}
if(behaviorVo.getEventCate_null() != null) {
if(behaviorVo.getEventCate_null().booleanValue()) {
criteria.andEventCateIsNull();
} else {
criteria.andEventCateIsNotNull();
}
}
if(behaviorVo.getEventCate_arr() != null) {
criteria.andEventCateIn(behaviorVo.getEventCate_arr());
}
if(behaviorVo.getEventCate_like() != null) {
criteria.andEventCateLike(behaviorVo.getEventCate_like());
}
if(behaviorVo.getEventRefid() != null) {
criteria.andEventRefidEqualTo(behaviorVo.getEventRefid());
}
if(behaviorVo.getEventRefid_null() != null) {
if(behaviorVo.getEventRefid_null().booleanValue()) {
criteria.andEventRefidIsNull();
} else {
criteria.andEventRefidIsNotNull();
}
}
if(behaviorVo.getEventRefid_arr() != null) {
criteria.andEventRefidIn(behaviorVo.getEventRefid_arr());
}
if(behaviorVo.getEventRefid_like() != null) {
criteria.andEventRefidLike(behaviorVo.getEventRefid_like());
}
if(behaviorVo.getEventTime() != null) {
criteria.andEventTimeEqualTo(behaviorVo.getEventTime());
}
if(behaviorVo.getEventTime_null() != null) {
if(behaviorVo.getEventTime_null().booleanValue()) {
criteria.andEventTimeIsNull();
} else {
criteria.andEventTimeIsNotNull();
}
}
if(behaviorVo.getEventTime_arr() != null) {
criteria.andEventTimeIn(behaviorVo.getEventTime_arr());
}
if(behaviorVo.getEventTime_gt() != null) {
criteria.andEventTimeGreaterThan(behaviorVo.getEventTime_gt());
}
if(behaviorVo.getEventTime_lt() != null) {
criteria.andEventTimeLessThan(behaviorVo.getEventTime_lt());
}
if(behaviorVo.getEventTime_gte() != null) {
criteria.andEventTimeGreaterThanOrEqualTo(behaviorVo.getEventTime_gte());
}
if(behaviorVo.getEventTime_lte() != null) {
criteria.andEventTimeLessThanOrEqualTo(behaviorVo.getEventTime_lte());
}
if(behaviorVo.getChannelUnid() != null) {
criteria.andChannelUnidEqualTo(behaviorVo.getChannelUnid());
}
if(behaviorVo.getChannelUnid_null() != null) {
if(behaviorVo.getChannelUnid_null().booleanValue()) {
criteria.andChannelUnidIsNull();
} else {
criteria.andChannelUnidIsNotNull();
}
}
if(behaviorVo.getChannelUnid_arr() != null) {
criteria.andChannelUnidIn(behaviorVo.getChannelUnid_arr());
}
if(behaviorVo.getChannelUnid_like() != null) {
criteria.andChannelUnidLike(behaviorVo.getChannelUnid_like());
}
if(behaviorVo.getTestPicFile() != null) {
criteria.andTestPicFileEqualTo(behaviorVo.getTestPicFile());
}
if(behaviorVo.getTestPicFile_null() != null) {
if(behaviorVo.getTestPicFile_null().booleanValue()) {
criteria.andTestPicFileIsNull();
} else {
criteria.andTestPicFileIsNotNull();
}
}
if(behaviorVo.getTestPicFile_arr() != null) {
criteria.andTestPicFileIn(behaviorVo.getTestPicFile_arr());
}
if(behaviorVo.getTestPicFile_like() != null) {
criteria.andTestPicFileLike(behaviorVo.getTestPicFile_like());
}
if(behaviorVo.getTestFrameNo() != null) {
criteria.andTestFrameNoEqualTo(behaviorVo.getTestFrameNo());
}
if(behaviorVo.getTestFrameNo_null() != null) {
if(behaviorVo.getTestFrameNo_null().booleanValue()) {
criteria.andTestFrameNoIsNull();
} else {
criteria.andTestFrameNoIsNotNull();
}
}
if(behaviorVo.getTestFrameNo_arr() != null) {
criteria.andTestFrameNoIn(behaviorVo.getTestFrameNo_arr());
}
if(behaviorVo.getTestFrameNo_like() != null) {
criteria.andTestFrameNoLike(behaviorVo.getTestFrameNo_like());
}
if(behaviorVo.getTaskName() != null) {
criteria.andTaskNameEqualTo(behaviorVo.getTaskName());
}
if(behaviorVo.getTaskName_null() != null) {
if(behaviorVo.getTaskName_null().booleanValue()) {
criteria.andTaskNameIsNull();
} else {
criteria.andTaskNameIsNotNull();
}
}
if(behaviorVo.getTaskName_arr() != null) {
criteria.andTaskNameIn(behaviorVo.getTaskName_arr());
}
if(behaviorVo.getTaskName_like() != null) {
criteria.andTaskNameLike(behaviorVo.getTaskName_like());
}
if(behaviorVo.getEventDataNum() != null) {
criteria.andEventDataNumEqualTo(behaviorVo.getEventDataNum());
}
if(behaviorVo.getEventDataNum_null() != null) {
if(behaviorVo.getEventDataNum_null().booleanValue()) {
criteria.andEventDataNumIsNull();
} else {
criteria.andEventDataNumIsNotNull();
}
}
if(behaviorVo.getEventDataNum_arr() != null) {
criteria.andEventDataNumIn(behaviorVo.getEventDataNum_arr());
}
if(behaviorVo.getEventDataNum_like() != null) {
criteria.andEventDataNumLike(behaviorVo.getEventDataNum_like());
}
return behaviorExample;
}
@Override
protected BaseService<Behavior> getService() {
return behaviorService;
}
}
\ No newline at end of file
package com.viontech.fanxing.forward.controller.base;
import com.viontech.fanxing.commons.base.BaseController;
import com.viontech.fanxing.commons.base.BaseExample;
import com.viontech.fanxing.commons.base.BaseMapper;
import com.viontech.fanxing.commons.base.BaseService;
import com.viontech.fanxing.forward.mapper.FlowEventMapper;
import com.viontech.fanxing.commons.model.FlowEvent;
import com.viontech.fanxing.commons.model.FlowEventExample;
import com.viontech.fanxing.forward.service.adapter.FlowEventService;
import com.viontech.fanxing.commons.vo.FlowEventVo;
import javax.annotation.Resource;
public abstract class FlowEventBaseController extends BaseController<FlowEvent, FlowEventVo> {
@Resource
protected FlowEventService flowEventService;
@Override
protected BaseExample getExample(FlowEventVo flowEventVo, int type) {
FlowEventExample flowEventExample = new FlowEventExample();
FlowEventExample.Criteria criteria = flowEventExample.createCriteria();
if(flowEventVo.getId() != null) {
criteria.andIdEqualTo(flowEventVo.getId());
}
if(flowEventVo.getId_arr() != null) {
criteria.andIdIn(flowEventVo.getId_arr());
}
if(flowEventVo.getId_gt() != null) {
criteria.andIdGreaterThan(flowEventVo.getId_gt());
}
if(flowEventVo.getId_lt() != null) {
criteria.andIdLessThan(flowEventVo.getId_lt());
}
if(flowEventVo.getId_gte() != null) {
criteria.andIdGreaterThanOrEqualTo(flowEventVo.getId_gte());
}
if(flowEventVo.getId_lte() != null) {
criteria.andIdLessThanOrEqualTo(flowEventVo.getId_lte());
}
if(flowEventVo.getUnid() != null) {
criteria.andUnidEqualTo(flowEventVo.getUnid());
}
if(flowEventVo.getUnid_arr() != null) {
criteria.andUnidIn(flowEventVo.getUnid_arr());
}
if(flowEventVo.getUnid_like() != null) {
criteria.andUnidLike(flowEventVo.getUnid_like());
}
if(flowEventVo.getTaskId() != null) {
criteria.andTaskIdEqualTo(flowEventVo.getTaskId());
}
if(flowEventVo.getTaskId_null() != null) {
if(flowEventVo.getTaskId_null().booleanValue()) {
criteria.andTaskIdIsNull();
} else {
criteria.andTaskIdIsNotNull();
}
}
if(flowEventVo.getTaskId_arr() != null) {
criteria.andTaskIdIn(flowEventVo.getTaskId_arr());
}
if(flowEventVo.getTaskId_gt() != null) {
criteria.andTaskIdGreaterThan(flowEventVo.getTaskId_gt());
}
if(flowEventVo.getTaskId_lt() != null) {
criteria.andTaskIdLessThan(flowEventVo.getTaskId_lt());
}
if(flowEventVo.getTaskId_gte() != null) {
criteria.andTaskIdGreaterThanOrEqualTo(flowEventVo.getTaskId_gte());
}
if(flowEventVo.getTaskId_lte() != null) {
criteria.andTaskIdLessThanOrEqualTo(flowEventVo.getTaskId_lte());
}
if(flowEventVo.getEventType() != null) {
criteria.andEventTypeEqualTo(flowEventVo.getEventType());
}
if(flowEventVo.getEventType_null() != null) {
if(flowEventVo.getEventType_null().booleanValue()) {
criteria.andEventTypeIsNull();
} else {
criteria.andEventTypeIsNotNull();
}
}
if(flowEventVo.getEventType_arr() != null) {
criteria.andEventTypeIn(flowEventVo.getEventType_arr());
}
if(flowEventVo.getEventType_like() != null) {
criteria.andEventTypeLike(flowEventVo.getEventType_like());
}
if(flowEventVo.getEventTime() != null) {
criteria.andEventTimeEqualTo(flowEventVo.getEventTime());
}
if(flowEventVo.getEventTime_null() != null) {
if(flowEventVo.getEventTime_null().booleanValue()) {
criteria.andEventTimeIsNull();
} else {
criteria.andEventTimeIsNotNull();
}
}
if(flowEventVo.getEventTime_arr() != null) {
criteria.andEventTimeIn(flowEventVo.getEventTime_arr());
}
if(flowEventVo.getEventTime_gt() != null) {
criteria.andEventTimeGreaterThan(flowEventVo.getEventTime_gt());
}
if(flowEventVo.getEventTime_lt() != null) {
criteria.andEventTimeLessThan(flowEventVo.getEventTime_lt());
}
if(flowEventVo.getEventTime_gte() != null) {
criteria.andEventTimeGreaterThanOrEqualTo(flowEventVo.getEventTime_gte());
}
if(flowEventVo.getEventTime_lte() != null) {
criteria.andEventTimeLessThanOrEqualTo(flowEventVo.getEventTime_lte());
}
if(flowEventVo.getDeviceCode() != null) {
criteria.andDeviceCodeEqualTo(flowEventVo.getDeviceCode());
}
if(flowEventVo.getDeviceCode_null() != null) {
if(flowEventVo.getDeviceCode_null().booleanValue()) {
criteria.andDeviceCodeIsNull();
} else {
criteria.andDeviceCodeIsNotNull();
}
}
if(flowEventVo.getDeviceCode_arr() != null) {
criteria.andDeviceCodeIn(flowEventVo.getDeviceCode_arr());
}
if(flowEventVo.getDeviceCode_like() != null) {
criteria.andDeviceCodeLike(flowEventVo.getDeviceCode_like());
}
if(flowEventVo.getDeviceName() != null) {
criteria.andDeviceNameEqualTo(flowEventVo.getDeviceName());
}
if(flowEventVo.getDeviceName_null() != null) {
if(flowEventVo.getDeviceName_null().booleanValue()) {
criteria.andDeviceNameIsNull();
} else {
criteria.andDeviceNameIsNotNull();
}
}
if(flowEventVo.getDeviceName_arr() != null) {
criteria.andDeviceNameIn(flowEventVo.getDeviceName_arr());
}
if(flowEventVo.getDeviceName_like() != null) {
criteria.andDeviceNameLike(flowEventVo.getDeviceName_like());
}
if(flowEventVo.getLocationCode() != null) {
criteria.andLocationCodeEqualTo(flowEventVo.getLocationCode());
}
if(flowEventVo.getLocationCode_null() != null) {
if(flowEventVo.getLocationCode_null().booleanValue()) {
criteria.andLocationCodeIsNull();
} else {
criteria.andLocationCodeIsNotNull();
}
}
if(flowEventVo.getLocationCode_arr() != null) {
criteria.andLocationCodeIn(flowEventVo.getLocationCode_arr());
}
if(flowEventVo.getLocationCode_like() != null) {
criteria.andLocationCodeLike(flowEventVo.getLocationCode_like());
}
if(flowEventVo.getLocationName() != null) {
criteria.andLocationNameEqualTo(flowEventVo.getLocationName());
}
if(flowEventVo.getLocationName_null() != null) {
if(flowEventVo.getLocationName_null().booleanValue()) {
criteria.andLocationNameIsNull();
} else {
criteria.andLocationNameIsNotNull();
}
}
if(flowEventVo.getLocationName_arr() != null) {
criteria.andLocationNameIn(flowEventVo.getLocationName_arr());
}
if(flowEventVo.getLocationName_like() != null) {
criteria.andLocationNameLike(flowEventVo.getLocationName_like());
}
if(flowEventVo.getPicName() != null) {
criteria.andPicNameEqualTo(flowEventVo.getPicName());
}
if(flowEventVo.getPicName_null() != null) {
if(flowEventVo.getPicName_null().booleanValue()) {
criteria.andPicNameIsNull();
} else {
criteria.andPicNameIsNotNull();
}
}
if(flowEventVo.getPicName_arr() != null) {
criteria.andPicNameIn(flowEventVo.getPicName_arr());
}
if(flowEventVo.getPicName_like() != null) {
criteria.andPicNameLike(flowEventVo.getPicName_like());
}
if(flowEventVo.getVideoName() != null) {
criteria.andVideoNameEqualTo(flowEventVo.getVideoName());
}
if(flowEventVo.getVideoName_null() != null) {
if(flowEventVo.getVideoName_null().booleanValue()) {
criteria.andVideoNameIsNull();
} else {
criteria.andVideoNameIsNotNull();
}
}
if(flowEventVo.getVideoName_arr() != null) {
criteria.andVideoNameIn(flowEventVo.getVideoName_arr());
}
if(flowEventVo.getVideoName_like() != null) {
criteria.andVideoNameLike(flowEventVo.getVideoName_like());
}
return flowEventExample;
}
@Override
protected BaseService<FlowEvent> getService() {
return flowEventService;
}
}
\ No newline at end of file
package com.viontech.fanxing.forward.controller.base;
import com.viontech.fanxing.commons.base.BaseController;
import com.viontech.fanxing.commons.base.BaseExample;
import com.viontech.fanxing.commons.base.BaseMapper;
import com.viontech.fanxing.commons.base.BaseService;
import com.viontech.fanxing.forward.mapper.ForwardMapper;
import com.viontech.fanxing.commons.model.Forward;
import com.viontech.fanxing.commons.model.ForwardExample;
import com.viontech.fanxing.forward.service.adapter.ForwardService;
import com.viontech.fanxing.commons.vo.ForwardVo;
import javax.annotation.Resource;
public abstract class ForwardBaseController extends BaseController<Forward, ForwardVo> {
@Resource
protected ForwardService forwardService;
@Override
protected BaseExample getExample(ForwardVo forwardVo, int type) {
ForwardExample forwardExample = new ForwardExample();
ForwardExample.Criteria criteria = forwardExample.createCriteria();
if(forwardVo.getId() != null) {
criteria.andIdEqualTo(forwardVo.getId());
}
if(forwardVo.getId_arr() != null) {
criteria.andIdIn(forwardVo.getId_arr());
}
if(forwardVo.getId_gt() != null) {
criteria.andIdGreaterThan(forwardVo.getId_gt());
}
if(forwardVo.getId_lt() != null) {
criteria.andIdLessThan(forwardVo.getId_lt());
}
if(forwardVo.getId_gte() != null) {
criteria.andIdGreaterThanOrEqualTo(forwardVo.getId_gte());
}
if(forwardVo.getId_lte() != null) {
criteria.andIdLessThanOrEqualTo(forwardVo.getId_lte());
}
if(forwardVo.getUnid() != null) {
criteria.andUnidEqualTo(forwardVo.getUnid());
}
if(forwardVo.getUnid_arr() != null) {
criteria.andUnidIn(forwardVo.getUnid_arr());
}
if(forwardVo.getUnid_like() != null) {
criteria.andUnidLike(forwardVo.getUnid_like());
}
if(forwardVo.getName() != null) {
criteria.andNameEqualTo(forwardVo.getName());
}
if(forwardVo.getName_arr() != null) {
criteria.andNameIn(forwardVo.getName_arr());
}
if(forwardVo.getName_like() != null) {
criteria.andNameLike(forwardVo.getName_like());
}
if(forwardVo.getUrl() != null) {
criteria.andUrlEqualTo(forwardVo.getUrl());
}
if(forwardVo.getUrl_arr() != null) {
criteria.andUrlIn(forwardVo.getUrl_arr());
}
if(forwardVo.getUrl_like() != null) {
criteria.andUrlLike(forwardVo.getUrl_like());
}
if(forwardVo.getTotal() != null) {
criteria.andTotalEqualTo(forwardVo.getTotal());
}
if(forwardVo.getTotal_arr() != null) {
criteria.andTotalIn(forwardVo.getTotal_arr());
}
if(forwardVo.getTotal_gt() != null) {
criteria.andTotalGreaterThan(forwardVo.getTotal_gt());
}
if(forwardVo.getTotal_lt() != null) {
criteria.andTotalLessThan(forwardVo.getTotal_lt());
}
if(forwardVo.getTotal_gte() != null) {
criteria.andTotalGreaterThanOrEqualTo(forwardVo.getTotal_gte());
}
if(forwardVo.getTotal_lte() != null) {
criteria.andTotalLessThanOrEqualTo(forwardVo.getTotal_lte());
}
if(forwardVo.getFailed() != null) {
criteria.andFailedEqualTo(forwardVo.getFailed());
}
if(forwardVo.getFailed_arr() != null) {
criteria.andFailedIn(forwardVo.getFailed_arr());
}
if(forwardVo.getFailed_gt() != null) {
criteria.andFailedGreaterThan(forwardVo.getFailed_gt());
}
if(forwardVo.getFailed_lt() != null) {
criteria.andFailedLessThan(forwardVo.getFailed_lt());
}
if(forwardVo.getFailed_gte() != null) {
criteria.andFailedGreaterThanOrEqualTo(forwardVo.getFailed_gte());
}
if(forwardVo.getFailed_lte() != null) {
criteria.andFailedLessThanOrEqualTo(forwardVo.getFailed_lte());
}
if(forwardVo.getLastSendTime() != null) {
criteria.andLastSendTimeEqualTo(forwardVo.getLastSendTime());
}
if(forwardVo.getLastSendTime_null() != null) {
if(forwardVo.getLastSendTime_null().booleanValue()) {
criteria.andLastSendTimeIsNull();
} else {
criteria.andLastSendTimeIsNotNull();
}
}
if(forwardVo.getLastSendTime_arr() != null) {
criteria.andLastSendTimeIn(forwardVo.getLastSendTime_arr());
}
if(forwardVo.getLastSendTime_gt() != null) {
criteria.andLastSendTimeGreaterThan(forwardVo.getLastSendTime_gt());
}
if(forwardVo.getLastSendTime_lt() != null) {
criteria.andLastSendTimeLessThan(forwardVo.getLastSendTime_lt());
}
if(forwardVo.getLastSendTime_gte() != null) {
criteria.andLastSendTimeGreaterThanOrEqualTo(forwardVo.getLastSendTime_gte());
}
if(forwardVo.getLastSendTime_lte() != null) {
criteria.andLastSendTimeLessThanOrEqualTo(forwardVo.getLastSendTime_lte());
}
if(forwardVo.getCreateTime() != null) {
criteria.andCreateTimeEqualTo(forwardVo.getCreateTime());
}
if(forwardVo.getCreateTime_arr() != null) {
criteria.andCreateTimeIn(forwardVo.getCreateTime_arr());
}
if(forwardVo.getCreateTime_gt() != null) {
criteria.andCreateTimeGreaterThan(forwardVo.getCreateTime_gt());
}
if(forwardVo.getCreateTime_lt() != null) {
criteria.andCreateTimeLessThan(forwardVo.getCreateTime_lt());
}
if(forwardVo.getCreateTime_gte() != null) {
criteria.andCreateTimeGreaterThanOrEqualTo(forwardVo.getCreateTime_gte());
}
if(forwardVo.getCreateTime_lte() != null) {
criteria.andCreateTimeLessThanOrEqualTo(forwardVo.getCreateTime_lte());
}
if(forwardVo.getStatus() != null) {
criteria.andStatusEqualTo(forwardVo.getStatus());
}
if(forwardVo.getStatus_arr() != null) {
criteria.andStatusIn(forwardVo.getStatus_arr());
}
if(forwardVo.getStatus_gt() != null) {
criteria.andStatusGreaterThan(forwardVo.getStatus_gt());
}
if(forwardVo.getStatus_lt() != null) {
criteria.andStatusLessThan(forwardVo.getStatus_lt());
}
if(forwardVo.getStatus_gte() != null) {
criteria.andStatusGreaterThanOrEqualTo(forwardVo.getStatus_gte());
}
if(forwardVo.getStatus_lte() != null) {
criteria.andStatusLessThanOrEqualTo(forwardVo.getStatus_lte());
}
return forwardExample;
}
@Override
protected BaseService<Forward> getService() {
return forwardService;
}
}
\ No newline at end of file
package com.viontech.fanxing.forward.controller.base;
import com.viontech.fanxing.commons.base.BaseController;
import com.viontech.fanxing.commons.base.BaseExample;
import com.viontech.fanxing.commons.base.BaseMapper;
import com.viontech.fanxing.commons.base.BaseService;
import com.viontech.fanxing.forward.mapper.ForwardConfigMapper;
import com.viontech.fanxing.commons.model.ForwardConfig;
import com.viontech.fanxing.commons.model.ForwardConfigExample;
import com.viontech.fanxing.forward.service.adapter.ForwardConfigService;
import com.viontech.fanxing.commons.vo.ForwardConfigVo;
import javax.annotation.Resource;
public abstract class ForwardConfigBaseController extends BaseController<ForwardConfig, ForwardConfigVo> {
@Resource
protected ForwardConfigService forwardConfigService;
@Override
protected BaseExample getExample(ForwardConfigVo forwardConfigVo, int type) {
ForwardConfigExample forwardConfigExample = new ForwardConfigExample();
ForwardConfigExample.Criteria criteria = forwardConfigExample.createCriteria();
if(forwardConfigVo.getId() != null) {
criteria.andIdEqualTo(forwardConfigVo.getId());
}
if(forwardConfigVo.getId_arr() != null) {
criteria.andIdIn(forwardConfigVo.getId_arr());
}
if(forwardConfigVo.getId_gt() != null) {
criteria.andIdGreaterThan(forwardConfigVo.getId_gt());
}
if(forwardConfigVo.getId_lt() != null) {
criteria.andIdLessThan(forwardConfigVo.getId_lt());
}
if(forwardConfigVo.getId_gte() != null) {
criteria.andIdGreaterThanOrEqualTo(forwardConfigVo.getId_gte());
}
if(forwardConfigVo.getId_lte() != null) {
criteria.andIdLessThanOrEqualTo(forwardConfigVo.getId_lte());
}
if(forwardConfigVo.getUnid() != null) {
criteria.andUnidEqualTo(forwardConfigVo.getUnid());
}
if(forwardConfigVo.getUnid_arr() != null) {
criteria.andUnidIn(forwardConfigVo.getUnid_arr());
}
if(forwardConfigVo.getUnid_like() != null) {
criteria.andUnidLike(forwardConfigVo.getUnid_like());
}
if(forwardConfigVo.getForwardId() != null) {
criteria.andForwardIdEqualTo(forwardConfigVo.getForwardId());
}
if(forwardConfigVo.getForwardId_arr() != null) {
criteria.andForwardIdIn(forwardConfigVo.getForwardId_arr());
}
if(forwardConfigVo.getForwardId_gt() != null) {
criteria.andForwardIdGreaterThan(forwardConfigVo.getForwardId_gt());
}
if(forwardConfigVo.getForwardId_lt() != null) {
criteria.andForwardIdLessThan(forwardConfigVo.getForwardId_lt());
}
if(forwardConfigVo.getForwardId_gte() != null) {
criteria.andForwardIdGreaterThanOrEqualTo(forwardConfigVo.getForwardId_gte());
}
if(forwardConfigVo.getForwardId_lte() != null) {
criteria.andForwardIdLessThanOrEqualTo(forwardConfigVo.getForwardId_lte());
}
if(forwardConfigVo.getEventCate() != null) {
criteria.andEventCateEqualTo(forwardConfigVo.getEventCate());
}
if(forwardConfigVo.getEventCate_arr() != null) {
criteria.andEventCateIn(forwardConfigVo.getEventCate_arr());
}
if(forwardConfigVo.getEventCate_like() != null) {
criteria.andEventCateLike(forwardConfigVo.getEventCate_like());
}
if(forwardConfigVo.getEventType() != null) {
criteria.andEventTypeEqualTo(forwardConfigVo.getEventType());
}
if(forwardConfigVo.getEventType_arr() != null) {
criteria.andEventTypeIn(forwardConfigVo.getEventType_arr());
}
if(forwardConfigVo.getEventType_like() != null) {
criteria.andEventTypeLike(forwardConfigVo.getEventType_like());
}
return forwardConfigExample;
}
@Override
protected BaseService<ForwardConfig> getService() {
return forwardConfigService;
}
}
\ No newline at end of file
package com.viontech.fanxing.forward.controller.web;
import com.viontech.fanxing.commons.base.BaseExample;
import com.viontech.fanxing.commons.base.BaseMapper;
import com.viontech.fanxing.commons.vo.BehaviorVo;
import com.viontech.fanxing.forward.controller.base.BehaviorBaseController;
import com.viontech.fanxing.commons.model.Behavior;
import com.viontech.fanxing.commons.model.BehaviorExample;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
@Controller
@RequestMapping("/behaviors")
public class BehaviorController extends BehaviorBaseController {
@Override
protected BaseExample getExample(BehaviorVo behaviorVo, int type) {
BehaviorExample behaviorExample = (BehaviorExample)super.getExample(behaviorVo,type);
return behaviorExample;
}
}
\ No newline at end of file
package com.viontech.fanxing.forward.controller.web;
import com.viontech.fanxing.commons.base.BaseExample;
import com.viontech.fanxing.commons.base.BaseMapper;
import com.viontech.fanxing.commons.vo.FlowDataVo;
import com.viontech.fanxing.forward.controller.base.FlowDataBaseController;
import com.viontech.fanxing.commons.model.FlowData;
import com.viontech.fanxing.commons.model.FlowDataExample;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
@Controller
@RequestMapping("/flowDatas")
public class FlowDataController extends FlowDataBaseController {
@Override
protected BaseExample getExample(FlowDataVo flowDataVo, int type) {
FlowDataExample flowDataExample = (FlowDataExample)super.getExample(flowDataVo,type);
return flowDataExample;
}
}
\ No newline at end of file
package com.viontech.fanxing.forward.controller.web;
import com.viontech.fanxing.commons.base.BaseExample;
import com.viontech.fanxing.commons.base.BaseMapper;
import com.viontech.fanxing.commons.vo.FlowEventVo;
import com.viontech.fanxing.forward.controller.base.FlowEventBaseController;
import com.viontech.fanxing.commons.model.FlowEvent;
import com.viontech.fanxing.commons.model.FlowEventExample;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
@Controller
@RequestMapping("/flowEvents")
public class FlowEventController extends FlowEventBaseController {
@Override
protected BaseExample getExample(FlowEventVo flowEventVo, int type) {
FlowEventExample flowEventExample = (FlowEventExample)super.getExample(flowEventVo,type);
return flowEventExample;
}
}
\ No newline at end of file
package com.viontech.fanxing.forward.controller.web;
import com.viontech.fanxing.commons.base.BaseExample;
import com.viontech.fanxing.commons.base.BaseMapper;
import com.viontech.fanxing.commons.vo.ForwardConfigVo;
import com.viontech.fanxing.forward.controller.base.ForwardConfigBaseController;
import com.viontech.fanxing.commons.model.ForwardConfig;
import com.viontech.fanxing.commons.model.ForwardConfigExample;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
@Controller
@RequestMapping("/forwardConfigs")
public class ForwardConfigController extends ForwardConfigBaseController {
@Override
protected BaseExample getExample(ForwardConfigVo forwardConfigVo, int type) {
ForwardConfigExample forwardConfigExample = (ForwardConfigExample)super.getExample(forwardConfigVo,type);
return forwardConfigExample;
}
}
\ No newline at end of file
package com.viontech.fanxing.forward.controller.web;
import com.viontech.fanxing.commons.base.BaseExample;
import com.viontech.fanxing.commons.base.BaseMapper;
import com.viontech.fanxing.commons.vo.ForwardVo;
import com.viontech.fanxing.forward.controller.base.ForwardBaseController;
import com.viontech.fanxing.commons.model.Forward;
import com.viontech.fanxing.commons.model.ForwardExample;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
@Controller
@RequestMapping("/forwards")
public class ForwardController extends ForwardBaseController {
@Override
protected BaseExample getExample(ForwardVo forwardVo, int type) {
ForwardExample forwardExample = (ForwardExample)super.getExample(forwardVo,type);
return forwardExample;
}
}
\ No newline at end of file
package com.viontech.fanxing.forward.controller.web;
import com.viontech.fanxing.commons.base.BaseExample;
import com.viontech.fanxing.commons.base.BaseMapper;
import com.viontech.fanxing.commons.vo.TrafficVo;
import com.viontech.fanxing.forward.controller.base.TrafficBaseController;
import com.viontech.fanxing.commons.model.Traffic;
import com.viontech.fanxing.commons.model.TrafficExample;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
@Controller
@RequestMapping("/traffics")
public class TrafficController extends TrafficBaseController {
@Override
protected BaseExample getExample(TrafficVo trafficVo, int type) {
TrafficExample trafficExample = (TrafficExample)super.getExample(trafficVo,type);
return trafficExample;
}
}
\ No newline at end of file
package com.viontech.fanxing.forward.mapper;
import com.viontech.fanxing.commons.base.BaseMapper;
import com.viontech.fanxing.commons.model.Behavior;
import com.viontech.fanxing.commons.model.BehaviorExample;
import java.util.List;
import org.apache.ibatis.annotations.Param;
public interface BehaviorMapper extends BaseMapper {
int countByExample(BehaviorExample example);
int deleteByExample(BehaviorExample example);
int deleteByPrimaryKey(Long id);
int insert(Behavior record);
int insertSelective(Behavior record);
List<Behavior> selectByExampleWithBLOBs(BehaviorExample example);
List<Behavior> selectByExample(BehaviorExample example);
Behavior selectByPrimaryKey(Long id);
int updateByExampleSelective(@Param("record") Behavior record, @Param("example") BehaviorExample example);
int updateByExampleWithBLOBs(@Param("record") Behavior record, @Param("example") BehaviorExample example);
int updateByExample(@Param("record") Behavior record, @Param("example") BehaviorExample example);
int updateByPrimaryKeySelective(Behavior record);
int updateByPrimaryKeyWithBLOBs(Behavior record);
int updateByPrimaryKey(Behavior record);
}
\ No newline at end of file
package com.viontech.fanxing.forward.mapper;
import com.viontech.fanxing.commons.base.BaseMapper;
import com.viontech.fanxing.commons.model.FlowData;
import com.viontech.fanxing.commons.model.FlowDataExample;
import java.util.List;
import org.apache.ibatis.annotations.Param;
public interface FlowDataMapper extends BaseMapper {
int countByExample(FlowDataExample example);
int deleteByExample(FlowDataExample example);
int deleteByPrimaryKey(Long id);
int insert(FlowData record);
int insertSelective(FlowData record);
List<FlowData> selectByExampleWithBLOBs(FlowDataExample example);
List<FlowData> selectByExample(FlowDataExample example);
FlowData selectByPrimaryKey(Long id);
int updateByExampleSelective(@Param("record") FlowData record, @Param("example") FlowDataExample example);
int updateByExampleWithBLOBs(@Param("record") FlowData record, @Param("example") FlowDataExample example);
int updateByExample(@Param("record") FlowData record, @Param("example") FlowDataExample example);
int updateByPrimaryKeySelective(FlowData record);
int updateByPrimaryKeyWithBLOBs(FlowData record);
int updateByPrimaryKey(FlowData record);
}
\ No newline at end of file
package com.viontech.fanxing.forward.mapper;
import com.viontech.fanxing.commons.base.BaseMapper;
import com.viontech.fanxing.commons.model.FlowEvent;
import com.viontech.fanxing.commons.model.FlowEventExample;
import java.util.List;
import org.apache.ibatis.annotations.Param;
public interface FlowEventMapper extends BaseMapper {
int countByExample(FlowEventExample example);
int deleteByExample(FlowEventExample example);
int deleteByPrimaryKey(Long id);
int insert(FlowEvent record);
int insertSelective(FlowEvent record);
List<FlowEvent> selectByExampleWithBLOBs(FlowEventExample example);
List<FlowEvent> selectByExample(FlowEventExample example);
FlowEvent selectByPrimaryKey(Long id);
int updateByExampleSelective(@Param("record") FlowEvent record, @Param("example") FlowEventExample example);
int updateByExampleWithBLOBs(@Param("record") FlowEvent record, @Param("example") FlowEventExample example);
int updateByExample(@Param("record") FlowEvent record, @Param("example") FlowEventExample example);
int updateByPrimaryKeySelective(FlowEvent record);
int updateByPrimaryKeyWithBLOBs(FlowEvent record);
int updateByPrimaryKey(FlowEvent record);
}
\ No newline at end of file
package com.viontech.fanxing.forward.mapper;
import com.viontech.fanxing.commons.base.BaseMapper;
import com.viontech.fanxing.commons.model.ForwardConfig;
import com.viontech.fanxing.commons.model.ForwardConfigExample;
import java.util.List;
import org.apache.ibatis.annotations.Param;
public interface ForwardConfigMapper extends BaseMapper {
int countByExample(ForwardConfigExample example);
int deleteByExample(ForwardConfigExample example);
int deleteByPrimaryKey(Long id);
int insert(ForwardConfig record);
int insertSelective(ForwardConfig record);
List<ForwardConfig> selectByExample(ForwardConfigExample example);
ForwardConfig selectByPrimaryKey(Long id);
int updateByExampleSelective(@Param("record") ForwardConfig record, @Param("example") ForwardConfigExample example);
int updateByExample(@Param("record") ForwardConfig record, @Param("example") ForwardConfigExample example);
int updateByPrimaryKeySelective(ForwardConfig record);
int updateByPrimaryKey(ForwardConfig record);
}
\ No newline at end of file
package com.viontech.fanxing.forward.mapper;
import com.viontech.fanxing.commons.base.BaseMapper;
import com.viontech.fanxing.commons.model.Forward;
import com.viontech.fanxing.commons.model.ForwardExample;
import java.util.List;
import org.apache.ibatis.annotations.Param;
public interface ForwardMapper extends BaseMapper {
int countByExample(ForwardExample example);
int deleteByExample(ForwardExample example);
int deleteByPrimaryKey(Long id);
int insert(Forward record);
int insertSelective(Forward record);
List<Forward> selectByExample(ForwardExample example);
Forward selectByPrimaryKey(Long id);
int updateByExampleSelective(@Param("record") Forward record, @Param("example") ForwardExample example);
int updateByExample(@Param("record") Forward record, @Param("example") ForwardExample example);
int updateByPrimaryKeySelective(Forward record);
int updateByPrimaryKey(Forward record);
}
\ No newline at end of file
package com.viontech.fanxing.forward.mapper;
import com.viontech.fanxing.commons.base.BaseMapper;
import com.viontech.fanxing.commons.model.Traffic;
import com.viontech.fanxing.commons.model.TrafficExample;
import java.util.List;
import org.apache.ibatis.annotations.Param;
public interface TrafficMapper extends BaseMapper {
int countByExample(TrafficExample example);
int deleteByExample(TrafficExample example);
int deleteByPrimaryKey(Long id);
int insert(Traffic record);
int insertSelective(Traffic record);
List<Traffic> selectByExampleWithBLOBs(TrafficExample example);
List<Traffic> selectByExample(TrafficExample example);
Traffic selectByPrimaryKey(Long id);
int updateByExampleSelective(@Param("record") Traffic record, @Param("example") TrafficExample example);
int updateByExampleWithBLOBs(@Param("record") Traffic record, @Param("example") TrafficExample example);
int updateByExample(@Param("record") Traffic record, @Param("example") TrafficExample example);
int updateByPrimaryKeySelective(Traffic record);
int updateByPrimaryKeyWithBLOBs(Traffic record);
int updateByPrimaryKey(Traffic record);
}
\ 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="com.viontech.fanxing.forward.mapper.ForwardConfigMapper" >
<resultMap id="BaseResultMapRoot" type="com.viontech.fanxing.commons.model.ForwardConfig" >
<id column="forwardConfig_id" property="id" />
<result column="forwardConfig_unid" property="unid" />
<result column="forwardConfig_forward_id" property="forwardId" />
<result column="forwardConfig_event_cate" property="eventCate" />
<result column="forwardConfig_event_type" property="eventType" />
</resultMap>
<resultMap id="BaseResultMap" type="com.viontech.fanxing.commons.model.ForwardConfig" extends="BaseResultMapRoot" />
<sql id="Example_Where_Clause" >
<where >
<foreach collection="oredCriteria" item="criteria" separator="or" >
<if test="criteria.valid" >
<trim prefix="(" suffix=")" prefixOverrides="and" >
<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 collection="criterion.value" item="listItem" open="(" close=")" 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="(" suffix=")" prefixOverrides="and" >
<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 collection="criterion.value" item="listItem" open="(" close=")" separator="," >
#{listItem}
</foreach>
</when>
</choose>
</foreach>
</trim>
</if>
</foreach>
</where>
</sql>
<sql id="Base_Column_List_Root" >
`forwardConfig`.id as forwardConfig_id, `forwardConfig`.unid as forwardConfig_unid,
`forwardConfig`.forward_id as forwardConfig_forward_id, `forwardConfig`.event_cate as forwardConfig_event_cate,
`forwardConfig`.event_type as forwardConfig_event_type
</sql>
<sql id="Base_Column_List" >
<if test="!(_parameter.getClass().getSimpleName() == 'ForwardConfigExample')" >
<include refid="com.viontech.fanxing.forward.mapper.ForwardConfigMapper.Base_Column_List_Root" />
</if>
<if test="_parameter.getClass().getSimpleName() == 'ForwardConfigExample'" >
<foreach collection="columnContainerSet" item="columns" separator="," >
<choose >
<when test="columns.tableName == 's_forward_config'.toString()" >
<if test="columns.valid" >
${columns.columnContainerStr}
</if>
<if test="!columns.valid" >
<include refid="com.viontech.fanxing.forward.mapper.ForwardConfigMapper.Base_Column_List_Root" />
</if>
</when>
</choose>
</foreach>
</if>
</sql>
<select id="selectByExample" resultMap="BaseResultMap" parameterType="com.viontech.fanxing.commons.model.ForwardConfigExample" >
select
<if test="distinct" >
distinct
</if>
<include refid="Base_Column_List" />
from `s_forward_config` `forwardConfig`
<if test="_parameter != null" >
<include refid="Example_Where_Clause" />
</if>
<if test="groupByClause != null" >
group by ${groupByClause}
</if>
<if test="orderByClause != null" >
order by ${orderByClause}
</if>
</select>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.Long" >
select
<include refid="Base_Column_List" />
from `s_forward_config` `forwardConfig`
where `forwardConfig`.id = #{id,jdbcType=BIGINT}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.Long" >
delete from `s_forward_config` `forwardConfig`
where id = #{id,jdbcType=BIGINT}
</delete>
<delete id="deleteByExample" parameterType="com.viontech.fanxing.commons.model.ForwardConfigExample" >
delete from `s_forward_config` `forwardConfig`
<if test="_parameter != null" >
<include refid="Example_Where_Clause" />
</if>
</delete>
<insert id="insert" parameterType="com.viontech.fanxing.commons.model.ForwardConfig" useGeneratedKeys="true" keyProperty="id" keyColumn="id" >
insert into `s_forward_config` (unid, forward_id, event_cate,
event_type)
values (#{unid,jdbcType=VARCHAR}, #{forwardId,jdbcType=BIGINT}, #{eventCate,jdbcType=VARCHAR},
#{eventType,jdbcType=VARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.viontech.fanxing.commons.model.ForwardConfig" useGeneratedKeys="true" keyProperty="id" keyColumn="id" >
insert into `s_forward_config`
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="unid != null" >
unid,
</if>
<if test="forwardId != null" >
forward_id,
</if>
<if test="eventCate != null" >
event_cate,
</if>
<if test="eventType != null" >
event_type,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="unid != null" >
#{unid,jdbcType=VARCHAR},
</if>
<if test="forwardId != null" >
#{forwardId,jdbcType=BIGINT},
</if>
<if test="eventCate != null" >
#{eventCate,jdbcType=VARCHAR},
</if>
<if test="eventType != null" >
#{eventType,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<select id="countByExample" parameterType="com.viontech.fanxing.commons.model.ForwardConfigExample" resultType="java.lang.Integer" >
select count(*) from `s_forward_config` `forwardConfig`
<if test="_parameter != null" >
<include refid="Example_Where_Clause" />
</if>
</select>
<update id="updateByExampleSelective" parameterType="map" >
update `s_forward_config` `forwardConfig`
<set >
<if test="record.id != null" >
id = #{record.id,jdbcType=BIGINT},
</if>
<if test="record.unid != null" >
unid = #{record.unid,jdbcType=VARCHAR},
</if>
<if test="record.forwardId != null" >
forward_id = #{record.forwardId,jdbcType=BIGINT},
</if>
<if test="record.eventCate != null" >
event_cate = #{record.eventCate,jdbcType=VARCHAR},
</if>
<if test="record.eventType != null" >
event_type = #{record.eventType,jdbcType=VARCHAR},
</if>
</set>
<if test="_parameter != null" >
<include refid="Update_By_Example_Where_Clause" />
</if>
</update>
<update id="updateByExample" parameterType="map" >
update `s_forward_config` `forwardConfig`
set id = #{record.id,jdbcType=BIGINT},
unid = #{record.unid,jdbcType=VARCHAR},
forward_id = #{record.forwardId,jdbcType=BIGINT},
event_cate = #{record.eventCate,jdbcType=VARCHAR},
event_type = #{record.eventType,jdbcType=VARCHAR}
<if test="_parameter != null" >
<include refid="Update_By_Example_Where_Clause" />
</if>
</update>
<update id="updateByPrimaryKeySelective" parameterType="com.viontech.fanxing.commons.model.ForwardConfig" >
update `s_forward_config`
<set >
<if test="unid != null" >
unid = #{unid,jdbcType=VARCHAR},
</if>
<if test="forwardId != null" >
forward_id = #{forwardId,jdbcType=BIGINT},
</if>
<if test="eventCate != null" >
event_cate = #{eventCate,jdbcType=VARCHAR},
</if>
<if test="eventType != null" >
event_type = #{eventType,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=BIGINT}
</update>
<update id="updateByPrimaryKey" parameterType="com.viontech.fanxing.commons.model.ForwardConfig" >
update `s_forward_config`
set unid = #{unid,jdbcType=VARCHAR},
forward_id = #{forwardId,jdbcType=BIGINT},
event_cate = #{eventCate,jdbcType=VARCHAR},
event_type = #{eventType,jdbcType=VARCHAR}
where id = #{id,jdbcType=BIGINT}
</update>
</mapper>
\ No newline at end of file
package com.viontech.fanxing.forward.service.adapter;
import com.viontech.fanxing.commons.base.BaseService;
import com.viontech.fanxing.commons.model.Behavior;
public interface BehaviorService extends BaseService<Behavior> {
}
\ No newline at end of file
package com.viontech.fanxing.forward.service.adapter;
import com.viontech.fanxing.commons.base.BaseService;
import com.viontech.fanxing.commons.model.FlowData;
public interface FlowDataService extends BaseService<FlowData> {
}
\ No newline at end of file
package com.viontech.fanxing.forward.service.adapter;
import com.viontech.fanxing.commons.base.BaseService;
import com.viontech.fanxing.commons.model.FlowEvent;
public interface FlowEventService extends BaseService<FlowEvent> {
}
\ No newline at end of file
package com.viontech.fanxing.forward.service.adapter;
import com.viontech.fanxing.commons.base.BaseService;
import com.viontech.fanxing.commons.model.ForwardConfig;
public interface ForwardConfigService extends BaseService<ForwardConfig> {
}
\ No newline at end of file
package com.viontech.fanxing.forward.service.adapter;
import com.viontech.fanxing.commons.base.BaseService;
import com.viontech.fanxing.commons.model.Forward;
public interface ForwardService extends BaseService<Forward> {
}
\ No newline at end of file
package com.viontech.fanxing.forward.service.adapter;
import com.viontech.fanxing.commons.base.BaseService;
import com.viontech.fanxing.commons.model.Traffic;
public interface TrafficService extends BaseService<Traffic> {
}
\ No newline at end of file
package com.viontech.fanxing.forward.service.impl;
import com.viontech.fanxing.commons.base.BaseMapper;
import com.viontech.fanxing.commons.base.BaseServiceImpl;
import com.viontech.fanxing.forward.mapper.BehaviorMapper;
import com.viontech.fanxing.commons.model.Behavior;
import com.viontech.fanxing.forward.service.adapter.BehaviorService;
import javax.annotation.Resource;
import org.springframework.stereotype.Service;
@Service
public class BehaviorServiceImpl extends BaseServiceImpl<Behavior> implements BehaviorService {
@Resource
private BehaviorMapper behaviorMapper;
@Override
public BaseMapper<Behavior> getMapper() {
return behaviorMapper;
}
}
\ No newline at end of file
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!