金属元素新增排序

This commit is contained in:
liss
2025-11-10 15:37:51 +08:00
parent 1c11f52636
commit bb5375d256
7 changed files with 30 additions and 6 deletions

View File

@@ -35,4 +35,6 @@ public class ElementPageReqVO extends PageParam {
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND) @DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
private LocalDateTime[] createTime; private LocalDateTime[] createTime;
@Schema(description = "排序")
private Integer sort;
} }

View File

@@ -44,4 +44,6 @@ public class ElementRespVO {
@ExcelProperty("创建时间") @ExcelProperty("创建时间")
private LocalDateTime createTime; private LocalDateTime createTime;
@Schema(description = "排序")
private Integer sort;
} }

View File

@@ -34,4 +34,7 @@ public class ElementSaveReqVO {
@NotEmpty(message = "品位单位不能为空") @NotEmpty(message = "品位单位不能为空")
private String gradeUnit; private String gradeUnit;
@Schema(description = "排序")
private Integer sort;
} }

View File

@@ -94,4 +94,7 @@ public class ElementDO extends BusinessBaseDO {
@TableField("UPDATER_NAME") @TableField("UPDATER_NAME")
private String updaterName; private String updaterName;
@TableField("SORT")
private Integer sort;
} }

View File

@@ -26,13 +26,14 @@ public interface ElementMapper extends BaseMapperX<ElementDO> {
.likeIfPresent(ElementDO::getCoding, reqVO.getCoding()) .likeIfPresent(ElementDO::getCoding, reqVO.getCoding())
.eqIfPresent(ElementDO::getGradeUnit, reqVO.getGradeUnit()) .eqIfPresent(ElementDO::getGradeUnit, reqVO.getGradeUnit())
.betweenIfPresent(ElementDO::getCreateTime, reqVO.getCreateTime()) .betweenIfPresent(ElementDO::getCreateTime, reqVO.getCreateTime())
.orderByDesc(ElementDO::getId)); .orderByDesc(ElementDO::getSort));
} }
String selectMaxCode(); String selectMaxCode();
default List<ElementDO> getElementNoPage() { default List<ElementDO> getElementNoPage() {
return selectList(new LambdaQueryWrapperX<ElementDO>() return selectList(new LambdaQueryWrapperX<ElementDO>()
.orderByDesc(ElementDO::getId)); .eq(ElementDO::getIsEnable, 1)
.orderByDesc(ElementDO::getSort));
} }
} }

View File

@@ -6,6 +6,7 @@ import com.zt.plat.framework.common.pojo.CommonResult;
import com.zt.plat.framework.common.pojo.PageResult; import com.zt.plat.framework.common.pojo.PageResult;
import com.zt.plat.framework.common.util.object.BeanUtils; import com.zt.plat.framework.common.util.object.BeanUtils;
import com.zt.plat.module.contractorder.api.ContractApi; import com.zt.plat.module.contractorder.api.ContractApi;
import com.zt.plat.module.contractorder.api.dto.order.PurchaseOrderWithDetailsDTO;
import com.zt.plat.module.contractorder.api.vo.contract.*; import com.zt.plat.module.contractorder.api.vo.contract.*;
import com.zt.plat.module.contractorder.api.vo.contract.international.IntContract; import com.zt.plat.module.contractorder.api.vo.contract.international.IntContract;
import com.zt.plat.module.contractorder.api.vo.contract.international.IntContractPageReq; import com.zt.plat.module.contractorder.api.vo.contract.international.IntContractPageReq;
@@ -206,4 +207,11 @@ public class ContractController implements BusinessControllerMarker {
public CommonResult<PageResult<IntContract>> logisticsListPage(IntContractPageReq pageReq) { public CommonResult<PageResult<IntContract>> logisticsListPage(IntContractPageReq pageReq) {
return contractApi.logisticsListPage(pageReq); return contractApi.logisticsListPage(pageReq);
} }
@PostMapping("/order-by-order-no")
@Operation(summary = "通过订单编号获取订单信息", description = "通过订单编号获取订单信息")
@PreAuthorize("@ss.hasPermission('base:contract:query')")
public CommonResult<List<PurchaseOrderWithDetailsDTO>> getOrderByOrderNo(@RequestBody List<String> orderNoS){
return contractApi.getOrderByOrderNo(orderNoS);
};
} }

View File

@@ -1,13 +1,16 @@
package com.zt.plat.module.contractorder.controller.admin.contractorder; package com.zt.plat.module.contractorder.controller.admin.contractorder;
import com.zt.plat.module.contractorder.api.dto.order.PurchaseOrderWithDetailsDTO;
import com.zt.plat.module.contractorder.service.contract.ContractService;
import io.swagger.v3.oas.annotations.Operation; import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.tags.Tag; import io.swagger.v3.oas.annotations.tags.Tag;
import org.springframework.web.bind.annotation.GetMapping; import jakarta.annotation.Resource;
import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.*;
import org.springframework.web.bind.annotation.RestController;
import com.zt.plat.framework.common.pojo.CommonResult; import com.zt.plat.framework.common.pojo.CommonResult;
import java.util.List;
import static com.zt.plat.framework.common.pojo.CommonResult.success; import static com.zt.plat.framework.common.pojo.CommonResult.success;
/** /**
@@ -20,10 +23,12 @@ import static com.zt.plat.framework.common.pojo.CommonResult.success;
@RequestMapping("/admin/contract-order/contract-order") @RequestMapping("/admin/contract-order/contract-order")
public class ContractOrderController { public class ContractOrderController {
@Resource
private ContractService contractService;
@GetMapping("/hello") @GetMapping("/hello")
@Operation(summary = "Hello ContractOrder") @Operation(summary = "Hello ContractOrder")
public CommonResult<String> hello() { public CommonResult<String> hello() {
return success("Hello, ContractOrder!"); return success("Hello, ContractOrder!");
} }
} }