瀏覽代碼

修改bug

lwhhszx 2 年之前
父節點
當前提交
75605c8dad

+ 4 - 1
PAS/src/main/java/cn/cslg/pas/common/utils/PatentRightUtils.java

@@ -168,7 +168,10 @@ public class PatentRightUtils {
             //英文专利的权要拆分 ↓
         } else {
             content = content.substring(content.indexOf("1."));
-            if (contentOut.contains("1.")) {
+            if(contentOut.equals("")){
+                contentOut="";
+            }
+           else if (contentOut.contains("1.")) {
                 contentOut = contentOut.substring(contentOut.indexOf("1."));
             } else {
                 contentOut = contentOut.substring(contentOut.indexOf("1、"));

+ 4 - 6
PAS/src/main/resources/mapper/AssoProductPatentMapper.xml

@@ -104,10 +104,10 @@
     </select>
 
     <select id="getPatentNos" resultType="java.lang.String">
-        select DISTINCT a.patentno as patent_no
+        select  a.patentno as patent_no
         from os_patent a
         left join asso_product_patent i on i.patent_no=a.patentno
-        left join asso_structure_patent t on t.patent_no =a.patentno
+        and i.product_id =#{params.productId}
         <if test="params.applicationName !=null ">
             left join os_applicant_attr b on a.id=b.pid and b.type =1
             left join os_patent_applicant c on c.id=b.applicantid
@@ -155,11 +155,10 @@
                 and a.`name` like concat("%", #{params.patentName}, "%")
             </if>
             <if test="params.isIn ==0">
-                and (i.product_id !=#{params.productId} or i.product_id is null)
-                and (t.product_id !=#{params.productId} or t.product_id is null)
+                and (i.product_id is null)
             </if>
             <if test="params.isIn !=0">
-                and (i.product_id =#{params.productId} or t.product_id =#{params.productId})
+                and (i.product_id =#{params.productId})
             </if>
             <if test="params.orderItem!=null and params.orderItem!='SysOrder'">
                 order by #{params.orderItem}
@@ -181,7 +180,6 @@
                 limit #{params.startNumber},#{params.endNumber}
             </if>
         </where>
-
     </select>
 
     <!--插入数据-->