mirror of
https://github.com/bitwarden/server.git
synced 2025-07-03 00:52:49 -05:00
Added Sql project with database schema. Added SqlServer repositories for Site, Folder, and User (Cipher still TODO). Switched DI in Startup to SqlServer repos.
This commit is contained in:
43
src/Sql/dbo/Stored Procedures/User_Create.sql
Normal file
43
src/Sql/dbo/Stored Procedures/User_Create.sql
Normal file
@ -0,0 +1,43 @@
|
||||
CREATE PROCEDURE [dbo].[User_Create]
|
||||
@Id UNIQUEIDENTIFIER,
|
||||
@Name NVARCHAR(50),
|
||||
@Email NVARCHAR(50),
|
||||
@MasterPassword NVARCHAR(300),
|
||||
@MasterPasswordHint NVARCHAR(50),
|
||||
@Culture NVARCHAR(10),
|
||||
@SecurityStamp NVARCHAR(50),
|
||||
@TwoFactorEnabled BIT,
|
||||
@TwoFactorProvider TINYINT,
|
||||
@AuthenticatorKey NVARCHAR(50),
|
||||
@CreationDate DATETIME2(7)
|
||||
AS
|
||||
BEGIN
|
||||
INSERT INTO [dbo].[User]
|
||||
(
|
||||
[Id],
|
||||
[Name],
|
||||
[Email],
|
||||
[MasterPassword],
|
||||
[MasterPasswordHint],
|
||||
[Culture],
|
||||
[SecurityStamp],
|
||||
[TwoFactorEnabled],
|
||||
[TwoFactorProvider],
|
||||
[AuthenticatorKey],
|
||||
[CreationDate]
|
||||
)
|
||||
VALUES
|
||||
(
|
||||
@Id,
|
||||
@Name,
|
||||
@Email,
|
||||
@MasterPassword,
|
||||
@MasterPasswordHint,
|
||||
@Culture,
|
||||
@SecurityStamp,
|
||||
@TwoFactorEnabled,
|
||||
@TwoFactorProvider,
|
||||
@AuthenticatorKey,
|
||||
@CreationDate
|
||||
)
|
||||
END
|
Reference in New Issue
Block a user