| | |
| | | import org.springframework.web.bind.annotation.RequestParam; |
| | | import org.springframework.web.bind.annotation.RestController; |
| | | |
| | | import javax.servlet.http.HttpServletRequest; |
| | | import javax.servlet.http.HttpServletResponse; |
| | | |
| | | @Api(tags = "产品管理") |
| | | @RestController |
| | | @RequestMapping("product") |
| | |
| | | public Response getProductVersion( @RequestParam String parentModel, String customCode){ |
| | | return historyService.getProductVersion(parentModel,customCode); |
| | | } |
| | | @ApiOperation(value = "根据产品id查询子件及其关联的物料信息",notes = "8.17修改后使用") |
| | | @ApiOperation(value = "根据产品id和版本查询子件及其关联的物料信息",notes = "8.17修改后使用") |
| | | @GetMapping("getBomAndMaterial") |
| | | public Response getBomAndMaterial( @RequestParam int productId){ |
| | | return bomService.getBomAndMaterial(productId); |
| | | public Response getBomAndMaterial( @RequestParam int productId, @RequestParam int version){ |
| | | return bomService.getBomAndMaterial(productId,version); |
| | | } |
| | | @ApiOperation(value = "产品下载(产品id和版本)",notes = "8.17修改后使用") |
| | | @GetMapping("downloadProduct") |
| | | public void downloadProduct(HttpServletRequest req, HttpServletResponse resp, @RequestParam int productId, @RequestParam int version){ |
| | | bomService.downloadProduct(req,resp,productId,version); |
| | | } |
| | | } |