| | |
| | | package com.vincent.rsf.server.api.controller; |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; |
| | | import com.vincent.rsf.framework.common.R; |
| | | import com.vincent.rsf.framework.exception.CoolException; |
| | | import com.vincent.rsf.server.api.controller.params.CheckObjParams; |
| | | import com.vincent.rsf.server.api.controller.params.OtherReceiptParams; |
| | | import com.vincent.rsf.server.api.controller.params.ReceiptParams; |
| | | import com.vincent.rsf.server.api.controller.params.*; |
| | | import com.vincent.rsf.server.api.service.MobileService; |
| | | import com.vincent.rsf.server.manager.controller.params.WaitPakinParam; |
| | | import com.vincent.rsf.server.manager.entity.AsnOrderItem; |
| | | import com.vincent.rsf.server.manager.entity.QlyIsptItem; |
| | | import com.vincent.rsf.server.system.controller.BaseController; |
| | | import com.vincent.rsf.server.system.controller.param.LoginParam; |
| | |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import javax.servlet.http.HttpServletRequest; |
| | | import java.util.Map; |
| | | import java.util.Objects; |
| | | |
| | | /** |
| | |
| | | @PreAuthorize("hasAuthority('manager:warehouseAreas:save')") |
| | | @PostMapping("/orders/confirm") |
| | | @ApiOperation("确认收货") |
| | | public R confirmReceipt(@RequestBody ReceiptParams params) { |
| | | public R confirmReceipt(@RequestBody Map<String, Object> params) { |
| | | if (Objects.isNull(params)) { |
| | | throw new CoolException("请求参数不能为空!!"); |
| | | } |
| | |
| | | @PostMapping("/inspect/check/update") |
| | | public R checkUpdate(@RequestBody QlyIsptItem params) { |
| | | if (Objects.isNull(params)) { |
| | | throw new CoolException("参数不能为空!!"); |
| | | return R.error("参数不能为空!!"); |
| | | } |
| | | return mobileService.checkUpdate(params); |
| | | } |
| | | |
| | | @ApiOperation("获取上架信息") |
| | | @PreAuthorize("hasAuthority('manager:qlyInspect:list')") |
| | | @PostMapping("/stock/operate/list") |
| | | public R operateToStock(@RequestBody OpStockParams params) { |
| | | if (Objects.isNull(params)) { |
| | | return R.error("参数不能为空!!"); |
| | | } |
| | | return mobileService.operateToStock(params); |
| | | } |
| | | |
| | | @ApiOperation("人工上架") |
| | | @PreAuthorize("hasAuthority('manager:qlyInspect:update')") |
| | | @PostMapping("/stock/operate") |
| | | public R publicToStock(@RequestBody PublicToStockParams params) { |
| | | if (Objects.isNull(params)) { |
| | | return R.error("参数不能为空!!"); |
| | | } |
| | | return mobileService.publicToStock(params, getLoginUserId()); |
| | | } |
| | | |
| | | @ApiOperation("获取任务信息") |
| | | @PreAuthorize("hasAuthority('manager:qlyInspect:list')") |
| | | @PostMapping("/task/stock/{code}") |
| | | public R taskToStock(@PathVariable String code) { |
| | | if (Objects.isNull(code)) { |
| | | return R.error("参数不能为空!!"); |
| | | } |
| | | return mobileService.taskToStock(code); |
| | | } |
| | | |
| | | @ApiOperation("任务上架") |
| | | @PreAuthorize("hasAuthority('manager:qlyInspect:update')") |
| | | @PostMapping("/task/public/{code}") |
| | | public R taskToLocs(@PathVariable String code) throws Exception { |
| | | if (Objects.isNull(code)) { |
| | | return R.error("参数不能为空!!"); |
| | | } |
| | | return mobileService.taskGetLocs(code); |
| | | } |
| | | |
| | | @ApiOperation("一键收货") |
| | | @PostMapping("/complete/{id}") |
| | | @PreAuthorize("hasAuthority('manager:asnOrder:update')") |
| | | public R completeOrder(@PathVariable Long id) { |
| | | if (Objects.isNull(id)) { |
| | | return R.error("参数不能为空!!"); |
| | | } |
| | | return mobileService.completeOrder(id, getLoginUserId()); |
| | | } |
| | | |
| | | } |