public VendorPriceInfo GetCliass() { VendorPriceInfo vendorPriceInfo = new VendorPriceInfo(); vendorPriceInfo.priceID = 1; vendorPriceInfo.oldID = 11; vendorPriceInfo.source = "asdfasfd"; return(vendorPriceInfo); }
/// <summary> /// 创建索引数据 /// </summary> public static void CreateIndexData() { var vendorPriceInfo = new VendorPriceInfo { priceID = 1, oldID = 2, source = "ttt" }; client.Index(vendorPriceInfo, o => o.Index("vendorpriceinfo").Type <VendorPriceInfo>());//使用 2)标记的类型 }