|
|
@@ -23,7 +23,9 @@ import com.uas.search.console.b2b.model.MakeOrderChangeItemSimpleInfo;
|
|
|
import com.uas.search.console.b2b.model.MakeOrderSimpleInfo;
|
|
|
import com.uas.search.console.b2b.model.MakeReturnSimpleInfo;
|
|
|
import com.uas.search.console.b2b.model.PagingReleaseDetailSimpleInfo;
|
|
|
+import com.uas.search.console.b2b.model.ProdNonStandardSimpleInfo;
|
|
|
import com.uas.search.console.b2b.model.ProdSimpleInfo;
|
|
|
+import com.uas.search.console.b2b.model.ProdStandardSimpleInfo;
|
|
|
import com.uas.search.console.b2b.model.ProductBrandSimpleInfo;
|
|
|
import com.uas.search.console.b2b.model.ProductComponentSimpleInfo;
|
|
|
import com.uas.search.console.b2b.model.PurcInquiryItemSimpleInfo2;
|
|
|
@@ -146,6 +148,10 @@ public class ObjectToDocumentUtils {
|
|
|
return toDocument((InvitationRecordSimpleInfo) object);
|
|
|
} else if (object instanceof ErpSaleTenderSimpleInfo) {
|
|
|
return toDocument((ErpSaleTenderSimpleInfo) object);
|
|
|
+ } else if (object instanceof ProdStandardSimpleInfo) {
|
|
|
+ return toDocument((ProdStandardSimpleInfo) object);
|
|
|
+ } else if (object instanceof ProdNonStandardSimpleInfo) {
|
|
|
+ return toDocument((ProdNonStandardSimpleInfo) object);
|
|
|
}
|
|
|
// TODO 其他表
|
|
|
else {
|
|
|
@@ -207,9 +213,9 @@ public class ObjectToDocumentUtils {
|
|
|
document.add(new LongField(ClassAndTableNameUtils.combineField(tableName, PurchaseOrderSimpleInfo.DATE_FIELD),
|
|
|
purchaseOrder.getDate().getTime(), Store.YES));
|
|
|
// enterprise、vend和orderItems以json的格式存储
|
|
|
- document.add(new TextField(
|
|
|
- ClassAndTableNameUtils.combineField(tableName, PurchaseOrderSimpleInfo.ENTERPRISE_FIELD),
|
|
|
- JSONObject.toJSONString(purchaseOrder.getEnterprise()), Store.YES));
|
|
|
+ document.add(
|
|
|
+ new TextField(ClassAndTableNameUtils.combineField(tableName, PurchaseOrderSimpleInfo.ENTERPRISE_FIELD),
|
|
|
+ JSONObject.toJSONString(purchaseOrder.getEnterprise()), Store.YES));
|
|
|
document.add(new TextField(ClassAndTableNameUtils.combineField(tableName, PurchaseOrderSimpleInfo.VEND_FIELD),
|
|
|
JSONObject.toJSONString(purchaseOrder.getVend()), Store.YES));
|
|
|
if (!CollectionUtils.isEmpty(purchaseOrder.getOrderItems())) {
|
|
|
@@ -266,9 +272,8 @@ public class ObjectToDocumentUtils {
|
|
|
document.add(new LongField(ClassAndTableNameUtils.combineField(tableName, MakeOrderSimpleInfo.DATE_FIELD),
|
|
|
makeOrder.getDate().getTime(), Store.YES));
|
|
|
// enterprise、vend和orderItems以json的格式存储
|
|
|
- document.add(
|
|
|
- new TextField(ClassAndTableNameUtils.combineField(tableName, MakeOrderSimpleInfo.ENTERPRISE_FIELD),
|
|
|
- JSONObject.toJSONString(makeOrder.getEnterprise()), Store.YES));
|
|
|
+ document.add(new TextField(ClassAndTableNameUtils.combineField(tableName, MakeOrderSimpleInfo.ENTERPRISE_FIELD),
|
|
|
+ JSONObject.toJSONString(makeOrder.getEnterprise()), Store.YES));
|
|
|
document.add(new TextField(ClassAndTableNameUtils.combineField(tableName, MakeOrderSimpleInfo.VEND_FIELD),
|
|
|
JSONObject.toJSONString(makeOrder.getVend()), Store.YES));
|
|
|
if (makeOrder.getProduct() != null) {
|
|
|
@@ -318,13 +323,11 @@ public class ObjectToDocumentUtils {
|
|
|
purcAccept.getDate().getTime(), Store.YES));
|
|
|
}
|
|
|
// vend和items以json的格式存储
|
|
|
+ document.add(new TextField(ClassAndTableNameUtils.combineField(tableName, PurchaseAcceptSimpleInfo.VEND_FIELD),
|
|
|
+ JSONObject.toJSONString(purcAccept.getVend()), Store.YES));
|
|
|
document.add(
|
|
|
- new TextField(ClassAndTableNameUtils.combineField(tableName, PurchaseAcceptSimpleInfo.VEND_FIELD),
|
|
|
- JSONObject.toJSONString(purcAccept.getVend()), Store.YES));
|
|
|
- document.add(
|
|
|
- new TextField(
|
|
|
- ClassAndTableNameUtils.combineField(tableName, PurchaseAcceptSimpleInfo.ENTERPRISE_FIELD),
|
|
|
- JSONObject.toJSONString(purcAccept.getEnterprise()), Store.YES));
|
|
|
+ new TextField(ClassAndTableNameUtils.combineField(tableName, PurchaseAcceptSimpleInfo.ENTERPRISE_FIELD),
|
|
|
+ JSONObject.toJSONString(purcAccept.getEnterprise()), Store.YES));
|
|
|
if (!CollectionUtils.isEmpty(purcAccept.getAcceptItems())) {
|
|
|
document.add(
|
|
|
new TextField(ClassAndTableNameUtils.combineField(tableName, PurchaseAcceptSimpleInfo.ITEMS_FIELD),
|
|
|
@@ -1493,11 +1496,230 @@ public class ObjectToDocumentUtils {
|
|
|
new StringField(ClassAndTableNameUtils.combineField(tableName, ProdSimpleInfo.MATCHESTAUTS_FIELD),
|
|
|
String.valueOf(prodSimpleInfo.getMatchstatus()), Store.YES));
|
|
|
}
|
|
|
+ if (null != prodSimpleInfo.getMatchsize()) {
|
|
|
+ document.add(
|
|
|
+ new StringField(ClassAndTableNameUtils.combineField(tableName, ProdSimpleInfo.MATCHESIZE_FIELD),
|
|
|
+ String.valueOf(prodSimpleInfo.getMatchsize()), Store.YES));
|
|
|
+ }
|
|
|
+ if (null != prodSimpleInfo.getKind()) {
|
|
|
+ document.add(new StringField(ClassAndTableNameUtils.combineField(tableName, ProdSimpleInfo.KIND_FIELD),
|
|
|
+ String.valueOf(prodSimpleInfo.getKind()), Store.YES));
|
|
|
+ }
|
|
|
+ if (null != prodSimpleInfo.getKinden()) {
|
|
|
+ document.add(new StringField(ClassAndTableNameUtils.combineField(tableName, ProdSimpleInfo.KINDEN_FIELD),
|
|
|
+ String.valueOf(prodSimpleInfo.getKinden()), Store.YES));
|
|
|
+ }
|
|
|
+ if (null != prodSimpleInfo.getPbrand()) {
|
|
|
+ document.add(new StringField(ClassAndTableNameUtils.combineField(tableName, ProdSimpleInfo.PBRAND_FIELD),
|
|
|
+ String.valueOf(prodSimpleInfo.getPbrand()), Store.YES));
|
|
|
+ }
|
|
|
+ if (null != prodSimpleInfo.getPbranden()) {
|
|
|
+ document.add(new StringField(ClassAndTableNameUtils.combineField(tableName, ProdSimpleInfo.PBRANDEN_FIELD),
|
|
|
+ String.valueOf(prodSimpleInfo.getPbranden()), Store.YES));
|
|
|
+ }
|
|
|
+ if (null != prodSimpleInfo.getPcmpcode()) {
|
|
|
+ document.add(new StringField(ClassAndTableNameUtils.combineField(tableName, ProdSimpleInfo.PCMPCODE_FIELD),
|
|
|
+ String.valueOf(prodSimpleInfo.getPcmpcode()), Store.YES));
|
|
|
+ }
|
|
|
document.add(new StringField(ClassAndTableNameUtils.combineField(tableName, ProdSimpleInfo.ENTERPRISE_FIELD),
|
|
|
JSON.toJSONString(prodSimpleInfo.getEnterprise()), Store.YES));
|
|
|
// 排序字段
|
|
|
document.add(new NumericDocValuesField(ClassAndTableNameUtils.combineField(tableName, ProdSimpleInfo.ID_FIELD),
|
|
|
prodSimpleInfo.getId()));
|
|
|
+ document.add(new NumericDocValuesField(
|
|
|
+ ClassAndTableNameUtils.combineField(tableName, ProdSimpleInfo.MATCHESIZE_FIELD),
|
|
|
+ prodSimpleInfo.getMatchsize()));
|
|
|
+ return document;
|
|
|
+ }
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 将ProdStandardSimpleInfo转换成Document
|
|
|
+ *
|
|
|
+ * @param saleArcheck
|
|
|
+ * @return
|
|
|
+ */
|
|
|
+ public static Document toDocument(ProdStandardSimpleInfo prodSimpleInfo) {
|
|
|
+ if (prodSimpleInfo == null || prodSimpleInfo.getId() == null || prodSimpleInfo.getProdCode() == null
|
|
|
+ || prodSimpleInfo.getEnterprise() == null || prodSimpleInfo.getEnterprise().getUu() == null
|
|
|
+ || StringUtils.isEmpty(prodSimpleInfo.getEnterprise().getEnName())) {
|
|
|
+ return null;
|
|
|
+ }
|
|
|
+ Table_name tableName = ClassAndTableNameUtils.toTableName(ProdStandardSimpleInfo.class);
|
|
|
+ Document document = new Document();
|
|
|
+ // 不能用LongField,否则后续实时更新索引时,方法updateDocument(new Term("", ""),
|
|
|
+ // doc)无法根据id进行更新
|
|
|
+ document.add(new StringField(ClassAndTableNameUtils.combineField(tableName, ProdStandardSimpleInfo.ID_FIELD),
|
|
|
+ String.valueOf(prodSimpleInfo.getId()), Store.YES));
|
|
|
+ document.add(new TextField(ClassAndTableNameUtils.combineField(tableName, ProdStandardSimpleInfo.CODE_FIELD),
|
|
|
+ prodSimpleInfo.getProdCode(), Store.YES));
|
|
|
+ if (null != prodSimpleInfo.getIssale()) {
|
|
|
+ document.add(
|
|
|
+ new StringField(ClassAndTableNameUtils.combineField(tableName, ProdStandardSimpleInfo.ISSALE_FIELD),
|
|
|
+ String.valueOf(prodSimpleInfo.getIssale()), Store.YES));
|
|
|
+ }
|
|
|
+ if (null != prodSimpleInfo.getIsPurchase()) {
|
|
|
+ document.add(
|
|
|
+ new StringField(ClassAndTableNameUtils.combineField(tableName, ProdStandardSimpleInfo.ISPURC_FIELD),
|
|
|
+ String.valueOf(prodSimpleInfo.getIsPurchase()), Store.YES));
|
|
|
+ }
|
|
|
+ if (null != prodSimpleInfo.getIsShow()) {
|
|
|
+ document.add(
|
|
|
+ new StringField(ClassAndTableNameUtils.combineField(tableName, ProdStandardSimpleInfo.ISSHOW_FIELD),
|
|
|
+ String.valueOf(prodSimpleInfo.getIsShow()), Store.YES));
|
|
|
+ }
|
|
|
+ if (null != prodSimpleInfo.getIsPubsale()) {
|
|
|
+ document.add(new StringField(
|
|
|
+ ClassAndTableNameUtils.combineField(tableName, ProdStandardSimpleInfo.ISPUBSALE_FIELD),
|
|
|
+ String.valueOf(prodSimpleInfo.getIsPubsale()), Store.YES));
|
|
|
+ }
|
|
|
+ if (null != prodSimpleInfo.getUuid()) {
|
|
|
+ document.add(
|
|
|
+ new TextField(ClassAndTableNameUtils.combineField(tableName, ProdStandardSimpleInfo.UUID_FIELD),
|
|
|
+ String.valueOf(prodSimpleInfo.getUuid()), Store.YES));
|
|
|
+ }
|
|
|
+ if (null != prodSimpleInfo.getStandard()) {
|
|
|
+ document.add(new StringField(
|
|
|
+ ClassAndTableNameUtils.combineField(tableName, ProdStandardSimpleInfo.STANDARD_FIELD),
|
|
|
+ String.valueOf(prodSimpleInfo.getStandard()), Store.YES));
|
|
|
+ }
|
|
|
+ if (null != prodSimpleInfo.getMatchstatus()) {
|
|
|
+ document.add(new StringField(
|
|
|
+ ClassAndTableNameUtils.combineField(tableName, ProdStandardSimpleInfo.MATCHESTAUTS_FIELD),
|
|
|
+ String.valueOf(prodSimpleInfo.getMatchstatus()), Store.YES));
|
|
|
+ }
|
|
|
+ if (null != prodSimpleInfo.getMatchsize()) {
|
|
|
+ document.add(new StringField(
|
|
|
+ ClassAndTableNameUtils.combineField(tableName, ProdStandardSimpleInfo.MATCHESIZE_FIELD),
|
|
|
+ String.valueOf(prodSimpleInfo.getMatchsize()), Store.YES));
|
|
|
+ }
|
|
|
+ if (null != prodSimpleInfo.getKind()) {
|
|
|
+ document.add(
|
|
|
+ new StringField(ClassAndTableNameUtils.combineField(tableName, ProdStandardSimpleInfo.KIND_FIELD),
|
|
|
+ String.valueOf(prodSimpleInfo.getKind()), Store.YES));
|
|
|
+ }
|
|
|
+ if (null != prodSimpleInfo.getKinden()) {
|
|
|
+ document.add(
|
|
|
+ new StringField(ClassAndTableNameUtils.combineField(tableName, ProdStandardSimpleInfo.KINDEN_FIELD),
|
|
|
+ String.valueOf(prodSimpleInfo.getKinden()), Store.YES));
|
|
|
+ }
|
|
|
+ if (null != prodSimpleInfo.getPbrand()) {
|
|
|
+ document.add(
|
|
|
+ new StringField(ClassAndTableNameUtils.combineField(tableName, ProdStandardSimpleInfo.PBRAND_FIELD),
|
|
|
+ String.valueOf(prodSimpleInfo.getPbrand()), Store.YES));
|
|
|
+ }
|
|
|
+ if (null != prodSimpleInfo.getPbranden()) {
|
|
|
+ document.add(new StringField(
|
|
|
+ ClassAndTableNameUtils.combineField(tableName, ProdStandardSimpleInfo.PBRANDEN_FIELD),
|
|
|
+ String.valueOf(prodSimpleInfo.getPbranden()), Store.YES));
|
|
|
+ }
|
|
|
+ if (null != prodSimpleInfo.getPcmpcode()) {
|
|
|
+ document.add(new StringField(
|
|
|
+ ClassAndTableNameUtils.combineField(tableName, ProdStandardSimpleInfo.PCMPCODE_FIELD),
|
|
|
+ String.valueOf(prodSimpleInfo.getPcmpcode()), Store.YES));
|
|
|
+ }
|
|
|
+ document.add(
|
|
|
+ new StringField(ClassAndTableNameUtils.combineField(tableName, ProdStandardSimpleInfo.ENTERPRISE_FIELD),
|
|
|
+ JSON.toJSONString(prodSimpleInfo.getEnterprise()), Store.YES));
|
|
|
+ // 排序字段
|
|
|
+ document.add(new NumericDocValuesField(
|
|
|
+ ClassAndTableNameUtils.combineField(tableName, ProdStandardSimpleInfo.ID_FIELD),
|
|
|
+ prodSimpleInfo.getId()));
|
|
|
+ document.add(new NumericDocValuesField(
|
|
|
+ ClassAndTableNameUtils.combineField(tableName, ProdStandardSimpleInfo.MATCHESIZE_FIELD),
|
|
|
+ prodSimpleInfo.getMatchsize()));
|
|
|
+ return document;
|
|
|
+ }
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 将ProdNonStandardSimpleInfo转换成Document
|
|
|
+ *
|
|
|
+ * @param saleArcheck
|
|
|
+ * @return
|
|
|
+ */
|
|
|
+ public static Document toDocument(ProdNonStandardSimpleInfo prodSimpleInfo) {
|
|
|
+ if (prodSimpleInfo == null || prodSimpleInfo.getId() == null || prodSimpleInfo.getProdCode() == null
|
|
|
+ || prodSimpleInfo.getEnterprise() == null || prodSimpleInfo.getEnterprise().getUu() == null
|
|
|
+ || StringUtils.isEmpty(prodSimpleInfo.getEnterprise().getEnName())) {
|
|
|
+ return null;
|
|
|
+ }
|
|
|
+ Table_name tableName = ClassAndTableNameUtils.toTableName(ProdNonStandardSimpleInfo.class);
|
|
|
+ Document document = new Document();
|
|
|
+ // 不能用LongField,否则后续实时更新索引时,方法updateDocument(new Term("", ""),
|
|
|
+ // doc)无法根据id进行更新
|
|
|
+ document.add(new StringField(ClassAndTableNameUtils.combineField(tableName, ProdNonStandardSimpleInfo.ID_FIELD),
|
|
|
+ String.valueOf(prodSimpleInfo.getId()), Store.YES));
|
|
|
+ document.add(new TextField(ClassAndTableNameUtils.combineField(tableName, ProdNonStandardSimpleInfo.CODE_FIELD),
|
|
|
+ prodSimpleInfo.getProdCode(), Store.YES));
|
|
|
+ if (null != prodSimpleInfo.getProdTitle()) {
|
|
|
+ document.add(
|
|
|
+ new TextField(ClassAndTableNameUtils.combineField(tableName, ProdNonStandardSimpleInfo.TITLE_FIELD),
|
|
|
+ String.valueOf(prodSimpleInfo.getProdTitle()), Store.YES));
|
|
|
+ }
|
|
|
+ if (null != prodSimpleInfo.getProdSpec()) {
|
|
|
+ document.add(
|
|
|
+ new TextField(ClassAndTableNameUtils.combineField(tableName, ProdNonStandardSimpleInfo.SPEC_FIELD),
|
|
|
+ String.valueOf(prodSimpleInfo.getProdSpec()), Store.YES));
|
|
|
+ }
|
|
|
+ if (null != prodSimpleInfo.getBrand()) {
|
|
|
+ document.add(
|
|
|
+ new TextField(ClassAndTableNameUtils.combineField(tableName, ProdNonStandardSimpleInfo.BRAND_FIELD),
|
|
|
+ String.valueOf(prodSimpleInfo.getBrand()), Store.YES));
|
|
|
+ }
|
|
|
+ if (null != prodSimpleInfo.getIssale()) {
|
|
|
+ document.add(new StringField(
|
|
|
+ ClassAndTableNameUtils.combineField(tableName, ProdNonStandardSimpleInfo.ISSALE_FIELD),
|
|
|
+ String.valueOf(prodSimpleInfo.getIssale()), Store.YES));
|
|
|
+ }
|
|
|
+ if (null != prodSimpleInfo.getIsPurchase()) {
|
|
|
+ document.add(new StringField(
|
|
|
+ ClassAndTableNameUtils.combineField(tableName, ProdNonStandardSimpleInfo.ISPURC_FIELD),
|
|
|
+ String.valueOf(prodSimpleInfo.getIsPurchase()), Store.YES));
|
|
|
+ }
|
|
|
+ if (null != prodSimpleInfo.getIsShow()) {
|
|
|
+ document.add(new StringField(
|
|
|
+ ClassAndTableNameUtils.combineField(tableName, ProdNonStandardSimpleInfo.ISSHOW_FIELD),
|
|
|
+ String.valueOf(prodSimpleInfo.getIsShow()), Store.YES));
|
|
|
+ }
|
|
|
+ if (null != prodSimpleInfo.getIsPubsale()) {
|
|
|
+ document.add(new StringField(
|
|
|
+ ClassAndTableNameUtils.combineField(tableName, ProdNonStandardSimpleInfo.ISPUBSALE_FIELD),
|
|
|
+ String.valueOf(prodSimpleInfo.getIsPubsale()), Store.YES));
|
|
|
+ }
|
|
|
+ if (null != prodSimpleInfo.getUuid()) {
|
|
|
+ document.add(
|
|
|
+ new TextField(ClassAndTableNameUtils.combineField(tableName, ProdNonStandardSimpleInfo.UUID_FIELD),
|
|
|
+ String.valueOf(prodSimpleInfo.getUuid()), Store.YES));
|
|
|
+ }
|
|
|
+ if (null != prodSimpleInfo.getCmpCode()) {
|
|
|
+ document.add(new TextField(
|
|
|
+ ClassAndTableNameUtils.combineField(tableName, ProdNonStandardSimpleInfo.CMPCODE_FIELD),
|
|
|
+ String.valueOf(prodSimpleInfo.getCmpCode()), Store.YES));
|
|
|
+ }
|
|
|
+ if (null != prodSimpleInfo.getStandard()) {
|
|
|
+ document.add(new StringField(
|
|
|
+ ClassAndTableNameUtils.combineField(tableName, ProdNonStandardSimpleInfo.STANDARD_FIELD),
|
|
|
+ String.valueOf(prodSimpleInfo.getStandard()), Store.YES));
|
|
|
+ }
|
|
|
+ if (null != prodSimpleInfo.getMatchstatus()) {
|
|
|
+ document.add(new StringField(
|
|
|
+ ClassAndTableNameUtils.combineField(tableName, ProdNonStandardSimpleInfo.MATCHESTAUTS_FIELD),
|
|
|
+ String.valueOf(prodSimpleInfo.getMatchstatus()), Store.YES));
|
|
|
+ }
|
|
|
+ if (null != prodSimpleInfo.getMatchsize()) {
|
|
|
+ document.add(new StringField(
|
|
|
+ ClassAndTableNameUtils.combineField(tableName, ProdNonStandardSimpleInfo.MATCHESIZE_FIELD),
|
|
|
+ String.valueOf(prodSimpleInfo.getMatchsize()), Store.YES));
|
|
|
+ }
|
|
|
+ document.add(new StringField(
|
|
|
+ ClassAndTableNameUtils.combineField(tableName, ProdNonStandardSimpleInfo.ENTERPRISE_FIELD),
|
|
|
+ JSON.toJSONString(prodSimpleInfo.getEnterprise()), Store.YES));
|
|
|
+ // 排序字段
|
|
|
+ document.add(new NumericDocValuesField(
|
|
|
+ ClassAndTableNameUtils.combineField(tableName, ProdNonStandardSimpleInfo.ID_FIELD),
|
|
|
+ prodSimpleInfo.getId()));
|
|
|
+ document.add(new NumericDocValuesField(
|
|
|
+ ClassAndTableNameUtils.combineField(tableName, ProdNonStandardSimpleInfo.MATCHESIZE_FIELD),
|
|
|
+ prodSimpleInfo.getMatchsize()));
|
|
|
return document;
|
|
|
}
|
|
|
|
|
|
@@ -1653,9 +1875,8 @@ public class ObjectToDocumentUtils {
|
|
|
}
|
|
|
if (prodComp.getCode() != null) {
|
|
|
document.add(
|
|
|
- new TextField(
|
|
|
- ClassAndTableNameUtils.combineField(tableName, ProductComponentSimpleInfo.CODE_FIELD),
|
|
|
- String.valueOf(prodComp.getCode()), Store.YES));
|
|
|
+ new TextField(ClassAndTableNameUtils.combineField(tableName, ProductComponentSimpleInfo.CODE_FIELD),
|
|
|
+ String.valueOf(prodComp.getCode()), Store.YES));
|
|
|
}
|
|
|
if (prodComp.getBrand() != null) {
|
|
|
document.add(new StringField(
|
|
|
@@ -2053,33 +2274,29 @@ public class ObjectToDocumentUtils {
|
|
|
Document document = new Document();
|
|
|
// 不能用LongField,否则后续实时更新索引时,方法updateDocument(new Term("", ""),
|
|
|
// doc)无法根据id进行更新
|
|
|
- document.add(
|
|
|
- new StringField(ClassAndTableNameUtils.combineField(tableName, VendorSimpleInfo.ID_FIELD),
|
|
|
- String.valueOf(vendorSimpleInfo.getId()), Store.YES));
|
|
|
+ document.add(new StringField(ClassAndTableNameUtils.combineField(tableName, VendorSimpleInfo.ID_FIELD),
|
|
|
+ String.valueOf(vendorSimpleInfo.getId()), Store.YES));
|
|
|
if (null != vendorSimpleInfo.getStatus()) {
|
|
|
- document.add(new StringField(
|
|
|
- ClassAndTableNameUtils.combineField(tableName, VendorSimpleInfo.STATUS_FIELD),
|
|
|
+ document.add(new StringField(ClassAndTableNameUtils.combineField(tableName, VendorSimpleInfo.STATUS_FIELD),
|
|
|
String.valueOf(vendorSimpleInfo.getStatus()), Store.YES));
|
|
|
}
|
|
|
if (null != vendorSimpleInfo.getEnterprise()) {
|
|
|
- document.add(new TextField(
|
|
|
- ClassAndTableNameUtils.combineField(tableName, VendorSimpleInfo.ENTERPRISE_FIELD),
|
|
|
- JSON.toJSONString(vendorSimpleInfo.getEnterprise()), Store.YES));
|
|
|
+ document.add(
|
|
|
+ new TextField(ClassAndTableNameUtils.combineField(tableName, VendorSimpleInfo.ENTERPRISE_FIELD),
|
|
|
+ JSON.toJSONString(vendorSimpleInfo.getEnterprise()), Store.YES));
|
|
|
}
|
|
|
if (null != vendorSimpleInfo.getVend()) {
|
|
|
- document.add(new TextField(
|
|
|
- ClassAndTableNameUtils.combineField(tableName, VendorSimpleInfo.VEND_FIELD),
|
|
|
+ document.add(new TextField(ClassAndTableNameUtils.combineField(tableName, VendorSimpleInfo.VEND_FIELD),
|
|
|
JSON.toJSONString(vendorSimpleInfo.getVend()), Store.YES));
|
|
|
}
|
|
|
if (null != vendorSimpleInfo.getMyUser()) {
|
|
|
- document.add(new StringField(
|
|
|
- ClassAndTableNameUtils.combineField(tableName, VendorSimpleInfo.MYUSER_FIELD),
|
|
|
+ document.add(new StringField(ClassAndTableNameUtils.combineField(tableName, VendorSimpleInfo.MYUSER_FIELD),
|
|
|
JSON.toJSONString(vendorSimpleInfo.getMyUser()), Store.YES));
|
|
|
}
|
|
|
if (null != vendorSimpleInfo.getVendUser()) {
|
|
|
- document.add(new StringField(
|
|
|
- ClassAndTableNameUtils.combineField(tableName, VendorSimpleInfo.VENDUSER_FIELD),
|
|
|
- JSON.toJSONString(vendorSimpleInfo.getVendUser()), Store.YES));
|
|
|
+ document.add(
|
|
|
+ new StringField(ClassAndTableNameUtils.combineField(tableName, VendorSimpleInfo.VENDUSER_FIELD),
|
|
|
+ JSON.toJSONString(vendorSimpleInfo.getVendUser()), Store.YES));
|
|
|
}
|
|
|
if (null != vendorSimpleInfo.getCustswitch()) {
|
|
|
document.add(
|