API UpdateCustomer: Porovnání verzí

Z Podpora.nextis.cz
Přejít na: navigace, hledání
(Založena nová stránka s textem „==== Description ==== Method allows You to update customer in system. ==== Exact name ==== <code>API_UpdateCustomer</code> ==== Type ==== Standard execut…“)
(Žádný rozdíl)

Verze z 7. 8. 2017, 14:56

Description

Method allows You to update customer in system.

Exact name

API_UpdateCustomer

Type

Standard executable stored procedure.

Specification

Parameter Data type Value range Description Relation
@ID int Internal system id API_GetBranches.ID
@ShortName nvarchar(30) Short name
@CompanyName nvarchar(250) Company name
@CompanyRegistrationNumber nvarchar(20) Company registration number
@VATNumber nvarchar(20) VAT number
@VATNumber2 nvarchar(15) VAT number 2
@VATPayer int VATPayer
@TransportID int ID of transport from transport list (see relation) API_GetTransports.ID
@Username nvarchar(255) Username
@Password nvarchar(25) Password
@OrderConfirmationPassword nvarchar(25) Order confirmation password
@Street nvarchar(100) Street
@City nvarchar(80) City
@ZIPCode nvarchar(15) ZIP code
@State int ID of country from country list (see relation) API_GetCountry.ID
@BranchID int ID of branche from branch list (see relation) API_GetBranches.ID
@WorkshopID int ID of workshop from workshop list (see relation) API_GetWorkshops.ID
@StockID int ID of stock from stock list (see relation) API_GetStocks.ID
@CurrencyID int ID of currency from currency list (see relation) API_GetCurrency.ID
@SendOrderConfirmationEmail int Send order confirmation email
@OrderConfirmationEmail nvarchar(100) Order confirmation email
@Email nvarchar(100) Email
@EshopEmails nvarchar(400) Eshop emails
@IsBuyer int Is buyer
@IsSupplier int Is supplier
@Region nvarchar(30) Region
@Country nvarchar(50) Country
@IsCompetition int Is competition
@FileMarkText nvarchar(200) File mark text
@IsWSInvoicesExportAllowed bit Is WS invoices export allowed
@IsWSDeliveryNotesExportAllowed bit Is WS delivery notes export Allowed
@IsWSImportOrdersAllowed bit Is WS import orders Allowed
@StoreBackOrder int Store backorder
@IsSupplierIndividualOrders int Is supplier individual orders
@IsSupplierShortcut nvarchar(10) Is supplier shortcut
@Note nvarchar(500) Note
@Note2 nvarchar(500) Note 2
@GlobalPricing int Global pricing
@OrderGroup nvarchar(10) Order group
@GPSLatitude nvarchar(20) GPS latitude
@GPSLongitude nvarchar(20) GPS longitude
@ParentID int ParentID


