Table of Contents

Class StockLocation

Namespace
Dynamicweb.Ecommerce.Stocks
Assembly
Dynamicweb.Ecommerce.dll
Represents the stock location.
[Serializable]
public class StockLocation
Inheritance
StockLocation
Inherited Members

Constructors

StockLocation()

Initializes a new instance of the StockLocation class.
public StockLocation()

Properties

CategoryId

public string CategoryId { get; set; }

Property Value

string

Description

Gets or sets the description.
[Obsolete("Use GetDescription and SetDescription instead.")]
public string Description { get; set; }

Property Value

string

GroupID

public long GroupID { get; set; }

Property Value

long

ID

public long ID { get; set; }

Property Value

long

LanguageId

Gets or sets the language id.
[Obsolete("Use Translations instead.")]
public string LanguageId { get; set; }

Property Value

string

Name

Gets or sets the name.
[Obsolete("Use GetName and SetName instead.")]
public string Name { get; set; }

Property Value

string

SortOrder

public int SortOrder { get; set; }

Property Value

int

Translations

Gets the translations
public TranslationCollection<StockLocationTranslation> Translations { get; }

Property Value

TranslationCollection<StockLocationTranslation>

UserId

public int UserId { get; set; }

Property Value

int

Methods

Clone()

Clones the stock location.
public StockLocation Clone()

Returns

StockLocation
New instance of the StockLocation.

Delete(long)

Deletes the object with specified ID.
[Obsolete("Use Services.StockService.DeleteStockLocation(StockLocation, Int64) instead.")]
public void Delete(long id)

Parameters

id long
Specified ID.

DeleteAllRelationFromShop(string)

Deletes all relations for the shop.
[Obsolete("Use Services.StockService.DeleteAllStockLocationRelationsFromShop(String) instead.")]
public static bool DeleteAllRelationFromShop(string shopId)

Parameters

shopId string
The shop id.

Returns

bool
True.

DeleteRelation(string, long)

Deletes the relation.
[Obsolete("Use Services.StockService.DeleteStockLocationRelation(String, Int64) instead.")]
public bool DeleteRelation(string shopId, long stockLocationId)

Parameters

shopId string
The shop id.
stockLocationId long
The stock location id.

Returns

bool
True.

DeleteStockRelations()

Delete relations to the stock location.
[Obsolete("Use Services.StockService.DeleteStockLocationRelations(StockLocation) instead.")]
public void DeleteStockRelations()

Fill(IDataReader)

[Obsolete("This method is no longer used.")]
public void Fill(IDataReader reader)

Parameters

reader IDataReader

FillRow(DataRow)

[Obsolete("This method is no longer used.")]
protected void FillRow(DataRow row)

Parameters

row DataRow

GetDescription(string)

Gets the description of the stock location for the given language.
public string GetDescription(string languageId)

Parameters

languageId string

Returns

string

GetName(string)

Gets the name of the stock location for the given language.
public string GetName(string languageId)

Parameters

languageId string

Returns

string

GetRelationByShopID(string)

Gets the relations.
[Obsolete("Use Services.StockService.GetStockLocationRelations(String) instead.")]
public static StockLocationCollection GetRelationByShopID(string shopId)

Parameters

shopId string
The shop id.

Returns

StockLocationCollection
The relations.

GetStockLocationById(long)

Gets the stock location by id.
[Obsolete("Use Services.StockService.GetStockLocation(Int64) instead.")]
public static StockLocation GetStockLocationById(long id)

Parameters

id long
The id of stock location.

Returns

StockLocation
The stock location.

GetStockLocationByIdAndLanguage(long, string)

Gets the stock location by id.
[Obsolete("Use Services.StockService.GetStockLocation(Int64, String) instead.")]
public static StockLocation GetStockLocationByIdAndLanguage(long id, string lagnguageId)

Parameters

id long
The id of stock location.
lagnguageId string

Returns

StockLocation
The stock location.

GetStockLocationByIdFromCache(Product, long)

Gets the stock location by id.
[Obsolete("Use Services.StockService.GetStockLocation(Product, Int64) instead.")]
public static StockLocation GetStockLocationByIdFromCache(Product product, long stockLocationId)

Parameters

product Product
stockLocationId long
The id of stock location.

Returns

StockLocation
The stock location.

GetStockLocations()

Gets the stock locations.
[Obsolete("Use Services.StockService.GetStockLocations() instead.")]
public static StockLocationCollection GetStockLocations()

Returns

StockLocationCollection
The collection of all stock location.

GetStockLocations(bool)

Gets the stock locations.
[Obsolete("Use Services.StockService.GetStockLocations(Boolean) instead.")]
public static StockLocationCollection GetStockLocations(bool sortByOrder)

Parameters

sortByOrder bool

Returns

StockLocationCollection
The collection of all stock location.

GetStockLocationsByGroupId(long)

Gets the stock locations by group id.
[Obsolete("Use Services.StockService.GetStockLocations(Int64) instead.")]
public static StockLocationCollection GetStockLocationsByGroupId(long groupId)

Parameters

groupId long
The id of stock location group.

Returns

StockLocationCollection
The stock locations.

GetStockLocationsByLanguageId(string)

Gets the stock locations by language id.
[Obsolete("Use Services.StockService.GetStockLocations(String) instead.")]
public static StockLocationCollection GetStockLocationsByLanguageId(string languageId)

Parameters

languageId string
The id of language.

Returns

StockLocationCollection
The stock location.

GetStockLocationsByLanguageIdAndProduct(Product, string)

Gets the stock locations by language id and product id.
[Obsolete("Use Services.StockService.GetStockLocations(Product, String) instead.")]
public static StockLocationCollection GetStockLocationsByLanguageIdAndProduct(Product product, string lagnguageId)

Parameters

product Product
lagnguageId string

Returns

StockLocationCollection
The collection of all stock location.

GetStockLocationsFilteredByLanguage(string, string)

Gets the stock locations.
[Obsolete("Use Services.StockService.GetStockLocations(String, Boolean)")]
public static StockLocationCollection GetStockLocationsFilteredByLanguage(string currentLanguageId, string defultLanguageId)

Parameters

currentLanguageId string
defultLanguageId string

Returns

StockLocationCollection
The collection of all stock location.

GetStockLocationsFromCache(Product)

Gets the stock location by id.
[Obsolete("Use Services.StockService.GetStockLocations(Product) instead.")]
public static StockLocationCollection GetStockLocationsFromCache(Product product)

Parameters

product Product

Returns

StockLocationCollection
The stock locations from cache.

Save()

Saves current data to the database.
[Obsolete("Use Services.StockService.SaveStockLocation(StockLocation) instead.")]
public void Save()

SaveRelation(string, long)

Saves the relation.
[Obsolete("Use Services.StockService.CreateStockLocationRelation(String, Int64) instead.")]
public bool SaveRelation(string shopId, long stockLocationId)

Parameters

shopId string
The shop id.
stockLocationId long
The stock location id.

Returns

bool
True.

SetDescription(string, string)

Sets the description of the stock location for the given language.
public void SetDescription(string languageId, string description)

Parameters

languageId string
description string

SetName(string, string)

Sets the name of the stock location for the given language.
public void SetName(string languageId, string name)

Parameters

languageId string
name string
To top