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
03f8f53a
Commit
03f8f53a
authored
Oct 13, 2020
by
hezhen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改商品详情
parent
ee9a082f
Changes
6
Show whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
47 additions
and
2 deletions
+47
-2
BranchCompany.java
.../java/com/xxfc/platform/vehicle/entity/BranchCompany.java
+9
-0
BranchCompanyBiz.java
.../java/com/xxfc/platform/vehicle/biz/BranchCompanyBiz.java
+2
-1
VehicleBiz.java
...c/main/java/com/xxfc/platform/vehicle/biz/VehicleBiz.java
+7
-0
VehicleMapper.java
.../java/com/xxfc/platform/vehicle/mapper/VehicleMapper.java
+3
-0
AppVehicleController.java
.../com/xxfc/platform/vehicle/rest/AppVehicleController.java
+11
-1
AppVehicleExtensionController.java
.../platform/vehicle/rest/AppVehicleExtensionController.java
+15
-0
No files found.
xx-vehicle/xx-vehicle-api/src/main/java/com/xxfc/platform/vehicle/entity/BranchCompany.java
View file @
03f8f53a
...
@@ -172,4 +172,13 @@ public class BranchCompany {
...
@@ -172,4 +172,13 @@ public class BranchCompany {
@Column
(
name
=
"is_del"
)
@Column
(
name
=
"is_del"
)
private
Integer
isDel
;
private
Integer
isDel
;
//浏览量
@Column
(
name
=
"browse_num"
)
private
Integer
browseNum
;
//点赞数量
@Column
(
name
=
"give_num"
)
private
Integer
giveNum
;
}
}
\ No newline at end of file
xx-vehicle/xx-vehicle-server/src/main/java/com/xxfc/platform/vehicle/biz/BranchCompanyBiz.java
View file @
03f8f53a
...
@@ -128,7 +128,7 @@ public class BranchCompanyBiz extends BaseBiz<BranchCompanyMapper, BranchCompany
...
@@ -128,7 +128,7 @@ public class BranchCompanyBiz extends BaseBiz<BranchCompanyMapper, BranchCompany
* @param id
* @param id
* @return
* @return
*/
*/
@Cache
(
key
=
RedisKey
.
BRANCH_COMPANY_CACHE
+
"{1}"
)
//
@Cache(key = RedisKey.BRANCH_COMPANY_CACHE + "{1}")
public
CompanyDetail
getDetailById
(
Integer
id
)
{
public
CompanyDetail
getDetailById
(
Integer
id
)
{
BranchCompany
branchCompany
=
this
.
getById
(
id
);
BranchCompany
branchCompany
=
this
.
getById
(
id
);
CompanyDetail
detail
=
null
;
CompanyDetail
detail
=
null
;
...
@@ -518,4 +518,5 @@ public class BranchCompanyBiz extends BaseBiz<BranchCompanyMapper, BranchCompany
...
@@ -518,4 +518,5 @@ public class BranchCompanyBiz extends BaseBiz<BranchCompanyMapper, BranchCompany
return
ObjectRestResponse
.
succ
();
return
ObjectRestResponse
.
succ
();
}
}
}
}
xx-vehicle/xx-vehicle-server/src/main/java/com/xxfc/platform/vehicle/biz/VehicleBiz.java
View file @
03f8f53a
...
@@ -1604,6 +1604,7 @@ public class VehicleBiz extends BaseBiz<VehicleMapper, Vehicle> implements UserR
...
@@ -1604,6 +1604,7 @@ public class VehicleBiz extends BaseBiz<VehicleMapper, Vehicle> implements UserR
}
}
Vehicle
vehicle
=
JSONUtil
.
toBean
(
vehicleApply
.
getChangeJson
(),
Vehicle
.
class
);
Vehicle
vehicle
=
JSONUtil
.
toBean
(
vehicleApply
.
getChangeJson
(),
Vehicle
.
class
);
if
(
StringUtils
.
isNotBlank
(
vehicleId
)){
if
(
StringUtils
.
isNotBlank
(
vehicleId
)){
vehicle
.
setExtensionList
(
null
);
if
(!
CheckObjectIsNullUtils
.
objCheckIsNull
(
vehicle
)
){
if
(!
CheckObjectIsNullUtils
.
objCheckIsNull
(
vehicle
)
){
vehicle
.
setId
(
vehicleId
);
vehicle
.
setId
(
vehicleId
);
updateSelectiveById
(
vehicle
);
updateSelectiveById
(
vehicle
);
...
@@ -1640,6 +1641,12 @@ public class VehicleBiz extends BaseBiz<VehicleMapper, Vehicle> implements UserR
...
@@ -1640,6 +1641,12 @@ public class VehicleBiz extends BaseBiz<VehicleMapper, Vehicle> implements UserR
}
}
public
Long
countByCompanyId
(
Integer
companyId
){
return
mapper
.
countByCompamyId
(
companyId
);
}
...
...
xx-vehicle/xx-vehicle-server/src/main/java/com/xxfc/platform/vehicle/mapper/VehicleMapper.java
View file @
03f8f53a
...
@@ -62,4 +62,7 @@ public interface VehicleMapper extends Mapper<Vehicle> {
...
@@ -62,4 +62,7 @@ public interface VehicleMapper extends Mapper<Vehicle> {
List
<
Vehicle
>
getAllVehicleByParam
(
Map
<
String
,
Object
>
param
);
List
<
Vehicle
>
getAllVehicleByParam
(
Map
<
String
,
Object
>
param
);
List
<
VehicleVO
>
selectList
(
VehicleFindDTO
vehicleFindDTO
);
List
<
VehicleVO
>
selectList
(
VehicleFindDTO
vehicleFindDTO
);
@Select
(
"SELECT COUNT(*) FROM vehicle WHERE is_del=0 and subordinate_branch = #{commpanyId}"
)
Long
countByCompamyId
(
@Param
(
"commpanyId"
)
Integer
commpanyId
);
}
}
\ No newline at end of file
xx-vehicle/xx-vehicle-server/src/main/java/com/xxfc/platform/vehicle/rest/AppVehicleController.java
View file @
03f8f53a
package
com
.
xxfc
.
platform
.
vehicle
.
rest
;
package
com
.
xxfc
.
platform
.
vehicle
.
rest
;
import
com.github.wxiaoqi.security.auth.client.annotation.IgnoreUserToken
;
import
com.github.wxiaoqi.security.common.msg.ObjectRestResponse
;
import
com.github.wxiaoqi.security.common.msg.ObjectRestResponse
;
import
com.github.wxiaoqi.security.common.util.process.ResultCode
;
import
com.github.wxiaoqi.security.common.util.process.ResultCode
;
import
com.xxfc.platform.vehicle.biz.VehicleApplyBiz
;
import
com.xxfc.platform.vehicle.biz.VehicleApplyBiz
;
...
@@ -54,8 +55,10 @@ public class AppVehicleController extends BaseController<VehicleBiz> {
...
@@ -54,8 +55,10 @@ public class AppVehicleController extends BaseController<VehicleBiz> {
return
ObjectRestResponse
.
succ
(
baseBiz
.
info
(
vehicleFindDTO
));
return
ObjectRestResponse
.
succ
(
baseBiz
.
info
(
vehicleFindDTO
));
}
}
@GetMapping
(
"detail/{id}"
)
@GetMapping
(
"app/unauth/detail/{id}"
)
@ApiModelProperty
(
"商品详情"
)
@ApiModelProperty
(
"商品详情"
)
@IgnoreUserToken
public
ObjectRestResponse
detail
(
@PathVariable
(
"id"
)
String
id
)
{
public
ObjectRestResponse
detail
(
@PathVariable
(
"id"
)
String
id
)
{
VehicleFindDTO
vehicleFindDTO
=
new
VehicleFindDTO
();
VehicleFindDTO
vehicleFindDTO
=
new
VehicleFindDTO
();
vehicleFindDTO
.
setVehicleId
(
id
);
vehicleFindDTO
.
setVehicleId
(
id
);
...
@@ -67,6 +70,13 @@ public class AppVehicleController extends BaseController<VehicleBiz> {
...
@@ -67,6 +70,13 @@ public class AppVehicleController extends BaseController<VehicleBiz> {
}
}
@GetMapping
(
"app/unauth/countByCompamyId/{id}"
)
@ApiModelProperty
(
"商品详情"
)
@IgnoreUserToken
public
ObjectRestResponse
countByCompamyId
(
@PathVariable
(
"id"
)
Integer
id
)
{
return
ObjectRestResponse
.
succ
(
baseBiz
.
countByCompanyId
(
id
));
}
...
...
xx-vehicle/xx-vehicle-server/src/main/java/com/xxfc/platform/vehicle/rest/AppVehicleExtensionController.java
View file @
03f8f53a
package
com
.
xxfc
.
platform
.
vehicle
.
rest
;
package
com
.
xxfc
.
platform
.
vehicle
.
rest
;
import
com.github.wxiaoqi.security.auth.client.annotation.IgnoreClientToken
;
import
com.github.wxiaoqi.security.common.msg.ObjectRestResponse
;
import
com.github.wxiaoqi.security.common.msg.ObjectRestResponse
;
import
com.xxfc.platform.vehicle.biz.VehicleExtensionBiz
;
import
com.xxfc.platform.vehicle.biz.VehicleExtensionBiz
;
import
com.xxfc.platform.vehicle.pojo.vo.VehicleExtensionVO
;
import
com.xxfc.platform.vehicle.pojo.vo.VehicleExtensionVO
;
...
@@ -42,6 +43,20 @@ public class AppVehicleExtensionController extends BaseController<VehicleExtensi
...
@@ -42,6 +43,20 @@ public class AppVehicleExtensionController extends BaseController<VehicleExtensi
}
}
@GetMapping
(
"app/unauth/tree"
)
@ApiModelProperty
(
"商品详情"
)
@IgnoreClientToken
public
ObjectRestResponse
tree
(
@RequestParam
(
value
=
"vehicleId"
,
defaultValue
=
""
)
String
vehicleId
,
@RequestParam
(
value
=
"extensionList"
,
defaultValue
=
""
)
String
extensionList
)
{
List
<
VehicleExtensionVO
>
list
=
null
;
if
(
StringUtils
.
isNotBlank
(
vehicleId
)){
list
=
baseBiz
.
getTree
(
vehicleId
);
}
else
if
(
StringUtils
.
isNotBlank
(
extensionList
)){
list
=
baseBiz
.
getTreeByApply
(
Arrays
.
asList
(
extensionList
.
split
(
","
)).
parallelStream
().
map
(
s
->
Integer
.
valueOf
(
s
)).
collect
(
Collectors
.
toList
()));
}
return
ObjectRestResponse
.
succ
(
list
);
}
...
...
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