Commit cea2377d authored by libin's avatar libin

旅游核销

parent aa48a0e5
...@@ -2,10 +2,13 @@ package com.xxfc.platform.tour.feign; ...@@ -2,10 +2,13 @@ package com.xxfc.platform.tour.feign;
import com.github.wxiaoqi.security.common.msg.ObjectRestResponse; import com.github.wxiaoqi.security.common.msg.ObjectRestResponse;
import com.github.wxiaoqi.security.common.vo.PageDataVO;
import com.xxfc.platform.tour.dto.TourSpePriceDTO; import com.xxfc.platform.tour.dto.TourSpePriceDTO;
import com.xxfc.platform.tour.entity.TourGood; import com.xxfc.platform.tour.entity.TourGood;
import com.xxfc.platform.tour.entity.TourGoodVerification; import com.xxfc.platform.tour.entity.TourGoodVerification;
import com.xxfc.platform.tour.entity.TourUser; import com.xxfc.platform.tour.entity.TourUser;
import com.xxfc.platform.tour.vo.TourGoodOrderFindVo;
import com.xxfc.platform.tour.vo.TourGoodOrderVo;
import com.xxfc.platform.tour.vo.TourSpePriceVo; import com.xxfc.platform.tour.vo.TourSpePriceVo;
import org.springframework.cloud.openfeign.FeignClient; import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.*; import org.springframework.web.bind.annotation.*;
...@@ -46,26 +49,26 @@ public interface TourFeign { ...@@ -46,26 +49,26 @@ public interface TourFeign {
/** /**
* 更新发车状态 * 更新发车状态
* @param goodId * @param verficationId
* @param speId
* @param siteId
* @return * @return
*/ */
@PutMapping("/tourGood/verfication/status") @PutMapping("/tourGood/verfication/status")
ObjectRestResponse<Void> updateTourGoodVerificationStatus(@RequestParam("goodId") Integer goodId, ObjectRestResponse<Void> updateTourGoodVerificationStatus(@RequestParam("verficationId") Integer verficationId);
@RequestParam("speId") Integer speId,
@RequestParam("siteId") Integer siteId);
/** /**
* 更新总人数或上车人数 * 更新总人数或上车人数
* @param goodId * @param verficationId
* @param speId
* @param siteId
* @param properties * @param properties
* @return * @return
*/ */
@PutMapping("/tourGood/verfication/personnums") @PutMapping("/tourGood/verfication/personnums")
ObjectRestResponse<Void> updateTourGoodPersonNum(@RequestParam("goodId") Integer goodId, ObjectRestResponse<Void> updateTourGoodPersonNum(@RequestParam("verficationId") Integer verficationId,String properties);
@RequestParam("speId") Integer speId,
@RequestParam("properties") Integer siteId ,String properties); /**
* 查询订单列表
* @param tourGoodOrderFindVo
* @return
*/
@GetMapping("/orders")
public ObjectRestResponse<PageDataVO<TourGoodOrderVo>> findTourGoodOrders(TourGoodOrderFindVo tourGoodOrderFindVo);
} }
...@@ -66,25 +66,21 @@ public class TourGoodVerificationBiz extends BaseBiz<TourGoodVerificationMapper, ...@@ -66,25 +66,21 @@ public class TourGoodVerificationBiz extends BaseBiz<TourGoodVerificationMapper,
/** /**
* 更改发车状态 * 更改发车状态
* @param goodId * @param verficationId
* @param speId
* @param siteId
* @return * @return
*/ */
public int updateTourGoodVerificationStatus(Integer goodId,Integer speId,Integer siteId){ public int updateTourGoodVerificationStatus(Integer verficationId){
return mapper.updateStatusByGoodIdAndSpeIdAndSiteId(goodId,speId,siteId,0); return mapper.updateStatusByGoodIdAndSpeIdAndSiteId(verficationId,0);
} }
/** /**
* 更新总人数 或 上车人数 * 更新总人数 或 上车人数
* @param goodId * @param verficationId
* @param speId
* @param siteId
* @param properties * @param properties
* @return * @return
*/ */
public int updateTourGoodPersonNum(Integer goodId,Integer speId,Integer siteId ,String properties){ public int updateTourGoodPersonNum(Integer verficationId,String properties){
return mapper.updateTourGoodPerNumbs(goodId,speId,siteId,properties); return mapper.updateTourGoodPerNumbs(verficationId,properties);
} }
} }
\ No newline at end of file
...@@ -32,22 +32,18 @@ public interface TourGoodVerificationMapper extends Mapper<TourGoodVerification> ...@@ -32,22 +32,18 @@ public interface TourGoodVerificationMapper extends Mapper<TourGoodVerification>
/** /**
* 更新总人数 或 上车人数 * 更新总人数 或 上车人数
* @param goodId
* @param speId
* @param siteId
* @param properties * @param properties
* @return * @return
*/ */
@Update("update tour_good_verification set ${properties}=${properties}+1 where `good_id`=#{goodId} and `spe_id`=#{speId} and `site_id`=#{siteId}") @Update("update tour_good_verification set ${properties}=${properties}+1 where `id`=#{verficationId}")
int updateTourGoodPerNumbs(@Param("goodId") Integer goodId, @Param("speId") Integer speId, @Param("siteId") Integer siteId,@Param("fileName") String properties); int updateTourGoodPerNumbs(@Param("verficationId") Integer verficationId,@Param("properties") String properties);
/** /**
* 更新出发状态 * 更新出发状态
* @param goodId * @param status
* @param speId * @param verficationId
* @param siteId
* @return * @return
*/ */
@Update("update tour_good_verification set `status`=#{status} where where `good_id`=#{goodId} and `spe_id`=#{speId} and `site_id`=#{siteId}") @Update("update tour_good_verification set `status`=#{status} where where `id`=#{verficationId}")
int updateStatusByGoodIdAndSpeIdAndSiteId(@Param("goodId") Integer goodId, @Param("speId") Integer speId, @Param("siteId") Integer siteId,@Param("status") Integer status); int updateStatusByGoodIdAndSpeIdAndSiteId(@Param("verficationId") Integer verficationId,@Param("status") Integer status);
} }
...@@ -30,17 +30,13 @@ public class TourGoodVerificationController extends BaseController<TourGoodVerif ...@@ -30,17 +30,13 @@ public class TourGoodVerificationController extends BaseController<TourGoodVerif
/** /**
* 更新发车状态 * 更新发车状态
* @param goodId * @param verficationId
* @param speId
* @param siteId
* @return * @return
*/ */
@PutMapping("/status") @PutMapping("/status")
@ApiOperation("更新发车状态") @ApiOperation("更新发车状态")
public ObjectRestResponse<Void> updateTourGoodVerificationStatus(@RequestParam("goodId") Integer goodId, public ObjectRestResponse<Void> updateTourGoodVerificationStatus(@RequestParam("verficationId") Integer verficationId){
@RequestParam("speId") Integer speId, int effectRows = getBaseBiz().updateTourGoodVerificationStatus(verficationId);
@RequestParam("siteId") Integer siteId){
int effectRows = getBaseBiz().updateTourGoodVerificationStatus(goodId, speId, siteId);
if (effectRows>0){ if (effectRows>0){
return ObjectRestResponse.succ(); return ObjectRestResponse.succ();
} }
...@@ -50,19 +46,15 @@ public class TourGoodVerificationController extends BaseController<TourGoodVerif ...@@ -50,19 +46,15 @@ public class TourGoodVerificationController extends BaseController<TourGoodVerif
/** /**
* 更新总人数或上车人数 * 更新总人数或上车人数
* @param goodId * @param verficationId
* @param speId
* @param siteId
* @param properties * @param properties
* @return * @return
*/ */
@PutMapping("/personnums") @PutMapping("/personnums")
@ApiOperation("更新总人数或上车人数") @ApiOperation("更新总人数或上车人数")
public ObjectRestResponse<Void> updateTourGoodPersonNum(@RequestParam("goodId") Integer goodId, public ObjectRestResponse<Void> updateTourGoodPersonNum(@RequestParam("verficationId") Integer verficationId,String properties){
@RequestParam("speId") Integer speId, int effectRows = getBaseBiz().updateTourGoodPersonNum(verficationId,properties);
@RequestParam("properties") Integer siteId ,String properties){ if (effectRows>0){
int effectRows = getBaseBiz().updateTourGoodPersonNum(goodId, speId, siteId, properties);
if (effectRows>0){
return ObjectRestResponse.succ(); return ObjectRestResponse.succ();
} }
return ObjectRestResponse.createDefaultFail(); return ObjectRestResponse.createDefaultFail();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment