| 
					
				 | 
			
			
				@ -194,48 +194,48 @@ public class TextSearchEndPoint extends EnvelopRestEndPoint { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                        continue; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                    } else { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                        start = ch; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                        otherString = keys.substring(i+1,keys.length()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                        otherString = keys.substring(i + 1, keys.length()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                    } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                //以"开头  ,查找后面是否有 " ,有则截取 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                if ("\"".equals(start)){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                    int fhIndex = otherString.indexOf("\""); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                    if (fhIndex > -1){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                        temp = keys.substring(i+1,i+fhIndex+1); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                        temp = keys.substring(i + 1, i + fhIndex + 1); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                        if (!"or".equalsIgnoreCase(preString)){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                            q = builderAndQuery(temp,q); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                            q = builderAndQuery(temp, q); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                        } else { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                            q = builderOrQuery(temp,q); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                            q = builderOrQuery(temp, q); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                        } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                        i = fhIndex+i+1; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                        i = fhIndex + i + 1; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                        start = ""; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                        preString = temp; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                    } else { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                        int kgIndex = otherString.indexOf(" "); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                        if (kgIndex > -1){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                            temp = keys.substring(i,i+kgIndex+1); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                            temp = keys.substring(i, i + kgIndex + 1); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                            if (!"or".equalsIgnoreCase(preString)){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                q = builderAndQuery(temp,q); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                q = builderAndQuery(temp, q); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                            } else { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                q = builderOrQuery(temp,q); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                q = builderOrQuery(temp, q); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                            } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                            i = kgIndex+i+1; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                            i = kgIndex + i + 1; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                            start = ""; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                            preString = temp; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                        } else { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                            temp = start+otherString; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                            if (!"or".equalsIgnoreCase(preString)){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                q = builderAndQuery(temp,q); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                q = builderAndQuery(temp, q); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                            } else { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                q = builderOrQuery(temp,q); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                q = builderOrQuery(temp, q); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                            } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                            i= keys.length(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                            i = keys.length(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                        } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                    } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                } else { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                    int kgIndex = otherString.indexOf(" "); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                    if (kgIndex > -1){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                        temp = keys.substring(i,i+kgIndex+1); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                        temp = keys.substring(i, i + kgIndex + 1); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                        if (!"and".equalsIgnoreCase(temp) &&  !"or".equalsIgnoreCase(temp)){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                            if (!"or".equalsIgnoreCase(preString)){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                q = builderAndQuery(temp,q); 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@ -243,7 +243,7 @@ public class TextSearchEndPoint extends EnvelopRestEndPoint { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                q = builderOrQuery(temp,q); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                            } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                        } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                        i=kgIndex+i+1; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                        i = kgIndex + i + 1; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                        start = ""; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                        preString = temp; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                    } else { 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@ -284,9 +284,9 @@ public class TextSearchEndPoint extends EnvelopRestEndPoint { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                substring = ClientUtils.escapeQueryChars(substring); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                if (StringUtils.isNotBlank(substring)){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                    if (StringUtils.isBlank(q)){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                        q += ResourceCells.SEARCH_FIELD + ":" + temp.substring(1,temp.length()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                        q += ResourceCells.SEARCH_FIELD + ":" + temp.substring(1, temp.length()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                    } else { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                        q +=" AND " + ResourceCells.SEARCH_FIELD + ":" + temp.substring(1,temp.length()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                        q += " AND " + ResourceCells.SEARCH_FIELD + ":" + temp.substring(1, temp.length()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                    } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				            } else { 
			 |