Merge branch 'feature/mall_product' of http://117.33.142.185:3000/zenghuapei/cyywl_server into feature/mall_product
|
@ -22,7 +22,8 @@ public class RechargeOrderPageReqVO extends PageParam {
|
||||||
|
|
||||||
@Schema(description = "租户id")
|
@Schema(description = "租户id")
|
||||||
private Long tenantId;
|
private Long tenantId;
|
||||||
|
@Schema(description = "商铺名称")
|
||||||
|
private String tenantName;
|
||||||
@Schema(description = "用户id", example = "28969")
|
@Schema(description = "用户id", example = "28969")
|
||||||
private Long uid;
|
private Long uid;
|
||||||
|
|
||||||
|
|
|
@ -1,7 +1,10 @@
|
||||||
package cn.iocoder.yudao.module.shop.controller.admin.recharge.vo;
|
package cn.iocoder.yudao.module.shop.controller.admin.recharge.vo;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||||
import io.swagger.v3.oas.annotations.media.Schema;
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
import lombok.*;
|
import lombok.*;
|
||||||
|
import org.springframework.format.annotation.DateTimeFormat;
|
||||||
|
|
||||||
import java.time.LocalDateTime;
|
import java.time.LocalDateTime;
|
||||||
|
|
||||||
@Schema(description = "管理后台 - 订单 Response VO")
|
@Schema(description = "管理后台 - 订单 Response VO")
|
||||||
|
@ -16,9 +19,14 @@ public class RechargeOrderRespVO extends RechargeOrderBaseVO {
|
||||||
@Schema(description = "创建时间")
|
@Schema(description = "创建时间")
|
||||||
private LocalDateTime createTime;
|
private LocalDateTime createTime;
|
||||||
@Schema(description = "创建时间")
|
@Schema(description = "创建时间")
|
||||||
private String stringCreateTime;
|
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||||
|
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||||
|
private LocalDateTime stringCreateTime;
|
||||||
@Schema(description = "档次")
|
@Schema(description = "档次")
|
||||||
private String grade;
|
private String grade;
|
||||||
|
|
||||||
|
@Schema(description = "商铺名称")
|
||||||
|
private String tenantName;
|
||||||
@Schema(description = "组织名称")
|
@Schema(description = "组织名称")
|
||||||
private String parentOrganizationName;
|
private String parentOrganizationName;
|
||||||
@Schema(description = "推广员名称")
|
@Schema(description = "推广员名称")
|
||||||
|
|
|
@ -161,8 +161,7 @@ public class RechargeOrderServiceImpl implements RechargeOrderService {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
orderDO.setGrade(grade.toString());
|
orderDO.setGrade(grade.toString());
|
||||||
DateTimeFormatter formatter = DateTimeFormatter.ofPattern("yyyy-MM-dd");
|
orderDO.setStringCreateTime(orderDO.getCreateTime());
|
||||||
orderDO.setStringCreateTime(orderDO.getCreateTime().format(formatter));
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return rechargeOrderRespVOS;
|
return rechargeOrderRespVOS;
|
||||||
|
@ -191,8 +190,7 @@ public class RechargeOrderServiceImpl implements RechargeOrderService {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
orderDO.setGrade(grade.toString());
|
orderDO.setGrade(grade.toString());
|
||||||
DateTimeFormatter formatter = DateTimeFormatter.ofPattern("yyyy-MM-dd");
|
orderDO.setStringCreateTime(orderDO.getCreateTime());
|
||||||
orderDO.setStringCreateTime(orderDO.getCreateTime().format(formatter));
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return new PageResult<>(page.getRecords(), page.getTotal());
|
return new PageResult<>(page.getRecords(), page.getTotal());
|
||||||
|
@ -277,8 +275,7 @@ public class RechargeOrderServiceImpl implements RechargeOrderService {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
orderDO.setGrade(grade.toString());
|
orderDO.setGrade(grade.toString());
|
||||||
DateTimeFormatter formatter = DateTimeFormatter.ofPattern("yyyy-MM-dd");
|
orderDO.setStringCreateTime(orderDO.getCreateTime());
|
||||||
orderDO.setStringCreateTime(orderDO.getCreateTime().format(formatter));
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return rechargeOrderRespVOS;
|
return rechargeOrderRespVOS;
|
||||||
|
|
|
@ -39,6 +39,7 @@
|
||||||
select
|
select
|
||||||
a.order_id,
|
a.order_id,
|
||||||
a.pay_serial_number,
|
a.pay_serial_number,
|
||||||
|
e.name as tenantName,
|
||||||
a.out_trade_no,
|
a.out_trade_no,
|
||||||
a.pay_time,
|
a.pay_time,
|
||||||
b.nickname,
|
b.nickname,
|
||||||
|
@ -54,6 +55,7 @@
|
||||||
from cy_recharge_order a
|
from cy_recharge_order a
|
||||||
left join member_user b on a.promoter_id = b.id
|
left join member_user b on a.promoter_id = b.id
|
||||||
left join system_dept d on d.id = a.dept_id
|
left join system_dept d on d.id = a.dept_id
|
||||||
|
left join system_tenant e on e.id = a.tenant_id
|
||||||
<include refid="baseWhere">
|
<include refid="baseWhere">
|
||||||
</include>
|
</include>
|
||||||
</select>
|
</select>
|
||||||
|
@ -108,6 +110,9 @@
|
||||||
<if test="data.tenantId !=null and data.tenantId!=1">
|
<if test="data.tenantId !=null and data.tenantId!=1">
|
||||||
and a.tenant_id =#{data.tenantId}
|
and a.tenant_id =#{data.tenantId}
|
||||||
</if>
|
</if>
|
||||||
|
<if test="data.tenantName !=null and data.tenantName!=''">
|
||||||
|
and d.name like CONCAT('%',#{data.tenantName},'%')
|
||||||
|
</if>
|
||||||
<if test="data.paySerialNumber !=null and data.paySerialNumber!=''">
|
<if test="data.paySerialNumber !=null and data.paySerialNumber!=''">
|
||||||
and a.pay_serial_number like CONCAT('%',#{data.paySerialNumber},'%')
|
and a.pay_serial_number like CONCAT('%',#{data.paySerialNumber},'%')
|
||||||
</if>
|
</if>
|
||||||
|
|
|
@ -88,7 +88,7 @@ public class DeptController {
|
||||||
|
|
||||||
@Operation(summary = "批量组织架构导入")
|
@Operation(summary = "批量组织架构导入")
|
||||||
@PostMapping(value = "/batch/import", name = "批量组织架构导入")
|
@PostMapping(value = "/batch/import", name = "批量组织架构导入")
|
||||||
public CommonResult<Boolean> batchImport(@RequestParam("file") MultipartFile file) throws IOException {
|
public CommonResult<Boolean> batchImport(@RequestParam("file") MultipartFile file){
|
||||||
deptService.batchImport(file);
|
deptService.batchImport(file);
|
||||||
return success(true);
|
return success(true);
|
||||||
}
|
}
|
||||||
|
|
|
@ -117,5 +117,5 @@ public interface DeptService {
|
||||||
*/
|
*/
|
||||||
void validateDeptList(Collection<Long> ids);
|
void validateDeptList(Collection<Long> ids);
|
||||||
|
|
||||||
void batchImport(MultipartFile file) throws IOException;
|
void batchImport(MultipartFile file);
|
||||||
}
|
}
|
||||||
|
|
|
@ -5,7 +5,6 @@ import cn.iocoder.yudao.framework.common.enums.CommonStatusEnum;
|
||||||
import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils;
|
import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils;
|
||||||
import cn.iocoder.yudao.framework.tenant.core.context.TenantContextHolder;
|
import cn.iocoder.yudao.framework.tenant.core.context.TenantContextHolder;
|
||||||
import cn.iocoder.yudao.framework.tenant.core.util.TenantUtils;
|
import cn.iocoder.yudao.framework.tenant.core.util.TenantUtils;
|
||||||
import cn.iocoder.yudao.module.system.api.dept.dto.DeptRespDTO;
|
|
||||||
import cn.iocoder.yudao.module.system.controller.admin.dept.vo.dept.BatchImportVO;
|
import cn.iocoder.yudao.module.system.controller.admin.dept.vo.dept.BatchImportVO;
|
||||||
import cn.iocoder.yudao.module.system.controller.admin.dept.vo.dept.DeptCreateReqVO;
|
import cn.iocoder.yudao.module.system.controller.admin.dept.vo.dept.DeptCreateReqVO;
|
||||||
import cn.iocoder.yudao.module.system.controller.admin.dept.vo.dept.DeptListReqVO;
|
import cn.iocoder.yudao.module.system.controller.admin.dept.vo.dept.DeptListReqVO;
|
||||||
|
@ -19,7 +18,6 @@ import cn.iocoder.yudao.module.system.util.TransactionalService;
|
||||||
import com.alibaba.excel.EasyExcel;
|
import com.alibaba.excel.EasyExcel;
|
||||||
import com.alibaba.excel.context.AnalysisContext;
|
import com.alibaba.excel.context.AnalysisContext;
|
||||||
import com.alibaba.excel.event.AnalysisEventListener;
|
import com.alibaba.excel.event.AnalysisEventListener;
|
||||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
|
||||||
import com.baomidou.mybatisplus.core.toolkit.IdWorker;
|
import com.baomidou.mybatisplus.core.toolkit.IdWorker;
|
||||||
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
|
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
|
||||||
import com.google.common.collect.ImmutableMap;
|
import com.google.common.collect.ImmutableMap;
|
||||||
|
@ -28,9 +26,8 @@ import com.google.common.collect.Multimap;
|
||||||
import lombok.Getter;
|
import lombok.Getter;
|
||||||
import lombok.extern.slf4j.Slf4j;
|
import lombok.extern.slf4j.Slf4j;
|
||||||
import org.apache.commons.collections4.CollectionUtils;
|
import org.apache.commons.collections4.CollectionUtils;
|
||||||
import org.apache.commons.lang3.StringUtils;
|
|
||||||
import org.springframework.beans.BeanUtils;
|
|
||||||
import org.springframework.stereotype.Service;
|
import org.springframework.stereotype.Service;
|
||||||
|
import org.springframework.transaction.annotation.Transactional;
|
||||||
import org.springframework.validation.annotation.Validated;
|
import org.springframework.validation.annotation.Validated;
|
||||||
import org.springframework.web.multipart.MultipartFile;
|
import org.springframework.web.multipart.MultipartFile;
|
||||||
|
|
||||||
|
@ -325,87 +322,65 @@ public class DeptServiceImpl implements DeptService {
|
||||||
private static List<DeptDO> deptDOS4 = new ArrayList<>();
|
private static List<DeptDO> deptDOS4 = new ArrayList<>();
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void batchImport(MultipartFile file) throws IOException {
|
public void batchImport(MultipartFile file){
|
||||||
List<BatchImportVO> list = ExcelUtils.read(file, BatchImportVO.class);
|
|
||||||
try {
|
try {
|
||||||
EasyExcel.read(file.getInputStream(), BatchImportVO.class, new AnalysisEventListener<BatchImportVO>() {
|
List<BatchImportVO> deptList = ExcelUtils.read(file, BatchImportVO.class);
|
||||||
|
|
||||||
private final List<BatchImportVO> deptList = new ArrayList<>(10000);
|
Map<String, List<BatchImportVO>> collect = deptList.stream().collect(Collectors.groupingBy(BatchImportVO::getHierarchy));
|
||||||
|
List<BatchImportVO> batchImportVOS1 = collect.get("1");
|
||||||
@Override
|
List<BatchImportVO> batchImportVOS2 = collect.get("2");
|
||||||
public void invoke(BatchImportVO o, AnalysisContext analysisContext) {
|
List<BatchImportVO> batchImportVOS3 = collect.get("3");
|
||||||
deptList.add(o);
|
List<BatchImportVO> batchImportVOS4 = collect.get("4");
|
||||||
if (deptList.size() % 15 == 0) {
|
// 装入层级1
|
||||||
batchInsert();
|
BatchImportVO batchImportVO1 = batchImportVOS1.get(0);
|
||||||
deptList.clear();
|
DeptDO deptDO1 = new DeptDO();
|
||||||
}
|
deptDO1.setParentId(0L);
|
||||||
}
|
deptDO1.setName(batchImportVO1.getDepName());
|
||||||
|
deptDO1.setParentOrganizationName(batchImportVO1.getDepName());
|
||||||
@Override
|
deptDO1.setCharacteristic(batchImportVO1.getCharacteristic());
|
||||||
public void doAfterAllAnalysed(AnalysisContext analysisContext) {
|
deptMapper.insert(deptDO1);
|
||||||
if (CollectionUtils.isNotEmpty(deptList)) {
|
deptDO1.setParentOrganizationIds(deptDO1.getId().toString());
|
||||||
batchInsert();
|
deptMapper.update(deptDO1,Wrappers.<DeptDO>lambdaUpdate().eq(DeptDO::getId,deptDO1.getId()));
|
||||||
}
|
// 装入层级2
|
||||||
}
|
for (BatchImportVO batchImportVO : batchImportVOS2) {
|
||||||
|
DeptDO deptDO2 = new DeptDO();
|
||||||
private void batchInsert() {
|
deptDO2.setName(batchImportVO.getDepName());
|
||||||
Map<String, List<BatchImportVO>> collect = deptList.stream().collect(Collectors.groupingBy(BatchImportVO::getHierarchy));
|
deptDO2.setParentId(deptDO1.getId());
|
||||||
List<BatchImportVO> batchImportVOS1 = collect.get("1");
|
deptDO2.setParentOrganizationName(deptDO1.getParentOrganizationName() + "," + batchImportVO.getDepName());
|
||||||
List<BatchImportVO> batchImportVOS2 = collect.get("2");
|
deptDO2.setCharacteristic(batchImportVO.getCharacteristic());
|
||||||
List<BatchImportVO> batchImportVOS3 = collect.get("3");
|
deptMapper.insert(deptDO2);
|
||||||
List<BatchImportVO> batchImportVOS4 = collect.get("4");
|
deptDO2.setParentOrganizationIds(deptDO1.getParentOrganizationIds() + "," + deptDO2.getId());
|
||||||
transactionalService.run(() -> {
|
deptMapper.update(deptDO2,Wrappers.<DeptDO>lambdaUpdate().eq(DeptDO::getId,deptDO2.getId()));
|
||||||
// 装入层级1
|
deptDOS2.add(deptDO2);
|
||||||
BatchImportVO batchImportVO1 = batchImportVOS1.get(0);
|
}
|
||||||
DeptDO deptDO1 = new DeptDO();
|
// 装入层级3
|
||||||
deptDO1.setParentId(0L);
|
for (BatchImportVO batchImportVO : batchImportVOS3) {
|
||||||
deptDO1.setName(batchImportVO1.getDepName());
|
DeptDO deptDO3 = new DeptDO();
|
||||||
deptDO1.setParentOrganizationName(batchImportVO1.getDepName());
|
deptDO3.setName(batchImportVO.getDepName());
|
||||||
deptDO1.setCharacteristic(batchImportVO1.getCharacteristic());
|
List<DeptDO> collect1 = deptDOS2.stream().filter(e -> e.getCharacteristic().equals(batchImportVO.getRelation())).collect(Collectors.toList());
|
||||||
deptMapper.insert(deptDO1);
|
DeptDO deptDO = collect1.get(0);
|
||||||
deptDO1.setParentOrganizationIds(deptDO1.getId().toString());
|
deptDO3.setParentId(deptDO.getId());
|
||||||
deptMapper.updateById(deptDO1);
|
deptDO3.setParentOrganizationName(deptDO.getParentOrganizationName() + "," + batchImportVO.getDepName());
|
||||||
// 装入层级2
|
deptDO3.setCharacteristic(batchImportVO.getCharacteristic());
|
||||||
for (BatchImportVO batchImportVO : batchImportVOS2) {
|
deptMapper.insert(deptDO3);
|
||||||
DeptDO deptDO2 = new DeptDO();
|
deptDO3.setParentOrganizationIds(deptDO.getParentOrganizationIds() + "," + deptDO3.getId());
|
||||||
deptDO2.setName(batchImportVO.getDepName());
|
deptMapper.update(deptDO3,Wrappers.<DeptDO>lambdaUpdate().eq(DeptDO::getId,deptDO3.getId()));
|
||||||
deptDO2.setParentId(deptDO1.getId());
|
deptDOS3.add(deptDO3);
|
||||||
deptDO2.setParentOrganizationName(deptDO1.getName() + "," + batchImportVO.getDepName());
|
}
|
||||||
deptDO2.setCharacteristic(batchImportVO.getCharacteristic());
|
// 装入层级4
|
||||||
deptMapper.insert(deptDO2);
|
for (BatchImportVO batchImportVO : batchImportVOS4) {
|
||||||
deptDO2.setParentOrganizationIds(deptDO1.getId() + "," + deptDO2.getId());
|
DeptDO deptDO4 = new DeptDO();
|
||||||
deptMapper.updateById(deptDO2);
|
deptDO4.setName(batchImportVO.getDepName());
|
||||||
deptDOS2.add(deptDO2);
|
List<DeptDO> collect1 = deptDOS3.stream().filter(e -> e.getCharacteristic().equals(batchImportVO.getRelation())).collect(Collectors.toList());
|
||||||
}
|
DeptDO deptDO = collect1.get(0);
|
||||||
// 装入层级3
|
deptDO4.setParentId(deptDO.getId());
|
||||||
for (BatchImportVO batchImportVO : batchImportVOS3) {
|
deptDO4.setParentOrganizationName(deptDO.getParentOrganizationName() + "," + batchImportVO.getDepName());
|
||||||
DeptDO deptDO3 = new DeptDO();
|
deptMapper.insert(deptDO4);
|
||||||
deptDO3.setName(batchImportVO.getDepName());
|
deptDO4.setParentOrganizationIds(deptDO.getParentOrganizationIds() + "," + deptDO4.getId());
|
||||||
List<DeptDO> collect1 = deptDOS2.stream().filter(e -> e.getCharacteristic().equals(batchImportVO.getCharacteristic())).collect(Collectors.toList());
|
deptMapper.update(deptDO4,Wrappers.<DeptDO>lambdaUpdate().eq(DeptDO::getId,deptDO4.getId()));
|
||||||
DeptDO deptDO = collect1.get(0);
|
deptDOS4.add(deptDO4);
|
||||||
deptDO3.setParentId(deptDO.getId());
|
}
|
||||||
deptDO3.setParentOrganizationName(deptDO.getName() + "," + batchImportVO.getDepName());
|
|
||||||
deptMapper.insert(deptDO3);
|
|
||||||
deptDO3.setParentOrganizationIds(deptDO.getId() + "," + deptDO3.getId());
|
|
||||||
deptMapper.updateById(deptDO3);
|
|
||||||
deptDOS3.add(deptDO3);
|
|
||||||
}
|
|
||||||
// 装入层级4
|
|
||||||
for (BatchImportVO batchImportVO : batchImportVOS4) {
|
|
||||||
DeptDO deptDO4 = new DeptDO();
|
|
||||||
deptDO4.setName(batchImportVO.getDepName());
|
|
||||||
List<DeptDO> collect1 = deptDOS3.stream().filter(e -> e.getCharacteristic().equals(batchImportVO.getCharacteristic())).collect(Collectors.toList());
|
|
||||||
DeptDO deptDO = collect1.get(0);
|
|
||||||
deptDO4.setParentId(deptDO.getId());
|
|
||||||
deptDO4.setParentOrganizationName(deptDO.getName() + "," + batchImportVO.getDepName());
|
|
||||||
deptMapper.insert(deptDO4);
|
|
||||||
deptDO4.setParentOrganizationIds(deptDO.getId() + "," + deptDO4.getId());
|
|
||||||
deptMapper.updateById(deptDO4);
|
|
||||||
deptDOS3.add(deptDO4);
|
|
||||||
}
|
|
||||||
});
|
|
||||||
}
|
|
||||||
}).sheet().headRowNumber(1).doRead();
|
|
||||||
} catch (IOException e) {
|
} catch (IOException e) {
|
||||||
log.error("导入组织架构失败!", e);
|
log.error("导入组织架构失败!", e);
|
||||||
} finally {
|
} finally {
|
||||||
|
|
|
@ -62,3 +62,17 @@ export function memberTopUp(data) {
|
||||||
export function memberApplyRefund(data) {
|
export function memberApplyRefund(data) {
|
||||||
return request.post('api/order/member/memberApplyRefund',data);
|
return request.post('api/order/member/memberApplyRefund',data);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* "获取当前登录账号为推广员的推广会员记录
|
||||||
|
*/
|
||||||
|
export function promoterOrderInfo(data) {
|
||||||
|
return request.post('api/order/member/promoterOrderInfo',data);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* "获取当前登录发展会员数量统计
|
||||||
|
*/
|
||||||
|
export function promoterOrderCount(type) {
|
||||||
|
return request.get(`api/order/member/promoterOrderCount?type=${type}`);
|
||||||
|
}
|
||||||
|
|
|
@ -2,9 +2,9 @@
|
||||||
<view class="box">
|
<view class="box">
|
||||||
<u-navbar autoBack title="发展会员业绩" bgColor="rgba(255,255,255,0)" :placeholder="true" leftIconSize="40"
|
<u-navbar autoBack title="发展会员业绩" bgColor="rgba(255,255,255,0)" :placeholder="true" leftIconSize="40"
|
||||||
leftIconColor="#fff" titleStyle="font-size:35rpx;color:#fff">
|
leftIconColor="#fff" titleStyle="font-size:35rpx;color:#fff">
|
||||||
<view slot="right">
|
<!-- <view slot="right">
|
||||||
<u-icon name="more-dot-fill" color="#fff"></u-icon>
|
<u-icon name="more-dot-fill" color="#fff"></u-icon>
|
||||||
</view>
|
</view> -->
|
||||||
</u-navbar>
|
</u-navbar>
|
||||||
<u-sticky bgColor="#fff">
|
<u-sticky bgColor="#fff">
|
||||||
<u-tabs @change="handleChange" :list="list" itemStyle=" padding-left: 46rpx; padding-right: 46rpx; height: 46px;" lineColor="#DA2E55" lineWidth="48rpx" lineHeight="10rpx" :activeStyle="activeStyle" :inactiveStyle="inactiveStyle"></u-tabs>
|
<u-tabs @change="handleChange" :list="list" itemStyle=" padding-left: 46rpx; padding-right: 46rpx; height: 46px;" lineColor="#DA2E55" lineWidth="48rpx" lineHeight="10rpx" :activeStyle="activeStyle" :inactiveStyle="inactiveStyle"></u-tabs>
|
||||||
|
@ -16,7 +16,7 @@
|
||||||
<image src="../../static/images/money1.png" ></image>
|
<image src="../../static/images/money1.png" ></image>
|
||||||
<text>总计金额</text>
|
<text>总计金额</text>
|
||||||
</view>
|
</view>
|
||||||
<view class="money_right"><text>¥</text>2400</view>
|
<view class="money_right"><text>¥</text>{{orderDetail.totalAmount}}</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="money_statistics">
|
<view class="money_statistics">
|
||||||
<view class="money_left">
|
<view class="money_left">
|
||||||
|
@ -24,7 +24,7 @@
|
||||||
<view class="segmentation" style="background: linear-gradient(0deg, #FFFFFF 0%, #FFE0C5 47%, #FFFFFF 100%);"></view>
|
<view class="segmentation" style="background: linear-gradient(0deg, #FFFFFF 0%, #FFE0C5 47%, #FFFFFF 100%);"></view>
|
||||||
<text>已发展会员个数</text>
|
<text>已发展会员个数</text>
|
||||||
</view>
|
</view>
|
||||||
<view class="money_right" style="color: #FF4800;">10个</view>
|
<view class="money_right" style="color: #FF4800;">{{orderDetail.memberCount}}个</view>
|
||||||
<image class="fillet" src="../../static/images/fillet1.png" ></image>
|
<image class="fillet" src="../../static/images/fillet1.png" ></image>
|
||||||
</view>
|
</view>
|
||||||
<view class="money_statistics">
|
<view class="money_statistics">
|
||||||
|
@ -33,7 +33,7 @@
|
||||||
<view class="segmentation" style="background: linear-gradient(0deg, #FFFFFF 0%, #C8EFFF 47%, #FFFFFF 100%);"></view>
|
<view class="segmentation" style="background: linear-gradient(0deg, #FFFFFF 0%, #C8EFFF 47%, #FFFFFF 100%);"></view>
|
||||||
<text>提成比例</text>
|
<text>提成比例</text>
|
||||||
</view>
|
</view>
|
||||||
<view class="money_right" style="color: #1082FF;">5%</view>
|
<view class="money_right" style="color: #1082FF;">{{orderDetail.memberCommission}}%</view>
|
||||||
<image class="fillet" src="../../static/images/fillet2.png" ></image>
|
<image class="fillet" src="../../static/images/fillet2.png" ></image>
|
||||||
</view>
|
</view>
|
||||||
<view class="money_statistics">
|
<view class="money_statistics">
|
||||||
|
@ -42,7 +42,7 @@
|
||||||
<view class="segmentation" style="background: linear-gradient(0deg, #FFFFFF 0%, #CEF0DA 47%, #FFFFFF 100%);"></view>
|
<view class="segmentation" style="background: linear-gradient(0deg, #FFFFFF 0%, #CEF0DA 47%, #FFFFFF 100%);"></view>
|
||||||
<text>预计提成金额</text>
|
<text>预计提成金额</text>
|
||||||
</view>
|
</view>
|
||||||
<view class="money_right" style="color: #32A84F;">120</view>
|
<view class="money_right" style="color: #32A84F;">{{parseFloat(orderDetail.totalAmount*(parseFloat(orderDetail.memberCommission) / 100))}}</view>
|
||||||
<image class="fillet" src="../../static/images/fillet3.png" ></image>
|
<image class="fillet" src="../../static/images/fillet3.png" ></image>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
@ -51,27 +51,23 @@
|
||||||
流水明细
|
流水明细
|
||||||
</view>
|
</view>
|
||||||
<view class="turnover_list">
|
<view class="turnover_list">
|
||||||
|
<u-list
|
||||||
|
height="500"
|
||||||
|
@scrolltolower="scrolltolower"
|
||||||
|
>
|
||||||
|
<u-list-item
|
||||||
|
v-for="(item, index) in orderData"
|
||||||
|
:key="index"
|
||||||
|
>
|
||||||
<view class="list_item">
|
<view class="list_item">
|
||||||
<view>
|
<view>
|
||||||
<view class="item_radius"></view>
|
<view class="item_radius"></view>
|
||||||
<text>客户1</text>
|
<text>{{item.nickname}}</text>
|
||||||
</view>
|
</view>
|
||||||
<text>¥640.00</text>
|
<text>¥{{item.payPrice}}</text>
|
||||||
</view>
|
|
||||||
<view class="list_item">
|
|
||||||
<view>
|
|
||||||
<view class="item_radius"></view>
|
|
||||||
<text>客户1</text>
|
|
||||||
</view>
|
</view>
|
||||||
<text>¥640.00</text>
|
</u-list-item>
|
||||||
</view>
|
</u-list>
|
||||||
<view class="list_item">
|
|
||||||
<view>
|
|
||||||
<view class="item_radius"></view>
|
|
||||||
<text>客户1</text>
|
|
||||||
</view>
|
|
||||||
<text>¥640.00</text>
|
|
||||||
</view>
|
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
@ -80,11 +76,12 @@
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import {
|
import {
|
||||||
memberGradeInfo
|
promoterOrderInfo,
|
||||||
|
promoterOrderCount
|
||||||
} from '@/api/member.js';
|
} from '@/api/member.js';
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: "member_loding",
|
name: "sale_performance",
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
activeStyle:{
|
activeStyle:{
|
||||||
|
@ -107,7 +104,14 @@
|
||||||
name: '上月'
|
name: '上月'
|
||||||
}, {
|
}, {
|
||||||
name: '累计'
|
name: '累计'
|
||||||
}]
|
}],
|
||||||
|
pageData:{
|
||||||
|
pageNo:1,
|
||||||
|
pageSize:10
|
||||||
|
},
|
||||||
|
orderDetail:{},
|
||||||
|
orderData:[],
|
||||||
|
total:0
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
|
|
||||||
|
@ -116,14 +120,32 @@
|
||||||
uni.showLoading({
|
uni.showLoading({
|
||||||
title: '加载中'
|
title: '加载中'
|
||||||
});
|
});
|
||||||
|
await this.orderCount(0)
|
||||||
|
await this.orderInfo(false)
|
||||||
} finally {
|
} finally {
|
||||||
uni.hideLoading();
|
uni.hideLoading();
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
handleChange(index){
|
async scrolltolower() {
|
||||||
|
if(this.total>this.orderData.length){
|
||||||
|
this.pageData.pageNo++
|
||||||
|
await this.orderInfo(true)
|
||||||
|
}
|
||||||
|
},
|
||||||
|
async orderInfo(bool=true){
|
||||||
|
const res = await promoterOrderInfo(this.pageData)
|
||||||
|
this.orderData = bool? this.orderData.concat(res.data.list):this.orderData = res.data.list
|
||||||
|
this.total = res.data.total
|
||||||
|
},
|
||||||
|
async orderCount(index){
|
||||||
|
const res = await promoterOrderCount(index+1)
|
||||||
|
this.orderDetail = res.data
|
||||||
|
},
|
||||||
|
async handleChange(value){
|
||||||
|
this.pageData.pageNo = 1
|
||||||
|
await this.orderCount(value.index)
|
||||||
|
await this.orderInfo(false)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
Before Width: | Height: | Size: 8.7 KiB After Width: | Height: | Size: 10 KiB |
Before Width: | Height: | Size: 5.3 KiB After Width: | Height: | Size: 6.0 KiB |
Before Width: | Height: | Size: 11 KiB After Width: | Height: | Size: 9.5 KiB |
Before Width: | Height: | Size: 5.5 KiB After Width: | Height: | Size: 5.5 KiB |