| | |
| | | public void downloadBom(HttpServletRequest req, HttpServletResponse resp,@RequestParam String parentModel){ |
| | | service.downloadBom(req,resp,parentModel); |
| | | } |
| | | @ApiOperation(tags = "散装件管理",value = "查询所有产品中没有与指定散装件关联的子件") |
| | | @GetMapping("getAllSubWithOutComponent") |
| | | public Response getAllSubWithOutComponent(@RequestParam int componentId){ |
| | | return service.getAllSubWithOutComponent(componentId); |
| | | } |
| | | |
| | | } |
| | |
| | | |
| | | void updateUrl(List<ProductBomApproving> fileBomApprovingList); |
| | | |
| | | //查询所有产品中没有与指定散装件关联的子件 |
| | | List<ProductBom> getAllSubWithOutComponent(int componentId); |
| | | } |
| | |
| | | e.printStackTrace(); |
| | | } |
| | | } |
| | | //查询所有产品中没有与指定散装件关联的子件 |
| | | public Response getAllSubWithOutComponent(int componentId) { |
| | | List<ProductBom> list=mapper.getAllSubWithOutComponent(componentId); |
| | | return new Response().setII(1,list.size()>0?true:false,list,"返回数据"); |
| | | } |
| | | } |
New file |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="com.whyc.mapper.ComponentMapper"> |
| | | |
| | | |
| | | </mapper> |
New file |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="com.whyc.mapper.ComponentProductMapper"> |
| | | |
| | | |
| | | </mapper> |
| | |
| | | |
| | | </where> |
| | | </select> |
| | | <select id="getAllSubWithOutComponent" resultType="com.whyc.pojo.ProductBom"> |
| | | select * from db_doc.tb_product_bom b where (select count(1) as num from db_doc.tb_component_product c |
| | | where b.parent_model= c.parent_model and b.sub_name= c.sub_name and c.component_id=#{componentId} ) = 0 |
| | | </select> |
| | | </mapper> |