记得上下班打卡 | git大法好,push需谨慎

Commit 8f90bd01 authored by 胡佳晨's avatar 胡佳晨

增加 同步票务平台controller

parent bf4059d3
...@@ -58,6 +58,22 @@ public class KylinPerformancesController extends BaseController { ...@@ -58,6 +58,22 @@ public class KylinPerformancesController extends BaseController {
kylinPerformancesService.test(); kylinPerformancesService.test();
} }
@Log(title = "同步票务平台-演出", businessType = BusinessType.OTHER)
@GetMapping(value = "/syncTicketSysPerformance/{performancesId}")
@ResponseBody
public AjaxResult syncTicketSysPerformance(@PathVariable("performancesId") String performancesId) {
boolean result = kylinPerformancesService.syncTicketSysPerformance(performancesId);
return toAjax(result);
}
@Log(title = "同步票务平台-订单", businessType = BusinessType.OTHER)
@GetMapping(value = "/syncTicketSysOrder/{performancesId}")
@ResponseBody
public AjaxResult syncTicketSysOrder(@PathVariable("performancesId") String performancesId) {
boolean result = kylinPerformancesService.syncTicketSysOrder(performancesId);
return toAjax(result);
}
/** /**
* 查询演出列表 * 查询演出列表
*/ */
......
...@@ -284,7 +284,7 @@ public class InnerService { ...@@ -284,7 +284,7 @@ public class InnerService {
orderVo.setSessionCode(getSessionCode(item.getTimeId())); orderVo.setSessionCode(getSessionCode(item.getTimeId()));
orderVo.setPriceId(getPriceId(item.getTicketId())); orderVo.setPriceId(getPriceId(item.getTicketId()));
orderVo.setTicketPrice((vo.getPrice().subtract(vo.getPriceRefund())).multiply(BigDecimal.valueOf(100)).intValue()); orderVo.setTicketPrice((vo.getPrice().subtract(vo.getPriceRefund())).multiply(BigDecimal.valueOf(100)).intValue());
orderVo.setTicketId(item.getTicketId()); orderVo.setTicketId(item.getOrderTicketEntitiesId());
orderVo.setTicketOrderAmount(orderVo.getTicketPrice() - voucherPrice - refundPrice); orderVo.setTicketOrderAmount(orderVo.getTicketPrice() - voucherPrice - refundPrice);
orderVos.add(orderVo); orderVos.add(orderVo);
} }
......
...@@ -142,7 +142,7 @@ public class KylinPerformancesAdminServiceImpl extends ServiceImpl<KylinPerforma ...@@ -142,7 +142,7 @@ public class KylinPerformancesAdminServiceImpl extends ServiceImpl<KylinPerforma
@Override @Override
public boolean syncTicketSysOrder(String performanceId) { public boolean syncTicketSysOrder(String performanceId) {
//查询演出下需要同步的订单id //查询演出下需要同步的订单id
List<String> orderIds = CollectionUtil.linkedListString(); List<String> orderIds = kylinOrderTicketsMapper.getPayOrderIds(performanceId);
boolean orderResult = true; boolean orderResult = true;
for (String orderId : orderIds) { for (String orderId : orderIds) {
orderResult = innerService.reportO(dataUtils.getOrderTicketVo(orderId), "摩登天空"); orderResult = innerService.reportO(dataUtils.getOrderTicketVo(orderId), "摩登天空");
......
...@@ -39,24 +39,33 @@ public interface KylinOrderTicketsMapper extends BaseMapper<KylinOrderTickets> { ...@@ -39,24 +39,33 @@ public interface KylinOrderTicketsMapper extends BaseMapper<KylinOrderTickets> {
List<OrderExpressExportListDao> selectExpressList(@Param("performanceId") String performanceId); List<OrderExpressExportListDao> selectExpressList(@Param("performanceId") String performanceId);
List<String> getPayOrderIds(@Param("performanceId") String performanceId);
/** /**
* 根据用户id获取 演出订单维度 完成没任务次数 * 根据用户id获取 演出订单维度 完成没任务次数
*
* @param uid * @param uid
* @return * @return
*/ */
Integer getOrderScore(@Param("uid") String uid); Integer getOrderScore(@Param("uid") String uid);
List<Map> getUserOrder(@Param("userId")String userId);
Map getUserCommission(@Param("agentId")String agentId);
List<Map> getUserSellOneDate(@Param("agentId")String agentId,@Param("performanceId")String performanceId);
Map getUserSellAllDate(@Param("agentId")String agentId,@Param("performanceId")String performanceId);
List<Map> getUserSellDetail(@Param("agentId")String agentId,@Param("ticketId")String ticketId);
List<Map> getUserPerformance(@Param("agentId")String userId);
Map getUserPerformanceByUidAndProId(@Param("agentId")String userId,@Param("performanceId")String performanceId); List<Map> getUserOrder(@Param("userId") String userId);
Map getUserCommission(@Param("agentId") String agentId);
List<Map> getUserSellOneDate(@Param("agentId") String agentId, @Param("performanceId") String performanceId);
Map getUserSellAllDate(@Param("agentId") String agentId, @Param("performanceId") String performanceId);
List<Map> getUserSellDetail(@Param("agentId") String agentId, @Param("ticketId") String ticketId);
List<Map> getUserPerformance(@Param("agentId") String userId);
Map getUserPerformanceByUidAndProId(@Param("agentId") String userId, @Param("performanceId") String performanceId);
List<KylinOrderTicketAndAgentVo> selectListByPerformanceId(@Param("performancesId") String performancesId,@Param("ticketId")String ticketId); List<KylinOrderTicketAndAgentVo> selectListByPerformanceId(@Param("performancesId") String performancesId, @Param("ticketId") String ticketId);
List<String> getAgentIdListByPerId(@Param("performancesId") String performancesId); List<String> getAgentIdListByPerId(@Param("performancesId") String performancesId);
Map selectNumAndPrice(@Param("performancesId") String performancesId,@Param("ticketsId") String ticketsId); Map selectNumAndPrice(@Param("performancesId") String performancesId, @Param("ticketsId") String ticketsId);
} }
...@@ -566,4 +566,15 @@ ...@@ -566,4 +566,15 @@
AND kk.performance_id = #{performancesId} AND kk.performance_id = #{performancesId}
AND kk.ticket_id = #{ticketsId} AND kk.ticket_id = #{ticketsId}
</select> </select>
<select id="getPayOrderIds" resultType="String">
SELECT order_tickets_id
FROM kylin_order_tickets kot
INNER JOIN kylin_order_ticket_relations as kotr on kotr.order_id = kot.order_tickets_id
INNER JOIN kylin_order_ticket_status as kots on kots.order_id = kot.order_tickets_id
WHERE kotr.performance_id = #{performanceId}
AND kots.status IN (1, 3, 6)
AND kots.transfer_status in (0, 1, 3, 5);
</select>
</mapper> </mapper>
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