Commit 68e1dc05 authored by 周健威's avatar 周健威

修改代码

parent 66213e1f
package com.upyuns.platform.rs.datacenter.entity;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import tk.mybatis.mapper.annotation.KeySql;
import javax.persistence.Column;
import javax.persistence.Id;
import javax.persistence.Table;
import javax.persistence.Transient;
import java.util.Date;
@Data
@Table(name = "rscp_monitorimage")
@ApiModel(description = "")
public class RscpMonitorimage implements java.io.Serializable {
/** 版本号 */
private static final long serialVersionUID = -6625661497803837040L;
@Id
@KeySql(useGeneratedKeys = true)
@Column(name = "id",insertable = false)
@ApiModelProperty(value = "")
private Integer id;
private String title;// 资源的中文标题
private String resourcename;// 资源唯一的标识名字
private String srs;// 资源的坐标系
private String extentSrs;// 四至范围的坐标系
private String extent;// 数据有效四至地理范围
private String legendurl;// 图例url
private Integer status;// 状态,-1删除,0,等待处理,1,等待传输,2、已完成
private String dataPath;// 存储路径
private String metajson;// 补充信息,以json形式表现
private String datatype;// 格式类型 : 1、tif 2、shp 等
private String orderId; // 订单id
private String recordId;// 推送id
private Date createTime;// 创建时间
private Date startTime; //开始时间
private Date endTime; //结束时间
private String areaCode; // 区域码
private String areaName; // 区域名称
private String resolution;
private String layers; //图层标识
private String monitorType; //监测类型
// 兼容旧版本
@Transient
private String extent_srs;
@Transient
private String data_path;
@Transient
private Date create_time;
private Date finishTime;// 完成时间
@ApiModelProperty(value = "地图服务地址")
private String url;
/* This code was generated by TableGo tools, mark 1 end. */
/* This code was generated by TableGo tools, mark 2 begin. */
}
\ No newline at end of file
package com.upyuns.platform.rs.datacenter.entity;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import tk.mybatis.mapper.annotation.KeySql;
import javax.persistence.Column;
import javax.persistence.Id;
import javax.persistence.Table;
import javax.persistence.Transient;
import java.util.Date;
@Data
@Table(name = "rscp_mosaicimage")
@ApiModel(description = "")
public class RscpMosaicimage implements java.io.Serializable {
/** 版本号 */
private static final long serialVersionUID = -6625661497803837040L;
@Id
@KeySql(useGeneratedKeys = true)
@Column(name = "id",insertable = false)
@ApiModelProperty(value = "")
private Integer id;
private String title;// 资源的中文标题
private String resourcename;// 资源唯一的标识名字
private String srs;// 资源的坐标系
private String extentSrs;// 四至范围的坐标系
private String extent;// 数据有效四至地理范围
private String legendurl;// 图例url
private Integer status;// 状态,-1删除,0,等待处理,1,等待传输,2、已完成
private String dataPath;// 存储路径
private String metajson;// 补充信息,以json形式表现
private String datatype;// 格式类型 : 1、tif 2、shp 等
private String orderId; // 订单id
private String recordId;// 推送id
private Date createTime;// 创建时间
private Date startTime; //开始时间
private Date endTime; //结束时间
private String areaCode; // 区域码
private String areaName; // 区域名称
private String resolution;
private String layers; //图层标识
private String monitorType; //监测类型
// 兼容旧版本
@Transient
private String extent_srs;
@Transient
private String data_path;
@Transient
private Date create_time;
private Date finishTime;// 完成时间
@ApiModelProperty(value = "地图服务地址")
private String url;
/* This code was generated by TableGo tools, mark 1 end. */
/* This code was generated by TableGo tools, mark 2 begin. */
}
\ No newline at end of file
......@@ -102,11 +102,36 @@
<artifactId>gt-jdbc-postgis</artifactId>
<version>24.3</version>
</dependency>
<!--mybatis逆向生成插件核心-->
<dependency>
<groupId>org.mybatis.generator</groupId>
<artifactId>mybatis-generator-core</artifactId>
<version>1.3.5</version>
</dependency>
</dependencies>
<build>
<finalName>rs-datacenter</finalName>
<plugins>
<plugin>
<groupId>org.mybatis.generator</groupId>
<artifactId>mybatis-generator-maven-plugin</artifactId>
<version>1.3.5</version>
<dependencies>
<dependency>
<groupId>org.postgresql</groupId>
<artifactId>postgresql</artifactId>
<version>9.4.1212</version>
</dependency>
</dependencies>
<configuration>
<verbose>true</verbose>
<overwrite>true</overwrite>
<configurationFile>${project.basedir}/src/main/resources/generatorConfig.xml</configurationFile>
</configuration>
</plugin>
<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
......
package com.upyuns.platform.rs.datacenter.biz;
import com.github.wxiaoqi.security.common.biz.BaseBiz;
import com.upyuns.platform.rs.datacenter.entity.RscpMonitorimage;
import com.upyuns.platform.rs.datacenter.mapper.RscpMonitorimageMapper;
import org.springframework.stereotype.Service;
@Service
public class RscpMonitorimageBiz extends BaseBiz<RscpMonitorimageMapper, RscpMonitorimage> {
}
package com.upyuns.platform.rs.datacenter.biz;
import com.github.wxiaoqi.security.common.biz.BaseBiz;
import com.upyuns.platform.rs.datacenter.entity.RscpMosaicimage;
import com.upyuns.platform.rs.datacenter.mapper.RscpMosaicimageMapper;
import org.springframework.stereotype.Service;
@Service
public class RscpMosaicimageBiz extends BaseBiz<RscpMosaicimageMapper, RscpMosaicimage> {
}
package com.upyuns.platform.rs.datacenter.mapper;
import com.upyuns.platform.rs.datacenter.entity.RscpMonitorimage;
import tk.mybatis.mapper.common.Mapper;
public interface RscpMonitorimageMapper extends Mapper<RscpMonitorimage> {
}
\ No newline at end of file
package com.upyuns.platform.rs.datacenter.mapper;
import com.upyuns.platform.rs.datacenter.entity.RscpMosaicimage;
import tk.mybatis.mapper.common.Mapper;
public interface RscpMosaicimageMapper extends Mapper<RscpMosaicimage> {
}
\ No newline at end of file
package com.upyuns.platform.rs.datacenter.rest;
import com.github.wxiaoqi.security.auth.client.annotation.IgnoreUserToken;
import com.github.wxiaoqi.security.common.msg.ObjectRestResponse;
import com.github.wxiaoqi.security.common.rest.BaseController;
import com.upyuns.platform.rs.datacenter.biz.RscpMonitorimageBiz;
import com.upyuns.platform.rs.datacenter.biz.RscpMosaicimageBiz;
import com.upyuns.platform.rs.datacenter.entity.RscpMonitorimage;
import com.upyuns.platform.rs.datacenter.entity.RscpMosaicimage;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;
import java.util.List;
@RestController
@RequestMapping("/web/rscpMonitorimage")
public class RscpMonitorimageController extends BaseController<RscpMonitorimageBiz, RscpMonitorimage> {
@RequestMapping(value = "/app/unauth/all", method = RequestMethod.GET)
@IgnoreUserToken
public ObjectRestResponse unauthQuery() {
List<RscpMonitorimage> list = baseBiz.selectByWeekend(w -> {
w.andEqualTo(RscpMonitorimage::getStatus, 2);
return w;
}, "create_time asc");
return ObjectRestResponse.succ(list);
}
}
\ No newline at end of file
package com.upyuns.platform.rs.datacenter.rest;
import cn.hutool.core.collection.CollUtil;
import com.github.wxiaoqi.security.auth.client.annotation.IgnoreUserToken;
import com.github.wxiaoqi.security.common.msg.ObjectRestResponse;
import com.github.wxiaoqi.security.common.rest.BaseController;
import com.github.wxiaoqi.security.common.util.AssertUtils;
import com.upyuns.platform.rs.datacenter.biz.RscpMosaicimageBiz;
import com.upyuns.platform.rs.datacenter.biz.RscpStorageJsonBiz;
import com.upyuns.platform.rs.datacenter.entity.RscpImagePrice;
import com.upyuns.platform.rs.datacenter.entity.RscpMosaicimage;
import com.upyuns.platform.rs.datacenter.entity.RscpStorageJson;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;
import java.util.List;
import java.util.stream.Collectors;
import static com.github.wxiaoqi.security.common.constant.CommonConstants.SYS_FALSE;
import static com.github.wxiaoqi.security.common.constant.CommonConstants.SYS_TRUE;
@RestController
@RequestMapping("/web/rscpMosaicimage")
public class RscpMosaicimageController extends BaseController<RscpMosaicimageBiz, RscpMosaicimage> {
@RequestMapping(value = "/app/unauth/all", method = RequestMethod.GET)
@IgnoreUserToken
public ObjectRestResponse unauthQuery() {
List<RscpMosaicimage> list = baseBiz.selectByWeekend(w -> {
w.andEqualTo(RscpMosaicimage::getStatus, 2);
return w;
}, "create_time asc");
return ObjectRestResponse.succ(list);
}
}
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE generatorConfiguration
PUBLIC "-//mybatis.org//DTD MyBatis Generator Configuration 1.0//EN"
"http://mybatis.org/dtd/mybatis-generator-config_1_0.dtd">
<generatorConfiguration>
<!-- 配置mysql 驱动jar包路径.用了绝对路径 -->
<classPathEntry location="/Users/zhoujianwei/.m2/repository/postgresql/postgresql/9.2-1002.jdbc4/postgresql-9.2-1002.jdbc4.jar" />
<context id="wangyongzhi_mysql_tables" targetRuntime="MyBatis3">
<!-- 防止生成的代码中有很多注释,加入下面的配置控制 -->
<commentGenerator>
<property name="suppressAllComments" value="true" />
<property name="suppressDate" value="true" />
</commentGenerator>
<!-- 数据库连接 -->
<!-- connectionURL="jdbc:mysql://localhost:3306/vueblog2?useUnicode=true&amp;characterEncoding=UTF-8"-->
<jdbcConnection driverClass="org.postgresql.Driver"
connectionURL="jdbc:postgresql://10.5.52.6:5432/rsclouds_platform"
userId="postgres"
password="root">
<property name="nullCatalogMeansCurrent" value="true"/>
</jdbcConnection>
<javaTypeResolver >
<property name="forceBigDecimals" value="false" />
</javaTypeResolver>
<!-- 数据表对应的model层 -->
<javaModelGenerator targetPackage="com.upyuns.platform.rs.datacenter.entity" targetProject="/Users/zhoujianwei/opt/rscp/">
<property name="enableSubPackages" value="true" />
<property name="trimStrings" value="true" />
</javaModelGenerator>
<!-- sql mapper 映射配置文件 -->
<sqlMapGenerator targetPackage="com.upyuns.platform.rs.datacenter.mapper" targetProject="/Users/zhoujianwei/opt/rscp/">
<property name="enableSubPackages" value="true" />
</sqlMapGenerator>
<!-- mybatis3中的mapper接口 -->
<javaClientGenerator type="XMLMAPPER" targetPackage="com.upyuns.platform.rs.datacenter.mapper" targetProject="/Users/zhoujianwei/opt/rscp/">
<property name="enableSubPackages" value="true" />
</javaClientGenerator>
<!-- <table schema="public" tableName="rscp_mosaicimage" domainObjectName="RscpMosaicimage"-->
<!-- enableCountByExample="false" enableUpdateByExample="false"-->
<!-- enableDeleteByExample="false" enableSelectByExample="false"-->
<!-- selectByExampleQueryId="false">-->
<!-- </table>-->
<table schema="public" tableName="rscp_monitorimage" domainObjectName="RscpMonitorimage"
enableCountByExample="false" enableUpdateByExample="false"
enableDeleteByExample="false" enableSelectByExample="false"
selectByExampleQueryId="false">
</table>
</context>
</generatorConfiguration>
\ 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">
<!-- rscp_image_input_log -->
<mapper namespace="com.upyuns.platform.rs.datacenter.mapper.RscpMonitorimageMapper">
<!-- This code was generated by TableGo tools, mark 1 begin. -->
<!-- 字段映射 -->
<resultMap id="rscpMonitorimageMap" type="com.upyuns.platform.rs.datacenter.entity.RscpMonitorimage">
<id column="id" jdbcType="BIGINT" property="id" />
<result column="title" jdbcType="VARCHAR" property="title" />
<result column="resourcename" jdbcType="VARCHAR" property="resourcename" />
<result column="srs" jdbcType="VARCHAR" property="srs" />
<result column="extent_srs" jdbcType="VARCHAR" property="extentSrs" />
<result column="extent" jdbcType="VARCHAR" property="extent" />
<result column="legendurl" jdbcType="VARCHAR" property="legendurl" />
<result column="status" jdbcType="SMALLINT" property="status" />
<result column="data_path" jdbcType="VARCHAR" property="dataPath" />
<result column="metajson" jdbcType="VARCHAR" property="metajson" />
<result column="datatype" jdbcType="VARCHAR" property="datatype" />
<result column="order_id" jdbcType="VARCHAR" property="orderId" />
<result column="record_id" jdbcType="VARCHAR" property="recordId" />
<result column="create_time" jdbcType="TIMESTAMP" property="createTime" />
<result column="area_code" jdbcType="VARCHAR" property="areaCode" />
<result column="start_time" jdbcType="TIMESTAMP" property="startTime" />
<result column="end_time" jdbcType="TIMESTAMP" property="endTime" />
<result column="area_name" jdbcType="VARCHAR" property="areaName" />
<result column="layers" jdbcType="VARCHAR" property="layers" />
<result column="monitor_type" jdbcType="VARCHAR" property="monitorType" />
<result column="finish_time" jdbcType="TIMESTAMP" property="finishTime" />
<result column="url" jdbcType="VARCHAR" property="url" />
</resultMap>
<!-- This code was generated by TableGo tools, mark 1 end. -->
<!-- This code was generated by TableGo tools, mark 2 begin. -->
<!-- 表查询字段 -->
<!-- <sql id="allColumns">-->
<!-- riil.id, riil.crt_time, riil.upd_time, riil.status, riil.context_json-->
<!-- </sql>-->
<!-- This code was generated by TableGo tools, mark 2 end. -->
</mapper>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<!-- rscp_image_input_log -->
<mapper namespace="com.upyuns.platform.rs.datacenter.mapper.RscpMosaicimageMapper">
<!-- This code was generated by TableGo tools, mark 1 begin. -->
<!-- 字段映射 -->
<resultMap id="rscpMosaicimageMap" type="com.upyuns.platform.rs.datacenter.entity.RscpMosaicimage">
<id column="id" jdbcType="BIGINT" property="id" />
<result column="title" jdbcType="VARCHAR" property="title" />
<result column="resourcename" jdbcType="VARCHAR" property="resourcename" />
<result column="srs" jdbcType="VARCHAR" property="srs" />
<result column="extent_srs" jdbcType="VARCHAR" property="extentSrs" />
<result column="extent" jdbcType="VARCHAR" property="extent" />
<result column="status" jdbcType="SMALLINT" property="status" />
<result column="data_path" jdbcType="VARCHAR" property="dataPath" />
<result column="metajson" jdbcType="VARCHAR" property="metajson" />
<result column="order_id" jdbcType="VARCHAR" property="orderId" />
<result column="record_id" jdbcType="VARCHAR" property="recordId" />
<result column="create_time" jdbcType="TIMESTAMP" property="createTime" />
<result column="start_time" jdbcType="VARCHAR" property="startTime" />
<result column="end_time" jdbcType="VARCHAR" property="endTime" />
<result column="area_code" jdbcType="VARCHAR" property="areaCode" />
<result column="area_name" jdbcType="VARCHAR" property="areaName" />
<result column="resolution" jdbcType="VARCHAR" property="resolution" />
<result column="layers" jdbcType="VARCHAR" property="layers" />
<result column="finish_time" jdbcType="TIMESTAMP" property="finishTime" />
<result column="url" jdbcType="VARCHAR" property="url" />
</resultMap>
<!-- This code was generated by TableGo tools, mark 1 end. -->
<!-- This code was generated by TableGo tools, mark 2 begin. -->
<!-- 表查询字段 -->
<!-- <sql id="allColumns">-->
<!-- riil.id, riil.crt_time, riil.upd_time, riil.status, riil.context_json-->
<!-- </sql>-->
<!-- This code was generated by TableGo tools, mark 2 end. -->
</mapper>
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment