Removing SkuDownloadOptions
This commit is contained in:
Родитель
206c5afad9
Коммит
db1d2db87e
|
@ -1,41 +0,0 @@
|
|||
// -----------------------------------------------------------------------
|
||||
// <copyright file="GetCustomerSkuDownloadOptions.cs" company="Microsoft">
|
||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
// </copyright>
|
||||
// -----------------------------------------------------------------------
|
||||
|
||||
namespace Microsoft.Store.PartnerCenter.Samples.CustomerProducts
|
||||
{
|
||||
using System.Globalization;
|
||||
|
||||
/// <summary>
|
||||
/// A scenario that retrieves the download options of a product's SKU for a customer.
|
||||
/// </summary>
|
||||
public class GetCustomerSkuDownloadOptions : BasePartnerScenario
|
||||
{
|
||||
/// <summary>
|
||||
/// Initializes a new instance of the <see cref="GetCustomerSkuDownloadOptions"/> class.
|
||||
/// </summary>
|
||||
/// <param name="context">The scenario context.</param>
|
||||
public GetCustomerSkuDownloadOptions(IScenarioContext context) : base("Get sku download options for customer", context)
|
||||
{
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Executes the scenario.
|
||||
/// </summary>
|
||||
protected override void RunScenario()
|
||||
{
|
||||
var partnerOperations = this.Context.UserPartnerOperations;
|
||||
var customerId = this.ObtainCustomerId("Enter the ID of the corresponding customer");
|
||||
var productId = this.ObtainProductId("Enter the ID of the corresponding product");
|
||||
var skuId = this.ObtainSkuId("Enter the ID of the corresponding sku");
|
||||
|
||||
this.Context.ConsoleHelper.StartProgress(string.Format(CultureInfo.InvariantCulture, "Getting sku download options for sku {0} from product {1} for customer {2}", skuId, productId, customerId));
|
||||
var sku = partnerOperations.Customers.ById(customerId).Products.ById(productId).Skus.ById(skuId).DownloadOptions.Get();
|
||||
this.Context.ConsoleHelper.StopProgress();
|
||||
|
||||
this.Context.ConsoleHelper.WriteObject(sku, "Sku download options for customer");
|
||||
}
|
||||
}
|
||||
}
|
|
@ -1,41 +0,0 @@
|
|||
// -----------------------------------------------------------------------
|
||||
// <copyright file="GetSkuDownloadOptions.cs" company="Microsoft">
|
||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
// </copyright>
|
||||
// -----------------------------------------------------------------------
|
||||
|
||||
namespace Microsoft.Store.PartnerCenter.Samples.Products
|
||||
{
|
||||
using System.Globalization;
|
||||
|
||||
/// <summary>
|
||||
/// A scenario that retrieves the download options of a product's SKU.
|
||||
/// </summary>
|
||||
public class GetSkuDownloadOptions : BasePartnerScenario
|
||||
{
|
||||
/// <summary>
|
||||
/// Initializes a new instance of the <see cref="GetSkuDownloadOptions"/> class.
|
||||
/// </summary>
|
||||
/// <param name="context">The scenario context.</param>
|
||||
public GetSkuDownloadOptions(IScenarioContext context) : base("Get sku download options", context)
|
||||
{
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Executes the scenario.
|
||||
/// </summary>
|
||||
protected override void RunScenario()
|
||||
{
|
||||
var partnerOperations = this.Context.UserPartnerOperations;
|
||||
var productId = this.ObtainProductId("Enter the ID of the corresponding product");
|
||||
var skuId = this.ObtainSkuId("Enter the ID of the corresponding sku");
|
||||
string countryCode = this.Context.ConsoleHelper.ReadNonEmptyString("Enter the 2 digit country code of the sku", "The country code can't be empty");
|
||||
|
||||
this.Context.ConsoleHelper.StartProgress(string.Format(CultureInfo.InvariantCulture, "Getting sku download options for product {0} and sku {1} in country {2}", productId, skuId, countryCode));
|
||||
var sku = partnerOperations.Products.ByCountry(countryCode).ById(productId).Skus.ById(skuId).DownloadOptions.Get();
|
||||
this.Context.ConsoleHelper.StopProgress();
|
||||
|
||||
this.Context.ConsoleHelper.WriteObject(sku, string.Format(CultureInfo.InvariantCulture, "Download options for sku {0}", skuId));
|
||||
}
|
||||
}
|
||||
}
|
|
@ -281,7 +281,6 @@ namespace Microsoft.Store.PartnerCenter.Samples
|
|||
new GetSkus(context),
|
||||
new GetSkusByTargetSegment(context),
|
||||
new GetSku(context),
|
||||
new GetSkuDownloadOptions(context),
|
||||
new GetAvailabilities(context),
|
||||
new GetAvailabilitiesByTargetSegment(context),
|
||||
new GetAvailability(context),
|
||||
|
@ -306,7 +305,6 @@ namespace Microsoft.Store.PartnerCenter.Samples
|
|||
new GetCustomerSkus(context),
|
||||
new GetCustomerSkusByTargetSegment(context),
|
||||
new GetCustomerSku(context),
|
||||
new GetCustomerSkuDownloadOptions(context),
|
||||
new GetCustomerAvailabilities(context),
|
||||
new GetCustomerAvailabilitiesByTargetSegment(context),
|
||||
new GetCustomerAvailability(context)
|
||||
|
|
|
@ -105,7 +105,6 @@
|
|||
<Compile Include="CustomerProducts\GetCustomerProducts.cs" />
|
||||
<Compile Include="CustomerProducts\GetCustomerProductsByTargetSegment.cs" />
|
||||
<Compile Include="CustomerProducts\GetCustomerSku.cs" />
|
||||
<Compile Include="CustomerProducts\GetCustomerSkuDownloadOptions.cs" />
|
||||
<Compile Include="CustomerProducts\GetCustomerSkus.cs" />
|
||||
<Compile Include="CustomerProducts\GetCustomerSkusByTargetSegment.cs" />
|
||||
<Compile Include="CustomerServiceCosts\GetCustomerServiceCostsLineItems.cs" />
|
||||
|
@ -189,7 +188,6 @@
|
|||
<Compile Include="Products\GetAvailabilities.cs" />
|
||||
<Compile Include="Products\GetAvailability.cs" />
|
||||
<Compile Include="Products\CheckInventory.cs" />
|
||||
<Compile Include="Products\GetSkuDownloadOptions.cs" />
|
||||
<Compile Include="Products\GetSku.cs" />
|
||||
<Compile Include="Products\GetProduct.cs" />
|
||||
<Compile Include="Products\GetSkusByTargetSegment.cs" />
|
||||
|
|
Загрузка…
Ссылка в новой задаче