Browse Source

PropertyValue实体删除与索引无关的字段

sunyj 9 years ago
parent
commit
33d9f16747

+ 0 - 32
search-console/src/main/java/com/uas/search/console/model/PropertyValue.java

@@ -2,12 +2,9 @@ package com.uas.search.console.model;
 
 import java.io.Serializable;
 
-import javax.persistence.CascadeType;
 import javax.persistence.Column;
 import javax.persistence.Entity;
 import javax.persistence.Id;
-import javax.persistence.JoinColumn;
-import javax.persistence.OneToOne;
 import javax.persistence.Table;
 
 /**
@@ -32,25 +29,12 @@ public class PropertyValue implements Serializable {
 	@Column(name = "pv_id")
 	private Long id;
 
-	/**
-	 * 器件Id
-	 */
-	@Column(name = "pv_componentid")
-	private Long componentid;
-
 	/**
 	 * 属性Id
 	 */
 	@Column(name = "pv_propertyid")
 	private Long propertyid;
 
-	/**
-	 * 属性
-	 */
-	@OneToOne(cascade = { CascadeType.REFRESH })
-	@JoinColumn(name = "pv_propertyid", insertable = false, updatable = false)
-	private Property property;
-
 	/**
 	 * 排序
 	 */
@@ -71,22 +55,6 @@ public class PropertyValue implements Serializable {
 		this.id = id;
 	}
 
-	public Long getComponentid() {
-		return componentid;
-	}
-
-	public void setComponentid(Long componentid) {
-		this.componentid = componentid;
-	}
-
-	public Property getProperty() {
-		return property;
-	}
-
-	public void setProperty(Property property) {
-		this.property = property;
-	}
-
 	public Short getDetno() {
 		return detno;
 	}

+ 0 - 3
search-console/src/main/java/com/uas/search/console/service/impl/IndexServiceImpl.java

@@ -138,7 +138,6 @@ public class IndexServiceImpl implements IndexService {
 			return 0L;
 
 		for (KindSimpleInfo kind : kinds) {
-			logger.info(kind);
 			Document document = toDocument(kind);
 			if (document != null)
 				indexWriter.addDocument(document);
@@ -160,7 +159,6 @@ public class IndexServiceImpl implements IndexService {
 			return 0L;
 
 		for (BrandSimpleInfo brand : brands) {
-			logger.info(brand);
 			Document document = toDocument(brand);
 			if (document != null) {
 				indexWriter.addDocument(document);
@@ -233,7 +231,6 @@ public class IndexServiceImpl implements IndexService {
 		while (totalElements > size) {
 			List<ComponentSimpleInfo> components = pageResult.getContent();
 			for (ComponentSimpleInfo component : components) {
-				logger.info(component);
 				Document document = toDocument(component);
 				if (document != null) {
 					indexWriter.addDocument(document);