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
0a1347c1
Commit
0a1347c1
authored
Jun 17, 2019
by
libin
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'base-modify' of
http://113.105.137.151:22280/youjj/cloud-platform
into base-modify
parents
97c240a3
6eb8e941
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
82 additions
and
22 deletions
+82
-22
BaseOrderBiz.java
...c/main/java/com/xxfc/platform/order/biz/BaseOrderBiz.java
+3
-0
BaseOrderMapper.java
.../java/com/xxfc/platform/order/mapper/BaseOrderMapper.java
+1
-0
BaseOrderController.java
...ava/com/xxfc/platform/order/rest/BaseOrderController.java
+30
-1
BaseOrderMapper.xml
...rder-server/src/main/resources/mapper/BaseOrderMapper.xml
+48
-21
No files found.
xx-order/xx-order-server/src/main/java/com/xxfc/platform/order/biz/BaseOrderBiz.java
View file @
0a1347c1
...
...
@@ -27,6 +27,9 @@ public class BaseOrderBiz extends BaseBiz<BaseOrderMapper,BaseOrder> {
public
List
<
OrderPageVO
>
pageByParm
(
Map
<
String
,
Object
>
paramMap
){
return
mapper
.
pageByParm
(
paramMap
);
}
public
List
<
OrderPageVO
>
listOrder
(
Map
<
String
,
Object
>
paramMap
){
return
mapper
.
listOrder
(
paramMap
);
}
private
static
Map
<
Integer
,
List
<
Integer
>>
cancelAble
;
static
{
cancelAble
=
new
HashMap
<
Integer
,
List
<
Integer
>>();
...
...
xx-order/xx-order-server/src/main/java/com/xxfc/platform/order/mapper/BaseOrderMapper.java
View file @
0a1347c1
...
...
@@ -16,4 +16,5 @@ import java.util.Map;
*/
public
interface
BaseOrderMapper
extends
Mapper
<
BaseOrder
>
{
public
List
<
OrderPageVO
>
pageByParm
(
Map
<
String
,
Object
>
paramMap
);
public
List
<
OrderPageVO
>
listOrder
(
Map
<
String
,
Object
>
paramMap
);
}
xx-order/xx-order-server/src/main/java/com/xxfc/platform/order/rest/BaseOrderController.java
View file @
0a1347c1
...
...
@@ -36,7 +36,6 @@ import org.springframework.beans.factory.annotation.Autowired;
import
org.springframework.beans.factory.annotation.Value
;
import
org.springframework.stereotype.Controller
;
import
org.springframework.web.bind.annotation.*
;
import
springfox.documentation.annotations.ApiIgnore
;
import
java.math.BigDecimal
;
...
...
@@ -79,6 +78,25 @@ public class BaseOrderController extends CommonBaseController {
return
new
ObjectRestResponse
<>().
data
(
PageDataVO
.
pageInfo
(
query
,
()
->
baseOrderBiz
.
pageByParm
(
query
.
getSuper
())));
}
@RequestMapping
(
value
=
"/list"
,
method
=
RequestMethod
.
GET
)
@ResponseBody
@ApiOperation
(
value
=
"订单列表"
)
@IgnoreClientToken
public
ObjectRestResponse
<
PageDataVO
<
OrderPageVO
>>
getOrderList
(
QueryOrderDTO
dto
){
Query
query
=
new
Query
(
dto
);
return
new
ObjectRestResponse
<>().
data
(
PageDataVO
.
pageInfo
(
query
,
()
->
baseOrderBiz
.
selectListAll
()));
}
@RequestMapping
(
value
=
"/selectByUser"
,
method
=
RequestMethod
.
GET
)
@ResponseBody
@ApiOperation
(
value
=
"订单列表"
)
@IgnoreClientToken
public
ObjectRestResponse
<
PageDataVO
<
OrderPageVO
>>
selectByUser
(
QueryOrderList
dto
){
Query
query
=
new
Query
(
dto
);
return
new
ObjectRestResponse
<>().
data
(
PageDataVO
.
pageInfo
(
query
,
()
->
baseOrderBiz
.
listOrder
(
query
.
getSuper
())));
}
// @RequestMapping(value = "/company/page",method = RequestMethod.GET)
// @ResponseBody
// @ApiOperation(value = "结合后台人员所属公司查询订单列表")
...
...
@@ -264,6 +282,7 @@ public class BaseOrderController extends CommonBaseController {
"5--出行中(进行中)\n"
+
"6--已完成"
)
private
Integer
status
;
}
/**
...
...
@@ -274,6 +293,16 @@ public class BaseOrderController extends CommonBaseController {
private
String
no
;
}
@Data
public
class
QueryOrderList
extends
QueryOrderDetailDTO
{
private
Long
startTime
;
private
Long
endTime
;
private
Integer
startCompanyId
;
}
@Data
public
class
NotifyUrlDTO
{
//订单号
...
...
xx-order/xx-order-server/src/main/resources/mapper/BaseOrderMapper.xml
View file @
0a1347c1
...
...
@@ -4,26 +4,26 @@
<mapper
namespace=
"com.xxfc.platform.order.mapper.BaseOrderMapper"
>
<!-- 可根据自己的需求,是否要使用 -->
<!-- <resultMap type="com.xxfc.platform.order.entity.BaseOrder" id="baseOrderMap">--
>
<!-- <result property="id" column="id"/>--
>
<!-- <result property="no" column="no"/>--
>
<!-- <result property="type" column="type"/>--
>
<!-- <result property="detailId" column="detail_id"/>--
>
<!-- <result property="status" column="status"/>--
>
<!-- <result property="productAmount" column="product_amount"/>--
>
<!-- <result property="orderAmount" column="order_amount"/>--
>
<!-- <result property="detailJson" column="detail_json"/>--
>
<!-- <result property="thirdType" column="third_type"/>--
>
<!-- <result property="outTradeNo" column="out_trade_no"/>--
>
<!-- <result property="crtTime" column="crt_time"/>--
>
<!-- <result property="crtUser" column="crt_user"/>--
>
<!-- <result property="crtName" column="crt_name"/>--
>
<!-- <result property="crtHost" column="crt_host"/>--
>
<!-- <result property="updTime" column="upd_time"/>--
>
<!-- <result property="updUser" column="upd_user"/>--
>
<!-- <result property="updName" column="upd_name"/>--
>
<!-- <result property="updHost" column="upd_host"/>--
>
<!-- </resultMap>--
>
<resultMap
type=
"com.xxfc.platform.order.entity.BaseOrder"
id=
"baseOrderMap"
>
<result
property=
"id"
column=
"id"
/
>
<result
property=
"no"
column=
"no"
/
>
<result
property=
"type"
column=
"type"
/
>
<result
property=
"detailId"
column=
"detail_id"
/
>
<result
property=
"status"
column=
"status"
/
>
<result
property=
"productAmount"
column=
"product_amount"
/
>
<result
property=
"orderAmount"
column=
"order_amount"
/
>
<result
property=
"detailJson"
column=
"detail_json"
/
>
<result
property=
"thirdType"
column=
"third_type"
/
>
<result
property=
"outTradeNo"
column=
"out_trade_no"
/
>
<result
property=
"crtTime"
column=
"crt_time"
/
>
<result
property=
"crtUser"
column=
"crt_user"
/
>
<result
property=
"crtName"
column=
"crt_name"
/
>
<result
property=
"crtHost"
column=
"crt_host"
/
>
<result
property=
"updTime"
column=
"upd_time"
/
>
<result
property=
"updUser"
column=
"upd_user"
/
>
<result
property=
"updName"
column=
"upd_name"
/
>
<result
property=
"updHost"
column=
"upd_host"
/
>
</resultMap
>
<resultMap
type=
"com.xxfc.platform.order.pojo.order.OrderPageVO"
id=
"orderPageMap"
>
<result
javaType=
"Integer"
column=
"type"
property=
"type"
></result>
...
...
@@ -45,7 +45,7 @@
and crt_user = #{crtUser}
</if>
<if
test=
"crtCompanyId != null"
>
and crt_
user
= #{crtCompanyId}
and crt_
company_id
= #{crtCompanyId}
</if>
<if
test=
"status != null"
>
and status = #{status}
...
...
@@ -57,4 +57,31 @@
order by crt_time desc
</select>
<select
id=
"listOrder"
parameterType=
"Map"
resultMap=
"orderPageMap"
>
select b.*
from base_order b
LEFT JOIN order_rent_vehicle_detail r on r.order_id = b.id
LEFT JOIN order_tour_detail t on t.order_id = b.id
<where>
<if
test=
"crtUser != null"
>
and b.crt_user = #{crtUser}
</if>
<if
test=
"status != null"
>
and b.status = #{status}
</if>
<if
test=
"no != null"
>
and no like CONCAT ("%", #{no}, "%")
</if>
<if
test=
"startTime != null"
>
and r.start_time between #{startTime} and #{endTime}
or t.start_time between #{startTime} and #{endTime}
</if>
<if
test=
"startCompanyId != null"
>
and r.start_company_id = #{startCompanyId}
or t.start_company_id = #{startCompanyId}
</if>
</where>
order by b.crt_time desc
</select>
</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