Example

 DECLARE @ID int
 DECLARE @ShortName nvarchar(30)
 DECLARE @CompanyName nvarchar(250)
 DECLARE @CompanyRegistrationNumber nvarchar(20)
 DECLARE @VATNumber nvarchar(20)
 DECLARE @VATNumber2 nvarchar(15)
 DECLARE @VATPayer int
 DECLARE @TransportID int
 DECLARE @Username nvarchar(20)
 DECLARE @Password nvarchar(25)
 DECLARE @OrderConfirmationPassword nvarchar(25)
 DECLARE @Street nvarchar(100)
 DECLARE @City nvarchar(80)
 DECLARE @ZIPCode nvarchar(15)
 DECLARE @Region nvarchar(30)
 DECLARE @Country nvarchar(50)
 DECLARE @FileMarkText nvarchar(200)
 DECLARE @BranchID int
 DECLARE @WorkshopID int
 DECLARE @StockID int
 DECLARE @CurrencyID int
 DECLARE @State int
 DECLARE @SendOrderConfirmationEmail int
 DECLARE @OrderConfirmationEmail nvarchar(100)
 DECLARE @Email nvarchar(100)
 DECLARE @EShopEMails nvarchar(400)
 DECLARE @IsBuyer bit
 DECLARE @IsSupplier bit
 DECLARE @IsCompetition bit
 DECLARE @IsWSInvoicesExportAllowed bit
 DECLARE @IsWSDeliveryNotesExportAllowed bit
 DECLARE @IsWSImportOrdersAllowed bit
 DECLARE @StoreBackOrder bit
 DECLARE @IsSupplierIndividualOrders bit
 DECLARE @IsSupplierShortcut nvarchar(10)
 DECLARE @Note nvarchar(500)
 DECLARE @Note2 nvarchar(500)
 DECLARE @GlobalPricing bit
 DECLARE @OrderGroup nvarchar(10)
 DECLARE @GPSLatitude nvarchar(20)
 DECLARE @GPSLongitude nvarchar(20)
 DECLARE @ParentID int

 
 SELECT @ID = [ID], 
       @ShortName = [ShortName],
       @CompanyName = [CompanyName],
       @CompanyRegistrationNumber = [CompanyRegistrationNumber],
       @VATNumber = [VATNumber],
       @VATNumber2 = [VATNumber2],
       @VATPayer = [VATPayer],
       @TransportID = [TransportID],
       @Username = [Username],
       @Password = [Password],
       @OrderConfirmationPassword = [OrderConfirmationPassword],
       @Street = [Street],
       @City = [City],
       @ZIPCode = [ZIPCode],
       @Region = [Region],
       @Country = [Country],
       @FileMarkText = [FileMarkText],
       @BranchID = [BranchID],
       @WorkshopID = [WorkshopID],
       @StockID = [StockID],
       @CurrencyID = [CurrencyID],
       @State = [State],
       @SendOrderConfirmationEmail = [SendOrderConfirmationEmail],
       @OrderConfirmationEmail = [OrderConfirmationEmail],
       @Email = [Email],
       @EShopEMails = [EShopEMails],
       @IsBuyer = [IsBuyer],
       @IsSupplier = [IsSupplier],
       @IsCompetition = [IsCompetition],
       @IsWSInvoicesExportAllowed = [IsWSInvoicesExportAllowed],
       @IsWSDeliveryNotesExportAllowed = [IsWSDeliveryNotesExportAllowed],
       @IsWSImportOrdersAllowed = [IsWSImportOrdersAllowed],
       @StoreBackOrder = [StoreBackOrder],
       @IsSupplierIndividualOrders = [IsSupplierIndividualOrders],
       @IsSupplierShortcut = [IsSupplierShortcut],
       @Note = [Note],
       @Note2 = [Note2],
       @GlobalPricing = [GlobalPricing],
       @OrderGroup = [OrderGroup],
       @GPSLatitude = [GPSLatitude],
       @GPSLongitude = [GPSLongitude],
       @ParentID = [ParentID]
 FROM   [API_GetCustomers] 
 WHERE  id = 3
 
 EXECUTE [API_UpdateCustomer] 
  @ID,
  @ShortName,
  @CompanyName,
  @CompanyRegistrationNumber,
  @VATNumber,
  @VATNumber2,
  @VATPayer,
  @TransportID,
  @Username,
  @Password,
  @OrderConfirmationPassword,
  @Street,
  @City,
  @ZIPCode,
  @Region,
  @Country,
  @FileMarkText,
  @BranchID,
  @WorkshopID,
  @StockID,
  @CurrencyID,
  @State,
  @SendOrderConfirmationEmail,
  @OrderConfirmationEmail,
  @Email,
  @EShopEMails,
  @IsBuyer,
  @IsSupplier,
  @IsCompetition,
  @IsWSInvoicesExportAllowed,
  @IsWSDeliveryNotesExportAllowed,
  @IsWSImportOrdersAllowed,
  @StoreBackOrder,
  @IsSupplierIndividualOrders,
  @IsSupplierShortcut,
  @Note,
  @Note2,
  @GlobalPricing,
  @OrderGroup,
  @GPSLatitude,
  @GPSLongitude,
  @ParentID

Notices

None.