| | |
| | | import com.dy.common.webUtil.BaseResponseUtils; |
| | | import com.dy.common.webUtil.QueryResultVo; |
| | | import com.dy.pmsGlobal.aop.Log; |
| | | import com.dy.pmsGlobal.pojoPlt.PltProduct; |
| | | import com.dy.pmsGlobal.pojoPr.PrAssemblyPlan; |
| | | import com.dy.pmsGlobal.pojoPr.PrOrder; |
| | | import com.dy.pmsProduct.taskPlan.QueryVo; |
| | | import com.dy.pmsProduct.order.QueryVo; |
| | | import jakarta.validation.Valid; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | |
| | | @SsoPowerAop(power = "10200001") |
| | | @Log("保存订单信息") |
| | | public BaseResponse<Boolean> save(@RequestBody @Valid PrOrder order){ |
| | | order.id = null; |
| | | order.setDeleted(false); |
| | | int count = sv.save(order); |
| | | if (count <= 0) { |
| | | return BaseResponseUtils.buildFail("数据库存储失败"); |
| | |
| | | return BaseResponseUtils.buildSuccess(list); |
| | | } |
| | | |
| | | /** |
| | | * 查询所有订单 |
| | | * @return |
| | | */ |
| | | @GetMapping(path="all") |
| | | @SsoPowerAop(power = "10300000") |
| | | @Log("查询所有产品") |
| | | public BaseResponse<List<PrOrder>> all(){ |
| | | QueryVo vo = new QueryVo(); |
| | | return BaseResponseUtils.buildSuccess(sv.selectAll(vo)); |
| | | } |
| | | |
| | | @PostMapping(path="updateStatus") |
| | | @SsoPowerAop(power = "10200001") |
| | | @Log("更新任务计划状态") |
| | | public BaseResponse<Boolean> updateStatus(@RequestBody PrAssemblyPlan plan){ |
| | | int count = sv.updateStatus(plan); |
| | | int count = 0;//sv.updateStatus(plan); |
| | | if (count <= 0) { |
| | | return BaseResponseUtils.buildFail("数据库存储失败"); |
| | | } else { |