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

Commit fe91f59c authored by wangyifan's avatar wangyifan

admin数据看板-admin数据修改

parent 70fa914e
......@@ -10,6 +10,8 @@ import com.liquidnet.client.admin.common.enums.BusinessType;
import com.liquidnet.client.admin.common.utils.poi.ExcelUtil;
import com.liquidnet.client.admin.zhengzai.kylin.dto.KylinPerformanceSubscribeTicketStatisticalExportDao;
import com.liquidnet.client.admin.zhengzai.kylin.dto.PerformanceOrderStatisCountResp;
import com.liquidnet.client.admin.zhengzai.kylin.dto.PerformanceTicketSalesDto;
import com.liquidnet.client.admin.zhengzai.kylin.service.IOpenDataService;
import com.liquidnet.commons.lang.util.JsonUtils;
import com.liquidnet.service.base.ResponseDto;
import com.liquidnet.service.kylin.dao.PerformanceAdminListDao;
......@@ -52,6 +54,8 @@ public class KylinPerformancesController extends BaseController {
@Autowired
private DamaiService damaiService;
@Autowired
private IOpenDataService openDataService;
//@RequiresPermissions("kylin:performances:view")
@GetMapping()
......@@ -145,12 +149,47 @@ public class KylinPerformancesController extends BaseController {
//@RequiresPermissions("kylin:performances:view")
@GetMapping(value = "/performanceStatic/{performancesId}")
public String performanceStatic(@PathVariable("performancesId") String performancesId, ModelMap mmap) {
PerformanceOrderStatisCountResp perCountResp = new PerformanceOrderStatisCountResp();
List<PerformanceOrderStatisticalDao> result = new ArrayList<>();
PerformanceTicketSalesDto ticketSalesInfo = openDataService.getPerformanceTicketSalesInfo(performancesId);
if (ticketSalesInfo != null) {
perCountResp.setPerformanceTitle(ticketSalesInfo.getPerformanceTitle());
perCountResp.setTotalSalePrice(new BigDecimal(ticketSalesInfo.getFullSalesAmountTotal()));
perCountResp.setSaleGeneral(new BigDecimal(ticketSalesInfo.getFullAudienceTicketTotal()));
perCountResp.setTotalGeneral(new BigDecimal(ticketSalesInfo.getFullTotalGeneral()));
perCountResp.setTotalRefundGeneral(new BigDecimal(ticketSalesInfo.getFullRefundTicketTotal()));
perCountResp.setTotalBuyUsers(new BigDecimal(ticketSalesInfo.getFullBuyTotal()));
List<PerformanceTicketSalesDto.TicketSales> fullTicketDataList = ticketSalesInfo.getFullTicketDataList();
if (!fullTicketDataList.isEmpty()) {
for (PerformanceTicketSalesDto.TicketSales ticketSales : fullTicketDataList) {
PerformanceOrderStatisticalDao dao = new PerformanceOrderStatisticalDao();
dao.setPerformancesId(ticketSalesInfo.getPerformanceId());
dao.setTicketsId(ticketSales.getTicketId());
dao.setTitle(ticketSales.getTicketTitle());
dao.setPrice(new BigDecimal(ticketSales.getTicketPrice()));
dao.setType(ticketSales.getTicketType());
dao.setTotalGeneral(new BigDecimal(ticketSales.getTotalGeneral()));
dao.setSaleGeneral(new BigDecimal(ticketSales.getAudienceTicketTotal()));
dao.setTotalRefundGeneral(new BigDecimal(ticketSales.getRefundTicketTotal()));
dao.setTotalPayingNumber(new BigDecimal(ticketSales.getPayingTotal()));
dao.setTimeId(ticketSales.getTimeId());
dao.setTimeTitle(ticketSales.getTimeTitle());
dao.setVipBuyTotal(ticketSales.getVipBuyTotal());
dao.setFullRefundTicketTotal(ticketSales.getFullRefundTicketTotal());
dao.setHandlingFeeRefundTicketTotal(ticketSales.getHandlingFeeRefundTicketTotal());
dao.setRefundFeeRevenueTotal(new BigDecimal(ticketSales.getRefundFeeRevenueTotal()));
dao.setAudienceSalesAmountTotal(new BigDecimal(ticketSales.getAudienceSalesAmountTotal()));
result.add(dao);
}
}
}else {
//获取演出详情
KylinPerformanceMisVo performanceMisVo = kylinPerformancesService.performanceDetails(performancesId);
List<PerformanceOrderStatisticalDao> result = kylinPerformancesService.getPerformanceOrderStatisticalList(performancesId);
//构造top统计数据
PerformanceOrderStatisCountResp perCountResp = new PerformanceOrderStatisCountResp();
result = kylinPerformancesService.getPerformanceOrderStatisticalList(performancesId);
perCountResp.setPerformanceTitle(performanceMisVo.getTitle());
if (result.size() >= 2) {
PerformanceOrderStatisticalDao resdao = result.get(result.size() - 1);
......@@ -163,6 +202,7 @@ public class KylinPerformancesController extends BaseController {
perCountResp.setTotalDisPrice(BigDecimal.ONE);
perCountResp.setTotalRefundGeneral(resdao.getTotalRefundGeneral());
}
}
mmap.put("perCountResp", perCountResp);
mmap.put("perOrderStaticList", result);
......
......@@ -53,12 +53,12 @@
<div th:text="*{totalBuyUsers}">39</div>
</div>
</div>
<div class="col-lg-1">
<div>
<div>小家伙分销(元)</div>
<div th:text="*{totalDisPrice}">0</div>
</div>
</div>
<!-- <div class="col-lg-1">-->
<!-- <div>-->
<!-- <div>小家伙分销(元)</div>-->
<!-- <div th:text="*{totalDisPrice}">0</div>-->
<!-- </div>-->
<!-- </div>-->
<div class="col-lg-1">
<div>
<div>退票数量(张)</div>
......@@ -71,65 +71,68 @@
<thead>
<tr>
<th>
<div class="cell">票种名</div>
<div class="cell">场次</div>
</th>
<th>
<div class="cell">单价</div>
<div class="cell">票种类型</div>
</th>
<th>
<div class="cell">类型</div>
<div class="cell">票种名称</div>
</th>
<th>
<div class="cell">适用时间</div>
<div class="cell">票种价格</div>
</th>
<th>
<div class="cell">销售总数量</div>
<div class="cell">库存数量</div>
</th>
<th>
<div class="cell">会员销售数量</div>
<div class="cell">销售数量</div>
</th>
<th>
<div class="cell">库存数量</div>
<div class="cell">登登登VIP购票数量</div>
</th>
<th>
<div class="cell">正在支付数量</div>
</th>
<th>
<div class="cell">退票数量</div>
<div class="cell">退票数量</div>
</th>
<th>
<div class="cell">羊毛券数量</div>
<div class="cell">全额退票数量</div>
</th>
<th>
<div class="cell">销售额(元)</div>
<div class="cell">手续费退票数量</div>
</th>
<th>
<div class="cell">退票手续费收益</div>
</th>
<th>
<div class="cell">票面销售金额</div>
</th>
<!-- <th>-->
<!-- <div class="cell">兑换数量</div>-->
<!-- </th>-->
</tr>
</thead>
<tbody>
<tr th:each="respBean,respBeanStat:${perOrderStaticList}">
<td>
<div class="cell" th:text="${respBean.title}">180元区</div>
<div class="cell" th:text="${respBean.timeTitle}">180元区</div>
</td>
<td>
<div class="cell" th:text="${respBean.price}">180.00</div>
<div class="cell" th:text="${@dict.getLabel('zhengzai_ticket_type',respBean.type)}">0</div>
</td>
<td>
<div class="cell" th:text="${@dict.getLabel('zhengzai_ticket_type',respBean.type)}">0</div>
<div class="cell" th:text="${respBean.price}">0</div>
</td>
<td>
<div class="cell" >[[${respBean.useStart}]] - [[${respBean.useEnd}]]</div>
<div class="cell" th:text="${respBean.totalGeneral}">0</div>
</td>
<td>
<div class="cell" th:text="${respBean.saleGeneral}">0</div>
</td>
<td>
<div class="cell" th:text="${respBean.totalMemberNumber}">0</div>
<div class="cell" th:text="${respBean.vipBuyTotal}">0</div>
</td>
<td>
<div class="cell" th:text="${respBean.surplusGeneral}">0</div>
<div class="cell" th:text="${respBean.totalPayingNumber}">0</div>
</td>
<td>
<div class="cell" th:text="${respBean.totalPayingNumber}">0</div>
......@@ -138,10 +141,16 @@
<div class="cell" th:text="${respBean.totalRefundGeneral}">0</div>
</td>
<td>
<div class="cell" th:text="${respBean.totalVoucherCount}">0</div>
<div class="cell" th:text="${respBean.fullRefundTicketTotal}">0</div>
</td>
<td>
<div class="cell" th:text="${respBean.handlingFeeRefundTicketTotal}">0</div>
</td>
<td>
<div class="cell" th:text="${respBean.refundFeeRevenueTotal}">0</div>
</td>
<td>
<div class="cell" th:text="${respBean.totalSalePrice}">0</div>
<div class="cell" th:text="${respBean.audienceSalesAmountTotal}">0</div>
</td>
<!-- <td>-->
<!-- <div class="cell" th:text="${respBean.totalExchange}">0</div>-->
......
......@@ -8,25 +8,39 @@ import java.util.List;
public class PerformanceTicketSalesDto {
/**
* 总销售票款(元)
* 演出ID
*/
private String performanceId;
/**
* 演出名称
*/
private String performanceTitle;
/**
* 总销售票款(元)
*/
private String fullSalesAmountTotal;
/**
* 观众购票数
*/
private Integer fullAudienceTicketTotal;
private String fullAudienceTicketTotal;
/**
* 总库存
*/
private Integer fullTotalGeneral;
private String fullTotalGeneral;
/**
* 退票数量(张)
*/
private Integer fullRefundTicketTotal;
private String fullRefundTicketTotal;
/**
* 购买人数
*/
private String fullBuyTotal;
/**
* 票种销售数据
......@@ -57,29 +71,29 @@ public class PerformanceTicketSalesDto {
// 退票手续费总收益
private String refundFeeRevenueTotal;
// 观众购票总数[销售总票量-兑换码票总数]
// 观众购票总数[销售总票量-兑换码票总数] 销售数量
private String audienceTicketTotal;
// 观众购票销售总金额[票种金额* 观众购票总数]
// 观众购票销售总金额[票种金额* 观众购票总数] 票面销售金额
private String audienceSalesAmountTotal;
// 全额退票总数
private String fullRefundTicketTotal;
private Integer fullRefundTicketTotal;
// 手续费退票总数
private String handlingFeeRefundTicketTotal;
private Integer handlingFeeRefundTicketTotal;
// 退票总数量
private String refundTicketTotal;
// 票种类型 1:单日票 2:通票
private String ticketType;
private Integer ticketType;
// 库存数量
private String totalGeneral;
// 登登登VIP购买数量
private String vipBuyTotal;
private Integer vipBuyTotal;
// 正在支付数量
private String payingTotal;
......
......@@ -3,7 +3,6 @@ package com.liquidnet.service.kylin.dao;
import lombok.Data;
import java.math.BigDecimal;
import java.time.LocalDateTime;
/**
* @author AnJiabin <anjiabin@zhengzai.tv>
......@@ -18,23 +17,46 @@ import java.time.LocalDateTime;
public class PerformanceOrderStatisticalDao implements Cloneable{
private String performancesId;
private String ticketsId;
private String title;
private BigDecimal price;
private Integer type;
private String title;// 票种名称
private BigDecimal price;// 票种价格
private Integer type;// 票种类型
private String useStart;
private String useEnd;
private BigDecimal totalGeneral = BigDecimal.ZERO;
private BigDecimal saleGeneral = BigDecimal.ZERO;
private BigDecimal totalGeneral = BigDecimal.ZERO;// 库存数量
private BigDecimal saleGeneral = BigDecimal.ZERO;// 销售数量
private BigDecimal surplusGeneral = BigDecimal.ZERO;
private BigDecimal totalSalePrice = BigDecimal.ZERO;
private BigDecimal totalExchange = BigDecimal.ZERO;
private BigDecimal totalRefundGeneral = BigDecimal.ZERO;
private BigDecimal totalRefundGeneral = BigDecimal.ZERO; // 退票总数量
private BigDecimal totalRefundPrice = BigDecimal.ZERO;
private BigDecimal totalMemberNumber = BigDecimal.ZERO;
private BigDecimal totalPayingNumber = BigDecimal.ZERO;
private BigDecimal totalPayingNumber = BigDecimal.ZERO;// 正在支付数量
private BigDecimal totalBuyUsers = BigDecimal.ZERO;
private BigDecimal totalVoucherCount = BigDecimal.ZERO;
// 场次ID
private String timeId;
// 场次名称
private String timeTitle;
// vip购票数量
private Integer vipBuyTotal = 0;
// 全额退票总数
private Integer fullRefundTicketTotal = 0;
// 手续费退票总数
private Integer handlingFeeRefundTicketTotal = 0;
// 退票手续费总收益
private BigDecimal refundFeeRevenueTotal = BigDecimal.ZERO;
// 票面销售金额
private BigDecimal audienceSalesAmountTotal = BigDecimal.ZERO;
private static final PerformanceOrderStatisticalDao obj = new PerformanceOrderStatisticalDao();
public static PerformanceOrderStatisticalDao getNew() {
try {
......
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