
ALTER TABLE dbo.ApiCrmTasks ADD CustErpId INT NOT NULL DEFAULT(0);
GO

ALTER TABLE dbo.ApiWorkers ADD CustId int NOT NULL DEFAULT(0)
GO

ALTER TABLE dbo.[ApiWmsDocuments] ADD 
--int [Priority] NOT NULL DEFAULT(0),
int PlaceId NOT NULL DEFAULT(0),
int OperatorId NOT NULL DEFAULT(0),
int OwnerId NOT NULL DEFAULT(0),
datetime ALTERTS ;
GO



  ALTER TABLE dbo.[ApiWmsDocLines] ADD 
--int [Priority] NOT NULL DEFAULT(0),
Stock decimal(18, 2)   NOT NULL DEFAULT(0),
int OperatorId NOT NULL DEFAULT(0),
int OwnerId NOT NULL DEFAULT(0),
datetime ALTERTS ;
GO

  ALTER TABLE dbo.ApiWorkers ADD 
  ImapServer nvarchar(50),ImapUser nvarchar(50),ImapPassword nvarchar(50),
  ImapPort int NOT NULL DEFAULT(0), ImapSSL int NOT NULL DEFAULT(0),
  SmtpServer nvarchar(50),SmtpUser nvarchar(50),SmtpPassword nvarchar(50),
  SmtpPort int NOT NULL DEFAULT(0), 
  SmtpSSL int NOT NULL DEFAULT(0),
  CheckMailBox int NOT NULL DEFAULT(0),
  EmailAdress nvarchar(50);

  GO