| | |
| | | package com.matrix.system.hive.bean; |
| | | |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import com.matrix.core.anotations.Extend; |
| | | import com.matrix.core.tools.DateUtil; |
| | | import lombok.Data; |
| | | |
| | | import java.io.Serializable; |
| | | import java.math.BigDecimal; |
| | |
| | | * @author wzy |
| | | * @date 2021-01-07 |
| | | **/ |
| | | @Data |
| | | public class SysOrderFlow implements Serializable { |
| | | private static final long serialVersionUID = 7519131902836023680L; |
| | | |
| | |
| | | private Long vipId; |
| | | |
| | | private Long cardId; |
| | | /** |
| | | * 扩展字段-支付卡名称 |
| | | */ |
| | | @Extend |
| | | private String cardName; |
| | | |
| | | private String isGift; |
| | | |
| | |
| | | |
| | | private Long companyId; |
| | | |
| | | public String getOrderNo() { |
| | | return orderNo; |
| | | } |
| | | |
| | | public void setOrderNo(String orderNo) { |
| | | this.orderNo = orderNo; |
| | | } |
| | | |
| | | public Long getCardId() { |
| | | return cardId; |
| | | } |
| | | |
| | | public void setCardId(Long cardId) { |
| | | this.cardId = cardId; |
| | | } |
| | | |
| | | public String getIsGift() { |
| | | return isGift; |
| | | } |
| | | |
| | | public void setIsGift(String isGift) { |
| | | this.isGift = isGift; |
| | | } |
| | | |
| | | public String getCreateBy() { |
| | | return createBy; |
| | | } |
| | | |
| | | public void setCreateBy(String createBy) { |
| | | this.createBy = createBy; |
| | | } |
| | | |
| | | public Date getCreateTime() { |
| | | return createTime; |
| | | } |
| | | |
| | | public void setCreateTime(Date createTime) { |
| | | this.createTime = createTime; |
| | | } |
| | | |
| | | public String getUpdateBy() { |
| | | return updateBy; |
| | | } |
| | | |
| | | public void setUpdateBy(String updateBy) { |
| | | this.updateBy = updateBy; |
| | | } |
| | | |
| | | public Date getUpdateTime() { |
| | | return updateTime; |
| | | } |
| | | |
| | | public void setUpdateTime(Date updateTime) { |
| | | this.updateTime = updateTime; |
| | | } |
| | | |
| | | public Long getId() { |
| | | return id; |
| | | } |
| | | |
| | | public void setId(Long id) { |
| | | this.id = id; |
| | | } |
| | | |
| | | public String getFlowNo() { |
| | | return flowNo; |
| | | } |
| | | |
| | | public void setFlowNo(String flowNo) { |
| | | this.flowNo = flowNo; |
| | | } |
| | | |
| | | public Long getOrderId() { |
| | | return orderId; |
| | | } |
| | | |
| | | public void setOrderId(Long orderId) { |
| | | this.orderId = orderId; |
| | | } |
| | | |
| | | public String getFlowContent() { |
| | | return flowContent; |
| | | } |
| | | |
| | | public void setFlowContent(String flowContent) { |
| | | this.flowContent = flowContent; |
| | | } |
| | | |
| | | public String getFlowType() { |
| | | return flowType; |
| | | } |
| | | |
| | | public void setFlowType(String flowType) { |
| | | this.flowType = flowType; |
| | | } |
| | | |
| | | public BigDecimal getAmount() { |
| | | return amount; |
| | | } |
| | | |
| | | public void setAmount(BigDecimal amount) { |
| | | this.amount = amount; |
| | | } |
| | | |
| | | public String getPayMethod() { |
| | | return payMethod; |
| | | } |
| | | |
| | | public void setPayMethod(String payMethod) { |
| | | this.payMethod = payMethod; |
| | | } |
| | | |
| | | public Long getVipId() { |
| | | return vipId; |
| | | } |
| | | |
| | | public void setVipId(Long vipId) { |
| | | this.vipId = vipId; |
| | | } |
| | | |
| | | public Long getShopId() { |
| | | return shopId; |
| | | } |
| | | |
| | | public void setShopId(Long shopId) { |
| | | this.shopId = shopId; |
| | | } |
| | | |
| | | public Long getCompanyId() { |
| | | return companyId; |
| | | } |
| | | |
| | | public void setCompanyId(Long companyId) { |
| | | this.companyId = companyId; |
| | | } |
| | | } |
| | |
| | | orderSheet.setSheetName("交易流水"); |
| | | orderSheet.setTitle("交易流水"); |
| | | String[] header = new String[]{"订单编号", "交易内容", "交易时间", "交易类型", "交易金额", "会员姓名", |
| | | "支付方式", "支付流水号", "操作人", "门店名称"}; |
| | | "支付方式","储值卡名称", "支付流水号", "操作人", "门店名称"}; |
| | | orderSheet.setHeaders(header); |
| | | List<List<Object>> body = new ArrayList<>(); |
| | | SimpleDateFormat dateFormat = new SimpleDateFormat("yyyy年MM月dd日 HH:mm:ss"); |
| | |
| | | bodyItem.add(flowVo.getAmount()); |
| | | bodyItem.add(flowVo.getVipName()); |
| | | bodyItem.add(flowVo.getPayMethod()); |
| | | bodyItem.add(flowVo.getCardName()); |
| | | bodyItem.add(flowVo.getFlowNo()); |
| | | bodyItem.add(flowVo.getStaffName()); |
| | | bodyItem.add(flowVo.getShopName()); |
| | |
| | | public void exportShowList(@RequestParam Map<String, Object> param, HttpServletResponse response) throws Exception { |
| | | SysUsers sysUsers = (SysUsers) WebUtil.getSession().getAttribute(MatrixConstance.LOGIN_KEY); |
| | | String title = "产品销售明细统计"; |
| | | String[] header = {"门店", "销售日期", "订单号", "商品名称", "分类", "客户名", "购买数量", "单价", "健康顾问", "支付方式", "状态"}; |
| | | String[] column = {"SHOP_NAME", "pay_time", "ORDER_NO", "goodsName", "cateName", "VIP_NAME", "COUNT", "ZK_PRICE", "su_name", "pay_method", "status"}; |
| | | String[] header = {"门店", "销售日期", "订单号", "商品名称", "分类", "客户名", "购买数量", "单价","小计", "健康顾问", "支付方式", "状态"}; |
| | | String[] column = {"SHOP_NAME", "pay_time", "ORDER_NO", "goodsName", "cateName", "VIP_NAME", "COUNT", "ZK_PRICE", "total","su_name", "pay_method", "statu"}; |
| | | |
| | | if(!DataAuthUtil.hasAllShopAuth()){ |
| | | param.put("shopId", sysUsers.getShopId()); |
| | |
| | | |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import com.matrix.core.tools.DateUtil; |
| | | import com.matrix.system.app.vo.OrderDetailItemVo; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import java.math.BigDecimal; |
| | | import java.util.Date; |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * @author jyy |
| | | * @date 2021-01-27 |
| | | **/ |
| | | @Data |
| | | @ApiModel(value = "OrderFlowVo", description = "订单流水返回参数类") |
| | | public class OrderFlowVo { |
| | | |
| | |
| | | @ApiModelProperty(value = "订单号") |
| | | private String orderNo; |
| | | |
| | | @ApiModelProperty(value ="交易类型") |
| | | @ApiModelProperty(value = "交易类型") |
| | | private String flowType; |
| | | |
| | | @ApiModelProperty(value ="支付方式") |
| | | @ApiModelProperty(value = "支付方式") |
| | | private String payMethod; |
| | | |
| | | @ApiModelProperty(value = "会员姓名") |
| | |
| | | @ApiModelProperty(value = "门店名称") |
| | | private String shopName; |
| | | |
| | | @ApiModelProperty(value = "支付卡名称") |
| | | private String cardName; |
| | | |
| | | @JsonFormat(pattern = DateUtil.DATE_FORMAT_SS, timezone = "GMT+8") |
| | | @ApiModelProperty(value = "创建时间") |
| | | private Date createTime; |
| | | |
| | | public Long getId() { |
| | | return id; |
| | | } |
| | | |
| | | public void setId(Long id) { |
| | | this.id = id; |
| | | } |
| | | |
| | | public String getOrderId() { |
| | | return orderId; |
| | | } |
| | | |
| | | public void setOrderId(String orderId) { |
| | | this.orderId = orderId; |
| | | } |
| | | |
| | | public String getOrderNo() { |
| | | return orderNo; |
| | | } |
| | | |
| | | public void setOrderNo(String orderNo) { |
| | | this.orderNo = orderNo; |
| | | } |
| | | |
| | | public String getFlowType() { |
| | | return flowType; |
| | | } |
| | | |
| | | public void setFlowType(String flowType) { |
| | | this.flowType = flowType; |
| | | } |
| | | |
| | | public String getPayMethod() { |
| | | return payMethod; |
| | | } |
| | | |
| | | public void setPayMethod(String payMethod) { |
| | | this.payMethod = payMethod; |
| | | } |
| | | |
| | | public String getVipName() { |
| | | return vipName; |
| | | } |
| | | |
| | | public void setVipName(String vipName) { |
| | | this.vipName = vipName; |
| | | } |
| | | |
| | | public String getFlowContent() { |
| | | return flowContent; |
| | | } |
| | | |
| | | public void setFlowContent(String flowContent) { |
| | | this.flowContent = flowContent; |
| | | } |
| | | |
| | | public BigDecimal getAmount() { |
| | | return amount; |
| | | } |
| | | |
| | | public void setAmount(BigDecimal amount) { |
| | | this.amount = amount; |
| | | } |
| | | |
| | | public String getStaffName() { |
| | | return staffName; |
| | | } |
| | | |
| | | public void setStaffName(String staffName) { |
| | | this.staffName = staffName; |
| | | } |
| | | |
| | | public String getFlowNo() { |
| | | return flowNo; |
| | | } |
| | | |
| | | public void setFlowNo(String flowNo) { |
| | | this.flowNo = flowNo; |
| | | } |
| | | |
| | | public String getShopName() { |
| | | return shopName; |
| | | } |
| | | |
| | | public void setShopName(String shopName) { |
| | | this.shopName = shopName; |
| | | } |
| | | |
| | | public Date getCreateTime() { |
| | | return createTime; |
| | | } |
| | | |
| | | public void setCreateTime(Date createTime) { |
| | | this.createTime = createTime; |
| | | } |
| | | } |
| | | |
| | |
| | | <result property="vipId" column="vip_id" /> |
| | | <result property="payMethod" column="pay_method" /> |
| | | <result property="cardId" column="card_id" /> |
| | | <result property="cardName" column="card_name" /> |
| | | <result property="isGift" column="is_gift" /> |
| | | |
| | | <result property="orderNo" column="order_no" /> |
| | |
| | | </delete> |
| | | |
| | | <select id="selectByOrderId" resultMap="SysOrderFlowMap"> |
| | | select a.*, b.order_no from sys_order_flow a |
| | | select a.*, b.order_no,c.card_name from sys_order_flow a |
| | | left join sys_order b on a.order_id=b.id |
| | | left join money_card_use c on a.card_id=c.id |
| | | where order_id=#{orderId} |
| | | </select> |
| | | |
| | |
| | | a.pay_method as payMethod, |
| | | a.flow_no as flowNo, |
| | | d.shop_short_name as shopName, |
| | | f.card_name as cardName, |
| | | e.su_name as staffName |
| | | from sys_order_flow a |
| | | LEFT JOIN sys_order b on a.order_id=b.ID |
| | | LEFT JOIN sys_vip_info c on a.vip_id=c.ID |
| | | LEFT JOIN sys_shop_info d on a.shop_id=d.ID |
| | | LEFT JOIN sys_users e on e.su_id=b.STAFF_ID |
| | | left join money_card_use f on a.card_id=f.id |
| | | |
| | | <where> |
| | | |
| | | and a.company_id=#{record.companyId} |
| | |
| | | c.name as goodsName, |
| | | g.name as cateName, |
| | | a.COUNT, |
| | | a.COUNT * a.ZK_PRICE as total, |
| | | a.refundCount, |
| | | a.ZK_PRICE, |
| | | a.IS_FREE, |
| | | a.pay_method, |
| | | a.status |
| | | b.statu |
| | | from sys_order_item a |
| | | left join sys_order b on a.ORDER_ID=b.ID |
| | | left join shopping_goods c on a.goods_id=c.id |
| | |
| | | <if test="guwenId != null and guwenId != '' "> |
| | | and b.STAFF_ID=#{guwenId} |
| | | </if> |
| | | <if test="status != null and status != '' "> |
| | | and a.status=#{status} |
| | | <if test="statu != null and statu != '' "> |
| | | and b.statu=#{statu} |
| | | </if> |
| | | |
| | | </where> |
| | |
| | | <if test="guwenId != null and guwenId != '' "> |
| | | and b.STAFF_ID=#{guwenId} |
| | | </if> |
| | | <if test="status != null and status != '' "> |
| | | and a.status=#{status} |
| | | <if test="statu != null and statu != '' "> |
| | | and b.statu=#{statu} |
| | | </if> |
| | | </where> |
| | | </select> |
| | |
| | | label="支付方式"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | prop="cardName" |
| | | label="储值卡名称"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | prop="flowNo" |
| | | label="流水号"> |
| | | </el-table-column> |
| | |
| | | label="支付方式"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | prop="cardName" |
| | | sortable="custom" |
| | | label="储值卡名称"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | prop="flowNo" |
| | | label="支付流水号"> |
| | | </el-table-column> |
| | |
| | | </div> |
| | | <div class="form-group mr-20"> |
| | | <label >订单状态</label> |
| | | <select class="form-control " name="status" > |
| | | <select class="form-control " name="statu" > |
| | | <option value=''>--请选择订单状态--</option> |
| | | <option value='欠款'>欠款</option> |
| | | <option value='待付款'>待付款</option> |
| | |
| | | <th data-field="VIP_NAME" >客户名</th> |
| | | <th data-field="COUNT" data-sortable="true" >购买数量</th> |
| | | <th data-field="ZK_PRICE" data-sortable="true" >单价</th> |
| | | <th data-field="total" >小计</th> |
| | | <th data-field="su_name" >健康顾问</th> |
| | | <th data-field="pay_method" >支付方式</th> |
| | | <th data-field="status" >状态</th> |
| | | <th data-field="statu" >状态</th> |
| | | </tr> |
| | | </thead> |
| | | </table> |
| | |
| | | label="支付方式"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | prop="cardName" |
| | | label="储值卡名称"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | prop="flowNo" |
| | | label="流水号"> |
| | | </el-table-column> |
| | |
| | | label="支付方式"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | prop="cardName" |
| | | sortable="custom" |
| | | label="储值卡名称"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | prop="flowNo" |
| | | label="支付流水号"> |
| | | </el-table-column> |
| | |
| | | </div> |
| | | <div class="form-group mr-20"> |
| | | <label >订单状态</label> |
| | | <select class="form-control " name="status" > |
| | | <select class="form-control " name="statu" > |
| | | <option value=''>--请选择订单状态--</option> |
| | | <option value='欠款'>欠款</option> |
| | | <option value='待付款'>待付款</option> |
| | |
| | | <th data-field="VIP_NAME" >客户名</th> |
| | | <th data-field="COUNT" data-sortable="true" >购买数量</th> |
| | | <th data-field="ZK_PRICE" data-sortable="true" >单价</th> |
| | | <th data-field="total" >小计</th> |
| | | <th data-field="su_name" >健康顾问</th> |
| | | <th data-field="pay_method" >支付方式</th> |
| | | <th data-field="status" >状态</th> |
| | | <th data-field="statu" >状态</th> |
| | | </tr> |
| | | </thead> |
| | | </table> |