mirror of
https://github.com/bitwarden/server.git
synced 2025-05-28 14:54:50 -05:00
move script back and move userview update up
This commit is contained in:
parent
266fc579f2
commit
b0aef93597
@ -7,6 +7,30 @@ BEGIN
|
||||
END
|
||||
GO
|
||||
|
||||
IF NOT EXISTS (
|
||||
SELECT * FROM sys.indexes WHERE [Name]='IX_User_Premium_PremiumExpirationDate_RenewalReminderDate'
|
||||
AND object_id = OBJECT_ID('[dbo].[User]')
|
||||
)
|
||||
BEGIN
|
||||
CREATE NONCLUSTERED INDEX [IX_User_Premium_PremiumExpirationDate_RenewalReminderDate]
|
||||
ON [dbo].[User]([Premium] ASC, [PremiumExpirationDate] ASC, [RenewalReminderDate] ASC)
|
||||
END
|
||||
GO
|
||||
|
||||
IF EXISTS(SELECT * FROM sys.views WHERE [Name] = 'UserView')
|
||||
BEGIN
|
||||
DROP VIEW [dbo].[UserView]
|
||||
END
|
||||
GO
|
||||
|
||||
CREATE VIEW [dbo].[UserView]
|
||||
AS
|
||||
SELECT
|
||||
*
|
||||
FROM
|
||||
[dbo].[User]
|
||||
GO
|
||||
|
||||
IF OBJECT_ID('[dbo].[User_Create]') IS NOT NULL
|
||||
BEGIN
|
||||
DROP PROCEDURE [dbo].[User_Create]
|
||||
@ -471,17 +495,3 @@ BEGIN
|
||||
EXEC [dbo].[User_BumpAccountRevisionDateByOrganizationId] @OrganizationId
|
||||
END
|
||||
GO
|
||||
|
||||
IF EXISTS(SELECT * FROM sys.views WHERE [Name] = 'UserView')
|
||||
BEGIN
|
||||
DROP VIEW [dbo].[UserView]
|
||||
END
|
||||
GO
|
||||
|
||||
CREATE VIEW [dbo].[UserView]
|
||||
AS
|
||||
SELECT
|
||||
*
|
||||
FROM
|
||||
[dbo].[User]
|
||||
GO
|
||||
|
@ -1,9 +0,0 @@
|
||||
IF NOT EXISTS (
|
||||
SELECT * FROM sys.indexes WHERE [Name]='IX_User_Premium_PremiumExpirationDate_RenewalReminderDate'
|
||||
AND object_id = OBJECT_ID('[dbo].[User]')
|
||||
)
|
||||
BEGIN
|
||||
CREATE NONCLUSTERED INDEX [IX_User_Premium_PremiumExpirationDate_RenewalReminderDate]
|
||||
ON [dbo].[User]([Premium] ASC, [PremiumExpirationDate] ASC, [RenewalReminderDate] ASC)
|
||||
END
|
||||
GO
|
@ -252,7 +252,7 @@ namespace Bit.Setup
|
||||
.JournalToSqlTable("dbo", "Migration")
|
||||
.WithScriptsAndCodeEmbeddedInAssembly(Assembly.GetExecutingAssembly(),
|
||||
s => s.Contains($".DbScripts.") && !s.Contains(".Archive."))
|
||||
.WithTransactionPerScript()
|
||||
.WithTransaction()
|
||||
.WithExecutionTimeout(new TimeSpan(0, 5, 0))
|
||||
.LogToConsole()
|
||||
.Build();
|
||||
|
@ -11,11 +11,9 @@
|
||||
<None Remove="DbScripts\2018-04-02_00_Org2fa.sql" />
|
||||
<None Remove="DbScripts\2018-04-24_00_CipherQueryTuning.sql" />
|
||||
<None Remove="DbScripts\2018-06-11_00_WebVaultUpdates.sql" />
|
||||
<None Remove="DbScripts\2018-07-19_00_UserPremiumIndex.sql" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<EmbeddedResource Include="DbScripts\2018-07-19_00_UserPremiumIndex.sql" />
|
||||
<EmbeddedResource Include="DbScripts\2018-06-11_00_WebVaultUpdates.sql" />
|
||||
<EmbeddedResource Include="DbScripts\2018-04-24_00_CipherQueryTuning.sql" />
|
||||
<EmbeddedResource Include="DbScripts\2018-04-02_00_Org2fa.sql" />
|
||||
|
Loading…
x
Reference in New Issue
Block a user