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
05840b6c
Commit
05840b6c
authored
Dec 14, 2020
by
hezhen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1232
parent
3545f609
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
61 additions
and
0 deletions
+61
-0
VehiclePublishBiz.java
...java/com/xxfc/platform/vehicle/biz/VehiclePublishBiz.java
+44
-0
VehiclePublishReceiveBiz.java
...m/xxfc/platform/vehicle/biz/VehiclePublishReceiveBiz.java
+4
-0
VehiclePublishReceiveMapper.java
.../platform/vehicle/mapper/VehiclePublishReceiveMapper.java
+4
-0
AppVehiclePublishController.java
...fc/platform/vehicle/rest/AppVehiclePublishController.java
+9
-0
No files found.
xx-vehicle/xx-vehicle-server/src/main/java/com/xxfc/platform/vehicle/biz/VehiclePublishBiz.java
View file @
05840b6c
...
@@ -2,11 +2,13 @@ package com.xxfc.platform.vehicle.biz;
...
@@ -2,11 +2,13 @@ package com.xxfc.platform.vehicle.biz;
import
com.alibaba.fastjson.JSONArray
;
import
com.alibaba.fastjson.JSONObject
;
import
com.alibaba.fastjson.JSONObject
;
import
com.github.pagehelper.PageHelper
;
import
com.github.pagehelper.PageHelper
;
import
com.github.pagehelper.PageInfo
;
import
com.github.pagehelper.PageInfo
;
import
com.github.wxiaoqi.security.common.biz.BaseBiz
;
import
com.github.wxiaoqi.security.common.biz.BaseBiz
;
import
com.github.wxiaoqi.security.common.exception.BaseException
;
import
com.github.wxiaoqi.security.common.exception.BaseException
;
import
com.github.wxiaoqi.security.common.util.BeanUtils
;
import
com.github.wxiaoqi.security.common.util.process.ResultCode
;
import
com.github.wxiaoqi.security.common.util.process.ResultCode
;
import
com.github.wxiaoqi.security.common.vo.PageDataVO
;
import
com.github.wxiaoqi.security.common.vo.PageDataVO
;
import
com.xxfc.platform.app.entity.Cofig
;
import
com.xxfc.platform.app.entity.Cofig
;
...
@@ -17,6 +19,7 @@ import com.xxfc.platform.vehicle.entity.VehiclePublishGoods;
...
@@ -17,6 +19,7 @@ import com.xxfc.platform.vehicle.entity.VehiclePublishGoods;
import
com.xxfc.platform.vehicle.entity.VehiclePublishReceive
;
import
com.xxfc.platform.vehicle.entity.VehiclePublishReceive
;
import
com.xxfc.platform.vehicle.mapper.VehiclePublishMapper
;
import
com.xxfc.platform.vehicle.mapper.VehiclePublishMapper
;
import
com.xxfc.platform.vehicle.pojo.dto.VehiclePublishFindDTO
;
import
com.xxfc.platform.vehicle.pojo.dto.VehiclePublishFindDTO
;
import
com.xxfc.platform.vehicle.pojo.vo.VehiclePublishGoodsVo
;
import
com.xxfc.platform.vehicle.pojo.vo.VehiclePublishVo
;
import
com.xxfc.platform.vehicle.pojo.vo.VehiclePublishVo
;
import
lombok.extern.slf4j.Slf4j
;
import
lombok.extern.slf4j.Slf4j
;
import
org.apache.commons.collections.CollectionUtils
;
import
org.apache.commons.collections.CollectionUtils
;
...
@@ -25,6 +28,7 @@ import org.springframework.beans.factory.annotation.Autowired;
...
@@ -25,6 +28,7 @@ import org.springframework.beans.factory.annotation.Autowired;
import
org.springframework.stereotype.Service
;
import
org.springframework.stereotype.Service
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.transaction.annotation.Transactional
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.List
;
...
@@ -125,6 +129,46 @@ public class VehiclePublishBiz extends BaseBiz<VehiclePublishMapper, VehiclePubl
...
@@ -125,6 +129,46 @@ public class VehiclePublishBiz extends BaseBiz<VehiclePublishMapper, VehiclePubl
}
}
public
JSONObject
detailV2
(
Integer
publisId
){
VehiclePublish
vehiclePublish
=
selectById
(
publisId
);
JSONObject
data
=
new
JSONObject
();
if
(
vehiclePublish
!=
null
){
data
.
put
(
"vehiclePublish"
,
vehiclePublish
);
VehiclePublishGoods
publishGoods
=
new
VehiclePublishGoods
();
publishGoods
.
setPublishId
(
publisId
);
List
<
VehiclePublishGoods
>
list
=
publishGoodsBiz
.
selectList
(
publishGoods
);
if
(
list
.
size
()
>
0
){
JSONArray
array1
=
new
JSONArray
();
JSONArray
array2
=
new
JSONArray
();
JSONArray
array3
=
new
JSONArray
();
for
(
VehiclePublishGoods
vehiclePublishGoods
:
list
){
JSONObject
jsonObject
=
new
JSONObject
();
jsonObject
.
put
(
"publishGoods"
,
vehiclePublishGoods
);
VehiclePublishReceive
publishReceive
=
publishReceiveBiz
.
getReceivByPubilishId
(
vehiclePublishGoods
.
getId
());
Integer
publishGoodsStatus
=
0
;
if
(
publishReceive
!=
null
){
publishGoodsStatus
=
publishReceive
.
getStatus
();
jsonObject
.
put
(
"publishGoodsStatus"
,
publishGoodsStatus
);
if
(
publishGoodsStatus
==
1
){
array1
.
add
(
jsonObject
);
}
else
if
(
publishGoodsStatus
==
3
||
publishGoodsStatus
==
5
||
publishGoodsStatus
==
6
){
array2
.
add
(
jsonObject
);
}
}
else
{
jsonObject
.
put
(
"publishGoodsStatus"
,
0
);
array3
.
add
(
jsonObject
);
}
}
data
.
put
(
"array1"
,
array1
);
data
.
put
(
"array2"
,
array2
);
data
.
put
(
"array3"
,
array3
);
}
}
return
data
;
}
//入驻规则管理
//入驻规则管理
public
JSONObject
getConfig
(){
public
JSONObject
getConfig
(){
...
...
xx-vehicle/xx-vehicle-server/src/main/java/com/xxfc/platform/vehicle/biz/VehiclePublishReceiveBiz.java
View file @
05840b6c
...
@@ -520,6 +520,10 @@ public class VehiclePublishReceiveBiz extends BaseBiz<VehiclePublishReceiveMappe
...
@@ -520,6 +520,10 @@ public class VehiclePublishReceiveBiz extends BaseBiz<VehiclePublishReceiveMappe
return
mapper
.
getReceivByVehicleId
(
vehicleId
);
return
mapper
.
getReceivByVehicleId
(
vehicleId
);
}
}
public
VehiclePublishReceive
getReceivByPubilishId
(
Integer
pubilishId
){
return
mapper
.
getReceivByPubilishId
(
pubilishId
);
}
public
void
canelReceiveOrder
(
String
orderNo
){
public
void
canelReceiveOrder
(
String
orderNo
){
VehiclePublishFindDTO
publishFindDTO
=
new
VehiclePublishFindDTO
();
VehiclePublishFindDTO
publishFindDTO
=
new
VehiclePublishFindDTO
();
...
...
xx-vehicle/xx-vehicle-server/src/main/java/com/xxfc/platform/vehicle/mapper/VehiclePublishReceiveMapper.java
View file @
05840b6c
...
@@ -34,4 +34,8 @@ public interface VehiclePublishReceiveMapper extends Mapper<VehiclePublishReceiv
...
@@ -34,4 +34,8 @@ public interface VehiclePublishReceiveMapper extends Mapper<VehiclePublishReceiv
"WHERE vehicle_id = #{vehicleId} and `status` in (0,1,3)"
)
"WHERE vehicle_id = #{vehicleId} and `status` in (0,1,3)"
)
VehiclePublishReceive
getReceivByVehicleId
(
@Param
(
"vehicleId"
)
String
vehicleId
);
VehiclePublishReceive
getReceivByVehicleId
(
@Param
(
"vehicleId"
)
String
vehicleId
);
@Select
(
"SELECT * FROM vehicle_publish_receive WHERE publish_goods_id =#{pubilishId} and `status` in (1,3,5,6) ORDER BY id DESC LIMIT 1"
)
VehiclePublishReceive
getReceivByPubilishId
(
@Param
(
"pubilishId"
)
Integer
pubilishId
);
}
}
\ No newline at end of file
xx-vehicle/xx-vehicle-server/src/main/java/com/xxfc/platform/vehicle/rest/AppVehiclePublishController.java
View file @
05840b6c
...
@@ -100,6 +100,15 @@ public class AppVehiclePublishController extends BaseController<VehiclePublishBi
...
@@ -100,6 +100,15 @@ public class AppVehiclePublishController extends BaseController<VehiclePublishBi
}
}
@GetMapping
(
"publishDetailV2"
)
@ApiModelProperty
(
"我的发布详情"
)
@IgnoreUserToken
public
ObjectRestResponse
publishDetailV2
(
VehiclePublishFindDTO
publishFindDTO
)
{
return
ObjectRestResponse
.
succ
(
baseBiz
.
detailV2
(
publishFindDTO
.
getPublishId
()));
}
...
...
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