Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
R
rs-cloud-platform
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
周健威
rs-cloud-platform
Commits
78de4310
Commit
78de4310
authored
Dec 08, 2020
by
unset
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/dev' into dev
parents
d8b16402
1db128e4
Changes
16
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
16 changed files
with
1220 additions
and
3 deletions
+1220
-3
BaseBiz.java
.../java/com/github/wxiaoqi/security/common/biz/BaseBiz.java
+63
-0
generator.properties
...les/ace-generator/src/main/resources/generator.properties
+2
-1
generator.properties
...modules/ace-generator/target/classes/generator.properties
+2
-1
RscpAreaInfo.java
...om/upyuns/platform/rs/datacenter/entity/RscpAreaInfo.java
+358
-0
RscpImagePrice.java
.../upyuns/platform/rs/datacenter/entity/RscpImagePrice.java
+508
-0
pom.xml
rs-datacenter/rs-datacenter-server/pom.xml
+18
-0
RscpAreaInfoBiz.java
...om/upyuns/platform/rs/datacenter/biz/RscpAreaInfoBiz.java
+23
-0
RscpImagePriceBiz.java
.../upyuns/platform/rs/datacenter/biz/RscpImagePriceBiz.java
+11
-0
RscpAreaInfoMapper.java
...uns/platform/rs/datacenter/mapper/RscpAreaInfoMapper.java
+13
-0
RscpImagePriceMapper.java
...s/platform/rs/datacenter/mapper/RscpImagePriceMapper.java
+9
-0
RscpAreaInfoController.java
...s/platform/rs/datacenter/rest/RscpAreaInfoController.java
+36
-0
RscpImageDataTotalController.java
...form/rs/datacenter/rest/RscpImageDataTotalController.java
+19
-0
RscpImagePriceController.java
...platform/rs/datacenter/rest/RscpImagePriceController.java
+63
-0
RscmAreaInfoMapper.xml
...r-server/src/main/resources/mapper/RscmAreaInfoMapper.xml
+49
-0
RscpImageDataTotalMapper.xml
...er/src/main/resources/mapper/RscpImageDataTotalMapper.xml
+4
-1
RscpImagePriceMapper.xml
...server/src/main/resources/mapper/RscpImagePriceMapper.xml
+42
-0
No files found.
ace-common/src/main/java/com/github/wxiaoqi/security/common/biz/BaseBiz.java
View file @
78de4310
package
com
.
github
.
wxiaoqi
.
security
.
common
.
biz
;
import
cn.hutool.core.util.StrUtil
;
import
com.github.pagehelper.Page
;
import
com.github.pagehelper.PageHelper
;
import
com.github.wxiaoqi.security.common.msg.TableResultResponse
;
...
...
@@ -8,11 +9,15 @@ import com.github.wxiaoqi.security.common.util.Query;
import
org.springframework.beans.factory.annotation.Autowired
;
import
tk.mybatis.mapper.common.Mapper
;
import
tk.mybatis.mapper.entity.Example
;
import
tk.mybatis.mapper.weekend.Fn
;
import
tk.mybatis.mapper.weekend.WeekendSqls
;
import
java.lang.reflect.ParameterizedType
;
import
java.util.Collection
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.function.Function
;
import
java.util.function.Supplier
;
/**
* Created by Mr.AG
...
...
@@ -24,6 +29,9 @@ public abstract class BaseBiz<M extends Mapper<T>, T> {
@Autowired
protected
M
mapper
;
//第二个泛型class
protected
Class
<
T
>
entityClass
=
(
Class
<
T
>)
((
ParameterizedType
)
getClass
().
getGenericSuperclass
()).
getActualTypeArguments
()[
1
];
public
void
setMapper
(
M
mapper
)
{
this
.
mapper
=
mapper
;
}
...
...
@@ -37,6 +45,61 @@ public abstract class BaseBiz<M extends Mapper<T>, T> {
return
mapper
.
selectByPrimaryKey
(
id
);
}
public
void
updateByWeekendSelective
(
T
target
,
Function
<
WeekendSqls
<
T
>,
WeekendSqls
<
T
>>
where
)
{
WeekendSqls
whereSqls
=
where
.
apply
(
WeekendSqls
.<
T
>
custom
());
Example
.
Builder
builder
=
new
Example
.
Builder
(
entityClass
)
.
where
(
whereSqls
);
Example
example
=
builder
.
build
();
mapper
.
updateByExampleSelective
(
target
,
example
);
}
public
List
<
T
>
selectByWeekend
(
Function
<
WeekendSqls
<
T
>,
WeekendSqls
<
T
>>
where
,
String
orderStr
)
{
WeekendSqls
whereSqls
=
where
.
apply
(
WeekendSqls
.<
T
>
custom
());
Example
.
Builder
builder
=
new
Example
.
Builder
(
entityClass
)
.
where
(
whereSqls
);
Example
example
=
builder
.
build
();
if
(
StrUtil
.
isNotBlank
(
orderStr
))
{
example
.
setOrderByClause
(
orderStr
);
}
return
selectByExample
(
example
);
}
public
List
<
T
>
selectByWeekendsOr
(
Supplier
<
List
<
WeekendSqls
<
T
>>>
where
,
String
orderStr
)
{
List
<
WeekendSqls
<
T
>>
whereSqlss
=
where
.
get
();
Example
.
Builder
builder
=
new
Example
.
Builder
(
entityClass
);
for
(
WeekendSqls
weekendSqls
:
whereSqlss
)
{
builder
.
andWhere
(
weekendSqls
);
}
Example
example
=
builder
.
build
();
if
(
StrUtil
.
isNotBlank
(
orderStr
))
{
example
.
setOrderByClause
(
orderStr
);
}
return
selectByExample
(
example
);
}
public
List
<
T
>
selectByWeekend
(
Function
<
WeekendSqls
<
T
>,
WeekendSqls
<
T
>>
where
)
{
return
selectByWeekend
(
where
,
null
);
}
public
List
<
T
>
selectByAttrs
(
Fn
<
T
,
Object
>
attrFn
,
List
attrFnList
)
{
return
selectByExample
(
new
Example
.
Builder
(
entityClass
)
.
where
(
WeekendSqls
.<
T
>
custom
().
andIn
(
attrFn
,
attrFnList
)).
build
());
}
public
List
<
T
>
selectBetween
(
Fn
<
T
,
Object
>
attrFn
,
Object
start
,
Object
end
)
{
return
selectBetween
(
attrFn
,
start
,
end
,
null
);
}
public
List
<
T
>
selectBetween
(
Fn
<
T
,
Object
>
attrFn
,
Object
start
,
Object
end
,
Fn
<
T
,
Object
>
deleteAttrFn
)
{
WeekendSqls
<
T
>
weekendSqls
=
WeekendSqls
.<
T
>
custom
()
.
andGreaterThanOrEqualTo
(
attrFn
,
start
)
.
andLessThanOrEqualTo
(
attrFn
,
end
);
if
(
null
!=
deleteAttrFn
)
{
weekendSqls
.
andEqualTo
(
deleteAttrFn
,
0
);
}
return
selectByExample
(
new
Example
.
Builder
(
entityClass
)
.
where
(
weekendSqls
).
build
());
}
public
List
<
T
>
selectList
(
T
entity
)
{
return
mapper
.
select
(
entity
);
...
...
ace-modules/ace-generator/src/main/resources/generator.properties
View file @
78de4310
...
...
@@ -3,7 +3,8 @@
#\u5305\u540D
package
=
com.upyuns.platform.rs.website
#\u4F5C\u8005
author
=
jiaoruizhen
#author=jiaoruizhen
author
=
zjw
#Email
email
=
jiaoruizhen@126.com
#\u8868\u524D\u9519\u8BEF\u7684Unicode\u5B57\u7B26\u4E32!
...
...
ace-modules/ace-generator/target/classes/generator.properties
View file @
78de4310
...
...
@@ -3,7 +3,8 @@
#\u5305\u540D
package
=
com.upyuns.platform.rs.website
#\u4F5C\u8005
author
=
jiaoruizhen
#author=jiaoruizhen
author
=
zjw
#Email
email
=
jiaoruizhen@126.com
#\u8868\u524D\u9519\u8BEF\u7684Unicode\u5B57\u7B26\u4E32!
...
...
rs-datacenter/rs-datacenter-api/src/main/java/com/upyuns/platform/rs/datacenter/entity/RscpAreaInfo.java
0 → 100644
View file @
78de4310
package
com
.
upyuns
.
platform
.
rs
.
datacenter
.
entity
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
javax.persistence.Table
;
import
java.math.BigDecimal
;
@Data
@Table
(
name
=
"rscm_area_info"
)
@ApiModel
(
description
=
""
)
public
class
RscpAreaInfo
implements
java
.
io
.
Serializable
{
/** 版本号 */
private
static
final
long
serialVersionUID
=
-
3661956697950578813L
;
/* This code was generated by TableGo tools, mark 1 begin. */
/** admincode */
@ApiModelProperty
(
value
=
""
)
private
String
admincode
;
/** proadcode */
@ApiModelProperty
(
value
=
""
)
private
String
proadcode
;
/** cityadcode */
@ApiModelProperty
(
value
=
""
)
private
String
cityadcode
;
/** name */
@ApiModelProperty
(
value
=
""
)
private
String
name
;
/** cityname */
@ApiModelProperty
(
value
=
""
)
private
String
cityname
;
/** proname */
@ApiModelProperty
(
value
=
""
)
private
String
proname
;
/** shapeLeng */
@ApiModelProperty
(
value
=
""
)
private
Integer
shapeLeng
;
/** shapeArea */
@ApiModelProperty
(
value
=
""
)
private
Integer
shapeArea
;
/** geom */
@ApiModelProperty
(
value
=
""
)
private
String
geom
;
/** pointGeom */
@ApiModelProperty
(
value
=
""
)
private
String
pointGeom
;
/** 地区中文拼音 */
@ApiModelProperty
(
value
=
"地区中文拼音"
)
private
String
pinyin
;
/** 拼音缩写 */
@ApiModelProperty
(
value
=
"拼音缩写"
)
private
String
pysx
;
/** geomSamll */
@ApiModelProperty
(
value
=
""
)
private
String
geomSamll
;
/** 是否根据下级区域计算覆盖率 */
@ApiModelProperty
(
value
=
"是否根据下级区域计算覆盖率"
)
private
Integer
isHandleCoverRate
;
/** 下级占上级区域的百分比 */
@ApiModelProperty
(
value
=
"下级占上级区域的百分比"
)
private
BigDecimal
areaParentPercent
;
/* This code was generated by TableGo tools, mark 1 end. */
/* This code was generated by TableGo tools, mark 2 begin. */
/**
* 获取admincode
*
* @return admincode
*/
public
String
getAdmincode
()
{
return
this
.
admincode
;
}
/**
* 设置admincode
*
* @param admincode
*/
public
void
setAdmincode
(
String
admincode
)
{
this
.
admincode
=
admincode
;
}
/**
* 获取proadcode
*
* @return proadcode
*/
public
String
getProadcode
()
{
return
this
.
proadcode
;
}
/**
* 设置proadcode
*
* @param proadcode
*/
public
void
setProadcode
(
String
proadcode
)
{
this
.
proadcode
=
proadcode
;
}
/**
* 获取cityadcode
*
* @return cityadcode
*/
public
String
getCityadcode
()
{
return
this
.
cityadcode
;
}
/**
* 设置cityadcode
*
* @param cityadcode
*/
public
void
setCityadcode
(
String
cityadcode
)
{
this
.
cityadcode
=
cityadcode
;
}
/**
* 获取name
*
* @return name
*/
public
String
getName
()
{
return
this
.
name
;
}
/**
* 设置name
*
* @param name
*/
public
void
setName
(
String
name
)
{
this
.
name
=
name
;
}
/**
* 获取cityname
*
* @return cityname
*/
public
String
getCityname
()
{
return
this
.
cityname
;
}
/**
* 设置cityname
*
* @param cityname
*/
public
void
setCityname
(
String
cityname
)
{
this
.
cityname
=
cityname
;
}
/**
* 获取proname
*
* @return proname
*/
public
String
getProname
()
{
return
this
.
proname
;
}
/**
* 设置proname
*
* @param proname
*/
public
void
setProname
(
String
proname
)
{
this
.
proname
=
proname
;
}
/**
* 获取shapeLeng
*
* @return shapeLeng
*/
public
Integer
getShapeLeng
()
{
return
this
.
shapeLeng
;
}
/**
* 设置shapeLeng
*
* @param shapeLeng
*/
public
void
setShapeLeng
(
Integer
shapeLeng
)
{
this
.
shapeLeng
=
shapeLeng
;
}
/**
* 获取shapeArea
*
* @return shapeArea
*/
public
Integer
getShapeArea
()
{
return
this
.
shapeArea
;
}
/**
* 设置shapeArea
*
* @param shapeArea
*/
public
void
setShapeArea
(
Integer
shapeArea
)
{
this
.
shapeArea
=
shapeArea
;
}
/**
* 获取geom
*
* @return geom
*/
public
String
getGeom
()
{
return
this
.
geom
;
}
/**
* 设置geom
*
* @param geom
*/
public
void
setGeom
(
String
geom
)
{
this
.
geom
=
geom
;
}
/**
* 获取pointGeom
*
* @return pointGeom
*/
public
String
getPointGeom
()
{
return
this
.
pointGeom
;
}
/**
* 设置pointGeom
*
* @param pointGeom
*/
public
void
setPointGeom
(
String
pointGeom
)
{
this
.
pointGeom
=
pointGeom
;
}
/**
* 获取地区中文拼音
*
* @return 地区中文拼音
*/
public
String
getPinyin
()
{
return
this
.
pinyin
;
}
/**
* 设置地区中文拼音
*
* @param pinyin
* 地区中文拼音
*/
public
void
setPinyin
(
String
pinyin
)
{
this
.
pinyin
=
pinyin
;
}
/**
* 获取拼音缩写
*
* @return 拼音缩写
*/
public
String
getPysx
()
{
return
this
.
pysx
;
}
/**
* 设置拼音缩写
*
* @param pysx
* 拼音缩写
*/
public
void
setPysx
(
String
pysx
)
{
this
.
pysx
=
pysx
;
}
/**
* 获取geomSamll
*
* @return geomSamll
*/
public
String
getGeomSamll
()
{
return
this
.
geomSamll
;
}
/**
* 设置geomSamll
*
* @param geomSamll
*/
public
void
setGeomSamll
(
String
geomSamll
)
{
this
.
geomSamll
=
geomSamll
;
}
/**
* 获取是否根据下级区域计算覆盖率
*
* @return 是否根据下级区域计算覆盖率
*/
public
Integer
getIsHandleCoverRate
()
{
return
this
.
isHandleCoverRate
;
}
/**
* 设置是否根据下级区域计算覆盖率
*
* @param isHandleCoverRate
* 是否根据下级区域计算覆盖率
*/
public
void
setIsHandleCoverRate
(
Integer
isHandleCoverRate
)
{
this
.
isHandleCoverRate
=
isHandleCoverRate
;
}
/**
* 获取下级占上级区域的百分比
*
* @return 下级占上级区域的百分比
*/
public
BigDecimal
getAreaParentPercent
()
{
return
this
.
areaParentPercent
;
}
/**
* 设置下级占上级区域的百分比
*
* @param areaParentPercent
* 下级占上级区域的百分比
*/
public
void
setAreaParentPercent
(
BigDecimal
areaParentPercent
)
{
this
.
areaParentPercent
=
areaParentPercent
;
}
/* This code was generated by TableGo tools, mark 2 end. */
}
\ No newline at end of file
rs-datacenter/rs-datacenter-api/src/main/java/com/upyuns/platform/rs/datacenter/entity/RscpImagePrice.java
0 → 100644
View file @
78de4310
This diff is collapsed.
Click to expand it.
rs-datacenter/rs-datacenter-server/pom.xml
View file @
78de4310
...
...
@@ -19,4 +19,22 @@
<scope>
compile
</scope>
</dependency>
</dependencies>
<build>
<finalName>
rs-datacenter
</finalName>
<plugins>
<plugin>
<groupId>
org.springframework.boot
</groupId>
<artifactId>
spring-boot-maven-plugin
</artifactId>
</plugin>
<plugin>
<groupId>
org.apache.maven.plugins
</groupId>
<artifactId>
maven-compiler-plugin
</artifactId>
<configuration>
<source>
1.8
</source>
<target>
1.8
</target>
</configuration>
</plugin>
</plugins>
</build>
</project>
\ No newline at end of file
rs-datacenter/rs-datacenter-server/src/main/java/com/upyuns/platform/rs/datacenter/biz/RscpAreaInfoBiz.java
0 → 100644
View file @
78de4310
package
com
.
upyuns
.
platform
.
rs
.
datacenter
.
biz
;
import
com.github.wxiaoqi.security.common.biz.BaseBiz
;
import
com.upyuns.platform.rs.datacenter.entity.RscpAreaInfo
;
import
com.upyuns.platform.rs.datacenter.entity.RscpImagePrice
;
import
com.upyuns.platform.rs.datacenter.mapper.RscpAreaInfoMapper
;
import
com.upyuns.platform.rs.datacenter.mapper.RscpImagePriceMapper
;
import
org.springframework.stereotype.Service
;
import
java.util.List
;
@Service
public
class
RscpAreaInfoBiz
extends
BaseBiz
<
RscpAreaInfoMapper
,
RscpAreaInfo
>
{
public
RscpAreaInfo
queryAreaInfoByAreaId
(
String
areaCode
)
{
return
mapper
.
queryAreaInfoByAreaCode
(
areaCode
);
}
public
List
<
RscpAreaInfo
>
getDirectSubAreas
(
String
parentId
)
{
return
mapper
.
getDirectSubAreas
(
parentId
);
}
}
rs-datacenter/rs-datacenter-server/src/main/java/com/upyuns/platform/rs/datacenter/biz/RscpImagePriceBiz.java
0 → 100644
View file @
78de4310
package
com
.
upyuns
.
platform
.
rs
.
datacenter
.
biz
;
import
com.github.wxiaoqi.security.common.biz.BaseBiz
;
import
com.upyuns.platform.rs.datacenter.entity.RscpImagePrice
;
import
com.upyuns.platform.rs.datacenter.mapper.RscpImagePriceMapper
;
import
org.springframework.stereotype.Service
;
@Service
public
class
RscpImagePriceBiz
extends
BaseBiz
<
RscpImagePriceMapper
,
RscpImagePrice
>
{
}
rs-datacenter/rs-datacenter-server/src/main/java/com/upyuns/platform/rs/datacenter/mapper/RscpAreaInfoMapper.java
0 → 100644
View file @
78de4310
package
com
.
upyuns
.
platform
.
rs
.
datacenter
.
mapper
;
import
com.upyuns.platform.rs.datacenter.entity.RscpAreaInfo
;
import
com.upyuns.platform.rs.datacenter.entity.RscpImagePrice
;
import
tk.mybatis.mapper.common.Mapper
;
import
java.util.List
;
public
interface
RscpAreaInfoMapper
extends
Mapper
<
RscpAreaInfo
>
{
public
RscpAreaInfo
queryAreaInfoByAreaCode
(
String
areaCode
);
public
List
<
RscpAreaInfo
>
getDirectSubAreas
(
String
parentId
);
}
\ No newline at end of file
rs-datacenter/rs-datacenter-server/src/main/java/com/upyuns/platform/rs/datacenter/mapper/RscpImagePriceMapper.java
0 → 100644
View file @
78de4310
package
com
.
upyuns
.
platform
.
rs
.
datacenter
.
mapper
;
import
com.upyuns.platform.rs.datacenter.entity.RscpImagePrice
;
import
tk.mybatis.mapper.common.Mapper
;
public
interface
RscpImagePriceMapper
extends
Mapper
<
RscpImagePrice
>
{
}
\ No newline at end of file
rs-datacenter/rs-datacenter-server/src/main/java/com/upyuns/platform/rs/datacenter/rest/RscpAreaInfoController.java
0 → 100644
View file @
78de4310
package
com
.
upyuns
.
platform
.
rs
.
datacenter
.
rest
;
import
cn.hutool.core.collection.CollUtil
;
import
cn.hutool.core.util.StrUtil
;
import
com.github.wxiaoqi.security.common.msg.ObjectRestResponse
;
import
com.github.wxiaoqi.security.common.rest.BaseController
;
import
com.upyuns.platform.rs.datacenter.biz.RscpAreaInfoBiz
;
import
com.upyuns.platform.rs.datacenter.entity.RscpAreaInfo
;
import
lombok.Data
;
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_TRUE
;
@RestController
@RequestMapping
(
"areaInfo"
)
public
class
RscpAreaInfoController
extends
BaseController
<
RscpAreaInfoBiz
,
RscpAreaInfo
>
{
@RequestMapping
(
value
=
"/app/unauth/getAreaList"
,
method
=
RequestMethod
.
GET
)
public
ObjectRestResponse
<
List
<
RscpAreaInfo
>>
getAreaList
(
String
parentId
)
{
if
(
StrUtil
.
isBlank
(
parentId
))
{
parentId
=
"000000"
;
}
return
ObjectRestResponse
.
succ
(
baseBiz
.
getDirectSubAreas
(
parentId
));
}
@RequestMapping
(
value
=
"/app/unauth/queryAreaInfoByAreaId"
,
method
=
RequestMethod
.
GET
)
public
ObjectRestResponse
<
RscpAreaInfo
>
queryAreaInfoByAreaId
(
String
areaCode
)
{
return
ObjectRestResponse
.
succ
(
baseBiz
.
queryAreaInfoByAreaId
(
areaCode
));
}
}
\ No newline at end of file
rs-datacenter/rs-datacenter-server/src/main/java/com/upyuns/platform/rs/datacenter/rest/RscpImageDataTotalController.java
View file @
78de4310
...
...
@@ -3,15 +3,34 @@ package com.upyuns.platform.rs.datacenter.rest;
import
com.alibaba.fastjson.JSONObject
;
import
com.github.wxiaoqi.security.common.msg.ObjectRestResponse
;
import
com.github.wxiaoqi.security.common.rest.BaseController
;
import
com.github.wxiaoqi.security.common.util.Query
;
import
com.github.wxiaoqi.security.common.util.UserAgentUtil
;
import
com.github.wxiaoqi.security.common.util.process.ResultCode
;
import
com.github.wxiaoqi.security.common.util.result.JsonResultUtil
;
import
com.github.wxiaoqi.security.common.vo.PageParam
;
import
com.upyuns.platform.rs.datacenter.biz.RscpImageDataTotalBiz
;
import
com.upyuns.platform.rs.datacenter.entity.RscpImageDataTotal
;
import
io.swagger.annotations.ApiOperation
;
import
org.apache.commons.lang3.StringUtils
;
import
org.springframework.web.bind.annotation.*
;
import
javax.servlet.http.HttpServletRequest
;
@RestController
@RequestMapping
(
"imageData"
)
public
class
RscpImageDataTotalController
extends
BaseController
<
RscpImageDataTotalBiz
,
RscpImageDataTotal
>
{
@RequestMapping
(
value
=
"/app/unauth/query"
,
method
=
RequestMethod
.
GET
)
public
ObjectRestResponse
unauthQuery
(
PageParam
pageParam
)
{
return
ObjectRestResponse
.
succ
(
baseBiz
.
selectByQuery
(
new
Query
(
pageParam
)));
}
@RequestMapping
(
value
=
"/app/unauth/query1"
,
method
=
RequestMethod
.
GET
)
public
ObjectRestResponse
unauthQuery1
(
PageParam
pageParam
)
{
return
ObjectRestResponse
.
succ
(
baseBiz
.
selectByQuery
(
new
Query
(
pageParam
)));
}
static
public
class
DTO
{
}
}
\ No newline at end of file
rs-datacenter/rs-datacenter-server/src/main/java/com/upyuns/platform/rs/datacenter/rest/RscpImagePriceController.java
0 → 100644
View file @
78de4310
package
com
.
upyuns
.
platform
.
rs
.
datacenter
.
rest
;
import
cn.hutool.core.collection.CollUtil
;
import
com.github.wxiaoqi.security.common.msg.ObjectRestResponse
;
import
com.github.wxiaoqi.security.common.rest.BaseController
;
import
com.github.wxiaoqi.security.common.util.Query
;
import
com.github.wxiaoqi.security.common.vo.PageParam
;
import
com.upyuns.platform.rs.datacenter.biz.RscpImageDataTotalBiz
;
import
com.upyuns.platform.rs.datacenter.biz.RscpImagePriceBiz
;
import
com.upyuns.platform.rs.datacenter.entity.RscpImageDataTotal
;
import
com.upyuns.platform.rs.datacenter.entity.RscpImagePrice
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
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_TRUE
;
@RestController
@RequestMapping
(
"imagePrice"
)
public
class
RscpImagePriceController
extends
BaseController
<
RscpImagePriceBiz
,
RscpImagePrice
>
{
@RequestMapping
(
value
=
"/app/unauth/all"
,
method
=
RequestMethod
.
GET
)
public
ObjectRestResponse
unauthQuery
()
{
List
<
RscpImagePrice
>
list
=
baseBiz
.
selectByWeekend
(
w
->
{
w
.
andEqualTo
(
RscpImagePrice:
:
getStatus
,
SYS_TRUE
);
return
w
;
},
" daily_sort asc"
);
List
<
ImagePriceVO
>
imagePriceVOS
=
CollUtil
.
newArrayList
();
String
key
=
""
;
List
<
String
>
satelliteTypes
=
list
.
parallelStream
().
map
(
RscpImagePrice:
:
getImageSatelliteType
).
collect
(
Collectors
.
toList
());
for
(
String
satelliteType
:
satelliteTypes
)
{
List
<
RscpImagePrice
>
imagePriceList
=
list
.
parallelStream
().
filter
(
rscpImagePrice
->
satelliteType
.
equals
(
rscpImagePrice
.
getImageSatelliteType
())).
collect
(
Collectors
.
toList
());
imagePriceVOS
.
add
(
new
ImagePriceVO
(){{
setImageSatelliteType
(
satelliteType
);
setSatelliteName
(
imagePriceList
.
get
(
0
).
getSatelliteName
());
setImagePrices
(
imagePriceList
);
}});
}
return
ObjectRestResponse
.
succ
(
imagePriceVOS
);
}
@Data
static
public
class
ImagePriceVO
{
/** 卫星 */
private
String
imageSatelliteType
;
/** 卫星全称 */
@ApiModelProperty
(
value
=
"卫星全称"
)
private
String
satelliteName
;
List
<
RscpImagePrice
>
imagePrices
;
}
}
\ No newline at end of file
rs-datacenter/rs-datacenter-server/src/main/resources/mapper/RscmAreaInfoMapper.xml
0 → 100644
View file @
78de4310
<?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">
<!-- rscm_area_info -->
<mapper
namespace=
"com.upyuns.platform.rs.datacenter.mapper.RscpAreaInfoMapper"
>
<!-- This code was generated by TableGo tools, mark 1 begin. -->
<!-- 字段映射 -->
<resultMap
id=
"rscmAreaInfoMap"
type=
"com.upyuns.platform.rs.datacenter.entity.RscpAreaInfo"
>
<id
column=
"admincode"
property=
"admincode"
jdbcType=
"VARCHAR"
/>
<result
column=
"proadcode"
property=
"proadcode"
jdbcType=
"VARCHAR"
/>
<result
column=
"cityadcode"
property=
"cityadcode"
jdbcType=
"VARCHAR"
/>
<result
column=
"name"
property=
"name"
jdbcType=
"VARCHAR"
/>
<result
column=
"cityname"
property=
"cityname"
jdbcType=
"VARCHAR"
/>
<result
column=
"proname"
property=
"proname"
jdbcType=
"VARCHAR"
/>
<result
column=
"shape_leng"
property=
"shapeLeng"
jdbcType=
"INTEGER"
/>
<result
column=
"shape_area"
property=
"shapeArea"
jdbcType=
"INTEGER"
/>
<result
column=
"geom"
property=
"geom"
jdbcType=
"VARCHAR"
/>
<result
column=
"point_geom"
property=
"pointGeom"
jdbcType=
"VARCHAR"
/>
<result
column=
"pinyin"
property=
"pinyin"
jdbcType=
"VARCHAR"
/>
<result
column=
"pysx"
property=
"pysx"
jdbcType=
"VARCHAR"
/>
<result
column=
"geom_samll"
property=
"geomSamll"
jdbcType=
"VARCHAR"
/>
<result
column=
"is_handle_cover_rate"
property=
"isHandleCoverRate"
jdbcType=
"INTEGER"
/>
<result
column=
"area_parent_percent"
property=
"areaParentPercent"
jdbcType=
"INTEGER"
/>
</resultMap>
<!-- This code was generated by TableGo tools, mark 1 end. -->
<!-- This code was generated by TableGo tools, mark 2 begin. -->
<!-- 表查询字段 -->
<sql
id=
"allColumns"
>
rai.admincode, rai.proadcode, rai.cityadcode, rai.name, rai.cityname, rai.proname, rai.shape_leng, rai.shape_area,
rai.geom, rai.point_geom, rai.pinyin, rai.pysx, rai.geom_samll, rai.is_handle_cover_rate, rai.area_parent_percent
</sql>
<!-- This code was generated by TableGo tools, mark 2 end. -->
<select
id=
"queryAreaInfoByAreaCode"
resultType=
"com.upyuns.platform.rs.datacenter.entity.RscpAreaInfo"
>
select a.name,a.shape_area,a.admincode,st_asgeojson(geom,16,0) geom,a.proname,a.cityname
from rscp_area_info a
where admincode=#{areaCode}
</select>
<select
id=
"getDirectSubAreas"
resultType=
"com.upyuns.platform.rs.datacenter.entity.RscpAreaInfo"
>
select admincode ,name, pinyin
from rscp_area_info where admincode != #{parentId} and admincode like
CASE WHEN #{parentId} = '000000' THEN '%0000'
WHEN substring(#{parentId}, 3, 4) = '0000' THEN substring(#{parentId}, 1, 2)||'%'||substring(#{parentId}, 5, 2)
ELSE substring(#{parentId}, 1, 4)||'%' END
order by pinyin
</select>
</mapper>
\ No newline at end of file
rs-datacenter/rs-datacenter-server/src/main/resources/mapper/RscpImageDataTotalMapper.xml
View file @
78de4310
...
...
@@ -88,5 +88,8 @@
ridt.image_year
</sql>
<!-- This code was generated by TableGo tools, mark 2 end. -->
<!-- <select id="selectList" >-->
<!-- </select>-->
</mapper>
\ No newline at end of file
rs-datacenter/rs-datacenter-server/src/main/resources/mapper/RscpImagePriceMapper.xml
0 → 100644
View file @
78de4310
<?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_price) -->
<mapper
namespace=
"com.upyuns.platform.rs.datacenter.mapper.RscpImagePriceMapper"
>
<!-- This code was generated by TableGo tools, mark 1 begin. -->
<!-- 字段映射 -->
<resultMap
id=
"rscpImagePriceMap"
type=
"com.upyuns.platform.rs.datacenter.entity.RscpImagePrice"
>
<id
column=
"id"
property=
"id"
jdbcType=
"VARCHAR"
/>
<result
column=
"image_satellite_type"
property=
"imageSatelliteType"
jdbcType=
"VARCHAR"
/>
<result
column=
"image_resolution"
property=
"imageResolution"
jdbcType=
"VARCHAR"
/>
<result
column=
"image_spectrum_type"
property=
"imageSpectrumType"
jdbcType=
"VARCHAR"
/>
<result
column=
"price"
property=
"price"
jdbcType=
"INTEGER"
/>
<result
column=
"discount"
property=
"discount"
jdbcType=
"INTEGER"
/>
<result
column=
"upd_name"
property=
"updName"
jdbcType=
"VARCHAR"
/>
<result
column=
"upd_time"
property=
"updTime"
jdbcType=
"TIMESTAMP"
/>
<result
column=
"image_product_type"
property=
"imageProductType"
jdbcType=
"VARCHAR"
/>
<result
column=
"unit_price"
property=
"unitPrice"
jdbcType=
"INTEGER"
/>
<result
column=
"image_sensor_type"
property=
"imageSensorType"
jdbcType=
"VARCHAR"
/>
<result
column=
"is_use_for_data"
property=
"isUseForData"
jdbcType=
"INTEGER"
/>
<result
column=
"status"
property=
"status"
jdbcType=
"INTEGER"
/>
<result
column=
"satellite_name"
property=
"satelliteName"
jdbcType=
"VARCHAR"
/>
<result
column=
"sensor_name"
property=
"sensorName"
jdbcType=
"VARCHAR"
/>
<result
column=
"data_type"
property=
"dataType"
jdbcType=
"VARCHAR"
/>
<result
column=
"daily_display"
property=
"dailyDisplay"
jdbcType=
"INTEGER"
/>
<result
column=
"daily_sort"
property=
"dailySort"
jdbcType=
"INTEGER"
/>
<result
column=
"is_sell"
property=
"isSell"
jdbcType=
"INTEGER"
/>
<result
column=
"index_sort"
property=
"indexSort"
jdbcType=
"INTEGER"
/>
<result
column=
"is_index"
property=
"isIndex"
jdbcType=
"INTEGER"
/>
</resultMap>
<!-- This code was generated by TableGo tools, mark 1 end. -->
<!-- This code was generated by TableGo tools, mark 2 begin. -->
<!-- 表查询字段 -->
<sql
id=
"allColumns"
>
rip.id, rip.image_satellite_type, rip.image_resolution, rip.image_spectrum_type, rip.price, rip.discount, rip.upd_name, rip.upd_time,
rip.image_product_type, rip.unit_price, rip.image_sensor_type, rip.is_use_for_data, rip.status, rip.satellite_name, rip.sensor_name, rip.data_type,
rip.daily_display, rip.daily_sort, rip.is_sell, rip.index_sort, rip.is_index
</sql>
<!-- This code was generated by TableGo tools, mark 2 end. -->
</mapper>
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment