Commit 960e6981 authored by libin's avatar libin

旅游核销

parent 56b174e3
......@@ -31,6 +31,9 @@ public class GoodSpePriceDTO {
@JsonFormat(pattern = "yyyy-MM-dd")
private Date endTime;
@ApiModelProperty("商品id")
private Integer goodId;
//规格id
@ApiModelProperty(value = "规格id")
private String speId;
......
......@@ -25,10 +25,10 @@ public class TourGoodSite implements Serializable {
private Integer id;
/**
* 路线id
* 商品id
*/
@Column(name = "good_id")
@ApiModelProperty(value = "路线id")
@ApiModelProperty(value = "商品id")
private Integer goodId;
/**
......
package com.xxfc.platform.tour.biz;
import com.github.wxiaoqi.security.common.vo.PageDataVO;
import com.sun.org.apache.regexp.internal.RE;
import com.xxfc.platform.tour.dto.GoodSiteDTO;
import com.xxfc.platform.tour.dto.GoodSpePriceDTO;
import com.xxfc.platform.tour.entity.TourGood;
import com.xxfc.platform.tour.entity.TourGoodSite;
import com.xxfc.platform.tour.vo.TourGoodOrderFindVo;
import com.xxfc.platform.tour.vo.TourGoodOrderVo;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.xxfc.platform.tour.entity.TourGoodVerification;
import com.xxfc.platform.tour.mapper.TourGoodVerificationMapper;
import com.github.wxiaoqi.security.common.biz.BaseBiz;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;
import java.util.Map;
import java.util.function.Function;
import java.util.stream.Collectors;
/**
* 旅游线路核销明细
......@@ -16,6 +31,16 @@ import java.util.List;
@Service
public class TourGoodVerificationBiz extends BaseBiz<TourGoodVerificationMapper,TourGoodVerification> {
@Autowired
private TourGoodSiteBiz tourGoodSiteBiz;
@Autowired
private TourGoodBiz tourGoodBiz;
@Autowired
private TourGoodSpeBiz tourGoodSpeBiz;
//删除线路核销
public void delGoodVerification(List<Integer> ids){ mapper.delVerification(ids);}
......@@ -29,5 +54,37 @@ public class TourGoodVerificationBiz extends BaseBiz<TourGoodVerificationMapper,
}
}
/**
* 分页查询订单列表
* @param tourGoodOrderFindVo
* @return
*/
public PageDataVO<TourGoodOrderVo> findTourGoodOrdersPage(TourGoodOrderFindVo tourGoodOrderFindVo) {
return null;
}
/**
* 更改发车状态
* @param goodId
* @param speId
* @param siteId
* @return
*/
public int updateTourGoodVerificationStatus(Integer goodId,Integer speId,Integer siteId){
return mapper.updateStatusByGoodIdAndSpeIdAndSiteId(goodId,speId,siteId,0);
}
/**
* 更新总人数 或 上车人数
* @param goodId
* @param speId
* @param siteId
* @param fileName
* @return
*/
public int updateTourGoodPersonNum(Integer goodId,Integer speId,Integer siteId ,String fileName){
return mapper.updateTourGoodPerNumbs(goodId,speId,siteId,fileName);
}
}
\ No newline at end of file
......@@ -4,6 +4,7 @@ package com.xxfc.platform.tour.mapper;
import com.xxfc.platform.tour.entity.TourGoodVerification;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Update;
import tk.mybatis.mapper.common.Mapper;
import java.util.List;
......@@ -28,4 +29,25 @@ public interface TourGoodVerificationMapper extends Mapper<TourGoodVerification>
*/
@Insert("insert into tour_good_verification(`spe_id`,`site_id`,`good_id`)values(#{speId} ,#{siteId} ,#{goodId}) where `spe_id`<>#{spId} and `site_id`<>#{siteId} and `good_id`<>#{goodId}")
int insertTourGoodVerification(TourGoodVerification tourGoodVerification);
/**
* 更新总人数 或 上车人数
* @param goodId
* @param speId
* @param siteId
* @param fileName
* @return
*/
@Update("update tour_good_verification set ${fileName}=${fileName}+1 where `good_id`=#{goodId} and `spe_id`=#{speId} and `site_id`=#{siteId}")
int updateTourGoodPerNumbs(@Param("goodId") Integer goodId, @Param("speId") Integer speId, @Param("siteId") Integer siteId,@Param("fileName") String fileName);
/**
* 更新出发状态
* @param goodId
* @param speId
* @param siteId
* @return
*/
@Update("update tour_good_verification set `status`=#{status} where where `good_id`=#{goodId} and `spe_id`=#{speId} and `site_id`=#{siteId}")
int updateStatusByGoodIdAndSpeIdAndSiteId(@Param("goodId") Integer goodId, @Param("speId") Integer speId, @Param("siteId") Integer siteId,@Param("status") Integer status);
}
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