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
c3de5602
Commit
c3de5602
authored
Jun 14, 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
61b9e60c
805ab780
Changes
13
Hide whitespace changes
Inline
Side-by-side
Showing
13 changed files
with
129 additions
and
1 deletion
+129
-1
TourGoodBannerBiz.java
...in/java/com/xxfc/platform/tour/biz/TourGoodBannerBiz.java
+6
-0
TourGoodBiz.java
...src/main/java/com/xxfc/platform/tour/biz/TourGoodBiz.java
+26
-1
TourGoodSiteBiz.java
...main/java/com/xxfc/platform/tour/biz/TourGoodSiteBiz.java
+6
-0
TourGoodSpeBiz.java
.../main/java/com/xxfc/platform/tour/biz/TourGoodSpeBiz.java
+4
-0
TourGoodTagBiz.java
.../main/java/com/xxfc/platform/tour/biz/TourGoodTagBiz.java
+5
-0
TourGoodBannerMapper.java
...a/com/xxfc/platform/tour/mapper/TourGoodBannerMapper.java
+3
-0
TourGoodSiteMapper.java
...ava/com/xxfc/platform/tour/mapper/TourGoodSiteMapper.java
+3
-0
TourGoodSpePriceMapper.java
...com/xxfc/platform/tour/mapper/TourGoodSpePriceMapper.java
+3
-0
TourGoodTagMapper.java
...java/com/xxfc/platform/tour/mapper/TourGoodTagMapper.java
+3
-0
TourGoodBannerMapper.xml
...server/src/main/resources/mapper/TourGoodBannerMapper.xml
+18
-0
TourGoodSiteMapper.xml
...r-server/src/main/resources/mapper/TourGoodSiteMapper.xml
+16
-0
TourGoodSpePriceMapper.xml
...rver/src/main/resources/mapper/TourGoodSpePriceMapper.xml
+18
-0
TourGoodTagMapper.xml
...ur-server/src/main/resources/mapper/TourGoodTagMapper.xml
+18
-0
No files found.
xx-tour/xx-tour-server/src/main/java/com/xxfc/platform/tour/biz/TourGoodBannerBiz.java
View file @
c3de5602
...
@@ -6,6 +6,8 @@ import org.springframework.stereotype.Service;
...
@@ -6,6 +6,8 @@ import org.springframework.stereotype.Service;
import
com.xxfc.platform.tour.entity.TourGoodBanner
;
import
com.xxfc.platform.tour.entity.TourGoodBanner
;
import
com.github.wxiaoqi.security.common.biz.BaseBiz
;
import
com.github.wxiaoqi.security.common.biz.BaseBiz
;
import
java.util.List
;
/**
/**
* 商品轮播图
* 商品轮播图
*
*
...
@@ -15,4 +17,8 @@ import com.github.wxiaoqi.security.common.biz.BaseBiz;
...
@@ -15,4 +17,8 @@ import com.github.wxiaoqi.security.common.biz.BaseBiz;
*/
*/
@Service
@Service
public
class
TourGoodBannerBiz
extends
BaseBiz
<
TourGoodBannerMapper
,
TourGoodBanner
>
{
public
class
TourGoodBannerBiz
extends
BaseBiz
<
TourGoodBannerMapper
,
TourGoodBanner
>
{
//删除轮播
public
void
delGoodBanner
(
Integer
goodId
,
List
<
Integer
>
ids
){
mapper
.
delBanner
(
goodId
,
ids
);
}
}
}
\ No newline at end of file
xx-tour/xx-tour-server/src/main/java/com/xxfc/platform/tour/biz/TourGoodBiz.java
View file @
c3de5602
...
@@ -22,6 +22,7 @@ import org.springframework.stereotype.Service;
...
@@ -22,6 +22,7 @@ import org.springframework.stereotype.Service;
import
java.lang.reflect.InvocationTargetException
;
import
java.lang.reflect.InvocationTargetException
;
import
java.math.BigDecimal
;
import
java.math.BigDecimal
;
import
java.math.RoundingMode
;
import
java.math.RoundingMode
;
import
java.util.ArrayList
;
import
java.util.HashMap
;
import
java.util.HashMap
;
import
java.util.List
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.Map
;
...
@@ -108,6 +109,7 @@ public class TourGoodBiz extends BaseBiz<TourGoodMapper, TourGood> {
...
@@ -108,6 +109,7 @@ public class TourGoodBiz extends BaseBiz<TourGoodMapper, TourGood> {
if
(
goodId
>
0
){
if
(
goodId
>
0
){
List
<
GoodBannerDTO
>
bannerList
=
dto
.
getBannerDTOS
();
List
<
GoodBannerDTO
>
bannerList
=
dto
.
getBannerDTOS
();
if
(
bannerList
.
size
()>
0
){
if
(
bannerList
.
size
()>
0
){
List
<
Integer
>
bannerIds
=
new
ArrayList
<>();
for
(
GoodBannerDTO
bannerDTO:
bannerList
){
for
(
GoodBannerDTO
bannerDTO:
bannerList
){
Integer
bannerId
=
bannerDTO
.
getId
();
Integer
bannerId
=
bannerDTO
.
getId
();
TourGoodBanner
goodBanner
=
new
TourGoodBanner
();
TourGoodBanner
goodBanner
=
new
TourGoodBanner
();
...
@@ -117,11 +119,19 @@ public class TourGoodBiz extends BaseBiz<TourGoodMapper, TourGood> {
...
@@ -117,11 +119,19 @@ public class TourGoodBiz extends BaseBiz<TourGoodMapper, TourGood> {
bannerBiz
.
insertSelective
(
goodBanner
);
bannerBiz
.
insertSelective
(
goodBanner
);
}
else
{
}
else
{
bannerBiz
.
updateSelectiveById
(
goodBanner
);
bannerBiz
.
updateSelectiveById
(
goodBanner
);
bannerIds
.
add
(
bannerId
);
}
}
}
}
if
(
bannerIds
.
size
()>
0
){
bannerBiz
.
delGoodBanner
(
null
,
bannerIds
);
}
}
else
{
bannerBiz
.
delGoodBanner
(
goodId
,
null
);
}
}
List
<
GoodSiteDTO
>
siteDTOList
=
dto
.
getSiteDTOS
();
List
<
GoodSiteDTO
>
siteDTOList
=
dto
.
getSiteDTOS
();
if
(
siteDTOList
.
size
()>
0
){
if
(
siteDTOList
.
size
()>
0
){
List
<
Integer
>
siteIds
=
new
ArrayList
<>();
for
(
GoodSiteDTO
siteDTO:
siteDTOList
){
for
(
GoodSiteDTO
siteDTO:
siteDTOList
){
Integer
siteId
=
siteDTO
.
getId
();
Integer
siteId
=
siteDTO
.
getId
();
TourGoodSite
site
=
new
TourGoodSite
();
TourGoodSite
site
=
new
TourGoodSite
();
...
@@ -131,12 +141,16 @@ public class TourGoodBiz extends BaseBiz<TourGoodMapper, TourGood> {
...
@@ -131,12 +141,16 @@ public class TourGoodBiz extends BaseBiz<TourGoodMapper, TourGood> {
siteBiz
.
insertSelective
(
site
);
siteBiz
.
insertSelective
(
site
);
}
else
{
}
else
{
siteBiz
.
updateById
(
site
);
siteBiz
.
updateById
(
site
);
siteIds
.
add
(
siteId
);
}
}
}
}
if
(
siteIds
.
size
()>
0
){
siteBiz
.
delGoodSite
(
null
,
siteIds
);
}
}
}
List
<
GoodTagDTO
>
tagList
=
dto
.
getTagDTOS
();
List
<
GoodTagDTO
>
tagList
=
dto
.
getTagDTOS
();
if
(
siteDTOList
.
size
()>
0
){
if
(
siteDTOList
.
size
()>
0
){
List
<
Integer
>
tagIds
=
new
ArrayList
<>();
for
(
GoodTagDTO
tagDTO:
tagList
){
for
(
GoodTagDTO
tagDTO:
tagList
){
Integer
tagId
=
tagDTO
.
getId
();
Integer
tagId
=
tagDTO
.
getId
();
TourGoodTag
tag
=
new
TourGoodTag
();
TourGoodTag
tag
=
new
TourGoodTag
();
...
@@ -146,11 +160,18 @@ public class TourGoodBiz extends BaseBiz<TourGoodMapper, TourGood> {
...
@@ -146,11 +160,18 @@ public class TourGoodBiz extends BaseBiz<TourGoodMapper, TourGood> {
tagBiz
.
insertSelective
(
tag
);
tagBiz
.
insertSelective
(
tag
);
}
else
{
}
else
{
tagBiz
.
updateById
(
tag
);
tagBiz
.
updateById
(
tag
);
tagIds
.
add
(
tagId
);
}
}
}
}
if
(
tagIds
.
size
()>
0
){
tagBiz
.
delGoodTag
(
null
,
tagIds
);
}
}
else
{
tagBiz
.
delGoodTag
(
goodId
,
null
);
}
}
List
<
GoodSpePriceDTO
>
priceDTOList
=
dto
.
getPriceDTOS
();
List
<
GoodSpePriceDTO
>
priceDTOList
=
dto
.
getPriceDTOS
();
if
(
siteDTOList
.
size
()>
0
){
if
(
siteDTOList
.
size
()>
0
){
List
<
Integer
>
priceIds
=
new
ArrayList
<>();
for
(
GoodSpePriceDTO
priceDTO:
priceDTOList
){
for
(
GoodSpePriceDTO
priceDTO:
priceDTOList
){
Integer
priceId
=
priceDTO
.
getId
();
Integer
priceId
=
priceDTO
.
getId
();
TourGoodSpePrice
spePrice
=
new
TourGoodSpePrice
();
TourGoodSpePrice
spePrice
=
new
TourGoodSpePrice
();
...
@@ -185,8 +206,12 @@ public class TourGoodBiz extends BaseBiz<TourGoodMapper, TourGood> {
...
@@ -185,8 +206,12 @@ public class TourGoodBiz extends BaseBiz<TourGoodMapper, TourGood> {
speBiz
.
insertSelective
(
spePrice
);
speBiz
.
insertSelective
(
spePrice
);
}
else
{
}
else
{
speBiz
.
updateById
(
spePrice
);
speBiz
.
updateById
(
spePrice
);
priceIds
.
add
(
priceId
);
}
}
}
}
if
(
priceIds
.
size
()>
0
){
speBiz
.
delGoodSpe
(
null
,
priceIds
);
}
}
}
}
}
}
catch
(
IllegalAccessException
e
)
{
}
catch
(
IllegalAccessException
e
)
{
...
...
xx-tour/xx-tour-server/src/main/java/com/xxfc/platform/tour/biz/TourGoodSiteBiz.java
View file @
c3de5602
...
@@ -6,6 +6,8 @@ import org.springframework.stereotype.Service;
...
@@ -6,6 +6,8 @@ import org.springframework.stereotype.Service;
import
com.xxfc.platform.tour.entity.TourGoodSite
;
import
com.xxfc.platform.tour.entity.TourGoodSite
;
import
com.github.wxiaoqi.security.common.biz.BaseBiz
;
import
com.github.wxiaoqi.security.common.biz.BaseBiz
;
import
java.util.List
;
/**
/**
* 路线站点表
* 路线站点表
*
*
...
@@ -15,4 +17,8 @@ import com.github.wxiaoqi.security.common.biz.BaseBiz;
...
@@ -15,4 +17,8 @@ import com.github.wxiaoqi.security.common.biz.BaseBiz;
*/
*/
@Service
@Service
public
class
TourGoodSiteBiz
extends
BaseBiz
<
TourGoodSiteMapper
,
TourGoodSite
>
{
public
class
TourGoodSiteBiz
extends
BaseBiz
<
TourGoodSiteMapper
,
TourGoodSite
>
{
//删除站点
public
void
delGoodSite
(
Integer
goodId
,
List
<
Integer
>
ids
){
mapper
.
delSite
(
goodId
,
ids
);}
}
}
\ No newline at end of file
xx-tour/xx-tour-server/src/main/java/com/xxfc/platform/tour/biz/TourGoodSpeBiz.java
View file @
c3de5602
...
@@ -15,6 +15,7 @@ import com.github.wxiaoqi.security.common.biz.BaseBiz;
...
@@ -15,6 +15,7 @@ import com.github.wxiaoqi.security.common.biz.BaseBiz;
import
java.math.BigDecimal
;
import
java.math.BigDecimal
;
import
java.math.RoundingMode
;
import
java.math.RoundingMode
;
import
java.util.List
;
/**
/**
* 旅游商品规格表
* 旅游商品规格表
...
@@ -92,5 +93,8 @@ public class TourGoodSpeBiz extends BaseBiz<TourGoodSpePriceMapper, TourGoodSpeP
...
@@ -92,5 +93,8 @@ public class TourGoodSpeBiz extends BaseBiz<TourGoodSpePriceMapper, TourGoodSpeP
}
}
}
}
//删除
public
void
delGoodSpe
(
Integer
goodId
,
List
<
Integer
>
ids
){
mapper
.
delSpe
(
goodId
,
ids
);}
}
}
\ No newline at end of file
xx-tour/xx-tour-server/src/main/java/com/xxfc/platform/tour/biz/TourGoodTagBiz.java
View file @
c3de5602
...
@@ -6,6 +6,8 @@ import org.springframework.stereotype.Service;
...
@@ -6,6 +6,8 @@ import org.springframework.stereotype.Service;
import
com.xxfc.platform.tour.entity.TourGoodTag
;
import
com.xxfc.platform.tour.entity.TourGoodTag
;
import
com.github.wxiaoqi.security.common.biz.BaseBiz
;
import
com.github.wxiaoqi.security.common.biz.BaseBiz
;
import
java.util.List
;
/**
/**
* 商品标签表
* 商品标签表
*
*
...
@@ -16,4 +18,7 @@ import com.github.wxiaoqi.security.common.biz.BaseBiz;
...
@@ -16,4 +18,7 @@ import com.github.wxiaoqi.security.common.biz.BaseBiz;
@Service
@Service
public
class
TourGoodTagBiz
extends
BaseBiz
<
TourGoodTagMapper
,
TourGoodTag
>
{
public
class
TourGoodTagBiz
extends
BaseBiz
<
TourGoodTagMapper
,
TourGoodTag
>
{
//删除标签
public
void
delGoodTag
(
Integer
goodId
,
List
<
Integer
>
ids
){
mapper
.
delTag
(
goodId
,
ids
);}
}
}
\ No newline at end of file
xx-tour/xx-tour-server/src/main/java/com/xxfc/platform/tour/mapper/TourGoodBannerMapper.java
View file @
c3de5602
...
@@ -17,5 +17,8 @@ import java.util.List;
...
@@ -17,5 +17,8 @@ import java.util.List;
public
interface
TourGoodBannerMapper
extends
Mapper
<
TourGoodBanner
>
{
public
interface
TourGoodBannerMapper
extends
Mapper
<
TourGoodBanner
>
{
//查询旅游路线列表
//查询旅游路线列表
public
List
<
GoodBannerDTO
>
getBannerList
(
@Param
(
"goodId"
)
Integer
goodId
);
public
List
<
GoodBannerDTO
>
getBannerList
(
@Param
(
"goodId"
)
Integer
goodId
);
//删除Banner
public
int
delBanner
(
@Param
(
"goodId"
)
Integer
goodId
,
@Param
(
"list"
)
List
<
Integer
>
ids
);
}
}
xx-tour/xx-tour-server/src/main/java/com/xxfc/platform/tour/mapper/TourGoodSiteMapper.java
View file @
c3de5602
...
@@ -19,4 +19,7 @@ public interface TourGoodSiteMapper extends Mapper<TourGoodSite> {
...
@@ -19,4 +19,7 @@ public interface TourGoodSiteMapper extends Mapper<TourGoodSite> {
public
List
<
TourDepartVo
>
getlistByGoodId
(
@Param
(
"goodId"
)
Integer
goodId
);
public
List
<
TourDepartVo
>
getlistByGoodId
(
@Param
(
"goodId"
)
Integer
goodId
);
//删除站点
public
int
delSite
(
@Param
(
"goodId"
)
Integer
goodId
,
@Param
(
"list"
)
List
<
Integer
>
ids
);
}
}
xx-tour/xx-tour-server/src/main/java/com/xxfc/platform/tour/mapper/TourGoodSpePriceMapper.java
View file @
c3de5602
...
@@ -21,6 +21,9 @@ public interface TourGoodSpePriceMapper extends Mapper<TourGoodSpePrice> {
...
@@ -21,6 +21,9 @@ public interface TourGoodSpePriceMapper extends Mapper<TourGoodSpePrice> {
//减库存
//减库存
int
updStockById
(
@Param
(
"id"
)
Integer
id
,
@Param
(
"number"
)
Integer
number
);
int
updStockById
(
@Param
(
"id"
)
Integer
id
,
@Param
(
"number"
)
Integer
number
);
//删除站点
public
int
delSpe
(
@Param
(
"goodId"
)
Integer
goodId
,
@Param
(
"list"
)
List
<
Integer
>
ids
);
}
}
xx-tour/xx-tour-server/src/main/java/com/xxfc/platform/tour/mapper/TourGoodTagMapper.java
View file @
c3de5602
...
@@ -20,6 +20,9 @@ public interface TourGoodTagMapper extends Mapper<TourGoodTag> {
...
@@ -20,6 +20,9 @@ public interface TourGoodTagMapper extends Mapper<TourGoodTag> {
//查询旅游标签
//查询旅游标签
public
List
<
GoodTagDTO
>
getGoodTagList
(
@Param
(
"goodId"
)
Integer
goodId
);
public
List
<
GoodTagDTO
>
getGoodTagList
(
@Param
(
"goodId"
)
Integer
goodId
);
//删除站点
public
int
delTag
(
@Param
(
"goodId"
)
Integer
goodId
,
@Param
(
"list"
)
List
<
Integer
>
ids
);
}
}
xx-tour/xx-tour-server/src/main/resources/mapper/TourGoodBannerMapper.xml
View file @
c3de5602
...
@@ -20,4 +20,22 @@
...
@@ -20,4 +20,22 @@
select * FROM tour_good_banner where good_id=#{goodId} and is_del=0
select * FROM tour_good_banner where good_id=#{goodId} and is_del=0
</select>
</select>
<update
id=
"delBanner"
>
update tour_good_banner set is_del=1
where 1=1
<if
test=
"goodId !=null and goodId >0 "
>
and good_id=#{goodId}
</if>
<if
test=
"list!=null "
>
and id not in (
<trim
suffixOverrides=
","
>
<foreach
collection=
"list"
item=
"id"
>
#{id},
</foreach>
</trim>
)
</if>
</update>
</mapper>
</mapper>
\ No newline at end of file
xx-tour/xx-tour-server/src/main/resources/mapper/TourGoodSiteMapper.xml
View file @
c3de5602
...
@@ -42,6 +42,22 @@
...
@@ -42,6 +42,22 @@
SELECT * FROM tour_good_site
SELECT * FROM tour_good_site
WHERE good_id=#{goodId} and is_del=0
WHERE good_id=#{goodId} and is_del=0
</select>
</select>
<update
id=
"delSite"
>
update tour_good_site set is_del=1
where 1=1
<if
test=
"goodId !=null and goodId >0 "
>
and good_id=#{goodId}
</if>
<if
test=
"list!=null "
>
and id not in (
<trim
suffixOverrides=
","
>
<foreach
collection=
"list"
item=
"id"
>
#{id},
</foreach>
</trim>
)
</if>
</update>
</mapper>
</mapper>
\ No newline at end of file
xx-tour/xx-tour-server/src/main/resources/mapper/TourGoodSpePriceMapper.xml
View file @
c3de5602
...
@@ -46,6 +46,24 @@
...
@@ -46,6 +46,24 @@
update tour_good_spe_price set stock=stock-#{number} where id=#{id}
update tour_good_spe_price set stock=stock-#{number} where id=#{id}
</update>
</update>
<update
id=
"delSpe"
>
update tour_good_spe_price set is_del=1
where 1=1
<if
test=
"goodId !=null and goodId >0 "
>
and good_id=#{goodId}
</if>
<if
test=
"list!=null "
>
and id not in (
<trim
suffixOverrides=
","
>
<foreach
collection=
"list"
item=
"id"
>
#{id},
</foreach>
</trim>
)
</if>
</update>
</mapper>
</mapper>
\ No newline at end of file
xx-tour/xx-tour-server/src/main/resources/mapper/TourGoodTagMapper.xml
View file @
c3de5602
...
@@ -26,4 +26,22 @@
...
@@ -26,4 +26,22 @@
WHERE g.id=#{goodId} and tag.is_del=0
WHERE g.id=#{goodId} and tag.is_del=0
</select>
</select>
<update
id=
"delTag"
>
update tour_good_tag set is_del=1
where 1=1
<if
test=
"goodId !=null and goodId >0 "
>
and good_id=#{goodId}
</if>
<if
test=
"list!=null "
>
and id not in (
<trim
suffixOverrides=
","
>
<foreach
collection=
"list"
item=
"id"
>
#{id},
</foreach>
</trim>
)
</if>
</update>
</mapper>
</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