本文整理汇总了C#中SKUInfo.SetValue方法的典型用法代码示例。如果您正苦于以下问题:C# SKUInfo.SetValue方法的具体用法?C# SKUInfo.SetValue怎么用?C# SKUInfo.SetValue使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类SKUInfo
的用法示例。
在下文中一共展示了SKUInfo.SetValue方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: ChangeProductToAttribute
/// <summary>
/// Changes SKU option from data set to attribute option. Attribute is an option and it does not need product data like for example itinerary.
/// </summary>
/// <param name="options">Data set with product option</param>
private void ChangeProductToAttribute(DataSet options)
{
if (DataHelper.DataSourceIsEmpty(options))
{
return;
}
foreach (DataRow option in options.Tables[0].Rows)
{
SKUInfo product = new SKUInfo(option);
product.SKUProductType = SKUProductTypeEnum.Product;
product.SetValue("SKUTrackInventory", null);
product.SetValue("SKUMaxItemsInOrder", null);
product.SetValue("SKUMinItemsInOrder", null);
product.SetValue("SKUAvailableItems", null);
product.SetValue("SKUValidity", null);
product.SetValue("SKUReorderAt", null);
product.SetValue("SKUDescription", null);
product.SetValue("SKUAvailableInDays", null);
product.SetValue("SKUNumber", null);
product.SetValue("SKUMaxDownloads", null);
product.SetValue("SKUMaxPrice", null);
product.SetValue("SKUMinPrice", null);
product.SetValue("SKUValidFor", null);
product.SetValue("SKURetailPrice", null);
product.SetValue("SKUEproductFilesCount", null);
product.SKUDepartmentID = 0;
product.SKUManufacturerID = 0;
product.SKUInternalStatusID = 0;
product.SKUPublicStatusID = 0;
product.SKUSupplierID = 0;
product.SKUImagePath = null;
product.SKUWeight = 0;
product.SKUWidth = 0;
product.SKUDepth = 0;
product.SKUHeight = 0;
product.SKUSellOnlyAvailable = false;
product.SKUPrivateDonation = false;
product.SKUNeedsShipping = false;
product.SKUValidUntil = DateTimeHelper.ZERO_TIME;
product.SKUMembershipGUID = Guid.Empty;
product.SKUConversionName = null;
product.SKUConversionValue = "";
product.SKUBundleInventoryType = 0;
product.SKUParentSKUID = 0;
product.SKUShortDescription = null;
SKUInfoProvider.SetSKUInfo(product);
}
}