This commit is contained in:
cjw 2024-08-24 15:59:06 +08:00
parent 7d83a1516e
commit d2d2ea166e
2 changed files with 18 additions and 18 deletions

View File

@ -1,15 +1,16 @@
package org.dromara.scale.domain.vo;
import com.alibaba.excel.annotation.ExcelIgnoreUnannotated;
import com.alibaba.excel.annotation.ExcelProperty;
import io.github.linpeilie.annotations.AutoMapper;
import io.github.linpeilie.annotations.AutoMapping;
import lombok.Data;
import org.dromara.common.translation.annotation.Translation;
import org.dromara.common.translation.constant.TransConstant;
import org.dromara.scale.domain.ReservationOrder;
import java.io.Serial;
import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;
/**
@ -19,7 +20,6 @@ import java.math.BigDecimal;
* @date 2024-08-22
*/
@Data
@ExcelIgnoreUnannotated
@AutoMapper(target = ReservationOrder.class)
public class ReservationOrderVo implements Serializable {
@ -29,56 +29,56 @@ public class ReservationOrderVo implements Serializable {
/**
*
*/
@ExcelProperty(value = "")
private Long id;
/**
* 预约时间id
*/
@ExcelProperty(value = "预约时间id")
private Long timeId;
/**
* 咨询师id
*/
@ExcelProperty(value = "咨询师id")
private Long counselorId;
@Translation(type = TransConstant.USER_ID_TO_NICKNAME)
@AutoMapping(target = "counselorId")
private Long counselorName;
/**
* 订单价格
*/
@ExcelProperty(value = "订单价格")
private BigDecimal orderPrice;
/**
* 实付价格
*/
@ExcelProperty(value = "实付价格")
private BigDecimal actualPrice;
/**
* 0现金, 1扫码付款,2 公众号支付,3 h5支付,4 当面付,5 小程序支付
* 0 现金,1 扫码付款,2 公众号支付,3 h5支付,4 当面付,5 小程序支付
*/
@ExcelProperty(value = "0现金, 1扫码付款,2 公众号支付,3 h5支付,4 当面付,5 小程序支付")
private Integer payWay;
/**
* 0未支付1:支付完成2:待评分3:已评分99已退款
*/
@ExcelProperty(value = "0未支付1:支付完成2:待评分3:已评分99已退款")
private Integer orderStatus;
/**
* 诊断
*/
@ExcelProperty(value = "诊断")
private String diagnose;
/**
* 附件
*/
@ExcelProperty(value = "附件")
private Long annex;
@Translation(type = TransConstant.OSS_ID_TO_URL)
@AutoMapping(target = "annex")
private Long annexUrl;
private Date createTime;
}

View File

@ -53,19 +53,19 @@ public class MyServiceImpl implements IMyService {
List<StatisticNumVo> list = new ArrayList<>();
Long userId = LoginHelper.getUserId();
Long recoreNum = evaluationRecordMapper.selectCount(new LambdaQueryWrapper<SysEvaluationRecord>()
Long recordNum = evaluationRecordMapper.selectCount(new LambdaQueryWrapper<SysEvaluationRecord>()
.eq(SysEvaluationRecord::getUserId, userId)
.eq(SysEvaluationRecord::getPublishFlag, 0)
.le(SysEvaluationRecord::getStatus, StatusEnum.DISABLED.getValue()));
list.add(new StatisticNumVo("evaluation", recoreNum.intValue()));
list.add(new StatisticNumVo("evaluation", recordNum.intValue()));
List<String> scaleList = evaluationRecordMapper.selectEvaluationScaleList(userId);
list.add(new StatisticNumVo("scale", scaleList.size()));
Long ordernum = reservationOrderMapper.selectCount(new LambdaQueryWrapper<ReservationOrder>()
Long orderNum = reservationOrderMapper.selectCount(new LambdaQueryWrapper<ReservationOrder>()
.eq(ReservationOrder::getCreateBy, userId)
.eq(ReservationOrder::getOrderStatus, 2));
list.add(new StatisticNumVo("intervene", ordernum.intValue()));
list.add(new StatisticNumVo("intervene", orderNum.intValue()));
return list;
}