API CreateProduct: Porovnání verzí

Z Podpora.nextis.cz
Přejít na: navigace, hledání
 
(Nejsou zobrazeny 3 mezilehlé verze od stejného uživatele.)
Řádka 16: Řádka 16:
 
!Relation
 
!Relation
 
|-
 
|-
|ID
+
|@SupplierID
|int
+
|int  
|
 
|Internal system id
 
 
|
 
|
 +
|Supplier ID
 +
|API_GetCustomers.ID
 
|-
 
|-
|GroupID
+
|@GroupID
 
|int  
 
|int  
 
|
 
|
|
+
|Group ID
 
|API_GetProductGroups.ID
 
|API_GetProductGroups.ID
 
|-
 
|-
|SupplierID
+
|@SupplierProductCode
|int
 
|
 
|SupplierID
 
|API_GetCustomers.ID
 
|-
 
|ProductCode
 
 
|nvarchar(40)  
 
|nvarchar(40)  
 
|
 
|
|Product code
+
|Supplier product code
 
|
 
|
 
|-
 
|-
|TypeID
+
|@ManufacturerSupplier
|int
+
|nvarchar(50)
 
|
 
|
|TypeID.
+
|Manufacturer supplier
1 - products
 
 
|
 
|
 
|-
 
|-
|MinimumOrderableQuantity
+
|@Prefix
|decimal(18,2)  
+
|nvarchar(3)  
 
|
 
|
|Minimum orderable quantity
+
|Prefix
|
 
|-
 
|BasicPrice
 
|decimal(18,6)
 
|
 
|Basic price
 
 
|
 
|
 
|-
 
|-
|CreatedDate
+
|@SupplierItemName
|datetime
 
|
 
|Created date
 
|
 
|-
 
|UpdatedDate
 
|datetime
 
|
 
|Updated date
 
|
 
|-
 
|SupplierItemName
 
 
|nvarchar(150)  
 
|nvarchar(150)  
 
|
 
|
Řádka 77: Řádka 52:
 
|
 
|
 
|-
 
|-
|SupplierProductCode
+
|@MinimumOrderableQuantity
|nvarchar(40)  
+
|decimal(18,2)  
 
|
 
|
|Supplier product code
+
|Minimum orderable quantity
 
|
 
|
 
|-
 
|-
|Prefix
+
|@ForeignPrice
|nvarchar(3)  
+
|decimal(19,6)  
 
|
 
|
|Prefix
+
|Foreign price
 
|
 
|
 
|-
 
|-
|ManufacturerSupplier
+
|@BasicPrice
|nvarchar(50)  
+
|decimal(18,6)  
 
|
 
|
|Manufacturer supplier
+
|Basic price
 
|
 
|
 
|-
 
|-
|ForeignPrice
+
|@InfoReturnOfGoods
|decimal(19,6)  
+
|nvarchar(50)
 
|
 
|
|Foreign price
+
|Info return of goods
|
 
|-
 
|RetailPrice
 
|decimal(18,6)
 
|
 
|Retail price
 
 
|
 
|
 
|}
 
|}
 +
 +
==== Return ====
 +
0 : OK
 +
100 : Item could not be created
  
 
==== Example ====
 
==== Example ====
 
<syntaxhighlight lang="sql">
 
<syntaxhighlight lang="sql">
EXEC [API_CreateBranch] @WorkshopID = 1 ,@Name = 'Name' ,@Street = 'Street' ,@City = 'City' ,@ZIPCode = 'ZIPCode' ,@Country = 'Country' ,@Region = 'Region' ,@State ='Česká republika' ,@StateID = 15797 ,@Phone = '+420 556 621 300' ,@Fax = '+420 596 790 789' ,@MobilePhone = '+420 556 621 301' ,@Email = 'info@nextis.cz' ,@Web = 'www.nextis.cz'
+
DECLARE @return_value int
 +
EXEC @return_value = [API_CreateProduct] @SupplierID= 2 ,@GroupID= 14 ,@SupplierProductCode= '1457429619BS' ,@ManufacturerSupplier= 'BOSCH2' ,@Prefix= '' ,@SupplierItemName= 'SupplierItemName' ,@MinimumOrderableQuantity= 1 ,@ForeignPrice= 110 ,@BasicPrice= 190, @InfoReturnOfGoods=''
 
</syntaxhighlight>
 
</syntaxhighlight>
  
 
==== Notices ====
 
==== Notices ====
 
None.
 
None.

Aktuální verze z 13. 8. 2020, 09:24

Description

Method allows You to create new product in system.

Exact name

API_CreateProduct

Type

Standard executable stored procedure.

Specification

Parameter Data type Value range Description Relation
@SupplierID int Supplier ID API_GetCustomers.ID
@GroupID int Group ID API_GetProductGroups.ID
@SupplierProductCode nvarchar(40) Supplier product code
@ManufacturerSupplier nvarchar(50) Manufacturer supplier
@Prefix nvarchar(3) Prefix
@SupplierItemName nvarchar(150) Supplier item name
@MinimumOrderableQuantity decimal(18,2) Minimum orderable quantity
@ForeignPrice decimal(19,6) Foreign price
@BasicPrice decimal(18,6) Basic price
@InfoReturnOfGoods nvarchar(50) Info return of goods

Return

0 : OK
100 : Item could not be created

Example

 DECLARE @return_value int
 EXEC @return_value = [API_CreateProduct] @SupplierID= 2 ,@GroupID= 14 ,@SupplierProductCode= '1457429619BS' ,@ManufacturerSupplier= 'BOSCH2' ,@Prefix= '' ,@SupplierItemName= 'SupplierItemName' ,@MinimumOrderableQuantity= 1 ,@ForeignPrice= 110 ,@BasicPrice= 190, @InfoReturnOfGoods=''

Notices

None.