a.del_flag = 1 and a.level = 1 and b.status in (9, 12, 13) and b.top_organization_id = #{topOrganizationId} and b.warehouse_id = #{warehouseId} and b.warehouse_name like concat('%', #{warehouseName}, '%') and b.customer_name like concat('%', #{customerName}, '%') and b.shipper_name like concat('%', #{shipperName}, '%') and b.line_code like concat('%', #{lineCode}, '%') and b.line_name like concat('%', #{lineName}, '%') and date_format(b.create_time,'%Y-%m-%d') >= #{createTimeStart} and date_format(b.create_time,'%Y-%m-%d') <= #{createTimeEnd} from out_material_detail a join stock_out_order b on a.out_order_number = b.out_order_number and b.del_flag = 1