|  |  | @ -131,15 +131,6 @@ | 
			
		
	
		
		
			
				
					
					|  |  |  |         select * |  |  |  |         select * | 
			
		
	
		
		
			
				
					
					|  |  |  |         from inv_product |  |  |  |         from inv_product | 
			
		
	
		
		
			
				
					
					|  |  |  |         <where> |  |  |  |         <where> | 
			
		
	
		
		
			
				
					
					|  |  |  | <!--            <if test="code != null and code != ''">--> |  |  |  |  | 
			
		
	
		
		
			
				
					
					|  |  |  | <!--                AND code like concat('%', #{code}, '%')--> |  |  |  |  | 
			
		
	
		
		
			
				
					
					|  |  |  | <!--            </if>--> |  |  |  |  | 
			
		
	
		
		
			
				
					
					|  |  |  | <!--            <if test="mainAction != null and mainAction != ''">--> |  |  |  |  | 
			
		
	
		
		
			
				
					
					|  |  |  | <!--                AND mainAction = #{mainAction}--> |  |  |  |  | 
			
		
	
		
		
			
				
					
					|  |  |  | <!--            </if>--> |  |  |  |  | 
			
		
	
		
		
			
				
					
					|  |  |  | <!--            <if test="action != null and action != ''">--> |  |  |  |  | 
			
		
	
		
		
			
				
					
					|  |  |  | <!--                AND action = #{action}--> |  |  |  |  | 
			
		
	
		
		
			
				
					
					|  |  |  | <!--            </if>--> |  |  |  |  | 
			
		
	
		
		
			
				
					
					|  |  |  |             <if test="supId != null and supId != ''"> |  |  |  |             <if test="supId != null and supId != ''"> | 
			
		
	
		
		
			
				
					
					|  |  |  |                 and supId = #{supId} |  |  |  |                 and supId = #{supId} | 
			
		
	
		
		
			
				
					
					|  |  |  |             </if> |  |  |  |             </if> | 
			
		
	
	
		
		
			
				
					|  |  | @ -149,9 +140,6 @@ | 
			
		
	
		
		
			
				
					
					|  |  |  |             <if test="nameCode != null and nameCode != ''"> |  |  |  |             <if test="nameCode != null and nameCode != ''"> | 
			
		
	
		
		
			
				
					
					|  |  |  |                 AND nameCode like concat('%', #{nameCode}, '%') |  |  |  |                 AND nameCode like concat('%', #{nameCode}, '%') | 
			
		
	
		
		
			
				
					
					|  |  |  |             </if> |  |  |  |             </if> | 
			
		
	
		
		
			
				
					
					|  |  |  | <!--            <if test="orderId != null and orderId != ''">--> |  |  |  |  | 
			
		
	
		
		
			
				
					
					|  |  |  | <!--                AND orderId = #{orderId}--> |  |  |  |  | 
			
		
	
		
		
			
				
					
					|  |  |  | <!--            </if>--> |  |  |  |  | 
			
		
	
		
		
			
				
					
					|  |  |  |             <if test="deptCode != null and deptCode != ''"> |  |  |  |             <if test="deptCode != null and deptCode != ''"> | 
			
		
	
		
		
			
				
					
					|  |  |  |                 AND deptCode = #{deptCode} |  |  |  |                 AND deptCode = #{deptCode} | 
			
		
	
		
		
			
				
					
					|  |  |  |             </if> |  |  |  |             </if> | 
			
		
	
	
		
		
			
				
					|  |  | @ -300,17 +288,24 @@ | 
			
		
	
		
		
			
				
					
					|  |  |  |     </select> |  |  |  |     </select> | 
			
		
	
		
		
			
				
					
					|  |  |  | 
 |  |  |  | 
 | 
			
		
	
		
		
			
				
					
					|  |  |  |     <select id="getInvPlaceOrderList" resultType="com.glxp.api.res.inout.IoOrderResponse"> |  |  |  |     <select id="getInvPlaceOrderList" resultType="com.glxp.api.res.inout.IoOrderResponse"> | 
			
		
	
		
		
			
				
					
					|  |  |  |         select odr.orderIdFk                                                     billNo, |  |  |  |         SELECT | 
			
				
				
			
		
	
		
		
			
				
					
					|  |  |  |                (select name from basic_bussiness_type where action = o.action) billTypeName, |  |  |  |         odr.orderIdFk AS billNo, | 
			
				
				
			
		
	
		
		
	
		
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  |         bbt.NAME AS billTypeName, | 
			
		
	
		
		
			
				
					
					|  |  |  |         o.mainAction, |  |  |  |         o.mainAction, | 
			
		
	
		
		
			
				
					
					|  |  |  |         o.fromCorp, |  |  |  |         o.fromCorp, | 
			
		
	
		
		
			
				
					
					|  |  |  |         o.corpOrderId, |  |  |  |         o.corpOrderId, | 
			
		
	
		
		
			
				
					
					|  |  |  |         o.fromType, |  |  |  |         o.fromType, | 
			
		
	
		
		
			
				
					
					|  |  |  |         o.createTime, |  |  |  |         o.createTime, | 
			
		
	
		
		
			
				
					
					|  |  |  |         o.auditTime, |  |  |  |         o.auditTime, | 
			
		
	
		
		
			
				
					
					|  |  |  |                (select employeeName from auth_user where id = o.reviewUser)    reviewUserName |  |  |  |         au.employeeName AS reviewUserName | 
			
				
				
			
		
	
		
		
			
				
					
					|  |  |  |         from io_order_detail_biz odr |  |  |  |         FROM | 
			
				
				
			
		
	
		
		
			
				
					
					|  |  |  |         left join io_order o on o.billNo = odr.orderIdFk |  |  |  |         io_order_detail_biz odr | 
			
				
				
			
		
	
		
		
	
		
		
	
		
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  |         LEFT JOIN | 
			
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  |         io_order o ON o.billNo = odr.orderIdFk | 
			
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  |         LEFT JOIN | 
			
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  |         basic_bussiness_type bbt ON bbt.action = o.action | 
			
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  |         LEFT JOIN | 
			
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  |         auth_user au ON au.id = o.reviewUser | 
			
		
	
		
		
			
				
					
					|  |  |  | 
 |  |  |  | 
 | 
			
		
	
		
		
			
				
					
					|  |  |  |         <where> |  |  |  |         <where> | 
			
		
	
		
		
			
				
					
					|  |  |  |             <if test="invCode != null and invCode != ''"> |  |  |  |             <if test="invCode != null and invCode != ''"> | 
			
		
	
	
		
		
			
				
					|  |  | @ -331,34 +326,37 @@ | 
			
		
	
		
		
			
				
					
					|  |  |  |     </select> |  |  |  |     </select> | 
			
		
	
		
		
			
				
					
					|  |  |  | 
 |  |  |  | 
 | 
			
		
	
		
		
			
				
					
					|  |  |  |     <select id="filterSpaceList" resultType="com.glxp.api.res.inv.InvPlaceDetailResponse"> |  |  |  |     <select id="filterSpaceList" resultType="com.glxp.api.res.inv.InvPlaceDetailResponse"> | 
			
		
	
		
		
			
				
					
					|  |  |  |         SELECT t1.nameCode, |  |  |  |         SELECT | 
			
				
				
			
		
	
		
		
			
				
					
					|  |  |  |                t1.relIdFk as relId, |  |  |  |         t1.nameCode, | 
			
				
				
			
		
	
		
		
			
				
					
					|  |  |  |                (SELECT NAME FROM auth_dept WHERE auth_dept.`code` = t1.deptCode)          AS deptName, |  |  |  |         t1.relIdFk AS relId, | 
			
				
				
			
		
	
		
		
			
				
					
					|  |  |  |                (SELECT NAME FROM auth_warehouse WHERE auth_warehouse.`code` = t1.invCode) AS invName, |  |  |  |         dept.NAME AS deptName, | 
			
				
				
			
		
	
		
		
			
				
					
					|  |  |  |                (SELECT NAME FROM auth_space WHERE auth_space.`code` = t1.invSpaceCode)    AS invSpaceName, |  |  |  |         warehouse.NAME AS invName, | 
			
				
				
			
		
	
		
		
			
				
					
					|  |  |  |                 <include refid="inOrOutcount"/>                                           as count, |  |  |  |         space.NAME AS invSpaceName, | 
			
				
				
			
		
	
		
		
			
				
					
					|  |  |  |                bp.cpmctymc                                                                as productName, |  |  |  |         <include refid="inOrOutcount"/> AS count, | 
			
				
				
			
		
	
		
		
	
		
		
	
		
		
	
		
		
	
		
		
	
		
		
	
		
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  |         bp.cpmctymc AS productName, | 
			
		
	
		
		
			
				
					
					|  |  |  |         bp.ggxh, |  |  |  |         bp.ggxh, | 
			
		
	
		
		
			
				
					
					|  |  |  |         t1.batchNo, |  |  |  |         t1.batchNo, | 
			
		
	
		
		
			
				
					
					|  |  |  |                t1.productionDate as produceDate                                                             as productionDate, |  |  |  |         t1.productionDate AS produceDate, | 
			
				
				
			
		
	
		
		
	
		
		
			
				
					
					|  |  |  |         t1.expireDate, |  |  |  |         t1.expireDate, | 
			
		
	
		
		
			
				
					
					|  |  |  |         bp.measname, |  |  |  |         bp.measname, | 
			
		
	
		
		
			
				
					
					|  |  |  |         bp.zczbhhzbapzbh, |  |  |  |         bp.zczbhhzbapzbh, | 
			
		
	
		
		
			
				
					
					|  |  |  |         bp.ylqxzcrbarmc, |  |  |  |         bp.ylqxzcrbarmc, | 
			
		
	
		
		
			
				
					
					|  |  |  |         bp.manufactory, |  |  |  |         bp.manufactory, | 
			
		
	
		
		
			
				
					
					|  |  |  |                (SELECT `name` FROM basic_corp WHERE erpId = t1.supId)                        supName |  |  |  |         corp.name AS supName | 
			
				
				
			
		
	
		
		
			
				
					
					|  |  |  |         FROM inv_product t1 |  |  |  |         FROM | 
			
				
				
			
		
	
		
		
	
		
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  |         inv_product t1 | 
			
		
	
		
		
			
				
					
					|  |  |  |         LEFT JOIN basic_udirel bu ON bu.id = t1.relIdFk |  |  |  |         LEFT JOIN basic_udirel bu ON bu.id = t1.relIdFk | 
			
		
	
		
		
			
				
					
					|  |  |  |         LEFT JOIN basic_products bp ON bp.uuid = bu.uuid |  |  |  |         LEFT JOIN basic_products bp ON bp.uuid = bu.uuid | 
			
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  |         LEFT JOIN auth_dept dept ON dept.code = t1.deptCode | 
			
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  |         LEFT JOIN auth_warehouse warehouse ON warehouse.code = t1.invCode | 
			
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  |         LEFT JOIN auth_space space ON space.code = t1.invSpaceCode | 
			
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  |         LEFT JOIN basic_corp corp ON corp.erpId = t1.supId | 
			
		
	
		
		
			
				
					
					|  |  |  |         <where> |  |  |  |         <where> | 
			
		
	
		
		
			
				
					
					|  |  |  | <!--            <if test="code != null and code != ''">--> |  |  |  |  | 
			
		
	
		
		
			
				
					
					|  |  |  | <!--                AND t1.code = #{code}--> |  |  |  |  | 
			
		
	
		
		
			
				
					
					|  |  |  | <!--            </if>--> |  |  |  |  | 
			
		
	
		
		
			
				
					
					|  |  |  |             <if test="invSpaceCode != null and invSpaceCode != ''"> |  |  |  |             <if test="invSpaceCode != null and invSpaceCode != ''"> | 
			
		
	
		
		
			
				
					
					|  |  |  |                 AND t1.invSpaceCode = #{invSpaceCode} |  |  |  |                 AND t1.invSpaceCode = #{invSpaceCode} | 
			
		
	
		
		
			
				
					
					|  |  |  |             </if> |  |  |  |             </if> | 
			
		
	
		
		
			
				
					
					|  |  |  |         </where> |  |  |  |         </where> | 
			
		
	
		
		
			
				
					
					|  |  |  |         GROUP BY invSpaceCode |  |  |  |         GROUP BY t1.invSpaceCode | 
			
				
				
			
		
	
		
		
	
		
		
			
				
					
					|  |  |  |     </select> |  |  |  |     </select> | 
			
		
	
		
		
			
				
					
					|  |  |  | 
 |  |  |  | 
 | 
			
		
	
		
		
			
				
					
					|  |  |  | 
 |  |  |  | 
 | 
			
		
	
	
		
		
			
				
					|  |  | @ -372,9 +370,6 @@ | 
			
		
	
		
		
			
				
					
					|  |  |  |             <if test="invCode != null and invCode != ''"> |  |  |  |             <if test="invCode != null and invCode != ''"> | 
			
		
	
		
		
			
				
					
					|  |  |  |                 AND invCode = #{invCode} |  |  |  |                 AND invCode = #{invCode} | 
			
		
	
		
		
			
				
					
					|  |  |  |             </if> |  |  |  |             </if> | 
			
		
	
		
		
			
				
					
					|  |  |  | <!--            <if test="mainAction != null and mainAction != ''">--> |  |  |  |  | 
			
		
	
		
		
			
				
					
					|  |  |  | <!--                AND mainAction = #{mainAction}--> |  |  |  |  | 
			
		
	
		
		
			
				
					
					|  |  |  | <!--            </if>--> |  |  |  |  | 
			
		
	
		
		
			
				
					
					|  |  |  |             <if test="batchNo != null and batchNo != ''"> |  |  |  |             <if test="batchNo != null and batchNo != ''"> | 
			
		
	
		
		
			
				
					
					|  |  |  |                 AND batchNo = #{batchNo} |  |  |  |                 AND batchNo = #{batchNo} | 
			
		
	
		
		
			
				
					
					|  |  |  |             </if> |  |  |  |             </if> | 
			
		
	
	
		
		
			
				
					|  |  | @ -395,9 +390,6 @@ | 
			
		
	
		
		
			
				
					
					|  |  |  |             <if test="invCode != null and invCode != ''"> |  |  |  |             <if test="invCode != null and invCode != ''"> | 
			
		
	
		
		
			
				
					
					|  |  |  |                 AND invCode = #{invCode} |  |  |  |                 AND invCode = #{invCode} | 
			
		
	
		
		
			
				
					
					|  |  |  |             </if> |  |  |  |             </if> | 
			
		
	
		
		
			
				
					
					|  |  |  | <!--            <if test="mainAction != null and mainAction != ''">--> |  |  |  |  | 
			
		
	
		
		
			
				
					
					|  |  |  | <!--                AND mainAction = #{mainAction}--> |  |  |  |  | 
			
		
	
		
		
			
				
					
					|  |  |  | <!--            </if>--> |  |  |  |  | 
			
		
	
		
		
			
				
					
					|  |  |  |             <if test="batchNo != null and batchNo != ''"> |  |  |  |             <if test="batchNo != null and batchNo != ''"> | 
			
		
	
		
		
			
				
					
					|  |  |  |                 AND batchNo = #{batchNo} |  |  |  |                 AND batchNo = #{batchNo} | 
			
		
	
		
		
			
				
					
					|  |  |  |             </if> |  |  |  |             </if> | 
			
		
	
	
		
		
			
				
					|  |  | @ -424,9 +416,6 @@ | 
			
		
	
		
		
			
				
					
					|  |  |  |             <if test="inBatchNo != null and inBatchNo != ''"> |  |  |  |             <if test="inBatchNo != null and inBatchNo != ''"> | 
			
		
	
		
		
			
				
					
					|  |  |  |                 AND inBatchNo = #{inBatchNo} |  |  |  |                 AND inBatchNo = #{inBatchNo} | 
			
		
	
		
		
			
				
					
					|  |  |  |             </if> |  |  |  |             </if> | 
			
		
	
		
		
			
				
					
					|  |  |  | <!--            <if test="mainAction != null and mainAction != ''">--> |  |  |  |  | 
			
		
	
		
		
			
				
					
					|  |  |  | <!--                AND mainAction = #{mainAction}--> |  |  |  |  | 
			
		
	
		
		
			
				
					
					|  |  |  | <!--            </if>--> |  |  |  |  | 
			
		
	
		
		
			
				
					
					|  |  |  |             <if test="batchNo != null and batchNo != ''"> |  |  |  |             <if test="batchNo != null and batchNo != ''"> | 
			
		
	
		
		
			
				
					
					|  |  |  |                 AND batchNo = #{batchNo} |  |  |  |                 AND batchNo = #{batchNo} | 
			
		
	
		
		
			
				
					
					|  |  |  |             </if> |  |  |  |             </if> | 
			
		
	
	
		
		
			
				
					|  |  | @ -448,9 +437,6 @@ | 
			
		
	
		
		
			
				
					
					|  |  |  |             <if test="invCode != null and invCode != ''"> |  |  |  |             <if test="invCode != null and invCode != ''"> | 
			
		
	
		
		
			
				
					
					|  |  |  |                 AND invCode = #{invCode} |  |  |  |                 AND invCode = #{invCode} | 
			
		
	
		
		
			
				
					
					|  |  |  |             </if> |  |  |  |             </if> | 
			
		
	
		
		
			
				
					
					|  |  |  | <!--            <if test="mainAction != null and mainAction != ''">--> |  |  |  |  | 
			
		
	
		
		
			
				
					
					|  |  |  | <!--                AND mainAction = #{mainAction}--> |  |  |  |  | 
			
		
	
		
		
			
				
					
					|  |  |  | <!--            </if>--> |  |  |  |  | 
			
		
	
		
		
			
				
					
					|  |  |  |             <if test="batchNo != null and batchNo != ''"> |  |  |  |             <if test="batchNo != null and batchNo != ''"> | 
			
		
	
		
		
			
				
					
					|  |  |  |                 AND batchNo = #{batchNo} |  |  |  |                 AND batchNo = #{batchNo} | 
			
		
	
		
		
			
				
					
					|  |  |  |             </if> |  |  |  |             </if> | 
			
		
	
	
		
		
			
				
					|  |  | 
 |