Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
C
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
youjj
cloud-platform
Commits
31a74322
Commit
31a74322
authored
Jun 08, 2019
by
周健威
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
添加旅遊確認訂單
parent
51d52c07
Changes
13
Hide whitespace changes
Inline
Side-by-side
Showing
13 changed files
with
535 additions
and
71 deletions
+535
-71
application.yml
ace-modules/ace-generator/src/main/resources/application.yml
+1
-1
generator.properties
...les/ace-generator/src/main/resources/generator.properties
+1
-1
OrderTourDetail.java
.../java/com/xxfc/platform/order/entity/OrderTourDetail.java
+122
-0
AddTourDTO.java
...rc/main/java/com/xxfc/platform/order/pojo/AddTourDTO.java
+90
-0
TourBO.java
.../main/java/com/xxfc/platform/order/pojo/order/TourBO.java
+14
-0
pom.xml
xx-order/xx-order-server/pom.xml
+2
-2
OrderTourDetailBiz.java
.../java/com/xxfc/platform/order/biz/OrderTourDetailBiz.java
+18
-0
OrderTourDetailMapper.java
...com/xxfc/platform/order/mapper/OrderTourDetailMapper.java
+15
-0
OrderTourController.java
...ava/com/xxfc/platform/order/rest/OrderTourController.java
+36
-0
OrderTourService.java
...ava/com/xxfc/platform/order/service/OrderTourService.java
+143
-0
OrderTourDetailMapper.xml
...erver/src/main/resources/mapper/OrderTourDetailMapper.xml
+27
-0
pom.xml
xx-tour/xx-tour-server/pom.xml
+64
-65
TourGoodBiz.java
...src/main/java/com/xxfc/platform/tour/biz/TourGoodBiz.java
+2
-2
No files found.
ace-modules/ace-generator/src/main/resources/application.yml
View file @
31a74322
...
...
@@ -10,7 +10,7 @@ spring:
datasource
:
type
:
com.alibaba.druid.pool.DruidDataSource
driverClassName
:
com.mysql.jdbc.Driver
url
:
jdbc:mysql://10.5.52.3:3306/xxfc_
tou
r?useUnicode=true&characterEncoding=UTF-8
url
:
jdbc:mysql://10.5.52.3:3306/xxfc_
orde
r?useUnicode=true&characterEncoding=UTF-8
username
:
root
password
:
sslcloud123*()
jackson
:
...
...
ace-modules/ace-generator/src/main/resources/generator.properties
View file @
31a74322
#代码生成器,配置信息
#包名
package
=
com.xxfc.platform.
tou
r
package
=
com.xxfc.platform.
orde
r
#作者
author
=
zjw
#Email
...
...
xx-order/xx-order-api/src/main/java/com/xxfc/platform/order/entity/OrderTourDetail.java
0 → 100644
View file @
31a74322
package
com
.
xxfc
.
platform
.
order
.
entity
;
import
java.io.Serializable
;
import
java.util.Date
;
import
javax.persistence.*
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
/**
* 旅游订单详情
*
* @author zjw
* @email nishijjo@qq.com
* @date 2019-06-06 18:18:33
*/
@Data
@Table
(
name
=
"order_tour_detail"
)
public
class
OrderTourDetail
implements
Serializable
{
private
static
final
long
serialVersionUID
=
1L
;
//主键
@Id
@GeneratedValue
(
generator
=
"JDBC"
)
@ApiModelProperty
(
"主键"
)
private
Integer
id
;
//基础订单id
@Column
(
name
=
"order_id"
)
@ApiModelProperty
(
value
=
"基础订单id"
)
private
Integer
orderId
;
//名称
@Column
(
name
=
"name"
)
@ApiModelProperty
(
value
=
"名称"
)
private
String
name
;
//创建时间
@Column
(
name
=
"crt_time"
)
@ApiModelProperty
(
value
=
"创建时间"
,
hidden
=
true
)
private
Long
crtTime
;
//更新时间
@Column
(
name
=
"upd_time"
)
@ApiModelProperty
(
value
=
"更新时间"
,
hidden
=
true
)
private
Long
updTime
;
//开始时间
@Column
(
name
=
"start_time"
)
@ApiModelProperty
(
value
=
"开始时间"
)
private
Long
startTime
;
//结束时间
@Column
(
name
=
"end_time"
)
@ApiModelProperty
(
value
=
"结束时间"
)
private
Long
endTime
;
//天数
@Column
(
name
=
"day_num"
)
@ApiModelProperty
(
value
=
"天数"
)
private
Integer
dayNum
;
//出发地点
@Column
(
name
=
"start_addr"
)
@ApiModelProperty
(
value
=
"出发地点"
)
private
String
startAddr
;
//还车地点
@Column
(
name
=
"end_addr"
)
@ApiModelProperty
(
value
=
"还车地点"
)
private
String
endAddr
;
//出发城市编号
@Column
(
name
=
"start_city"
)
@ApiModelProperty
(
value
=
"出发城市编号"
)
private
Integer
startCity
;
//还车城市编号
@Column
(
name
=
"end_city"
)
@ApiModelProperty
(
value
=
"还车城市编号"
)
private
Integer
endCity
;
//出发城市名称
@Column
(
name
=
"start_city_name"
)
@ApiModelProperty
(
value
=
"出发城市名称"
)
private
String
startCityName
;
//还车城市名称
@Column
(
name
=
"end_city_name"
)
@ApiModelProperty
(
value
=
"还车城市名称"
)
private
String
endCityName
;
//自己乘客ids
@Column
(
name
=
"my_passager_ids"
)
@ApiModelProperty
(
value
=
"自己乘客ids"
)
private
String
myPassagerIds
;
//出发公司Id
@Column
(
name
=
"start_company_id"
)
@ApiModelProperty
(
value
=
"出发公司Id"
)
private
Integer
startCompanyId
;
//费用明细
@Column
(
name
=
"cost_detail"
)
@ApiModelProperty
(
value
=
"费用明细"
)
private
String
costDetail
;
//商品id
@Column
(
name
=
"good_id"
)
@ApiModelProperty
(
value
=
"商品id"
)
private
Integer
goodId
;
//商品规格ids
@Column
(
name
=
"spe_ids"
)
@ApiModelProperty
(
value
=
"商品规格ids"
)
private
String
speIds
;
//具体商品(商品项)id
@Column
(
name
=
"spe_price_id"
)
@ApiModelProperty
(
value
=
"具体商品(商品项)id"
)
private
String
spePriceId
;
}
xx-order/xx-order-api/src/main/java/com/xxfc/platform/order/pojo/AddTourDTO.java
0 → 100644
View file @
31a74322
package
com
.
xxfc
.
platform
.
order
.
pojo
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
javax.persistence.Column
;
import
java.time.Instant
;
import
java.time.LocalDateTime
;
import
java.time.ZoneOffset
;
import
java.time.format.DateTimeFormatter
;
@Data
public
class
AddTourDTO
{
public
static
final
DateTimeFormatter
DEFAULT_DATE_TIME_FORMATTER
=
DateTimeFormatter
.
ofPattern
(
"yyyy-MM-dd"
);
//开始时间
@Column
(
name
=
"start_time"
)
@ApiModelProperty
(
value
=
"活动开始时间"
)
private
Long
startTime
;
//结束时间
@Column
(
name
=
"end_time"
)
@ApiModelProperty
(
value
=
"活动结束时间"
)
private
Long
endTime
;
//天数
@Column
(
name
=
"day_num"
)
@ApiModelProperty
(
value
=
"天数"
)
private
Integer
dayNum
;
//取车地点
@Column
(
name
=
"start_addr"
)
@ApiModelProperty
(
value
=
"出发地点"
)
private
String
startAddr
;
//还车地点
@Column
(
name
=
"end_addr"
)
@ApiModelProperty
(
value
=
"结束地点"
)
private
String
endAddr
;
//费用详情
@Column
(
name
=
"cost_detail"
)
@ApiModelProperty
(
value
=
"费用详情"
)
private
String
costDetail
;
//取车城市编号
@Column
(
name
=
"start_city"
)
@ApiModelProperty
(
value
=
"出发城市编号"
)
private
Integer
startCity
;
//还车城市编号
@Column
(
name
=
"end_city"
)
@ApiModelProperty
(
value
=
"结束城市编号"
)
private
Integer
endCity
;
//取车城市名称
@Column
(
name
=
"start_city_name"
)
@ApiModelProperty
(
value
=
"出发城市名称"
)
private
String
startCityName
;
//还车城市名称
@Column
(
name
=
"end_city_name"
)
@ApiModelProperty
(
value
=
"结束城市名称"
)
private
String
endCityName
;
//自己乘客ids
@Column
(
name
=
"my_passager_ids"
)
@ApiModelProperty
(
value
=
"自己乘客ids"
)
private
String
myPassagerIds
;
//出发公司Id
@Column
(
name
=
"start_company_id"
)
@ApiModelProperty
(
value
=
"出发公司Id"
)
private
Integer
startCompanyId
;
//商品id
@Column
(
name
=
"good_id"
)
@ApiModelProperty
(
value
=
"商品id"
)
private
Integer
goodId
;
//商品规格ids
@Column
(
name
=
"spe_ids"
)
@ApiModelProperty
(
value
=
"商品规格ids"
)
private
String
speIds
;
//具体商品(商品项)id
@Column
(
name
=
"spe_price_id"
)
@ApiModelProperty
(
value
=
"具体商品(商品项)id"
)
private
String
spePriceId
;
}
xx-order/xx-order-api/src/main/java/com/xxfc/platform/order/pojo/order/TourBO.java
0 → 100644
View file @
31a74322
package
com
.
xxfc
.
platform
.
order
.
pojo
.
order
;
import
com.xxfc.platform.order.entity.BaseOrder
;
import
com.xxfc.platform.order.entity.OrderRentVehicleDetail
;
import
com.xxfc.platform.order.entity.OrderTourDetail
;
import
com.xxfc.platform.order.entity.inter.OrderDetail
;
import
com.xxfc.platform.vehicle.entity.VehicleModel
;
import
lombok.Data
;
@Data
public
class
TourBO
extends
OrderTourDetail
implements
OrderDetail
{
private
BaseOrder
order
;
// private Tour
}
xx-order/xx-order-server/pom.xml
View file @
31a74322
...
...
@@ -25,6 +25,7 @@
<version>
2.0-SNAPSHOT
</version>
<scope>
compile
</scope>
</dependency>
<dependency>
<groupId>
com.xxfc.platform
</groupId>
<artifactId>
xx-vehicle-api
</artifactId>
...
...
@@ -33,9 +34,8 @@
<dependency>
<groupId>
com.xxfc.platform
</groupId>
<artifactId>
xx-
vehicle
-api
</artifactId>
<artifactId>
xx-
tour
-api
</artifactId>
<version>
2.0-SNAPSHOT
</version>
<scope>
compile
</scope>
</dependency>
</dependencies>
...
...
xx-order/xx-order-server/src/main/java/com/xxfc/platform/order/biz/OrderTourDetailBiz.java
0 → 100644
View file @
31a74322
package
com
.
xxfc
.
platform
.
order
.
biz
;
import
org.springframework.stereotype.Service
;
import
com.xxfc.platform.order.entity.OrderTourDetail
;
import
com.xxfc.platform.order.mapper.OrderTourDetailMapper
;
import
com.github.wxiaoqi.security.common.biz.BaseBiz
;
/**
* 旅游订单详情
*
* @author zjw
* @email nishijjo@qq.com
* @date 2019-06-06 18:18:33
*/
@Service
public
class
OrderTourDetailBiz
extends
BaseBiz
<
OrderTourDetailMapper
,
OrderTourDetail
>
{
}
\ No newline at end of file
xx-order/xx-order-server/src/main/java/com/xxfc/platform/order/mapper/OrderTourDetailMapper.java
0 → 100644
View file @
31a74322
package
com
.
xxfc
.
platform
.
order
.
mapper
;
import
com.xxfc.platform.order.entity.OrderTourDetail
;
import
tk.mybatis.mapper.common.Mapper
;
/**
* 旅游订单详情
*
* @author zjw
* @email nishijjo@qq.com
* @date 2019-06-06 18:18:33
*/
public
interface
OrderTourDetailMapper
extends
Mapper
<
OrderTourDetail
>
{
}
xx-order/xx-order-server/src/main/java/com/xxfc/platform/order/rest/OrderTourController.java
0 → 100644
View file @
31a74322
package
com
.
xxfc
.
platform
.
order
.
rest
;
import
cn.hutool.core.bean.BeanUtil
;
import
com.github.wxiaoqi.security.common.msg.ObjectRestResponse
;
import
com.github.wxiaoqi.security.common.rest.BaseController
;
import
com.xxfc.platform.order.biz.OrderTourDetailBiz
;
import
com.xxfc.platform.order.entity.OrderRentVehicleDetail
;
import
com.xxfc.platform.order.entity.OrderTourDetail
;
import
com.xxfc.platform.order.pojo.AddRentVehicleDTO
;
import
com.xxfc.platform.order.pojo.AddTourDTO
;
import
com.xxfc.platform.order.pojo.order.RentVehicleBO
;
import
com.xxfc.platform.order.service.OrderTourService
;
import
io.swagger.annotations.ApiOperation
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Controller
;
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.ResponseBody
;
@Controller
@RequestMapping
(
"orderTour"
)
public
class
OrderTourController
extends
BaseController
<
OrderTourDetailBiz
,
OrderTourDetail
>
{
@Autowired
OrderTourService
orderTourService
;
@RequestMapping
(
value
=
"add"
,
method
=
RequestMethod
.
POST
)
@ResponseBody
@ApiOperation
(
value
=
"确认旅游订单"
)
public
ObjectRestResponse
<
OrderRentVehicleDetail
>
add
(
@RequestBody
AddTourDTO
vo
){
RentVehicleBO
bo
=
BeanUtil
.
toBean
(
vo
,
RentVehicleBO
.
class
);
orderTourService
.
createOrder
(
bo
);
return
new
ObjectRestResponse
<>().
rel
(
true
).
data
(
bo
.
getOrder
());
}
}
\ No newline at end of file
xx-order/xx-order-server/src/main/java/com/xxfc/platform/order/service/OrderTourService.java
0 → 100644
View file @
31a74322
package
com
.
xxfc
.
platform
.
order
.
service
;
import
cn.hutool.core.bean.BeanUtil
;
import
cn.hutool.core.lang.Dict
;
import
cn.hutool.extra.template.Template
;
import
cn.hutool.extra.template.TemplateConfig
;
import
cn.hutool.extra.template.TemplateEngine
;
import
cn.hutool.extra.template.TemplateUtil
;
import
com.xxfc.platform.order.biz.OrderCostDetailBiz
;
import
com.xxfc.platform.order.biz.OrderRentVehicleBiz
;
import
com.xxfc.platform.order.biz.OrderTemplateBiz
;
import
com.xxfc.platform.order.contant.enumerate.OrderCostEnum
;
import
com.xxfc.platform.order.contant.enumerate.OrderStatusEnum
;
import
com.xxfc.platform.order.contant.enumerate.OrderTypeEnum
;
import
com.xxfc.platform.order.entity.OrderCostDetail
;
import
com.xxfc.platform.order.pojo.order.RentVehicleBO
;
import
com.xxfc.platform.order.pojo.price.RentVehiclePriceVO
;
import
com.xxfc.platform.vehicle.entity.VehicleModel
;
import
com.xxfc.platform.vehicle.feign.VehicleFeign
;
import
lombok.extern.log4j.Log4j
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
javax.annotation.PostConstruct
;
import
java.math.BigDecimal
;
@Service
@Log4j
public
class
OrderTourService
extends
AbstractOrderHandle
<
OrderRentVehicleBiz
,
RentVehicleBO
>
{
private
static
BigDecimal
DRIVER_PRICE
=
new
BigDecimal
(
"600.00"
);
private
static
BigDecimal
DAMAGE_SAFE
=
new
BigDecimal
(
"100.00"
);
//车损免赔
private
static
Integer
DRIVER_TYPE_COMPANY
=
1
;
private
static
BigDecimal
DEPOSIT
=
new
BigDecimal
(
"20000.00"
);
@Autowired
VehicleFeign
vehicleFeign
;
@Autowired
OrderCostDetailBiz
orderCostDetailBiz
;
@Autowired
OrderTemplateBiz
orderTemplateBiz
;
@PostConstruct
public
void
init
(){
this
.
orderTypeEnum
=
OrderTypeEnum
.
RentVehicle
;
}
@Override
public
void
initDetail
(
RentVehicleBO
bo
)
{
super
.
initDetail
(
bo
);
VehicleModel
vehicleModel
=
vehicleFeign
.
get
(
bo
.
getModelId
()).
getData
();
bo
.
setVehicleModel
(
vehicleModel
);
}
@Override
public
void
handleDetail
(
RentVehicleBO
bo
)
{
//获取可用车辆
acquireVehicle
(
bo
);
//设置订单状态为3
bo
.
getOrder
().
setStatus
(
OrderStatusEnum
.
ORDER_UNPAY
.
getCode
());
//设置订单图片
bo
.
getOrder
().
setPicture
(
bo
.
getVehicleModel
().
getPicture
());
//设置订单名称
bo
.
getOrder
().
setName
(
bo
.
getVehicleModel
().
getName
());
super
.
handleDetail
(
bo
);
}
@Override
public
void
handleCalculate
(
RentVehicleBO
bo
)
{
RentVehiclePriceVO
rvpv
=
calculatePrice
(
bo
);
BeanUtil
.
copyProperties
(
rvpv
,
bo
.
getOrder
());
BeanUtil
.
copyProperties
(
rvpv
,
bo
);
}
@Override
public
RentVehiclePriceVO
calculatePrice
(
RentVehicleBO
detail
)
{
BigDecimal
orderAmount
=
BigDecimal
.
ZERO
;
BigDecimal
goodsAmount
=
BigDecimal
.
ZERO
;
BigDecimal
vehicleAmount
=
BigDecimal
.
ZERO
;
BigDecimal
driverAmount
=
BigDecimal
.
ZERO
;
//计算价格
//计算车辆费用
VehicleModel
vehicleModel
=
vehicleFeign
.
get
(
detail
.
getModelId
()).
getData
();
vehicleAmount
=
vehicleAmount
.
add
(
vehicleModel
.
getPrice
().
multiply
(
BigDecimal
.
valueOf
(
detail
.
getDayNum
())));
if
(
DRIVER_TYPE_COMPANY
.
equals
(
detail
.
getDriverType
()))
{
//计算司机费用
driverAmount
=
driverAmount
.
add
(
DRIVER_PRICE
.
multiply
(
BigDecimal
.
valueOf
(
detail
.
getDayNum
())));
}
//商品价格
goodsAmount
=
goodsAmount
.
add
(
vehicleAmount
).
add
(
driverAmount
);
//总价格(包含押金)
orderAmount
=
orderAmount
.
add
(
goodsAmount
).
add
(
DEPOSIT
);
//生成订单明细
RentVehiclePriceVO
rvp
=
new
RentVehiclePriceVO
();
rvp
.
setOrderAmount
(
orderAmount
);
rvp
.
setGoodsAmount
(
goodsAmount
);
rvp
.
setDriverAmount
(
driverAmount
);
rvp
.
setVehicleAmount
(
vehicleAmount
);
rvp
.
setRealAmount
(
orderAmount
);
rvp
.
setDeposit
(
DEPOSIT
);
rvp
.
setModelAmount
(
vehicleModel
.
getPrice
());
rvp
.
setDriverPrice
(
DRIVER_PRICE
);
rvp
.
setModelName
(
vehicleModel
.
getName
());
rvp
.
setDayNum
(
detail
.
getDayNum
());
rvp
.
setVehicleNum
(
1
);
rvp
.
setDriverNum
(
1
);
detail
.
setCostDetail
(
costDetail
(
rvp
));
return
rvp
;
}
/**
* 计算费用明细
* @param vo
* @return
*/
private
String
costDetail
(
RentVehiclePriceVO
vo
)
{
//orderTemplateBiz.result(orderTemplateBiz.selectById(OrderCostEnum.RentVehicle.getCode()), Dict.parse(pojo));
TemplateEngine
engine
=
TemplateUtil
.
createEngine
(
new
TemplateConfig
());
OrderCostDetail
orderCostDetail
=
orderCostDetailBiz
.
selectById
(
OrderCostEnum
.
RentVehicle
.
getCode
());
Template
template
=
engine
.
getTemplate
(
orderCostDetail
.
getTemplate
());
String
result
=
template
.
render
(
Dict
.
parse
(
vo
));
vo
.
setCostDetail
(
result
);
return
result
;
}
private
String
acquireVehicle
(
RentVehicleBO
detail
)
{
//根据车型、时间、距离,门店,预定车辆
// BookVehicleVO bookVehicleVO = new BookVehicleVO(){{
// setBookStartDate(detail);
// }};
// vehicleFeign.rentApplyVehicle()
String
vehicleId
=
"0e9a88db-cb1b-48a4-b307-40f89eed906f"
;
detail
.
setVehicleId
(
vehicleId
);
return
vehicleId
;
}
}
xx-order/xx-order-server/src/main/resources/mapper/OrderTourDetailMapper.xml
0 → 100644
View file @
31a74322
<?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.xxfc.platform.order.mapper.OrderTourDetailMapper"
>
<!-- 可根据自己的需求,是否要使用 -->
<resultMap
type=
"com.xxfc.platform.order.entity.OrderTourDetail"
id=
"orderTourDetailMap"
>
<result
property=
"id"
column=
"id"
/>
<result
property=
"orderId"
column=
"order_id"
/>
<result
property=
"name"
column=
"name"
/>
<result
property=
"crtTime"
column=
"crt_time"
/>
<result
property=
"updTime"
column=
"upd_time"
/>
<result
property=
"startTime"
column=
"start_time"
/>
<result
property=
"endTime"
column=
"end_time"
/>
<result
property=
"dayNum"
column=
"day_num"
/>
<result
property=
"startAddr"
column=
"start_addr"
/>
<result
property=
"endAddr"
column=
"end_addr"
/>
<result
property=
"startCity"
column=
"start_city"
/>
<result
property=
"endCity"
column=
"end_city"
/>
<result
property=
"startCityName"
column=
"start_city_name"
/>
<result
property=
"endCityName"
column=
"end_city_name"
/>
<result
property=
"myPassagerIds"
column=
"my_passager_ids"
/>
<result
property=
"startCompanyId"
column=
"start_company_id"
/>
<result
property=
"costDetail"
column=
"cost_detail"
/>
</resultMap>
</mapper>
\ No newline at end of file
xx-tour/xx-tour-server/pom.xml
View file @
31a74322
<?xml version="1.0" encoding="UTF-8"?>
<project
xmlns=
"http://maven.apache.org/POM/4.0.0"
xmlns:xsi=
"http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation=
"http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"
>
<parent>
<groupId>
com.xxfc.common
</groupId>
<artifactId>
xx-common-platform-web
</artifactId>
<version>
2.0-SNAPSHOT
</version>
</parent>
<modelVersion>
4.0.0
</modelVersion>
<groupId>
com.xxfc.platform
</groupId>
<artifactId>
xx-tour-server
</artifactId>
<dependencies>
<!-- 自己项目 -->
<dependency>
<groupId>
com.xxfc.platform
</groupId>
<artifactId>
xx-tour-api
</artifactId>
<version>
2.0-SNAPSHOT
</version>
<scope>
compile
</scope>
</dependency>
</dependencies>
<build>
<plugins>
<!-- 此插件用来生成通用mapper的代码 -->
<plugin>
<groupId>
org.mybatis.generator
</groupId>
<artifactId>
mybatis-generator-maven-plugin
</artifactId>
<version>
1.3.2
</version>
<configuration>
<configurationFile>
${basedir}/src/main/resources/builder/generatorConfig.xml
</configurationFile>
<overwrite>
true
</overwrite>
<verbose>
true
</verbose>
</configuration>
<dependencies>
<dependency>
<groupId>
mysql
</groupId>
<artifactId>
mysql-connector-java
</artifactId>
<version>
5.1.30
</version>
<scope>
runtime
</scope>
</dependency>
<dependency>
<groupId>
tk.mybatis
</groupId>
<artifactId>
mapper
</artifactId>
<version>
${mapper.version}
</version>
</dependency>
</dependencies>
</plugin>
<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>
<?xml version="1.0" encoding="UTF-8"?>
<project
xmlns=
"http://maven.apache.org/POM/4.0.0"
xmlns:xsi=
"http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation=
"http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"
>
<parent>
<groupId>
com.xxfc.common
</groupId>
<artifactId>
xx-common-platform-web
</artifactId>
<version>
2.0-SNAPSHOT
</version>
</parent>
<modelVersion>
4.0.0
</modelVersion>
<groupId>
com.xxfc.platform
</groupId>
<artifactId>
xx-tour-server
</artifactId>
<dependencies>
<!-- 自己项目 -->
<dependency>
<groupId>
com.xxfc.platform
</groupId>
<artifactId>
xx-tour-api
</artifactId>
<version>
2.0-SNAPSHOT
</version>
</dependency>
</dependencies>
<build>
<plugins>
<!-- 此插件用来生成通用mapper的代码 -->
<plugin>
<groupId>
org.mybatis.generator
</groupId>
<artifactId>
mybatis-generator-maven-plugin
</artifactId>
<version>
1.3.2
</version>
<configuration>
<configurationFile>
${basedir}/src/main/resources/builder/generatorConfig.xml
</configurationFile>
<overwrite>
true
</overwrite>
<verbose>
true
</verbose>
</configuration>
<dependencies>
<dependency>
<groupId>
mysql
</groupId>
<artifactId>
mysql-connector-java
</artifactId>
<version>
5.1.30
</version>
<scope>
runtime
</scope>
</dependency>
<dependency>
<groupId>
tk.mybatis
</groupId>
<artifactId>
mapper
</artifactId>
<version>
${mapper.version}
</version>
</dependency>
</dependencies>
</plugin>
<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
xx-tour/xx-tour-server/src/main/java/com/xxfc/platform/tour/biz/TourGoodBiz.java
View file @
31a74322
...
...
@@ -35,7 +35,7 @@ public class TourGoodBiz extends BaseBiz<TourGoodMapper,TourGood> {
params
.
put
(
"longitude"
,
longitude
);
params
.
put
(
"tagId"
,
tagId
);
params
.
put
(
"distance"
,
distance
);
List
<
TourGood
>
list
=
tourGoodMapper
.
getGoodList
(
params
);
return
PageDataVO
.
pageInfo
(
page
,
limit
,
list
);
//
List<TourGood> list = tourGoodMapper.getGoodList(params);
return
PageDataVO
.
pageInfo
(
page
,
limit
,
mapper
.
getGoodList
(
params
)
);
}
}
\ 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