18 changed files with 943 additions and 13 deletions
@ -0,0 +1,147 @@
|
||||
/* |
||||
* Copyright (c) 2018-2028, Chill Zhuang All rights reserved. |
||||
* |
||||
* Redistribution and use in source and binary forms, with or without |
||||
* modification, are permitted provided that the following conditions are met: |
||||
* |
||||
* Redistributions of source code must retain the above copyright notice, |
||||
* this list of conditions and the following disclaimer. |
||||
* Redistributions in binary form must reproduce the above copyright |
||||
* notice, this list of conditions and the following disclaimer in the |
||||
* documentation and/or other materials provided with the distribution. |
||||
* Neither the name of the dreamlu.net developer nor the names of its |
||||
* contributors may be used to endorse or promote products derived from |
||||
* this software without specific prior written permission. |
||||
* Author: Chill 庄骞 (smallchill@163.com) |
||||
*/ |
||||
package com.logpm.distribution.entity; |
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableName; |
||||
import lombok.Data; |
||||
import io.swagger.annotations.ApiModel; |
||||
import io.swagger.annotations.ApiModelProperty; |
||||
import java.util.Date; |
||||
import java.math.BigDecimal; |
||||
import lombok.EqualsAndHashCode; |
||||
import org.springblade.core.tenant.mp.TenantEntity; |
||||
|
||||
/** |
||||
* 配送管理 实体类 |
||||
* |
||||
* @author lmy |
||||
* @since 2023-06-16 |
||||
*/ |
||||
@Data |
||||
@TableName("logpm_distribution_delivery_list") |
||||
@ApiModel(value = "DistributionDeliveryList对象", description = "配送管理") |
||||
@EqualsAndHashCode(callSuper = true) |
||||
public class DistributionDeliveryListEntity extends TenantEntity { |
||||
|
||||
/** |
||||
* 预留1 |
||||
*/ |
||||
@ApiModelProperty(value = "预留1") |
||||
private String reserve1; |
||||
/** |
||||
* 预留2 |
||||
*/ |
||||
@ApiModelProperty(value = "预留2") |
||||
private String reserve2; |
||||
/** |
||||
* 预留3 |
||||
*/ |
||||
@ApiModelProperty(value = "预留3") |
||||
private String reserve3; |
||||
/** |
||||
* 预留4 |
||||
*/ |
||||
@ApiModelProperty(value = "预留4") |
||||
private String reserve4; |
||||
/** |
||||
* 预留5 |
||||
*/ |
||||
@ApiModelProperty(value = "预留5") |
||||
private String reserve5; |
||||
/** |
||||
* 车次 |
||||
*/ |
||||
@ApiModelProperty(value = "车次") |
||||
private String trainNumber; |
||||
/** |
||||
* 仓库 |
||||
*/ |
||||
@ApiModelProperty(value = "仓库") |
||||
private String warehouse; |
||||
/** |
||||
* 配送类型;1-市配,2-商配 |
||||
*/ |
||||
@ApiModelProperty(value = "配送种类;1-市配,2-商配") |
||||
private String type; |
||||
|
||||
/** |
||||
* 配送种类;1-自主配送,2-三方配送 |
||||
*/ |
||||
@ApiModelProperty(value = "配送类型;1-自主配送,2-三方配送") |
||||
private String kind; |
||||
/** |
||||
* 配送车辆 |
||||
*/ |
||||
@ApiModelProperty(value = "配送车辆") |
||||
private String vehicle; |
||||
/** |
||||
* 配送司机 |
||||
*/ |
||||
@ApiModelProperty(value = "配送司机") |
||||
private String driver; |
||||
/** |
||||
* 配送公司;1-货拉拉,2-京东 |
||||
*/ |
||||
@ApiModelProperty(value = "配送公司;1-货拉拉,2-京东") |
||||
private String distributionCompany; |
||||
/** |
||||
* 配送状态;1-配送中,2-已完成 |
||||
*/ |
||||
@ApiModelProperty(value = "配送状态;1-配送中,2-已完成") |
||||
private String state; |
||||
/** |
||||
* 配送客户数 |
||||
*/ |
||||
@ApiModelProperty(value = "配送客户数") |
||||
private Integer customersNumber; |
||||
/** |
||||
* 配送价格 |
||||
*/ |
||||
@ApiModelProperty(value = "配送价格") |
||||
private BigDecimal price; |
||||
/** |
||||
* 增值服务表id |
||||
*/ |
||||
@ApiModelProperty(value = "增值服务表id") |
||||
private Integer addedServicesId; |
||||
/** |
||||
* 订单总数 |
||||
*/ |
||||
@ApiModelProperty(value = "订单总数") |
||||
private Integer orderNumber; |
||||
/** |
||||
* 配送件数 |
||||
*/ |
||||
@ApiModelProperty(value = "配送件数") |
||||
private Integer deliveryNumber; |
||||
/** |
||||
* 扫描件数 |
||||
*/ |
||||
@ApiModelProperty(value = "扫描件数") |
||||
private Integer scannedNumber; |
||||
/** |
||||
* 装卸班组 |
||||
*/ |
||||
@ApiModelProperty(value = "装卸班组") |
||||
private String loadingTeam; |
||||
/** |
||||
* 预约表id |
||||
*/ |
||||
@ApiModelProperty(value = "预约表id") |
||||
private String reservationId; |
||||
|
||||
} |
@ -0,0 +1,50 @@
|
||||
/* |
||||
* Copyright (c) 2018-2028, Chill Zhuang All rights reserved. |
||||
* |
||||
* Redistribution and use in source and binary forms, with or without |
||||
* modification, are permitted provided that the following conditions are met: |
||||
* |
||||
* Redistributions of source code must retain the above copyright notice, |
||||
* this list of conditions and the following disclaimer. |
||||
* Redistributions in binary form must reproduce the above copyright |
||||
* notice, this list of conditions and the following disclaimer in the |
||||
* documentation and/or other materials provided with the distribution. |
||||
* Neither the name of the dreamlu.net developer nor the names of its |
||||
* contributors may be used to endorse or promote products derived from |
||||
* this software without specific prior written permission. |
||||
* Author: Chill 庄骞 (smallchill@163.com) |
||||
*/ |
||||
package com.logpm.distribution.feign; |
||||
|
||||
import org.springblade.common.constant.ModuleNameConstant; |
||||
import org.springblade.core.mp.support.BladePage; |
||||
import com.logpm.distribution.entity.DistributionDeliveryListEntity; |
||||
import org.springframework.cloud.openfeign.FeignClient; |
||||
import org.springframework.web.bind.annotation.GetMapping; |
||||
import org.springframework.web.bind.annotation.RequestParam; |
||||
|
||||
/** |
||||
* 配送管理 Feign接口类 |
||||
* |
||||
* @author lmy |
||||
* @since 2023-06-16 |
||||
*/ |
||||
@FeignClient( |
||||
value = ModuleNameConstant.APPLICATION_DISTRIBUTION_NAME |
||||
) |
||||
public interface IDistributionDeliveryListClient { |
||||
|
||||
String API_PREFIX = "deliveryList/client"; |
||||
String TOP = API_PREFIX + "/top"; |
||||
|
||||
/** |
||||
* 获取配送管理列表 |
||||
* |
||||
* @param current 页号 |
||||
* @param size 页数 |
||||
* @return BladePage |
||||
*/ |
||||
@GetMapping(TOP) |
||||
BladePage<DistributionDeliveryListEntity> top(@RequestParam("current") Integer current, @RequestParam("size") Integer size); |
||||
|
||||
} |
@ -0,0 +1,42 @@
|
||||
/* |
||||
* Copyright (c) 2018-2028, Chill Zhuang All rights reserved. |
||||
* |
||||
* Redistribution and use in source and binary forms, with or without |
||||
* modification, are permitted provided that the following conditions are met: |
||||
* |
||||
* Redistributions of source code must retain the above copyright notice, |
||||
* this list of conditions and the following disclaimer. |
||||
* Redistributions in binary form must reproduce the above copyright |
||||
* notice, this list of conditions and the following disclaimer in the |
||||
* documentation and/or other materials provided with the distribution. |
||||
* Neither the name of the dreamlu.net developer nor the names of its |
||||
* contributors may be used to endorse or promote products derived from |
||||
* this software without specific prior written permission. |
||||
* Author: Chill 庄骞 (smallchill@163.com) |
||||
*/ |
||||
package com.logpm.distribution.vo; |
||||
|
||||
import com.logpm.distribution.entity.DistributionDeliveryListEntity; |
||||
import io.swagger.annotations.ApiModelProperty; |
||||
import org.springblade.core.tool.node.INode; |
||||
import lombok.Data; |
||||
import lombok.EqualsAndHashCode; |
||||
|
||||
/** |
||||
* 配送管理 视图实体类 |
||||
* |
||||
* @author lmy |
||||
* @since 2023-06-16 |
||||
*/ |
||||
@Data |
||||
@EqualsAndHashCode(callSuper = true) |
||||
public class DistributionDeliveryListVO extends DistributionDeliveryListEntity { |
||||
private static final long serialVersionUID = 1L; |
||||
/** |
||||
* 预留4 |
||||
*/ |
||||
@ApiModelProperty(value = "预留4") |
||||
private String reserve4; |
||||
|
||||
|
||||
} |
@ -0,0 +1,154 @@
|
||||
/* |
||||
* Copyright (c) 2018-2028, Chill Zhuang All rights reserved. |
||||
* |
||||
* Redistribution and use in source and binary forms, with or without |
||||
* modification, are permitted provided that the following conditions are met: |
||||
* |
||||
* Redistributions of source code must retain the above copyright notice, |
||||
* this list of conditions and the following disclaimer. |
||||
* Redistributions in binary form must reproduce the above copyright |
||||
* notice, this list of conditions and the following disclaimer in the |
||||
* documentation and/or other materials provided with the distribution. |
||||
* Neither the name of the dreamlu.net developer nor the names of its |
||||
* contributors may be used to endorse or promote products derived from |
||||
* this software without specific prior written permission. |
||||
* Author: Chill 庄骞 (smallchill@163.com) |
||||
*/ |
||||
package com.logpm.distribution.controller; |
||||
|
||||
import cn.hutool.core.util.BooleanUtil; |
||||
import com.logpm.distribution.dto.DistributionDeliveryListDTO; |
||||
import io.swagger.annotations.Api; |
||||
import io.swagger.annotations.ApiOperation; |
||||
import io.swagger.annotations.ApiParam; |
||||
import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport; |
||||
import lombok.AllArgsConstructor; |
||||
import javax.validation.Valid; |
||||
|
||||
import org.springblade.core.secure.BladeUser; |
||||
import org.springblade.core.mp.support.Condition; |
||||
import org.springblade.core.mp.support.Query; |
||||
import org.springblade.core.tool.api.R; |
||||
import org.springblade.core.tool.utils.Func; |
||||
import org.springframework.beans.BeanUtils; |
||||
import org.springframework.web.bind.annotation.*; |
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
||||
import com.baomidou.mybatisplus.core.metadata.IPage; |
||||
import com.logpm.distribution.entity.DistributionDeliveryListEntity; |
||||
import com.logpm.distribution.vo.DistributionDeliveryListVO; |
||||
import com.logpm.distribution.excel.DistributionDeliveryListExcel; |
||||
import com.logpm.distribution.service.IDistributionDeliveryListService; |
||||
import org.springblade.core.boot.ctrl.BladeController; |
||||
import org.springblade.core.tool.utils.DateUtil; |
||||
import org.springblade.core.excel.util.ExcelUtil; |
||||
import org.springblade.core.tool.constant.BladeConstant; |
||||
import springfox.documentation.annotations.ApiIgnore; |
||||
import java.util.Map; |
||||
import java.util.List; |
||||
import javax.servlet.http.HttpServletResponse; |
||||
|
||||
/** |
||||
* 配送管理 控制器 |
||||
* |
||||
* @author lmy |
||||
* @since 2023-06-16 |
||||
*/ |
||||
@RestController |
||||
@AllArgsConstructor |
||||
@RequestMapping("/deliveryList") |
||||
@Api(value = "配送管理", tags = "配送管理接口") |
||||
public class DistributionDeliveryListController extends BladeController { |
||||
|
||||
private final IDistributionDeliveryListService distributionDeliveryListService; |
||||
|
||||
/** |
||||
* 配送管理 详情 |
||||
*/ |
||||
@GetMapping("/detail") |
||||
@ApiOperationSupport(order = 1) |
||||
@ApiOperation(value = "详情", notes = "传入distributionDeliveryList") |
||||
public R<DistributionDeliveryListVO> detail(DistributionDeliveryListDTO distributionDeliveryList) { |
||||
DistributionDeliveryListEntity detail = distributionDeliveryListService.getOne(Condition.getQueryWrapper(distributionDeliveryList)); |
||||
DistributionDeliveryListVO distributionDeliveryListVO = distributionDeliveryListService.getdetailVO(detail); |
||||
return R.data(distributionDeliveryListVO); |
||||
} |
||||
/** |
||||
* 配送管理 分页 |
||||
*/ |
||||
@GetMapping("/list") |
||||
@ApiOperationSupport(order = 2) |
||||
@ApiOperation(value = "分页", notes = "传入distributionDeliveryList") |
||||
public R<IPage<DistributionDeliveryListEntity>> list(@ApiIgnore @RequestParam Map<String, Object> distributionDeliveryList, Query query) { |
||||
IPage<DistributionDeliveryListEntity> pages = distributionDeliveryListService.page(Condition.getPage(query), Condition.getQueryWrapper(distributionDeliveryList, DistributionDeliveryListEntity.class)); |
||||
return R.data(pages); |
||||
} |
||||
|
||||
/** |
||||
* 配送管理 自定义分页 |
||||
*/ |
||||
@GetMapping("/page") |
||||
@ApiOperationSupport(order = 3) |
||||
@ApiOperation(value = "分页", notes = "传入distributionDeliveryList") |
||||
public R<IPage<DistributionDeliveryListVO>> page(DistributionDeliveryListVO distributionDeliveryList, Query query) { |
||||
IPage<DistributionDeliveryListVO> pages = distributionDeliveryListService.selectDistributionDeliveryListPage(Condition.getPage(query), distributionDeliveryList); |
||||
return R.data(pages); |
||||
} |
||||
|
||||
/** |
||||
* 配送管理 新增 |
||||
*/ |
||||
@PostMapping("/save") |
||||
@ApiOperationSupport(order = 4) |
||||
@ApiOperation(value = "新增", notes = "传入distributionDeliveryList") |
||||
public R save(@Valid @RequestBody DistributionDeliveryListEntity distributionDeliveryList) { |
||||
return R.status(distributionDeliveryListService.save(distributionDeliveryList)); |
||||
} |
||||
|
||||
/** |
||||
* 配送管理 修改 |
||||
*/ |
||||
@PostMapping("/update") |
||||
@ApiOperationSupport(order = 5) |
||||
@ApiOperation(value = "修改", notes = "传入distributionDeliveryList") |
||||
public R update(@Valid @RequestBody DistributionDeliveryListEntity distributionDeliveryList) { |
||||
return R.status(distributionDeliveryListService.updateById(distributionDeliveryList)); |
||||
} |
||||
|
||||
/** |
||||
* 配送管理 新增或修改 |
||||
*/ |
||||
@PostMapping("/submit") |
||||
@ApiOperationSupport(order = 6) |
||||
@ApiOperation(value = "新增或修改", notes = "传入distributionDeliveryList") |
||||
public R submit(@Valid @RequestBody DistributionDeliveryListEntity distributionDeliveryList) { |
||||
return R.status(distributionDeliveryListService.saveOrUpdate(distributionDeliveryList)); |
||||
} |
||||
|
||||
/** |
||||
* 配送管理 删除 |
||||
*/ |
||||
@PostMapping("/remove") |
||||
@ApiOperationSupport(order = 7) |
||||
@ApiOperation(value = "逻辑删除", notes = "传入ids") |
||||
public R remove(@ApiParam(value = "主键集合", required = true) @RequestParam String ids) { |
||||
return R.status(distributionDeliveryListService.deleteLogic(Func.toLongList(ids))); |
||||
} |
||||
|
||||
|
||||
/** |
||||
* 导出数据 |
||||
*/ |
||||
@GetMapping("/export-distributionDeliveryList") |
||||
@ApiOperationSupport(order = 9) |
||||
@ApiOperation(value = "导出数据", notes = "传入distributionDeliveryList") |
||||
public void exportDistributionDeliveryList(@ApiIgnore @RequestParam Map<String, Object> distributionDeliveryList, BladeUser bladeUser, HttpServletResponse response) { |
||||
QueryWrapper<DistributionDeliveryListEntity> queryWrapper = Condition.getQueryWrapper(distributionDeliveryList, DistributionDeliveryListEntity.class); |
||||
//if (!AuthUtil.isAdministrator()) {
|
||||
// queryWrapper.lambda().eq(DistributionDeliveryList::getTenantId, bladeUser.getTenantId());
|
||||
//}
|
||||
queryWrapper.lambda().eq(DistributionDeliveryListEntity::getIsDeleted, BladeConstant.DB_NOT_DELETED); |
||||
List<DistributionDeliveryListExcel> list = distributionDeliveryListService.exportDistributionDeliveryList(queryWrapper); |
||||
ExcelUtil.export(response, "配送管理数据" + DateUtil.time(), "配送管理数据表", list, DistributionDeliveryListExcel.class); |
||||
} |
||||
|
||||
} |
@ -0,0 +1,34 @@
|
||||
/* |
||||
* Copyright (c) 2018-2028, Chill Zhuang All rights reserved. |
||||
* |
||||
* Redistribution and use in source and binary forms, with or without |
||||
* modification, are permitted provided that the following conditions are met: |
||||
* |
||||
* Redistributions of source code must retain the above copyright notice, |
||||
* this list of conditions and the following disclaimer. |
||||
* Redistributions in binary form must reproduce the above copyright |
||||
* notice, this list of conditions and the following disclaimer in the |
||||
* documentation and/or other materials provided with the distribution. |
||||
* Neither the name of the dreamlu.net developer nor the names of its |
||||
* contributors may be used to endorse or promote products derived from |
||||
* this software without specific prior written permission. |
||||
* Author: Chill 庄骞 (smallchill@163.com) |
||||
*/ |
||||
package com.logpm.distribution.dto; |
||||
|
||||
import com.logpm.distribution.entity.DistributionDeliveryListEntity; |
||||
import lombok.Data; |
||||
import lombok.EqualsAndHashCode; |
||||
|
||||
/** |
||||
* 配送管理 数据传输对象实体类 |
||||
* |
||||
* @author lmy |
||||
* @since 2023-06-16 |
||||
*/ |
||||
@Data |
||||
@EqualsAndHashCode(callSuper = true) |
||||
public class DistributionDeliveryListDTO extends DistributionDeliveryListEntity { |
||||
private static final long serialVersionUID = 1L; |
||||
|
||||
} |
@ -0,0 +1,184 @@
|
||||
/* |
||||
* Copyright (c) 2018-2028, Chill Zhuang All rights reserved. |
||||
* |
||||
* Redistribution and use in source and binary forms, with or without |
||||
* modification, are permitted provided that the following conditions are met: |
||||
* |
||||
* Redistributions of source code must retain the above copyright notice, |
||||
* this list of conditions and the following disclaimer. |
||||
* Redistributions in binary form must reproduce the above copyright |
||||
* notice, this list of conditions and the following disclaimer in the |
||||
* documentation and/or other materials provided with the distribution. |
||||
* Neither the name of the dreamlu.net developer nor the names of its |
||||
* contributors may be used to endorse or promote products derived from |
||||
* this software without specific prior written permission. |
||||
* Author: Chill 庄骞 (smallchill@163.com) |
||||
*/ |
||||
package com.logpm.distribution.excel; |
||||
|
||||
|
||||
import lombok.Data; |
||||
|
||||
import java.util.Date; |
||||
import java.math.BigDecimal; |
||||
import com.alibaba.excel.annotation.ExcelProperty; |
||||
import com.alibaba.excel.annotation.write.style.ColumnWidth; |
||||
import com.alibaba.excel.annotation.write.style.ContentRowHeight; |
||||
import com.alibaba.excel.annotation.write.style.HeadRowHeight; |
||||
import java.io.Serializable; |
||||
|
||||
|
||||
/** |
||||
* 配送管理 Excel实体类 |
||||
* |
||||
* @author lmy |
||||
* @since 2023-06-16 |
||||
*/ |
||||
@Data |
||||
@ColumnWidth(25) |
||||
@HeadRowHeight(20) |
||||
@ContentRowHeight(18) |
||||
public class DistributionDeliveryListExcel implements Serializable { |
||||
|
||||
private static final long serialVersionUID = 1L; |
||||
|
||||
/** |
||||
* 租户号 |
||||
*/ |
||||
@ColumnWidth(20) |
||||
@ExcelProperty("租户号") |
||||
private String tenantId; |
||||
/** |
||||
* 是否已删除 |
||||
*/ |
||||
@ColumnWidth(20) |
||||
@ExcelProperty("是否已删除") |
||||
private Integer isDeleted; |
||||
/** |
||||
* 预留1 |
||||
*/ |
||||
@ColumnWidth(20) |
||||
@ExcelProperty("预留1") |
||||
private String reserve1; |
||||
/** |
||||
* 预留2 |
||||
*/ |
||||
@ColumnWidth(20) |
||||
@ExcelProperty("预留2") |
||||
private String reserve2; |
||||
/** |
||||
* 预留3 |
||||
*/ |
||||
@ColumnWidth(20) |
||||
@ExcelProperty("预留3") |
||||
private String reserve3; |
||||
/** |
||||
* 预留4 |
||||
*/ |
||||
@ColumnWidth(20) |
||||
@ExcelProperty("预留4") |
||||
private String reserve4; |
||||
/** |
||||
* 预留5 |
||||
*/ |
||||
@ColumnWidth(20) |
||||
@ExcelProperty("预留5") |
||||
private String reserve5; |
||||
/** |
||||
* 车次 |
||||
*/ |
||||
@ColumnWidth(20) |
||||
@ExcelProperty("车次") |
||||
private String trainNumber; |
||||
/** |
||||
* 仓库 |
||||
*/ |
||||
@ColumnWidth(20) |
||||
@ExcelProperty("仓库") |
||||
private String warehouse; |
||||
/** |
||||
* 配送类型;1-自主配送,2-三方配送 |
||||
*/ |
||||
@ColumnWidth(20) |
||||
@ExcelProperty("配送类型;1-自主配送,2-三方配送") |
||||
private String type; |
||||
/** |
||||
* 配送种类;1-市配,2-商配 |
||||
*/ |
||||
@ColumnWidth(20) |
||||
@ExcelProperty("配送种类;1-市配,2-商配") |
||||
private String kind; |
||||
/** |
||||
* 配送车辆 |
||||
*/ |
||||
@ColumnWidth(20) |
||||
@ExcelProperty("配送车辆") |
||||
private String vehicle; |
||||
/** |
||||
* 配送司机 |
||||
*/ |
||||
@ColumnWidth(20) |
||||
@ExcelProperty("配送司机") |
||||
private String driver; |
||||
/** |
||||
* 配送公司;1-货拉拉,2-京东 |
||||
*/ |
||||
@ColumnWidth(20) |
||||
@ExcelProperty("配送公司;1-货拉拉,2-京东") |
||||
private String distributionCompany; |
||||
/** |
||||
* 配送状态;1-配送中,2-已完成 |
||||
*/ |
||||
@ColumnWidth(20) |
||||
@ExcelProperty("配送状态;1-配送中,2-已完成") |
||||
private String state; |
||||
/** |
||||
* 配送客户数 |
||||
*/ |
||||
@ColumnWidth(20) |
||||
@ExcelProperty("配送客户数") |
||||
private Integer customersNumber; |
||||
/** |
||||
* 配送价格 |
||||
*/ |
||||
@ColumnWidth(20) |
||||
@ExcelProperty("配送价格") |
||||
private BigDecimal price; |
||||
/** |
||||
* 增值服务表id |
||||
*/ |
||||
@ColumnWidth(20) |
||||
@ExcelProperty("增值服务表id") |
||||
private Integer addedServicesId; |
||||
/** |
||||
* 订单总数 |
||||
*/ |
||||
@ColumnWidth(20) |
||||
@ExcelProperty("订单总数") |
||||
private Integer orderNumber; |
||||
/** |
||||
* 配送件数 |
||||
*/ |
||||
@ColumnWidth(20) |
||||
@ExcelProperty("配送件数") |
||||
private Integer deliveryNumber; |
||||
/** |
||||
* 扫描件数 |
||||
*/ |
||||
@ColumnWidth(20) |
||||
@ExcelProperty("扫描件数") |
||||
private Integer scannedNumber; |
||||
/** |
||||
* 装卸班组 |
||||
*/ |
||||
@ColumnWidth(20) |
||||
@ExcelProperty("装卸班组") |
||||
private String loadingTeam; |
||||
/** |
||||
* 预约表id |
||||
*/ |
||||
@ColumnWidth(20) |
||||
@ExcelProperty("预约表id") |
||||
private String reservationId; |
||||
|
||||
} |
@ -0,0 +1,53 @@
|
||||
/* |
||||
* Copyright (c) 2018-2028, Chill Zhuang All rights reserved. |
||||
* |
||||
* Redistribution and use in source and binary forms, with or without |
||||
* modification, are permitted provided that the following conditions are met: |
||||
* |
||||
* Redistributions of source code must retain the above copyright notice, |
||||
* this list of conditions and the following disclaimer. |
||||
* Redistributions in binary form must reproduce the above copyright |
||||
* notice, this list of conditions and the following disclaimer in the |
||||
* documentation and/or other materials provided with the distribution. |
||||
* Neither the name of the dreamlu.net developer nor the names of its |
||||
* contributors may be used to endorse or promote products derived from |
||||
* this software without specific prior written permission. |
||||
* Author: Chill 庄骞 (smallchill@163.com) |
||||
*/ |
||||
package com.logpm.distribution.feign; |
||||
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage; |
||||
import lombok.AllArgsConstructor; |
||||
import org.springblade.core.mp.support.BladePage; |
||||
import org.springblade.core.mp.support.Condition; |
||||
import org.springblade.core.mp.support.Query; |
||||
import com.logpm.distribution.entity.DistributionDeliveryListEntity; |
||||
import com.logpm.distribution.service.IDistributionDeliveryListService; |
||||
import org.springframework.web.bind.annotation.GetMapping; |
||||
import org.springframework.web.bind.annotation.RestController; |
||||
import springfox.documentation.annotations.ApiIgnore; |
||||
|
||||
/** |
||||
* 配送管理 Feign实现类 |
||||
* |
||||
* @author lmy |
||||
* @since 2023-06-16 |
||||
*/ |
||||
@ApiIgnore() |
||||
@RestController |
||||
@AllArgsConstructor |
||||
public class DistributionDeliveryListClient implements IDistributionDeliveryListClient { |
||||
|
||||
private final IDistributionDeliveryListService distributionDeliveryListService; |
||||
|
||||
@Override |
||||
@GetMapping(TOP) |
||||
public BladePage<DistributionDeliveryListEntity> top(Integer current, Integer size) { |
||||
Query query = new Query(); |
||||
query.setCurrent(current); |
||||
query.setSize(size); |
||||
IPage<DistributionDeliveryListEntity> page = distributionDeliveryListService.page(Condition.getPage(query)); |
||||
return BladePage.of(page); |
||||
} |
||||
|
||||
} |
@ -0,0 +1,54 @@
|
||||
/* |
||||
* Copyright (c) 2018-2028, Chill Zhuang All rights reserved. |
||||
* |
||||
* Redistribution and use in source and binary forms, with or without |
||||
* modification, are permitted provided that the following conditions are met: |
||||
* |
||||
* Redistributions of source code must retain the above copyright notice, |
||||
* this list of conditions and the following disclaimer. |
||||
* Redistributions in binary form must reproduce the above copyright |
||||
* notice, this list of conditions and the following disclaimer in the |
||||
* documentation and/or other materials provided with the distribution. |
||||
* Neither the name of the dreamlu.net developer nor the names of its |
||||
* contributors may be used to endorse or promote products derived from |
||||
* this software without specific prior written permission. |
||||
* Author: Chill 庄骞 (smallchill@163.com) |
||||
*/ |
||||
package com.logpm.distribution.mapper; |
||||
|
||||
import com.logpm.distribution.entity.DistributionDeliveryListEntity; |
||||
import com.logpm.distribution.vo.DistributionDeliveryListVO; |
||||
import com.logpm.distribution.excel.DistributionDeliveryListExcel; |
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
||||
import com.baomidou.mybatisplus.core.conditions.Wrapper; |
||||
import com.baomidou.mybatisplus.core.metadata.IPage; |
||||
import org.apache.ibatis.annotations.Param; |
||||
import java.util.List; |
||||
|
||||
/** |
||||
* 配送管理 Mapper 接口 |
||||
* |
||||
* @author lmy |
||||
* @since 2023-06-16 |
||||
*/ |
||||
public interface DistributionDeliveryListMapper extends BaseMapper<DistributionDeliveryListEntity> { |
||||
|
||||
/** |
||||
* 自定义分页 |
||||
* |
||||
* @param page |
||||
* @param distributionDeliveryList |
||||
* @return |
||||
*/ |
||||
List<DistributionDeliveryListVO> selectDistributionDeliveryListPage(IPage page, DistributionDeliveryListVO distributionDeliveryList); |
||||
|
||||
|
||||
/** |
||||
* 获取导出数据 |
||||
* |
||||
* @param queryWrapper |
||||
* @return |
||||
*/ |
||||
List<DistributionDeliveryListExcel> exportDistributionDeliveryList(@Param("ew") Wrapper<DistributionDeliveryListEntity> queryWrapper); |
||||
|
||||
} |
@ -0,0 +1,49 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?> |
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
||||
<mapper namespace="com.logpm.distribution.mapper.DistributionDeliveryListMapper"> |
||||
|
||||
<!-- 通用查询映射结果 --> |
||||
<resultMap id="distributionDeliveryListResultMap" type="com.logpm.distribution.entity.DistributionDeliveryListEntity"> |
||||
<result column="id" property="id"/> |
||||
<result column="tenant_id" property="tenantId"/> |
||||
<result column="create_user" property="createUser"/> |
||||
<result column="create_time" property="createTime"/> |
||||
<result column="update_user" property="updateUser"/> |
||||
<result column="update_time" property="updateTime"/> |
||||
<result column="status" property="status"/> |
||||
<result column="is_deleted" property="isDeleted"/> |
||||
<result column="create_dept" property="createDept"/> |
||||
<result column="reserve1" property="reserve1"/> |
||||
<result column="reserve2" property="reserve2"/> |
||||
<result column="reserve3" property="reserve3"/> |
||||
<result column="reserve4" property="reserve4"/> |
||||
<result column="reserve5" property="reserve5"/> |
||||
<result column="train_number" property="trainNumber"/> |
||||
<result column="warehouse" property="warehouse"/> |
||||
<result column="type" property="type"/> |
||||
<result column="kind" property="kind"/> |
||||
<result column="vehicle" property="vehicle"/> |
||||
<result column="driver" property="driver"/> |
||||
<result column="distribution_company" property="distributionCompany"/> |
||||
<result column="state" property="state"/> |
||||
<result column="customers_number" property="customersNumber"/> |
||||
<result column="price" property="price"/> |
||||
<result column="added_services_id" property="addedServicesId"/> |
||||
<result column="order_number" property="orderNumber"/> |
||||
<result column="delivery_number" property="deliveryNumber"/> |
||||
<result column="scanned_number" property="scannedNumber"/> |
||||
<result column="loading_team" property="loadingTeam"/> |
||||
<result column="reservation_id" property="reservationId"/> |
||||
</resultMap> |
||||
|
||||
|
||||
<select id="selectDistributionDeliveryListPage" resultMap="distributionDeliveryListResultMap"> |
||||
select * from logpm_distribution_delivery_list where is_deleted = 0 |
||||
</select> |
||||
|
||||
|
||||
<select id="exportDistributionDeliveryList" resultType="com.logpm.distribution.excel.DistributionDeliveryListExcel"> |
||||
SELECT * FROM logpm_distribution_delivery_list ${ew.customSqlSegment} |
||||
</select> |
||||
|
||||
</mapper> |
@ -0,0 +1,58 @@
|
||||
/* |
||||
* Copyright (c) 2018-2028, Chill Zhuang All rights reserved. |
||||
* |
||||
* Redistribution and use in source and binary forms, with or without |
||||
* modification, are permitted provided that the following conditions are met: |
||||
* |
||||
* Redistributions of source code must retain the above copyright notice, |
||||
* this list of conditions and the following disclaimer. |
||||
* Redistributions in binary form must reproduce the above copyright |
||||
* notice, this list of conditions and the following disclaimer in the |
||||
* documentation and/or other materials provided with the distribution. |
||||
* Neither the name of the dreamlu.net developer nor the names of its |
||||
* contributors may be used to endorse or promote products derived from |
||||
* this software without specific prior written permission. |
||||
* Author: Chill 庄骞 (smallchill@163.com) |
||||
*/ |
||||
package com.logpm.distribution.service; |
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.Wrapper; |
||||
import com.logpm.distribution.entity.DistributionDeliveryListEntity; |
||||
import com.logpm.distribution.vo.DistributionDeliveryListVO; |
||||
import com.logpm.distribution.excel.DistributionDeliveryListExcel; |
||||
import com.baomidou.mybatisplus.core.metadata.IPage; |
||||
import org.springblade.core.mp.base.BaseService; |
||||
import java.util.List; |
||||
|
||||
/** |
||||
* 配送管理 服务类 |
||||
* |
||||
* @author lmy |
||||
* @since 2023-06-16 |
||||
*/ |
||||
public interface IDistributionDeliveryListService extends BaseService<DistributionDeliveryListEntity> { |
||||
/** |
||||
* 自定义分页 |
||||
* |
||||
* @param page |
||||
* @param distributionDeliveryList |
||||
* @return |
||||
*/ |
||||
IPage<DistributionDeliveryListVO> selectDistributionDeliveryListPage(IPage<DistributionDeliveryListVO> page, DistributionDeliveryListVO distributionDeliveryList); |
||||
|
||||
|
||||
/** |
||||
* 导出数据 |
||||
* |
||||
* @param queryWrapper |
||||
* @return |
||||
*/ |
||||
List<DistributionDeliveryListExcel> exportDistributionDeliveryList(Wrapper<DistributionDeliveryListEntity> queryWrapper); |
||||
/** |
||||
* 获取其他表信息 |
||||
* |
||||
* @param detail |
||||
* @return |
||||
*/ |
||||
DistributionDeliveryListVO getdetailVO(DistributionDeliveryListEntity detail); |
||||
} |
@ -0,0 +1,64 @@
|
||||
/* |
||||
* Copyright (c) 2018-2028, Chill Zhuang All rights reserved. |
||||
* |
||||
* Redistribution and use in source and binary forms, with or without |
||||
* modification, are permitted provided that the following conditions are met: |
||||
* |
||||
* Redistributions of source code must retain the above copyright notice, |
||||
* this list of conditions and the following disclaimer. |
||||
* Redistributions in binary form must reproduce the above copyright |
||||
* notice, this list of conditions and the following disclaimer in the |
||||
* documentation and/or other materials provided with the distribution. |
||||
* Neither the name of the dreamlu.net developer nor the names of its |
||||
* contributors may be used to endorse or promote products derived from |
||||
* this software without specific prior written permission. |
||||
* Author: Chill 庄骞 (smallchill@163.com) |
||||
*/ |
||||
package com.logpm.distribution.service.impl; |
||||
|
||||
import com.logpm.distribution.entity.DistributionDeliveryListEntity; |
||||
import com.logpm.distribution.vo.DistributionDeliveryListVO; |
||||
import com.logpm.distribution.excel.DistributionDeliveryListExcel; |
||||
import com.logpm.distribution.mapper.DistributionDeliveryListMapper; |
||||
import com.logpm.distribution.service.IDistributionDeliveryListService; |
||||
import org.springframework.beans.BeanUtils; |
||||
import org.springframework.stereotype.Service; |
||||
import com.baomidou.mybatisplus.core.conditions.Wrapper; |
||||
import com.baomidou.mybatisplus.core.metadata.IPage; |
||||
import org.springblade.core.mp.base.BaseServiceImpl; |
||||
import java.util.List; |
||||
|
||||
/** |
||||
* 配送管理 服务实现类 |
||||
* |
||||
* @author lmy |
||||
* @since 2023-06-16 |
||||
*/ |
||||
@Service |
||||
public class DistributionDeliveryListServiceImpl extends BaseServiceImpl<DistributionDeliveryListMapper, DistributionDeliveryListEntity> implements IDistributionDeliveryListService { |
||||
|
||||
@Override |
||||
public IPage<DistributionDeliveryListVO> selectDistributionDeliveryListPage(IPage<DistributionDeliveryListVO> page, DistributionDeliveryListVO distributionDeliveryList) { |
||||
return page.setRecords(baseMapper.selectDistributionDeliveryListPage(page, distributionDeliveryList)); |
||||
} |
||||
|
||||
|
||||
@Override |
||||
public List<DistributionDeliveryListExcel> exportDistributionDeliveryList(Wrapper<DistributionDeliveryListEntity> queryWrapper) { |
||||
List<DistributionDeliveryListExcel> distributionDeliveryListList = baseMapper.exportDistributionDeliveryList(queryWrapper); |
||||
//distributionDeliveryListList.forEach(distributionDeliveryList -> {
|
||||
// distributionDeliveryList.setTypeName(DictCache.getValue(DictEnum.YES_NO, DistributionDeliveryList.getType()));
|
||||
//});
|
||||
return distributionDeliveryListList; |
||||
} |
||||
|
||||
@Override |
||||
public DistributionDeliveryListVO getdetailVO(DistributionDeliveryListEntity detail) { |
||||
DistributionDeliveryListVO distributionDeliveryListVO = new DistributionDeliveryListVO(); |
||||
//转移数据到VO上
|
||||
BeanUtils.copyProperties(detail,distributionDeliveryListVO); |
||||
|
||||
return null; |
||||
} |
||||
|
||||
} |
Loading…
Reference in new issue