| | |
| | | spacerThickness: 0, |
| | | inWeight: 4000, |
| | | inMaxQuantity: 20, |
| | | inLenMin:350, |
| | | inLenMin:400, |
| | | inLenMax:3500, |
| | | inShortMax:2500, |
| | | inShortMin:350 |
| | | inShortMin:400 |
| | | }, |
| | | rules:{ |
| | | shelfThickness: [ |
| | |
| | | |
| | | import com.example.erp.common.Result; |
| | | import com.example.erp.entity.sd.Order; |
| | | import com.example.erp.service.mm.MaterialInventoryService; |
| | | import com.example.erp.service.sd.DeliveryService; |
| | | import com.example.erp.service.sd.OrderService; |
| | | import io.swagger.annotations.Api; |
| | |
| | | public class AppController { |
| | | private final OrderService orderService; |
| | | private final DeliveryService deliveryService; |
| | | private final MaterialInventoryService materialInventoryService; |
| | | |
| | | @ApiOperation("订单报表") |
| | | @PostMapping("/getOrderList") |
| | |
| | | public Result getDeliveryList(@RequestBody List<String> dates) { |
| | | return Result.success(deliveryService.appGetDeliveryList(dates)); |
| | | } |
| | | |
| | | @ApiOperation("原片库存报表") |
| | | @PostMapping("/getStockList") |
| | | public Result getStockList() { |
| | | |
| | | return Result.success(materialInventoryService.appGetStockList()); |
| | | } |
| | | } |
| | |
| | | Boolean updateMaterialInventoryAll(@Param("materialInventoryId") Long materialInventoryId,@Param("materialInventory") MaterialInventory materialInventory); |
| | | |
| | | Boolean updateMaterialInventoryOne(@Param("materialInventoryId") Long materialInventoryId,@Param("materialInventory") MaterialInventory materialInventory); |
| | | |
| | | List<MaterialInventory> selectGetStockList(); |
| | | } |
| | |
| | | |
| | | } |
| | | |
| | | public Object appGetStockList() { |
| | | List<MaterialInventory> materialInventoryList = materialInventoryMapper.selectGetStockList(); |
| | | Map<String, Object> totalSum = new HashMap<>(); |
| | | Integer inventoryQuantity = 0; |
| | | Integer availableQuantity = 0; |
| | | Double totalArea = 0.00; |
| | | for (MaterialInventory materialInventory : materialInventoryList) { |
| | | inventoryQuantity += materialInventory.getInventoryQuantity(); |
| | | availableQuantity += materialInventory.getAvailableQuantity(); |
| | | totalArea += materialInventory.getTotalArea(); |
| | | } |
| | | totalSum.put("inventoryQuantity",inventoryQuantity); |
| | | totalSum.put("availableQuantity",availableQuantity); |
| | | totalSum.put("totalArea",totalArea); |
| | | |
| | | |
| | | Map<String, Object> map = new HashMap<>(); |
| | | map.put("glassStock", materialInventoryList); |
| | | return map; |
| | | } |
| | | } |
| | |
| | | where id=#{materialInventoryId} |
| | | </update> |
| | | |
| | | <select id="selectGetStockList"> |
| | | select * from mm.material_inventory |
| | | where inventory_quantity>0 |
| | | </select> |
| | | |
| | | </mapper> |