Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Coscine
backend
libraries
Migrations
Commits
97b9a4ea
Commit
97b9a4ea
authored
Jun 18, 2020
by
Marcel Nellesen
Browse files
Merge branch 'Sprint/2020-10' into 'Product/702-createUserProfile'
parents
6e51230b
0cec191b
Changes
3
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
src/Migrator/Migrations/Migration202005281400ProjectUrl.cs
0 → 100644
View file @
97b9a4ea
using
FluentMigrator
;
using
System
;
namespace
Coscine.Database.Migration.Migrations
{
//yyyymmddhhmm
[
Migration
(
202005281400
)]
public
class
Migration202005281400ProjectUrl
:
FluentMigrator
.
Migration
{
public
override
void
Down
()
{
Delete
.
Column
(
"Slug"
).
FromTable
(
"Projects"
);
}
public
override
void
Up
()
{
Alter
.
Table
(
"Projects"
).
AddColumn
(
"Slug"
).
AsString
(
63
).
Nullable
();
Execute
.
EmbeddedScript
(
"Migration202005281400ProjectUrl_up.sql"
);
Alter
.
Table
(
"Projects"
).
AlterColumn
(
"Slug"
).
AsString
(
63
).
NotNullable
();
}
}
}
src/Migrator/Migrations/Migration202005281400ProjectUrl_up.sql
0 → 100644
View file @
97b9a4ea
UPDATE
[
Coscine
].[
dbo
].[
Projects
]
SET
Slug
=
Id
\ No newline at end of file
src/Migrator/Migrator.csproj
View file @
97b9a4ea
...
...
@@ -146,6 +146,7 @@
<Compile
Include=
"MigrationsHelpers.cs"
/>
<Compile
Include=
"Migrations\Migration201907011352ProjectApi.cs"
/>
<Compile
Include=
"Migrations\Migration201907081510EnhanceProjectApi.cs"
/>
<Compile
Include=
"Migrations\Migration202005281400ProjectUrl.cs"
/>
<Compile
Include=
"Migrations\Migration201910021300ResourceDescription.cs"
/>
<Compile
Include=
"Migrations\Migration201909190938ResourceEnhancement.cs"
/>
<Compile
Include=
"Migrations\Migration201909111125ProjectEnhancement.cs"
/>
...
...
@@ -182,6 +183,9 @@
<EmbeddedResource
Include=
"Assets\Institutes.csv"
/>
<None
Include=
"packages.config"
/>
</ItemGroup>
<ItemGroup>
<EmbeddedResource
Include=
"Migrations\Migration202005281400ProjectUrl_up.sql"
/>
</ItemGroup>
<ItemGroup>
<EmbeddedResource
Include=
"Migrations\Migration202003121255ActivatedFeatures_up.sql"
/>
</ItemGroup>
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment