Showing
7 changed files
with
76 additions
and
19 deletions
| @@ -5,7 +5,10 @@ import com.fasterxml.jackson.annotation.JsonFormat; | @@ -5,7 +5,10 @@ import com.fasterxml.jackson.annotation.JsonFormat; | ||
| 5 | import com.lframework.starter.common.constants.StringPool; | 5 | import com.lframework.starter.common.constants.StringPool; |
| 6 | import com.lframework.starter.web.core.bo.BaseBo; | 6 | import com.lframework.starter.web.core.bo.BaseBo; |
| 7 | import java.time.LocalDate; | 7 | import java.time.LocalDate; |
| 8 | +import java.util.List; | ||
| 9 | + | ||
| 8 | import com.lframework.xingyun.sc.entity.PurchaseOrderInfo; | 10 | import com.lframework.xingyun.sc.entity.PurchaseOrderInfo; |
| 11 | +import com.lframework.xingyun.sc.entity.PurchaseOrderLine; | ||
| 9 | import io.swagger.annotations.ApiModelProperty; | 12 | import io.swagger.annotations.ApiModelProperty; |
| 10 | 13 | ||
| 11 | import lombok.Data; | 14 | import lombok.Data; |
| @@ -200,6 +203,12 @@ public class GetPurchaseOrderInfoBo extends BaseBo<PurchaseOrderInfo> { | @@ -200,6 +203,12 @@ public class GetPurchaseOrderInfoBo extends BaseBo<PurchaseOrderInfo> { | ||
| 200 | @ApiModelProperty("实际订货数量") | 203 | @ApiModelProperty("实际订货数量") |
| 201 | private String actualOrderNumber; | 204 | private String actualOrderNumber; |
| 202 | 205 | ||
| 206 | + /** | ||
| 207 | + * 订货单表物料行 | ||
| 208 | + */ | ||
| 209 | + @ApiModelProperty("订货单表物料行") | ||
| 210 | + private List<PurchaseOrderLine> purchaseOrderLineList; | ||
| 211 | + | ||
| 203 | 212 | ||
| 204 | 213 | ||
| 205 | public GetPurchaseOrderInfoBo() { | 214 | public GetPurchaseOrderInfoBo() { |
xingyun-sc/src/main/java/com/lframework/xingyun/sc/controller/order/PurchaseOrderInfoController.java
| @@ -5,12 +5,17 @@ import com.lframework.starter.web.core.controller.DefaultBaseController; | @@ -5,12 +5,17 @@ import com.lframework.starter.web.core.controller.DefaultBaseController; | ||
| 5 | import com.lframework.starter.web.core.utils.PageResultUtil; | 5 | import com.lframework.starter.web.core.utils.PageResultUtil; |
| 6 | import com.lframework.starter.web.core.components.resp.PageResult; | 6 | import com.lframework.starter.web.core.components.resp.PageResult; |
| 7 | import com.lframework.starter.web.core.components.resp.InvokeResult; | 7 | import com.lframework.starter.web.core.components.resp.InvokeResult; |
| 8 | + | ||
| 9 | +import javax.annotation.Resource; | ||
| 8 | import javax.validation.constraints.NotBlank; | 10 | import javax.validation.constraints.NotBlank; |
| 9 | import com.lframework.xingyun.sc.bo.order.GetPurchaseOrderInfoBo; | 11 | import com.lframework.xingyun.sc.bo.order.GetPurchaseOrderInfoBo; |
| 10 | import com.lframework.xingyun.sc.entity.PurchaseOrderInfo; | 12 | import com.lframework.xingyun.sc.entity.PurchaseOrderInfo; |
| 13 | +import com.lframework.xingyun.sc.entity.PurchaseOrderLine; | ||
| 11 | import com.lframework.xingyun.sc.service.order.PurchaseOrderInfoService; | 14 | import com.lframework.xingyun.sc.service.order.PurchaseOrderInfoService; |
| 15 | +import com.lframework.xingyun.sc.service.order.PurchaseOrderLineService; | ||
| 12 | import com.lframework.xingyun.sc.vo.order.CreatePurchaseOrderInfoVo; | 16 | import com.lframework.xingyun.sc.vo.order.CreatePurchaseOrderInfoVo; |
| 13 | import com.lframework.xingyun.sc.vo.order.QueryPurchaseOrderInfoVo; | 17 | import com.lframework.xingyun.sc.vo.order.QueryPurchaseOrderInfoVo; |
| 18 | +import com.lframework.xingyun.sc.vo.order.QueryPurchaseOrderLineVo; | ||
| 14 | import com.lframework.xingyun.sc.vo.order.UpdatePurchaseOrderInfoVo; | 19 | import com.lframework.xingyun.sc.vo.order.UpdatePurchaseOrderInfoVo; |
| 15 | import io.swagger.annotations.ApiImplicitParam; | 20 | import io.swagger.annotations.ApiImplicitParam; |
| 16 | import com.lframework.starter.web.core.components.resp.InvokeResultBuilder; | 21 | import com.lframework.starter.web.core.components.resp.InvokeResultBuilder; |
| @@ -18,6 +23,7 @@ import com.lframework.starter.common.exceptions.impl.DefaultClientException; | @@ -18,6 +23,7 @@ import com.lframework.starter.common.exceptions.impl.DefaultClientException; | ||
| 18 | import io.swagger.annotations.ApiOperation; | 23 | import io.swagger.annotations.ApiOperation; |
| 19 | import com.lframework.starter.common.utils.CollectionUtil; | 24 | import com.lframework.starter.common.utils.CollectionUtil; |
| 20 | import io.swagger.annotations.Api; | 25 | import io.swagger.annotations.Api; |
| 26 | +import org.springframework.security.core.parameters.P; | ||
| 21 | import org.springframework.web.bind.annotation.DeleteMapping; | 27 | import org.springframework.web.bind.annotation.DeleteMapping; |
| 22 | import org.springframework.beans.factory.annotation.Autowired; | 28 | import org.springframework.beans.factory.annotation.Autowired; |
| 23 | import org.springframework.validation.annotation.Validated; | 29 | import org.springframework.validation.annotation.Validated; |
| @@ -39,7 +45,8 @@ public class PurchaseOrderInfoController extends DefaultBaseController { | @@ -39,7 +45,8 @@ public class PurchaseOrderInfoController extends DefaultBaseController { | ||
| 39 | 45 | ||
| 40 | @Autowired | 46 | @Autowired |
| 41 | private PurchaseOrderInfoService purchaseOrderInfoService; | 47 | private PurchaseOrderInfoService purchaseOrderInfoService; |
| 42 | - | 48 | + @Resource |
| 49 | + private PurchaseOrderLineService purchaseOrderLineService; | ||
| 43 | /** | 50 | /** |
| 44 | * 查询列表 | 51 | * 查询列表 |
| 45 | */ | 52 | */ |
| @@ -66,7 +73,7 @@ public class PurchaseOrderInfoController extends DefaultBaseController { | @@ -66,7 +73,7 @@ public class PurchaseOrderInfoController extends DefaultBaseController { | ||
| 66 | @ApiOperation("根据ID查询") | 73 | @ApiOperation("根据ID查询") |
| 67 | @ApiImplicitParam(value = "id", name = "id", paramType = "query", required = true) | 74 | @ApiImplicitParam(value = "id", name = "id", paramType = "query", required = true) |
| 68 | @HasPermission({"purchaseOrderInfo:purchaseorderinfo:query"}) | 75 | @HasPermission({"purchaseOrderInfo:purchaseorderinfo:query"}) |
| 69 | - @GetMapping | 76 | + @GetMapping("/get") |
| 70 | public InvokeResult<GetPurchaseOrderInfoBo> get(@NotBlank(message = "id不能为空!") String id) { | 77 | public InvokeResult<GetPurchaseOrderInfoBo> get(@NotBlank(message = "id不能为空!") String id) { |
| 71 | 78 | ||
| 72 | PurchaseOrderInfo data = purchaseOrderInfoService.findById(id); | 79 | PurchaseOrderInfo data = purchaseOrderInfoService.findById(id); |
| @@ -75,6 +82,13 @@ public class PurchaseOrderInfoController extends DefaultBaseController { | @@ -75,6 +82,13 @@ public class PurchaseOrderInfoController extends DefaultBaseController { | ||
| 75 | } | 82 | } |
| 76 | 83 | ||
| 77 | GetPurchaseOrderInfoBo result = new GetPurchaseOrderInfoBo(data); | 84 | GetPurchaseOrderInfoBo result = new GetPurchaseOrderInfoBo(data); |
| 85 | + QueryPurchaseOrderLineVo vo = new QueryPurchaseOrderLineVo(); | ||
| 86 | + vo.setPurchaseOrderId(id); | ||
| 87 | + List<PurchaseOrderLine> purchaseOrderLineList = purchaseOrderLineService.query(vo); | ||
| 88 | + if (CollectionUtil.isNotEmpty(purchaseOrderLineList)) { | ||
| 89 | + result.setPurchaseOrderLineList(purchaseOrderLineList); | ||
| 90 | + } | ||
| 91 | + | ||
| 78 | 92 | ||
| 79 | return InvokeResultBuilder.success(result); | 93 | return InvokeResultBuilder.success(result); |
| 80 | } | 94 | } |
| @@ -84,8 +98,8 @@ public class PurchaseOrderInfoController extends DefaultBaseController { | @@ -84,8 +98,8 @@ public class PurchaseOrderInfoController extends DefaultBaseController { | ||
| 84 | */ | 98 | */ |
| 85 | @ApiOperation("新增") | 99 | @ApiOperation("新增") |
| 86 | @HasPermission({"purchaseOrderInfo:purchaseorderinfo:add"}) | 100 | @HasPermission({"purchaseOrderInfo:purchaseorderinfo:add"}) |
| 87 | - @PostMapping | ||
| 88 | - public InvokeResult<Void> create(@Valid CreatePurchaseOrderInfoVo vo) { | 101 | + @PostMapping("/create") |
| 102 | + public InvokeResult<Void> create(@Valid @RequestBody CreatePurchaseOrderInfoVo vo) { | ||
| 89 | 103 | ||
| 90 | purchaseOrderInfoService.create(vo); | 104 | purchaseOrderInfoService.create(vo); |
| 91 | 105 | ||
| @@ -97,8 +111,8 @@ public class PurchaseOrderInfoController extends DefaultBaseController { | @@ -97,8 +111,8 @@ public class PurchaseOrderInfoController extends DefaultBaseController { | ||
| 97 | */ | 111 | */ |
| 98 | @ApiOperation("修改") | 112 | @ApiOperation("修改") |
| 99 | @HasPermission({"purchaseOrderInfo:purchaseorderinfo:modify"}) | 113 | @HasPermission({"purchaseOrderInfo:purchaseorderinfo:modify"}) |
| 100 | - @PutMapping | ||
| 101 | - public InvokeResult<Void> update(@Valid UpdatePurchaseOrderInfoVo vo) { | 114 | + @PutMapping("/update") |
| 115 | + public InvokeResult<Void> update(@Valid @RequestBody UpdatePurchaseOrderInfoVo vo) { | ||
| 102 | 116 | ||
| 103 | purchaseOrderInfoService.update(vo); | 117 | purchaseOrderInfoService.update(vo); |
| 104 | 118 | ||
| @@ -111,7 +125,7 @@ public class PurchaseOrderInfoController extends DefaultBaseController { | @@ -111,7 +125,7 @@ public class PurchaseOrderInfoController extends DefaultBaseController { | ||
| 111 | @ApiOperation("根据ID删除") | 125 | @ApiOperation("根据ID删除") |
| 112 | @ApiImplicitParam(value = "id", name = "id", paramType = "query", required = true) | 126 | @ApiImplicitParam(value = "id", name = "id", paramType = "query", required = true) |
| 113 | @HasPermission({"purchaseOrderInfo:purchaseorderinfo:delete"}) | 127 | @HasPermission({"purchaseOrderInfo:purchaseorderinfo:delete"}) |
| 114 | - @DeleteMapping | 128 | + @DeleteMapping("/deleteById") |
| 115 | public InvokeResult<Void> deleteById(@NotBlank(message = "id不能为空!") String id) { | 129 | public InvokeResult<Void> deleteById(@NotBlank(message = "id不能为空!") String id) { |
| 116 | 130 | ||
| 117 | purchaseOrderInfoService.deleteById(id); | 131 | purchaseOrderInfoService.deleteById(id); |
| @@ -16,14 +16,14 @@ import com.lframework.starter.web.core.annotations.oplog.OpLog; | @@ -16,14 +16,14 @@ import com.lframework.starter.web.core.annotations.oplog.OpLog; | ||
| 16 | import com.lframework.starter.web.core.utils.PageHelperUtil; | 16 | import com.lframework.starter.web.core.utils.PageHelperUtil; |
| 17 | import com.lframework.starter.common.utils.Assert; | 17 | import com.lframework.starter.common.utils.Assert; |
| 18 | import com.lframework.starter.web.inner.components.oplog.OtherOpLogType; | 18 | import com.lframework.starter.web.inner.components.oplog.OtherOpLogType; |
| 19 | +import com.lframework.xingyun.sc.entity.CustomerCredit; | ||
| 19 | import com.lframework.xingyun.sc.entity.PurchaseOrderInfo; | 20 | import com.lframework.xingyun.sc.entity.PurchaseOrderInfo; |
| 20 | import com.lframework.xingyun.sc.mappers.PurchaseOrderInfoMapper; | 21 | import com.lframework.xingyun.sc.mappers.PurchaseOrderInfoMapper; |
| 22 | +import com.lframework.xingyun.sc.service.customer.CustomerCreditService; | ||
| 21 | import com.lframework.xingyun.sc.service.order.PurchaseOrderInfoService; | 23 | import com.lframework.xingyun.sc.service.order.PurchaseOrderInfoService; |
| 22 | import com.lframework.xingyun.sc.service.order.PurchaseOrderLineService; | 24 | import com.lframework.xingyun.sc.service.order.PurchaseOrderLineService; |
| 23 | -import com.lframework.xingyun.sc.vo.order.CreatePurchaseOrderInfoVo; | ||
| 24 | -import com.lframework.xingyun.sc.vo.order.CreatePurchaseOrderLineVo; | ||
| 25 | -import com.lframework.xingyun.sc.vo.order.QueryPurchaseOrderInfoVo; | ||
| 26 | -import com.lframework.xingyun.sc.vo.order.UpdatePurchaseOrderInfoVo; | 25 | +import com.lframework.xingyun.sc.vo.customer.credit.QueryCustomerCreditVo; |
| 26 | +import com.lframework.xingyun.sc.vo.order.*; | ||
| 27 | import org.apache.commons.collections.CollectionUtils; | 27 | import org.apache.commons.collections.CollectionUtils; |
| 28 | import org.springframework.transaction.annotation.Transactional; | 28 | import org.springframework.transaction.annotation.Transactional; |
| 29 | import org.springframework.stereotype.Service; | 29 | import org.springframework.stereotype.Service; |
| @@ -37,6 +37,8 @@ public class PurchaseOrderInfoServiceImpl extends BaseMpServiceImpl<PurchaseOrde | @@ -37,6 +37,8 @@ public class PurchaseOrderInfoServiceImpl extends BaseMpServiceImpl<PurchaseOrde | ||
| 37 | 37 | ||
| 38 | @Resource | 38 | @Resource |
| 39 | private PurchaseOrderLineService purchaseOrderLineService; | 39 | private PurchaseOrderLineService purchaseOrderLineService; |
| 40 | + @Resource | ||
| 41 | + private CustomerCreditService customerCreditService; | ||
| 40 | 42 | ||
| 41 | @Override | 43 | @Override |
| 42 | public PageResult<PurchaseOrderInfo> query(Integer pageIndex, Integer pageSize, QueryPurchaseOrderInfoVo vo) { | 44 | public PageResult<PurchaseOrderInfo> query(Integer pageIndex, Integer pageSize, QueryPurchaseOrderInfoVo vo) { |
| @@ -59,7 +61,7 @@ public class PurchaseOrderInfoServiceImpl extends BaseMpServiceImpl<PurchaseOrde | @@ -59,7 +61,7 @@ public class PurchaseOrderInfoServiceImpl extends BaseMpServiceImpl<PurchaseOrde | ||
| 59 | @Override | 61 | @Override |
| 60 | public PurchaseOrderInfo findById(String id) { | 62 | public PurchaseOrderInfo findById(String id) { |
| 61 | 63 | ||
| 62 | - return getBaseMapper().selectById(id); | 64 | + return getBaseMapper().findById(id); |
| 63 | } | 65 | } |
| 64 | 66 | ||
| 65 | @OpLog(type = OtherOpLogType.class, name = "新增订货单表,ID:{}", params = {"#id"}) | 67 | @OpLog(type = OtherOpLogType.class, name = "新增订货单表,ID:{}", params = {"#id"}) |
| @@ -77,6 +79,15 @@ public class PurchaseOrderInfoServiceImpl extends BaseMpServiceImpl<PurchaseOrde | @@ -77,6 +79,15 @@ public class PurchaseOrderInfoServiceImpl extends BaseMpServiceImpl<PurchaseOrde | ||
| 77 | } | 79 | } |
| 78 | if (!StringUtil.isBlank(vo.getOrderingUnit())) { | 80 | if (!StringUtil.isBlank(vo.getOrderingUnit())) { |
| 79 | data.setOrderingUnit(vo.getOrderingUnit()); | 81 | data.setOrderingUnit(vo.getOrderingUnit()); |
| 82 | + //根据客户id查出客户资信,资信状态不为取消 | ||
| 83 | + QueryCustomerCreditVo queryVo = new QueryCustomerCreditVo(); | ||
| 84 | + queryVo.setCompanyId(vo.getOrderingUnit()); | ||
| 85 | + queryVo.setStatusCancel("CANCEL"); | ||
| 86 | + List<CustomerCredit> query = customerCreditService.query(queryVo); | ||
| 87 | + if (CollectionUtils.isNotEmpty(query)) { | ||
| 88 | + CustomerCredit customerCredit = query.get(0); | ||
| 89 | + data.setCustomerCreditId(customerCredit.getId()); | ||
| 90 | + } | ||
| 80 | } | 91 | } |
| 81 | if (vo.getOrderDate() != null) { | 92 | if (vo.getOrderDate() != null) { |
| 82 | data.setOrderDate(vo.getOrderDate()); | 93 | data.setOrderDate(vo.getOrderDate()); |
| @@ -135,9 +146,6 @@ public class PurchaseOrderInfoServiceImpl extends BaseMpServiceImpl<PurchaseOrde | @@ -135,9 +146,6 @@ public class PurchaseOrderInfoServiceImpl extends BaseMpServiceImpl<PurchaseOrde | ||
| 135 | if (!StringUtil.isBlank(vo.getWorkshopId())) { | 146 | if (!StringUtil.isBlank(vo.getWorkshopId())) { |
| 136 | data.setWorkshopId(vo.getWorkshopId()); | 147 | data.setWorkshopId(vo.getWorkshopId()); |
| 137 | } | 148 | } |
| 138 | - if (!StringUtil.isBlank(vo.getCustomerCreditId())) { | ||
| 139 | - data.setCustomerCreditId(vo.getCustomerCreditId()); | ||
| 140 | - } | ||
| 141 | 149 | ||
| 142 | getBaseMapper().insert(data); | 150 | getBaseMapper().insert(data); |
| 143 | 151 | ||
| @@ -194,6 +202,14 @@ public class PurchaseOrderInfoServiceImpl extends BaseMpServiceImpl<PurchaseOrde | @@ -194,6 +202,14 @@ public class PurchaseOrderInfoServiceImpl extends BaseMpServiceImpl<PurchaseOrde | ||
| 194 | 202 | ||
| 195 | getBaseMapper().update(updateWrapper); | 203 | getBaseMapper().update(updateWrapper); |
| 196 | 204 | ||
| 205 | + //更新订货单表物料行 | ||
| 206 | + List<UpdatePurchaseOrderLineVo> updatePurchaseOrderLineVoList = vo.getUpdatePurchaseOrderLineVoList(); | ||
| 207 | + if (CollectionUtils.isNotEmpty(updatePurchaseOrderLineVoList)) { | ||
| 208 | + for (UpdatePurchaseOrderLineVo updatePurchaseOrderLineVo : updatePurchaseOrderLineVoList) { | ||
| 209 | + purchaseOrderLineService.update(updatePurchaseOrderLineVo); | ||
| 210 | + } | ||
| 211 | + } | ||
| 212 | + | ||
| 197 | OpLogUtil.setVariable("id", data.getId()); | 213 | OpLogUtil.setVariable("id", data.getId()); |
| 198 | OpLogUtil.setExtra(vo); | 214 | OpLogUtil.setExtra(vo); |
| 199 | } | 215 | } |
| @@ -21,4 +21,6 @@ public interface PurchaseOrderInfoMapper extends BaseMapper<PurchaseOrderInfo> { | @@ -21,4 +21,6 @@ public interface PurchaseOrderInfoMapper extends BaseMapper<PurchaseOrderInfo> { | ||
| 21 | * @return | 21 | * @return |
| 22 | */ | 22 | */ |
| 23 | List<PurchaseOrderInfo> query(@Param("vo") QueryPurchaseOrderInfoVo vo); | 23 | List<PurchaseOrderInfo> query(@Param("vo") QueryPurchaseOrderInfoVo vo); |
| 24 | + | ||
| 25 | + PurchaseOrderInfo findById(@Param("id") String id); | ||
| 24 | } | 26 | } |
| @@ -32,13 +32,13 @@ public class QueryPurchaseOrderInfoVo extends PageVo implements BaseVo, Serializ | @@ -32,13 +32,13 @@ public class QueryPurchaseOrderInfoVo extends PageVo implements BaseVo, Serializ | ||
| 32 | /** | 32 | /** |
| 33 | * 订货开始日期 | 33 | * 订货开始日期 |
| 34 | */ | 34 | */ |
| 35 | - @ApiModelProperty("登记开始日期") | 35 | + @ApiModelProperty("订货开始日期") |
| 36 | private String orderDateStart; | 36 | private String orderDateStart; |
| 37 | 37 | ||
| 38 | /** | 38 | /** |
| 39 | * 订货结束日期 | 39 | * 订货结束日期 |
| 40 | */ | 40 | */ |
| 41 | - @ApiModelProperty("登记结束日期") | 41 | + @ApiModelProperty("订货结束日期") |
| 42 | private String orderDateEnd; | 42 | private String orderDateEnd; |
| 43 | 43 | ||
| 44 | /** | 44 | /** |
| @@ -8,6 +8,7 @@ import com.lframework.starter.web.core.components.validation.TypeMismatch; | @@ -8,6 +8,7 @@ import com.lframework.starter.web.core.components.validation.TypeMismatch; | ||
| 8 | import io.swagger.annotations.ApiModelProperty; | 8 | import io.swagger.annotations.ApiModelProperty; |
| 9 | import org.hibernate.validator.constraints.Length; | 9 | import org.hibernate.validator.constraints.Length; |
| 10 | import java.io.Serializable; | 10 | import java.io.Serializable; |
| 11 | +import java.util.List; | ||
| 11 | 12 | ||
| 12 | @Data | 13 | @Data |
| 13 | public class UpdatePurchaseOrderInfoVo implements BaseVo, Serializable { | 14 | public class UpdatePurchaseOrderInfoVo implements BaseVo, Serializable { |
| @@ -184,4 +185,10 @@ public class UpdatePurchaseOrderInfoVo implements BaseVo, Serializable { | @@ -184,4 +185,10 @@ public class UpdatePurchaseOrderInfoVo implements BaseVo, Serializable { | ||
| 184 | @ApiModelProperty("客户资信Id") | 185 | @ApiModelProperty("客户资信Id") |
| 185 | private String customerCreditId; | 186 | private String customerCreditId; |
| 186 | 187 | ||
| 188 | + /** | ||
| 189 | + * 订货单表物料行 | ||
| 190 | + */ | ||
| 191 | + @ApiModelProperty("订货单表物料行") | ||
| 192 | + private List<UpdatePurchaseOrderLineVo> updatePurchaseOrderLineVoList; | ||
| 193 | + | ||
| 187 | } | 194 | } |
| @@ -92,11 +92,11 @@ | @@ -92,11 +92,11 @@ | ||
| 92 | AND cu.name LIKE CONCAT('%', #{vo.orderingUnitName},'%') | 92 | AND cu.name LIKE CONCAT('%', #{vo.orderingUnitName},'%') |
| 93 | </if> | 93 | </if> |
| 94 | <if test="vo.orderDateStart != null"> | 94 | <if test="vo.orderDateStart != null"> |
| 95 | - AND tb.order_date >= #{vo.orderDate} | 95 | + AND tb.order_date >= #{vo.orderDateStart} |
| 96 | </if> | 96 | </if> |
| 97 | <if test="vo.orderDateEnd != null"> | 97 | <if test="vo.orderDateEnd != null"> |
| 98 | <![CDATA[ | 98 | <![CDATA[ |
| 99 | - AND tb.order_date <= #{vo.orderDate} | 99 | + AND tb.order_date <= #{vo.orderDateEnd} |
| 100 | ]]> | 100 | ]]> |
| 101 | </if> | 101 | </if> |
| 102 | <if test="vo.status != null and vo.status != ''"> | 102 | <if test="vo.status != null and vo.status != ''"> |
| @@ -114,4 +114,13 @@ | @@ -114,4 +114,13 @@ | ||
| 114 | </where> | 114 | </where> |
| 115 | ORDER BY tb.update_time DESC | 115 | ORDER BY tb.update_time DESC |
| 116 | </select> | 116 | </select> |
| 117 | + | ||
| 118 | + <select id="findById" resultType="com.lframework.xingyun.sc.entity.PurchaseOrderInfo"> | ||
| 119 | + <include refid="PurchaseOrderInfo_sql"/> | ||
| 120 | + <where> | ||
| 121 | + <if test="id != null and id != ''"> | ||
| 122 | + AND tb.id = #{id} | ||
| 123 | + </if> | ||
| 124 | + </where> | ||
| 125 | + </select> | ||
| 117 | </mapper> | 126 | </mapper> |